summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Diehl2021-04-22 07:30:00 +0200
committerMartin Diehl2021-04-22 07:30:00 +0200
commit55b36a78c25bea75692c79d71c5e2bcd4f99bc7b (patch)
tree2b64cc5ed69d46061702043d911d2f2a813605a6
parent73b3423ea4465a07f6558b7bd128db13cf015a6a (diff)
downloadaur-55b36a78c25bea75692c79d71c5e2bcd4f99bc7b.tar.gz
build shared libraries
thanks to eDgar for the fixes
-rw-r--r--.SRCINFO9
-rw-r--r--Makefile.inc12
-rw-r--r--PKGBUILD56
3 files changed, 46 insertions, 31 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 7328c45c9d08..d548443fa714 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = mumps
pkgdesc = Sparse solver library using Gaussian elimination
pkgver = 5.3.5
- pkgrel = 1
+ pkgrel = 2
url = http://mumps.enseeiht.fr
arch = i686
arch = x86_64
@@ -11,16 +11,15 @@ pkgbase = mumps
depends = openmpi
depends = scotch
depends = scalapack
- depends = parmetis
+ depends = metis
depends = zlib
depends = bzip2
- provides = mumps
conflicts = mumps-par
conflicts = mumps4
source = http://mumps.enseeiht.fr/MUMPS_5.3.5.tar.gz
source = Makefile.inc
- sha256sums = e5d665fdb7043043f0799ae3dbe3b37e5b200d1ab7a6f7b2a4e463fd89507fa4
- sha256sums = 507c99dacf4e25d72ed9f47aac95bfa28f0ad846bf4698cad005b1cb16e9444c
+ sha512sums = 6e3bb081f38af8540ada7b4fb54c6e766739c854e2a3dd253e3e012eee05dae30064b1b4a8d7493f10691725aba4cc9e80544b0fe5b71670cb0b2726ccfc4439
+ sha512sums = 578813e63588a16d26c3c9c88db475e8d981bfe755bf1fd584866cdcb23cb0388b2dfc2c9a58c68f7786a1574beeb8f0a104dc999df666dfd320694e673a1cb7
pkgname = mumps
diff --git a/Makefile.inc b/Makefile.inc
index 7cd8c3b3a50e..57735b552a44 100644
--- a/Makefile.inc
+++ b/Makefile.inc
@@ -91,7 +91,7 @@ IORDERINGSC = $(IMETIS) $(IPORD) $(ISCOTCH)
PLAT =
# Library extension, + C and Fortran "-o" option
# may be different under Windows
-LIBEXT = .a
+LIBEXT = .so
OUTC = -o
OUTF = -o
# RM : remove files
@@ -104,11 +104,11 @@ FC = mpif90
FL = mpif90
# AR : Archive object in a library
# keep a space at the end if options have to be separated from lib name
-AR = ar vr
+AR = $(CC) -shared $(OPTC) -o
# RANLIB : generate index of an archive file
# (optionnal use "RANLIB = echo" in case of problem)
-RANLIB = ranlib
-#RANLIB = echo
+# RANLIB = ranlib
+RANLIB = echo
# DEFINE HERE YOUR LAPACK LIBRARY
@@ -159,10 +159,10 @@ OPTL = ${CFLAGS} -fPIC
#Sequential:
#INCS = $(INCSEQ)
#LIBS = $(LIBSEQ)
-LIBSEQNEEDED = libseqneeded
+#LIBSEQNEEDED = libseqneeded
#Parallel:
INCS = $(INCPAR)
LIBS = $(LIBPAR)
-#LIBSEQNEEDED =
+LIBSEQNEEDED =
diff --git a/PKGBUILD b/PKGBUILD
index 497dbb440d09..b192ec132b7a 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,53 +1,69 @@
# Maintainer: Martin Diehl <aur@martin-diehl.net>
+# Contributor: eDgar <eDgar |at| openmail.cc >
# Contributor: Michele Mocciola <mickele>
# Contributor: Guillaume Dollé < dolle dot guillaume at gmail dot com >
# Contributor: Lucas H. Gabrielli
pkgname=mumps
pkgver=5.3.5
-pkgrel=1
+pkgrel=2
pkgdesc='Sparse solver library using Gaussian elimination'
url='http://mumps.enseeiht.fr'
license=('custom')
-depends=('lapack' 'openmpi' 'scotch' 'scalapack' 'parmetis' 'zlib' 'bzip2')
+depends=('lapack' 'openmpi' 'scotch' 'scalapack' 'metis' 'zlib' 'bzip2')
makedepends=('gcc-fortran')
-provides=('mumps')
conflicts=('mumps-par' 'mumps4')
-replaces=()
-backup=()
arch=('i686' 'x86_64')
source=(http://mumps.enseeiht.fr/MUMPS_${pkgver}.tar.gz
Makefile.inc)
-sha256sums=('e5d665fdb7043043f0799ae3dbe3b37e5b200d1ab7a6f7b2a4e463fd89507fa4'
- '507c99dacf4e25d72ed9f47aac95bfa28f0ad846bf4698cad005b1cb16e9444c')
-build() {
+sha512sums=('6e3bb081f38af8540ada7b4fb54c6e766739c854e2a3dd253e3e012eee05dae30064b1b4a8d7493f10691725aba4cc9e80544b0fe5b71670cb0b2726ccfc4439'
+ '578813e63588a16d26c3c9c88db475e8d981bfe755bf1fd584866cdcb23cb0388b2dfc2c9a58c68f7786a1574beeb8f0a104dc999df666dfd320694e673a1cb7')
+
+prepare () {
cd "${srcdir}/MUMPS_${pkgver}"
cp "${srcdir}/Makefile.inc" .
+}
+
+build() {
+ cd "${srcdir}/MUMPS_${pkgver}"
+ make alllib
+}
- make -j1 LIBSEQNEEDED='' alllib || return 1
+check () {
+ cd "${srcdir}/MUMPS_${pkgver}/examples"
+ make all
+ # From the README (in examples)
+ MPIRUN="mpirun -np 3 --mca opal_warn_on_missing_libcuda 0 --oversubscribe"
+ export LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:${srcdir}/MUMPS_${pkgver}/lib"
+ ${MPIRUN} ./ssimpletest < input_simpletest_real
+ ${MPIRUN} ./dsimpletest < input_simpletest_real
+ ${MPIRUN} ./csimpletest < input_simpletest_cmplx
+ ${MPIRUN} ./zsimpletest < input_simpletest_cmplx
+ ${MPIRUN} ./c_example
+ ${MPIRUN} ./multiple_arithmetics_example
+ ${MPIRUN} ./ssimpletest_save_restore < input_simpletest_real
+ ${MPIRUN} ./dsimpletest_save_restore < input_simpletest_real
+ ${MPIRUN} ./csimpletest_save_restore < input_simpletest_cmplx
+ ${MPIRUN} ./zsimpletest_save_restore < input_simpletest_cmplx
+ ${MPIRUN} ./c_example_save_restore
}
package(){
# Install all headers
cd "${srcdir}/MUMPS_${pkgver}/include"
- install -m 755 -d "${pkgdir}/usr/include"
+ install -d -m755 "${pkgdir}/usr/include"
install -D -m644 *.h "${pkgdir}/usr/include"
# Install all libraries
- cd "${srcdir}/MUMPS_${pkgver}/lib" || return 1
- install -m 755 -d "${pkgdir}/usr/lib" || return 1
- install -D -m644 lib*.a ${pkgdir}/usr/lib || return 1
- for _FILE in `ls *.a | sed "s|\.a||"`; do
- ld -Bshareable -o ${_FILE}.so.${pkgver} -x -soname ${_FILE}.so --whole-archive ${_FILE}.a
- install -m 644 -D ${_FILE}.a ${pkgdir}/usr/lib/${_FILE}.a
- install -m 755 ${_FILE}.so.${pkgver} ${pkgdir}/usr/lib
- ln -sf ${_FILE}.so.${pkgver} ${pkgdir}/usr/lib/${_FILE}.so.${pkgver:0:1}
- ln -sf ${_FILE}.so.${pkgver} ${pkgdir}/usr/lib/${_FILE}.so
- done
+ cd "${srcdir}/MUMPS_${pkgver}/lib"
+ install -d -m755 ${pkgdir}/usr/lib
+ install -D -m644 *.so ${pkgdir}/usr/lib
# Install examples
install -m 755 -d "${pkgdir}/usr/share/doc/${pkgname}/examples"
cd "${srcdir}/MUMPS_${pkgver}/examples"
install -m 644 * "${pkgdir}/usr/share/doc/${pkgname}/examples"
+ install -m 644 "${srcdir}/MUMPS_${pkgver}/Makefile.inc" "${pkgdir}/usr/share/doc/${pkgname}/examples"
+ sed -i 's_\(topdir =\).*_\1 /usr_g; s-.*\(Makefile.inc\)-include Makefile.inc-g' "${pkgdir}/usr/share/doc/${pkgname}/examples/Makefile"
# Install license
install -D -m644 "${srcdir}/MUMPS_${pkgver}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"