diff --git a/.python-cicoclient.metadata b/.python-cicoclient.metadata index 00dfc24..d2344b0 100644 --- a/.python-cicoclient.metadata +++ b/.python-cicoclient.metadata @@ -1 +1 @@ -e41e69a91a3b6c4347d0735b04d4f6d7dbd11b9b SOURCES/python-cicoclient-0.4.6.tar.gz +9adbe40cb785a215af200c5c2b161825cac26b1e SOURCES/python-cicoclient-0.4.7.tar.gz diff --git a/SPECS/python-cicoclient.spec b/SPECS/python-cicoclient.spec index 95f6284..2f8220a 100644 --- a/SPECS/python-cicoclient.spec +++ b/SPECS/python-cicoclient.spec @@ -1,5 +1,13 @@ +%if 0%{?rhel} && 0%{?rhel} < 8 +%bcond_without python2 +%bcond_with python3 +%else +%bcond_with python2 +%bcond_without python3 +%endif + Name: python-cicoclient -Version: 0.4.6 +Version: 0.4.7 Release: 1%{?dist} Summary: Client interfaces to admin.ci.centos.org @@ -10,22 +18,38 @@ Source0: https://pypi.io/packages/source/p/%{name}/%{name}-%{version}.t BuildArch: noarch BuildRequires: git + +%if %{with python2} BuildRequires: python2-devel BuildRequires: python-cliff BuildRequires: python-pbr BuildRequires: python-requests BuildRequires: python-setuptools -BuildRequires: python-simplejson BuildRequires: python-six - -# Work around an old version of python-sphinx_rtd_theme in CBS BuildRequires: fontawesome-fonts-web +%endif +%if %{with python3} +BuildRequires: python3-devel +BuildRequires: python3-cliff +BuildRequires: python3-pbr +BuildRequires: python3-requests +BuildRequires: python3-setuptools +BuildRequires: python3-six +%endif + +%if %{with python2} Requires: python-cliff >= 1.14.0 Requires: python-pbr >= 1.6 Requires: python-requests >= 2.5.2 -Requires: python-simplejson Requires: python-six >= 1.9.0 +%endif +%if %{with python3} +Requires: python3-cliff >= 1.14.0 +Requires: python3-pbr >= 1.6 +Requires: python3-requests >= 2.5.2 +Requires: python3-six >= 1.9.0 +%endif %description python-cicoclient is a client, library, and a CLI interface that can be used to @@ -34,10 +58,14 @@ communicate with the ci.centos.org infrastructure provisioning system: Duffy. %package doc Summary: Documentation for python-cicoclient +%if %{with python2} BuildRequires: python-sphinx BuildRequires: python-sphinx_rtd_theme -# python-sphinx_rtd_theme missing dependency https://bugzilla.redhat.com/show_bug.cgi?id=1282297 -BuildRequires: fontawesome-fonts-web +%endif +%if %{with python3} +BuildRequires: python3-sphinx +BuildRequires: python3-sphinx_rtd_theme +%endif Requires: %{name} = %{version}-%{release} @@ -54,10 +82,20 @@ This package contains auto-generated documentation. rm -f requirements.txt test-requirements.txt %build +%if %{with python2} %{__python2} setup.py build +%endif +%if %{with python3} +%py3_build +%endif %install +%if %{with python2} %{__python2} setup.py install --skip-build --root %{buildroot} +%endif +%if %{with python3} +%py3_install +%endif export PYTHONPATH="$( pwd ):$PYTHONPATH" sphinx-build -b html docs html @@ -72,8 +110,14 @@ rm -rf html/.doctrees html/.buildinfo %license LICENSE %doc README.rst %{_bindir}/cico +%if %{with python2} %{python2_sitelib}/cicoclient %{python2_sitelib}/*.egg-info +%endif +%if %{with python3} +%{python3_sitelib}/cicoclient +%{python3_sitelib}/*.egg-info +%endif %{_mandir}/man1/cico.1* %files doc @@ -81,7 +125,11 @@ rm -rf html/.doctrees html/.buildinfo %doc html %changelog -* Tue Oct 19 2021 arrfab@centos.org - 0.4.5-1 +* Fri Oct 22 2021 Evgeni Golov - 0.4.7-1 +- Update to 0.4.7 +- modified .spec for py3 support + +* Tue Oct 19 2021 arrfab@centos.org - 0.4.6-1 - Bumped to 0.4.6 for 9-stream support * Tue Oct 29 2019 brian@bstinson.com - 0.4.5-1