Update to 3.5.0

And do a major cleanup of the spec.

This removes manual %python_provide call and hence should not be backported to Fedora < 33 as is.
This commit is contained in:
Miro Hrončok 2020-04-14 15:29:48 +02:00
parent 735bdead4a
commit f85891207b
3 changed files with 12 additions and 46 deletions

1
.gitignore vendored
View File

@ -13,3 +13,4 @@
/setuptools_scm-3.3.0.tar.gz /setuptools_scm-3.3.0.tar.gz
/setuptools_scm-3.3.1.tar.gz /setuptools_scm-3.3.1.tar.gz
/setuptools_scm-3.3.3.tar.gz /setuptools_scm-3.3.3.tar.gz
/setuptools_scm-3.5.0.tar.gz

View File

@ -2,20 +2,14 @@
%global srcname setuptools_scm %global srcname setuptools_scm
%if 0%{?fedora} >= 32 || 0%{?rhel} >= 8
%bcond_with python2
%else
%bcond_without python2
%endif
Name: python-%{srcname} Name: python-%{srcname}
Version: 3.3.3 Version: 3.5.0
Release: 7%{?dist} Release: 1%{?dist}
Summary: Blessed package to manage your versions by SCM tags Summary: Blessed package to manage your versions by SCM tags
License: MIT License: MIT
URL: https://pypi.python.org/pypi/setuptools_scm URL: https://pypi.python.org/pypi/setuptools_scm
Source0: https://files.pythonhosted.org/packages/source/%(n=%{srcname}; echo ${n:0:1})/%{srcname}/%{srcname}-%{version}.tar.gz Source0: %pypi_source
BuildArch: noarch BuildArch: noarch
@ -28,30 +22,15 @@ BuildRequires: mercurial
Setuptools_scm handles managing your python package versions in SCM metadata. Setuptools_scm handles managing your python package versions in SCM metadata.
It also handles file finders for the supported SCMs. It also handles file finders for the supported SCMs.
%if %{with python2}
%package -n python2-%{srcname}
Summary: %{summary}
BuildRequires: python2-devel
BuildRequires: python2-setuptools
%if %{with tests}
BuildRequires: python2-pytest
%endif
%{?python_provide:%python_provide python2-%{srcname}}
%description -n python2-%{srcname}
Setuptools_scm handles managing your python package versions in SCM metadata.
It also handles file finders for the supported SCMs.
%endif
%package -n python%{python3_pkgversion}-%{srcname} %package -n python%{python3_pkgversion}-%{srcname}
Summary: %{summary} Summary: %{summary}
BuildRequires: python%{python3_pkgversion}-devel BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: python%{python3_pkgversion}-setuptools BuildRequires: python%{python3_pkgversion}-setuptools
%if %{with tests} %if %{with tests}
BuildRequires: python%{python3_pkgversion}-pip
BuildRequires: python%{python3_pkgversion}-pytest BuildRequires: python%{python3_pkgversion}-pytest
BuildRequires: python%{python3_pkgversion}-toml
%endif %endif
%{?python_provide:%python_provide python%{python3_pkgversion}-%{srcname}}
Obsoletes: platform-python-%{srcname} < %{version}-%{release}
%description -n python%{python3_pkgversion}-%{srcname} %description -n python%{python3_pkgversion}-%{srcname}
Setuptools_scm handles managing your python package versions in SCM metadata. Setuptools_scm handles managing your python package versions in SCM metadata.
@ -61,40 +40,26 @@ It also handles file finders for the supported SCMs.
%autosetup -n %{srcname}-%{version} %autosetup -n %{srcname}-%{version}
%build %build
%if %{with python2}
%py2_build
%endif
%py3_build %py3_build
%install %install
%if %{with python2}
%py2_install
%endif
%py3_install %py3_install
%if %{with tests} %if %{with tests}
%check %check
%if %{with python2} PYTHONPATH=%{buildroot}%{python3_sitelib} pytest-3 -v -k 'not test_pip_download'
PYTHONPATH=%{buildroot}%{python2_sitelib} py.test-%{python2_version} -v -k 'not (test_pip_download or test_old_setuptools_fails or test_old_setuptools_allows_with_warnings or test_distlib_setuptools_works)'
%endif
PYTHONPATH=%{buildroot}%{python3_sitelib} py.test-%{python3_version} -v -k 'not (test_pip_download or test_old_setuptools_fails or test_old_setuptools_allows_with_warnings or test_distlib_setuptools_works)'
%endif
%if %{with python2}
%files -n python2-%{srcname}
%license LICENSE
%doc README.rst
%{python2_sitelib}/%{srcname}/
%{python2_sitelib}/%{srcname}-*.egg-info/
%endif %endif
%files -n python%{python3_pkgversion}-%{srcname} %files -n python%{python3_pkgversion}-%{srcname}
%license LICENSE %license LICENSE
%doc README.rst %doc README.rst
%{python3_sitelib}/%{srcname}/ %{python3_sitelib}/%{srcname}/
%{python3_sitelib}/%{srcname}-*.egg-info %{python3_sitelib}/%{srcname}-*.egg-info/
%changelog %changelog
* Tue Apr 14 2020 Miro Hrončok <mhroncok@redhat.com> - 3.5.0-1
- Update to 3.5.0 (#1792534)
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.3-7 * Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.3-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild

View File

@ -1 +1 @@
SHA512 (setuptools_scm-3.3.3.tar.gz) = 196d4785a1802875d89b9e54ae788e791a9c5cb685109784059955b691242984e42b96d77075116790935f56be82259bc2588d95d65ecbb101261d76daddb83c SHA512 (setuptools_scm-3.5.0.tar.gz) = f7e2cdae7a8a3d5ef3d12effcda5ce7f362c426e11aecaef69ef604bede9abbab2aa1eee6f5310cdd72a9bf11a927dbd1f42671e28bd467ad7b15f2dba5b81d9