blob: 3ed223977b4d8a66682b97ddfbf44b4f0ca5dbf2 (
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
|
# Maintainer: Thomas Dziedzic < gostrc at gmail >
# Contributor: Klimov Max <cleemmi@gmail.com>
pkgname=libcgns
_basever=3.1.3
_relver=3
pkgver=${_basever}.${_relver}
pkgrel=2
pkgdesc='General purpose library for the storage and retrieval of computational fluid dynamics analysis data by CGNS standard'
arch=('i686' 'x86_64')
url='http://www.cgns.org'
license=('custom')
conflicts=('libcgns2')
makedepends=('cmake')
source=("http://downloads.sourceforge.net/project/cgns/cgnslib_${_basever:0:3}/cgnslib_${_basever}-${_relver}.tar.gz")
md5sums=('8d19e0c69779d7ea74b1731e09a96b9d')
# need to tell cmake when to build 64bit version
[[ "$CARCH" == "i686" ]] && _64bits=OFF
[[ "$CARCH" == "x86_64" ]] && _64bits=ON
build() {
mkdir build
cd build
cmake \
-DCMAKE_INSTALL_PREFIX:PATH=/usr \
-DCMAKE_SKIP_RPATH:BOOL=ON \
-DENABLE_64BIT:BOOL=${_64bits} \
-DENABLE_TESTS:BOOL=ON \
../cgnslib_${_basever}
make
}
check() {
cd build
make test
}
package() {
cd build
make DESTDIR=${pkgdir} install
# install license
install -d ${pkgdir}/usr/share/licenses/libcgns
install -m644 ${srcdir}/cgnslib_${_basever}/license.txt \
${pkgdir}/usr/share/licenses/libcgns
}
|