blob: 3e74a9896d1197a67e7510c9884b07bd0681628e (
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
|
# Maintainer: Andrea Manenti <andrea [dot] manenti [at] yahoo [dot] com>
pkgname=sdpb-git
pkgver=2016.6418959a
pkgrel=1
pkgdesc="A semidefinite program solver for the conformal bootstrap"
arch=(x86_64)
license=('MIT')
url="https://github.com/davidsd/sdpb"
depends=('boost' 'libarchive' 'libxml2' 'mpfr' 'rapidjson' 'elemental-gmp-git' 'intel-oneapi-mkl' 'flint')
optdepends=('openmpi')
makedepends=('git' 'python')
source=('git+https://github.com/davidsd/sdpb.git')
sha256sums=('SKIP')
pkgver() {
cd "$srcdir"/sdpb
echo `git rev-list --count master`.`git rev-parse --short master`
}
build () {
cd "$srcdir"/sdpb
# 'U' read mode was deprecated in python 3.11
# This is a workaround
python waf configure --prefix=/usr 1>&2 2> /dev/null || true # is going to fail but it generates the scripts
sed -i -e "s/'rU'/'r'/g" .waf*/waflib/Context.py
python waf configure --prefix=/usr
# We need to do this one more time
sed -i -e "s/'rU'/'r'/g" .waf*/waflib/ConfigSet.py
python waf
}
package() {
cd "$srcdir"/sdpb/build
for bin_name in pmp2functions spectrum pmp2sdp sdp2input sdpb approx_objective outer_limits pvm2sdp
do
install -vDm 755 "$bin_name" "$pkgdir"/usr/bin/"$bin_name"
done
}
check () {
cd "$srcdir"/sdpb/test
/usr/bin/sh run_all_tests.sh
}
|