From e0db7e60c0c6059a907ea77822ba735a993d7101 Mon Sep 17 00:00:00 2001 From: Karolina Surma Date: Mar 10 2022 08:17:49 +0000 Subject: Build numpy using Python's standard library distutils We patch Python's distutils to exclude the standard paths from rpaths. setuptools 60+ switches to its own copy of distutils by default, which doesn't contain the patch and leads to the failed RPM build. This behavior is overriden with the environment variable SETUPTOOLS_USE_DISTUTILS=stdlib. --- diff --git a/numpy.spec b/numpy.spec index a6191f6..6d49435 100644 --- a/numpy.spec +++ b/numpy.spec @@ -121,6 +121,7 @@ EOF env OPENBLAS=%{_libdir} \ BLAS=%{_libdir} \ LAPACK=%{_libdir} CFLAGS="%{optflags}" \ + SETUPTOOLS_USE_DISTUTILS=stdlib %{__python3} setup.py build %install @@ -134,6 +135,7 @@ popd env OPENBLAS=%{_libdir} \ FFTW=%{_libdir} BLAS=%{_libdir} \ LAPACK=%{_libdir} CFLAGS="%{optflags}" \ + SETUPTOOLS_USE_DISTUTILS=stdlib %{__python3} setup.py install --root %{buildroot} pushd %{buildroot}%{_bindir} &> /dev/null ln -s f2py3 f2py.numpy @@ -204,6 +206,7 @@ python3 runtests.py --no-build -- -ra -k 'not test_ppc64_ibm_double_double128' * Mon Mar 07 2022 Karolina Surma - 1:1.22.0-4 - Work around the test failures with setuptools >= 60.x by using the Python's standard library distutils +- Build numpy using Python's standard library distutils * Sat Feb 19 2022 Elliott Sales de Andrade - 1:1.22.0-3 - Re-enable tests