blob: 9f5d8320d6f4cb1ae32036266d5d98d21d0dee77 (
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
|
#!/bin/hint/bash
# Maintainer : bartus <arch-user-repoᘓbartus.33mail.com>
# prev-Maintainer: Raimar Sandner <raimar.sandner@uibk.ac.at>
pkgname=cppqed-git
pkgver=2.100.3
pkgrel=1
pkgdesc="Highly flexible framework for simulating open quantum dynamics."
arch=(i686 x86_64)
url=http://cppqed.sourceforge.net
license=(custom)
depends=(boost-libs blitz flens python python-numpy python-scipy gsl)
makedepends=(git cmake ninja clang boost)
provides=(cppqed)
conflicts=(cppqed)
source=("${pkgname}"::git+https://github.com/vukics/cppqed
"blitz-cppqed::git+https://github.com/vukics/blitz"
"pcg-cpp::git+https://github.com/vukics/pcg-cpp"
"Xoshiro-cpp::git+https://github.com/vukics/Xoshiro-cpp")
sha256sums=('SKIP'
'SKIP'
'SKIP'
'SKIP')
prepare() {
git -C "${srcdir}/${pkgname}" config submodule.blitz.url "${srcdir}"/blitz-cppqed
git -C "${srcdir}/${pkgname}" config submodule.CPPQEDutils/thirdPartyRandom/pcg-cpp.url "${srcdir}"/pcg-cpp
git -C "${srcdir}/${pkgname}" config submodule.CPPQEDutils/thirdPartyRandom/Xoshiro-cpp.url "${srcdir}"/Xoshiro-cpp
git -C "${srcdir}/${pkgname}" submodule update --init --recursive --remote
}
pkgver() {
cd "${pkgname}"
echo "$(git describe --tags | sed 's|-|_|g')"
}
build() {
CXXFLAGS+=" -DBOOST_BIND_GLOBAL_PLACEHOLDERS -std=c++17"
CFLAGS+=" -DBOOST_BIND_GLOBAL_PLACEHOLDERS"
cmake \
-S "${srcdir}/${pkgname}" \
-B build \
-G Ninja \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER=clang \
-DCMAKE_CXX_COMPILER=clang++
# shellcheck disable=SC2086 # expand multiple flags passed in MAKEFLAGS
ninja -C build ${MAKEFLAGS:--j1}
}
package() {
DESTDIR="${pkgdir}" ninja -C build install
install -Dm644 "${srcdir}"/${pkgname}/LICENSE.txt "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}
# vim:set ts=2 sw=2 et:
|