Mercurial > hg > vamp-build-and-test
comparison DEPENDENCIES/mingw32/Python27/Lib/site-packages/numpy/distutils/fcompiler/sun.py @ 87:2a2c65a20a8b
Add Python libs and headers
author | Chris Cannam |
---|---|
date | Wed, 25 Feb 2015 14:05:22 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
86:413a9d26189e | 87:2a2c65a20a8b |
---|---|
1 from __future__ import division, absolute_import, print_function | |
2 | |
3 from numpy.distutils.ccompiler import simple_version_match | |
4 from numpy.distutils.fcompiler import FCompiler | |
5 | |
6 compilers = ['SunFCompiler'] | |
7 | |
8 class SunFCompiler(FCompiler): | |
9 | |
10 compiler_type = 'sun' | |
11 description = 'Sun or Forte Fortran 95 Compiler' | |
12 # ex: | |
13 # f90: Sun WorkShop 6 update 2 Fortran 95 6.2 Patch 111690-10 2003/08/28 | |
14 version_match = simple_version_match( | |
15 start=r'f9[05]: (Sun|Forte|WorkShop).*Fortran 95') | |
16 | |
17 executables = { | |
18 'version_cmd' : ["<F90>", "-V"], | |
19 'compiler_f77' : ["f90"], | |
20 'compiler_fix' : ["f90", "-fixed"], | |
21 'compiler_f90' : ["f90"], | |
22 'linker_so' : ["<F90>", "-Bdynamic", "-G"], | |
23 'archiver' : ["ar", "-cr"], | |
24 'ranlib' : ["ranlib"] | |
25 } | |
26 module_dir_switch = '-moddir=' | |
27 module_include_switch = '-M' | |
28 pic_flags = ['-xcode=pic32'] | |
29 | |
30 def get_flags_f77(self): | |
31 ret = ["-ftrap=%none"] | |
32 if (self.get_version() or '') >= '7': | |
33 ret.append("-f77") | |
34 else: | |
35 ret.append("-fixed") | |
36 return ret | |
37 def get_opt(self): | |
38 return ['-fast', '-dalign'] | |
39 def get_arch(self): | |
40 return ['-xtarget=generic'] | |
41 def get_libraries(self): | |
42 opt = [] | |
43 opt.extend(['fsu', 'sunmath', 'mvec']) | |
44 return opt | |
45 | |
46 if __name__ == '__main__': | |
47 from distutils import log | |
48 log.set_verbosity(2) | |
49 from numpy.distutils.fcompiler import new_fcompiler | |
50 compiler = new_fcompiler(compiler='sun') | |
51 compiler.customize() | |
52 print(compiler.get_version()) |