aboutsummaryrefslogtreecommitdiffstats
path: root/community/suitesparse/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'community/suitesparse/APKBUILD')
-rw-r--r--community/suitesparse/APKBUILD84
1 files changed, 47 insertions, 37 deletions
diff --git a/community/suitesparse/APKBUILD b/community/suitesparse/APKBUILD
index 9e697ffc988..d8e3af389fa 100644
--- a/community/suitesparse/APKBUILD
+++ b/community/suitesparse/APKBUILD
@@ -2,54 +2,64 @@
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=suitesparse
_pkgname=SuiteSparse
-pkgver=5.6.0
-pkgrel=2
+pkgver=7.3.1
+pkgrel=0
pkgdesc="A collection of sparse matrix libraries"
url="http://faculty.cse.tamu.edu/davis/suitesparse.html"
arch="all"
-license="GPL-3.0-only"
-depends_dev="lapack-dev"
-makedepends="$depends_dev cmake m4"
-subpackages="$pkgname-dev $pkgname-doc"
-source="$pkgname-$pkgver.tar.gz::https://github.com/DrTimothyAldenDavis/SuiteSparse/archive/v$pkgver.tar.gz
- 0001-exclude-metis.patch
- 0002-remove-rpath.patch
+license="BSD-3-Clause AND LGPL-2.1-or-later AND GPL-2.0-or-later"
+depends_dev="
+ gmp-dev
+ mpfr-dev
+ openblas-dev
+ "
+makedepends="
+ $depends_dev
+ cmake
+ m4
+ "
+subpackages="
+ $pkgname-static
+ $pkgname-dev
+ $pkgname-graphblas
+ "
+source="https://github.com/DrTimothyAldenDavis/SuiteSparse/archive/v$pkgver/$_pkgname-$pkgver.tar.gz
+ remove-rpath.patch
"
builddir="$srcdir/$_pkgname-$pkgver"
-case "$CARCH" in
- mips*)
- makedepends="$makedepends blas-dev"
- _blas='BLAS=-lblas'
- ;;
- *)
- makedepends="$makedepends openblas-dev"
- ;;
-esac
-
-prepare() {
- # Do not include the Partition module and METIS (it's optional and
- # Julia doesn't need it).
- export CFLAGS="$CFLAGS -DNPARTITION"
- rm -r metis-*
+_flags="BLAS=-lopenblas LAPACK=-lopenblas"
- default_prepare
-}
+# Do not include the Partition module (it's optional and Julia doesn't need it).
+# Do not try to override optimization level. SuiteSparse is a huge library
+# heavily optimized for performance, so compiling with -Os doesn't make sense.
+# Actually, the build scripts currently override -Os with -O3 anyway,
+# but better to not rely on it.
+export CFLAGS="${CFLAGS/-Os/} -DNPARTITION"
+export CPPFLAGS=${CPPFLAGS/-Os/}
+export CXXFLAGS=${CXXFLAGS/-Os/}
build() {
- make library $_blas \
- CMAKE_OPTIONS="-DCMAKE_INSTALL_LIBDIR=$pkgdir/usr/lib \
- -DCMAKE_INSTALL_INCLUDEDIR=$pkgdir/usr/include"
+ make library $_flags CMAKE_OPTIONS="\
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_INSTALL_INCLUDEDIR=/usr/include/suitesparse \
+ -DCMAKE_INSTALL_LIBDIR=/usr/lib \
+ -DCMAKE_VERBOSE_MAKEFILE=ON \
+ "
}
package() {
- make install $_blas \
- INSTALL="$pkgdir"/usr \
- INSTALL_INCLUDE="$pkgdir"/usr/include/"$pkgname" \
- INSTALL_DOC="$pkgdir"/usr/share/doc/"$pkgname" \
- INSTALL_LIB="$pkgdir"/usr/lib
+ make install $_flags DESTDIR="$pkgdir"
+}
+
+graphblas() {
+ pkgdesc="Graph algorithms in the language of linear algebra"
+ license="Apache-2.0 AND GPL-3.0-or-later"
+
+ amove usr/lib/libgraphblas.so.*
}
-sha512sums="c4dac62710501388fd58e52fe239723f83a94ff666410f711d42710485730d2821d3bb0ad937b40ac1a257e6da2ed317e30d74592b16ac3f959295965314d6dc suitesparse-5.6.0.tar.gz
-0bdaed29c7770104eb94d9e60a42fe68b5643c8f958aba4cc6d7996888a83ae75a4e509d0c262264c49d5d9b1ca23a958cc71cfaa5e983b0008e65455a987cac 0001-exclude-metis.patch
-cd40b696515b26c95298b435a5111e582dc42c2fa2e8ef9889558467d375b1d19452838b9463df66958e73ddb0c8c0191936e3e952586a3c7d345edb08fa7e62 0002-remove-rpath.patch"
+sha512sums="
+681d64349360246aaebea3246a87a7415c3528b4cde4aef6def3988e19087d7184ce1bf1fad0f80f7ea312d59f6f207dc2195f6be100871c5714115705c243f6 SuiteSparse-7.3.1.tar.gz
+79886862a6edfcec8462ccb973ced03aa09968166c317964f107f43222b3b6be8e21aadb4c242696f4b2e1c34f2403c4bdd6d006c6aecc3b84128ba13d079a08 remove-rpath.patch
+"