mirror of
https://github.com/servo/servo.git
synced 2025-07-24 15:50:21 +01:00
Upgrade pip properly on windows.
This commit is contained in:
parent
a568a71498
commit
18303211cb
1 changed files with 11 additions and 4 deletions
|
@ -193,11 +193,18 @@ def _activate_virtualenv(topdir, is_firefox):
|
||||||
if need_pip_upgrade:
|
if need_pip_upgrade:
|
||||||
# Upgrade pip when virtualenv is created to fix the issue
|
# Upgrade pip when virtualenv is created to fix the issue
|
||||||
# https://github.com/servo/servo/issues/11074
|
# https://github.com/servo/servo/issues/11074
|
||||||
pip = _get_exec_path(PIP_NAMES, is_valid_path=check_exec_path)
|
if sys.platform in ['msys', 'win32']:
|
||||||
if not pip:
|
python = _get_exec_path(PYTHON_NAMES, is_valid_path=check_exec_path)
|
||||||
sys.exit("Python pip is either not installed or not found in virtualenv.")
|
if not python:
|
||||||
|
sys.exit("Python is either not installed or not found in virtualenv.")
|
||||||
|
|
||||||
_process_exec([pip, "install", "-I", "-U", "pip"])
|
_process_exec([python, "-m", "pip", "install", "-I", "-U", "pip"])
|
||||||
|
else:
|
||||||
|
pip = _get_exec_path(PIP_NAMES, is_valid_path=check_exec_path)
|
||||||
|
if not pip:
|
||||||
|
sys.exit("Python pip is either not installed or not found in virtualenv.")
|
||||||
|
|
||||||
|
_process_exec([pip, "install", "-I", "-U", "pip"])
|
||||||
|
|
||||||
for req_rel_path in requirements_paths:
|
for req_rel_path in requirements_paths:
|
||||||
req_path = os.path.join(topdir, req_rel_path)
|
req_path = os.path.join(topdir, req_rel_path)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue