diff --git a/_multibuild b/_multibuild
new file mode 100644
index 0000000..fcc7b97
--- /dev/null
+++ b/_multibuild
@@ -0,0 +1,3 @@
+
+ test
+
diff --git a/python-setuptools.changes b/python-setuptools.changes
index a68058b..54458ab 100644
--- a/python-setuptools.changes
+++ b/python-setuptools.changes
@@ -1,3 +1,17 @@
+-------------------------------------------------------------------
+Wed Aug 21 12:40:01 UTC 2019 - Tomáš Chvátal
+
+- Switch to multibuild to enable testsuite
+
+-------------------------------------------------------------------
+Wed Aug 21 12:12:39 UTC 2019 - Tomáš Chvátal
+
+- Update to 41.2.0:
+ * #479: Remove some usage of the deprecated imp module.
+ * #1565: Changed html_sidebars from string to list of string as per https://www.sphinx-doc.org/en/master/changes.html#id58
+ * #1697: Moved most of the constants from setup.py to setup.cfg
+ * #1756: Forse metadata-version >= 1.2. when project urls are present.
+
-------------------------------------------------------------------
Sat May 4 19:54:21 UTC 2019 - Arun Persaud
@@ -265,6 +279,11 @@ Sun May 6 05:30:02 UTC 2018 - arun@gmx.de
loaded by the SourcelessFileLoader.
* #1332: Silence spurious wheel related warnings on Windows.
+-------------------------------------------------------------------
+Tue Apr 24 14:02:55 UTC 2018 - jgonzalez@suse.com
+
+- build python3 subpackage (FATE#323875)
+
-------------------------------------------------------------------
Mon Mar 19 10:56:56 UTC 2018 - tchvatal@suse.com
@@ -1061,6 +1080,12 @@ Tue Aug 11 07:02:31 UTC 2015 - tbechtold@suse.com
- update to 18.1:
* Upgrade to vendored packaging 15.3.
+-------------------------------------------------------------------
+Mon Aug 3 15:40:48 UTC 2015 - jmatejek@suse.com
+
+- update to 18.0.1 for fate#319032
+ * see full changelog in CHANGES.txt
+
-------------------------------------------------------------------
Mon Jul 20 19:39:31 UTC 2015 - dmueller@suse.com
@@ -1098,6 +1123,11 @@ Mon Jun 8 16:43:29 UTC 2015 - tbechtold@suse.com
``pkg_resources._initialize_master_working_set``, allowing for
imperative re-initialization of the master working set.
+-------------------------------------------------------------------
+Wed May 27 09:57:53 UTC 2015 - jmatejek@suse.com
+
+- fix vulnerability in non-RFC6125-compliant host name matching
+ (bsc#930189, setuptools-1.1.7-match-hostname.patch)
-------------------------------------------------------------------
Mon Apr 27 07:04:26 UTC 2015 - mcihar@suse.cz
@@ -1330,6 +1360,11 @@ Fri Mar 27 14:30:44 UTC 2015 - tbechtold@suse.com
- Add fix-type-error.patch: Fix error during test run
- Add fix-sle11-test-failure.patch: Fix error during test run on SLE11SP3
+-------------------------------------------------------------------
+Thu Jan 15 17:48:35 CET 2015 - lchiquitto@suse.de
+
+- Add package to SLE 12 SDK (FATE#318137, bnc#913229)
+
-------------------------------------------------------------------
Wed Jul 23 08:54:56 UTC 2014 - sleep_walker@suse.cz
diff --git a/python-setuptools.spec b/python-setuptools.spec
index ff26aa9..a690b51 100644
--- a/python-setuptools.spec
+++ b/python-setuptools.spec
@@ -18,8 +18,16 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define oldpython python
-Name: python-setuptools
-Version: 41.0.1
+%global flavor @BUILD_FLAVOR@%{nil}
+%if "%{flavor}" == "test"
+%define psuffix -test
+%bcond_without test
+%else
+%define psuffix %{nil}
+%bcond_with test
+%endif
+Name: python-setuptools%{psuffix}
+Version: 41.2.0
Release: 0
Summary: Enhancements to distutils for building and distributing Python packages
License: Python-2.0 OR ZPL-2.0
@@ -35,8 +43,6 @@ BuildRequires: %{python_module xml}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildRequires: unzip
-#!BuildIgnore: python2-pyparsing
-#!BuildIgnore: python3-pyparsing
# needed for SLE
Requires: python
Requires: python-appdirs
@@ -46,11 +52,26 @@ Requires: python-xml
Requires(post): update-alternatives
Requires(postun): update-alternatives
BuildArch: noarch
+%if %{with test}
+BuildRequires: %{python_module Paver}
+BuildRequires: %{python_module devel}
+BuildRequires: %{python_module mock}
+BuildRequires: %{python_module pip}
+BuildRequires: %{python_module pyparsing >= 2.0.2}
+BuildRequires: %{python_module pytest-fixture-config}
+BuildRequires: %{python_module pytest-virtualenv}
+BuildRequires: %{python_module pytest}
+BuildRequires: %{python_module setuptools >= %{version}}
+BuildRequires: %{python_module wheel}
+BuildRequires: python-futures
+%else
+#!BuildIgnore: python-pyparsing
+#!BuildIgnore: python2-pyparsing
+#!BuildIgnore: python3-pyparsing
+%endif
%if 0%{?suse_version} || 0%{?fedora_version} >= 24
Recommends: ca-certificates-mozilla
%endif
-# NOTE(saschpe): Distribute was merged into 0.7.x, so even though distribute
-# obsoletes setuptools < 0.6.45, current setuptools obsoletes distribute again
%ifpython2
Provides: %{oldpython}-distribute = %{version}
Obsoletes: %{oldpython}-distribute < %{version}
@@ -81,15 +102,18 @@ sed -r -i '1s@^#!/.*$@@' setuptools/command/easy_install.py
%python_build
%install
+%if !%{with test}
%python_install
%prepare_alternative easy_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
+%endif
-# Can not run testsuite as this introduces build cycle
-#%%check
-#export LANG="en_US.UTF-8"
-#python setup.py ptr --addopts='-rxs'
+%check
+%if %{with test}
+%pytest
+%endif
+%if !%{with test}
%post
%python_install_alternative easy_install
@@ -105,5 +129,6 @@ sed -r -i '1s@^#!/.*$@@' setuptools/command/easy_install.py
%pycache_only %{python_sitelib}/__pycache__/easy_install.*
%dir %{python_sitelib}/pkg_resources
%{python_sitelib}/pkg_resources/*
+%endif
%changelog
diff --git a/setuptools-41.0.1.zip b/setuptools-41.0.1.zip
deleted file mode 100644
index d13b859..0000000
--- a/setuptools-41.0.1.zip
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:a222d126f5471598053c9a77f4b5d4f26eaa1f150ad6e01dcf1a42e185d05613
-size 849016
diff --git a/setuptools-41.2.0.zip b/setuptools-41.2.0.zip
new file mode 100644
index 0000000..d1361fe
--- /dev/null
+++ b/setuptools-41.2.0.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:66b86bbae7cc7ac2e867f52dc08a6bd064d938bac59dfec71b9b565dd36d6012
+size 851251