summaryrefslogtreecommitdiff
path: root/numpy
diff options
context:
space:
mode:
Diffstat (limited to 'numpy')
-rw-r--r--numpy/core/bscript6
-rw-r--r--numpy/core/setup.py6
2 files changed, 2 insertions, 10 deletions
diff --git a/numpy/core/bscript b/numpy/core/bscript
index 5c5c6e4c1..83c0b4b6f 100644
--- a/numpy/core/bscript
+++ b/numpy/core/bscript
@@ -30,11 +30,7 @@ from setup_common \
C99_FUNCS_SINGLE, C99_COMPLEX_TYPES, C99_COMPLEX_FUNCS, \
MANDATORY_FUNCS, C_ABI_VERSION, C_API_VERSION
-try:
- val = os.environ['NPY_SEPARATE_COMPILATION']
- ENABLE_SEPARATE_COMPILATION = (val != "0")
-except KeyError:
- ENABLE_SEPARATE_COMPILATION = False
+ENABLE_SEPARATE_COMPILATION = (os.environ.get('NPY_SEPARATE_COMPILATION', "0") != "0")
NUMPYCONFIG_SYM = []
diff --git a/numpy/core/setup.py b/numpy/core/setup.py
index a1000ae0b..e0a114483 100644
--- a/numpy/core/setup.py
+++ b/numpy/core/setup.py
@@ -12,11 +12,7 @@ import re
from setup_common import *
# Set to True to enable multiple file compilations (experimental)
-try:
- val = os.environ['NPY_SEPARATE_COMPILATION']
- ENABLE_SEPARATE_COMPILATION = (val != "0")
-except KeyError:
- ENABLE_SEPARATE_COMPILATION = False
+ENABLE_SEPARATE_COMPILATION = (os.environ.get('NPY_SEPARATE_COMPILATION', "0") != "0")
# XXX: ugly, we use a class to avoid calling twice some expensive functions in
# config.h/numpyconfig.h. I don't see a better way because distutils force