blob: 74f654206f62fd8af9741dcb97892f9466b1347d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
# Maintainer: Luke Labrie-Cleary <luke dot cleary at copenhagenatomics dot com>
pkgname=moab-git
pkgver=5.5.1.r643.g84f4f69e0
pkgrel=1
pkgdesc="The Mesh-Oriented datABase MOAB is a component for representing and evaluating mesh data"
arch=('x86_64')
url="https://bitbucket.org/fathomteam/moab"
license=('GPL3')
depends=(
python-numpy
blas
lapack
cython
hdf5-openmpi
openmpi
)
makedepends=(
git
eigen
netcdf
"glibc>=2.34"
cmake
patch
)
provides=('moab')
source=("${pkgname}::git+${url}.git")
pkgver() {
cd $srcdir/${pkgname}
git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}
conflicts=('moab')
md5sums=('SKIP')
build() {
cd $srcdir
mkdir build && cd build
cmake ../$pkgname -DENABLE_HDF5=ON \
-DENABLE_NETCDF=ON \
-DENABLE_FORTRAN=OFF \
-DENABLE_BLASLAPACK=OFF \
-DBUILD_SHARED_LIBS=ON \
-DCMAKE_INSTALL_PREFIX=/opt/MOAB \
-DHDF5_ROOT=/usr \
-DENABLE_MPI=ON \
-DMPI_C_COMPILER=mpicc \
-DMPI_CXX_COMPILER=mpicxx
_ccores=$(nproc)
# check if _ccores is a positive integer, if not, serial build
if [[ "${_ccores}" =~ ^[1-9][0-9]*$ ]]; then
make -j ${_ccores}
else
make
fi
}
package() {
cd $srcdir/build
make DESTDIR="$pkgdir/" install
}
|