lang/ocaml: Fix build on aarch64

SYSTEM_ARCH has to be set to arm64
The raw_spacetime_lib is only built on aarch64

Approved by:	portmgr (build fix blanket)
This commit is contained in:
Mikael Urankar 2023-07-28 09:04:38 +02:00
parent 1c54dce738
commit 7638e6aabb
2 changed files with 17 additions and 1 deletions

View file

@ -48,7 +48,7 @@ CONFIGURE_ARGS= --prefix="${PREFIX}"
CONFIGURE_ENV= LDFLAGS="${LDFLAGS}" \
ASPP="${CC} -c" \
PARTIALLD="${LD} -r"
MAKE_ENV= SYSTEM_ARCH="${ARCH:C/powerpc.*/power/}"
MAKE_ENV= SYSTEM_ARCH="${ARCH:C/aarch64/arm64/:C/powerpc.*/power/}"
OPTIONS_DEFINE= X11 THREADS DOCS EXAMPLES
OPTIONS_DEFAULT=X11 THREADS
@ -74,6 +74,12 @@ DOCS_DISTFILES= ${DISTNAME:R}-refman-html.tar.gz:docs \
.include <bsd.port.pre.mk>
.if ${ARCH} == aarch64
PLIST_SUB+= RAWSPACETIMELIB=" "
.else
PLIST_SUB+= RAWSPACETIMELIB="@comment "
.endif
.if ${ARCH} == armv6 || ${ARCH} == armv7
CONFIGURE_ENV+= AS="${AS} ${ASFLAGS} -meabi=5" \
CC="${CC}"

View file

@ -1440,6 +1440,7 @@ lib/ocaml/libcamlrund.a
lib/ocaml/libcamlruni.a
lib/ocaml/libcamlstr.a
%%X11%%lib/ocaml/libgraphics.a
%%RAWSPACETIMELIB%%lib/ocaml/libraw_spacetime_lib.a
%%THREADS%%lib/ocaml/libthreads.a
%%THREADS%%lib/ocaml/libthreadsnat.a
lib/ocaml/libunix.a
@ -1581,6 +1582,14 @@ lib/ocaml/queue.ml
lib/ocaml/queue.mli
lib/ocaml/random.ml
lib/ocaml/random.mli
%%RAWSPACETIMELIB%%lib/ocaml/raw_spacetime_lib.a
%%RAWSPACETIMELIB%%lib/ocaml/raw_spacetime_lib.cma
%%RAWSPACETIMELIB%%lib/ocaml/raw_spacetime_lib.cmi
%%RAWSPACETIMELIB%%lib/ocaml/raw_spacetime_lib.cmti
%%RAWSPACETIMELIB%%lib/ocaml/raw_spacetime_lib.cmx
%%RAWSPACETIMELIB%%lib/ocaml/raw_spacetime_lib.cmxa
%%RAWSPACETIMELIB%%lib/ocaml/raw_spacetime_lib.cmxs
%%RAWSPACETIMELIB%%lib/ocaml/raw_spacetime_lib.mli
lib/ocaml/result.ml
lib/ocaml/result.mli
lib/ocaml/scanf.ml
@ -1957,6 +1966,7 @@ lib/ocaml/stringLabels.ml
lib/ocaml/stringLabels.mli
lib/ocaml/stublibs/dllcamlstr.so
%%X11%%lib/ocaml/stublibs/dllgraphics.so
%%RAWSPACETIMELIB%%lib/ocaml/stublibs/dllraw_spacetime_lib.so
%%THREADS%%lib/ocaml/stublibs/dllthreads.so
lib/ocaml/stublibs/dllunix.so
lib/ocaml/stublibs/dllvmthreads.so