summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRicardo Cordeiro <gryfrev8-redhat.com-rjmco@tux.com.pt>2016-12-31 16:02:22 +0000
committerRicardo Cordeiro <gryfrev8-redhat.com-rjmco@tux.com.pt>2016-12-31 16:02:22 +0000
commit979a6326fa9c1b65e92be9635f7701e5c4098d43 (patch)
tree3426b823509d153f7b6257a1f54951ce73bbf8b5
parentd739eb0a58351990d047c07eb772d09836cde623 (diff)
downloadpython-novaclient-os-diskconfig-979a6326fa9c1b65e92be9635f7701e5c4098d43.tar.gz
python-novaclient-os-diskconfig-979a6326fa9c1b65e92be9635f7701e5c4098d43.tar.xz
python-novaclient-os-diskconfig-979a6326fa9c1b65e92be9635f7701e5c4098d43.zip
0.1.3-1: Added python3 sub-package for the releases that have the necessary dependencies
-rw-r--r--SPECS/python-novaclient-os-diskconfig.spec37
1 files changed, 37 insertions, 0 deletions
diff --git a/SPECS/python-novaclient-os-diskconfig.spec b/SPECS/python-novaclient-os-diskconfig.spec
index 91b8a58..13bac90 100644
--- a/SPECS/python-novaclient-os-diskconfig.spec
+++ b/SPECS/python-novaclient-os-diskconfig.spec
@@ -1,6 +1,10 @@
%global srcname novaclient-os-diskconfig
%global upstreamname os_diskconfig_python_novaclient_ext
+%if 0%{?fedora} >= 25
+%global with_python3 1
+%endif
+
Name: python-%{srcname}
Version: 0.1.3
Release: 1%{?dist}
@@ -13,9 +17,13 @@ Source0: http://pypi.python.org/packages/source/o/%{upstreamname}/%{upstreamname
BuildArch: noarch
BuildRequires: python2-devel
+%if 0%{?with_python3}
+BuildRequires: python3-devel
+%endif
%description
%{summary}
+
%package -n python2-%{srcname}
Summary: %{summary}
BuildRequires: python-novaclient
@@ -25,22 +33,51 @@ Requires: python-novaclient
%description -n python2-%{srcname}
%{summary}
+%if 0%{?with_python3}
+%package -n python3-%{srcname}
+Summary: %{summary}
+BuildRequires: python3-novaclient
+Requires: python3-novaclient
+%{?python_provide:%python_provide python3-%{srcname}}
+
+%description -n python3-%{srcname}
+%{summary}
+%endif
+
%prep
%autosetup -n %{upstreamname}-%{version}
%build
%py2_build
+%if 0%{?with_python3}
+%py3_build
+%endif
%install
%py2_install
+%if 0%{?with_python3}
+%py3_install
+%endif
%check
%{__python2} setup.py test
+%if 0%{?with_python3}
+%{__python3} setup.py test
+%endif
%files -n python2-%{srcname}
%doc README.rst
%{python2_sitelib}/*
+%if 0%{?with_python3}
+%files -n python3-%{srcname}
+%doc README.rst
+%{python3_sitelib}/*
+%endif
+
%changelog
+* Sat Dec 31 2016 Ricardo Cordeiro <gryfrev8-redhat.com-rjmco@tux.com.pt> - 0.1.3-1
+- Added python3 sub-package for the releases that have the necessary dependencies
+
* Thu Mar 03 2016 Ricardo Cordeiro <gryfrev8-redhat.com-rjmco@tux.com.pt> - 0.1.3-1
- Initial package