summaryrefslogtreecommitdiff
path: root/multilib.patch
diff options
context:
space:
mode:
authorJan Palus2022-01-12 18:33:23 (GMT)
committerJan Palus2022-01-12 18:34:52 (GMT)
commitb9bca61ecbd51c84d7d0e7853aa46356dbe8b881 (patch)
tree1c21e8fd16d25fe32e44ccecd939787d5e8784f8 /multilib.patch
parentb58ce4a6740a8e7bae124a48eca07b2e1f6cdf4f (diff)
downloadpython-virtualenv-b9bca61ecbd51c84d7d0e7853aa46356dbe8b881.zip
python-virtualenv-b9bca61ecbd51c84d7d0e7853aa46356dbe8b881.tar.gz
up to 20.13.0
- project structure/logic changed - disable docs by default: requires manual sphinx invocation and doc dependencies update
Diffstat (limited to 'multilib.patch')
-rw-r--r--multilib.patch107
1 files changed, 0 insertions, 107 deletions
diff --git a/multilib.patch b/multilib.patch
deleted file mode 100644
index 84dd1ba..0000000
--- a/multilib.patch
+++ /dev/null
@@ -1,107 +0,0 @@
---- virtualenv-15.0.1/virtualenv.py~ 2016-03-17 16:16:07.000000000 +0100
-+++ virtualenv-15.0.1/virtualenv.py 2016-10-18 22:48:47.174956732 +0200
-@@ -1094,7 +1094,7 @@
- else:
- prefix = sys.prefix
- mkdir(lib_dir)
-- fix_lib64(lib_dir, symlink)
-+ fix_libarch(lib_dir, symlink)
- stdlib_dirs = [os.path.dirname(os.__file__)]
- if is_win:
- stdlib_dirs.append(join(os.path.dirname(stdlib_dirs[0]), 'DLLs'))
-@@ -1498,7 +1498,7 @@
- copyfile(os.path.abspath(os.path.join(home_dir, subdir_name)), \
- os.path.join(local_path, subdir_name), symlink)
-
--def fix_lib64(lib_dir, symlink=True):
-+def fix_libarch(lib_dir, symlink=True):
- """
- Some platforms (particularly Gentoo on x64) put things in lib64/pythonX.Y
- instead of lib/pythonX.Y. If this is such a platform we'll just create a
-@@ -1507,29 +1507,37 @@
- # PyPy's library path scheme is not affected by this.
- # Return early or we will die on the following assert.
- if is_pypy:
-- logger.debug('PyPy detected, skipping lib64 symlinking')
-+ logger.debug('PyPy detected, skipping lib64/libx32 symlinking')
- return
-- # Check we have a lib64 library path
-- if not [p for p in distutils.sysconfig.get_config_vars().values()
-+ lib_arch = None
-+ # Check we have a lib64 or libx32 library path
-+ if [p for p in distutils.sysconfig.get_config_vars().values()
-+ if isinstance(p, basestring) and 'libx32' in p]:
-+ lib_arch = 'libx32'
-+
-+ if [p for p in distutils.sysconfig.get_config_vars().values()
- if isinstance(p, basestring) and 'lib64' in p]:
-+ lib_arch = 'lib64'
-+
-+ if not lib_arch:
- return
-
-- logger.debug('This system uses lib64; symlinking lib64 to lib')
-+ logger.debug('This system uses %s; symlinking %s to lib', lib_arch, lib_arch)
-
- assert os.path.basename(lib_dir) == 'python%s' % sys.version[:3], (
- "Unexpected python lib dir: %r" % lib_dir)
- lib_parent = os.path.dirname(lib_dir)
- top_level = os.path.dirname(lib_parent)
- lib_dir = os.path.join(top_level, 'lib')
-- lib64_link = os.path.join(top_level, 'lib64')
-+ libarch_link = os.path.join(top_level, lib_arch)
- assert os.path.basename(lib_parent) == 'lib', (
- "Unexpected parent dir: %r" % lib_parent)
-- if os.path.lexists(lib64_link):
-+ if os.path.lexists(libarch_link):
- return
-- if symlink:
-- os.symlink('lib', lib64_link)
-+ if True:
-+ os.symlink('lib', libarch_link)
- else:
-- copyfile('lib', lib64_link)
-+ copyfile('lib', libarch_link)
-
- def resolve_interpreter(exe):
- """
---- virtualenv-15.0.1/virtualenv_support/site.py~ 2016-10-19 09:09:07.000000000 +0200
-+++ virtualenv-15.0.1/virtualenv_support/site.py 2016-10-19 09:11:26.681732254 +0200
-@@ -243,6 +243,13 @@
- sitedirs.insert(0, lib64_dir)
- else:
- sitedirs.append(lib64_dir)
-+ libx32_dir = os.path.join(prefix, "libx32", "python" + sys.version[:3], "site-packages")
-+ if (os.path.exists(libx32_dir) and
-+ os.path.realpath(libx32_dir) not in [os.path.realpath(p) for p in sitedirs]):
-+ if _is_64bit:
-+ sitedirs.append(libx32_dir)
-+ else:
-+ sitedirs.insert(0, libx32_dir)
- try:
- # sys.getobjects only available in --with-pydebug build
- sys.getobjects
-@@ -589,6 +596,12 @@
- paths.insert(0, lib64_path)
- else:
- paths.append(lib64_path)
-+ libx32_path = os.path.join(sys.real_prefix, 'libx32', 'python'+sys.version[:3])
-+ if os.path.exists(libx32_path):
-+ if _is_64bit:
-+ paths.append(libx32_path)
-+ else:
-+ paths.insert(0, libx32_path)
- # This is hardcoded in the Python executable, but relative to
- # sys.prefix. Debian change: we need to add the multiarch triplet
- # here, which is where the real stuff lives. As per PEP 421, in
---- virtualenv-16.0.0/tests/test_virtualenv.py.orig 2018-05-17 01:36:07.000000000 +0200
-+++ virtualenv-16.0.0/tests/test_virtualenv.py 2018-07-23 21:40:47.981924463 +0200
-@@ -135,6 +135,8 @@
- for root, dirs, files in os.walk(tmp_virtualenv):
- for f in files + dirs:
- full_name = os.path.join(root, f)
-+ if os.path.islink(full_name) and os.readlink(full_name) == "lib":
-+ continue
- assert not os.path.islink(full_name), "%s should not be a" \
- " symlink (to %s)" % (full_name, os.readlink(full_name))
- finally: