[packages/python3-setuptools] Python3 version as separate spec.
arekm
arekm at pld-linux.org
Thu Apr 8 20:53:37 CEST 2021
commit 34676580fa1a64f29cfa1d07e1f6cfc220852e82
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Thu Apr 8 20:53:29 2021 +0200
Python3 version as separate spec.
python-setuptools.spec => python3-setuptools.spec | 94 +----------------------
1 file changed, 1 insertion(+), 93 deletions(-)
---
diff --git a/python-setuptools.spec b/python3-setuptools.spec
similarity index 63%
rename from python-setuptools.spec
rename to python3-setuptools.spec
index 9927c03..a3bd1a7 100644
--- a/python-setuptools.spec
+++ b/python3-setuptools.spec
@@ -4,13 +4,7 @@
%bcond_with system_libs # use system modules (appdirs, packaging, pyparsing, six) # TODO
%bcond_with tests # py.test tests (few failures)
%bcond_with bootstrap # convenience alias for without: apidocs,system_libs,tests
-%bcond_without python2 # CPython 2.x module
-%bcond_without python3 # CPython 3.x module
-%bcond_without python3_default # Use Python 3.x for easy_install executable
-%if %{without python3}
-%undefine python3_default
-%endif
%if %{with bootstrap}
%undefine with_apidocs
%undefine with_system_libs
@@ -21,7 +15,7 @@
%define pypi_name setuptools
Summary: A collection of enhancements to the Python distutils
Summary(pl.UTF-8): Zestaw rozszerzeń dla pythonowych distutils
-Name: python-setuptools
+Name: python3-setuptools
Version: 42.0.2
Release: 5
Epoch: 1
@@ -34,32 +28,6 @@ URL: https://github.com/pypa/setuptools
%if %(locale -a | grep -q '^C\.utf8$'; echo $?)
BuildRequires: glibc-localedb-all
%endif
-%if %{with python2}
-BuildRequires: python-modules >= 1:2.7
-%if %{with system_libs}
-# versions from pkg_resources/_vendor/vendored.txt
-BuildRequires: python-appdirs >= 1.4.3
-BuildRequires: python-packaging >= 19.2
-BuildRequires: python-pyparsing >= 2.2.1
-BuildRequires: python-six >= 1.10.0
-%endif
-BuildConflicts: python-distribute < 0.7
-%if %{with tests}
-# https://raw.githubusercontent.com/pypa/setuptools/v%{version}/tests/requirements.txt
-BuildRequires: python-coverage >= 4.5.1
-BuildRequires: python-futures
-BuildRequires: python-mock
-BuildRequires: python-pip >= 19.1
-BuildRequires: python-pytest >= 3.7
-BuildRequires: python-pytest-cov >= 2.5.1
-BuildRequires: python-pytest-fixture-config
-BuildRequires: python-pytest-flake8
-BuildRequires: python-pytest-virtualenv >= 1.2.7
-BuildRequires: python-virtualenv >= 13.0.0
-BuildRequires: python-wheel
-%endif
-%endif
-%if %{with python3}
BuildRequires: python3-modules >= 1:3.4
%if %{with system_libs}
# versions from pkg_resources/_vendor/vendored.txt
@@ -85,7 +53,6 @@ BuildRequires: python3-pytest-virtualenv >= 1.2.7
BuildRequires: python3-virtualenv >= 13.0.0
BuildRequires: python3-wheel
%endif
-%endif
%if %{with apidocs}
BuildRequires: python3-jaraco
BuildRequires: python3-jaraco.packaging >= 6.1
@@ -123,30 +90,6 @@ Ten pakiet zawiera składniki uruchomieniowe setuptools, potrzebne do
uruchamiania kodu wymagającego pkg_resources.py, przeznaczone dla
Pythona 2.x.
-%package -n python3-%{module}
-Summary: A collection of enhancements to the Python distutils
-Summary(pl.UTF-8): Zestaw rozszerzeń dla pythonowych distutils
-Group: Libraries/Python
-Requires: python3-modules >= 1:3.4
-%if %{with system_libs}
-# versions from pkg_resources/_vendor/vendored.txt
-Requires: python3-appdirs >= 1.4.0
-Requires: python3-packaging >= 16.8
-Requires: python3-pyparsing >= 2.1.10
-Requires: python3-six >= 1.10.0
-%endif
-Obsoletes: python3-distribute < 0.7
-
-%description -n python3-%{module}
-setuptools is a collection of enhancements to the Python distutils
-that allow you to more easily build and distribute Python 3.x
-packages, especially ones that have dependencies on other packages.
-
-%description -n python3-%{module} -l pl.UTF-8
-setuptools to zestaw rozszerzeń do pythonowych distutils umożliwiający
-łatwiejsze budowanie i rozprowadzanie pakietów Pythona 3.x,
-szczególnie tych mających zależności od innych pakietów.
-
%package -n easy_install
Summary: Python software installer (deprecated)
Summary(pl.UTF-8): Instalator oprogramowania napisanego w Pythonie (przestarzały)
@@ -184,19 +127,10 @@ exit 1 # TODO: unvendor modules from pkg_resources/_vendor
%endif
%build
-%if %{with python2}
-LC_ALL=C.UTF-8 \
-%py_build
-
-%{?with_tests:%{__python} -m pytest pkg_resources/tests setuptools/tests tests}
-%endif
-
-%if %{with python3}
LC_ALL=C.UTF-8 \
%py3_build
%{?with_tests:%{__python3} -m pytest pkg_resources/tests setuptools/tests tests}
-%endif
%if %{with apidocs}
%{__make} -C docs html SPHINXBUILD=sphinx-build-3
@@ -205,48 +139,22 @@ LC_ALL=C.UTF-8 \
%install
rm -rf $RPM_BUILD_ROOT
-%if %{with python3}
%py3_install
-%endif
-%if %{with python2}
-%py_install
-
-# note: setuptools/command/easy_install.py expects setuptools/site-patch.py to exist
-%py_postclean -x site-patch.py
-%endif
-
-%if %{with python3_default}
ln -sf easy_install-%{py3_ver} $RPM_BUILD_ROOT%{_bindir}/easy_install
-%else
-ln -sf easy_install-%{py_ver} $RPM_BUILD_ROOT%{_bindir}/easy_install
-%endif
%clean
rm -rf $RPM_BUILD_ROOT
-%if %{with python2}
%files
%defattr(644,root,root,755)
%doc CHANGES.rst LICENSE README.rst
-%attr(755,root,root) %{_bindir}/easy_install-%{py_ver}
-%{py_sitescriptdir}/pkg_resources
-%{py_sitescriptdir}/setuptools
-%{py_sitescriptdir}/easy_install.py[co]
-%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
-%endif
-
-%if %{with python3}
-%files -n python3-%{module}
-%defattr(644,root,root,755)
-%doc CHANGES.rst LICENSE README.rst
%attr(755,root,root) %{_bindir}/easy_install-%{py3_ver}
%{py3_sitescriptdir}/__pycache__/easy_install.*.py[co]
%{py3_sitescriptdir}/pkg_resources
%{py3_sitescriptdir}/setuptools
%{py3_sitescriptdir}/easy_install.py
%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
-%endif
%files -n easy_install
%defattr(644,root,root,755)
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python3-setuptools.git/commitdiff/34676580fa1a64f29cfa1d07e1f6cfc220852e82
More information about the pld-cvs-commit
mailing list