mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
More fixes for PEP 3147 compliance in distutils (#11254)
This commit is contained in:
parent
5df1108de2
commit
c465b2f843
5 changed files with 94 additions and 59 deletions
|
@ -2,7 +2,8 @@
|
|||
|
||||
Implements the Distutils 'build_py' command."""
|
||||
|
||||
import sys, os
|
||||
import os
|
||||
import imp
|
||||
import sys
|
||||
from glob import glob
|
||||
|
||||
|
@ -311,9 +312,11 @@ class build_py (Command):
|
|||
outputs.append(filename)
|
||||
if include_bytecode:
|
||||
if self.compile:
|
||||
outputs.append(filename + "c")
|
||||
outputs.append(imp.cache_from_source(filename,
|
||||
debug_override=True))
|
||||
if self.optimize > 0:
|
||||
outputs.append(filename + "o")
|
||||
outputs.append(imp.cache_from_source(filename,
|
||||
debug_override=False))
|
||||
|
||||
outputs += [
|
||||
os.path.join(build_dir, filename)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue