aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuri Victorovich <yuri@FreeBSD.org>2022-04-20 03:34:59 +0000
committerYuri Victorovich <yuri@FreeBSD.org>2022-04-20 03:40:01 +0000
commit8966a50749a7196941feb311dd6f9fa01ca73868 (patch)
tree11469ee01e4dbd6c6435e9238304656d26d5eebc
parent7b0ed522b1c641d4bcfc9e9c4d8b18710c945320 (diff)
downloadports-8966a50749a7196941feb311dd6f9fa01ca73868.tar.gz
ports-8966a50749a7196941feb311dd6f9fa01ca73868.zip
math/ambit: Update 0.5.1 -> 0.6
Also add test target. Reported by: portscout
-rw-r--r--math/ambit/Makefile13
-rw-r--r--math/ambit/distinfo6
-rw-r--r--math/ambit/files/patch-CMakeLists.txt25
-rw-r--r--math/ambit/files/patch-src_CMakeLists.txt14
4 files changed, 46 insertions, 12 deletions
diff --git a/math/ambit/Makefile b/math/ambit/Makefile
index 5d134e127598..8a5940ccc07a 100644
--- a/math/ambit/Makefile
+++ b/math/ambit/Makefile
@@ -1,6 +1,6 @@
PORTNAME= ambit
DISTVERSIONPREFIX= v
-DISTVERSION= 0.5.1
+DISTVERSION= 0.6
CATEGORIES= math
PKGNAMESUFFIX= -tensor # avoid clash with shells/ambit
@@ -14,14 +14,15 @@ LIB_DEPENDS= libhdf5.so:science/hdf5 \
libopenblas.so:math/openblas \
libsz.so:science/szip
-USES= cmake compiler:c++11-lang python:build
+USES= cmake:testing compiler:c++11-lang python:build
+USE_LDCONFIG= yes
+
USE_GITHUB= yes
GH_ACCOUNT= jturney
-USE_LDCONFIG= yes
# some declared cmake options do nothing: see https://github.com/jturney/ambit/issues/25 and the patch
-CMAKE_ARGS+= -DSHARED_ONLY:BOOL=ON
-CMAKE_ARGS+= -DENABLE_OPENMP:BOOL=ON
-CMAKE_ARGS+= -DENABLE_TESTS:BOOL=OFF # https://github.com/jturney/ambit/issues/24
+CMAKE_ON= SHARED_ONLY ENABLE_OPENMP
+CMAKE_OFF= ENABLE_TESTS # https://github.com/jturney/ambit/issues/24
+CMAKE_TESTING_ON= ENABLE_TESTS
.include <bsd.port.mk>
diff --git a/math/ambit/distinfo b/math/ambit/distinfo
index 4566b1cc405d..2371492c9e70 100644
--- a/math/ambit/distinfo
+++ b/math/ambit/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1595259724
-SHA256 (jturney-ambit-v0.5.1_GH0.tar.gz) = 9c132fa9d735b0137190b9412ae516cf855efd626fe8ab4125518ff0a6525c98
-SIZE (jturney-ambit-v0.5.1_GH0.tar.gz) = 341152
+TIMESTAMP = 1650421128
+SHA256 (jturney-ambit-v0.6_GH0.tar.gz) = ede894402ef719e74e9d03a9458139543fa66d38d0cf91632362ba8a0e478aa6
+SIZE (jturney-ambit-v0.6_GH0.tar.gz) = 332730
diff --git a/math/ambit/files/patch-CMakeLists.txt b/math/ambit/files/patch-CMakeLists.txt
index 4b42af67a27e..116e9ce72f8f 100644
--- a/math/ambit/files/patch-CMakeLists.txt
+++ b/math/ambit/files/patch-CMakeLists.txt
@@ -1,6 +1,25 @@
---- CMakeLists.txt.orig 2017-11-12 20:15:25 UTC
+--- CMakeLists.txt.orig 2022-03-26 22:14:15 UTC
+++ CMakeLists.txt
-@@ -155,7 +155,7 @@ add_subdirectory(include)
+@@ -99,7 +99,7 @@ find_package (TargetLAPACK REQUIRED)
+
+ # Python Detection
+ set(Python_ADDITIONAL_VERSIONS 3.10 3.9 3.8 3.7) # adjust with CMake minimum FindPythonInterp
+-find_package(Python 3.7 COMPONENTS Interpreter Development NumPy REQUIRED)
++find_package(Python 3.7 COMPONENTS Interpreter Development REQUIRED)
+ message(STATUS "Found Python ${Python_VERSION_MAJOR}.${Python_VERSION_MINOR}: ${Python_EXECUTABLE} (found version ${Python_VERSION})")
+
+ #if (NOT ENABLE_STATIC AND NOT ENABLE_PSI4)
+@@ -149,7 +149,9 @@ endif()
+ #endif()
+
+ # library directory
++if (FREEBSD_BUILD_PYTHON_BINDING)
+ add_subdirectory(lib)
++endif()
+
+ # include directory (for installation)
+ add_subdirectory(include)
+@@ -157,7 +159,7 @@ add_subdirectory(include)
# recursively add source directories
add_subdirectory(src)
@@ -9,7 +28,7 @@
# test suite
enable_testing()
include(CTest)
-@@ -163,7 +163,7 @@ add_subdirectory(src)
+@@ -165,7 +167,7 @@ add_subdirectory(src)
# sample suite
add_subdirectory(samples)
diff --git a/math/ambit/files/patch-src_CMakeLists.txt b/math/ambit/files/patch-src_CMakeLists.txt
new file mode 100644
index 000000000000..774e662241d2
--- /dev/null
+++ b/math/ambit/files/patch-src_CMakeLists.txt
@@ -0,0 +1,14 @@
+- python bindinf isn't installed into the right location, see https://github.com/jturney/ambit/issues/54
+
+--- src/CMakeLists.txt.orig 2022-04-20 02:23:19 UTC
++++ src/CMakeLists.txt
+@@ -128,7 +128,9 @@ else()
+ add_library(ambit-lib ALIAS ambit-shared)
+ endif()
+
++if (FREEBSD_BUILD_PYTHON_BINDING)
+ add_subdirectory(python)
++endif()
+
+ # <<< Install >>>
+