Commit 0cb7c312 authored by Marc-André Lemburg's avatar Marc-André Lemburg

Added an execution layer to be able to customize per-extension

building.
parent 5634233c
...@@ -356,13 +356,16 @@ class build_ext (Command): ...@@ -356,13 +356,16 @@ class build_ext (Command):
# get_outputs () # get_outputs ()
def build_extensions(self):
def build_extensions (self):
# First, sanity-check the 'extensions' list # First, sanity-check the 'extensions' list
self.check_extensions_list(self.extensions) self.check_extensions_list(self.extensions)
for ext in self.extensions: for ext in self.extensions:
self.build_extension(ext)
def build_extension(self, ext):
sources = ext.sources sources = ext.sources
if sources is None or type(sources) not in (ListType, TupleType): if sources is None or type(sources) not in (ListType, TupleType):
raise DistutilsSetupError, \ raise DistutilsSetupError, \
...@@ -391,7 +394,7 @@ class build_ext (Command): ...@@ -391,7 +394,7 @@ class build_ext (Command):
if not (self.force or newer_group(sources, ext_filename, 'newer')): if not (self.force or newer_group(sources, ext_filename, 'newer')):
self.announce("skipping '%s' extension (up-to-date)" % self.announce("skipping '%s' extension (up-to-date)" %
ext.name) ext.name)
continue # 'for' loop over all extensions return
else: else:
self.announce("building '%s' extension" % ext.name) self.announce("building '%s' extension" % ext.name)
...@@ -453,8 +456,6 @@ class build_ext (Command): ...@@ -453,8 +456,6 @@ class build_ext (Command):
debug=self.debug, debug=self.debug,
build_temp=self.build_temp) build_temp=self.build_temp)
# build_extensions ()
def swig_sources (self, sources): def swig_sources (self, sources):
......
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