guido.van.rossum
2008-07-17 16:23:53 UTC
Author: guido.van.rossum
Date: Thu Jul 17 18:23:53 2008
New Revision: 65063
Log:
Fix bug 3375 - _multiprocessing.so build problems on OS X.
The solution is to clear sys.path_importer_cache.
Modified:
python/branches/py3k/setup.py
Modified: python/branches/py3k/setup.py
==============================================================================
--- python/branches/py3k/setup.py (original)
+++ python/branches/py3k/setup.py Thu Jul 17 18:23:53 2008
@@ -263,6 +263,12 @@
ext_filename = os.path.join(
self.build_lib,
self.get_ext_filename(self.get_ext_fullname(ext.name)))
+
+ # If the build directory didn't exist when setup.py was
+ # started, sys.path_importer_cache has a negative result
+ # cached. Clear that cache before trying to import.
+ sys.path_importer_cache.clear()
+
try:
imp.load_dynamic(ext.name, ext_filename)
except ImportError as why:
Date: Thu Jul 17 18:23:53 2008
New Revision: 65063
Log:
Fix bug 3375 - _multiprocessing.so build problems on OS X.
The solution is to clear sys.path_importer_cache.
Modified:
python/branches/py3k/setup.py
Modified: python/branches/py3k/setup.py
==============================================================================
--- python/branches/py3k/setup.py (original)
+++ python/branches/py3k/setup.py Thu Jul 17 18:23:53 2008
@@ -263,6 +263,12 @@
ext_filename = os.path.join(
self.build_lib,
self.get_ext_filename(self.get_ext_fullname(ext.name)))
+
+ # If the build directory didn't exist when setup.py was
+ # started, sys.path_importer_cache has a negative result
+ # cached. Clear that cache before trying to import.
+ sys.path_importer_cache.clear()
+
try:
imp.load_dynamic(ext.name, ext_filename)
except ImportError as why: