[f2py] Getting error while using f2py for large fortran code.

Pearu Peterson pearu at f2py.com
Mon Apr 4 20:51:57 EEST 2011


Could you send a complete but minimal example that is causing problems?
A single Fortran file with a f2py command that give errors would be
sufficient.
Also, what numpy version are you using?

Regards,
Pearu

On Mon, Apr 4, 2011 at 8:41 PM, swayambhoo jain
<swayambhoo.jain at gmail.com>wrote:

> Hi All,
>          I am trying to build a module for SPARSKIT (A fortran code
> base for sparse matrices). It contains fortran files in multiple
> directories. I am able to generate the signature file successfully but
> when I am trying to compile the I am getting lots of similar error.
> Below are the errors I am getting. I will really appreciate if someone
> can help in this.
>
> $ f2py -m SPARSKIT2  SPARSKIT2/BLASSM/*.f SPARSKIT2/FORMATS/*.f
> SPARSKIT2/INOUT/*.F SPARSKIT2/ITSOL/*.f SPARSKIT2/MATGEN/FDIF/*.f
> SPARSKIT2/MATGEN/FEM/*.f SPARSKIT2/ORDERINGS/*.f -h SPARSKIT2.pyf
> <This command was successful>
>
> I am getting lots of below error when I execute this command.
>
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53085: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_stripes’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53086: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53086: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_stripes0’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53087: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53087: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_maskdeg’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53088: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53088: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_perphn’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53089: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53089: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_mapper4’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53090: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53090: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_get_domns2’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53091: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53091: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_mindom’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53092: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53092: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_add_lk’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53093: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53093: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_find_ctr’
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53094: warning:
> initialization from incompatible pointer type
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c:53094: error:
> expected ‘}’ before ‘f2py_rout_SPARSKIT2_rversp’
> error: Command "gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv
> -O2 -Wall -Wstrict-prototypes -fPIC
> -I/tmp/tmpdRDFbe/src.linux-i686-2.6
> -I/usr/lib/python2.6/dist-packages/numpy/core/include
> -I/usr/include/python2.6 -c
> /tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.c -o
> /tmp/tmpdRDFbe/tmp/tmpdRDFbe/src.linux-i686-2.6/SPARSKIT2module.o"
> failed with exit status 1
>
>
> Thanks in Advance
> --
> Swayambhoo jain,
> Graduate Student, MSEE
> Electrical and Computer Engineering Dept.
> University of Minnesota, Twin Cities
>
> _______________________________________________
> f2py-users mailing list
> f2py-users at cens.ioc.ee
> http://cens.ioc.ee/mailman/listinfo/f2py-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://cens.ioc.ee/pipermail/f2py-users/attachments/20110404/65a9e95b/attachment.htm 


More information about the f2py-users mailing list