Commit f050f0ec authored by Timo Teräs's avatar Timo Teräs
Browse files

testing/openblas: fix build on arm

parent d5c182e6
...@@ -25,21 +25,27 @@ prepare() { ...@@ -25,21 +25,27 @@ prepare() {
done done
} }
# DYNAMIC_ARCH: supported on x86* only, see https://github.com/xianyi/OpenBLAS/issues/709
case "$CARCH" in
x86 | x86_64) DYNAMIC_ARCH=1 ;;
*) DYNAMIC_ARCH=0 ;;
esac
# USE_OPENMP=0: see GCC bug 60035
# NO_AFFINITY: don't expect to work on musl, also breaks R
FLAGS="USE_OPENMP=0 NO_LAPACK=0 NUM_THREADS=8 MAJOR_VERSION=3 \
NO_AFFINITY=1 DYNAMIC_ARCH=$DYNAMIC_ARCH"
build() { build() {
cd "$_builddir" cd "$_builddir"
#USE_OPENMP=0: see GCC bug 60035 make $FLAGS PREFIX=/usr || return 1
#NO_AFFINITY: don't expect to work on musl, also breaks R
#DYNAMIC_ARCH=1 requires 00-cpuid.patch
make USE_OPENMP=0 NO_LAPACK=0 NUM_THREADS=8 MAJOR_VERSION=3 \
NO_AFFINITY=1 DYNAMIC_ARCH=1 PREFIX=/usr || return 1
} }
package() { package() {
cd "$_builddir" cd "$_builddir"
mkdir -pm 0755 "$pkgdir/usr/lib" "$pkgdir/usr/include" \ mkdir -pm 0755 "$pkgdir/usr/lib" "$pkgdir/usr/include" \
"$pkgdir/usr/share/doc/$pkgname" || return 1 "$pkgdir/usr/share/doc/$pkgname" || return 1
make USE_OPENMP=0 NO_LAPACK=0 NUM_THREADS=2 MAJOR_VERSION=3 \ make $FLAGS PREFIX="$pkgdir/usr" install || return 1
NO_AFFINITY=1 DYNAMIC_ARCH=1 PREFIX="$pkgdir/usr" install || return 1
for FILE in *.txt *.md LICENSE; do for FILE in *.txt *.md LICENSE; do
install -m 0644 $FILE "$pkgdir/usr/share/doc/$pkgname" || return 1 install -m 0644 $FILE "$pkgdir/usr/share/doc/$pkgname" || return 1
done done
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment