summaryrefslogtreecommitdiff
path: root/devel/ocaml-findlib
diff options
context:
space:
mode:
Diffstat (limited to 'devel/ocaml-findlib')
-rw-r--r--devel/ocaml-findlib/Makefile25
-rw-r--r--devel/ocaml-findlib/files/patch-configure12
-rw-r--r--devel/ocaml-findlib/files/patch-src_findlib-toolbox_Makefile11
-rw-r--r--devel/ocaml-findlib/pkg-plist4
4 files changed, 32 insertions, 20 deletions
diff --git a/devel/ocaml-findlib/Makefile b/devel/ocaml-findlib/Makefile
index 8de85e2b19c5..f61db9ce2bce 100644
--- a/devel/ocaml-findlib/Makefile
+++ b/devel/ocaml-findlib/Makefile
@@ -1,6 +1,6 @@
PORTNAME= findlib
PORTVERSION= 1.9.6
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= devel
MASTER_SITES= http://download.camlcity.org/download/
PKGNAMEPREFIX= ocaml-
@@ -15,8 +15,6 @@ LICENSE_FILE= ${WRKSRC}/LICENSE
USES= gmake
USE_OCAML= yes
USE_OCAML_CAMLP4=yes
-USE_OCAML_FINDLIB=yes
-OCAMLFIND_DEPEND= # Avoid dependency loop
HAS_CONFIGURE= yes
CONFIGURE_ARGS= -bindir "${PREFIX}/bin" -mandir "${PREFIX}/share/man" \
-sitelib "${PREFIX}/${OCAML_SITELIBDIR}" \
@@ -24,7 +22,7 @@ CONFIGURE_ARGS= -bindir "${PREFIX}/bin" -mandir "${PREFIX}/share/man" \
MAKE_ENV= OCAML_LIBDIR="${PREFIX}/${OCAML_LIBDIR}"
ALL_TARGET= all opt
MAKE_JOBS_UNSAFE= yes
-DOCSDIR= ${PREFIX}/share/doc/ocaml/${PORTNAME}
+DOCSDIR= ${OCAML_DOCSDIR}/${PORTNAME}
PORTDOCS= *
OPTIONS_DEFINE= TOOLBOX DOCS
@@ -39,21 +37,16 @@ TOOLBOX_BUILD_DEPENDS= ${TOOLBOX_RUN_DEPENDS}
.include <bsd.port.pre.mk>
post-install:
- cd ${STAGEDIR}${PREFIX} && \
+ # META files provided by the respective ocaml-* package,
+ # (those libraries used to be belong in the core ocaml
+ # compiler package).
+ @for oldlib in camlp4 graphics labltk ocamlbuild; \
+ do ${RM} -r ${STAGEDIR}${PREFIX}/${OCAML_SITELIBDIR}/$$oldlib ; done
+ @(cd ${STAGEDIR}${PREFIX} && \
${STRIP_CMD} bin/ocamlfind \
${OCAML_SITELIBDIR}/findlib/findlib.cmxs \
${OCAML_SITELIBDIR}/findlib/findlib_dynload.cmxs \
- ${OCAML_SITELIBDIR}/findlib/findlib_top.cmxs
-.if !exists(${LOCALBASE}/lib/ocaml/graphics.cmi)
- @${REINPLACE_CMD} -e '/graphics\/META/d' ${TMPPLIST}
-.endif
-.if !exists(${LOCALBASE}/lib/ocaml/ocamlbuild/ocamlbuildlib.cma)
- @${REINPLACE_CMD} -e '/ocamlbuild\/META/d' ${TMPPLIST}
-.endif
-# Spacetime profiling is only available for native code on 64-bit targets
-.if ${ARCH} == armv7 || ${ARCH} == i386 || ${ARCH} == powerpc || ${ARCH} == powerpcspe
- @${REINPLACE_CMD} -e '/raw_spacetime/d' ${TMPPLIST}
-.endif
+ ${OCAML_SITELIBDIR}/findlib/findlib_top.cmxs)
post-install-TOOLBOX-on:
${CHMOD} 755 ${STAGEDIR}${PREFIX}/bin/ocamlfind \
diff --git a/devel/ocaml-findlib/files/patch-configure b/devel/ocaml-findlib/files/patch-configure
new file mode 100644
index 000000000000..b70bddb841fd
--- /dev/null
+++ b/devel/ocaml-findlib/files/patch-configure
@@ -0,0 +1,12 @@
+--- configure.orig 2024-03-01 00:17:41 UTC
++++ configure
+@@ -457,9 +457,7 @@ if [ -d "${ocaml_sitelib}" ] && [ ${ocaml_major} -lt 5
+ echo "Installation has: $findlib_installed_meta"
+ else
+ previous_config=''
+- check_before_install=1
+ echo "Querying installation: META list not found"
+- echo "make install will double-check installed META files"
+ fi
+ else
+ previous_config=''
diff --git a/devel/ocaml-findlib/files/patch-src_findlib-toolbox_Makefile b/devel/ocaml-findlib/files/patch-src_findlib-toolbox_Makefile
new file mode 100644
index 000000000000..629b264f1aea
--- /dev/null
+++ b/devel/ocaml-findlib/files/patch-src_findlib-toolbox_Makefile
@@ -0,0 +1,11 @@
+--- src/findlib-toolbox/Makefile.orig 2024-03-01 00:20:34 UTC
++++ src/findlib-toolbox/Makefile
+@@ -9,7 +9,7 @@ make_wizard$(EXEC_SUFFIX): make_wizard.ml
+ true
+
+ make_wizard$(EXEC_SUFFIX): make_wizard.ml
+- ocamlc -o make_wizard$(EXEC_SUFFIX) -I +unix -I +labltk -I ../findlib \
++ ocamlc -o make_wizard$(EXEC_SUFFIX) -I +unix -I +site-lib/labltk -I ../findlib \
+ unix.cma str.cma labltk.cma findlib.cma make_wizard.ml
+
+ install:
diff --git a/devel/ocaml-findlib/pkg-plist b/devel/ocaml-findlib/pkg-plist
index b30e436e3923..034467e6b8f1 100644
--- a/devel/ocaml-findlib/pkg-plist
+++ b/devel/ocaml-findlib/pkg-plist
@@ -3,7 +3,6 @@ bin/safe_camlp4
%%ETCDIR%%.conf
%%OCAML_SITELIBDIR%%/bigarray/META
%%OCAML_SITELIBDIR%%/bytes/META
-%%OCAML_SITELIBDIR%%/camlp4/META
%%OCAML_SITELIBDIR%%/compiler-libs/META
%%OCAML_SITELIBDIR%%/dynlink/META
%%OCAML_SITELIBDIR%%/findlib/META
@@ -42,9 +41,6 @@ bin/safe_camlp4
%%TOOLBOX%%%%OCAML_SITELIBDIR%%/findlib/make_wizard.pattern
%%OCAML_SITELIBDIR%%/findlib/topfind.cmi
%%OCAML_SITELIBDIR%%/findlib/topfind.mli
-%%OCAML_SITELIBDIR%%/graphics/META
-%%TOOLBOX%%%%OCAML_SITELIBDIR%%/labltk/META
-%%OCAML_SITELIBDIR%%/ocamlbuild/META
%%OCAML_SITELIBDIR%%/ocamldoc/META
%%OCAML_SITELIBDIR%%/stdlib/META
%%OCAML_SITELIBDIR%%/str/META