Ticket #41122: patch-setup.py.diff
File patch-setup.py.diff, 1.4 KB (added by anowacki (Andy Nowacki), 11 years ago) |
---|
-
setup.
old new 27 27 from distutils.unixccompiler import UnixCCompiler 28 28 from setuptools import find_packages, setup 29 29 from setuptools.extension import Extension 30 import distribute_setup31 30 import glob 32 31 import os 33 32 import platform … … 370 369 # otherwise we just use the original compile method 371 370 UnixCCompiler.linker_so = None 372 371 return self._original_compile(obj, src, *args, **kwargs) 373 UnixCCompiler.linker_so = [ "gfortran"]374 self.compiler_so = [ "gfortran"]372 UnixCCompiler.linker_so = [os.environ.get("F77")] 373 self.compiler_so = [os.environ.get("F77")] 375 374 cc_args = ['-c', '-fno-underscoring'] 376 375 cc_args.append('-fPIC') 377 376 try: … … 621 620 taupargs = [] 622 621 623 622 lib = MyExtension(lib_name, 624 623 libraries=['gfortran'], 625 extra_link_args= extra_link_args,624 extra_link_args=['-L/opt/local/lib/gcc46'], 626 625 sources=[src + 'emdlv.f', src + 'libtau.f', 627 626 src + 'ttimes_subrout.f']) … … 629 627 630 628 631 629 def setupPackage(gfortran=True, ccompiler=True): 632 # automatically install distribute if the user does not have it installed633 distribute_setup.use_setuptools()634 630 # use lib2to3 for Python 3.x 635 631 if sys.version_info[0] == 3: 636 632 convert2to3()