%global dlrn_nvr keystonemiddleware-7.0.1-0.20191004112333.0a65b14 %global dlrn 1 %define upstream_version 7.0.1 %{lua: posix.setenv("RHEL_ALLOW_PYTHON2_FOR_BUILD",1)} # Macros for py2/py3 compatibility %if 0%{?fedora} || 0%{?rhel} > 7 %global pyver %{python3_pkgversion} %else %global pyver 2 %endif %global pyver_bin python%{pyver} %global pyver_sitelib %python%{pyver}_sitelib %global pyver_install %py%{pyver}_install %global pyver_build %py%{pyver}_build # End of macros for py2/py3 compatibility %{!?upstream_version: %global upstream_version %{version}%{?milestone}} %global sname keystonemiddleware %global with_doc 0 %global common_desc \ This package contains middleware modules designed to provide authentication \ and authorization features to web services other than OpenStack Keystone. \ The most prominent module is keystonemiddleware.auth_token. \ This package does not expose any CLI or Python API features. Name: python-%{sname} Version: 7.0.1 Release: 0.20191004112333.0a65b14%{?dist} Summary: Middleware for OpenStack Identity License: ASL 2.0 URL: http://launchpad.net/keystonemiddleware Source0: keystonemiddleware-7.0.1-0.20191004112333.0a65b14.tar.gz # patches_base=0a65b1420799e7c7f8736e9f6c234f755ab5ac6b # patches_ignore=DROP-IN-RPM BuildArch: noarch BuildRequires: git BuildRequires: openstack-macros %description %{common_desc} %package -n python%{pyver}-%{sname} Summary: Middleware for OpenStack Identity %{?python_provide:%python_provide python%{pyver}-%{sname}} BuildRequires: python%{pyver}-devel BuildRequires: python%{pyver}-setuptools BuildRequires: python%{pyver}-pbr # Required to generate sample config automatically in documentation BuildRequires: python%{pyver}-oslo-config BuildRequires: python%{pyver}-oslo-log BuildRequires: python%{pyver}-keystoneauth1 BuildRequires: python%{pyver}-keystoneclient BuildRequires: python%{pyver}-oslo-cache Requires: python%{pyver}-keystoneclient >= 1:3.20.0 # for s3 and ec2 token middlewares Requires: python%{pyver}-keystoneauth1 >= 3.12.0 Requires: python%{pyver}-oslo-config >= 2:5.2.0 Requires: python%{pyver}-oslo-context >= 2.19.2 Requires: python%{pyver}-oslo-i18n >= 3.15.3 Requires: python%{pyver}-oslo-log >= 3.36.0 Requires: python%{pyver}-oslo-serialization >= 2.18.0 Requires: python%{pyver}-oslo-utils >= 3.33.0 Requires: python%{pyver}-pbr >= 2.0.0 Requires: python%{pyver}-pycadf >= 1.1.0 Requires: python%{pyver}-requests >= 2.14.2 Requires: python%{pyver}-six >= 1.10.0 Requires: python%{pyver}-oslo-cache >= 1.26.0 Requires: python%{pyver}-webob >= 1.7.1 %description -n python%{pyver}-%{sname} %{common_desc} %if 0%{?with_doc} %package -n python-%{sname}-doc Summary: Documentation for the Middleware for OpenStack Identity Group: Documentation BuildRequires: python%{pyver}-sphinx BuildRequires: python%{pyver}-openstackdocstheme BuildRequires: python%{pyver}-pycadf BuildRequires: python%{pyver}-oslotest BuildRequires: python%{pyver}-oslo-messaging BuildRequires: python%{pyver}-sphinxcontrib-apidoc BuildRequires: python%{pyver}-sphinxcontrib-rsvgconverter BuildRequires: python%{pyver}-requests-mock BuildRequires: python%{pyver}-testresources # Handle python2 exception %if %{pyver} == 2 BuildRequires: python-webtest %else BuildRequires: python%{pyver}-webtest %endif %description -n python-%{sname}-doc Documentation for the Middleware for OpenStack Identity %endif %prep %autosetup -n %{sname}-%{upstream_version} -S git # Let RPM handle the dependencies %py_req_cleanup # Remove bundled egg-info rm -rf %{sname}.egg-info # disable warning-is-error, this project has intersphinx in docs # so some warnings are generated in network isolated build environment # as koji sed -i 's/^warning-is-error.*/warning-is-error = 0/g' setup.cfg %build %{pyver_build} %if 0%{?with_doc} # generate html docs sphinx-build-%{pyver} -b html doc/source doc/build/html # remove the sphinx-build-%{pyver} leftovers rm -rf doc/build/html/.{doctrees,buildinfo} %endif %install %{pyver_install} # Delete tests rm -r %{buildroot}%{pyver_sitelib}/%{sname}/tests %files -n python%{pyver}-%{sname} %doc README.rst %license LICENSE %{pyver_sitelib}/%{sname} %{pyver_sitelib}/%{sname}-*.egg-info %if 0%{?with_doc} %files -n python-%{sname}-doc %doc doc/build/html LICENSE %endif %changelog * Fri Oct 04 2019 OSP Prod Chain 7.0.1-2 - Update patches * Wed Oct 02 2019 Joel Capitao 7.0.1-2 - Removed python2 subpackages in no el7 distros * Thu Sep 19 2019 RDO 7.0.1-1 - Update to 7.0.1