summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorMaximilian Stahlberg2021-02-06 15:13:40 +0100
committerMaximilian Stahlberg2021-02-06 15:13:40 +0100
commit1291cd5c5bf2c103446fda2295005b879515d969 (patch)
treefd7bf0748336d515a9cd7526fc8db0d49527cab3 /PKGBUILD
parentd7201a025c2b20f4cae273f5fc2b5bd3b870cc2b (diff)
downloadaur-1291cd5c5bf2c103446fda2295005b879515d969.tar.gz
Make check() more robust.
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD8
1 files changed, 5 insertions, 3 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 190f84acab1..deee28b7ef5 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=python-swiglpk
pkgver=4.65.1
-pkgrel=4
+pkgrel=5
pkgdesc='A Python interface to the GLPK optimization solver.'
arch=('any')
url='https://github.com/biosustain/swiglpk'
@@ -26,7 +26,10 @@ build() {
}
check() {
- cd "${srcdir}/swiglpk-${pkgver}/build/lib."*
+ _arch="linux-$(uname -m)"
+ _pymajver="$(python -V | awk '{print $2}' | awk -F. '{print $1"."$2}')"
+
+ cd "${srcdir}/swiglpk-${pkgver}/build/lib.${_arch}-${_pymajver}"
python -Bc "import swiglpk"
}
@@ -34,4 +37,3 @@ package() {
cd "${srcdir}/swiglpk-${pkgver}"
python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
}
-