]> git.pld-linux.org Git - packages/python-setuptools.git/blame_incremental - python-setuptools.spec
- updated to 14.0
[packages/python-setuptools.git] / python-setuptools.spec
... / ...
CommitLineData
1#
2# Conditional build:
3%bcond_without apidocs # sphinx based documentation
4%bcond_with tests # "test" action (fails?)
5%bcond_without python2 # CPython 2.x module
6%bcond_without python3 # CPython 3.x module
7
8%define module setuptools
9Summary: A collection of enhancements to the Python distutils
10Summary(pl.UTF-8): Zestaw rozszerzeń dla pythonowych distutils
11Name: python-setuptools
12Version: 14.0
13Release: 1
14Epoch: 1
15License: PSF or ZPL
16Group: Development/Languages/Python
17#Source0Download: https://pypi.python.org/pypi/setuptools
18Source0: https://pypi.python.org/packages/source/s/setuptools/setuptools-%{version}.tar.gz
19# Source0-md5: 058655fe511deccb4359bf02727f5199
20URL: https://bitbucket.org/pypa/setuptools
21%if %(locale -a | grep -q '^en_US.UTF-8$'; echo $?)
22BuildRequires: glibc-localedb-all
23%endif
24%if %{with python2}
25BuildRequires: python-distribute
26BuildRequires: python-modules >= 1:2.6
27%endif
28%if %{with python3}
29BuildRequires: python3-distribute
30BuildRequires: python3-modules >= 1:3.2
31%endif
32%if %{with apidocs}
33BuildRequires: python-rst.linker
34BuildRequires: sphinx-pdg
35%endif
36BuildRequires: rpm-pythonprov
37Requires: python-modules >= 1:2.6
38Obsoletes: python-distribute
39Obsoletes: python-setuptools-devel
40BuildArch: noarch
41BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
42
43%description
44setuptools is a collection of enhancements to the Python distutils
45that allow you to more easily build and distribute Python 2.x
46packages, especially ones that have dependencies on other packages.
47
48%description -l pl.UTF-8
49setuptools to zestaw rozszerzeń do pythonowych distutils umożliwiający
50łatwiejsze budowanie i rozprowadzanie pakietów Pythona 2.x,
51szczególnie tych mających zależności od innych pakietów.
52
53Ten pakiet zawiera składniki uruchomieniowe setuptools, potrzebne do
54uruchamiania kodu wymagającego pkg_resources.py, przeznaczone dla
55Pythona 2.x.
56
57%package -n python3-%{module}
58Summary: A collection of enhancements to the Python distutils
59Summary(pl.UTF-8): Zestaw rozszerzeń dla pythonowych distutils
60Group: Libraries/Python
61Requires: python3-modules >= 1:3.2
62
63%description -n python3-%{module}
64setuptools is a collection of enhancements to the Python distutils
65that allow you to more easily build and distribute Python 3.x
66packages, especially ones that have dependencies on other packages.
67
68%description -n python3-%{module} -l pl.UTF-8
69setuptools to zestaw rozszerzeń do pythonowych distutils umożliwiający
70łatwiejsze budowanie i rozprowadzanie pakietów Pythona 3.x,
71szczególnie tych mających zależności od innych pakietów.
72
73%package apidocs
74Summary: %{module} API documentation
75Summary(pl.UTF-8): Dokumentacja API %{module}
76Group: Documentation
77
78%description apidocs
79API documentation for %{module}.
80
81%description apidocs -l pl.UTF-8
82Dokumentacja API %{module}.
83
84%prep
85%setup -q -n %{module}-%{version}
86
87%build
88%if %{with python2}
89LC_ALL=en_US.UTF-8 \
90%{__python} setup.py build --build-base build-2 %{?with_tests:test}
91%endif
92
93%if %{with python3}
94LC_ALL=en_US.UTF-8 \
95%{__python3} setup.py build --build-base build-3 %{?with_tests:test}
96%endif
97
98%if %{with apidocs}
99#%{__make} -C docs html
100# rst.linker needs sphinx-build to be run from directory containing "CHANGES.txt"
101sphinx-build -b html -d build/doctrees -D latex_paper_size=a4 docs build/html
102%endif
103
104%install
105rm -rf $RPM_BUILD_ROOT
106
107%if %{with python3}
108%{__python3} setup.py \
109 build --build-base build-3 \
110 install --skip-build \
111 --optimize=2 \
112 --root=$RPM_BUILD_ROOT
113%endif
114
115%if %{with python2}
116%{__python} setup.py \
117 build --build-base build-2 \
118 install --skip-build \
119 --optimize=2 \
120 --root=$RPM_BUILD_ROOT
121
122%py_postclean
123%endif
124
125%clean
126rm -rf $RPM_BUILD_ROOT
127
128%if %{with python2}
129%files
130%defattr(644,root,root,755)
131%doc CHANGES.txt README.txt DEVGUIDE.txt
132%attr(755,root,root) %{_bindir}/easy_install
133%attr(755,root,root) %{_bindir}/easy_install-2.*
134%{py_sitescriptdir}/pkg_resources
135%{py_sitescriptdir}/setuptools
136%{py_sitescriptdir}/_markerlib
137%{py_sitescriptdir}/easy_install.py[co]
138%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
139%endif
140
141%if %{with python3}
142%files -n python3-%{module}
143%defattr(644,root,root,755)
144%doc CHANGES.txt README.txt DEVGUIDE.txt
145%attr(755,root,root) %{_bindir}/easy_install-3.*
146%{py3_sitescriptdir}/__pycache__/easy_install.*.py[co]
147%{py3_sitescriptdir}/pkg_resources
148%{py3_sitescriptdir}/setuptools
149%{py3_sitescriptdir}/_markerlib
150%{py3_sitescriptdir}/easy_install.py
151%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
152%endif
153
154%if %{with apidocs}
155%files apidocs
156%defattr(644,root,root,755)
157%doc build/html/*
158%endif
This page took 0.053205 seconds and 4 git commands to generate.