diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000000..eb1a5fa1c3f --- /dev/null +++ b/.gitignore @@ -0,0 +1,24 @@ +# syntax: glob +# See https://blog.jaraco.com/skeleton/#ignoring-artifacts before modifying. +bin +build +dist +docs/build +include +lib +distribute.egg-info +setuptools.egg-info +setuptools/tests/bdist_wheel_testdata/*/*.egg-info/ +.coverage +.eggs +.tox +.venv +*.egg +*.py[cod] +*.swp +*~ +.hg* +.cache +.pytest_cache/ +.mypy_cache/ +.pybuild diff --git a/MANIFEST.in b/MANIFEST.in index 0643e7ee2d5..791ab8d352a 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -3,6 +3,7 @@ recursive-include tests *.py recursive-include setuptools/tests *.html recursive-include docs *.py *.txt *.rst *.conf *.css *.css_t Makefile indexsidebar.html recursive-include setuptools/_vendor * +recursive-include setuptools/_distutils/_vendor * recursive-include pkg_resources *.py *.txt recursive-include pkg_resources/tests/data * recursive-include tools * diff --git a/PKG-INFO b/PKG-INFO new file mode 100644 index 00000000000..63edca47b6b --- /dev/null +++ b/PKG-INFO @@ -0,0 +1,143 @@ +Metadata-Version: 2.1 +Name: setuptools +Version: 75.2.0 +Summary: Easily download, build, install, upgrade, and uninstall Python packages +Author-email: Python Packaging Authority +Project-URL: Source, https://github.com/pypa/setuptools +Project-URL: Documentation, https://setuptools.pypa.io/ +Project-URL: Changelog, https://setuptools.pypa.io/en/stable/history.html +Keywords: CPAN PyPI distutils eggs package management +Classifier: Development Status :: 5 - Production/Stable +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: MIT License +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Topic :: Software Development :: Libraries :: Python Modules +Classifier: Topic :: System :: Archiving :: Packaging +Classifier: Topic :: System :: Systems Administration +Classifier: Topic :: Utilities +Requires-Python: >=3.8 +Description-Content-Type: text/x-rst +License-File: LICENSE +Provides-Extra: test +Requires-Dist: pytest!=8.1.*,>=6; extra == "test" +Requires-Dist: virtualenv>=13.0.0; extra == "test" +Requires-Dist: wheel>=0.44.0; extra == "test" +Requires-Dist: pip>=19.1; extra == "test" +Requires-Dist: packaging>=23.2; extra == "test" +Requires-Dist: jaraco.envs>=2.2; extra == "test" +Requires-Dist: pytest-xdist>=3; extra == "test" +Requires-Dist: jaraco.path>=3.2.0; extra == "test" +Requires-Dist: build[virtualenv]>=1.0.3; extra == "test" +Requires-Dist: filelock>=3.4.0; extra == "test" +Requires-Dist: ini2toml[lite]>=0.14; extra == "test" +Requires-Dist: tomli-w>=1.0.0; extra == "test" +Requires-Dist: pytest-timeout; extra == "test" +Requires-Dist: pytest-perf; sys_platform != "cygwin" and extra == "test" +Requires-Dist: jaraco.develop>=7.21; (python_version >= "3.9" and sys_platform != "cygwin") and extra == "test" +Requires-Dist: pytest-home>=0.5; extra == "test" +Requires-Dist: pytest-subprocess; extra == "test" +Requires-Dist: pyproject-hooks!=1.1; extra == "test" +Requires-Dist: jaraco.test; extra == "test" +Provides-Extra: doc +Requires-Dist: sphinx>=3.5; extra == "doc" +Requires-Dist: jaraco.packaging>=9.3; extra == "doc" +Requires-Dist: rst.linker>=1.9; extra == "doc" +Requires-Dist: furo; extra == "doc" +Requires-Dist: sphinx-lint; extra == "doc" +Requires-Dist: jaraco.tidelift>=1.4; extra == "doc" +Requires-Dist: pygments-github-lexers==0.0.5; extra == "doc" +Requires-Dist: sphinx-favicon; extra == "doc" +Requires-Dist: sphinx-inline-tabs; extra == "doc" +Requires-Dist: sphinx-reredirects; extra == "doc" +Requires-Dist: sphinxcontrib-towncrier; extra == "doc" +Requires-Dist: sphinx-notfound-page<2,>=1; extra == "doc" +Requires-Dist: pyproject-hooks!=1.1; extra == "doc" +Requires-Dist: towncrier<24.7; extra == "doc" +Provides-Extra: ssl +Provides-Extra: certs +Provides-Extra: core +Requires-Dist: packaging>=24; extra == "core" +Requires-Dist: more_itertools>=8.8; extra == "core" +Requires-Dist: jaraco.text>=3.7; extra == "core" +Requires-Dist: importlib_resources>=5.10.2; python_version < "3.9" and extra == "core" +Requires-Dist: importlib_metadata>=6; python_version < "3.10" and extra == "core" +Requires-Dist: tomli>=2.0.1; python_version < "3.11" and extra == "core" +Requires-Dist: wheel>=0.43.0; extra == "core" +Requires-Dist: platformdirs>=2.6.2; extra == "core" +Requires-Dist: jaraco.collections; extra == "core" +Requires-Dist: jaraco.functools; extra == "core" +Requires-Dist: packaging; extra == "core" +Requires-Dist: more_itertools; extra == "core" +Provides-Extra: check +Requires-Dist: pytest-checkdocs>=2.4; extra == "check" +Requires-Dist: pytest-ruff>=0.2.1; sys_platform != "cygwin" and extra == "check" +Requires-Dist: ruff>=0.5.2; sys_platform != "cygwin" and extra == "check" +Provides-Extra: cover +Requires-Dist: pytest-cov; extra == "cover" +Provides-Extra: enabler +Requires-Dist: pytest-enabler>=2.2; extra == "enabler" +Provides-Extra: type +Requires-Dist: pytest-mypy; extra == "type" +Requires-Dist: mypy==1.11.*; extra == "type" +Requires-Dist: importlib_metadata>=7.0.2; python_version < "3.10" and extra == "type" +Requires-Dist: jaraco.develop>=7.21; sys_platform != "cygwin" and extra == "type" + +.. |pypi-version| image:: https://img.shields.io/pypi/v/setuptools.svg + :target: https://pypi.org/project/setuptools + +.. |py-version| image:: https://img.shields.io/pypi/pyversions/setuptools.svg + +.. |test-badge| image:: https://github.com/pypa/setuptools/actions/workflows/main.yml/badge.svg + :target: https://github.com/pypa/setuptools/actions?query=workflow%3A%22tests%22 + :alt: tests + +.. |ruff-badge| image:: https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json + :target: https://github.com/astral-sh/ruff + :alt: Ruff + +.. |docs-badge| image:: https://img.shields.io/readthedocs/setuptools/latest.svg + :target: https://setuptools.pypa.io + +.. |skeleton-badge| image:: https://img.shields.io/badge/skeleton-2024-informational + :target: https://blog.jaraco.com/skeleton + +.. |codecov-badge| image:: https://img.shields.io/codecov/c/github/pypa/setuptools/master.svg?logo=codecov&logoColor=white + :target: https://codecov.io/gh/pypa/setuptools + +.. |tidelift-badge| image:: https://tidelift.com/badges/github/pypa/setuptools?style=flat + :target: https://tidelift.com/subscription/pkg/pypi-setuptools?utm_source=pypi-setuptools&utm_medium=readme + +.. |discord-badge| image:: https://img.shields.io/discord/803025117553754132 + :target: https://discord.com/channels/803025117553754132/815945031150993468 + :alt: Discord + +|pypi-version| |py-version| |test-badge| |ruff-badge| |docs-badge| |skeleton-badge| |codecov-badge| |discord-badge| + +See the `Quickstart `_ +and the `User's Guide `_ for +instructions on how to use Setuptools. + +Questions and comments should be directed to `GitHub Discussions +`_. +Bug reports and especially tested patches may be +submitted directly to the `bug tracker +`_. + + +Code of Conduct +=============== + +Everyone interacting in the setuptools project's codebases, issue trackers, +chat rooms, and fora is expected to follow the +`PSF Code of Conduct `_. + + +For Enterprise +============== + +Available as part of the Tidelift Subscription. + +Setuptools and the maintainers of thousands of other packages are working with Tidelift to deliver one enterprise subscription that covers all of the open source you use. + +`Learn more `_. diff --git a/debian/.gitignore b/debian/.gitignore new file mode 100644 index 00000000000..0fed149274a --- /dev/null +++ b/debian/.gitignore @@ -0,0 +1,8 @@ +*.substvars +*debhelper* +.debhelper +files +python3-pkg-resources +python3-setuptools +python3-setuptools-whl +tmp diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 00000000000..ae9d560500a --- /dev/null +++ b/debian/changelog @@ -0,0 +1,5 @@ +python-setuptools (100:75.4.0-1) UNRELEASED; urgency=medium + + * https://github.com/pypa/setuptools/releases/tag/v75.4.0 + + -- Wong Hoi Sing Edison Tue, 12 Nov 2024 07:03:07 +0800 diff --git a/debian/control b/debian/control new file mode 100644 index 00000000000..afef6a3163f --- /dev/null +++ b/debian/control @@ -0,0 +1,63 @@ +Source: python-setuptools +Section: python +Priority: optional +Standards-Version: 4.5.0 +Maintainer: Wong Hoi Sing Edison +Homepage: https://github.com/pypa/setuptools/tags +Vcs-Browser: https://github.com/alvistack/pypa-setuptools +Vcs-Git: https://github.com/alvistack/pypa-setuptools.git +Build-Depends: + debhelper, + debhelper-compat (= 10), + dh-python, + fdupes, + python3-dev, + python3-wheel, + +Package: python3-pkg-resources +Architecture: all +Description: Package Discovery and Resource Access using pkg_resources + The pkg_resources module provides an API for Python libraries to + access their resource files, and for extensible applications and + frameworks to automatically discover plugins. It also provides + runtime support for using C extensions that are inside zipfile-format + eggs, support for merging packages that have separately-distributed + modules or subpackages, and APIs for managing Python's current + "working set" of active packages. +Depends: + ${misc:Depends}, + ${shlibs:Depends}, + ${python3:Depends}, + python3, +Breaks: + python3-setuptools (<< 73), +Replaces: + python3-setuptools (<< 73), + +Package: python3-setuptools +Architecture: all +Description: Python3 Distutils Enhancements + Extensions to the python-distutils for large or complex distributions. +Depends: + ${misc:Depends}, + ${shlibs:Depends}, + ${python3:Depends}, + python3, + python3-pkg-resources (= ${source:Version}), + +Package: python3-setuptools-whl +Architecture: all +Description: Python Distutils Enhancements (wheel package) + Extensions to the python-distutils for large or complex distributions. + . + This is the support package for the PEP 427 wheel version of the package, + required for using setuptools inside a virtual environment. +Depends: + ${misc:Depends}, + ${shlibs:Depends}, + ${python3:Depends}, + python3, +Breaks: + python-pip-whl (<< 21.3.1+dfsg-2~), +Replaces: + python-pip-whl (<< 21.3.1+dfsg-2~), diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 00000000000..12900b4193c --- /dev/null +++ b/debian/copyright @@ -0,0 +1,21 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ + +Files: debian/* +Copyright: 2024 Wong Hoi Sing Edison +License: Apache-2.0 + +License: Apache-2.0 + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + . + http://www.apache.org/licenses/LICENSE-2.0 + . + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + . + The complete text of the Apache version 2.0 license + can be found in "/usr/share/common-licenses/Apache-2.0". diff --git a/debian/patches/install-layout.diff b/debian/patches/install-layout.diff new file mode 100644 index 00000000000..1160a573fa5 --- /dev/null +++ b/debian/patches/install-layout.diff @@ -0,0 +1,452 @@ +diff --git a/_distutils_system_mod.py b/_distutils_system_mod.py +new file mode 100644 +index 000000000..254e425ce +--- /dev/null ++++ b/_distutils_system_mod.py +@@ -0,0 +1,136 @@ ++""" ++Apply Debian-specific patches to distutils commands and sysconfig. ++ ++Extracts the customized behavior from patches as reported ++in pypa/distutils#2 and applies those customizations (except ++for scheme definitions) to those commands. ++ ++Place this module somewhere in sys.path to take effect. ++""" ++ ++import os ++import sys ++import sysconfig ++ ++import distutils.sysconfig ++import distutils.command.install as orig_install ++import distutils.command.install_egg_info as orig_install_egg_info ++from distutils.command.install_egg_info import ( ++ to_filename, ++ safe_name, ++ safe_version, ++ ) ++from distutils.errors import DistutilsOptionError ++ ++ ++class install(orig_install.install): ++ user_options = list(orig_install.install.user_options) + [ ++ ('install-layout=', None, ++ "installation layout to choose (known values: deb, unix)"), ++ ] ++ ++ def initialize_options(self): ++ super().initialize_options() ++ self.prefix_option = None ++ self.install_layout = None ++ ++ def finalize_unix(self): ++ self.prefix_option = self.prefix ++ super().finalize_unix() ++ if self.install_layout: ++ if self.install_layout.lower() in ['deb']: ++ self.select_scheme("deb_system") ++ elif self.install_layout.lower() in ['unix']: ++ self.select_scheme("posix_prefix") ++ else: ++ raise DistutilsOptionError( ++ "unknown value for --install-layout") ++ elif ((self.prefix_option and ++ os.path.normpath(self.prefix) != '/usr/local') ++ or sys.base_prefix != sys.prefix ++ or 'PYTHONUSERBASE' in os.environ ++ or 'VIRTUAL_ENV' in os.environ ++ or 'real_prefix' in sys.__dict__): ++ self.select_scheme("posix_prefix") ++ else: ++ if os.path.normpath(self.prefix) == '/usr/local': ++ self.prefix = self.exec_prefix = '/usr' ++ self.install_base = self.install_platbase = '/usr' ++ self.select_scheme("posix_local") ++ ++ ++class install_egg_info(orig_install_egg_info.install_egg_info): ++ user_options = list(orig_install_egg_info.install_egg_info.user_options) + [ ++ ('install-layout', None, "custom installation layout"), ++ ] ++ ++ def initialize_options(self): ++ super().initialize_options() ++ self.prefix_option = None ++ self.install_layout = None ++ ++ def finalize_options(self): ++ self.set_undefined_options('install',('install_layout','install_layout')) ++ self.set_undefined_options('install',('prefix_option','prefix_option')) ++ super().finalize_options() ++ ++ @property ++ def basename(self): ++ if self.install_layout: ++ if not self.install_layout.lower() in ['deb', 'unix']: ++ raise DistutilsOptionError( ++ "unknown value for --install-layout") ++ no_pyver = (self.install_layout.lower() == 'deb') ++ elif self.prefix_option: ++ no_pyver = False ++ else: ++ no_pyver = True ++ if no_pyver: ++ basename = "%s-%s.egg-info" % ( ++ to_filename(safe_name(self.distribution.get_name())), ++ to_filename(safe_version(self.distribution.get_version())) ++ ) ++ else: ++ basename = "%s-%s-py%d.%d.egg-info" % ( ++ to_filename(safe_name(self.distribution.get_name())), ++ to_filename(safe_version(self.distribution.get_version())), ++ *sys.version_info[:2] ++ ) ++ return basename ++ ++ ++def _posix_lib(standard_lib, libpython, early_prefix, prefix): ++ is_default_prefix = not early_prefix or os.path.normpath(early_prefix) in ('/usr', '/usr/local') ++ if standard_lib: ++ return libpython ++ elif (is_default_prefix and ++ 'PYTHONUSERBASE' not in os.environ and ++ 'VIRTUAL_ENV' not in os.environ and ++ 'real_prefix' not in sys.__dict__ and ++ sys.prefix == sys.base_prefix): ++ return os.path.join(prefix, "lib", "python3", "dist-packages") ++ else: ++ return os.path.join(libpython, "site-packages") ++ ++ ++def extend_schemes(): ++ sysconfig._INSTALL_SCHEMES.setdefault( ++ 'deb_system', ++ dict( ++ purelib='{base}/lib/python3/dist-packages', ++ platlib='{platbase}/lib/python3/dist-packages', ++ headers='{base}/include/python{py_version_short}/{dist_name}', ++ scripts='{base}/bin', ++ data='{base}', ++ ), ++ ) ++ ++ ++def apply_customizations(): ++ orig_install.install = install ++ orig_install_egg_info.install_egg_info = install_egg_info ++ distutils.sysconfig._posix_lib = _posix_lib ++ extend_schemes() ++ ++ ++apply_customizations() +diff --git a/setuptools/_distutils/command/install.py b/setuptools/_distutils/command/install.py +index ceb453e04..2c7379f85 100644 +--- a/setuptools/_distutils/command/install.py ++++ b/setuptools/_distutils/command/install.py +@@ -62,6 +62,44 @@ INSTALL_SCHEMES = { + 'scripts': '{base}/Scripts', + 'data': '{base}', + }, ++ 'unix_local': { ++ 'stdlib': '{installed_base}/{platlibdir}/python{py_version_short}', ++ 'platstdlib': '{platbase}/{platlibdir}/python{py_version_short}', ++ 'purelib': '{base}/local/lib/python{py_version_short}/dist-packages', ++ 'platlib': ++ '{platbase}/local/{platlibdir}/python{py_version_short}/dist-packages', ++ 'include': '{installed_base}/include/python{py_version_short}{abiflags}', ++ 'headers': '{base}/local/include/python{py_version_short}{abiflags}', ++ 'platinclude': ++ '{installed_platbase}/include/python{py_version_short}{abiflags}', ++ 'scripts': '{base}/local/bin', ++ 'data': '{base}/local', ++ }, ++ 'deb_system': { ++ 'stdlib': '{installed_base}/{platlibdir}/python{py_version_short}', ++ 'platstdlib': '{platbase}/{platlibdir}/python{py_version_short}', ++ 'purelib': '{base}/lib/python3/dist-packages', ++ 'platlib': '{platbase}/{platlibdir}/python3/dist-packages', ++ 'include': '{installed_base}/include/python{py_version_short}{abiflags}', ++ 'headers': '{installed_base}/include/python{py_version_short}{abiflags}', ++ 'platinclude': ++ '{installed_platbase}/include/python{py_version_short}{abiflags}', ++ 'scripts': '{base}/bin', ++ 'data': '{base}', ++ }, ++ 'posix_local': { ++ 'stdlib': '{installed_base}/lib/python{py_version_short}', ++ 'platstdlib': '{platbase}/lib/python{py_version_short}', ++ 'purelib': '{base}/local/lib/python{py_version_short}/dist-packages', ++ 'platlib': '{platbase}/local/lib/python{py_version_short}/dist-packages', ++ 'include': ++ '{installed_base}/include/python{py_version_short}{abiflags}', ++ 'headers': '{base}/local/include/python{py_version_short}{abiflags}', ++ 'platinclude': ++ '{installed_platbase}/include/python{py_version_short}{abiflags}', ++ 'scripts': '{base}/local/bin', ++ 'data': '{base}/local', ++ }, + } + + # user site schemes +diff --git a/setuptools/_distutils/sysconfig.py b/setuptools/_distutils/sysconfig.py +index 9e0eb4e45..7f5d1b911 100644 +--- a/setuptools/_distutils/sysconfig.py ++++ b/setuptools/_distutils/sysconfig.py +@@ -211,8 +211,15 @@ def _get_python_inc_nt(prefix, spec_prefix, plat_specific): + + # allow this behavior to be monkey-patched. Ref pypa/distutils#2. + def _posix_lib(standard_lib, libpython, early_prefix, prefix): ++ is_default_prefix = not early_prefix or os.path.normpath(early_prefix) in ('/usr', '/usr/local') + if standard_lib: + return libpython ++ elif (is_default_prefix and ++ 'PYTHONUSERBASE' not in os.environ and ++ 'VIRTUAL_ENV' not in os.environ and ++ 'real_prefix' not in sys.__dict__ and ++ sys.prefix == sys.base_prefix): ++ return os.path.join(prefix, "lib", "python3", "dist-packages") + else: + return os.path.join(libpython, "site-packages") + +diff --git a/setuptools/command/easy_install.py b/setuptools/command/easy_install.py +index 1567a1e67..c6867fe2d 100644 +--- a/setuptools/command/easy_install.py ++++ b/setuptools/command/easy_install.py +@@ -144,6 +144,8 @@ class easy_install(Command): + ('allow-hosts=', 'H', "pattern(s) that hostnames must match"), + ('local-snapshots-ok', 'l', "allow building eggs from local checkouts"), + ('version', None, "print version information and exit"), ++ ('install-layout=', None, "installation layout to choose (known values: deb)"), ++ ('force-installation-into-system-dir', '0', "force installation into /usr"), + ( + 'no-find-links', + None, +@@ -159,6 +161,7 @@ class easy_install(Command): + 'always-copy', + 'editable', + 'no-deps', ++ 'force-installation-into-system-dir', + 'local-snapshots-ok', + 'version', + 'user', +@@ -201,6 +204,10 @@ class easy_install(Command): + self.pth_file = self.always_copy_from = None + self.site_dirs = None + self.installed_projects = {} ++ # enable custom installation, known values: deb ++ self.install_layout = None ++ self.force_installation_into_system_dir = None ++ + # Always read easy_install options, even if we are subclassed, or have + # an independent instance created. This ensures that defaults will + # always come from the standard configuration file(s)' "easy_install" +@@ -284,6 +291,11 @@ class easy_install(Command): + self.expand_basedirs() + self.expand_dirs() + ++ if self.install_layout: ++ if not self.install_layout.lower() in ['deb']: ++ raise DistutilsOptionError("unknown value for --install-layout") ++ self.install_layout = self.install_layout.lower() ++ + self._expand( + 'install_dir', + 'script_dir', +@@ -308,6 +320,15 @@ class easy_install(Command): + if self.user and self.install_purelib: + self.install_dir = self.install_purelib + self.script_dir = self.install_scripts ++ ++ if self.prefix == '/usr' and not self.force_installation_into_system_dir: ++ raise DistutilsOptionError("""installation into /usr ++ ++Trying to install into the system managed parts of the file system. Please ++consider to install to another location, or use the option ++--force-installation-into-system-dir to overwrite this warning. ++""") ++ + # default --record from the install command + self.set_undefined_options('install', ('record', 'record')) + self.all_site_dirs = get_site_dirs() +@@ -1377,11 +1398,28 @@ class easy_install(Command): + self.debug_print("os.makedirs('%s', 0o700)" % path) + os.makedirs(path, 0o700) + ++ if sys.version[:3] in ('2.3', '2.4', '2.5') or 'real_prefix' in sys.__dict__: ++ sitedir_name = 'site-packages' ++ else: ++ sitedir_name = 'dist-packages' ++ + INSTALL_SCHEMES = dict( + posix=dict( + install_dir='$base/lib/python$py_version_short/site-packages', + script_dir='$base/bin', + ), ++ unix_local = dict( ++ install_dir = '$base/local/lib/python$py_version_short/%s' % sitedir_name, ++ script_dir = '$base/local/bin', ++ ), ++ posix_local = dict( ++ install_dir = '$base/local/lib/python$py_version_short/%s' % sitedir_name, ++ script_dir = '$base/local/bin', ++ ), ++ deb_system = dict( ++ install_dir = '$base/lib/python3/%s' % sitedir_name, ++ script_dir = '$base/bin', ++ ), + ) + + DEFAULT_SCHEME = dict( +@@ -1392,11 +1430,18 @@ class easy_install(Command): + def _expand(self, *attrs): + config_vars = self.get_finalized_command('install').config_vars + +- if self.prefix: ++ if self.prefix or self.install_layout: ++ if self.install_layout and self.install_layout in ['deb']: ++ scheme_name = "deb_system" ++ self.prefix = '/usr' ++ elif self.prefix or 'real_prefix' in sys.__dict__: ++ scheme_name = os.name ++ else: ++ scheme_name = "posix_local" + # Set default install_dir/scripts from --prefix + config_vars = dict(config_vars) + config_vars['base'] = self.prefix +- scheme = self.INSTALL_SCHEMES.get(os.name, self.DEFAULT_SCHEME) ++ scheme = self.INSTALL_SCHEMES.get(scheme_name,self.DEFAULT_SCHEME) + for attr, val in scheme.items(): + if getattr(self, attr, None) is None: + setattr(self, attr, val) +@@ -1438,11 +1483,17 @@ def get_site_dirs(): + sitedirs.append(os.path.join(prefix, "Lib", "site-packages")) + elif os.sep == '/': + sitedirs.extend([ ++ os.path.join( ++ prefix, ++ "local/lib", ++ "python" + sys.version[:3], ++ "dist-packages", ++ ), + os.path.join( + prefix, + "lib", + "python{}.{}".format(*sys.version_info), +- "site-packages", ++ "dist-packages", + ), + os.path.join(prefix, "lib", "site-python"), + ]) +diff --git a/setuptools/command/install.py b/setuptools/command/install.py +index e1dff0aac..2ac3d245a 100644 +--- a/setuptools/command/install.py ++++ b/setuptools/command/install.py +@@ -1,5 +1,8 @@ + from __future__ import annotations + ++import os ++import sys ++ + import glob + import inspect + import platform +@@ -32,6 +35,11 @@ class install(orig.install): + None, + "used by system package builders to create 'flat' eggs", + ), ++ ( ++ 'install-layout=', ++ None, ++ "installation layout to choose (known values: deb, unix)", ++ ), + ] + boolean_options = orig.install.boolean_options + [ + 'old-and-unmanageable', +@@ -62,6 +70,8 @@ class install(orig.install): + super().initialize_options() + self.old_and_unmanageable = None + self.single_version_externally_managed = None ++ self.install_layout = None ++ self.prefix_option = None + + def finalize_options(self): + super().finalize_options() +@@ -73,6 +83,30 @@ class install(orig.install): + "You must specify --record or --root when building system packages" + ) + ++ def finalize_unix(self): ++ self.prefix_option = self.prefix ++ super().finalize_unix() ++ if self.install_layout: ++ if self.install_layout.lower() in ['deb']: ++ self.select_scheme("deb_system") ++ elif self.install_layout.lower() in ['unix']: ++ self.select_scheme("posix_prefix") ++ else: ++ raise DistutilsOptionError( ++ "unknown value for --install-layout") ++ elif ((self.prefix_option and ++ os.path.normpath(self.prefix) != '/usr/local') ++ or sys.base_prefix != sys.prefix ++ or 'PYTHONUSERBASE' in os.environ ++ or 'VIRTUAL_ENV' in os.environ ++ or 'real_prefix' in sys.__dict__): ++ self.select_scheme("posix_prefix") ++ else: ++ if os.path.normpath(self.prefix) == '/usr/local': ++ self.prefix = self.exec_prefix = '/usr' ++ self.install_base = self.install_platbase = '/usr' ++ self.select_scheme("posix_local") ++ + def handle_extra_path(self): + if self.root or self.single_version_externally_managed: + # explicit backward-compatibility mode, allow extra_path to work +diff --git a/setuptools/command/install_egg_info.py b/setuptools/command/install_egg_info.py +index be47254f0..8f2b14efa 100644 +--- a/setuptools/command/install_egg_info.py ++++ b/setuptools/command/install_egg_info.py +@@ -1,4 +1,5 @@ + import os ++import sys + + from setuptools import Command, namespaces + from setuptools.archive_util import unpack_archive +@@ -6,6 +7,7 @@ from setuptools.archive_util import unpack_archive + from .._path import ensure_directory + + from distutils import dir_util, log ++from distutils.errors import DistutilsOptionError + + + class install_egg_info(namespaces.Installer, Command): +@@ -19,11 +21,28 @@ class install_egg_info(namespaces.Installer, Command): + + def initialize_options(self): + self.install_dir = None ++ self.install_layout = None ++ self.prefix_option = None + + def finalize_options(self): + self.set_undefined_options('install_lib', ('install_dir', 'install_dir')) ++ self.set_undefined_options('install', ('install_layout', 'install_layout')) ++ if sys.hexversion > 0x2060000: ++ self.set_undefined_options('install', ('prefix_option', 'prefix_option')) + ei_cmd = self.get_finalized_command("egg_info") + basename = f"{ei_cmd._get_egg_basename()}.egg-info" ++ ++ if self.install_layout: ++ if not self.install_layout.lower() in ['deb']: ++ raise DistutilsOptionError("unknown value for --install-layout") ++ self.install_layout = self.install_layout.lower() ++ basename = basename.replace('-py%s' % sys.version[:4], '') ++ elif self.prefix_option or 'real_prefix' in sys.__dict__: ++ # don't modify for virtualenv ++ pass ++ else: ++ basename = basename.replace('-py%s' % sys.version[:4], '') ++ + self.source = ei_cmd.egg_info + self.target = os.path.join(self.install_dir, basename) + self.outputs = [] diff --git a/debian/patches/multiarch-extname.diff b/debian/patches/multiarch-extname.diff new file mode 100644 index 00000000000..c5509abe28e --- /dev/null +++ b/debian/patches/multiarch-extname.diff @@ -0,0 +1,75 @@ +--- a/setuptools/command/easy_install.py ++++ b/setuptools/command/easy_install.py +@@ -204,6 +204,7 @@ class easy_install(Command): + # enable custom installation, known values: deb + self.install_layout = None + self.force_installation_into_system_dir = None ++ self.multiarch = None + + # Always read easy_install options, even if we are subclassed, or have + # an independent instance created. This ensures that defaults will +@@ -293,6 +294,10 @@ class easy_install(Command): + raise DistutilsOptionError("unknown value for --install-layout") + self.install_layout = self.install_layout.lower() + ++ import sysconfig ++ if sys.version_info[:2] >= (3, 3): ++ self.multiarch = sysconfig.get_config_var('MULTIARCH') ++ + self._expand( + 'install_dir', + 'script_dir', +--- a/setuptools/command/install_lib.py ++++ b/setuptools/command/install_lib.py +@@ -15,6 +15,18 @@ class install_lib(orig.install_lib): + + distribution: Distribution # override distutils.dist.Distribution with setuptools.dist.Distribution + ++ def initialize_options(self): ++ orig.install_lib.initialize_options(self) ++ self.multiarch = None ++ self.install_layout = None ++ ++ def finalize_options(self): ++ orig.install_lib.finalize_options(self) ++ self.set_undefined_options('install',('install_layout','install_layout')) ++ if self.install_layout == 'deb' and sys.version_info[:2] >= (3, 3): ++ import sysconfig ++ self.multiarch = sysconfig.get_config_var('MULTIARCH') ++ + def run(self): + self.build() + outfiles = self.install() +@@ -104,6 +116,8 @@ class install_lib(orig.install_lib): + exclude = self.get_exclusions() + + if not exclude: ++ import distutils.dir_util ++ distutils.dir_util._multiarch = self.multiarch + return orig.install_lib.copy_tree(self, infile, outfile) + + # Exclude namespace package __init__.py* files from the output +@@ -114,11 +128,23 @@ class install_lib(orig.install_lib): + + outfiles: list[str] = [] + ++ if self.multiarch: ++ import sysconfig ++ ext_suffix = sysconfig.get_config_var ('EXT_SUFFIX') ++ if ext_suffix.endswith(self.multiarch + ext_suffix[-3:]): ++ new_suffix = None ++ else: ++ new_suffix = "%s-%s%s" % (ext_suffix[:-3], self.multiarch, ext_suffix[-3:]) ++ + def pf(src: str, dst: str): + if dst in exclude: + log.warn("Skipping installation of %s (namespace package)", dst) + return False + ++ if self.multiarch and new_suffix and dst.endswith(ext_suffix) and not dst.endswith(new_suffix): ++ dst = dst.replace(ext_suffix, new_suffix) ++ log.info("renaming extension to %s", os.path.basename(dst)) ++ + log.info("copying %s -> %s", src, os.path.dirname(dst)) + outfiles.append(dst) + return dst diff --git a/debian/patches/no-SOURCES.txt-in-egg-ingo.diff b/debian/patches/no-SOURCES.txt-in-egg-ingo.diff new file mode 100644 index 00000000000..05c0204393d --- /dev/null +++ b/debian/patches/no-SOURCES.txt-in-egg-ingo.diff @@ -0,0 +1,12 @@ +--- a/setuptools/command/install_egg_info.py ++++ b/setuptools/command/install_egg_info.py +@@ -68,6 +68,9 @@ class install_egg_info(namespaces.Instal + for skip in '.svn/', 'CVS/': + if src.startswith(skip) or '/' + skip in src: + return None ++ if self.install_layout and self.install_layout in ['deb'] and src.startswith('SOURCES.txt'): ++ log.info("Skipping SOURCES.txt") ++ return None + self.outputs.append(dst) + log.debug("Copying %s to %s", src, dst) + return dst diff --git a/debian/patches/reproducible.diff b/debian/patches/reproducible.diff new file mode 100644 index 00000000000..1386ad40b62 --- /dev/null +++ b/debian/patches/reproducible.diff @@ -0,0 +1,22 @@ +--- a/setuptools/command/easy_install.py ++++ b/setuptools/command/easy_install.py +@@ -460,7 +460,7 @@ consider to install to another location, + for spec in self.args: + self.easy_install(spec, not self.no_deps) + if self.record: +- outputs = self.outputs ++ outputs = list(sorted(self.outputs)) + if self.root: # strip any package prefix + root_len = len(self.root) + for counter in range(len(outputs)): +--- a/setuptools/_core_metadata.py ++++ b/setuptools/_core_metadata.py +@@ -226,7 +226,7 @@ def _write_requirements(self, file): + + if extra: + _write_provides_extra(file, processed_extras, extra, unsafe_extra) +- for req in _reqs.parse_strings(reqs): ++ for req in sorted(_reqs.parse_strings(reqs)): + r = _include_extra(req, extra, condition.strip()) + file.write(f"Requires-Dist: {r}\n") + diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 00000000000..e42a7115cf5 --- /dev/null +++ b/debian/patches/series @@ -0,0 +1,5 @@ +install-layout.diff +multiarch-extname.diff +no-SOURCES.txt-in-egg-ingo.diff +reproducible.diff +sorted-requires.diff diff --git a/debian/patches/sorted-requires.diff b/debian/patches/sorted-requires.diff new file mode 100644 index 00000000000..dd67eae2b48 --- /dev/null +++ b/debian/patches/sorted-requires.diff @@ -0,0 +1,11 @@ +--- a/setuptools/command/_requirestxt.py ++++ b/setuptools/command/_requirestxt.py +@@ -108,7 +108,7 @@ def _write_requirements(stream, reqs): + def append_cr(line): + return line + '\n' + +- lines = map(append_cr, lines) ++ lines = map(append_cr, sorted(lines)) + stream.writelines(lines) + + diff --git a/debian/python3-pkg-resources.install b/debian/python3-pkg-resources.install new file mode 100644 index 00000000000..9a71d66aae1 --- /dev/null +++ b/debian/python3-pkg-resources.install @@ -0,0 +1 @@ +usr/lib/python*/*-packages/pkg_resources diff --git a/debian/python3-pkg-resources.lintian-overrides b/debian/python3-pkg-resources.lintian-overrides new file mode 100644 index 00000000000..ec0ffe41ff8 --- /dev/null +++ b/debian/python3-pkg-resources.lintian-overrides @@ -0,0 +1,3 @@ +python3-pkg-resources: copyright-without-copyright-notice +python3-pkg-resources: initial-upload-closes-no-bugs +python3-pkg-resources: zero-byte-file-in-doc-directory diff --git a/debian/python3-setuptools-whl.install b/debian/python3-setuptools-whl.install new file mode 100644 index 00000000000..b33828b5865 --- /dev/null +++ b/debian/python3-setuptools-whl.install @@ -0,0 +1 @@ +usr/share/python-wheels/*.whl diff --git a/debian/python3-setuptools-whl.lintian-overrides b/debian/python3-setuptools-whl.lintian-overrides new file mode 100644 index 00000000000..6871d973311 --- /dev/null +++ b/debian/python3-setuptools-whl.lintian-overrides @@ -0,0 +1 @@ +python3-setuptools-whl: initial-upload-closes-no-bugs diff --git a/debian/python3-setuptools.install b/debian/python3-setuptools.install new file mode 100644 index 00000000000..6fcc6fef40a --- /dev/null +++ b/debian/python3-setuptools.install @@ -0,0 +1,4 @@ +usr/lib/python*/*-packages/_distutils_hack +usr/lib/python*/*-packages/_distutils_system_mod.py +usr/lib/python*/*-packages/distutils-precedence.pth +usr/lib/python*/*-packages/setuptools* diff --git a/debian/python3-setuptools.lintian-overrides b/debian/python3-setuptools.lintian-overrides new file mode 100644 index 00000000000..fae1831c164 --- /dev/null +++ b/debian/python3-setuptools.lintian-overrides @@ -0,0 +1,5 @@ +python3-setuptools: copyright-without-copyright-notice +python3-setuptools: initial-upload-closes-no-bugs +python3-setuptools: national-encoding +python3-setuptools: no-manual-page +python3-setuptools: zero-byte-file-in-doc-directory diff --git a/debian/rules b/debian/rules new file mode 100755 index 00000000000..dfdde914db4 --- /dev/null +++ b/debian/rules @@ -0,0 +1,26 @@ +#!/usr/bin/make -f + +SHELL := /bin/bash + +override_dh_auto_build: + dh_auto_build + mkdir -p build/$(shell python3 -c "import sys; print('scripts-%d.%d' % sys.version_info[:2])") + python3 setup.py bdist_wheel + +override_dh_auto_install: + ln -s setuptools/_distutils distutils + PYTHONPATH=. dh_auto_install --destdir=debian/tmp + unlink distutils + install -Dpm644 -t debian/tmp/usr/lib/python*/*-packages _distutils_system_mod.py + install -Dpm755 -d debian/tmp/usr/share/python-wheels + install -Dpm644 -t debian/tmp/usr/share/python-wheels dist/*.whl + rm -rf debian/tmp/usr/lib/python*/*-packages/pkg_resources/tests + find debian/tmp/usr/lib/python*/*-packages -type f -name '*.pyc' -exec rm -rf {} \; + fdupes -qnrps debian/tmp/usr/lib/python*/*-packages + +override_dh_auto_test: + +override_dh_auto_clean: + +%: + dh $@ --buildsystem=pybuild --with python3 diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 00000000000..163aaf8d82b --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (quilt) diff --git a/debian/source/lintian-overrides b/debian/source/lintian-overrides new file mode 100644 index 00000000000..5ae1c36bdf9 --- /dev/null +++ b/debian/source/lintian-overrides @@ -0,0 +1,5 @@ +python-setuptools source: file-without-copyright-information +python-setuptools source: no-debian-changes +python-setuptools source: source-contains-prebuilt-windows-binary +python-setuptools source: source-is-missing +python-setuptools source: source-package-encodes-python-version diff --git a/pkg_resources/__init__.py b/pkg_resources/__init__.py index 74b0465bfa2..dfc830dd018 100644 --- a/pkg_resources/__init__.py +++ b/pkg_resources/__init__.py @@ -87,7 +87,7 @@ import packaging.specifiers import packaging.utils import packaging.version -from jaraco.text import drop_comment, join_continuation, yield_lines +from setuptools._vendor.jaraco.text import drop_comment, join_continuation, yield_lines from platformdirs import user_cache_dir as _user_cache_dir if TYPE_CHECKING: diff --git a/python-setuptools.spec b/python-setuptools.spec new file mode 100644 index 00000000000..d20d3affa2b --- /dev/null +++ b/python-setuptools.spec @@ -0,0 +1,178 @@ +# Copyright 2024 Wong Hoi Sing Edison +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +%global debug_package %{nil} + +%global source_date_epoch_from_changelog 0 + +Name: python-setuptools +Epoch: 100 +Version: 75.4.0 +Release: 1%{?dist} +BuildArch: noarch +Summary: Download, build, install, upgrade, and uninstall Python packages +License: MIT +URL: https://github.com/pypa/setuptools/tags +Source0: %{name}_%{version}.orig.tar.gz +BuildRequires: fdupes +BuildRequires: gcc +BuildRequires: glibc-static +BuildRequires: python-rpm-macros +BuildRequires: python3-devel +BuildRequires: python3-wheel + +%description +setuptools is a collection of enhancements to the Python distutils that +allow you to build and distribute Python packages, especially ones that +have dependencies on other packages. + +%prep +%autosetup -T -c -n %{name}_%{version}-%{release} +tar -zx -f %{S:0} --strip-components=1 -C . + +%build +%py3_build +mkdir -p build/$(python3 -c "import sys; print('scripts-%d.%d' % sys.version_info[:2])") +python3 setup.py bdist_wheel + +%install +ln -s setuptools/_distutils distutils +PYTHONPATH=. %py3_install +unlink distutils +%if 0%{?suse_version} > 1500 +install -Dpm755 -d %{buildroot}%{python3_sitelib}/../wheels +install -Dpm644 -t %{buildroot}%{python3_sitelib}/../wheels dist/*.whl +%endif +%if 0%{?rhel} >= 7 +install -Dpm755 -d %{buildroot}%{_datarootdir}/%{python3_version}-wheels +install -Dpm644 -t %{buildroot}%{_datarootdir}/%{python3_version}-wheels dist/*.whl +%endif +%if !(0%{?suse_version} > 1500) && !(0%{?rhel} >= 7) +install -Dpm755 -d %{buildroot}%{_datarootdir}/python-wheels +install -Dpm644 -t %{buildroot}%{_datarootdir}/python-wheels dist/*.whl +%endif +rm -rf %{buildroot}%{python3_sitelib}/pkg_resources/tests +find %{buildroot}%{python3_sitelib} -type f -name '*.pyc' -exec rm -rf {} \; +fdupes -qnrps %{buildroot}%{python3_sitelib} + +%check + +%if 0%{?suse_version} > 1500 +%package -n python%{python_version_nodots}-setuptools +Summary: Download, build, install, upgrade, and uninstall Python packages +Requires: python3 +Provides: python3-setuptools = %{epoch}:%{version}-%{release} +Provides: python3dist(setuptools) = %{epoch}:%{version}-%{release} +Provides: python%{python3_version}-setuptools = %{epoch}:%{version}-%{release} +Provides: python%{python3_version}dist(setuptools) = %{epoch}:%{version}-%{release} +Provides: python%{python3_version_nodots}-setuptools = %{epoch}:%{version}-%{release} +Provides: python%{python3_version_nodots}dist(setuptools) = %{epoch}:%{version}-%{release} + +%description -n python%{python_version_nodots}-setuptools +setuptools is a collection of enhancements to the Python distutils that +allow you to build and distribute Python packages, especially ones that +have dependencies on other packages. + +%package -n python%{python_version_nodots}-setuptools-wheel +Summary: The setuptools wheel + +%description -n python%{python_version_nodots}-setuptools-wheel +A Python wheel of setuptools to use with venv. + +%files -n python%{python_version_nodots}-setuptools +%license LICENSE +%{python3_sitelib}/* + +%files -n python%{python_version_nodots}-setuptools-wheel +%dir %{python3_sitelib}/../wheels +%{python3_sitelib}/../wheels/*.whl +%endif + +%if 0%{?rhel} >= 7 +%package -n platform-python-setuptools +Summary: Download, build, install, upgrade, and uninstall Python packages +Requires: python3 +Conflicts: platform-python-setuptools < %{epoch}:%{version}-%{release} +Conflicts: python3-setuptools < %{epoch}:%{version}-%{release} + +%description -n platform-python-setuptools +setuptools is a collection of enhancements to the Python distutils that +allow you to build and distribute Python packages, especially ones that +have dependencies on other packages. + +%package -n python3-setuptools +Summary: Download, build, install, upgrade, and uninstall Python packages +Requires: platform-python-setuptools = %{epoch}:%{version}-%{release} +Provides: python3-setuptools = %{epoch}:%{version}-%{release} +Provides: python3dist(setuptools) = %{epoch}:%{version}-%{release} +Provides: python%{python3_version}-setuptools = %{epoch}:%{version}-%{release} +Provides: python%{python3_version}dist(setuptools) = %{epoch}:%{version}-%{release} +Provides: python%{python3_version_nodots}-setuptools = %{epoch}:%{version}-%{release} +Provides: python%{python3_version_nodots}dist(setuptools) = %{epoch}:%{version}-%{release} + +%description -n python3-setuptools +setuptools is a collection of enhancements to the Python distutils that +allow you to build and distribute Python packages, especially ones that +have dependencies on other packages. + +%package -n python3-setuptools-wheel +Summary: The setuptools wheel + +%description -n python3-setuptools-wheel +A Python wheel of setuptools to use with venv. + +%files -n platform-python-setuptools +%license LICENSE +%{python3_sitelib}/* + +%files -n python3-setuptools +%license LICENSE + +%files -n python3-setuptools-wheel +%dir %{_datarootdir}/%{python3_version}-wheels +%{_datarootdir}/%{python3_version}-wheels/*.whl +%endif + +%if !(0%{?suse_version} > 1500) && !(0%{?rhel} >= 7) +%package -n python3-setuptools +Summary: Download, build, install, upgrade, and uninstall Python packages +Requires: python3 +Provides: python3-setuptools = %{epoch}:%{version}-%{release} +Provides: python3dist(setuptools) = %{epoch}:%{version}-%{release} +Provides: python%{python3_version}-setuptools = %{epoch}:%{version}-%{release} +Provides: python%{python3_version}dist(setuptools) = %{epoch}:%{version}-%{release} +Provides: python%{python3_version_nodots}-setuptools = %{epoch}:%{version}-%{release} +Provides: python%{python3_version_nodots}dist(setuptools) = %{epoch}:%{version}-%{release} + +%description -n python3-setuptools +setuptools is a collection of enhancements to the Python distutils that +allow you to build and distribute Python packages, especially ones that +have dependencies on other packages. + +%package -n python-setuptools-wheel +Summary: The setuptools wheel + +%description -n python-setuptools-wheel +A Python wheel of setuptools to use with venv. + +%files -n python3-setuptools +%license LICENSE +%{python3_sitelib}/* + +%files -n python-setuptools-wheel +%dir %{_datarootdir}/python-wheels +%{_datarootdir}/python-wheels/*.whl +%endif + +%changelog diff --git a/setup.cfg b/setup.cfg index 38922089ada..8bfd5a12f85 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,3 +1,4 @@ [egg_info] -tag_build = .post -tag_date = 1 +tag_build = +tag_date = 0 + diff --git a/setuptools.egg-info/PKG-INFO b/setuptools.egg-info/PKG-INFO new file mode 100644 index 00000000000..1f774ae2b9d --- /dev/null +++ b/setuptools.egg-info/PKG-INFO @@ -0,0 +1,143 @@ +Metadata-Version: 2.1 +Name: setuptools +Version: 75.3.0 +Summary: Easily download, build, install, upgrade, and uninstall Python packages +Author-email: Python Packaging Authority +Project-URL: Source, https://github.com/pypa/setuptools +Project-URL: Documentation, https://setuptools.pypa.io/ +Project-URL: Changelog, https://setuptools.pypa.io/en/stable/history.html +Keywords: CPAN PyPI distutils eggs package management +Classifier: Development Status :: 5 - Production/Stable +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: MIT License +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Topic :: Software Development :: Libraries :: Python Modules +Classifier: Topic :: System :: Archiving :: Packaging +Classifier: Topic :: System :: Systems Administration +Classifier: Topic :: Utilities +Requires-Python: >=3.8 +Description-Content-Type: text/x-rst +License-File: LICENSE +Provides-Extra: test +Requires-Dist: build[virtualenv]>=1.0.3; extra == "test" +Requires-Dist: filelock>=3.4.0; extra == "test" +Requires-Dist: ini2toml[lite]>=0.14; extra == "test" +Requires-Dist: jaraco.develop>=7.21; (python_version >= "3.9" and sys_platform != "cygwin") and extra == "test" +Requires-Dist: jaraco.envs>=2.2; extra == "test" +Requires-Dist: jaraco.path>=3.2.0; extra == "test" +Requires-Dist: jaraco.test>=5.5; extra == "test" +Requires-Dist: packaging>=23.2; extra == "test" +Requires-Dist: pip>=19.1; extra == "test" +Requires-Dist: pyproject-hooks!=1.1; extra == "test" +Requires-Dist: pytest!=8.1.*,>=6; extra == "test" +Requires-Dist: pytest-home>=0.5; extra == "test" +Requires-Dist: pytest-perf; sys_platform != "cygwin" and extra == "test" +Requires-Dist: pytest-subprocess; extra == "test" +Requires-Dist: pytest-timeout; extra == "test" +Requires-Dist: pytest-xdist>=3; extra == "test" +Requires-Dist: tomli-w>=1.0.0; extra == "test" +Requires-Dist: virtualenv>=13.0.0; extra == "test" +Requires-Dist: wheel>=0.44.0; extra == "test" +Provides-Extra: doc +Requires-Dist: furo; extra == "doc" +Requires-Dist: jaraco.packaging>=9.3; extra == "doc" +Requires-Dist: jaraco.tidelift>=1.4; extra == "doc" +Requires-Dist: pygments-github-lexers==0.0.5; extra == "doc" +Requires-Dist: pyproject-hooks!=1.1; extra == "doc" +Requires-Dist: rst.linker>=1.9; extra == "doc" +Requires-Dist: sphinx-favicon; extra == "doc" +Requires-Dist: sphinx-inline-tabs; extra == "doc" +Requires-Dist: sphinx-lint; extra == "doc" +Requires-Dist: sphinx-notfound-page<2,>=1; extra == "doc" +Requires-Dist: sphinx-reredirects; extra == "doc" +Requires-Dist: sphinx>=3.5; extra == "doc" +Requires-Dist: sphinxcontrib-towncrier; extra == "doc" +Requires-Dist: towncrier<24.7; extra == "doc" +Provides-Extra: ssl +Provides-Extra: certs +Provides-Extra: core +Requires-Dist: importlib_metadata>=6; python_version < "3.10" and extra == "core" +Requires-Dist: importlib_resources>=5.10.2; python_version < "3.9" and extra == "core" +Requires-Dist: jaraco.collections; extra == "core" +Requires-Dist: jaraco.functools; extra == "core" +Requires-Dist: jaraco.text>=3.7; extra == "core" +Requires-Dist: more_itertools; extra == "core" +Requires-Dist: more_itertools>=8.8; extra == "core" +Requires-Dist: packaging; extra == "core" +Requires-Dist: packaging>=24; extra == "core" +Requires-Dist: platformdirs>=4.2.2; extra == "core" +Requires-Dist: tomli>=2.0.1; python_version < "3.11" and extra == "core" +Requires-Dist: wheel>=0.43.0; extra == "core" +Provides-Extra: check +Requires-Dist: pytest-checkdocs>=2.4; extra == "check" +Requires-Dist: pytest-ruff>=0.2.1; sys_platform != "cygwin" and extra == "check" +Requires-Dist: ruff>=0.5.2; sys_platform != "cygwin" and extra == "check" +Provides-Extra: cover +Requires-Dist: pytest-cov; extra == "cover" +Provides-Extra: enabler +Requires-Dist: pytest-enabler>=2.2; extra == "enabler" +Provides-Extra: type +Requires-Dist: importlib_metadata>=7.0.2; python_version < "3.10" and extra == "type" +Requires-Dist: jaraco.develop>=7.21; sys_platform != "cygwin" and extra == "type" +Requires-Dist: mypy==1.12.*; extra == "type" +Requires-Dist: pytest-mypy; extra == "type" + +.. |pypi-version| image:: https://img.shields.io/pypi/v/setuptools.svg + :target: https://pypi.org/project/setuptools + +.. |py-version| image:: https://img.shields.io/pypi/pyversions/setuptools.svg + +.. |test-badge| image:: https://github.com/pypa/setuptools/actions/workflows/main.yml/badge.svg + :target: https://github.com/pypa/setuptools/actions?query=workflow%3A%22tests%22 + :alt: tests + +.. |ruff-badge| image:: https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json + :target: https://github.com/astral-sh/ruff + :alt: Ruff + +.. |docs-badge| image:: https://img.shields.io/readthedocs/setuptools/latest.svg + :target: https://setuptools.pypa.io + +.. |skeleton-badge| image:: https://img.shields.io/badge/skeleton-2024-informational + :target: https://blog.jaraco.com/skeleton + +.. |codecov-badge| image:: https://img.shields.io/codecov/c/github/pypa/setuptools/master.svg?logo=codecov&logoColor=white + :target: https://codecov.io/gh/pypa/setuptools + +.. |tidelift-badge| image:: https://tidelift.com/badges/github/pypa/setuptools?style=flat + :target: https://tidelift.com/subscription/pkg/pypi-setuptools?utm_source=pypi-setuptools&utm_medium=readme + +.. |discord-badge| image:: https://img.shields.io/discord/803025117553754132 + :target: https://discord.com/channels/803025117553754132/815945031150993468 + :alt: Discord + +|pypi-version| |py-version| |test-badge| |ruff-badge| |docs-badge| |skeleton-badge| |codecov-badge| |discord-badge| + +See the `Quickstart `_ +and the `User's Guide `_ for +instructions on how to use Setuptools. + +Questions and comments should be directed to `GitHub Discussions +`_. +Bug reports and especially tested patches may be +submitted directly to the `bug tracker +`_. + + +Code of Conduct +=============== + +Everyone interacting in the setuptools project's codebases, issue trackers, +chat rooms, and fora is expected to follow the +`PSF Code of Conduct `_. + + +For Enterprise +============== + +Available as part of the Tidelift Subscription. + +Setuptools and the maintainers of thousands of other packages are working with Tidelift to deliver one enterprise subscription that covers all of the open source you use. + +`Learn more `_. diff --git a/setuptools.egg-info/SOURCES.txt b/setuptools.egg-info/SOURCES.txt new file mode 100644 index 00000000000..d9b640a68a4 --- /dev/null +++ b/setuptools.egg-info/SOURCES.txt @@ -0,0 +1,643 @@ +LICENSE +MANIFEST.in +NEWS.rst +README.rst +_distutils_system_mod.py +conftest.py +exercises.py +launcher.c +mypy.ini +pyproject.toml +pytest.ini +setup.cfg +setup.py +tox.ini +.pybuild/cpython3_3.12/build/setuptools/_vendor/autocommand-2.2.2.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/backports.tarfile-1.2.0.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/importlib_metadata-8.0.0.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/importlib_resources-6.4.0.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/inflect-7.3.1.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/jaraco.collections-5.1.0.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/jaraco.context-5.3.0.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/jaraco.functools-4.0.1.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/jaraco.text-3.12.1.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/more_itertools-10.3.0.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/packaging-24.1.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/packaging-24.1.dist-info/LICENSE.APACHE +.pybuild/cpython3_3.12/build/setuptools/_vendor/packaging-24.1.dist-info/LICENSE.BSD +.pybuild/cpython3_3.12/build/setuptools/_vendor/platformdirs-4.2.2.dist-info/licenses/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/tomli-2.0.1.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/typeguard-4.3.0.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/typing_extensions-4.12.2.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/_vendor/wheel-0.43.0.dist-info/LICENSE.txt +.pybuild/cpython3_3.12/build/setuptools/_vendor/zipp-3.19.2.dist-info/LICENSE +.pybuild/cpython3_3.12/build/setuptools/config/NOTICE +.pybuild/cpython3_3.12/build/setuptools/config/_validate_pyproject/NOTICE +_distutils_hack/__init__.py +_distutils_hack/override.py +docs/artwork.rst +docs/build_meta.rst +docs/conf.py +docs/history.rst +docs/index.rst +docs/pkg_resources.rst +docs/python 2 sunset.rst +docs/roadmap.rst +docs/setuptools.rst +docs/deprecated/changed_keywords.rst +docs/deprecated/commands.rst +docs/deprecated/dependency_links.rst +docs/deprecated/distutils-legacy.rst +docs/deprecated/easy_install.rst +docs/deprecated/functionalities.rst +docs/deprecated/index.rst +docs/deprecated/python_eggs.rst +docs/deprecated/resource_extraction.rst +docs/deprecated/zip_safe.rst +docs/deprecated/distutils/_setuptools_disclaimer.rst +docs/deprecated/distutils/apiref.rst +docs/deprecated/distutils/builtdist.rst +docs/deprecated/distutils/commandref.rst +docs/deprecated/distutils/configfile.rst +docs/deprecated/distutils/examples.rst +docs/deprecated/distutils/extending.rst +docs/deprecated/distutils/index.rst +docs/deprecated/distutils/introduction.rst +docs/deprecated/distutils/packageindex.rst +docs/deprecated/distutils/setupscript.rst +docs/deprecated/distutils/sourcedist.rst +docs/deprecated/distutils/uploading.rst +docs/development/developer-guide.rst +docs/development/index.rst +docs/development/releases.rst +docs/references/keywords.rst +docs/userguide/datafiles.rst +docs/userguide/declarative_config.rst +docs/userguide/dependency_management.rst +docs/userguide/development_mode.rst +docs/userguide/distribution.rst +docs/userguide/entry_point.rst +docs/userguide/ext_modules.rst +docs/userguide/extension.rst +docs/userguide/index.rst +docs/userguide/miscellaneous.rst +docs/userguide/package_discovery.rst +docs/userguide/pyproject_config.rst +docs/userguide/quickstart.rst +newsfragments/.gitignore +newsfragments/README.rst +pkg_resources/__init__.py +pkg_resources/api_tests.txt +pkg_resources/py.typed +pkg_resources/tests/__init__.py +pkg_resources/tests/test_find_distributions.py +pkg_resources/tests/test_integration_zope_interface.py +pkg_resources/tests/test_markers.py +pkg_resources/tests/test_pkg_resources.py +pkg_resources/tests/test_resources.py +pkg_resources/tests/test_working_set.py +pkg_resources/tests/data/my-test-package-source/setup.cfg +pkg_resources/tests/data/my-test-package-source/setup.py +pkg_resources/tests/data/my-test-package-zip/my-test-package.zip +pkg_resources/tests/data/my-test-package_unpacked-egg/my_test_package-1.0-py3.7.egg/EGG-INFO/PKG-INFO +pkg_resources/tests/data/my-test-package_unpacked-egg/my_test_package-1.0-py3.7.egg/EGG-INFO/SOURCES.txt +pkg_resources/tests/data/my-test-package_unpacked-egg/my_test_package-1.0-py3.7.egg/EGG-INFO/dependency_links.txt +pkg_resources/tests/data/my-test-package_unpacked-egg/my_test_package-1.0-py3.7.egg/EGG-INFO/top_level.txt +pkg_resources/tests/data/my-test-package_unpacked-egg/my_test_package-1.0-py3.7.egg/EGG-INFO/zip-safe +pkg_resources/tests/data/my-test-package_zipped-egg/my_test_package-1.0-py3.7.egg +setuptools/__init__.py +setuptools/_core_metadata.py +setuptools/_entry_points.py +setuptools/_imp.py +setuptools/_importlib.py +setuptools/_itertools.py +setuptools/_normalization.py +setuptools/_path.py +setuptools/_reqs.py +setuptools/archive_util.py +setuptools/build_meta.py +setuptools/cli-32.exe +setuptools/cli-64.exe +setuptools/cli-arm64.exe +setuptools/cli.exe +setuptools/depends.py +setuptools/discovery.py +setuptools/dist.py +setuptools/errors.py +setuptools/extension.py +setuptools/glob.py +setuptools/gui-32.exe +setuptools/gui-64.exe +setuptools/gui-arm64.exe +setuptools/gui.exe +setuptools/installer.py +setuptools/launch.py +setuptools/logging.py +setuptools/modified.py +setuptools/monkey.py +setuptools/msvc.py +setuptools/namespaces.py +setuptools/package_index.py +setuptools/sandbox.py +setuptools/script (dev).tmpl +setuptools/script.tmpl +setuptools/unicode_utils.py +setuptools/version.py +setuptools/warnings.py +setuptools/wheel.py +setuptools/windows_support.py +setuptools.egg-info/PKG-INFO +setuptools.egg-info/SOURCES.txt +setuptools.egg-info/dependency_links.txt +setuptools.egg-info/entry_points.txt +setuptools.egg-info/requires.txt +setuptools.egg-info/top_level.txt +setuptools/_distutils/__init__.py +setuptools/_distutils/_log.py +setuptools/_distutils/_macos_compat.py +setuptools/_distutils/_modified.py +setuptools/_distutils/_msvccompiler.py +setuptools/_distutils/archive_util.py +setuptools/_distutils/ccompiler.py +setuptools/_distutils/cmd.py +setuptools/_distutils/core.py +setuptools/_distutils/cygwinccompiler.py +setuptools/_distutils/debug.py +setuptools/_distutils/dep_util.py +setuptools/_distutils/dir_util.py +setuptools/_distutils/dist.py +setuptools/_distutils/errors.py +setuptools/_distutils/extension.py +setuptools/_distutils/fancy_getopt.py +setuptools/_distutils/file_util.py +setuptools/_distutils/filelist.py +setuptools/_distutils/log.py +setuptools/_distutils/spawn.py +setuptools/_distutils/sysconfig.py +setuptools/_distutils/text_file.py +setuptools/_distutils/unixccompiler.py +setuptools/_distutils/util.py +setuptools/_distutils/version.py +setuptools/_distutils/versionpredicate.py +setuptools/_distutils/zosccompiler.py +setuptools/_distutils/command/__init__.py +setuptools/_distutils/command/_framework_compat.py +setuptools/_distutils/command/bdist.py +setuptools/_distutils/command/bdist_dumb.py +setuptools/_distutils/command/bdist_rpm.py +setuptools/_distutils/command/build.py +setuptools/_distutils/command/build_clib.py +setuptools/_distutils/command/build_ext.py +setuptools/_distutils/command/build_py.py +setuptools/_distutils/command/build_scripts.py +setuptools/_distutils/command/check.py +setuptools/_distutils/command/clean.py +setuptools/_distutils/command/config.py +setuptools/_distutils/command/install.py +setuptools/_distutils/command/install_data.py +setuptools/_distutils/command/install_egg_info.py +setuptools/_distutils/command/install_headers.py +setuptools/_distutils/command/install_lib.py +setuptools/_distutils/command/install_scripts.py +setuptools/_distutils/command/sdist.py +setuptools/_distutils/compat/__init__.py +setuptools/_distutils/compat/py38.py +setuptools/_distutils/compat/py39.py +setuptools/_distutils/tests/__init__.py +setuptools/_distutils/tests/support.py +setuptools/_distutils/tests/test_archive_util.py +setuptools/_distutils/tests/test_bdist.py +setuptools/_distutils/tests/test_bdist_dumb.py +setuptools/_distutils/tests/test_bdist_rpm.py +setuptools/_distutils/tests/test_build.py +setuptools/_distutils/tests/test_build_clib.py +setuptools/_distutils/tests/test_build_ext.py +setuptools/_distutils/tests/test_build_py.py +setuptools/_distutils/tests/test_build_scripts.py +setuptools/_distutils/tests/test_ccompiler.py +setuptools/_distutils/tests/test_check.py +setuptools/_distutils/tests/test_clean.py +setuptools/_distutils/tests/test_cmd.py +setuptools/_distutils/tests/test_config_cmd.py +setuptools/_distutils/tests/test_core.py +setuptools/_distutils/tests/test_cygwinccompiler.py +setuptools/_distutils/tests/test_dir_util.py +setuptools/_distutils/tests/test_dist.py +setuptools/_distutils/tests/test_extension.py +setuptools/_distutils/tests/test_file_util.py +setuptools/_distutils/tests/test_filelist.py +setuptools/_distutils/tests/test_install.py +setuptools/_distutils/tests/test_install_data.py +setuptools/_distutils/tests/test_install_headers.py +setuptools/_distutils/tests/test_install_lib.py +setuptools/_distutils/tests/test_install_scripts.py +setuptools/_distutils/tests/test_log.py +setuptools/_distutils/tests/test_mingwccompiler.py +setuptools/_distutils/tests/test_modified.py +setuptools/_distutils/tests/test_msvccompiler.py +setuptools/_distutils/tests/test_sdist.py +setuptools/_distutils/tests/test_spawn.py +setuptools/_distutils/tests/test_sysconfig.py +setuptools/_distutils/tests/test_text_file.py +setuptools/_distutils/tests/test_unixccompiler.py +setuptools/_distutils/tests/test_util.py +setuptools/_distutils/tests/test_version.py +setuptools/_distutils/tests/test_versionpredicate.py +setuptools/_distutils/tests/unix_compat.py +setuptools/_distutils/tests/compat/__init__.py +setuptools/_distutils/tests/compat/py38.py +setuptools/_vendor/ruff.toml +setuptools/_vendor/typing_extensions.py +setuptools/_vendor/autocommand/__init__.py +setuptools/_vendor/autocommand/autoasync.py +setuptools/_vendor/autocommand/autocommand.py +setuptools/_vendor/autocommand/automain.py +setuptools/_vendor/autocommand/autoparse.py +setuptools/_vendor/autocommand/errors.py +setuptools/_vendor/autocommand-2.2.2.dist-info/INSTALLER +setuptools/_vendor/autocommand-2.2.2.dist-info/LICENSE +setuptools/_vendor/autocommand-2.2.2.dist-info/METADATA +setuptools/_vendor/autocommand-2.2.2.dist-info/RECORD +setuptools/_vendor/autocommand-2.2.2.dist-info/WHEEL +setuptools/_vendor/autocommand-2.2.2.dist-info/top_level.txt +setuptools/_vendor/backports/__init__.py +setuptools/_vendor/backports.tarfile-1.2.0.dist-info/INSTALLER +setuptools/_vendor/backports.tarfile-1.2.0.dist-info/LICENSE +setuptools/_vendor/backports.tarfile-1.2.0.dist-info/METADATA +setuptools/_vendor/backports.tarfile-1.2.0.dist-info/RECORD +setuptools/_vendor/backports.tarfile-1.2.0.dist-info/REQUESTED +setuptools/_vendor/backports.tarfile-1.2.0.dist-info/WHEEL +setuptools/_vendor/backports.tarfile-1.2.0.dist-info/top_level.txt +setuptools/_vendor/backports/tarfile/__init__.py +setuptools/_vendor/backports/tarfile/__main__.py +setuptools/_vendor/backports/tarfile/compat/__init__.py +setuptools/_vendor/backports/tarfile/compat/py38.py +setuptools/_vendor/importlib_metadata/__init__.py +setuptools/_vendor/importlib_metadata/_adapters.py +setuptools/_vendor/importlib_metadata/_collections.py +setuptools/_vendor/importlib_metadata/_compat.py +setuptools/_vendor/importlib_metadata/_functools.py +setuptools/_vendor/importlib_metadata/_itertools.py +setuptools/_vendor/importlib_metadata/_meta.py +setuptools/_vendor/importlib_metadata/_text.py +setuptools/_vendor/importlib_metadata/diagnose.py +setuptools/_vendor/importlib_metadata/py.typed +setuptools/_vendor/importlib_metadata-8.0.0.dist-info/INSTALLER +setuptools/_vendor/importlib_metadata-8.0.0.dist-info/LICENSE +setuptools/_vendor/importlib_metadata-8.0.0.dist-info/METADATA +setuptools/_vendor/importlib_metadata-8.0.0.dist-info/RECORD +setuptools/_vendor/importlib_metadata-8.0.0.dist-info/REQUESTED +setuptools/_vendor/importlib_metadata-8.0.0.dist-info/WHEEL +setuptools/_vendor/importlib_metadata-8.0.0.dist-info/top_level.txt +setuptools/_vendor/importlib_metadata/compat/__init__.py +setuptools/_vendor/importlib_metadata/compat/py311.py +setuptools/_vendor/importlib_metadata/compat/py39.py +setuptools/_vendor/importlib_resources/__init__.py +setuptools/_vendor/importlib_resources/_adapters.py +setuptools/_vendor/importlib_resources/_common.py +setuptools/_vendor/importlib_resources/_itertools.py +setuptools/_vendor/importlib_resources/abc.py +setuptools/_vendor/importlib_resources/functional.py +setuptools/_vendor/importlib_resources/py.typed +setuptools/_vendor/importlib_resources/readers.py +setuptools/_vendor/importlib_resources/simple.py +setuptools/_vendor/importlib_resources-6.4.0.dist-info/INSTALLER +setuptools/_vendor/importlib_resources-6.4.0.dist-info/LICENSE +setuptools/_vendor/importlib_resources-6.4.0.dist-info/METADATA +setuptools/_vendor/importlib_resources-6.4.0.dist-info/RECORD +setuptools/_vendor/importlib_resources-6.4.0.dist-info/REQUESTED +setuptools/_vendor/importlib_resources-6.4.0.dist-info/WHEEL +setuptools/_vendor/importlib_resources-6.4.0.dist-info/top_level.txt +setuptools/_vendor/importlib_resources/compat/__init__.py +setuptools/_vendor/importlib_resources/compat/py38.py +setuptools/_vendor/importlib_resources/compat/py39.py +setuptools/_vendor/importlib_resources/future/__init__.py +setuptools/_vendor/importlib_resources/future/adapters.py +setuptools/_vendor/importlib_resources/tests/__init__.py +setuptools/_vendor/importlib_resources/tests/_path.py +setuptools/_vendor/importlib_resources/tests/test_compatibilty_files.py +setuptools/_vendor/importlib_resources/tests/test_contents.py +setuptools/_vendor/importlib_resources/tests/test_custom.py +setuptools/_vendor/importlib_resources/tests/test_files.py +setuptools/_vendor/importlib_resources/tests/test_functional.py +setuptools/_vendor/importlib_resources/tests/test_open.py +setuptools/_vendor/importlib_resources/tests/test_path.py +setuptools/_vendor/importlib_resources/tests/test_read.py +setuptools/_vendor/importlib_resources/tests/test_reader.py +setuptools/_vendor/importlib_resources/tests/test_resource.py +setuptools/_vendor/importlib_resources/tests/util.py +setuptools/_vendor/importlib_resources/tests/zip.py +setuptools/_vendor/importlib_resources/tests/compat/__init__.py +setuptools/_vendor/importlib_resources/tests/compat/py312.py +setuptools/_vendor/importlib_resources/tests/compat/py39.py +setuptools/_vendor/importlib_resources/tests/data01/__init__.py +setuptools/_vendor/importlib_resources/tests/data01/binary.file +setuptools/_vendor/importlib_resources/tests/data01/utf-16.file +setuptools/_vendor/importlib_resources/tests/data01/utf-8.file +setuptools/_vendor/importlib_resources/tests/data01/subdirectory/__init__.py +setuptools/_vendor/importlib_resources/tests/data01/subdirectory/binary.file +setuptools/_vendor/importlib_resources/tests/data02/__init__.py +setuptools/_vendor/importlib_resources/tests/data02/one/__init__.py +setuptools/_vendor/importlib_resources/tests/data02/one/resource1.txt +setuptools/_vendor/importlib_resources/tests/data02/subdirectory/subsubdir/resource.txt +setuptools/_vendor/importlib_resources/tests/data02/two/__init__.py +setuptools/_vendor/importlib_resources/tests/data02/two/resource2.txt +setuptools/_vendor/importlib_resources/tests/namespacedata01/binary.file +setuptools/_vendor/importlib_resources/tests/namespacedata01/utf-16.file +setuptools/_vendor/importlib_resources/tests/namespacedata01/utf-8.file +setuptools/_vendor/importlib_resources/tests/namespacedata01/subdirectory/binary.file +setuptools/_vendor/inflect/__init__.py +setuptools/_vendor/inflect/py.typed +setuptools/_vendor/inflect-7.3.1.dist-info/INSTALLER +setuptools/_vendor/inflect-7.3.1.dist-info/LICENSE +setuptools/_vendor/inflect-7.3.1.dist-info/METADATA +setuptools/_vendor/inflect-7.3.1.dist-info/RECORD +setuptools/_vendor/inflect-7.3.1.dist-info/WHEEL +setuptools/_vendor/inflect-7.3.1.dist-info/top_level.txt +setuptools/_vendor/inflect/compat/__init__.py +setuptools/_vendor/inflect/compat/py38.py +setuptools/_vendor/jaraco/context.py +setuptools/_vendor/jaraco.collections-5.1.0.dist-info/INSTALLER +setuptools/_vendor/jaraco.collections-5.1.0.dist-info/LICENSE +setuptools/_vendor/jaraco.collections-5.1.0.dist-info/METADATA +setuptools/_vendor/jaraco.collections-5.1.0.dist-info/RECORD +setuptools/_vendor/jaraco.collections-5.1.0.dist-info/REQUESTED +setuptools/_vendor/jaraco.collections-5.1.0.dist-info/WHEEL +setuptools/_vendor/jaraco.collections-5.1.0.dist-info/top_level.txt +setuptools/_vendor/jaraco.context-5.3.0.dist-info/INSTALLER +setuptools/_vendor/jaraco.context-5.3.0.dist-info/LICENSE +setuptools/_vendor/jaraco.context-5.3.0.dist-info/METADATA +setuptools/_vendor/jaraco.context-5.3.0.dist-info/RECORD +setuptools/_vendor/jaraco.context-5.3.0.dist-info/WHEEL +setuptools/_vendor/jaraco.context-5.3.0.dist-info/top_level.txt +setuptools/_vendor/jaraco.functools-4.0.1.dist-info/INSTALLER +setuptools/_vendor/jaraco.functools-4.0.1.dist-info/LICENSE +setuptools/_vendor/jaraco.functools-4.0.1.dist-info/METADATA +setuptools/_vendor/jaraco.functools-4.0.1.dist-info/RECORD +setuptools/_vendor/jaraco.functools-4.0.1.dist-info/WHEEL +setuptools/_vendor/jaraco.functools-4.0.1.dist-info/top_level.txt +setuptools/_vendor/jaraco.text-3.12.1.dist-info/INSTALLER +setuptools/_vendor/jaraco.text-3.12.1.dist-info/LICENSE +setuptools/_vendor/jaraco.text-3.12.1.dist-info/METADATA +setuptools/_vendor/jaraco.text-3.12.1.dist-info/RECORD +setuptools/_vendor/jaraco.text-3.12.1.dist-info/REQUESTED +setuptools/_vendor/jaraco.text-3.12.1.dist-info/WHEEL +setuptools/_vendor/jaraco.text-3.12.1.dist-info/top_level.txt +setuptools/_vendor/jaraco/collections/__init__.py +setuptools/_vendor/jaraco/collections/py.typed +setuptools/_vendor/jaraco/functools/__init__.py +setuptools/_vendor/jaraco/functools/__init__.pyi +setuptools/_vendor/jaraco/functools/py.typed +setuptools/_vendor/jaraco/text/Lorem ipsum.txt +setuptools/_vendor/jaraco/text/__init__.py +setuptools/_vendor/jaraco/text/layouts.py +setuptools/_vendor/jaraco/text/show-newlines.py +setuptools/_vendor/jaraco/text/strip-prefix.py +setuptools/_vendor/jaraco/text/to-dvorak.py +setuptools/_vendor/jaraco/text/to-qwerty.py +setuptools/_vendor/more_itertools/__init__.py +setuptools/_vendor/more_itertools/__init__.pyi +setuptools/_vendor/more_itertools/more.py +setuptools/_vendor/more_itertools/more.pyi +setuptools/_vendor/more_itertools/py.typed +setuptools/_vendor/more_itertools/recipes.py +setuptools/_vendor/more_itertools/recipes.pyi +setuptools/_vendor/more_itertools-10.3.0.dist-info/INSTALLER +setuptools/_vendor/more_itertools-10.3.0.dist-info/LICENSE +setuptools/_vendor/more_itertools-10.3.0.dist-info/METADATA +setuptools/_vendor/more_itertools-10.3.0.dist-info/RECORD +setuptools/_vendor/more_itertools-10.3.0.dist-info/REQUESTED +setuptools/_vendor/more_itertools-10.3.0.dist-info/WHEEL +setuptools/_vendor/packaging/__init__.py +setuptools/_vendor/packaging/_elffile.py +setuptools/_vendor/packaging/_manylinux.py +setuptools/_vendor/packaging/_musllinux.py +setuptools/_vendor/packaging/_parser.py +setuptools/_vendor/packaging/_structures.py +setuptools/_vendor/packaging/_tokenizer.py +setuptools/_vendor/packaging/markers.py +setuptools/_vendor/packaging/metadata.py +setuptools/_vendor/packaging/py.typed +setuptools/_vendor/packaging/requirements.py +setuptools/_vendor/packaging/specifiers.py +setuptools/_vendor/packaging/tags.py +setuptools/_vendor/packaging/utils.py +setuptools/_vendor/packaging/version.py +setuptools/_vendor/packaging-24.1.dist-info/INSTALLER +setuptools/_vendor/packaging-24.1.dist-info/LICENSE +setuptools/_vendor/packaging-24.1.dist-info/LICENSE.APACHE +setuptools/_vendor/packaging-24.1.dist-info/LICENSE.BSD +setuptools/_vendor/packaging-24.1.dist-info/METADATA +setuptools/_vendor/packaging-24.1.dist-info/RECORD +setuptools/_vendor/packaging-24.1.dist-info/REQUESTED +setuptools/_vendor/packaging-24.1.dist-info/WHEEL +setuptools/_vendor/platformdirs/__init__.py +setuptools/_vendor/platformdirs/__main__.py +setuptools/_vendor/platformdirs/android.py +setuptools/_vendor/platformdirs/api.py +setuptools/_vendor/platformdirs/macos.py +setuptools/_vendor/platformdirs/py.typed +setuptools/_vendor/platformdirs/unix.py +setuptools/_vendor/platformdirs/version.py +setuptools/_vendor/platformdirs/windows.py +setuptools/_vendor/platformdirs-4.2.2.dist-info/INSTALLER +setuptools/_vendor/platformdirs-4.2.2.dist-info/METADATA +setuptools/_vendor/platformdirs-4.2.2.dist-info/RECORD +setuptools/_vendor/platformdirs-4.2.2.dist-info/REQUESTED +setuptools/_vendor/platformdirs-4.2.2.dist-info/WHEEL +setuptools/_vendor/platformdirs-4.2.2.dist-info/licenses/LICENSE +setuptools/_vendor/tomli/__init__.py +setuptools/_vendor/tomli/_parser.py +setuptools/_vendor/tomli/_re.py +setuptools/_vendor/tomli/_types.py +setuptools/_vendor/tomli/py.typed +setuptools/_vendor/tomli-2.0.1.dist-info/INSTALLER +setuptools/_vendor/tomli-2.0.1.dist-info/LICENSE +setuptools/_vendor/tomli-2.0.1.dist-info/METADATA +setuptools/_vendor/tomli-2.0.1.dist-info/RECORD +setuptools/_vendor/tomli-2.0.1.dist-info/REQUESTED +setuptools/_vendor/tomli-2.0.1.dist-info/WHEEL +setuptools/_vendor/typeguard/__init__.py +setuptools/_vendor/typeguard/_checkers.py +setuptools/_vendor/typeguard/_config.py +setuptools/_vendor/typeguard/_decorators.py +setuptools/_vendor/typeguard/_exceptions.py +setuptools/_vendor/typeguard/_functions.py +setuptools/_vendor/typeguard/_importhook.py +setuptools/_vendor/typeguard/_memo.py +setuptools/_vendor/typeguard/_pytest_plugin.py +setuptools/_vendor/typeguard/_suppression.py +setuptools/_vendor/typeguard/_transformer.py +setuptools/_vendor/typeguard/_union_transformer.py +setuptools/_vendor/typeguard/_utils.py +setuptools/_vendor/typeguard/py.typed +setuptools/_vendor/typeguard-4.3.0.dist-info/INSTALLER +setuptools/_vendor/typeguard-4.3.0.dist-info/LICENSE +setuptools/_vendor/typeguard-4.3.0.dist-info/METADATA +setuptools/_vendor/typeguard-4.3.0.dist-info/RECORD +setuptools/_vendor/typeguard-4.3.0.dist-info/WHEEL +setuptools/_vendor/typeguard-4.3.0.dist-info/entry_points.txt +setuptools/_vendor/typeguard-4.3.0.dist-info/top_level.txt +setuptools/_vendor/typing_extensions-4.12.2.dist-info/INSTALLER +setuptools/_vendor/typing_extensions-4.12.2.dist-info/LICENSE +setuptools/_vendor/typing_extensions-4.12.2.dist-info/METADATA +setuptools/_vendor/typing_extensions-4.12.2.dist-info/RECORD +setuptools/_vendor/typing_extensions-4.12.2.dist-info/WHEEL +setuptools/_vendor/wheel/__init__.py +setuptools/_vendor/wheel/__main__.py +setuptools/_vendor/wheel/_setuptools_logging.py +setuptools/_vendor/wheel/bdist_wheel.py +setuptools/_vendor/wheel/macosx_libfile.py +setuptools/_vendor/wheel/metadata.py +setuptools/_vendor/wheel/util.py +setuptools/_vendor/wheel/wheelfile.py +setuptools/_vendor/wheel-0.43.0.dist-info/INSTALLER +setuptools/_vendor/wheel-0.43.0.dist-info/LICENSE.txt +setuptools/_vendor/wheel-0.43.0.dist-info/METADATA +setuptools/_vendor/wheel-0.43.0.dist-info/RECORD +setuptools/_vendor/wheel-0.43.0.dist-info/REQUESTED +setuptools/_vendor/wheel-0.43.0.dist-info/WHEEL +setuptools/_vendor/wheel-0.43.0.dist-info/entry_points.txt +setuptools/_vendor/wheel/cli/__init__.py +setuptools/_vendor/wheel/cli/convert.py +setuptools/_vendor/wheel/cli/pack.py +setuptools/_vendor/wheel/cli/tags.py +setuptools/_vendor/wheel/cli/unpack.py +setuptools/_vendor/wheel/vendored/__init__.py +setuptools/_vendor/wheel/vendored/vendor.txt +setuptools/_vendor/wheel/vendored/packaging/__init__.py +setuptools/_vendor/wheel/vendored/packaging/_elffile.py +setuptools/_vendor/wheel/vendored/packaging/_manylinux.py +setuptools/_vendor/wheel/vendored/packaging/_musllinux.py +setuptools/_vendor/wheel/vendored/packaging/_parser.py +setuptools/_vendor/wheel/vendored/packaging/_structures.py +setuptools/_vendor/wheel/vendored/packaging/_tokenizer.py +setuptools/_vendor/wheel/vendored/packaging/markers.py +setuptools/_vendor/wheel/vendored/packaging/requirements.py +setuptools/_vendor/wheel/vendored/packaging/specifiers.py +setuptools/_vendor/wheel/vendored/packaging/tags.py +setuptools/_vendor/wheel/vendored/packaging/utils.py +setuptools/_vendor/wheel/vendored/packaging/version.py +setuptools/_vendor/zipp/__init__.py +setuptools/_vendor/zipp/glob.py +setuptools/_vendor/zipp-3.19.2.dist-info/INSTALLER +setuptools/_vendor/zipp-3.19.2.dist-info/LICENSE +setuptools/_vendor/zipp-3.19.2.dist-info/METADATA +setuptools/_vendor/zipp-3.19.2.dist-info/RECORD +setuptools/_vendor/zipp-3.19.2.dist-info/REQUESTED +setuptools/_vendor/zipp-3.19.2.dist-info/WHEEL +setuptools/_vendor/zipp-3.19.2.dist-info/top_level.txt +setuptools/_vendor/zipp/compat/__init__.py +setuptools/_vendor/zipp/compat/py310.py +setuptools/command/__init__.py +setuptools/command/_requirestxt.py +setuptools/command/alias.py +setuptools/command/bdist_egg.py +setuptools/command/bdist_rpm.py +setuptools/command/bdist_wheel.py +setuptools/command/build.py +setuptools/command/build_clib.py +setuptools/command/build_ext.py +setuptools/command/build_py.py +setuptools/command/develop.py +setuptools/command/dist_info.py +setuptools/command/easy_install.py +setuptools/command/editable_wheel.py +setuptools/command/egg_info.py +setuptools/command/install.py +setuptools/command/install_egg_info.py +setuptools/command/install_lib.py +setuptools/command/install_scripts.py +setuptools/command/launcher manifest.xml +setuptools/command/rotate.py +setuptools/command/saveopts.py +setuptools/command/sdist.py +setuptools/command/setopt.py +setuptools/command/test.py +setuptools/compat/__init__.py +setuptools/compat/py310.py +setuptools/compat/py311.py +setuptools/compat/py312.py +setuptools/compat/py39.py +setuptools/config/NOTICE +setuptools/config/__init__.py +setuptools/config/_apply_pyprojecttoml.py +setuptools/config/distutils.schema.json +setuptools/config/expand.py +setuptools/config/pyprojecttoml.py +setuptools/config/setupcfg.py +setuptools/config/setuptools.schema.json +setuptools/config/_validate_pyproject/NOTICE +setuptools/config/_validate_pyproject/__init__.py +setuptools/config/_validate_pyproject/error_reporting.py +setuptools/config/_validate_pyproject/extra_validations.py +setuptools/config/_validate_pyproject/fastjsonschema_exceptions.py +setuptools/config/_validate_pyproject/fastjsonschema_validations.py +setuptools/config/_validate_pyproject/formats.py +setuptools/tests/__init__.py +setuptools/tests/contexts.py +setuptools/tests/environment.py +setuptools/tests/fixtures.py +setuptools/tests/mod_with_constant.py +setuptools/tests/namespaces.py +setuptools/tests/script-with-bom.py +setuptools/tests/server.py +setuptools/tests/test_archive_util.py +setuptools/tests/test_bdist_deprecations.py +setuptools/tests/test_bdist_egg.py +setuptools/tests/test_bdist_wheel.py +setuptools/tests/test_build.py +setuptools/tests/test_build_clib.py +setuptools/tests/test_build_ext.py +setuptools/tests/test_build_meta.py +setuptools/tests/test_build_py.py +setuptools/tests/test_config_discovery.py +setuptools/tests/test_core_metadata.py +setuptools/tests/test_depends.py +setuptools/tests/test_develop.py +setuptools/tests/test_dist.py +setuptools/tests/test_dist_info.py +setuptools/tests/test_distutils_adoption.py +setuptools/tests/test_easy_install.py +setuptools/tests/test_editable_install.py +setuptools/tests/test_egg_info.py +setuptools/tests/test_extern.py +setuptools/tests/test_find_packages.py +setuptools/tests/test_find_py_modules.py +setuptools/tests/test_glob.py +setuptools/tests/test_install_scripts.py +setuptools/tests/test_logging.py +setuptools/tests/test_manifest.py +setuptools/tests/test_namespaces.py +setuptools/tests/test_packageindex.py +setuptools/tests/test_sandbox.py +setuptools/tests/test_sdist.py +setuptools/tests/test_setopt.py +setuptools/tests/test_setuptools.py +setuptools/tests/test_unicode_utils.py +setuptools/tests/test_virtualenv.py +setuptools/tests/test_warnings.py +setuptools/tests/test_wheel.py +setuptools/tests/test_windows_wrappers.py +setuptools/tests/text.py +setuptools/tests/textwrap.py +setuptools/tests/compat/__init__.py +setuptools/tests/compat/py39.py +setuptools/tests/config/__init__.py +setuptools/tests/config/setupcfg_examples.txt +setuptools/tests/config/test_apply_pyprojecttoml.py +setuptools/tests/config/test_expand.py +setuptools/tests/config/test_pyprojecttoml.py +setuptools/tests/config/test_pyprojecttoml_dynamic_deps.py +setuptools/tests/config/test_setupcfg.py +setuptools/tests/config/downloads/__init__.py +setuptools/tests/config/downloads/preload.py +setuptools/tests/indexes/test_links_priority/external.html +setuptools/tests/indexes/test_links_priority/simple/foobar/index.html +setuptools/tests/integration/__init__.py +setuptools/tests/integration/helpers.py +setuptools/tests/integration/test_pip_install_sdist.py +tools/build_launchers.py +tools/finalize.py +tools/generate_validation_code.py +tools/vendored.py \ No newline at end of file diff --git a/setuptools.egg-info/dependency_links.txt b/setuptools.egg-info/dependency_links.txt new file mode 100644 index 00000000000..8b137891791 --- /dev/null +++ b/setuptools.egg-info/dependency_links.txt @@ -0,0 +1 @@ + diff --git a/setuptools.egg-info/entry_points.txt b/setuptools.egg-info/entry_points.txt new file mode 100644 index 00000000000..0db0a6c8f1b --- /dev/null +++ b/setuptools.egg-info/entry_points.txt @@ -0,0 +1,51 @@ +[distutils.commands] +alias = setuptools.command.alias:alias +bdist_egg = setuptools.command.bdist_egg:bdist_egg +bdist_rpm = setuptools.command.bdist_rpm:bdist_rpm +bdist_wheel = setuptools.command.bdist_wheel:bdist_wheel +build = setuptools.command.build:build +build_clib = setuptools.command.build_clib:build_clib +build_ext = setuptools.command.build_ext:build_ext +build_py = setuptools.command.build_py:build_py +develop = setuptools.command.develop:develop +dist_info = setuptools.command.dist_info:dist_info +easy_install = setuptools.command.easy_install:easy_install +editable_wheel = setuptools.command.editable_wheel:editable_wheel +egg_info = setuptools.command.egg_info:egg_info +install = setuptools.command.install:install +install_egg_info = setuptools.command.install_egg_info:install_egg_info +install_lib = setuptools.command.install_lib:install_lib +install_scripts = setuptools.command.install_scripts:install_scripts +rotate = setuptools.command.rotate:rotate +saveopts = setuptools.command.saveopts:saveopts +sdist = setuptools.command.sdist:sdist +setopt = setuptools.command.setopt:setopt + +[distutils.setup_keywords] +dependency_links = setuptools.dist:assert_string_list +eager_resources = setuptools.dist:assert_string_list +entry_points = setuptools.dist:check_entry_points +exclude_package_data = setuptools.dist:check_package_data +extras_require = setuptools.dist:check_extras +include_package_data = setuptools.dist:assert_bool +install_requires = setuptools.dist:check_requirements +namespace_packages = setuptools.dist:check_nsp +package_data = setuptools.dist:check_package_data +packages = setuptools.dist:check_packages +python_requires = setuptools.dist:check_specifier +setup_requires = setuptools.dist:check_requirements +use_2to3 = setuptools.dist:invalid_unless_false +zip_safe = setuptools.dist:assert_bool + +[egg_info.writers] +PKG-INFO = setuptools.command.egg_info:write_pkg_info +dependency_links.txt = setuptools.command.egg_info:overwrite_arg +eager_resources.txt = setuptools.command.egg_info:overwrite_arg +entry_points.txt = setuptools.command.egg_info:write_entries +namespace_packages.txt = setuptools.command.egg_info:overwrite_arg +requires.txt = setuptools.command.egg_info:write_requirements +top_level.txt = setuptools.command.egg_info:write_toplevel_names + +[setuptools.finalize_distribution_options] +keywords = setuptools.dist:Distribution._finalize_setup_keywords +parent_finalize = setuptools.dist:_Distribution.finalize_options diff --git a/setuptools.egg-info/requires.txt b/setuptools.egg-info/requires.txt new file mode 100644 index 00000000000..c1c54a403ed --- /dev/null +++ b/setuptools.egg-info/requires.txt @@ -0,0 +1,88 @@ + +[certs] + +[check] +pytest-checkdocs>=2.4 + +[check:sys_platform != "cygwin"] +pytest-ruff>=0.2.1 +ruff>=0.5.2 + +[core] +jaraco.collections +jaraco.functools +jaraco.text>=3.7 +more_itertools +more_itertools>=8.8 +packaging +packaging>=24 +platformdirs>=4.2.2 +wheel>=0.43.0 + +[core:python_version < "3.10"] +importlib_metadata>=6 + +[core:python_version < "3.11"] +tomli>=2.0.1 + +[core:python_version < "3.9"] +importlib_resources>=5.10.2 + +[cover] +pytest-cov + +[doc] +furo +jaraco.packaging>=9.3 +jaraco.tidelift>=1.4 +pygments-github-lexers==0.0.5 +pyproject-hooks!=1.1 +rst.linker>=1.9 +sphinx-favicon +sphinx-inline-tabs +sphinx-lint +sphinx-notfound-page<2,>=1 +sphinx-reredirects +sphinx>=3.5 +sphinxcontrib-towncrier +towncrier<24.7 + +[enabler] +pytest-enabler>=2.2 + +[ssl] + +[test] +build[virtualenv]>=1.0.3 +filelock>=3.4.0 +ini2toml[lite]>=0.14 +jaraco.envs>=2.2 +jaraco.path>=3.2.0 +jaraco.test>=5.5 +packaging>=23.2 +pip>=19.1 +pyproject-hooks!=1.1 +pytest!=8.1.*,>=6 +pytest-home>=0.5 +pytest-subprocess +pytest-timeout +pytest-xdist>=3 +tomli-w>=1.0.0 +virtualenv>=13.0.0 +wheel>=0.44.0 + +[test:python_version >= "3.9" and sys_platform != "cygwin"] +jaraco.develop>=7.21 + +[test:sys_platform != "cygwin"] +pytest-perf + +[type] +mypy==1.12.* +pytest-mypy + +[type:python_version < "3.10"] +importlib_metadata>=7.0.2 + +[type:sys_platform != "cygwin"] +jaraco.develop>=7.21 diff --git a/setuptools.egg-info/top_level.txt b/setuptools.egg-info/top_level.txt new file mode 100644 index 00000000000..b5ac1070294 --- /dev/null +++ b/setuptools.egg-info/top_level.txt @@ -0,0 +1,3 @@ +_distutils_hack +pkg_resources +setuptools diff --git a/setuptools/_distutils/_modified.py b/setuptools/_distutils/_modified.py index 7cdca9398f4..cfa34e1ae2f 100644 --- a/setuptools/_distutils/_modified.py +++ b/setuptools/_distutils/_modified.py @@ -3,7 +3,7 @@ import functools import os.path -from jaraco.functools import splat +from setuptools._vendor.jaraco.functools import splat from .compat.py39 import zip_strict from .errors import DistutilsFileError diff --git a/setuptools/_distutils/sysconfig.py b/setuptools/_distutils/sysconfig.py index da1eecbe7e4..9e0eb4e45f6 100644 --- a/setuptools/_distutils/sysconfig.py +++ b/setuptools/_distutils/sysconfig.py @@ -16,7 +16,7 @@ import sys import sysconfig -from jaraco.functools import pass_none +from setuptools._vendor.jaraco.functools import pass_none from .compat import py39 from .errors import DistutilsPlatformError diff --git a/setuptools/_distutils/tests/test_sysconfig.py b/setuptools/_distutils/tests/test_sysconfig.py index 49274a36aea..309e057d8a9 100644 --- a/setuptools/_distutils/tests/test_sysconfig.py +++ b/setuptools/_distutils/tests/test_sysconfig.py @@ -13,7 +13,7 @@ import jaraco.envs import path import pytest -from jaraco.text import trim +from setuptools._vendor.jaraco.text import trim from test.support import swap_item diff --git a/setuptools/_distutils/util.py b/setuptools/_distutils/util.py index 609c1a50cdd..e98b73269cb 100644 --- a/setuptools/_distutils/util.py +++ b/setuptools/_distutils/util.py @@ -17,7 +17,7 @@ import sysconfig import tempfile -from jaraco.functools import pass_none +from setuptools._vendor.jaraco.functools import pass_none from ._log import log from ._modified import newer diff --git a/setuptools/_entry_points.py b/setuptools/_entry_points.py index e785fc7df8d..ca9390187e7 100644 --- a/setuptools/_entry_points.py +++ b/setuptools/_entry_points.py @@ -2,8 +2,8 @@ import itertools import operator -from jaraco.functools import pass_none -from jaraco.text import yield_lines +from setuptools._vendor.jaraco.functools import pass_none +from setuptools._vendor.jaraco.text import yield_lines from more_itertools import consume from ._importlib import metadata diff --git a/setuptools/_vendor/jaraco/text/strip-prefix.py b/setuptools/_vendor/jaraco/text/strip-prefix.py index 761717a9b9e..5750e8be4f8 100644 --- a/setuptools/_vendor/jaraco/text/strip-prefix.py +++ b/setuptools/_vendor/jaraco/text/strip-prefix.py @@ -2,7 +2,7 @@ import autocommand -from jaraco.text import Stripper +from setuptools._vendor.jaraco.text import Stripper def strip_prefix(): diff --git a/setuptools/command/_requirestxt.py b/setuptools/command/_requirestxt.py index 171f41b87ee..ebd8ab0fc31 100644 --- a/setuptools/command/_requirestxt.py +++ b/setuptools/command/_requirestxt.py @@ -15,7 +15,7 @@ from itertools import filterfalse from typing import TypeVar -from jaraco.text import yield_lines +from setuptools._vendor.jaraco.text import yield_lines from packaging.requirements import Requirement from .. import _reqs diff --git a/setuptools/command/easy_install.py b/setuptools/command/easy_install.py index b40610f8ba2..e738cee6346 100644 --- a/setuptools/command/easy_install.py +++ b/setuptools/command/easy_install.py @@ -36,7 +36,7 @@ from sysconfig import get_path from typing import TYPE_CHECKING, NoReturn, TypedDict -from jaraco.text import yield_lines +from setuptools._vendor.jaraco.text import yield_lines import pkg_resources from pkg_resources import ( diff --git a/setuptools/monkey.py b/setuptools/monkey.py index 07919722b8a..d456ae5774d 100644 --- a/setuptools/monkey.py +++ b/setuptools/monkey.py @@ -89,6 +89,8 @@ def patch_all(): 'distutils.command.build_ext' ].Extension = setuptools.extension.Extension + patch_for_msvc_specialized_compiler() + def _patch_distribution_metadata(): from . import _core_metadata @@ -124,3 +126,36 @@ def patch_func(replacement, target_mod, func_name): def get_unpatched_function(candidate): return candidate.unpatched + + +def patch_for_msvc_specialized_compiler(): + """ + Patch functions in distutils to use standalone Microsoft Visual C++ + compilers. + """ + from . import msvc + + if platform.system() != 'Windows': + # Compilers only available on Microsoft Windows + return + + def patch_params(mod_name, func_name): + """ + Prepare the parameters for patch_func to patch indicated function. + """ + repl_prefix = 'msvc14_' + repl_name = repl_prefix + func_name.lstrip('_') + repl = getattr(msvc, repl_name) + mod = import_module(mod_name) + if not hasattr(mod, func_name): + raise ImportError(func_name) + return repl, mod, func_name + + # Python 3.5+ + msvc14 = functools.partial(patch_params, 'distutils._msvccompiler') + + try: + # Patch distutils._msvccompiler._get_vc_env + patch_func(*msvc14('_get_vc_env')) + except ImportError: + pass