[f2py] f2py -- getting Intel 8.0 to work with f2py with fib1.f90
example
Vitaly Marin
integrated.m at gmail.com
Sun Feb 3 00:31:02 EET 2008
Hello,
I am a newbie to f2py and I am trying to get fib1.f90 example from the
f2py documentation on intel_fc_8.0 compiler:
=================================
SUBROUTINE FIB(A,N)
INTEGER N
REAL*8 A(N)
DO I=1,N
IF (I.EQ.1) THEN
A(I) = 0.0D0
ELSEIF (I.EQ.2) THEN
A(I) = 1.0D0
ELSE
A(I) = A(I-1) + A(I-2)
ENDIF
ENDDO
END
=====================
I when I use the following command to run f2py on fib1.f90
f2py -c --noarch --f90exec=/opt/intel_fc_80/bin/ifort
--f90flags="-ccdefault list -tpp6 -W0 -L/opt/intel_fc_80/lib -lifport"
--fcompiler=intel fib1.f90 -m fib1
I am able to compile the code but when I do ldd on fib1.so I get
libifport.so.5 => not found
libifcore.so.5 => not found
libimf.so => not found
libm.so.6 => /lib/i686/libm.so.6 (0x4000c000)
libcxa.so.5 => not found
libunwind.so.5 => not found
libc.so.6 => /lib/i686/libc.so.6 (0x40031000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x2aaaa000)
so when I run python with this library it is not able to find
libifport.so.5 library.
Traceback (most recent call last):
File "demo.py", line 10, in ?
import fib1
ImportError: libifport.so.5: cannot load shared object file: No such
file or directory
Could somebody please let me know what would be the correct command to
link to libraries, or fix this issue? Thank you so much.
More information about the f2py-users
mailing list