From 5f1f0a73b10684d1701dad88cc74b06b879c78f5 Mon Sep 17 00:00:00 2001 From: Haikel Guemar Date: Wed, 24 Feb 2016 15:31:04 +0100 Subject: [PATCH] Upstream 2.5.0 - Add python3 subpackage --- .gitignore | 1 + python-semantic_version.spec | 66 ++++++++++++++++++++++++++++++------ sources | 2 +- 3 files changed, 57 insertions(+), 12 deletions(-) diff --git a/.gitignore b/.gitignore index 6d29c6c..bb25f56 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ /semantic_version-2.4.1.tar.gz /semantic_version-2.4.2.tar.gz +/semantic_version-2.5.0.tar.gz diff --git a/python-semantic_version.spec b/python-semantic_version.spec index 69b2c26..6083006 100644 --- a/python-semantic_version.spec +++ b/python-semantic_version.spec @@ -1,9 +1,13 @@ %global pypi_name semantic_version %{!?_licensedir:%global license %%doc} +%if 0%{?fedora} +%global with_python3 1 +%endif + Name: python-%{pypi_name} -Version: 2.4.2 -Release: 2%{?dist} +Version: 2.5.0 +Release: 1%{?dist} Summary: A library implementing the 'SemVer' scheme License: BSD @@ -11,15 +15,37 @@ URL: https://github.com/rbarrois/python-semanticversion Source0: https://pypi.python.org/packages/source/s/%{pypi_name}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch -BuildRequires: python2-devel -BuildRequires: python-setuptools >= 0.8 - -Provides: python-semantic-version %description This small python library provides a few tools to handle semantic versioning in Python +%package -n python2-%{pypi_name} +Summary: %{summary} +BuildRequires: python2-devel +BuildRequires: python-setuptools >= 0.8 + +%{?python_provide:%python_provide python2-%{pypi_name}} +Provides: python-semantic-version + +%description -n python2-%{pypi_name} +This small python library provides a few tools to handle semantic versioning +in Python + +%if 0%{?with_python3} +%package -n python3-%{pypi_name} +Summary: %{summary} +BuildRequires: python3-devel +BuildRequires: python3-setuptools >= 0.8 + +%{?python_provide:%python_provide python3-%{pypi_name}} + +%description -n python3-%{pypi_name} +This small python library provides a few tools to handle semantic versioning +in Python +%endif + + %package doc Summary: Documentation for python-%{pypi_name} @@ -40,33 +66,51 @@ rm docs/credits.rst %build %{__python2} setup.py build - +%if 0%{?with_python3} +%{__python3} setup.py build +%endif # generate html docs sphinx-build docs html # remove the sphinx-build leftovers rm -rf html/.{doctrees,buildinfo} - %install %{__python2} setup.py install --skip-build --root %{buildroot} - +%if 0%{?with_python3} +%{__python3} setup.py install --skip-build --root %{buildroot} +%endif %check %{__python2} setup.py test +%if 0%{?with_python3} +%{__python3} setup.py test +%endif - -%files +%files -n python2-%{pypi_name} %license LICENSE %doc README.rst ChangeLog %{python2_sitelib}/%{pypi_name} %{python2_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info +%if 0%{?with_python3} +%files -n python3-%{pypi_name} +%license LICENSE +%doc README.rst ChangeLog +%{python3_sitelib}/%{pypi_name} +%{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info +%endif + + %files doc %license LICENSE %doc html %changelog +* Wed Feb 24 2016 Haïkel Guémar - 2.5.0-1 +- Upstream 2.5.0 +- Add python3 subpackage + * Thu Feb 04 2016 Fedora Release Engineering - 2.4.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild diff --git a/sources b/sources index 7bd04c5..f0733c5 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -fd7d5ade76e78d8540b9a4044496a57c semantic_version-2.4.2.tar.gz +9a3f8e3ca00dcd2da16e30d55a4d4d99 semantic_version-2.5.0.tar.gz