[Numpy-svn] r3896 - in trunk/numpy/distutils: . fcompiler
numpy-svn at scipy.org
numpy-svn at scipy.org
Tue Jul 24 08:09:05 EDT 2007
Author: pearu
Date: 2007-07-24 07:08:46 -0500 (Tue, 24 Jul 2007)
New Revision: 3896
Modified:
trunk/numpy/distutils/exec_command.py
trunk/numpy/distutils/fcompiler/compaq.py
Log:
Modified: trunk/numpy/distutils/exec_command.py
===================================================================
--- trunk/numpy/distutils/exec_command.py 2007-07-24 07:46:07 UTC (rev 3895)
+++ trunk/numpy/distutils/exec_command.py 2007-07-24 12:08:46 UTC (rev 3896)
@@ -123,7 +123,7 @@
############################################################
def find_executable(exe, path=None):
- """Return full path of a executable.
+ """Return full path of a executable or None.
Symbolic links are not followed.
"""
@@ -358,7 +358,6 @@
use_shell = os.name=='posix'
if use_tee is None:
use_tee = os.name=='posix'
-
using_command = 0
if use_shell:
# We use shell (unless use_shell==0) so that wildcards can be
@@ -380,7 +379,7 @@
spawn_command = os.spawnvpe
else:
spawn_command = os.spawnve
- argv[0] = find_executable(argv[0])
+ argv[0] = find_executable(argv[0]) or argv[0]
if not os.path.isfile(argv[0]):
log.warn('Executable %s does not exist' % (argv[0]))
if os.name in ['nt','dos']:
Modified: trunk/numpy/distutils/fcompiler/compaq.py
===================================================================
--- trunk/numpy/distutils/fcompiler/compaq.py 2007-07-24 07:46:07 UTC (rev 3895)
+++ trunk/numpy/distutils/fcompiler/compaq.py 2007-07-24 12:08:46 UTC (rev 3896)
@@ -5,6 +5,7 @@
import sys
from numpy.distutils.fcompiler import FCompiler
+from distutils.errors import DistutilsPlatformError
compilers = ['CompaqFCompiler']
if os.name != 'posix':
@@ -69,12 +70,17 @@
ar_exe = 'lib.exe'
fc_exe = 'DF'
+
if sys.platform=='win32':
from distutils.msvccompiler import MSVCCompiler
- m = MSVCCompiler()
- m.initialize()
- ar_exe = m.lib
+ try:
+ m = MSVCCompiler()
+ m.initialize()
+ ar_exe = m.lib
+ except DistutilsPlatformError, msg:
+ print 'Ignoring %s (one should fix me in fcompiler/compaq.py)' % (msg)
+
executables = {
'version_cmd' : ['<F90>', "/what"],
'compiler_f77' : [fc_exe, "/f77rtl","/fixed"],
More information about the Numpy-svn
mailing list