summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
Diffstat (limited to 'setup.py')
-rwxr-xr-xsetup.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/setup.py b/setup.py
index d98fece35..b9acb647b 100755
--- a/setup.py
+++ b/setup.py
@@ -15,6 +15,7 @@ basic linear algebra and random number generation.
DOCLINES = __doc__.split("\n")
+import __builtin__
import os
import sys
@@ -37,6 +38,12 @@ Operating System :: MacOS
# update it when the contents of directories change.
if os.path.exists('MANIFEST'): os.remove('MANIFEST')
+# This is a bit hackish: we are setting a global variable so that the main
+# numpy __init__ can detect if it is being loaded by the setup routine, to
+# avoid attempting to load components that aren't built yet. While ugly, it's
+# a lot more robust than what was previously being used.
+__builtin__.__NUMPY_SETUP__ = True
+
def configuration(parent_package='',top_path=None):
from numpy.distutils.misc_util import Configuration