Kaydet (Commit) 7ab5923d authored tarafından Michael W. Hudson's avatar Michael W. Hudson

nnorwitz's fix for:

[ 532618 ] install fails if build .so fails
üst dcddbc3a
...@@ -176,8 +176,13 @@ class PyBuildExt(build_ext): ...@@ -176,8 +176,13 @@ class PyBuildExt(build_ext):
# distutils.command.build_ext.build_extension(). The # distutils.command.build_ext.build_extension(). The
# _built_objects attribute is stored there strictly for # _built_objects attribute is stored there strictly for
# use here. # use here.
for filename in self._built_objects: # If there is a failure, _built_objects may not be there,
os.remove(filename) # so catch the AttributeError and move on.
try:
for filename in self._built_objects:
os.remove(filename)
except AttributeError:
self.announce('unable to remove files (ignored)')
def get_platform (self): def get_platform (self):
# Get value of sys.platform # Get value of sys.platform
...@@ -587,7 +592,7 @@ class PyBuildExt(build_ext): ...@@ -587,7 +592,7 @@ class PyBuildExt(build_ext):
# procedure triggers on. # procedure triggers on.
frameworkdir = sysconfig.get_config_var('PYTHONFRAMEWORKDIR') frameworkdir = sysconfig.get_config_var('PYTHONFRAMEWORKDIR')
exts.append( Extension('gestalt', ['gestaltmodule.c'], exts.append( Extension('gestalt', ['gestaltmodule.c'],
extra_link_args=['-framework', 'Carbon']) ) extra_link_args=['-framework', 'Carbon']) )
exts.append( Extension('MacOS', ['macosmodule.c'], exts.append( Extension('MacOS', ['macosmodule.c'],
extra_link_args=['-framework', 'Carbon']) ) extra_link_args=['-framework', 'Carbon']) )
exts.append( Extension('icglue', ['icgluemodule.c'], exts.append( Extension('icglue', ['icgluemodule.c'],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment