Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 21 Mar 2024 18:02:13 GMT
From:      Thierry Thomas <thierry@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: d0646a9501a8 - main - science/elmerfem: support opencascade-7.8.0
Message-ID:  <202403211802.42LI2Dkq023279@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by thierry:

URL: https://cgit.FreeBSD.org/ports/commit/?id=d0646a9501a862ba21e8f9c1e919d94580036379

commit d0646a9501a862ba21e8f9c1e919d94580036379
Author:     Henrik Gulbrandsen <henrik@gulbra.net>
AuthorDate: 2024-03-16 13:02:09 +0000
Commit:     Thierry Thomas <thierry@FreeBSD.org>
CommitDate: 2024-03-21 18:01:17 +0000

    science/elmerfem: support opencascade-7.8.0
    
    PR:             277307
---
 science/elmerfem/Makefile                            |  8 ++++----
 science/elmerfem/files/patch-ElmerGUI_CMakeLists.txt | 15 +++++++++++++++
 2 files changed, 19 insertions(+), 4 deletions(-)

diff --git a/science/elmerfem/Makefile b/science/elmerfem/Makefile
index e14f822e06da..3f807b3cb60c 100644
--- a/science/elmerfem/Makefile
+++ b/science/elmerfem/Makefile
@@ -1,7 +1,7 @@
 PORTNAME=	elmerfem
 DISTVERSIONPREFIX=	release-
 DISTVERSION=	9.0
-PORTREVISION=	14
+PORTREVISION=	15
 CATEGORIES=	science
 
 PATCH_SITES=	https://github.com/ElmerCSC/${PORTNAME}/commit/
@@ -97,10 +97,10 @@ post-patch:
 	@${REINPLACE_CMD} -e 's,"metis.*/metis\.h",<metis.h>,' \
 		${WRKSRC}/elmergrid/src/egparallel.c
 
-post-patch-OCC-on:
-	@${REINPLACE_CMD} -e "s|\$${VERSION}|`${PKG_QUERY} '%v' opencascade`|" \
+pre-configure-OCC-on:
+	${REINPLACE_CMD} -e "s|\$${VERSION}|`${PKG_QUERY} '%v' opencascade`|" \
 		"${WRKSRC}/cmake/Modules/FindOCE.cmake"
-	@${REINPLACE_CMD} -e 's|$${INCLUDE}|${LOCALBASE}/include/OpenCASCADE|' \
+	${REINPLACE_CMD} -e 's|$${INCLUDE}|${LOCALBASE}/include/OpenCASCADE|' \
 		"${WRKSRC}/cmake/Modules/FindOCE.cmake"
 
 post-configure:
diff --git a/science/elmerfem/files/patch-ElmerGUI_CMakeLists.txt b/science/elmerfem/files/patch-ElmerGUI_CMakeLists.txt
new file mode 100644
index 000000000000..1207457d52e1
--- /dev/null
+++ b/science/elmerfem/files/patch-ElmerGUI_CMakeLists.txt
@@ -0,0 +1,15 @@
+--- ElmerGUI/CMakeLists.txt.orig	2020-11-10 19:52:44 UTC
++++ ElmerGUI/CMakeLists.txt
+@@ -83,7 +83,11 @@ IF(WITH_OCC)
+     MESSAGE(STATUS "  [ElmerGUI] OCE_VERSION:       " ${OCE_VERSION})
+     MESSAGE(STATUS "  [ElmerGUI] OCE_INCLUDE_DIRS:  " ${OCE_INCLUDE_DIRS})
+   ENDIF()
+-  SET(ELMER_OCC_LIBS "TKernel;TKMath;TKG3d;TKG2d;TKBRep;TKSTEP;TKMesh;TKIGES;TKG2d;TKGeomBase;TKBool;TKBO;TKGeomAlgo;TKPrim;TKShHealing;TKSTEP209;TKSTEPAttr;TKSTEPBase;TKTopAlgo;TKXSBase" CACHE INTERNAL "")
++  IF(OCE_VERSION AND OCE_VERSION VERSION_GREATER_EQUAL "7.8.0")
++    SET(ELMER_OCC_LIBS "TKernel;TKMath;TKG3d;TKG2d;TKBRep;TKDESTEP;TKMesh;TKDEIGES;TKG2d;TKGeomBase;TKBool;TKBO;TKGeomAlgo;TKPrim;TKShHealing;TKTopAlgo;TKXSBase" CACHE INTERNAL "")
++  ELSE()
++    SET(ELMER_OCC_LIBS "TKernel;TKMath;TKG3d;TKG2d;TKBRep;TKSTEP;TKMesh;TKIGES;TKG2d;TKGeomBase;TKBool;TKBO;TKGeomAlgo;TKPrim;TKShHealing;TKSTEP209;TKSTEPAttr;TKSTEPBase;TKTopAlgo;TKXSBase" CACHE INTERNAL "")
++  ENDIF()
+   MESSAGE(STATUS "  [ElmerGUI] ELMER_OCC_LIBS:    " "${ELMER_OCC_LIBS}")
+   MESSAGE(STATUS "------------------------------------------------")
+ ENDIF()



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202403211802.42LI2Dkq023279>