| 1 |
#!/bin/sh |
| 2 |
|
| 3 |
# Run upstream testsuite for BLAS and CBLAS |
| 4 |
|
| 5 |
set -e |
| 6 |
|
| 7 |
if [ $(dpkg-architecture -qDEB_HOST_ARCH_BITS) != 64 ]; then |
| 8 |
echo "$(basename $0): test only supported on 64bit" |
| 9 |
exit 77 |
| 10 |
fi |
| 11 |
|
| 12 |
DEB_HOST_MULTIARCH=$(dpkg-architecture -q DEB_HOST_MULTIARCH) |
| 13 |
|
| 14 |
# Enforce the BLAS contained in package libblas64-3 |
| 15 |
export LD_LIBRARY_PATH=/usr/lib/${DEB_HOST_MULTIARCH}/blas64 |
| 16 |
|
| 17 |
PATH=/usr/lib/${DEB_HOST_MULTIARCH}/blas64:$PATH |
| 18 |
|
| 19 |
DATADIR=/usr/lib/${DEB_HOST_MULTIARCH}/blas64 |
| 20 |
|
| 21 |
cd "$AUTOPKGTEST_TMP" |
| 22 |
|
| 23 |
# Test Fortran BLAS |
| 24 |
for p in s d c z |
| 25 |
do |
| 26 |
xblat1${p} > ${p}blat1.out |
| 27 |
xblat2${p} < $DATADIR/${p}blat2.in |
| 28 |
xblat3${p} < $DATADIR/${p}blat3.in |
| 29 |
done |
| 30 |
|
| 31 |
# Test CBLAS |
| 32 |
for p in s d c z |
| 33 |
do |
| 34 |
x${p}cblat1 > ${p}test1.out |
| 35 |
x${p}cblat2 < $DATADIR/${p}in2 > ${p}test2.out |
| 36 |
x${p}cblat3 < $DATADIR/${p}in3 > ${p}test3.out |
| 37 |
done |
| 38 |
|
| 39 |
! grep -q -i fail *.out |