aboutsummaryrefslogtreecommitdiff
path: root/math
diff options
context:
space:
mode:
Diffstat (limited to 'math')
-rw-r--r--math/Makefile1
-rw-r--r--math/primecount/Makefile31
-rw-r--r--math/primecount/distinfo3
-rw-r--r--math/primecount/pkg-descr5
-rw-r--r--math/primecount/pkg-plist7
5 files changed, 47 insertions, 0 deletions
diff --git a/math/Makefile b/math/Makefile
index 5341be1e6987..5ee6ba182630 100644
--- a/math/Makefile
+++ b/math/Makefile
@@ -778,6 +778,7 @@
SUBDIR += poly2tri
SUBDIR += polylib
SUBDIR += polymake
+ SUBDIR += primecount
SUBDIR += primegen
SUBDIR += primesieve
SUBDIR += primme
diff --git a/math/primecount/Makefile b/math/primecount/Makefile
new file mode 100644
index 000000000000..1a69fdf704c9
--- /dev/null
+++ b/math/primecount/Makefile
@@ -0,0 +1,31 @@
+# Created by: thierry@pompo.net
+
+PORTNAME= primecount
+DISTVERSIONPREFIX= v
+DISTVERSION= 7.1
+CATEGORIES= math
+
+MAINTAINER= thierry@FreeBSD.org
+COMMENT= Fast prime counting function implementations
+
+LICENSE= BSD2CLAUSE
+
+BUILD_DEPENDS= libdivide>0:math/libdivide
+LIB_DEPENDS= libprimesieve.so:math/primesieve
+
+USE_GITHUB= yes
+GH_ACCOUNT= kimwalisch
+
+USES= cmake compiler:c++11-lang
+USE_LDCONFIG= yes
+
+CMAKE_ON= BUILD_SHARED_LIBS
+CMAKE_OFF= BUILD_LIBPRIMESIEVE BUILD_STATIC_LIBS
+
+do-test:
+ cd ${BUILD_WRKSRC} && \
+ ${SETENV} ${CONFIGURE_ENV} ${CMAKE_BIN} ${CMAKE_ARGS} -DBUILD_TESTS:BOOL=ON ${CMAKE_SOURCE_PATH} && \
+ ${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_ARGS} ${ALL_TARGET} && \
+ ${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_ARGS} test
+
+.include <bsd.port.mk>
diff --git a/math/primecount/distinfo b/math/primecount/distinfo
new file mode 100644
index 000000000000..96c6224de16d
--- /dev/null
+++ b/math/primecount/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1638108625
+SHA256 (kimwalisch-primecount-v7.1_GH0.tar.gz) = 4f156f3945b613c9262156a25255f689abcaf30fff778c1d27b17126fcd1db72
+SIZE (kimwalisch-primecount-v7.1_GH0.tar.gz) = 331976
diff --git a/math/primecount/pkg-descr b/math/primecount/pkg-descr
new file mode 100644
index 000000000000..39d205fd17fb
--- /dev/null
+++ b/math/primecount/pkg-descr
@@ -0,0 +1,5 @@
+primecount is a command-line program and C/C++ library that counts the primes
+below an integer x <= 1031 using highly optimized implementations of the
+combinatorial prime counting algorithms.
+
+WWW: https://github.com/kimwalisch/primecount
diff --git a/math/primecount/pkg-plist b/math/primecount/pkg-plist
new file mode 100644
index 000000000000..c437ab5777b0
--- /dev/null
+++ b/math/primecount/pkg-plist
@@ -0,0 +1,7 @@
+bin/primecount
+include/primecount.h
+include/primecount.hpp
+lib/libprimecount.so
+lib/libprimecount.so.7
+lib/libprimecount.so.7.1
+man/man1/primecount.1.gz