aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--math/suitesparse/Makefile108
-rw-r--r--math/suitesparse/bsd.suitesparse.mk136
-rw-r--r--math/suitesparse/distinfo6
-rw-r--r--math/suitesparse/pkg-descr4
-rw-r--r--math/suitesparse/pkg-plist142
5 files changed, 163 insertions, 233 deletions
diff --git a/math/suitesparse/Makefile b/math/suitesparse/Makefile
index 4b288536795d..2ac859a1ccb8 100644
--- a/math/suitesparse/Makefile
+++ b/math/suitesparse/Makefile
@@ -2,99 +2,33 @@
PORTNAME= suitesparse
PORTVERSION= 5.10.0
-DISTVERSIONPREFIX= v
+PORTREVISION= 1
CATEGORIES= math
MAINTAINER= fortran@FreeBSD.org
COMMENT= Set of packages for sparse matrix calculation
-LICENSE= GPLv2 LGPL21
-LICENSE_COMB= dual
-
-LIB_DEPENDS= libgmp.so:math/gmp \
- libmpfr.so:math/mpfr \
- libmetis.so:math/metis
-
-USE_GITHUB= yes
-GH_ACCOUNT= DrTimothyAldenDavis
-GH_PROJECT= SuiteSparse
-
-USES= cmake:insource fortran gmake localbase:ldflags
-USE_LDCONFIG= yes
-INSTALL_TARGET= install # skip USES=cmake
-MAKE_ENV= BLAS="${BLASLIB}" LAPACK="${LAPACKLIB}" \
- MY_METIS_LIB="-lmetis" \
- JOBS="${MAKE_JOBS_NUMBER}" \
- CMAKE_OPTIONS='${CMAKE_ARGS}' \
- INSTALL="${STAGEDIR}${PREFIX}" \
- INSTALL_DOC="${STAGEDIR}${DOCSDIR}" \
- INSTALL_INCLUDE="${STAGEDIR}${PREFIX}/include/${PORTNAME}"
-CMAKE_ARGS= -DCMAKE_INSTALL_INCLUDEDIR:PATH="include/${PORTNAME}" \
- -DBUILD_GRB_STATIC_LIBRARY:BOOL=ON
-LDFLAGS+= -L${WRKSRC}/lib # prevent linking with shared libs from the preinstalled older versions
-
-CONFLICTS_INSTALL= mongoose plinkseq # bin/mongoose
-
-OPTIONS_DEFINE= DEMOS DOCS OPENMP # TBB
-OPTIONS_EXCLUDE_aarch64= OPENMP
-OPTIONS_RADIO= BLAS
-OPTIONS_RADIO_BLAS= ATLAS GOTOBLAS NETLIB OPENBLAS
-OPTIONS_DEFAULT= OPENBLAS OPENMP # TBB
-
-ATLAS_USES= blaslapack:atlas
-GOTOBLAS_DESC= Goto blas implementation
-GOTOBLAS_USES= blaslapack:gotoblas
-NETLIB_USES= blaslapack:netlib
-OPENBLAS_USES= blaslapack:openblas
-
-OPENMP_MAKE_ENV_OFF= CFOPENMP=
-.if !exists(/usr/include/omp.h)
-# XXX ports/199603: LLVM openmp in base doesn't support armv6, armv7 yet
-OPENMP_VARS= OPENMP=gcc-
+LICENSE= GPLv2+
+
+RUN_DEPENDS= suitesparse-AMD>0:math/suitesparse-amd \
+ suitesparse-BTF>0:math/suitesparse-btf \
+ suitesparse-CCOLAMD>0:math/suitesparse-ccolamd \
+ suitesparse-CHOLMOD>0:math/suitesparse-cholmod \
+ suitesparse-COLAMD>0:math/suitesparse-colamd \
+ suitesparse-config>0:math/suitesparse-config \
+ suitesparse-CXSparse>0:math/suitesparse-cxsparse \
+ suitesparse-GraphBLAS>0:math/suitesparse-graphblas \
+ suitesparse-KLU>0:math/suitesparse-klu \
+ suitesparse-LDL>0:math/suitesparse-ldl \
+ suitesparse-Mongoose>0:math/suitesparse-mongoose \
+ suitesparse-RBio>0:math/suitesparse-rbio \
+ suitesparse-SLIP_LU>0:math/suitesparse-slip_lu \
+ suitesparse-SPQR>0:math/suitesparse-spqr \
+ suitesparse-UMFPACK>0:math/suitesparse-umfpack
+.if !defined(PACKAGE_BUILDING)
+RUN_DEPENDS+= suitesparse-CSparse>0:math/suitesparse-csparse
.endif
-DEMOS_DESC= Install the demonstrations
-DEMOS_ALL_TARGET= go
-DEMOS_ALL_TARGET_OFF= library
-
-TBB_DESC= Intel threading building blocks
-TBB_LIB_DEPENDS= libtbb.so:devel/tbb
-TBB_MAKE_ENV= TBB="-ltbb" SPQR_CONFIG="-DHAVE_TBB"
-# See https://github.com/DrTimothyAldenDavis/SuiteSparse/issues/72
-TBB_BROKEN= oneTBB doesn't provide tbb/task_scheduler_init.h any more, see PR 252651
-
-MODULES= AMD CAMD CCOLAMD CHOLMOD COLAMD CSparse CXSparse_newfiles \
- CXSparse GPUQREngine KLU LDL RBio SPQR UMFPACK
-
-.include <bsd.port.options.mk>
-
-.if ${ARCH} == i386
-# See PR 230888 : Missing 64 bit atomic functions for i386
-USE_GCC= yes
-LDFLAGS+= -latomic
-.elif defined(PPC_ABI) && ${PPC_ABI} == ELFv1
-USE_GCC= yes
-.else
-USES+= compiler:c++11-lib
-.endif
-
-post-extract:
- ${RM} -r ${WRKSRC}/metis-*
-
-post-patch-OPENMP-off:
- @${REINPLACE_CMD} -e '/find_package.*OpenMP/d' \
- ${WRKSRC}/GraphBLAS/CMakeLists.txt
-
-pre-configure:
-.for m in ${MODULES}
- ${REINPLACE_CMD} -e 's|-I../../include|-I${STAGEDIR}${PREFIX}/include/suitesparse|;\
- s|-lsuitesparseconfig|-lsuitesparseconfig -L${LOCALBASE}/lib|' \
- ${WRKSRC}/${m}/Demo/Makefile
-.endfor
-
-do-configure: # skip USES=cmake
-
-post-install:
- @${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/* ${STAGEDIR}${PREFIX}/lib/*.so
+USES= metaport
.include <bsd.port.mk>
diff --git a/math/suitesparse/bsd.suitesparse.mk b/math/suitesparse/bsd.suitesparse.mk
new file mode 100644
index 000000000000..1da90622f2e0
--- /dev/null
+++ b/math/suitesparse/bsd.suitesparse.mk
@@ -0,0 +1,136 @@
+# Created by: Maho Nakata <maho@FreeBSD.org>
+#
+# Common elements used by the SuiteSparse modules
+
+PKGNAMEPREFIX= suitesparse-
+SSPNAME= suitesparse
+SSPVERSION= 5.10.0
+DISTVERSIONPREFIX= v
+
+MAINTAINER= fortran@FreeBSD.org
+
+#USE_GITHUB= yes # Does not work with different versions for modules
+GH_ACCOUNT= DrTimothyAldenDavis
+GH_PROJECT= SuiteSparse
+GH_TAGNAME= ${SSPVERSION}
+MASTER_SITES= https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/archive/refs/tags/
+DISTNAME= ${DISTVERSIONPREFIX}${SSPVERSION}
+DIST_SUBDIR= ${SSPNAME}
+WRKSRC= ${WRKDIR}/${GH_PROJECT}-${SSPVERSION}
+
+.if ${PORTNAME} != config && \
+ ${PORTNAME} != CSparse && \
+ ${PORTNAME} != ssget
+LIB_DEPENDS+= libsuitesparseconfig.so:math/suitesparse-config
+.endif
+.if ${PORTNAME} != config && \
+ ${PORTNAME} != BTF && \
+ ${PORTNAME} != ssget
+OPTIONS_DEFINE+=DEMOS
+.else
+ALL_TARGET= library
+.endif
+
+USES+= gmake
+
+DOCSDIR= ${PREFIX}/share/doc/${SSPNAME}
+MAKE_ENV= BLAS="${BLASLIB}" LAPACK="${LAPACKLIB}" \
+ OPTIMIZATION="${OPTIMIZATION}" \
+ MY_METIS_LIB="-lmetis" \
+ JOBS="${MAKE_JOBS_NUMBER}" \
+ CMAKE_OPTIONS='${CMAKE_ARGS}' \
+ INSTALL="${STAGEDIR}${PREFIX}" \
+ INSTALL_DOC="${STAGEDIR}${DOCSDIR}" \
+ INSTALL_INCLUDE="${STAGEDIR}${PREFIX}/include/${SSPNAME}"
+CMAKE_ARGS= -DCMAKE_INSTALL_INCLUDEDIR:PATH="include/${SSPNAME}" \
+ -DBUILD_GRB_STATIC_LIBRARY:BOOL=ON
+LDFLAGS+= -L${WRKSRC}/lib # prevent linking with shared libs from the preinstalled older versions
+
+INSTALL_TARGET= install # skip USES=cmake
+INSTALL_WRKSRC= ${BUILD_WRKSRC}
+
+# FIXME: wont work if .CURDIR contains spaces
+DISTINFO_FILE= ${.CURDIR}/../../math/suitesparse/distinfo
+
+OPTIONS_DEFINE+= DOCS OPTIMIZED_CFLAGS
+OPTIONS_DEFAULT+= OPTIMIZED_CFLAGS
+
+.if defined(BLAS_NEEDED)
+OPTIONS_RADIO+= BLAS
+OPTIONS_RADIO_BLAS+= ATLAS GOTOBLAS NETLIB OPENBLAS
+OPTIONS_DEFAULT+= OPENBLAS
+
+ATLAS_USES= blaslapack:atlas
+GOTOBLAS_DESC= Goto blas implementation
+GOTOBLAS_USES= blaslapack:gotoblas
+NETLIB_USES= blaslapack:netlib
+OPENBLAS_USES= blaslapack:openblas
+.endif
+
+.if defined(OMP_NEEDED)
+OPTIONS_DEFINE+= OPENMP
+OPTIONS_EXCLUDE_aarch64= OPENMP
+OPTIONS_DEFAULT+= OPENMP
+
+OPENMP_MAKE_ENV_OFF= CFOPENMP=
+. if !exists(/usr/include/omp.h)
+# XXX ports/199603: LLVM openmp in base doesn't support armv6, armv7 yet
+OPENMP_VARS= OPENMP=gcc-
+. endif
+.endif
+
+DEMOS_DESC= Build the demonstrations
+.if ${PORTNAME} == Mongoose
+DEMOS_ALL_TARGET= default
+.else
+DEMOS_ALL_TARGET= all
+.endif
+DEMOS_ALL_TARGET_OFF= library
+
+.if !defined(WITH_DEBUG)
+OPTIMIZED_CFLAGS_VARS= OPTIMIZATION="-O3"
+LDFLAGS+= -s
+.endif
+
+post-extract:
+ ${RM} -r ${WRKSRC}/metis-*
+
+.if ${PORTNAME} == AMD || \
+ ${PORTNAME} == CAMD || \
+ ${PORTNAME} == CCOLAMD || \
+ ${PORTNAME} == CHOLMOD || \
+ ${PORTNAME} == COLAMD || \
+ ${PORTNAME} == CSparse || \
+ ${PORTNAME} == CXSparse_newfiles || \
+ ${PORTNAME} == CXSparse || \
+ ${PORTNAME} == GPUQREngine || \
+ ${PORTNAME} == KLU || \
+ ${PORTNAME} == LDL || \
+ ${PORTNAME} == RBio || \
+ ${PORTNAME} == SPQR || \
+ ${PORTNAME} == UMFPACK
+pre-configure:
+ ${REINPLACE_CMD} -e 's|-I../../include|-I${STAGEDIR}${PREFIX}/include/suitesparse -I../../SuiteSparse_config -I../../AMD/Include -I../../COLAMD/Include -I../../BTF/Include -I../../CHOLMOD/Include|;\
+ s|-lsuitesparseconfig|-lsuitesparseconfig -L${LOCALBASE}/lib|' \
+ ${BUILD_WRKSRC}/Demo/Makefile
+.endif
+
+do-configure: # skip USES=cmake
+
+post-install:
+.if ! ${PORTNAME} == config
+ @${RM} ${STAGEDIR}${DOCSDIR}/SUITESPARSECONFIG_README.txt \
+ ${STAGEDIR}${PREFIX}/include/suitesparse/SuiteSparse_config.h
+.endif
+
+.include <bsd.port.pre.mk>
+
+.if ${ARCH} == i386
+# See PR 230888 : Missing 64 bit atomic functions for i386
+USE_GCC= yes
+LDFLAGS+= -latomic
+.elif defined(PPC_ABI) && ${PPC_ABI} == ELFv1
+USE_GCC= yes
+.else
+USES+= compiler:c++11-lib
+.endif
diff --git a/math/suitesparse/distinfo b/math/suitesparse/distinfo
index a6a82dbf05fa..fe7b3d794a0d 100644
--- a/math/suitesparse/distinfo
+++ b/math/suitesparse/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1621267603
-SHA256 (DrTimothyAldenDavis-SuiteSparse-v5.10.0_GH0.tar.gz) = 4bcc974901c0173acf80c41ee0fd779eb7dce2871d4afa24a5d15b1a468f93e5
-SIZE (DrTimothyAldenDavis-SuiteSparse-v5.10.0_GH0.tar.gz) = 59919998
+TIMESTAMP = 1621443759
+SHA256 (suitesparse/v5.10.0.tar.gz) = 4bcc974901c0173acf80c41ee0fd779eb7dce2871d4afa24a5d15b1a468f93e5
+SIZE (suitesparse/v5.10.0.tar.gz) = 59919998
diff --git a/math/suitesparse/pkg-descr b/math/suitesparse/pkg-descr
index 7d6d4373c115..77bfa1dbf4b9 100644
--- a/math/suitesparse/pkg-descr
+++ b/math/suitesparse/pkg-descr
@@ -1,4 +1,5 @@
SuiteSparse is a set of sparse matrices libraries.
+
It contains:
* AMD: symmetric approximate minimum degree
* BTF: permutation to block triangular form (beta)
@@ -13,8 +14,9 @@ It contains:
* LDL: a simple LDL^T factorization
* Mongoose: graph partitioning
* RBio: read/write sparse matrices
+ * SLIP_LU : Sparse Left-looking Integer-Preserving LU Factorization
* SPQR: sparse QR factorization
* UMFPACK: sparse multifrontal LU factorization
- * UFconfig: common configuration for all of the above
+ * SuiteSparse_config: common configuration for all of the above
WWW: http://faculty.cse.tamu.edu/davis/suitesparse.html
diff --git a/math/suitesparse/pkg-plist b/math/suitesparse/pkg-plist
deleted file mode 100644
index ae1cd60da741..000000000000
--- a/math/suitesparse/pkg-plist
+++ /dev/null
@@ -1,142 +0,0 @@
-bin/mongoose
-include/suitesparse/GraphBLAS.h
-include/suitesparse/Mongoose.hpp
-include/suitesparse/RBio.h
-include/suitesparse/SLIP_LU.h
-include/suitesparse/SuiteSparseQR.hpp
-include/suitesparse/SuiteSparseQR_C.h
-include/suitesparse/SuiteSparseQR_definitions.h
-include/suitesparse/SuiteSparse_config.h
-include/suitesparse/amd.h
-include/suitesparse/btf.h
-include/suitesparse/camd.h
-include/suitesparse/ccolamd.h
-include/suitesparse/cholmod.h
-include/suitesparse/cholmod_blas.h
-include/suitesparse/cholmod_camd.h
-include/suitesparse/cholmod_check.h
-include/suitesparse/cholmod_cholesky.h
-include/suitesparse/cholmod_complexity.h
-include/suitesparse/cholmod_config.h
-include/suitesparse/cholmod_core.h
-include/suitesparse/cholmod_function.h
-include/suitesparse/cholmod_gpu.h
-include/suitesparse/cholmod_gpu_kernels.h
-include/suitesparse/cholmod_io64.h
-include/suitesparse/cholmod_matrixops.h
-include/suitesparse/cholmod_modify.h
-include/suitesparse/cholmod_partition.h
-include/suitesparse/cholmod_supernodal.h
-include/suitesparse/cholmod_template.h
-include/suitesparse/colamd.h
-include/suitesparse/cs.h
-include/suitesparse/klu.h
-include/suitesparse/ldl.h
-include/suitesparse/spqr.hpp
-include/suitesparse/umfpack.h
-include/suitesparse/umfpack_col_to_triplet.h
-include/suitesparse/umfpack_defaults.h
-include/suitesparse/umfpack_free_numeric.h
-include/suitesparse/umfpack_free_symbolic.h
-include/suitesparse/umfpack_get_determinant.h
-include/suitesparse/umfpack_get_lunz.h
-include/suitesparse/umfpack_get_numeric.h
-include/suitesparse/umfpack_get_symbolic.h
-include/suitesparse/umfpack_global.h
-include/suitesparse/umfpack_load_numeric.h
-include/suitesparse/umfpack_load_symbolic.h
-include/suitesparse/umfpack_numeric.h
-include/suitesparse/umfpack_qsymbolic.h
-include/suitesparse/umfpack_report_control.h
-include/suitesparse/umfpack_report_info.h
-include/suitesparse/umfpack_report_matrix.h
-include/suitesparse/umfpack_report_numeric.h
-include/suitesparse/umfpack_report_perm.h
-include/suitesparse/umfpack_report_status.h
-include/suitesparse/umfpack_report_symbolic.h
-include/suitesparse/umfpack_report_triplet.h
-include/suitesparse/umfpack_report_vector.h
-include/suitesparse/umfpack_save_numeric.h
-include/suitesparse/umfpack_save_symbolic.h
-include/suitesparse/umfpack_scale.h
-include/suitesparse/umfpack_solve.h
-include/suitesparse/umfpack_symbolic.h
-include/suitesparse/umfpack_tictoc.h
-include/suitesparse/umfpack_timer.h
-include/suitesparse/umfpack_transpose.h
-include/suitesparse/umfpack_triplet_to_col.h
-include/suitesparse/umfpack_wsolve.h
-lib/libamd.so
-lib/libamd.so.2
-lib/libamd.so.2.4.6
-lib/libbtf.so
-lib/libbtf.so.1
-lib/libbtf.so.1.2.6
-lib/libcamd.so
-lib/libcamd.so.2
-lib/libcamd.so.2.4.6
-lib/libccolamd.so
-lib/libccolamd.so.2
-lib/libccolamd.so.2.9.6
-lib/libcholmod.so
-lib/libcholmod.so.3
-lib/libcholmod.so.3.0.14
-lib/libcolamd.so
-lib/libcolamd.so.2
-lib/libcolamd.so.2.9.6
-lib/libcxsparse.so
-lib/libcxsparse.so.3
-lib/libcxsparse.so.3.2.0
-lib/libgraphblas.a
-lib/libgraphblas.so
-lib/libgraphblas.so.5
-lib/libgraphblas.so.5.0.4
-lib/libklu.so
-lib/libklu.so.1
-lib/libklu.so.1.3.8
-lib/libldl.so
-lib/libldl.so.2
-lib/libldl.so.2.2.6
-lib/libmongoose.a
-lib/libmongoose.so
-lib/libmongoose.so.2
-lib/libmongoose.so.2.0.4
-lib/librbio.so
-lib/librbio.so.2
-lib/librbio.so.2.2.6
-lib/libsliplu.so
-lib/libsliplu.so.1
-lib/libsliplu.so.1.0.2
-lib/libspqr.so
-lib/libspqr.so.2
-lib/libspqr.so.2.0.9
-lib/libsuitesparseconfig.so
-lib/libsuitesparseconfig.so.5
-lib/libsuitesparseconfig.so.5.10.0
-lib/libumfpack.so
-lib/libumfpack.so.5
-lib/libumfpack.so.5.7.9
-%%PORTDOCS%%%%DOCSDIR%%/AMD_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/AMD_UserGuide.pdf
-%%PORTDOCS%%%%DOCSDIR%%/BTF_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/CAMD_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/CAMD_UserGuide.pdf
-%%PORTDOCS%%%%DOCSDIR%%/CCOLAMD_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/CHOLMOD_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/CHOLMOD_UserGuide.pdf
-%%PORTDOCS%%%%DOCSDIR%%/COLAMD_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/CXSPARSE_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/KLU_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/KLU_UserGuide.pdf
-%%PORTDOCS%%%%DOCSDIR%%/LDL_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/RBIO_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/SLIP_LU_README.md
-%%PORTDOCS%%%%DOCSDIR%%/SLIP_LU_UserGuide.pdf
-%%PORTDOCS%%%%DOCSDIR%%/SPQR_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/SUITESPARSECONFIG_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/SuiteSparse_README.md
-%%PORTDOCS%%%%DOCSDIR%%/UMFPACK_QuickStart.pdf
-%%PORTDOCS%%%%DOCSDIR%%/UMFPACK_README.txt
-%%PORTDOCS%%%%DOCSDIR%%/UMFPACK_UserGuide.pdf
-%%PORTDOCS%%%%DOCSDIR%%/ldl_userguide.pdf
-%%PORTDOCS%%%%DOCSDIR%%/spqr_user_guide.pdf