pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/devel/ocaml-findlib



Module Name:    pkgsrc
Committed By:   jaapb
Date:           Sat Jun 25 13:55:15 UTC 2016

Modified Files:
        pkgsrc/devel/ocaml-findlib: Makefile PLIST
Added Files:
        pkgsrc/devel/ocaml-findlib: INSTALL
Removed Files:
        pkgsrc/devel/ocaml-findlib/files: ocaml-findlib-register.sh

Log Message:
- Removed ocaml-findlib-register, no longer needed;
- Updated INSTALL fragment to detect and add to ld.conf the autodetected
  libraries that are part of the standard ocaml installation
Discussed on packages@ and OK'd by jperkin


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 pkgsrc/devel/ocaml-findlib/INSTALL
cvs rdiff -u -r1.28 -r1.29 pkgsrc/devel/ocaml-findlib/Makefile
cvs rdiff -u -r1.10 -r1.11 pkgsrc/devel/ocaml-findlib/PLIST
cvs rdiff -u -r1.1 -r0 \
    pkgsrc/devel/ocaml-findlib/files/ocaml-findlib-register.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/devel/ocaml-findlib/Makefile
diff -u pkgsrc/devel/ocaml-findlib/Makefile:1.28 pkgsrc/devel/ocaml-findlib/Makefile:1.29
--- pkgsrc/devel/ocaml-findlib/Makefile:1.28    Thu May  5 09:42:19 2016
+++ pkgsrc/devel/ocaml-findlib/Makefile Sat Jun 25 13:55:15 2016
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.28 2016/05/05 09:42:19 jaapb Exp $
+# $NetBSD: Makefile,v 1.29 2016/06/25 13:55:15 jaapb Exp $
 
 DISTNAME=              findlib-1.6.2
 PKGNAME=       ocaml-${DISTNAME}
+PKGREVISION=   1
 CATEGORIES=            devel
 MASTER_SITES=          http://download.camlcity.org/download/
 
@@ -10,12 +11,15 @@ HOMEPAGE=           http://www.camlcity.org/
 COMMENT=               Library finder for OCaml
 LICENSE=               mit
 
+OCAML_FINDLIB_DIRS+=   bigarray bytes compiler-libs dynlink findlib graphics \
+                       ocamldoc num-top num stdlib str threads unix
+
 .include "../../mk/ocaml.mk"
 
 # Undeclared dependencies between different components
 MAKE_JOBS_SAFE=                no
 
-USE_TOOLS+=            gmake m4 bash
+USE_TOOLS+=            gmake m4 bash fgrep:run sh:run
 USE_PKGLOCALEDIR=      yes
 HAS_CONFIGURE=         yes
 CONFIGURE_ARGS+=       -bindir ${PREFIX}/bin
@@ -35,7 +39,8 @@ INSTALLATION_DIRS=    lib/ocaml libexec bin
 
 CONF_FILES=            ${EGDIR}/ocamlfind.conf ${PKG_SYSCONFDIR}/ocamlfind.conf
 
-USE_TOOLS+=            fgrep:run sh:run
+FILES_SUBST+=          OCAML_FINDLIB_DIRS="${OCAML_FINDLIB_DIRS}" OCAML_SITELIBDIR="${OCAML_SITELIBDIR}"
+
 SUBST_CLASSES+=                ofr
 SUBST_STAGE.ofr=       pre-configure
 SUBST_FILES.ofr=       ocaml-findlib-register.sh
@@ -48,12 +53,6 @@ SUBST_STAGE.pathes=  post-install
 SUBST_FILES.pathes=    ${DESTDIR}${PREFIX}/lib/ocaml/site-lib/findlib/Makefile.config
 SUBST_SED.pathes=      -e 's,^\(OCAML_CORE_BIN=\).*,\1'${PREFIX:Q}/bin','
 
-post-extract:
-       ${CP} ${FILESDIR}/ocaml-findlib-register.sh ${WRKSRC}
-
-post-install:
-       ${INSTALL_SCRIPT} ${WRKSRC}/ocaml-findlib-register.sh ${DESTDIR}${PREFIX}/libexec/ocaml-findlib-register
-
 do-test:
        ${RUN} cd ${WRKSRC}; ${SH} itest
 

Index: pkgsrc/devel/ocaml-findlib/PLIST
diff -u pkgsrc/devel/ocaml-findlib/PLIST:1.10 pkgsrc/devel/ocaml-findlib/PLIST:1.11
--- pkgsrc/devel/ocaml-findlib/PLIST:1.10       Thu May  5 09:42:19 2016
+++ pkgsrc/devel/ocaml-findlib/PLIST    Sat Jun 25 13:55:15 2016
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.10 2016/05/05 09:42:19 jaapb Exp $
+@comment $NetBSD: PLIST,v 1.11 2016/06/25 13:55:15 jaapb Exp $
 bin/ocamlfind
 ${OCAML_SITELIB}/bigarray/META
 ${OCAML_SITELIB}/bytes/META
@@ -38,7 +38,6 @@ ${OCAML_SITELIB}/str/META
 ${OCAML_SITELIB}/threads/META
 ${OCAML_SITELIB}/unix/META
 lib/ocaml/topfind
-libexec/ocaml-findlib-register
 @comment man/man1/ocamlfind.1
 @comment man/man5/META.5
 @comment man/man5/findlib.conf.5

Added files:

Index: pkgsrc/devel/ocaml-findlib/INSTALL
diff -u /dev/null pkgsrc/devel/ocaml-findlib/INSTALL:1.1
--- /dev/null   Sat Jun 25 13:55:15 2016
+++ pkgsrc/devel/ocaml-findlib/INSTALL  Sat Jun 25 13:55:15 2016
@@ -0,0 +1,22 @@
+#!@SH@
+#
+# $NetBSD: INSTALL,v 1.1 2016/06/25 13:55:15 jaapb Exp $
+
+GREP="@GREP@"
+OCAML_FINDLIB_DIRS="@OCAML_FINDLIB_DIRS@"
+OCAML_SITELIBDIR="@OCAML_SITELIBDIR@"
+TOUCH="@TOUCH@"
+
+LDCONF="@PREFIX@/lib/ocaml/ld.conf"
+
+case "${STAGE}" in
+POST-INSTALL)
+       ${TOUCH} "${LDCONF}.tmp"
+       for i in ${OCAML_FINDLIB_DIRS}
+       do
+               ${GREP} -F -v -- "${OCAML_SITELIBDIR}/$i" < "${LDCONF}" > "${LDCONF}.tmp"
+               ${ECHO} "@PREFIX@/${OCAML_SITELIBDIR}/$i" >> "${LDCONF}.tmp"
+               mv "${LDCONF}.tmp" "${LDCONF}"
+       done
+        ;;
+esac



Home | Main Index | Thread Index | Old Index