short-circuit setup_requires for egg_info in pip context

PYTHON-448
This commit is contained in:
Adam Holmberg
2015-12-02 15:56:14 -06:00
parent 4cbf170d42
commit d8fff46286

View File

@@ -189,6 +189,7 @@ try_extensions = "--no-extensions" not in sys.argv and is_supported_platform and
try_murmur3 = try_extensions and "--no-murmur3" not in sys.argv
try_libev = try_extensions and "--no-libev" not in sys.argv and not is_pypy and not is_windows
try_cython = try_extensions and "--no-cython" not in sys.argv and not is_pypy and not os.environ.get('CASS_DRIVER_NO_CYTHON')
try_cython &= 'egg_info' not in sys.argv # bypass setup_requires for pip egg_info calls, which will never have --install-option"--no-cython" coming fomr pip
sys.argv = [a for a in sys.argv if a not in ("--no-murmur3", "--no-libev", "--no-cython", "--no-extensions")]