Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 148180 Details for
Bug 145206
python's distutils does not respect CXXFLAGS
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
fixed some strange things in my last patch (irrelevant code)
python-2.5.2-distutils-cxxflags.patch (text/plain), 3.14 KB, created by
Markus Peloquin
on 2008-04-03 08:02:58 UTC
(
hide
)
Description:
fixed some strange things in my last patch (irrelevant code)
Filename:
MIME Type:
Creator:
Markus Peloquin
Created:
2008-04-03 08:02:58 UTC
Size:
3.14 KB
patch
obsolete
>--- Python-2.5.2/Lib/distutils/sysconfig.py 2008-04-03 02:33:10.000000000 -0500 >+++ Python-2.5.2/Lib/distutils/sysconfig.py 2008-04-03 02:37:12.000000000 -0500 >@@ -146,9 +146,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) = \ >- get_config_vars('CC', 'CXX', 'OPT', 'CFLAGS', >- 'CCSHARED', 'LDSHARED', 'SO') >+ (cc, cxx, opt, cflags, ccshared, ldshared, so_ext, cxxflags) = ( >+ get_config_vars('CC', 'CXX', 'OPT', 'CFLAGS', 'CCSHARED', >+ 'LDSHARED', 'SO', 'CXXFLAGS')) > > if os.environ.has_key('CC'): > cc = os.environ['CC'] >@@ -169,13 +169,17 @@ def customize_compiler(compiler): > cpp = cpp + ' ' + os.environ['CPPFLAGS'] > cflags = cflags + ' ' + os.environ['CPPFLAGS'] > ldshared = ldshared + ' ' + os.environ['CPPFLAGS'] >+ if os.environ.has_key('CXXFLAGS'): >+ cxxflags = opt + ' ' + os.environ['CXXFLAGS'] > > cc_cmd = cc + ' ' + cflags >+ cxx_cmd = cxx + ' ' + cxxflags > compiler.set_executables( > preprocessor=cpp, > compiler=cc_cmd, > compiler_so=cc_cmd + ' ' + ccshared, >- compiler_cxx=cxx, >+ compiler_cxx=cxx_cmd, >+ compiler_cxx_so=cxx_cmd + ' ' + ccshared, > linker_so=ldshared, > linker_exe=cc) > >@@ -512,6 +516,7 @@ def get_config_vars(*args): > for key in ('LDFLAGS', 'BASECFLAGS', > # a number of derived variables. These need to be > # patched up as well. >+ 'CXXFLAGS', > 'CFLAGS', 'PY_CFLAGS', 'BLDSHARED'): > > flags = _config_vars[key] >--- Python-2.5.2/Lib/distutils/unixccompiler.py 2008-04-03 02:33:10.000000000 -0500 >+++ Python-2.5.2/Lib/distutils/unixccompiler.py 2008-04-03 02:41:30.000000000 -0500 >@@ -114,6 +114,7 @@ class UnixCCompiler(CCompiler): > 'compiler' : ["cc"], > 'compiler_so' : ["cc"], > 'compiler_cxx' : ["cc"], >+ 'compiler_cxx_so' : ["cc"], > 'linker_so' : ["cc", "-shared"], > 'linker_exe' : ["cc"], > 'archiver' : ["ar", "-cr"], >@@ -167,10 +168,15 @@ class UnixCCompiler(CCompiler): > > def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts): > compiler_so = self.compiler_so >+ compiler_cxx_so = self.compiler_cxx_so > if sys.platform == 'darwin': > compiler_so = _darwin_compiler_fixup(compiler_so, cc_args + extra_postargs) > try: >- self.spawn(compiler_so + cc_args + [src, '-o', obj] + >+ if ext == '.c' or ext == '.m': >+ cc = compiler_so + cc_args >+ else: >+ cc = compiler_cxx_so + cc_args >+ self.spawn(cc + cc_args + [src, '-o', obj] + > extra_postargs) > except DistutilsExecError, msg: > raise CompileError, msg
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 145206
:
148178
|
148180
|
148946
|
148947