diff --git a/python-pandas.spec b/python-pandas.spec index 78c9c6f..4ba2a93 100644 --- a/python-pandas.spec +++ b/python-pandas.spec @@ -229,16 +229,6 @@ BuildRequires: gcc-c++ BuildRequires: python3-devel -# pyproject.toml: [build-system] requires -BuildRequires: python3dist(setuptools) >= 51 -BuildRequires: python3dist(wheel) -BuildRequires: ((python3dist(cython) >= 0.29.24) with (python3dist(cython) < 3)) - -# setup.cfg: [options] install_requires -BuildRequires: python3dist(numpy) >= 1.21 -BuildRequires: python3dist(python-dateutil) >= 2.7.3 -BuildRequires: python3dist(pytz) >= 2017.3 - # doc/source/getting_started/install.rst “Recommended dependencies” # Since these provide large speedups, we make them hard dependencies. BuildRequires: python3dist(numexpr) >= 2.7 @@ -363,19 +353,32 @@ rm -vf $(grep -rl '/\* Generated by Cython') sed -r -i '/\boldest-supported-numpy\b/d' pyproject.toml +%generate_buildrequires +%pyproject_buildrequires -r + + %build -%py3_build +%pyproject_wheel %install -%py3_install +%pyproject_install +%pyproject_save_files %{srcname} -%files -n python3-pandas +%check +%pyproject_check_import -e 'pandas.conftest' -e 'pandas.tests.*' + + +%files -n python3-pandas -f %{pyproject_files} +# While pyproject_files automatically handles the LICENSE file in the Python +# package’s dist-info directory, we also want to package the entire LICENSES/ +# directory to include third-party license text. We include a second copy of +# the LICENSE file since it would be surprising to see a license directory for +# the package without the overall license file in it. +%license LICENSE LICENSES/ %doc README.md %doc RELEASE.md -%license LICENSE LICENSES -%{python3_sitearch}/%{srcname}* %changelog @@ -386,6 +389,7 @@ sed -r -i '/\boldest-supported-numpy\b/d' pyproject.toml - Also package README.md - Do not install C sources - Carefully handle virtual Provides and licenses for bundled/copied code +- Use pyproject-rpm-macros * Fri Jan 21 2022 Fedora Release Engineering - 1.3.3-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild