Bug 1466211 - Remove broken call to initial virtualenv when using pipenv; r?ahal
MozReview-Commit-ID: Bcx67IwQxTa
--- a/build/moz.configure/init.configure
+++ b/build/moz.configure/init.configure
@@ -195,17 +195,16 @@ option(env='PYTHON', nargs=1, help='Pyth
# Setup python virtualenv
# ==============================================================
@depends('PYTHON', check_build_environment, mozconfig, '--help')
@imports('os')
@imports('sys')
-@imports('subprocess')
@imports(_from='mozbuild.configure.util', _import='LineIO')
@imports(_from='mozbuild.virtualenv', _import='VirtualenvManager')
@imports(_from='mozbuild.virtualenv', _import='verify_python_version')
@imports('distutils.sysconfig')
def virtualenv_python(env_python, build_env, mozconfig, help):
if help:
return
@@ -251,24 +250,16 @@ def virtualenv_python(env_python, build_
python = sys.executable
if not manager.up_to_date(python):
log.info('Creating Python environment')
manager.build(python)
python = normsep(manager.python_path)
- if python != normsep(sys.executable):
- log.info('Reexecuting in the virtualenv')
- if env_python:
- del os.environ['PYTHON']
- # One would prefer to use os.execl, but that's completely borked on
- # Windows.
- sys.exit(subprocess.call([python] + sys.argv))
-
# We are now in the virtualenv
if not distutils.sysconfig.get_python_lib():
die('Could not determine python site packages directory')
return python
set_config('PYTHON', virtualenv_python)