]> git.pld-linux.org Git - packages/python-urllib3.git/blame - python-urllib3.spec
- release 3 (by relup.sh)
[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
fb337b23 6%bcond_with tests # test target (uses network etc.)
5381b073
ER
7
8%define module urllib3
9%define pypi_name 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}
686fd12d 13Version: 1.22
2a47d280 14Release: 3
f980972e
ŁK
15License: MIT
16Group: Development/Languages/Python
5381b073 17Source0: https://files.pythonhosted.org/packages/source/u/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
686fd12d 18# Source0-md5: 0da7bed3fe94bf7dc59ae37885cc72f7
f980972e
ŁK
19URL: http://urllib3.readthedocs.org/
20%if %{with python2}
21BuildRequires: python-modules >= 1:2.7
fb337b23
JB
22%if %{with tests}
23BuildRequires: python-PySocks >= 1.5.6
24BuildRequires: python-PySocks < 2.0
25BuildRequires: python-mock
26BuildRequires: python-nose
27BuildRequires: python-tornado
28# SO_REUSEPORT option
29BuildRequires: uname(release) >= 3.9
30%endif
f980972e
ŁK
31%endif
32%if %{with python3}
d1b278cf 33BuildRequires: python3-modules >= 1:3.2
fb337b23
JB
34%if %{with tests}
35BuildRequires: python3-PySocks >= 1.5.6
36BuildRequires: python3-PySocks < 2.0
37BuildRequires: python3-nose
38BuildRequires: python3-tornado
39# SO_REUSEPORT option
40BuildRequires: uname(release) >= 3.9
41%endif
f980972e
ŁK
42%endif
43BuildRequires: rpm-pythonprov
fb337b23 44BuildRequires: rpmbuild(macros) >= 1.714
f980972e
ŁK
45Requires: python-modules >= 1:2.7
46BuildArch: noarch
47BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48
49%description
d1b278cf 50Python 2 HTTP module with connection pooling and file POST abilities.
f980972e
ŁK
51Features are:
52- Re-use the same socket connection for multiple requests (with
53 optional client-side certificate verification).
54- File posting (encode_multipart_formdata).
55- Built-in redirection and retries (optional).
56- Supports gzip and deflate decoding.
57- Thread-safe and sanity-safe.
58
d1b278cf
JB
59%description -l pl.UTF-8
60Moduł HTTP dla Pythona 2 z pulą połączeń i możliwością wysyłania
61plików metodą POST. Możliwości:
62- używanie tego samego połączenia dla wielu żądań (z opcjonalną
63 weryfikacją certyfikatu po stronie klienta)
64- wysyłanie plików (encode_multipart_formdata)
65- wbudowane przekierowania i ponawianie prób (opcjonalne)
66- obsługa kodowań gzip i deflate
67- bezpieczeństwo względem wątków.
68
f980972e
ŁK
69%package -n python3-urllib3
70Summary: HTTP library with thread-safe connection pooling, file post, and more
d1b278cf 71Summary(pl.UTF-8): Biblioteka HTTP z bezpieczną wątkowo pulą połączeń, wysyłaniem plików itd.
f980972e 72Group: Development/Languages/Python
d1b278cf 73Requires: python3-modules >= 1:3.2
f980972e
ŁK
74
75%description -n python3-urllib3
d1b278cf 76Python 3 HTTP module with connection pooling and file POST abilities.
f980972e
ŁK
77Features are:
78- Re-use the same socket connection for multiple requests (with
79 optional client-side certificate verification).
80- File posting (encode_multipart_formdata).
81- Built-in redirection and retries (optional).
82- Supports gzip and deflate decoding.
83- Thread-safe and sanity-safe.
84
d1b278cf
JB
85%description -n python3-urllib3 -l pl.UTF-8
86Moduł HTTP dla Pythona 3 z pulą połączeń i możliwością wysyłania
87plików metodą POST. Możliwości:
88- używanie tego samego połączenia dla wielu żądań (z opcjonalną
89 weryfikacją certyfikatu po stronie klienta)
90- wysyłanie plików (encode_multipart_formdata)
91- wbudowane przekierowania i ponawianie prób (opcjonalne)
92- obsługa kodowań gzip i deflate
93- bezpieczeństwo względem wątków.
94
f980972e
ŁK
95%prep
96%setup -q -n %{module}-%{version}
97
98%build
99%if %{with python2}
fb337b23 100%py_build %{?with_tests:test}
f980972e
ŁK
101%endif
102
103%if %{with python3}
fb337b23 104%py3_build %{?with_tests:test}
f980972e
ŁK
105%endif
106
107%install
108rm -rf $RPM_BUILD_ROOT
109
110%if %{with python2}
fb337b23 111%py_install
f980972e
ŁK
112%py_postclean
113%endif
114
115%if %{with python3}
fb337b23 116%py3_install
fb337b23 117%endif
f980972e
ŁK
118
119%clean
120rm -rf $RPM_BUILD_ROOT
121
122%if %{with python2}
123%files
124%defattr(644,root,root,755)
fb337b23 125%doc CHANGES.rst CONTRIBUTORS.txt LICENSE.txt README.rst
f980972e 126%{py_sitescriptdir}/%{module}
f980972e
ŁK
127%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
128%endif
f980972e
ŁK
129
130%if %{with python3}
131%files -n python3-urllib3
132%defattr(644,root,root,755)
fb337b23 133%doc CHANGES.rst CONTRIBUTORS.txt LICENSE.txt README.rst
f980972e
ŁK
134%{py3_sitescriptdir}/%{module}
135%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
136%endif
This page took 0.041857 seconds and 4 git commands to generate.