pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/mk Added variable to have ocaml-jbuilder only build ce...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/d74b563e836a
branches:  trunk
changeset: 367873:d74b563e836a
user:      jaapb <jaapb%pkgsrc.org@localhost>
date:      Fri Sep 08 08:39:06 2017 +0000

description:
Added variable to have ocaml-jbuilder only build certain packages

diffstat:

 mk/ocaml.mk |  10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diffs (40 lines):

diff -r d5e4fa8e3100 -r d74b563e836a mk/ocaml.mk
--- a/mk/ocaml.mk       Fri Sep 08 08:19:39 2017 +0000
+++ b/mk/ocaml.mk       Fri Sep 08 08:39:06 2017 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: ocaml.mk,v 1.14 2017/07/26 09:41:31 jaapb Exp $
+# $NetBSD: ocaml.mk,v 1.15 2017/09/08 08:39:06 jaapb Exp $
 #
 # This Makefile fragment handles the common variables used by OCaml packages.
 #
@@ -58,6 +58,7 @@
        OCAML_TOPKG_OPTIONAL_TARGETS \
        OCAML_USE_JBUILDER \
        JBUILDER_BUILD_FLAGS \
+       JBUILDER_BUILD_PACKAGES \
        JBUILDER_BUILD_TARGETS \
        OCAML_BUILD_ARGS \
        OPAM_INSTALL_FILES
@@ -96,6 +97,7 @@
 OPAM_INSTALL_FILES?=   ${OCAML_TOPKG_NAME}
 JBUILDER_BUILD_FLAGS?= # empty
 JBUILDER_BUILD_TARGETS?=       @install
+JBUILDER_BUILD_PACKAGES?=      # empty
 
 # Default value of OASIS_BUILD_ARGS
 OASIS_BUILD_ARGS?=     # empty
@@ -243,8 +245,14 @@
 .if ${OCAML_USE_JBUILDER} == "yes"
 
 do-build:
+.if !empty(JBUILDER_BUILD_PACKAGES)
+       ${RUN} cd ${WRKSRC} && jbuilder build -j ${MAKE_JOBS} \
+               ${JBUILDER_BUILD_FLAGS} -p ${JBUILDER_BUILD_PACKAGES:ts,} \
+               ${JBUILDER_BUILD_TARGETS}
+.else
        ${RUN} cd ${WRKSRC} && jbuilder build -j ${MAKE_JOBS} \
                ${JBUILDER_BUILD_FLAGS} ${JBUILDER_BUILD_TARGETS}
+.endif
 
 .endif # topkg-jbuilder
 



Home | Main Index | Thread Index | Old Index