ports/science/openmolcas/files/patch-CMakeLists.txt
Yuri Victorovich 6f94e40e34 science/openmolcas: Update 22.02 -> 22.06
Also test target is added.
The workaround for the cmake bug when cmake fails to find the
physical memory size is added.
2022-07-26 10:05:36 -07:00

22 lines
998 B
Text

--- CMakeLists.txt.orig 2022-06-07 08:43:34 UTC
+++ CMakeLists.txt
@@ -48,7 +48,7 @@ find_program (GIT "git")
find_program (PERL "perl")
mark_as_advanced (FORCE GIT PERL)
-FIND_PACKAGE (Python COMPONENTS Interpreter)
+FIND_PACKAGE (Python ${FREEBSD_PYTHON_VER} EXACT COMPONENTS Interpreter)
################################################################################
# #
@@ -2375,6 +2375,10 @@ message ("Configuring runtime environment settings:")
cmake_host_system_information (RESULT host_mem QUERY TOTAL_PHYSICAL_MEMORY)
cmake_host_system_information (RESULT host_name QUERY HOSTNAME)
cmake_host_system_information (RESULT host_system QUERY OS_NAME)
+
+# workaround for https://gitlab.kitware.com/cmake/cmake/-/issues/23776
+execute_process(COMMAND sysctl -n hw.physmem OUTPUT_VARIABLE host_mem)
+math (EXPR host_mem "${host_mem}/1024/1024")
# memory/disk default sizes
#==========================