summaryrefslogtreecommitdiff
path: root/numpy/distutils/intelccompiler.py
diff options
context:
space:
mode:
authorTravis Oliphant <oliphant@enthought.com>2006-01-04 17:26:31 +0000
committerTravis Oliphant <oliphant@enthought.com>2006-01-04 17:26:31 +0000
commit8e2654541c6eae0f308908f501cccbc86b2f9101 (patch)
treebfcfe3b282c8fb659832bf86a841ce76852094ad /numpy/distutils/intelccompiler.py
parentddaed649c23bbd0ad36cdafdfe9cd92397ce69e3 (diff)
downloadnumpy-8e2654541c6eae0f308908f501cccbc86b2f9101.tar.gz
Moved scipy directory to numpy
Diffstat (limited to 'numpy/distutils/intelccompiler.py')
-rw-r--r--numpy/distutils/intelccompiler.py30
1 files changed, 30 insertions, 0 deletions
diff --git a/numpy/distutils/intelccompiler.py b/numpy/distutils/intelccompiler.py
new file mode 100644
index 000000000..87b7f564b
--- /dev/null
+++ b/numpy/distutils/intelccompiler.py
@@ -0,0 +1,30 @@
+
+import os
+from distutils.unixccompiler import UnixCCompiler
+from scipy.distutils.exec_command import find_executable
+
+class IntelCCompiler(UnixCCompiler):
+
+ """ A modified Intel compiler compatible with an gcc built Python.
+ """
+
+ compiler_type = 'intel'
+ cc_exe = 'icc'
+
+ def __init__ (self, verbose=0, dry_run=0, force=0):
+ UnixCCompiler.__init__ (self, verbose,dry_run, force)
+ compiler = self.cc_exe
+ self.set_executables(compiler=compiler,
+ compiler_so=compiler,
+ compiler_cxx=compiler,
+ linker_exe=compiler,
+ linker_so=compiler + ' -shared')
+
+class IntelItaniumCCompiler(IntelCCompiler):
+ compiler_type = 'intele'
+
+ # On Itanium, the Intel Compiler used to be called ecc, let's search for
+ # it (now it's also icc, so ecc is last in the search).
+ for cc_exe in map(find_executable,['icc','ecc']):
+ if os.path.isfile(cc_exe):
+ break