Only run build_py if we have pure Python modules, and build_ext if we
have extension modules.
This commit is contained in:
parent
dbb96253ea
commit
02e1c56212
|
@ -40,10 +40,14 @@ class Build (Command):
|
||||||
# For now, "build" means "build_py" then "build_ext". (Eventually
|
# For now, "build" means "build_py" then "build_ext". (Eventually
|
||||||
# it should also build documentation.)
|
# it should also build documentation.)
|
||||||
|
|
||||||
# Invoke the 'build_py' command
|
# Invoke the 'build_py' command to "build" pure Python modules
|
||||||
self.run_peer ('build_py')
|
# (ie. copy 'em into the build tree)
|
||||||
|
if self.distribution.packages or self.distribution.py_modules:
|
||||||
|
self.run_peer ('build_py')
|
||||||
|
|
||||||
# And now 'build_ext'
|
# And now 'build_ext' -- compile extension modules and put them
|
||||||
self.run_peer ('build_ext')
|
# into the build tree
|
||||||
|
if self.distribution.ext_modules:
|
||||||
|
self.run_peer ('build_ext')
|
||||||
|
|
||||||
# end class Build
|
# end class Build
|
||||||
|
|
Loading…
Reference in New Issue