packaging fixes

https://github.com/release-engineering/productmd/pull/103

Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
This commit is contained in:
Igor Gnatenko 2018-02-07 12:47:42 +01:00
parent c440f9c6ca
commit 0524659438
No known key found for this signature in database
GPG Key ID: 695714BD1BBC5F4C

View File

@ -7,32 +7,13 @@
Name: python-productmd
Version: 1.10
Release: 2%{?dist}
Release: 3%{?dist}
Summary: Library providing parsers for metadata related to OS installation
Group: Development/Tools
License: LGPLv2+
URL: https://github.com/release-engineering/productmd
Source0: https://files.pythonhosted.org/packages/source/p/%{name}/%{name}-%{version}.tar.gz
BuildRequires: python2-devel
%if 0%{?epel} < 7
BuildRequires: python-setuptools
%else
BuildRequires: python2-setuptools
%endif
%if 0%{?fedora}
BuildRequires: python2-six
%else
BuildRequires: python-six
%endif
%if 0%{?with_python3}
BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: python%{python3_pkgversion}-setuptools
BuildRequires: python%{python3_pkgversion}-six
%endif
BuildArch: noarch
%global _description\
@ -45,10 +26,15 @@ and installation media.
Summary: %summary
Obsoletes: productmd <= %{version}-%{release}
Provides: productmd = %{version}-%{release}
%if 0%{?fedora}
Requires: python2-six
%else
BuildRequires: python2-devel
%if 0%{?rhel} && 0%{?rhel} <= 7
BuildRequires: python-setuptools
BuildRequires: python-six
Requires: python-six
%else
BuildRequires: python2-setuptools
BuildRequires: python2-six
Requires: python2-six
%endif
%{?python_provide:%python_provide python2-productmd}
@ -56,13 +42,13 @@ Requires: python-six
%if 0%{?with_python3}
%package -n python%{python3_pkgversion}-productmd
Summary: Library providing parsers for metadata related to OS installation
Group: Development/Tools
Summary: %{summary}
BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: python%{python3_pkgversion}-setuptools
BuildRequires: python%{python3_pkgversion}-six
Requires: python%{python3_pkgversion}-six
%description -n python%{python3_pkgversion}-productmd
Python library providing parsers for metadata related to composes
and installation media.
%description -n python%{python3_pkgversion}-productmd %_description
%endif
%prep
@ -102,6 +88,9 @@ and installation media.
%endif
%changelog
* Wed Feb 07 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.10-3
- packaging fixes
* Fri Jan 19 2018 Lubomír Sedlář <lsedlar@redhat.com> - 1.10-2
- Fix wrong python_sitelib macro (RHBZ#1536202)