summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaximilian Stahlberg2021-02-06 15:13:40 +0100
committerMaximilian Stahlberg2021-02-06 15:13:40 +0100
commit1291cd5c5bf2c103446fda2295005b879515d969 (patch)
treefd7bf0748336d515a9cd7526fc8db0d49527cab3
parentd7201a025c2b20f4cae273f5fc2b5bd3b870cc2b (diff)
downloadaur-1291cd5c5bf2c103446fda2295005b879515d969.tar.gz
Make check() more robust.
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD8
2 files changed, 6 insertions, 4 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 802c85592fc..832075541b5 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = python-swiglpk
pkgdesc = A Python interface to the GLPK optimization solver.
pkgver = 4.65.1
- pkgrel = 4
+ pkgrel = 5
url = https://github.com/biosustain/swiglpk
arch = any
license = GPL3
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
}
-