From 450ec9b4408cbaec5c0ba6726f6a2b1d17ab9140 Mon Sep 17 00:00:00 2001 From: Lumir Balhar Date: Fri, 16 Sep 2016 21:59:27 +0200 Subject: [PATCH] Initial import (#1376710). --- .gitignore | 1 + python-packaging.spec | 100 ++++++++++++++++++++++++++++++++++++++++++ sources | 1 + 3 files changed, 102 insertions(+) create mode 100644 python-packaging.spec diff --git a/.gitignore b/.gitignore index e69de29..66f7564 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/packaging-16.7.tar.gz diff --git a/python-packaging.spec b/python-packaging.spec new file mode 100644 index 0000000..bd3fae5 --- /dev/null +++ b/python-packaging.spec @@ -0,0 +1,100 @@ +%global pypi_name packaging + +Name: python-%{pypi_name} +Version: 16.7 +Release: 1%{?dist} +Summary: Core utilities for Python packages + +License: BSD or ASL 2.0 +URL: https://github.com/pypa/packaging +Source0: https://files.pythonhosted.org/packages/source/p/%{pypi_name}/%{pypi_name}-%{version}.tar.gz +BuildArch: noarch + +BuildRequires: python2-setuptools +BuildRequires: python2-devel +BuildRequires: python2-pytest +BuildRequires: python-pretend +BuildRequires: python2-pyparsing +BuildRequires: python-six + +BuildRequires: python3-setuptools +BuildRequires: python3-devel +BuildRequires: python3-pytest +BuildRequires: python3-pretend +BuildRequires: python3-pyparsing +BuildRequires: python3-six +BuildRequires: python3-sphinx + +%description +python-packaging provides core utilities for Python packages like utilities for +dealing with versions, specifiers, markers etc. + +%package -n python2-%{pypi_name} +Summary: %{summary} +%{?python_provide:%python_provide python2-%{pypi_name}} + +Requires: python2-pyparsing +Requires: python-six +%description -n python2-%{pypi_name} +python2-packaging provides core utilities for Python packages like utilities for +dealing with versions, specifiers, markers etc. + + +%package -n python3-%{pypi_name} +Summary: %{summary} +%{?python_provide:%python_provide python3-%{pypi_name}} + +Requires: python3-pyparsing +Requires: python3-six +%description -n python3-%{pypi_name} +python3-packaging provides core utilities for Python packages like utilities for +dealing with versions, specifiers, markers etc. + +%package -n python-%{pypi_name}-doc +Summary: python-packaging documentation +Suggests: python3-%{pypi_name} = %{version}-%{release} +%description -n python-%{pypi_name}-doc +Documentation for python-packaging + +%prep +%autosetup -n %{pypi_name}-%{version} +# Remove bundled egg-info +rm -rf %{pypi_name}.egg-info + +%build +%py2_build +%py3_build +# generate html docs +sphinx-build-3 docs html +# remove the sphinx-build leftovers +rm -rf html/.{doctrees,buildinfo} +# Do not bundle fonts +rm -rf html/_static/fonts/ + +%install +%py2_install +%py3_install + +%check +%{__python2} -m pytest tests/ +%{__python3} -m pytest tests/ + +%files -n python2-%{pypi_name} +%license LICENSE LICENSE.APACHE LICENSE.BSD +%doc README.rst CHANGELOG.rst CONTRIBUTING.rst +%{python2_sitelib}/%{pypi_name}/ +%{python2_sitelib}/%{pypi_name}-%{version}-py%{python2_version}.egg-info + +%files -n python3-%{pypi_name} +%license LICENSE LICENSE.APACHE LICENSE.BSD +%doc README.rst CHANGELOG.rst CONTRIBUTING.rst +%{python3_sitelib}/%{pypi_name}/ +%{python3_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info + +%files -n python-%{pypi_name}-doc +%doc html +%license LICENSE LICENSE.APACHE LICENSE.BSD + +%changelog +* Fri Sep 16 2016 Lumir Balhar - 16.7-1 +- Initial package. diff --git a/sources b/sources index e69de29..28edf4b 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +5bfeb52de8dee2fcc95a003b0ebe9011 packaging-16.7.tar.gz