git: d98decf4c6f7 - main - science/votca: Fix build with HDF5 1.12.0+
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 18 Jul 2022 12:52:04 UTC
The branch main has been updated by sunpoet:
URL: https://cgit.FreeBSD.org/ports/commit/?id=d98decf4c6f7a8d92e742a8fd7b7795818a0904f
commit d98decf4c6f7a8d92e742a8fd7b7795818a0904f
Author: Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2022-07-18 12:50:26 +0000
Commit: Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2022-07-18 12:51:29 +0000
science/votca: Fix build with HDF5 1.12.0+
---
science/votca/Makefile | 2 +-
science/votca/files/patch-hdf5 | 28 ++++++++++++++++++++++++++++
2 files changed, 29 insertions(+), 1 deletion(-)
diff --git a/science/votca/Makefile b/science/votca/Makefile
index 0a05b64299e6..6c8ad2ba96bc 100644
--- a/science/votca/Makefile
+++ b/science/votca/Makefile
@@ -47,7 +47,7 @@ SHEBANG_FILES= csg/scripts/csg_call.in csg/scripts/csg_inverse.in \
xtp/scripts/xtp_qmmm2qm.in
CMAKE_ON= BUILD_XTP
-CMAKE_ARGS= -DPython_EXECUTABLE=${PYTHON_CMD}
+CMAKE_ARGS= -DLOCALBASE=${LOCALBASE} -DPython_EXECUTABLE=${PYTHON_CMD}
OPTIONS_DEFINE= APPS
OPTIONS_DEFAULT= APPS
diff --git a/science/votca/files/patch-hdf5 b/science/votca/files/patch-hdf5
new file mode 100644
index 000000000000..24bcadb8e571
--- /dev/null
+++ b/science/votca/files/patch-hdf5
@@ -0,0 +1,28 @@
+--- csg/src/libcsg/CMakeLists.txt.orig 2022-01-15 22:47:05 UTC
++++ csg/src/libcsg/CMakeLists.txt
+@@ -14,8 +14,9 @@ if (TARGET Gromacs::libgromacs)
+ target_link_libraries(votca_csg PRIVATE Gromacs::libgromacs)
+ endif()
+
+-
+-find_package(HDF5 COMPONENTS "CXX")
++set(HDF5_FOUND TRUE)
++set(HDF5_INCLUDE_DIRS "${LOCALBASE}/include")
++set(HDF5_LIBRARIES "-L${LOCALBASE}/lib -lhdf5 -lhdf5_cpp")
+ set_package_properties(HDF5 PROPERTIES TYPE RECOMMENDED PURPOSE "Used to read h5md data files")
+ if(HDF5_FOUND)
+ set(H5MD true)
+--- xtp/CMakeLists.txt.orig 2022-01-15 22:47:05 UTC
++++ xtp/CMakeLists.txt
+@@ -50,7 +50,10 @@ find_package(ecpint REQUIRED)
+ set_package_properties(ecpint PROPERTIES TYPE REQUIRED PURPOSE "Calculates Gaussian integrals over pseudo potentials")
+ message(STATUS "Found libecpint: ${ecpint_DIR}")
+
+-find_package(HDF5 1.8 REQUIRED COMPONENTS CXX)
++set(HDF5_FOUND TRUE)
++set(HDF5_VERSION 1.12)
++set(HDF5_INCLUDE_DIRS "${LOCALBASE}/include")
++set(HDF5_LIBRARIES "-L${LOCALBASE}/lib -lhdf5 -lhdf5_cpp")
+ set_package_properties(HDF5 PROPERTIES TYPE REQUIRED PURPOSE "Used to read/write HDF5 data files")
+
+ if(HDF5_VERSION VERSION_GREATER 1.8)