diff options
Diffstat (limited to 'Lib/distutils/sysconfig.py')
-rw-r--r-- | Lib/distutils/sysconfig.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py index ec2f8a9c33..deb51a1c1a 100644 --- a/Lib/distutils/sysconfig.py +++ b/Lib/distutils/sysconfig.py @@ -165,9 +165,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) = \ + (cc, cxx, opt, cflags, ccshared, ldshared, so_ext, ar) = \ get_config_vars('CC', 'CXX', 'OPT', 'CFLAGS', - 'CCSHARED', 'LDSHARED', 'SO') + 'CCSHARED', 'LDSHARED', 'SO', 'AR') if 'CC' in os.environ: cc = os.environ['CC'] @@ -188,6 +188,8 @@ def customize_compiler(compiler): cpp = cpp + ' ' + os.environ['CPPFLAGS'] cflags = cflags + ' ' + os.environ['CPPFLAGS'] ldshared = ldshared + ' ' + os.environ['CPPFLAGS'] + if 'AR' in os.environ: + ar = os.environ['AR'] cc_cmd = cc + ' ' + cflags compiler.set_executables( @@ -196,7 +198,8 @@ def customize_compiler(compiler): compiler_so=cc_cmd + ' ' + ccshared, compiler_cxx=cxx, linker_so=ldshared, - linker_exe=cc) + linker_exe=cc, + archiver=ar) compiler.shared_lib_extension = so_ext |