diff --git a/python-uncertainties.changes b/python-uncertainties.changes index f072ff3..86393d0 100644 --- a/python-uncertainties.changes +++ b/python-uncertainties.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Sep 7 01:51:59 UTC 2023 - Steve Kowalik + +- Add patch remove-future-requirement.patch, remove requirement for future +- Switch to pyproject and autosetup macros + ------------------------------------------------------------------- Thu Jun 23 06:34:32 UTC 2022 - Arun Persaud diff --git a/python-uncertainties.spec b/python-uncertainties.spec index 964858c..afb9689 100644 --- a/python-uncertainties.spec +++ b/python-uncertainties.spec @@ -1,7 +1,7 @@ # # spec file for package python-uncertainties # -# Copyright (c) 2022 SUSE LLC +# Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,24 +16,23 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-uncertainties Version: 3.1.7 Release: 0 Summary: Uncertainties on the Quantities Involved (aka "Error Propagation") License: BSD-3-Clause -Group: Development/Languages/Python URL: https://github.com/lebigot/uncertainties/ Source: https://files.pythonhosted.org/packages/source/u/uncertainties/uncertainties-%{version}.tar.gz -BuildRequires: %{python_module future} +Patch0: remove-future-requirement.patch +BuildRequires: %{python_module numpy} +BuildRequires: %{python_module pip} BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module testsuite} BuildRequires: %{python_module tools} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros -BuildRequires: %{python_module numpy if (%python-base without python36-base)} -Requires: python-future BuildArch: noarch %if 0%{?suse_version} Recommends: python-numpy @@ -46,26 +45,24 @@ performed transparently. Much more complex mathematical expressions involving numbers with uncertainties can also be evaluated directly. %prep -%setup -q -n uncertainties-%{version} +%autosetup -p1 -n uncertainties-%{version} sed -i -e '/^#!\//, 1d' uncertainties/1to2.py sed -i -e '/^#!\//, 1d' uncertainties/lib1to2/test_1to2.py %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check -# no python36-numpy -python36_ignore="--ignore uncertainties/unumpy" -%pytest ${$python_ignore} +%pytest %files %{python_files} %license LICENSE.txt %doc README.rst %{python_sitelib}/uncertainties/ -%{python_sitelib}/uncertainties-%{version}*-info +%{python_sitelib}/uncertainties-%{version}.dist-info %changelog diff --git a/remove-future-requirement.patch b/remove-future-requirement.patch new file mode 100644 index 0000000..2fd86ff --- /dev/null +++ b/remove-future-requirement.patch @@ -0,0 +1,13 @@ +Index: uncertainties-3.1.7/setup.py +=================================================================== +--- uncertainties-3.1.7.orig/setup.py ++++ uncertainties-3.1.7/setup.py +@@ -337,7 +337,7 @@ try: + 'Source': 'https://github.com/lebigot/uncertainties' + }, + +- install_requires=['future'], ++ install_requires=[], + + tests_require=['nose', 'numpy'], +