diff --git a/bugfix-eliminate-random-order-in-metadata.patch b/bugfix-eliminate-random-order-in-metadata.patch deleted file mode 100644 index a99903e412cfe233ff3f2b0f1fcf9128ebe5f728..0000000000000000000000000000000000000000 --- a/bugfix-eliminate-random-order-in-metadata.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 99ba862948c27f8851ae2131ff36daee0195ae4a Mon Sep 17 00:00:00 2001 -From: chengzihan2 -Date: Thu, 4 Jun 2020 17:29:07 +0800 -Subject: [PATCH] bugfix eliminate random order in metadata - ---- - setuptools/dist.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/setuptools/dist.py b/setuptools/dist.py -index f0f030b..d22e533 100644 ---- a/setuptools/dist.py -+++ b/setuptools/dist.py -@@ -194,7 +194,7 @@ def write_pkg_file(self, file): - self.long_description_content_type - ) - if self.provides_extras: -- for extra in self.provides_extras: -+ for extra in sorted(self.provides_extras): - write_field('Provides-Extra', extra) - - --- -2.23.0 - diff --git a/create-site-packages.patch b/create-site-packages.patch deleted file mode 100644 index 60f9795e1d047c78473643391cbb37cf3b9bed4b..0000000000000000000000000000000000000000 --- a/create-site-packages.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff --git a/setuptools/command/easy_install.py b/setuptools/command/easy_install.py -index 91c48b3..0c9b0f4 100755 ---- a/setuptools/command/easy_install.py -+++ b/setuptools/command/easy_install.py -@@ -446,6 +446,12 @@ class easy_install(Command): - instdir = normalize_path(self.install_dir) - pth_file = os.path.join(instdir, 'easy-install.pth') - -+ if not os.path.exists(instdir): -+ try: -+ os.makedirs(instdir) -+ except (OSError, IOError): -+ self.cant_write_to_target() -+ - # Is it a configured, PYTHONPATH, implicit, or explicit site dir? - is_site_dir = instdir in self.all_site_dirs - diff --git a/python-setuptools.spec b/python-setuptools.spec index a81bb70e5ac902b2ae8764f954d7284242b0bc47..a136f8b9b801d198e7b3a3c614975b17d5bf787e 100644 --- a/python-setuptools.spec +++ b/python-setuptools.spec @@ -1,35 +1,20 @@ %bcond_with tests -%bcond_without python2 -%if %{with python2} -%global python2_record %{python2_sitelib}/setuptools-%{version}.dist-info/RECORD -%endif %global python3_record %{python3_sitelib}/setuptools-%{version}.dist-info/RECORD %global python_whldir %{_datadir}/python-wheels -%global python_whlname setuptools-%{version}-py2.py3-none-any.whl +%global python_whlname setuptools-%{version}-py3-none-any.whl Name: python-setuptools -Version: 41.2.0 -Release: 3 +Version: 49.2.0 +Release: 1 Summary: Easily build and distribute Python packages License: MIT and (BSD or ASL 2.0) URL: https://pypi.python.org/pypi/setuptools Source0: %{pypi_source setuptools %{version} zip} -Patch0: create-site-packages.patch -Patch9000: bugfix-eliminate-random-order-in-metadata.patch BuildArch: noarch -%if %{with python2} -BuildRequires: python2-devel -BuildRequires: python2-pip, python2-wheel -%if %{with tests} -BuildRequires: python2-pip, python2-mock, python2-backports-unittest_mock -BuildRequires: python2-pytest, python2-pytest-fixture-config -BuildRequires: python2-pytest-virtualenv -%endif -%endif BuildRequires: python3-devel %if %{with tests} @@ -49,20 +34,6 @@ have dependencies on other packages. This package contains a python wheel of setuptools to use with venv. -%if %{with python2} -%package -n python2-setuptools -Summary: Easily build and distribute Python packages -%{?python_provide:%python_provide python2-setuptools} - -%description -n python2-setuptools -Setuptools is a collection of enhancements to the Python 2 distutils that allow -you to more easily build and distribute Python 2 packages, especially ones that -have dependencies on other packages. - -This package also contains the runtime components of setuptools, necessary to -execute the software that requires pkg_resources.py. - -%endif %package -n python3-setuptools Summary: Easily build and distribute Python 3 packages @@ -97,12 +68,6 @@ rm -rf %{buildroot}%{python3_sitelib}/setuptools/tests sed -i '/^setuptools\/tests\//d' %{buildroot}%{python3_record} find %{buildroot}%{python3_sitelib} -name '*.exe' | xargs rm -f -%if %{with python2} -%py2_install_wheel %{python_whlname} -rm -rf %{buildroot}%{python2_sitelib}/setuptools/tests -sed -i '/^setuptools\/tests\//d' %{buildroot}%{python2_record} -find %{buildroot}%{python2_sitelib} -name '*.exe' | xargs rm -f -%endif rm -r docs/{Makefile,conf.py,_*} mkdir -p %{buildroot}%{python_whldir} @@ -110,9 +75,6 @@ install -p dist/%{python_whlname} -t %{buildroot}%{python_whldir} %if %{with tests} %check -%if %{with python2} -PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=$(pwd) py.test-%{python2_version} -%endif PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=$(pwd) py.test-%{python3_version} --ignore=setuptools/tests/test_virtualenv.py --ignore=pavement.py %endif @@ -122,13 +84,6 @@ PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=$(pwd) py.test-%{python3_version} --ignore= %dir %{python_whldir}/ %{python_whldir}/%{python_whlname} -%if %{with python2} -%files -n python2-setuptools -%defattr(-,root,root) -%{_bindir}/easy_install -%{_bindir}/easy_install-2.* -%{python2_sitelib}/* -%endif %files -n python3-setuptools %defattr(-,root,root) diff --git a/setuptools-41.2.0.zip b/setuptools-41.2.0.zip deleted file mode 100644 index e2cb40dfae8844746f97fdf465454b56e037c359..0000000000000000000000000000000000000000 Binary files a/setuptools-41.2.0.zip and /dev/null differ diff --git a/setuptools-49.2.0.zip b/setuptools-49.2.0.zip new file mode 100644 index 0000000000000000000000000000000000000000..9a09b85c7d8f574844d785dc14565456fa742372 Binary files /dev/null and b/setuptools-49.2.0.zip differ