pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/x11/ocaml-lablgtk3
Module Name: pkgsrc
Committed By: gdt
Date: Sun Nov 24 14:32:49 UTC 2024
Modified Files:
pkgsrc/x11/ocaml-lablgtk3: Makefile
Log Message:
x11/ocaml-lablgtk3: Kludge around dune pkg-config issues
For unclear reasons, if PKG_CONFIG is set in the environment, even if
properly to a copy of pkg-config in the work directory, dune objects
to it and errors out. Remove PKG_CONFIG from the build environment.
This allows building to succeed.
This commit adds some test targets, not invoked, with comments that
are notes to the next person struggling with this, perhaps future
self.
The removal of PKG_CONFIG is implemented by open-coding the do-build
target from ocaml.mk, pending disscussion of the wisdom of changing
that target, on the theory that this is a dune bug, not a lablgtk bug.
To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 pkgsrc/x11/ocaml-lablgtk3/Makefile
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/x11/ocaml-lablgtk3/Makefile
diff -u pkgsrc/x11/ocaml-lablgtk3/Makefile:1.33 pkgsrc/x11/ocaml-lablgtk3/Makefile:1.34
--- pkgsrc/x11/ocaml-lablgtk3/Makefile:1.33 Sun Nov 24 12:20:57 2024
+++ pkgsrc/x11/ocaml-lablgtk3/Makefile Sun Nov 24 14:32:49 2024
@@ -1,11 +1,11 @@
-# $NetBSD: Makefile,v 1.33 2024/11/24 12:20:57 gdt Exp $
+# $NetBSD: Makefile,v 1.34 2024/11/24 14:32:49 gdt Exp $
GITHUB_PROJECT= lablgtk
GITHUB_TAG= ${VERSION}
VERSION= 3.1.3
DISTNAME= ${GITHUB_PROJECT}-${VERSION}
PKGNAME= ocaml-${GITHUB_PROJECT}3-${VERSION}
-PKGREVISION= 17
+PKGREVISION= 18
CATEGORIES= x11
MASTER_SITES= ${MASTER_SITE_GITHUB:=garrigue/}
@@ -21,6 +21,27 @@ OCAML_FINDLIB_DIRS= lablgtk3
OPAM_INSTALL_FILES= ${OCAML_FINDLIB_DIRS}
DUNE_BUILD_PACKAGES= ${OCAML_FINDLIB_DIRS}
+# Undo the wrapper, in the hope that dune finds real pkg-config. Does not help.
+no-pkgconfig-wrapper:
+ ${RM} ${WRKDIR}/.tools/bin/pkg-config
+ ${CP} ${PREFIX}/bin/pkg-config ${WRKDIR}/.tools/bin/pkg-config
+
+# dune tries to run pkg-config, and this fails under pkgsrc for some reason.
+# But when run in pre-configure, it seems to be ok.
+test-dune-config:
+ ${ECHO} Testing dune calling pkg-config.
+ (cd ${WRKSRC} && \
+ dune exec -- ./_build/default/.bin/dune_config -verbose -pkg gtk+-3.0 -version 3.18) || ${TRUE}
+
+# This is a huge hack, to undefine PKG_CONFIG in the environment,
+# which apparently breaks dune's searching for pkg-config. Copied
+# from ocaml/ocaml.mk, to where it should perhaps be hoisted.
+do-build:
+ ${RUN} ${_ULIMIT_CMD} \
+ cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${SETENV} -u PKG_CONFIG \
+ dune build -j ${MAKE_JOBS:U1} \
+ ${DUNE_BUILD_FLAGS} -p ${DUNE_BUILD_PACKAGES:ts,} \
+ ${DUNE_BUILD_TARGETS}
.include "../../lang/ocaml/ocaml.mk"
Home |
Main Index |
Thread Index |
Old Index