]> git.pld-linux.org Git - packages/python-packaging.git/blame - python-packaging.spec
dependencies fixed
[packages/python-packaging.git] / python-packaging.spec
CommitLineData
02ced7fb
JB
1#
2# Conditional build:
3%bcond_without doc # don't build doc
4%bcond_without tests # py.test tests
5%bcond_without python2 # CPython 2.x module
6%bcond_without python3 # CPython 3.x module
055091a1 7%bcond_without setuptools # build without setuptools (for bootstraping)
02ced7fb
JB
8
9Summary: Core utilities for Python packages
10Summary(pl.UTF-8): Bazowe funkcje narzędziowe do pakietów Pythona
11Name: python-packaging
370b6b2a
JB
12Version: 17.1
13Release: 1
02ced7fb
JB
14License: Apache v2.0 or BSD
15Group: Libraries/Python
370b6b2a 16#Source0Download: https://pypi.org/simple/packaging/
02ced7fb 17Source0: https://files.pythonhosted.org/packages/source/p/packaging/packaging-%{version}.tar.gz
370b6b2a 18# Source0-md5: 8baf8241d1b6b0a5fae9b00f359976a8
02ced7fb
JB
19URL: https://github.com/pypa/packaging
20%if %{with python2}
21BuildRequires: python-modules >= 1:2.6
055091a1 22%{?with_setuptools:BuildRequires: python-setuptools}
02ced7fb
JB
23%if %{with tests}
24BuildRequires: python-pretend
25BuildRequires: python-pyparsing
26BuildRequires: python-pytest
27BuildRequires: python-six
28%endif
29%endif
30%if %{with python3}
31BuildRequires: python3-modules >= 1:3.2
055091a1 32%{?with_setuptools:BuildRequires: python3-setuptools}
02ced7fb
JB
33%if %{with tests}
34BuildRequires: python3-pretend
35BuildRequires: python3-pyparsing
36BuildRequires: python3-pytest
37BuildRequires: python3-six
38%endif
39%endif
40BuildRequires: rpm-pythonprov
41BuildRequires: rpmbuild(macros) >= 1.714
42%if %{with doc}
43BuildRequires: python3-sphinx_rtd_theme
370b6b2a 44BuildRequires: sphinx-pdg-3
02ced7fb
JB
45%endif
46Requires: python-modules >= 1:2.6
378c97d4 47Requires: python-six
81d5f5a3 48Requires: python-pyparsing >= 2.0.2
02ced7fb
JB
49BuildArch: noarch
50BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
51
52%description
53Core utilities for Python packages.
54
55%description -l pl.UTF-8
56Bazowe funkcje narzędziowe do pakietów Pythona.
57
58%package -n python3-packaging
59Summary: Core utilities for Python packages
60Summary(pl.UTF-8): Bazowe funkcje narzędziowe do pakietów Pythona
61Group: Libraries/Python
62Requires: python3-modules >= 1:3.2
378c97d4
JK
63Requires: python3-pyparsing >= 2.0.2
64Requires: python3-six
02ced7fb
JB
65
66%description -n python3-packaging
67Core utilities for Python packages.
68
69%description -n python3-packaging -l pl.UTF-8
70Bazowe funkcje narzędziowe do pakietów Pythona.
71
72%package apidocs
73Summary: API documentation for Python packaging library
74Summary(pl.UTF-8): Dokumentacja API biblioteki Pythona packaging
75Group: Documentation
76
77%description apidocs
78API documentation for Python packaging library.
79
80%description apidocs -l pl.UTF-8
81Dokumentacja API biblioteki Pythona packaging.
82
83%prep
84%setup -q -n packaging-%{version}
85
86%build
87%if %{with python2}
88%py_build
89
90%{?with_tests:%{__python} -m pytest}
91%endif
92
93%if %{with python3}
94%py3_build
95
96%{?with_tests:%{__python3} -m pytest}
97%endif
98
99%if %{with doc}
370b6b2a
JB
100%{__make} -C docs html \
101 SPHINXBUILD=sphinx-build-3
02ced7fb
JB
102%endif
103
104%install
105rm -rf $RPM_BUILD_ROOT
106
107%if %{with python2}
108%py_install
109
110%py_postclean
111%endif
112
113%if %{with python3}
114%py3_install
115%endif
116
117%clean
118rm -rf $RPM_BUILD_ROOT
119
120%if %{with python2}
121%files
122%defattr(644,root,root,755)
123%doc CHANGELOG.rst LICENSE LICENSE.BSD README.rst
124%{py_sitescriptdir}/packaging
125%{py_sitescriptdir}/packaging-%{version}-py*.egg-info
126%endif
127
128%if %{with python3}
129%files -n python3-packaging
130%defattr(644,root,root,755)
131%doc CHANGELOG.rst LICENSE LICENSE.BSD README.rst
132%{py3_sitescriptdir}/packaging
133%{py3_sitescriptdir}/packaging-%{version}-py*.egg-info
134%endif
135
136%if %{with doc}
137%files apidocs
138%defattr(644,root,root,755)
139%doc docs/_build/html/{_static,development,*.html,*.js}
140%endif
This page took 0.170398 seconds and 4 git commands to generate.