Accepting request 634935 from home:mcepl:work
- Switch to multibuild to minize requirements for providing urllib3 module. OBS-URL: https://build.opensuse.org/request/show/634935 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-urllib3?expand=0&rev=51
This commit is contained in:
parent
6cd76951c4
commit
af538da8db
3
_multibuild
Normal file
3
_multibuild
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<multibuild>
|
||||||
|
<package>test</package>
|
||||||
|
</multibuild>
|
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Sep 7 14:45:38 CEST 2018 - mcepl@suse.com
|
||||||
|
|
||||||
|
- Switch to multibuild to minize requirements for providing
|
||||||
|
urllib3 module.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Aug 21 11:39:09 UTC 2018 - dmueller@suse.com
|
Tue Aug 21 11:39:09 UTC 2018 - dmueller@suse.com
|
||||||
|
|
||||||
|
@ -18,7 +18,19 @@
|
|||||||
|
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
%define oldpython python
|
%define oldpython python
|
||||||
|
|
||||||
|
%global flavor @BUILD_FLAVOR@%{nil}
|
||||||
|
%if "%{flavor}" == "test"
|
||||||
|
%define test 1
|
||||||
|
%bcond_without test
|
||||||
|
%else
|
||||||
|
%bcond_with test
|
||||||
|
%endif
|
||||||
|
%if %{with test}
|
||||||
|
Name: python-urllib3-%{flavor}
|
||||||
|
%else
|
||||||
Name: python-urllib3
|
Name: python-urllib3
|
||||||
|
%endif
|
||||||
Version: 1.23
|
Version: 1.23
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: HTTP library with thread-safe connection pooling, file post, and more
|
Summary: HTTP library with thread-safe connection pooling, file post, and more
|
||||||
@ -36,12 +48,15 @@ Patch3: urllib3-test-ssl-drop-sslv3.patch
|
|||||||
# PATCH-FIX-UPSTREAM python-urllib3-recent-date.patch gh#shazow/urllib3#1303, boo#1074247 dimstar@opensuse.org -- Fix test suite, use correct date
|
# PATCH-FIX-UPSTREAM python-urllib3-recent-date.patch gh#shazow/urllib3#1303, boo#1074247 dimstar@opensuse.org -- Fix test suite, use correct date
|
||||||
Patch4: python-urllib3-recent-date.patch
|
Patch4: python-urllib3-recent-date.patch
|
||||||
BuildRequires: %{python_module PySocks}
|
BuildRequires: %{python_module PySocks}
|
||||||
BuildRequires: %{python_module mock >= 1.3.0}
|
|
||||||
BuildRequires: %{python_module psutil}
|
BuildRequires: %{python_module psutil}
|
||||||
BuildRequires: %{python_module pytest}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: %{python_module tornado >= 4.2.1}
|
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
|
%if %{with test}
|
||||||
|
BuildRequires: %{python_module mock >= 1.3.0}
|
||||||
|
BuildRequires: %{python_module pytest}
|
||||||
|
BuildRequires: %{python_module tornado >= 4.2.1}
|
||||||
|
%endif
|
||||||
#!BuildIgnore: python-requests
|
#!BuildIgnore: python-requests
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
%if 0%{?suse_version} >= 1000 || 0%{?fedora_version} >= 24
|
%if 0%{?suse_version} >= 1000 || 0%{?fedora_version} >= 24
|
||||||
@ -90,10 +105,14 @@ find . -type f -exec chmod a-x '{}' \;
|
|||||||
|
|
||||||
%install
|
%install
|
||||||
%python_install
|
%python_install
|
||||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
%{python_expand \
|
||||||
|
$python -m compileall -d %{$python_sitelib} %{buildroot}%{$python_sitelib}/urllib3/
|
||||||
|
$python -O -m compileall -d %{$python_sitelib} %{buildroot}%{$python_sitelib}/urllib3/
|
||||||
|
%fdupes %{buildroot}%{$python_sitelib}
|
||||||
|
}
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
%if %{with test}
|
||||||
skiplist='not test_select_interrupt_exception and not test_selector_error and not timeout and not test_request_host_header_ignores_fqdn_dot and not test_dotted_fqdn'
|
skiplist='not test_select_interrupt_exception and not test_selector_error and not timeout and not test_request_host_header_ignores_fqdn_dot and not test_dotted_fqdn'
|
||||||
case $(uname -m) in
|
case $(uname -m) in
|
||||||
ppc*)
|
ppc*)
|
||||||
@ -109,11 +128,15 @@ export TRAVIS=1
|
|||||||
--ignore=test/with_dummyserver/test_poolmanager.py \
|
--ignore=test/with_dummyserver/test_poolmanager.py \
|
||||||
-k "${skiplist}" \
|
-k "${skiplist}" \
|
||||||
urllib3 test}
|
urllib3 test}
|
||||||
|
rm -rf %{buildroot}%{_libexecdir}/python*
|
||||||
|
%endif
|
||||||
|
|
||||||
%files %{python_files}
|
%files %{python_files}
|
||||||
%license LICENSE.txt
|
%license LICENSE.txt
|
||||||
%doc CHANGES.rst CONTRIBUTORS.txt README.rst
|
%doc CHANGES.rst CONTRIBUTORS.txt README.rst
|
||||||
|
%if ! %{with test}
|
||||||
%{python_sitelib}/urllib3
|
%{python_sitelib}/urllib3
|
||||||
%{python_sitelib}/urllib3-%{version}-py*.egg-info
|
%{python_sitelib}/urllib3-%{version}-py*.egg-info
|
||||||
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
Reference in New Issue
Block a user