cpython: 2c0253d4d9ba (original) (raw)
Mercurial > cpython
changeset 73313:2c0253d4d9ba 3.2
Issue #13307: fix bdist_rpm test failures [#13307]
Antoine Pitrou solipsis@pitrou.net | |
---|---|
date | Thu, 03 Nov 2011 02:45:46 +0100 |
parents | e41663970ca5 |
children | eb2991f7cdc8 3e4c0caf56a8 |
files | Lib/distutils/command/build_py.py Lib/distutils/command/install_lib.py |
diffstat | 2 files changed, 6 insertions(+), 5 deletions(-)[+] [-] Lib/distutils/command/build_py.py 6 Lib/distutils/command/install_lib.py 5 |
line wrap: on
line diff
--- a/Lib/distutils/command/build_py.py +++ b/Lib/distutils/command/build_py.py @@ -3,7 +3,7 @@ Implements the Distutils 'build_py' command.""" import sys, os -import sys +import imp from glob import glob from distutils.core import Command @@ -311,9 +311,9 @@ class build_py (Command): outputs.append(filename) if include_bytecode: if self.compile:
outputs.append(filename + "c")[](#l1.16)
outputs.append(imp.cache_from_source(filename, True))[](#l1.17) if self.optimize > 0:[](#l1.18)
outputs.append(filename + "o")[](#l1.19)
outputs.append(imp.cache_from_source(filename, False))[](#l1.20)
outputs += [ os.path.join(build_dir, filename)
--- a/Lib/distutils/command/install_lib.py +++ b/Lib/distutils/command/install_lib.py @@ -4,6 +4,7 @@ Implements the Distutils 'install_lib' c (install all Python modules).""" import os +import imp import sys from distutils.core import Command @@ -164,9 +165,9 @@ class install_lib(Command): if ext != PYTHON_SOURCE_EXTENSION: continue if self.compile:
bytecode_files.append(py_file + "c")[](#l2.15)
bytecode_files.append(imp.cache_from_source(py_file, True))[](#l2.16) if self.optimize > 0:[](#l2.17)
bytecode_files.append(py_file + "o")[](#l2.18)
bytecode_files.append(imp.cache_from_source(py_file, False))[](#l2.19)