[Numpy-discussion] F2py and Absoft Fortran compiler v11.0 (unable to locate U77.lib) [patch]

Åsmund Hjulstad asmund.hjulstad@gmail....
Fri Sep 24 07:15:08 CDT 2010

Hi all,

I have a small patch to absoft.py:

Compiling my fortran extension using f2py and distutils from Numpy 1.5, with
Python 2.7 on Windows, using Absoft v11.0 and MSVC 2008 Pro, first, it
complained about not finding the library U77.lib. Removing this from the
library list (in absoft.py) gave me this error:

error LNK2001: unresolved external symbol __absoft_s_cat

This symbol is now exported from amisc.lib, and after adding this to the
library list everything works fine.

The end result is the following patch:  (or just replacing U77 with amisc)
Fri Sep 24 15:10:57 2010
+++ C:/Python27/Lib/site-packages/numpy/distutils/fcompiler/absoft.py    Fri
Sep 24 15:09:52 2010
@@ -91,7 +91,9 @@

     def get_libraries(self):
         opt = FCompiler.get_libraries(self)
-        if self.get_version() >= '10.0':
+        if self.get_version() >= '11.0':
+            opt.extend(['af90math', 'afio', 'af77math', 'amisc'])
+        elif self.get_version() >= '10.0':
             opt.extend(['af90math', 'afio', 'af77math', 'U77'])
         elif self.get_version() >= '8.0':

BTW, the performance increase compared to gfortran v4.5.0 is really
noticeable, perhaps more than 50%.

Best regards,
Åsmund Hjulstad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/numpy-discussion/attachments/20100924/f4eb8b36/attachment.html 

More information about the NumPy-Discussion mailing list