mirror of
https://github.com/python/cpython.git
synced 2025-08-01 15:43:13 +00:00
Apply diff2.txt from SF patch http://www.python.org/sf/572113
(with one small bugfix in bgen/bgen/scantools.py) This replaces string module functions with string methods for the stuff in the Tools directory. Several uses of string.letters etc. are still remaining.
This commit is contained in:
parent
6a0477b099
commit
aaab30e00c
70 changed files with 271 additions and 346 deletions
|
@ -91,7 +91,6 @@ if it does, the resulting binary is not self-contained.
|
|||
|
||||
import getopt
|
||||
import os
|
||||
import string
|
||||
import sys
|
||||
|
||||
|
||||
|
@ -148,7 +147,7 @@ def main():
|
|||
# last option can not be "-i", so this ensures "pos+1" is in range!
|
||||
if sys.argv[pos] == '-i':
|
||||
try:
|
||||
options = string.split(open(sys.argv[pos+1]).read())
|
||||
options = open(sys.argv[pos+1]).read().split()
|
||||
except IOError, why:
|
||||
usage("File name '%s' specified with the -i option "
|
||||
"can not be read - %s" % (sys.argv[pos+1], why) )
|
||||
|
@ -198,9 +197,9 @@ def main():
|
|||
if o == '-l':
|
||||
addn_link.append(a)
|
||||
if o == '-a':
|
||||
apply(modulefinder.AddPackagePath, tuple(string.split(a,"=", 2)))
|
||||
apply(modulefinder.AddPackagePath, tuple(a.split("=", 2)))
|
||||
if o == '-r':
|
||||
f,r = string.split(a,"=", 2)
|
||||
f,r = a.split("=", 2)
|
||||
replace_paths.append( (f,r) )
|
||||
|
||||
# default prefix and exec_prefix
|
||||
|
@ -419,7 +418,7 @@ def main():
|
|||
# report unknown modules
|
||||
if unknown:
|
||||
sys.stderr.write('Warning: unknown modules remain: %s\n' %
|
||||
string.join(unknown))
|
||||
' '.join(unknown))
|
||||
|
||||
# windows gets different treatment
|
||||
if win:
|
||||
|
@ -462,8 +461,8 @@ def main():
|
|||
for key in makevars.keys():
|
||||
somevars[key] = makevars[key]
|
||||
|
||||
somevars['CFLAGS'] = string.join(cflags) # override
|
||||
somevars['CPPFLAGS'] = string.join(cppflags) # override
|
||||
somevars['CFLAGS'] = ' '.join(cflags) # override
|
||||
somevars['CPPFLAGS'] = ' '.join(cppflags) # override
|
||||
files = [base_config_c, base_frozen_c] + \
|
||||
files + supp_sources + addfiles + libs + \
|
||||
['$(MODLIBS)', '$(LIBS)', '$(SYSLIBS)']
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue