]> git.pld-linux.org Git - packages/python3-setuptools.git/blame_incremental - python-setuptools.spec
up to 40.2.0
[packages/python3-setuptools.git] / python-setuptools.spec
... / ...
CommitLineData
1#
2# Conditional build:
3%bcond_without apidocs # Sphinx based documentation
4%bcond_with tests # py.test tests (few failures)
5%bcond_without python2 # CPython 2.x module
6%bcond_without python3 # CPython 3.x module
7%bcond_without python3_default # Use Python 3.x for easy_install executable
8
9%if %{without python3}
10%undefine python3_default
11%endif
12
13%define module setuptools
14Summary: A collection of enhancements to the Python distutils
15Summary(pl.UTF-8): Zestaw rozszerzeń dla pythonowych distutils
16Name: python-setuptools
17Version: 40.2.0
18Release: 1
19Epoch: 1
20License: PSF or ZPL
21Group: Development/Languages/Python
22#Source0Download: https://pypi.python.org/simple/setuptools/
23Source0: https://files.pythonhosted.org/packages/ef/1d/201c13e353956a1c840f5d0fbf0461bd45bbd678ea4843ebf25924e8984c/setuptools-%{version}.zip
24# Source0-md5: 592efabea3a65d8e97a025ed52f69b12
25URL: https://github.com/pypa/setuptools
26%if %(locale -a | grep -q '^C.UTF-8$'; echo $?)
27BuildRequires: glibc-localedb-all
28%endif
29%if %{with python2}
30BuildRequires: python-appdirs >= 1.4.0
31BuildRequires: python-modules >= 1:2.6
32BuildRequires: python-packaging >= 16.8
33BuildConflicts: python-distribute < 0.7
34BuildRequires: python-six >= 1.6.0
35%if %{with tests}
36BuildRequires: python-backports.unittest_mock >= 1.2
37BuildRequires: python-pytest >= 3.0.2
38BuildRequires: python-pytest-flake8
39%endif
40%endif
41%if %{with python3}
42BuildRequires: python3-appdirs >= 1.4.0
43BuildRequires: python3-modules >= 1:3.3
44BuildRequires: python3-packaging >= 16.8
45BuildRequires: python3-six >= 1.6.0
46BuildConflicts: python3-distribute < 0.7
47%if %{with tests}
48BuildRequires: python3-pytest >= 3.0.2
49BuildRequires: python3-pytest-flake8
50%endif
51%endif
52%if %{with apidocs}
53BuildRequires: python3-jaraco
54BuildRequires: python3-jaraco.packaging
55BuildRequires: python3-rst.linker >= 1.6.1
56BuildRequires: sphinx-pdg-3 >= 1.4
57%endif
58BuildRequires: rpm-pythonprov
59BuildRequires: rpmbuild(macros) >= 1.714
60BuildRequires: unzip
61Requires: python-modules >= 1:2.6
62Obsoletes: python-distribute < 0.7
63Obsoletes: python-setuptools-devel
64BuildArch: noarch
65BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
66
67%description
68setuptools is a collection of enhancements to the Python distutils
69that allow you to more easily build and distribute Python 2.x
70packages, especially ones that have dependencies on other packages.
71
72%description -l pl.UTF-8
73setuptools to zestaw rozszerzeń do pythonowych distutils umożliwiający
74łatwiejsze budowanie i rozprowadzanie pakietów Pythona 2.x,
75szczególnie tych mających zależności od innych pakietów.
76
77Ten pakiet zawiera składniki uruchomieniowe setuptools, potrzebne do
78uruchamiania kodu wymagającego pkg_resources.py, przeznaczone dla
79Pythona 2.x.
80
81%package -n python3-%{module}
82Summary: A collection of enhancements to the Python distutils
83Summary(pl.UTF-8): Zestaw rozszerzeń dla pythonowych distutils
84Group: Libraries/Python
85Requires: python3-modules >= 1:3.3
86Obsoletes: python3-distribute < 0.7
87
88%description -n python3-%{module}
89setuptools is a collection of enhancements to the Python distutils
90that allow you to more easily build and distribute Python 3.x
91packages, especially ones that have dependencies on other packages.
92
93%description -n python3-%{module} -l pl.UTF-8
94setuptools to zestaw rozszerzeń do pythonowych distutils umożliwiający
95łatwiejsze budowanie i rozprowadzanie pakietów Pythona 3.x,
96szczególnie tych mających zależności od innych pakietów.
97
98%package -n easy_install
99Summary: Python software installer
100Summary(pl.UTF-8): Instalator oprogramowania napisanego w Pythonie
101Group: Libraries/Python
102%if %{with python3_default}
103Requires: python3-%{module} = %{epoch}:%{version}-%{release}
104%else
105Requires: python-%{module} = %{epoch}:%{version}-%{release}
106%endif
107Conflicts: python-setuptools < 1:18.6.1-2
108
109%description -n easy_install
110Python software installer.
111
112%description -n easy_install -l pl.UTF-8
113Instalator oprogramowania napisanego w Pythonie.
114
115%package apidocs
116Summary: %{module} API documentation
117Summary(pl.UTF-8): Dokumentacja API %{module}
118Group: Documentation
119
120%description apidocs
121API documentation for %{module}.
122
123%description apidocs -l pl.UTF-8
124Dokumentacja API %{module}.
125
126%prep
127%setup -q -n %{module}-%{version}
128
129%build
130%if %{with python2}
131LC_ALL=C.UTF-8 \
132%py_build
133
134%{?with_tests:%{__python} -m pytest pkg_resources/tests setuptools/tests tests}
135%endif
136
137%if %{with python3}
138LC_ALL=C.UTF-8 \
139%py3_build
140
141%{?with_tests:%{__python3} -m pytest pkg_resources/tests setuptools/tests tests}
142%endif
143
144%if %{with apidocs}
145%{__make} -C docs html SPHINXBUILD=sphinx-build-3
146%endif
147
148%install
149rm -rf $RPM_BUILD_ROOT
150
151%if %{with python3}
152%py3_install
153%endif
154
155%if %{with python2}
156%py_install
157
158# note: setuptools/command/easy_install.py expects setuptools/site-patch.py to exist
159%py_postclean -x site-patch.py
160%endif
161
162%if %{with python3_default}
163ln -sf easy_install-%{py3_ver} $RPM_BUILD_ROOT%{_bindir}/easy_install
164%else
165ln -sf easy_install-%{py_ver} $RPM_BUILD_ROOT%{_bindir}/easy_install
166%endif
167
168%clean
169rm -rf $RPM_BUILD_ROOT
170
171%if %{with python2}
172%files
173%defattr(644,root,root,755)
174%doc CHANGES.rst README.rst
175%attr(755,root,root) %{_bindir}/easy_install-%{py_ver}
176%{py_sitescriptdir}/pkg_resources
177%{py_sitescriptdir}/setuptools
178%{py_sitescriptdir}/easy_install.py[co]
179%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
180%endif
181
182%if %{with python3}
183%files -n python3-%{module}
184%defattr(644,root,root,755)
185%doc CHANGES.rst README.rst
186%attr(755,root,root) %{_bindir}/easy_install-%{py3_ver}
187%{py3_sitescriptdir}/__pycache__/easy_install.*.py[co]
188%{py3_sitescriptdir}/pkg_resources
189%{py3_sitescriptdir}/setuptools
190%{py3_sitescriptdir}/easy_install.py
191%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
192%endif
193
194%files -n easy_install
195%defattr(644,root,root,755)
196%attr(755,root,root) %{_bindir}/easy_install
197
198%if %{with apidocs}
199%files apidocs
200%defattr(644,root,root,755)
201%doc docs/build/html/{_static,*.html,*.js}
202%endif
This page took 0.027941 seconds and 4 git commands to generate.