]> git.pld-linux.org Git - packages/python-urllib3.git/blame - python-urllib3.spec
- updated to 1.25.6
[packages/python-urllib3.git] / python-urllib3.spec
CommitLineData
fb337b23 1# TODO: use system six, [backports.]ssl_match_hostname
d1b278cf 2#
f980972e 3# Conditional build:
d1b278cf
JB
4%bcond_without python2 # CPython 2.x module
5%bcond_without python3 # CPython 3.x module
1cbae8fc 6%bcond_without doc # Sphinx documentation
fb337b23 7%bcond_with tests # test target (uses network etc.)
5381b073
ER
8
9%define module urllib3
f980972e 10Summary: HTTP library with thread-safe connection pooling, file post, and more
d1b278cf 11Summary(pl.UTF-8): Biblioteka HTTP z bezpieczną wątkowo pulą połączeń, wysyłaniem plików itd.
f980972e 12Name: python-%{module}
a957e881 13Version: 1.25.6
3b3a1b3a 14Release: 1
f980972e
ŁK
15License: MIT
16Group: Development/Languages/Python
70df9369 17#Source0Download: https://pypi.org/simple/urllib3/
1cbae8fc 18Source0: https://files.pythonhosted.org/packages/source/u/urllib3/%{module}-%{version}.tar.gz
a957e881 19# Source0-md5: a7504a9fcb7ed4ffa482fe098c80b6d4
70df9369 20Patch0: %{name}-mock.patch
f980972e
ŁK
21URL: http://urllib3.readthedocs.org/
22%if %{with python2}
23BuildRequires: python-modules >= 1:2.7
fb337b23
JB
24%if %{with tests}
25BuildRequires: python-PySocks >= 1.5.6
26BuildRequires: python-PySocks < 2.0
27BuildRequires: python-mock
28BuildRequires: python-nose
29BuildRequires: python-tornado
30# SO_REUSEPORT option
31BuildRequires: uname(release) >= 3.9
32%endif
f980972e
ŁK
33%endif
34%if %{with python3}
1cbae8fc 35BuildRequires: python3-modules >= 1:3.4
fb337b23
JB
36%if %{with tests}
37BuildRequires: python3-PySocks >= 1.5.6
38BuildRequires: python3-PySocks < 2.0
39BuildRequires: python3-nose
40BuildRequires: python3-tornado
41# SO_REUSEPORT option
42BuildRequires: uname(release) >= 3.9
43%endif
f980972e
ŁK
44%endif
45BuildRequires: rpm-pythonprov
fb337b23 46BuildRequires: rpmbuild(macros) >= 1.714
1cbae8fc 47%if %{with doc}
70df9369 48BuildRequires: sphinx-pdg-3
1cbae8fc 49%endif
f980972e
ŁK
50Requires: python-modules >= 1:2.7
51BuildArch: noarch
52BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
53
54%description
d1b278cf 55Python 2 HTTP module with connection pooling and file POST abilities.
f980972e
ŁK
56Features are:
57- Re-use the same socket connection for multiple requests (with
58 optional client-side certificate verification).
59- File posting (encode_multipart_formdata).
60- Built-in redirection and retries (optional).
61- Supports gzip and deflate decoding.
62- Thread-safe and sanity-safe.
63
d1b278cf
JB
64%description -l pl.UTF-8
65Moduł HTTP dla Pythona 2 z pulą połączeń i możliwością wysyłania
66plików metodą POST. Możliwości:
67- używanie tego samego połączenia dla wielu żądań (z opcjonalną
68 weryfikacją certyfikatu po stronie klienta)
69- wysyłanie plików (encode_multipart_formdata)
70- wbudowane przekierowania i ponawianie prób (opcjonalne)
71- obsługa kodowań gzip i deflate
72- bezpieczeństwo względem wątków.
73
f980972e
ŁK
74%package -n python3-urllib3
75Summary: HTTP library with thread-safe connection pooling, file post, and more
d1b278cf 76Summary(pl.UTF-8): Biblioteka HTTP z bezpieczną wątkowo pulą połączeń, wysyłaniem plików itd.
f980972e 77Group: Development/Languages/Python
1cbae8fc 78Requires: python3-modules >= 1:3.4
f980972e
ŁK
79
80%description -n python3-urllib3
d1b278cf 81Python 3 HTTP module with connection pooling and file POST abilities.
f980972e
ŁK
82Features are:
83- Re-use the same socket connection for multiple requests (with
84 optional client-side certificate verification).
85- File posting (encode_multipart_formdata).
86- Built-in redirection and retries (optional).
87- Supports gzip and deflate decoding.
88- Thread-safe and sanity-safe.
89
d1b278cf
JB
90%description -n python3-urllib3 -l pl.UTF-8
91Moduł HTTP dla Pythona 3 z pulą połączeń i możliwością wysyłania
92plików metodą POST. Możliwości:
93- używanie tego samego połączenia dla wielu żądań (z opcjonalną
94 weryfikacją certyfikatu po stronie klienta)
95- wysyłanie plików (encode_multipart_formdata)
96- wbudowane przekierowania i ponawianie prób (opcjonalne)
97- obsługa kodowań gzip i deflate
98- bezpieczeństwo względem wątków.
99
1cbae8fc
JB
100%package apidocs
101Summary: API documentation for Python urllib3 module
102Summary(pl.UTF-8): Dokumentacja API modułu Pythona urllib3
103Group: Documentation
104
105%description apidocs
106API documentation for Python urllib3 module.
107
108%description apidocs -l pl.UTF-8
109Dokumentacja API modułu Pythona urllib3.
110
f980972e
ŁK
111%prep
112%setup -q -n %{module}-%{version}
70df9369 113%patch0 -p1
f980972e
ŁK
114
115%build
116%if %{with python2}
fb337b23 117%py_build %{?with_tests:test}
f980972e
ŁK
118%endif
119
120%if %{with python3}
fb337b23 121%py3_build %{?with_tests:test}
f980972e
ŁK
122%endif
123
1cbae8fc 124%if %{with doc}
ad572b13 125%{__make} -C docs html \
70df9369 126 SPHINXBUILD=sphinx-build-3 \
ad572b13 127 SPHINXOPTS=
1cbae8fc
JB
128%endif
129
f980972e
ŁK
130%install
131rm -rf $RPM_BUILD_ROOT
132
133%if %{with python2}
fb337b23 134%py_install
f980972e
ŁK
135%py_postclean
136%endif
137
138%if %{with python3}
fb337b23 139%py3_install
fb337b23 140%endif
f980972e
ŁK
141
142%clean
143rm -rf $RPM_BUILD_ROOT
144
145%if %{with python2}
146%files
147%defattr(644,root,root,755)
fb337b23 148%doc CHANGES.rst CONTRIBUTORS.txt LICENSE.txt README.rst
f980972e 149%{py_sitescriptdir}/%{module}
f980972e
ŁK
150%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
151%endif
f980972e
ŁK
152
153%if %{with python3}
154%files -n python3-urllib3
155%defattr(644,root,root,755)
fb337b23 156%doc CHANGES.rst CONTRIBUTORS.txt LICENSE.txt README.rst
f980972e
ŁK
157%{py3_sitescriptdir}/%{module}
158%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
159%endif
1cbae8fc
JB
160
161%if %{with doc}
162%files apidocs
163%defattr(644,root,root,755)
164%doc docs/_build/html/{_static,reference,*.html,*.js}
165%endif
This page took 0.077132 seconds and 4 git commands to generate.