Permalink
Browse files

Merge pull request #323 from pnasrat/develop

Unset __PYENV_LAUNCHER__ for frameworks.
  • Loading branch information...
2 parents 1b9cb8d + b3eb01d commit 756fd9533a5f7422c17f8f8486341206135bd120 @jezdez jezdez committed Sep 3, 2012
Showing with 5 additions and 1 deletion.
  1. +5 −1 virtualenv.py
View
@@ -511,7 +511,7 @@ def _install_req(py_executable, unzip=False, distribute=False,
if unzip:
cmd.append('--always-unzip')
env = {}
- remove_from_env = []
+ remove_from_env = ['__PYVENV_LAUNCHER__']
if logger.stdout_level_matches(logger.DEBUG):
cmd.append('-v')
@@ -1257,6 +1257,10 @@ def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear):
mkdir(bin_dir)
py_executable = join(bin_dir, os.path.basename(sys.executable))
if 'Python.framework' in prefix:
+ # OS X framework builds cause validation to break
+ # https://github.com/pypa/virtualenv/issues/322
+ if os.environ.get('__PYVENV_LAUNCHER__'):
+ os.unsetenv('__PYVENV_LAUNCHER__')
if re.search(r'/Python(?:-32|-64)*$', py_executable):
# The name of the python executable is not quite what
# we want, rename it.

0 comments on commit 756fd95

Please sign in to comment.