Merged revisions 72445 via svnmerge from

svn+ssh://pythondev@svn.python.org/python/trunk

........
  r72445 | tarek.ziade | 2009-05-07 23:20:34 +0200 (Thu, 07 May 2009) | 1 line

  Fixed #5941: added ARFLAGS for the archiver command.
........
This commit is contained in:
Tarek Ziadé 2009-05-07 21:24:43 +00:00
parent 72b06c6be0
commit 5662d3e676
7 changed files with 70 additions and 11 deletions

View file

@ -160,9 +160,9 @@ def customize_compiler(compiler):
varies across Unices and is stored in Python's Makefile.
"""
if compiler.compiler_type == "unix":
(cc, cxx, opt, cflags, ccshared, ldshared, so_ext, ar) = \
(cc, cxx, opt, cflags, ccshared, ldshared, so_ext, ar, ar_flags) = \
get_config_vars('CC', 'CXX', 'OPT', 'CFLAGS',
'CCSHARED', 'LDSHARED', 'SO', 'AR')
'CCSHARED', 'LDSHARED', 'SO', 'AR', 'ARFLAGS')
if 'CC' in os.environ:
cc = os.environ['CC']
@ -185,6 +185,10 @@ def customize_compiler(compiler):
ldshared = ldshared + ' ' + os.environ['CPPFLAGS']
if 'AR' in os.environ:
ar = os.environ['AR']
if 'ARFLAGS' in os.environ:
archiver = ar + ' ' + os.environ['ARFLAGS']
else:
archiver = ar + ' ' + ar_flags
cc_cmd = cc + ' ' + cflags
compiler.set_executables(
@ -194,7 +198,7 @@ def customize_compiler(compiler):
compiler_cxx=cxx,
linker_so=ldshared,
linker_exe=cc,
archiver=ar)
archiver=archiver)
compiler.shared_lib_extension = so_ext