This allows virtualenv to install pip < 19.2 on Python 3.4 once we update pip.epel9
parent
024fd362d7
commit
e70801ec26
@ -1,16 +1,24 @@
|
|||||||
diff --git a/virtualenv.py b/virtualenv.py
|
diff --git a/virtualenv.py b/virtualenv.py
|
||||||
index 3ccbed6..504efc8 100755
|
index 8f05739..cd10e9f 100755
|
||||||
--- a/virtualenv.py
|
--- a/virtualenv.py
|
||||||
+++ b/virtualenv.py
|
+++ b/virtualenv.py
|
||||||
@@ -473,7 +473,10 @@ def virtualenv_support_dirs():
|
@@ -476,7 +476,18 @@ def virtualenv_support_dirs():
|
||||||
|
|
||||||
# normal filesystem installation
|
# normal filesystem installation
|
||||||
if os.path.isdir(join(HERE, "virtualenv_support")):
|
if os.path.isdir(join(HERE, "virtualenv_support")):
|
||||||
- yield [join(HERE, "virtualenv_support")]
|
- yield [join(HERE, "virtualenv_support")]
|
||||||
|
+ dirs = [join(HERE, "virtualenv_support")]
|
||||||
+ if os.path.isdir("/usr/share/python-wheels"):
|
+ if os.path.isdir("/usr/share/python-wheels"):
|
||||||
+ yield ["/usr/share/python-wheels", join(HERE, "virtualenv_support")]
|
+ dirs.insert(0, "/usr/share/python-wheels")
|
||||||
|
+ try:
|
||||||
|
+ import ensurepip
|
||||||
|
+ ensurepip_path = os.path.join(ensurepip.__path__[0], "_bundled")
|
||||||
|
+ except (ImportError, AttributeError, IndexError):
|
||||||
|
+ pass
|
||||||
+ else:
|
+ else:
|
||||||
+ yield [join(HERE, "virtualenv_support")]
|
+ if os.path.isdir(ensurepip_path):
|
||||||
|
+ dirs.insert(0, ensurepip_path)
|
||||||
|
+ yield dirs
|
||||||
elif IS_ZIPAPP:
|
elif IS_ZIPAPP:
|
||||||
tmpdir = tempfile.mkdtemp()
|
tmpdir = tempfile.mkdtemp()
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in new issue