tech-pkg archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
cmake prefix buildink question
Hello,
I'm trying to build wip/freecad, and it chokes because cad/occt's cmake file
includes path to the buildink directory:
fgrep .buildlink /usr/pkg/lib/cmake/opencascade/OpenCASCADEVisualizationTargets.cmake
INTERFACE_LINK_LIBRARIES "TKernel;TKMath;X11;fontconfig;/usr/tmp/cad/occt/work/.buildlink/lib/libfreeimage.so;/usr/tmp/cad/occt/work/.buildlink/lib/libfreetype.so"
INTERFACE_LINK_LIBRARIES "TKBRep;TKMath;TKernel;TKService;TKShHealing;TKTopAlgo;TKG2d;TKG3d;TKGeomBase;TKMesh;TKGeomAlgo;TKHLR;GL;X11;/usr/tmp/cad/occt/work/.buildlink/lib/libfreetype.so"
I guess this is because the installed files uses the same value as the one
used to build the package.
The attached patch works around this, but is there a better way to fix this ?
--
Manuel Bouyer <bouyer%antioche.eu.org@localhost>
NetBSD: 26 ans d'experience feront toujours la difference
--
Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/cad/occt/Makefile,v
retrieving revision 1.9
diff -u -p -u -r1.9 Makefile
--- Makefile 30 Oct 2025 13:25:14 -0000 1.9
+++ Makefile 1 Feb 2026 20:42:13 -0000
@@ -1,6 +1,7 @@
# $NetBSD: Makefile,v 1.9 2025/10/30 13:25:14 gdt Exp $
VERSION= 7.8.0
+PKGREVISION= 1
DISTNAME= opencascade-${VERSION}
PKGNAME= ${DISTNAME:S/opencascade/occt/}
CATEGORIES= cad
@@ -50,6 +51,11 @@ OCCT_CUSTOM_COMPILER_DRIVER= custom_gcc_
PLIST_SUBST= OCCT_CUSTOM_COMPILER_DRIVER=${OCCT_CUSTOM_COMPILER_DRIVER:Q}
PLIST_SUBST+= MINOR_VERSION=${VERSION:C/.[0-9]$//}
+SUBST_CLASSES+= cmakefiles
+SUBST_STAGE.cmakefiles= post-configure
+SUBST_FILES.cmakefiles= cmake-pkgsrc-build/CMakeFiles/Export/*/*.cmake
+SUBST_SED.cmakefiles= -e 's,${BUILDLINK_DIR},${PREFIX},g'
+
.include "../../devel/cmake/build.mk"
.include "../../fonts/fontconfig/buildlink3.mk"
.include "../../graphics/freetype2/buildlink3.mk"
Home |
Main Index |
Thread Index |
Old Index