The attached diff modifies an existing patch to lang/elixir to detect erlang's erts directory (containing the "erl" binary) at runtime instead of hardcoding it to "erl${MODERL_VERSION}".

This fixes the remaining test failures that occurred because no self-contained releases could be built, plus it makes 'mix release' work properly on OpenBSD.

It also contains a trivial update to the latest bugfix release 1.14.3

Tested on amd64.
Index: Makefile
===================================================================
RCS file: /cvs/ports/lang/elixir/Makefile,v
retrieving revision 1.65
diff -u -p -r1.65 Makefile
--- Makefile	23 Dec 2022 10:14:01 -0000	1.65
+++ Makefile	15 Jan 2023 15:43:17 -0000
@@ -1,6 +1,6 @@
 COMMENT=		functional language for building scalable applications
 
-V=			1.14.2
+V=			1.14.3
 GH_ACCOUNT=		elixir-lang
 GH_PROJECT=		elixir
 GH_TAGNAME=		v$V
Index: distinfo
===================================================================
RCS file: /cvs/ports/lang/elixir/distinfo,v
retrieving revision 1.55
diff -u -p -r1.55 distinfo
--- distinfo	23 Dec 2022 10:14:01 -0000	1.55
+++ distinfo	15 Jan 2023 15:43:17 -0000
@@ -1,2 +1,2 @@
-SHA256 (elixir-1.14.2.tar.gz) = P3njhHBklXJRGfYJgvoW6oLVEMP76s/G7hp3x5K/FSo=
-SIZE (elixir-1.14.2.tar.gz) = 3085613
+SHA256 (elixir-1.14.3.tar.gz) = vUZBRSV/Nr1k97qL7ZO2SZxQVxtBXEkbICZ9J9cDVwc=
+SIZE (elixir-1.14.3.tar.gz) = 3086297
Index: patches/patch-bin_elixir
===================================================================
RCS file: /cvs/ports/lang/elixir/patches/patch-bin_elixir,v
retrieving revision 1.8
diff -u -p -r1.8 patch-bin_elixir
--- patches/patch-bin_elixir	4 Sep 2022 08:36:44 -0000	1.8
+++ patches/patch-bin_elixir	15 Jan 2023 15:43:17 -0000
@@ -1,12 +1,16 @@
+Detect erlang ERTS directory at runtime.
+
 Index: bin/elixir
 --- bin/elixir.orig
 +++ bin/elixir
-@@ -92,7 +92,7 @@ starts_with () {
-   esac
- }
+@@ -226,7 +226,9 @@ fi
  
--ERL_EXEC="erl"
-+ERL_EXEC="erl${MODERL_VERSION}"
- MODE="elixir"
- I=1
- E=0
+ # One MAY change ERTS_BIN= but you MUST NOT change
+ # ERTS_BIN=$ERTS_BIN as it is handled by Elixir releases.
+-ERTS_BIN=
++for obsd_erts in ${LOCALBASE}/lib/erlang${MODERL_VERSION}/erts-*; do
++  ERTS_BIN="$obsd_erts/bin/";
++done
+ ERTS_BIN="$ERTS_BIN"
+ 
+ set -- "$ERTS_BIN$ERL_EXEC" -pa "$SCRIPT_PATH"/../lib/*/ebin $ELIXIR_ERL_OPTIONS $ERL "$@"

Reply via email to