]> git.pld-linux.org Git - packages/python3-setuptools.git/blame - python-setuptools.spec
- updated to 20.2.2
[packages/python3-setuptools.git] / python-setuptools.spec
CommitLineData
2f649423
MK
1#
2# Conditional build:
e2cd79ed
JB
3%bcond_without apidocs # Sphinx based documentation
4%bcond_with tests # "test" action (fails, pytest-runner doesn't support build-base)
5%bcond_without python2 # CPython 2.x module
6%bcond_without python3 # CPython 3.x module
25fb9ea9
JK
7%bcond_without python3_default # Use Python 3.x for easy_install executable
8
9%if %{without python3}
10%undefine python3_default
11%endif
2f649423 12
cb552c1a 13%define module setuptools
b79e62bc 14Summary: A collection of enhancements to the Python distutils
e4a6c4e2 15Summary(pl.UTF-8): Zestaw rozszerzeń dla pythonowych distutils
b79e62bc 16Name: python-setuptools
e2cd79ed 17Version: 20.2.2
dfd639a7 18Release: 1
67093d8e 19Epoch: 1
2f649423 20License: PSF or ZPL
b79e62bc 21Group: Development/Languages/Python
e2cd79ed 22#Source0Download: https://pypi.python.org/simple/setuptools/
15009e3d 23Source0: https://pypi.python.org/packages/source/s/setuptools/setuptools-%{version}.tar.gz
e2cd79ed 24# Source0-md5: bf37191cb4c1472fb61e6f933d2006b1
2f649423 25URL: https://bitbucket.org/pypa/setuptools
c034c756
JB
26%if %(locale -a | grep -q '^en_US.UTF-8$'; echo $?)
27BuildRequires: glibc-localedb-all
28%endif
2f649423 29%if %{with python2}
c034c756 30BuildRequires: python-modules >= 1:2.6
b6cbc91d 31BuildConflicts: python-distribute < 0.7
e2cd79ed
JB
32%if %{with tests}
33BuildRequires: python-mock
34BuildRequires: python-pytest >= 2.8
35BuildRequires: python-pytest-runner
36%endif
2f649423
MK
37%endif
38%if %{with python3}
c034c756 39BuildRequires: python3-modules >= 1:3.2
b6cbc91d 40BuildConflicts: python3-distribute < 0.7
e2cd79ed
JB
41%if %{with tests}
42%if "%{py3_ver}" < "3.3"
43BuildRequires: python3-mock
44%endif
45BuildRequires: python3-pytest >= 2.8
46BuildRequires: python3-pytest-runner
47%endif
2f649423 48%endif
5c02125b 49%if %{with apidocs}
e2cd79ed 50BuildRequires: python3-rst.linker >= 1.4
96995d3d 51BuildRequires: sphinx-pdg-3
5c02125b 52%endif
c034c756 53BuildRequires: rpm-pythonprov
b6cbc91d 54BuildRequires: rpmbuild(macros) >= 1.710
c034c756 55Requires: python-modules >= 1:2.6
64c5aa5e 56Obsoletes: python-distribute < 0.7
c034c756 57Obsoletes: python-setuptools-devel
b79e62bc
AM
58BuildArch: noarch
59BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
60
61%description
62setuptools is a collection of enhancements to the Python distutils
c034c756
JB
63that allow you to more easily build and distribute Python 2.x
64packages, especially ones that have dependencies on other packages.
b79e62bc 65
1c17442b 66%description -l pl.UTF-8
d539774b 67setuptools to zestaw rozszerzeń do pythonowych distutils umożliwiający
c034c756
JB
68łatwiejsze budowanie i rozprowadzanie pakietów Pythona 2.x,
69szczególnie tych mających zależności od innych pakietów.
d539774b
JB
70
71Ten pakiet zawiera składniki uruchomieniowe setuptools, potrzebne do
c034c756
JB
72uruchamiania kodu wymagającego pkg_resources.py, przeznaczone dla
73Pythona 2.x.
eadb908c 74
2f649423 75%package -n python3-%{module}
c034c756
JB
76Summary: A collection of enhancements to the Python distutils
77Summary(pl.UTF-8): Zestaw rozszerzeń dla pythonowych distutils
2f649423 78Group: Libraries/Python
c034c756 79Requires: python3-modules >= 1:3.2
ff466203 80Obsoletes: python3-distribute < 0.7
2f649423
MK
81
82%description -n python3-%{module}
c034c756
JB
83setuptools is a collection of enhancements to the Python distutils
84that allow you to more easily build and distribute Python 3.x
85packages, especially ones that have dependencies on other packages.
2f649423
MK
86
87%description -n python3-%{module} -l pl.UTF-8
c034c756
JB
88setuptools to zestaw rozszerzeń do pythonowych distutils umożliwiający
89łatwiejsze budowanie i rozprowadzanie pakietów Pythona 3.x,
90szczególnie tych mających zależności od innych pakietów.
2f649423 91
25fb9ea9
JK
92%package -n easy_install
93Summary: Python software installer
94Summary(pl.UTF-8): Instalator oprogramowania napisanego w Pythonie
95Group: Libraries/Python
96%if %{with python3_default}
97Requires: python3-%{module} = %{epoch}:%{version}-%{release}
98%else
99Requires: python-%{module} = %{epoch}:%{version}-%{release}
100%endif
b6cbc91d 101Conflicts: python-setuptools < 1:18.6.1-2
25fb9ea9
JK
102
103%description -n easy_install
104Python software installer.
105
106%description -n easy_install
107Instalator oprogramowania napisanego w Pythonie.
108
2f649423
MK
109%package apidocs
110Summary: %{module} API documentation
111Summary(pl.UTF-8): Dokumentacja API %{module}
112Group: Documentation
113
114%description apidocs
115API documentation for %{module}.
116
117%description apidocs -l pl.UTF-8
118Dokumentacja API %{module}.
119
b79e62bc 120%prep
2f649423 121%setup -q -n %{module}-%{version}
b79e62bc
AM
122
123%build
2f649423 124%if %{with python2}
c034c756 125LC_ALL=en_US.UTF-8 \
a21b5be7 126%py_build %{?with_tests:test}
2f649423
MK
127%endif
128
129%if %{with python3}
c034c756 130LC_ALL=en_US.UTF-8 \
a21b5be7 131%py3_build %{?with_tests:test}
2f649423 132%endif
b79e62bc 133
c034c756 134%if %{with apidocs}
e2cd79ed 135#%{__make} -C docs html SPHINXBUILD=sphinx-build-3
5c02125b 136# rst.linker needs sphinx-build to be run from directory containing "CHANGES.txt"
96995d3d 137sphinx-build-3 -b html -d build/doctrees -D latex_paper_size=a4 docs build/html
c034c756
JB
138%endif
139
b79e62bc
AM
140%install
141rm -rf $RPM_BUILD_ROOT
142
c034c756 143%if %{with python3}
a21b5be7 144%py3_install
2f649423 145%endif
991fba2b 146
c034c756 147%if %{with python2}
a21b5be7 148%py_install
c034c756
JB
149
150%py_postclean
2f649423 151%endif
b79e62bc 152
25fb9ea9 153%if %{with python3_default}
b6cbc91d 154ln -sf easy_install-%{py3_ver} $RPM_BUILD_ROOT%{_bindir}/easy_install
25fb9ea9 155%else
b6cbc91d 156ln -sf easy_install-%{py_ver} $RPM_BUILD_ROOT%{_bindir}/easy_install
25fb9ea9
JK
157%endif
158
b79e62bc
AM
159%clean
160rm -rf $RPM_BUILD_ROOT
161
2f649423 162%if %{with python2}
b79e62bc
AM
163%files
164%defattr(644,root,root,755)
e2cd79ed 165%doc CHANGES.txt README.txt
25fb9ea9 166%attr(755,root,root) %{_bindir}/easy_install-%{py_ver}
5c02125b
JB
167%{py_sitescriptdir}/pkg_resources
168%{py_sitescriptdir}/setuptools
2f649423 169%{py_sitescriptdir}/easy_install.py[co]
2f649423
MK
170%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
171%endif
2f649423
MK
172
173%if %{with python3}
174%files -n python3-%{module}
f4841952 175%defattr(644,root,root,755)
e2cd79ed 176%doc CHANGES.txt README.txt
25fb9ea9 177%attr(755,root,root) %{_bindir}/easy_install-%{py3_ver}
c034c756 178%{py3_sitescriptdir}/__pycache__/easy_install.*.py[co]
5c02125b
JB
179%{py3_sitescriptdir}/pkg_resources
180%{py3_sitescriptdir}/setuptools
2f649423 181%{py3_sitescriptdir}/easy_install.py
2f649423
MK
182%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
183%endif
184
25fb9ea9
JK
185%files -n easy_install
186%defattr(644,root,root,755)
187%attr(755,root,root) %{_bindir}/easy_install
188
c034c756 189%if %{with apidocs}
2f649423
MK
190%files apidocs
191%defattr(644,root,root,755)
5c02125b 192%doc build/html/*
2f649423 193%endif
This page took 0.071275 seconds and 4 git commands to generate.