# 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 library ovsdbapp %global module ovsdbapp %global common_desc \ A library for writing Open vSwitch OVSDB-based applications. Name: python-%{library} Version: 0.15.0 Release: 1%{?dist} Summary: Python OVSDB Application Library License: ASL 2.0 URL: http://launchpad.net/%{library}/ Source0: https://tarballs.openstack.org/%{library}/%{library}-%{upstream_version}.tar.gz BuildArch: noarch BuildRequires: git BuildRequires: openstack-macros %package -n python%{pyver}-%{library} Summary: Python OVSDB Application Library %{?python_provide:%python_provide python%{pyver}-%{library}} Requires: python%{pyver}-openvswitch Requires: python%{pyver}-pbr Requires: python%{pyver}-six Requires: python%{pyver}-netaddr >= 0.7.18 BuildRequires: python%{pyver}-devel BuildRequires: python%{pyver}-pbr BuildRequires: python%{pyver}-setuptools BuildRequires: python%{pyver}-mock BuildRequires: python%{pyver}-openvswitch BuildRequires: python%{pyver}-stestr BuildRequires: python%{pyver}-netaddr >= 0.7.18 %description -n python%{pyver}-%{library} %{common_desc} %description %{common_desc} %prep %autosetup -n %{library}-%{upstream_version} -S git # Let's handle dependencies ourselves %py_req_cleanup %build %{pyver_build} %install %{pyver_install} %files -n python%{pyver}-%{library} %license LICENSE %{pyver_sitelib}/%{module} %{pyver_sitelib}/%{module}-*.egg-info %exclude %{pyver_sitelib}/%{module}/tests %changelog * Tue Jan 28 2020 Miguel Barroso - 0.15.0-1 - Rebase on upstream 0.15.0 * Thu Feb 07 2019 Miguel Barroso - 0.12.2-1 - Rebase on upstream 0.12.2 * Mon Aug 06 2018 Miguel Barroso - 0.11.0-1 - Rebase on upstream 0.11.0 * Fri Oct 13 2017 Sandro Bonazzola - 0.6.0-1 - Rebase on upstream 0.6.0 * Thu Sep 14 2017 Sandro Bonazzola - 0.5.0-1 - Rebase on upstream 0.5.0 * Mon Aug 14 2017 Alfredo Moralejo 0.4.0-1 - Update to 0.4.0