diff options
author | Robert Kern <robert.kern@gmail.com> | 2007-12-04 07:58:37 +0000 |
---|---|---|
committer | Robert Kern <robert.kern@gmail.com> | 2007-12-04 07:58:37 +0000 |
commit | 941a93af7f8ea0ac5f1bda1c2b3c46865d8e8360 (patch) | |
tree | a70e2ecb24f9e2bf1b662eca7d1559449c9fdb43 /numpy/distutils/fcompiler/intel.py | |
parent | 8610fb8f3aadad9677d55b2959c3e03d419ccef1 (diff) | |
download | numpy-941a93af7f8ea0ac5f1bda1c2b3c46865d8e8360.tar.gz |
Use the correct link parameters for shared libraries with Intel Fortran on OS X.
Diffstat (limited to 'numpy/distutils/fcompiler/intel.py')
-rw-r--r-- | numpy/distutils/fcompiler/intel.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/numpy/distutils/fcompiler/intel.py b/numpy/distutils/fcompiler/intel.py index 9bfd541b2..b226c5e20 100644 --- a/numpy/distutils/fcompiler/intel.py +++ b/numpy/distutils/fcompiler/intel.py @@ -3,6 +3,8 @@ # of intele # http://developer.intel.com/software/products/compilers/flin/ +import sys + from numpy.distutils.cpuinfo import cpu from numpy.distutils.ccompiler import simple_version_match from numpy.distutils.fcompiler import FCompiler, dummy_fortran_file @@ -105,6 +107,14 @@ class IntelFCompiler(BaseIntelFCompiler): v = self.get_version() if v and v >= '8.0': opt.append('-nofor_main') + if sys.platform == 'darwin': + # Here, it's -dynamiclib + try: + idx = opt.index('-shared') + opt.remove('-shared') + except ValueError: + idx = 0 + opt[idx:idx] = ['-dynamiclib', 'Wl,-undefined,dynamic_lookup'] return opt class IntelItaniumFCompiler(IntelFCompiler): |