diff options
author | Collin Winter <collinw@gmail.com> | 2007-08-30 03:52:21 (GMT) |
---|---|---|
committer | Collin Winter <collinw@gmail.com> | 2007-08-30 03:52:21 (GMT) |
commit | 5b7e9d76f39dbf63573519c178835f72e5a5027a (patch) | |
tree | 96b04b9d52d875c9f39d148d88efeafb5184fd35 /Lib/distutils/command/build.py | |
parent | a73bfee73da519a508e7d95bc55c1984ae7089bd (diff) | |
download | cpython-5b7e9d76f39dbf63573519c178835f72e5a5027a.zip cpython-5b7e9d76f39dbf63573519c178835f72e5a5027a.tar.gz cpython-5b7e9d76f39dbf63573519c178835f72e5a5027a.tar.bz2 |
General cleanup, raise normalization in Lib/distutils.
Diffstat (limited to 'Lib/distutils/command/build.py')
-rw-r--r-- | Lib/distutils/command/build.py | 26 |
1 files changed, 9 insertions, 17 deletions
diff --git a/Lib/distutils/command/build.py b/Lib/distutils/command/build.py index 9ae0a29..1f2ce06 100644 --- a/Lib/distutils/command/build.py +++ b/Lib/distutils/command/build.py @@ -2,8 +2,6 @@ Implements the Distutils 'build' command.""" -# This module should be kept compatible with Python 2.1. - __revision__ = "$Id$" import sys, os @@ -11,12 +9,12 @@ from distutils.core import Command from distutils.util import get_platform -def show_compilers (): +def show_compilers(): from distutils.ccompiler import show_compilers show_compilers() -class build (Command): +class build(Command): description = "build everything needed to install" @@ -51,7 +49,7 @@ class build (Command): "list available compilers", show_compilers), ] - def initialize_options (self): + def initialize_options(self): self.build_base = 'build' # these are decided only after 'build_base' has its final value # (unless overridden by the user or client) @@ -65,8 +63,7 @@ class build (Command): self.force = 0 self.executable = None - def finalize_options (self): - + def finalize_options(self): plat_specifier = ".%s-%s" % (get_platform(), sys.version[0:3]) # 'build_purelib' and 'build_platlib' just default to 'lib' and @@ -98,11 +95,8 @@ class build (Command): if self.executable is None: self.executable = os.path.normpath(sys.executable) - # finalize_options () - - - def run (self): + def run(self): # Run all relevant sub-commands. This will be some subset of: # - build_py - pure Python modules # - build_clib - standalone C libraries @@ -114,16 +108,16 @@ class build (Command): # -- Predicates for the sub-command list --------------------------- - def has_pure_modules (self): + def has_pure_modules(self): return self.distribution.has_pure_modules() - def has_c_libraries (self): + def has_c_libraries(self): return self.distribution.has_c_libraries() - def has_ext_modules (self): + def has_ext_modules(self): return self.distribution.has_ext_modules() - def has_scripts (self): + def has_scripts(self): return self.distribution.has_scripts() @@ -132,5 +126,3 @@ class build (Command): ('build_ext', has_ext_modules), ('build_scripts', has_scripts), ] - -# class build |