diff options
author | Travis Oliphant <oliphant@enthought.com> | 2006-06-29 01:41:03 +0000 |
---|---|---|
committer | Travis Oliphant <oliphant@enthought.com> | 2006-06-29 01:41:03 +0000 |
commit | 9913769d0719b6cfca1b3d51baee8421ba7cf288 (patch) | |
tree | 0e143e52bcb00f51c3d6a201ac06221d1b40d8ff /numpy | |
parent | b173aa1a6dc1c361d65150c6782db7618a5ff126 (diff) | |
download | numpy-9913769d0719b6cfca1b3d51baee8421ba7cf288.tar.gz |
Fix some compiler_cxx errors.
Diffstat (limited to 'numpy')
-rw-r--r-- | numpy/distutils/ccompiler.py | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/numpy/distutils/ccompiler.py b/numpy/distutils/ccompiler.py index f068a997b..1c417f9a2 100644 --- a/numpy/distutils/ccompiler.py +++ b/numpy/distutils/ccompiler.py @@ -201,15 +201,17 @@ def CCompiler_customize(self, dist, need_cxx=0): except ValueError: pass - if hasattr(self,'compiler') and self.compiler[0].find('gcc')>=0: - if sys.version[:3]>='2.3': - if not self.compiler_cxx: - self.compiler_cxx = [self.compiler[0].replace('gcc','g++')]\ - + self.compiler[1:] - else: - self.compiler_cxx = [self.compiler[0].replace('gcc','g++')]\ + if hasattr(self,'compiler') and self.compiler[0].find('cc')>=0: + if not self.compiler_cxx: + if self.compiler[0][:3] == 'gcc': + a, b = 'gcc', 'g++' + else: + a, b = 'cc', 'c++' + self.compiler_cxx = [self.compiler[0].replace(a,b)]\ + self.compiler[1:] else: + if hasattr(self,'compiler'): + log.warn("#### %s #######" % (self.compiler,)) log.warn('Missing compiler_cxx fix for '+self.__class__.__name__) return |