summaryrefslogtreecommitdiffstats
path: root/Lib/distutils/command/install_lib.py
diff options
context:
space:
mode:
authorGregory P. Smith <greg@mad-scientist.com>2000-05-12 01:46:47 (GMT)
committerGregory P. Smith <greg@mad-scientist.com>2000-05-12 01:46:47 (GMT)
commit74ead8ff5d0861e7adb4eca185a1f0beb1a54227 (patch)
treed73ecb1dafb07943d72de88807a140c2b4ede848 /Lib/distutils/command/install_lib.py
parentf8f2b98bdd9ba37c8cb416a56f1aab7d25071139 (diff)
downloadcpython-74ead8ff5d0861e7adb4eca185a1f0beb1a54227.zip
cpython-74ead8ff5d0861e7adb4eca185a1f0beb1a54227.tar.gz
cpython-74ead8ff5d0861e7adb4eca185a1f0beb1a54227.tar.bz2
Added --skip-build option, so lazy debuggers/testers (mainly me) don't
have to wade through all the 'build' output when testing installation.
Diffstat (limited to 'Lib/distutils/command/install_lib.py')
-rw-r--r--Lib/distutils/command/install_lib.py15
1 files changed, 10 insertions, 5 deletions
diff --git a/Lib/distutils/command/install_lib.py b/Lib/distutils/command/install_lib.py
index 852e3f6..2d0a719 100644
--- a/Lib/distutils/command/install_lib.py
+++ b/Lib/distutils/command/install_lib.py
@@ -15,6 +15,7 @@ class install_lib (Command):
('build-dir=','b', "build directory (where to install from)"),
('compile', 'c', "compile .py to .pyc"),
('optimize', 'o', "compile .py to .pyo (optimized)"),
+ ('skip-build', None, "skip the build steps"),
]
@@ -24,6 +25,7 @@ class install_lib (Command):
self.build_dir = None
self.compile = 1
self.optimize = 1
+ self.skip_build = None
def finalize_options (self):
@@ -34,16 +36,19 @@ class install_lib (Command):
('build_lib', 'build_dir'),
('install_lib', 'install_dir'),
('compile_py', 'compile'),
- ('optimize_py', 'optimize'))
+ ('optimize_py', 'optimize'),
+ ('skip_build', 'skip_build'),
+ )
def run (self):
# Make sure we have built everything we need first
- if self.distribution.has_pure_modules():
- self.run_peer ('build_py')
- if self.distribution.has_ext_modules():
- self.run_peer ('build_ext')
+ if not self.skip_build:
+ if self.distribution.has_pure_modules():
+ self.run_peer ('build_py')
+ if self.distribution.has_ext_modules():
+ self.run_peer ('build_ext')
# Install everything: simply dump the entire contents of the build
# directory to the installation directory (that's the beauty of