Accepting request 1067465 from home:eeich:branches:science
- Set -ffloat-store for the entire build on ix86 platforms. This helps to avoid effects from excess precision that can be seen in the test suite. OBS-URL: https://build.opensuse.org/request/show/1067465 OBS-URL: https://build.opensuse.org/package/show/science/lapack?expand=0&rev=37
This commit is contained in:
parent
f6607ec703
commit
d6eca87945
@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Feb 23 16:58:25 UTC 2023 - Egbert Eich <eich@suse.com>
|
||||||
|
|
||||||
|
- Set -ffloat-store for the entire build on ix86 platforms.
|
||||||
|
This helps to avoid effects from excess precision that
|
||||||
|
can be seen in the test suite.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Feb 15 08:51:06 UTC 2023 - Egbert Eich <eich@suse.com>
|
Wed Feb 15 08:51:06 UTC 2023 - Egbert Eich <eich@suse.com>
|
||||||
|
|
||||||
|
29
lapack.spec
29
lapack.spec
@ -213,6 +213,10 @@ The cblas-devel-static package contains the CBLAS static libraries
|
|||||||
for -static linking. You do not need these, unless you link
|
for -static linking. You do not need these, unless you link
|
||||||
statically, which is highly discouraged.
|
statically, which is highly discouraged.
|
||||||
|
|
||||||
|
%ifarch %{ix86}
|
||||||
|
%global precflags "-ffloat-store"
|
||||||
|
%endif
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%autopatch -p1
|
%autopatch -p1
|
||||||
@ -221,9 +225,6 @@ sed -i -e '1 s@env python@python3@' lapack_testing.py
|
|||||||
%build
|
%build
|
||||||
%global _lto_cflags %{_lto_cflags} -ffat-lto-objects
|
%global _lto_cflags %{_lto_cflags} -ffat-lto-objects
|
||||||
%global optflags_f %{optflags}
|
%global optflags_f %{optflags}
|
||||||
%ifarch %{ix86}
|
|
||||||
%global test_precflags "-ffloat-store"
|
|
||||||
%endif
|
|
||||||
|
|
||||||
cp make.inc.example make.inc
|
cp make.inc.example make.inc
|
||||||
# for ABI compatibility we need to build the deprecated interfaces
|
# for ABI compatibility we need to build the deprecated interfaces
|
||||||
@ -232,7 +233,7 @@ echo 'BUILD_DEPRECATED = Yes' >> make.inc
|
|||||||
|
|
||||||
%make_build cleanlib
|
%make_build cleanlib
|
||||||
%make_build blaslib \
|
%make_build blaslib \
|
||||||
FFLAGS="%{optflags_f} -fPIC"
|
FFLAGS="%{optflags_f} %{?precflags} -fPIC"
|
||||||
mkdir tmp
|
mkdir tmp
|
||||||
( cd tmp; ar x ../librefblas.a )
|
( cd tmp; ar x ../librefblas.a )
|
||||||
gfortran -shared -Wl,-soname=libblas.so.3 -o libblas.so.%{version} -Wl,--no-undefined tmp/*.o
|
gfortran -shared -Wl,-soname=libblas.so.3 -o libblas.so.%{version} -Wl,--no-undefined tmp/*.o
|
||||||
@ -240,7 +241,7 @@ ln -s libblas.so.%{version} libblas.so
|
|||||||
rm -rf tmp
|
rm -rf tmp
|
||||||
|
|
||||||
%make_build cblaslib \
|
%make_build cblaslib \
|
||||||
CFLAGS="%{optflags} -fPIC -DADD_ "
|
CFLAGS="%{optflags} %{?precflags} -fPIC -DADD_ "
|
||||||
mkdir tmp
|
mkdir tmp
|
||||||
( cd tmp; ar x ../libcblas.a )
|
( cd tmp; ar x ../libcblas.a )
|
||||||
gfortran -shared -Wl,-soname=libcblas.so.3 -o libcblas.so.%{version} -Wl,--no-undefined tmp/*.o -L. -lblas
|
gfortran -shared -Wl,-soname=libcblas.so.3 -o libcblas.so.%{version} -Wl,--no-undefined tmp/*.o -L. -lblas
|
||||||
@ -248,10 +249,10 @@ ln -s libcblas.so.%{version} libcblas.so
|
|||||||
rm -rf tmp
|
rm -rf tmp
|
||||||
|
|
||||||
# May need to be included in liblapack
|
# May need to be included in liblapack
|
||||||
%make_build -C TESTING/MATGEN FFLAGS="%{optflags_f} %{?test_precflags} %{?with_tmg:-fPIC}"
|
%make_build -C TESTING/MATGEN FFLAGS="%{optflags_f} %{?precflags} %{?with_tmg:-fPIC}"
|
||||||
|
|
||||||
%make_build lapacklib \
|
%make_build lapacklib \
|
||||||
FFLAGS="%{optflags_f} -fPIC"
|
FFLAGS="%{optflags_f} %{?precflags} -fPIC"
|
||||||
mkdir tmp
|
mkdir tmp
|
||||||
( cd tmp; ar x ../liblapack.a; %{?with_tmg: ar x ../libtmglib.a; ar cr ../liblapack.a *.o; ranlib ../liblapack.a })
|
( cd tmp; ar x ../liblapack.a; %{?with_tmg: ar x ../libtmglib.a; ar cr ../liblapack.a *.o; ranlib ../liblapack.a })
|
||||||
gfortran -shared -Wl,-soname=liblapack.so.3 -o liblapack.so.%{version} -Wl,--no-undefined tmp/*.o -L. -lblas
|
gfortran -shared -Wl,-soname=liblapack.so.3 -o liblapack.so.%{version} -Wl,--no-undefined tmp/*.o -L. -lblas
|
||||||
@ -259,7 +260,7 @@ ln -s liblapack.so.%{version} liblapack.so
|
|||||||
rm -rf tmp
|
rm -rf tmp
|
||||||
|
|
||||||
make %{?_smp_mflags} lapackelib \
|
make %{?_smp_mflags} lapackelib \
|
||||||
CFLAGS="%{optflags} -fPIC -DADD_ -DHAVE_LAPACK_CONFIG_H -DLAPACK_COMPLEX_STRUCTURE"
|
CFLAGS="%{optflags} %{?precflags} -fPIC -DADD_ -DHAVE_LAPACK_CONFIG_H -DLAPACK_COMPLEX_STRUCTURE"
|
||||||
mkdir tmp
|
mkdir tmp
|
||||||
( cd tmp; ar x ../liblapacke.a )
|
( cd tmp; ar x ../liblapacke.a )
|
||||||
gfortran -shared -Wl,-soname=liblapacke.so.3 -o liblapacke.so.%{version} -Wl,--no-undefined tmp/*.o -L. -llapack
|
gfortran -shared -Wl,-soname=liblapacke.so.3 -o liblapacke.so.%{version} -Wl,--no-undefined tmp/*.o -L. -llapack
|
||||||
@ -267,12 +268,12 @@ ln -s liblapacke.so.%{version} liblapacke.so
|
|||||||
rm -rf tmp
|
rm -rf tmp
|
||||||
|
|
||||||
# Build test binaries - blas
|
# Build test binaries - blas
|
||||||
%make_build -C BLAS/TESTING FFLAGS="%{optflags_f} %{?test_precflags}"
|
%make_build -C BLAS/TESTING FFLAGS="%{optflags_f} %{?precflags}"
|
||||||
# Build test binaries - cblas
|
# Build test binaries - cblas
|
||||||
%make_build -C CBLAS/testing FFLAGS="%{optflags_f} %{?test_precflags}"
|
%make_build -C CBLAS/testing FFLAGS="%{optflags_f} %{?precflags}"
|
||||||
# Build test binaries - lapack
|
# Build test binaries - lapack
|
||||||
%make_build -C TESTING/LIN FFLAGS="%{optflags_f} %{?test_precflags}"
|
%make_build -C TESTING/LIN FFLAGS="%{optflags_f} %{?precflags}"
|
||||||
%make_build -C TESTING/EIG FFLAGS="%{optflags_f} %{?test_precflags}"
|
%make_build -C TESTING/EIG FFLAGS="%{optflags_f} %{?precflags}"
|
||||||
|
|
||||||
%check
|
%check
|
||||||
# Increase stack size, required for xeigtstz, see
|
# Increase stack size, required for xeigtstz, see
|
||||||
@ -280,7 +281,7 @@ rm -rf tmp
|
|||||||
# Remove for lapack > 3.9
|
# Remove for lapack > 3.9
|
||||||
ulimit -s 16384
|
ulimit -s 16384
|
||||||
|
|
||||||
%make_build blas_testing FFLAGS="%{optflags_f} %{?test_precflags}"
|
%make_build blas_testing FFLAGS="%{optflags_f} %{?precflags}"
|
||||||
if grep -B15 -A15 FAIL BLAS/TESTING/*.out; then
|
if grep -B15 -A15 FAIL BLAS/TESTING/*.out; then
|
||||||
echo
|
echo
|
||||||
echo "blas_testing FAILED"
|
echo "blas_testing FAILED"
|
||||||
@ -290,7 +291,7 @@ fi
|
|||||||
%make_build cblas_testing CFLAGS="%{optflags} -fPIC"
|
%make_build cblas_testing CFLAGS="%{optflags} -fPIC"
|
||||||
grep -B15 -A15 FAIL CBLAS/testing/*.out && false
|
grep -B15 -A15 FAIL CBLAS/testing/*.out && false
|
||||||
|
|
||||||
%make_build lapack_testing FFLAGS="%{optflags_f} %{?test_precflags}"
|
%make_build lapack_testing FFLAGS="%{optflags_f} %{?precflags}"
|
||||||
if grep -B15 -A15 FAIL TESTING/*.out; then
|
if grep -B15 -A15 FAIL TESTING/*.out; then
|
||||||
echo
|
echo
|
||||||
echo "lapack_testing FAILED"
|
echo "lapack_testing FAILED"
|
||||||
|
Loading…
Reference in New Issue
Block a user