[f2py] shareable shared object
cownby at uvb.nrel.colostate.edu
Mon Jul 30 19:42:20 EEST 2012
I am relatively new to f2py and just found this list. What a relief to find
other folks using this tool! I've been struggling with f2py for a few
weeks, and have finally located & loaded all the compilers required and am
successfully executing Fortran methods from my python scripts.
Now for the question: Is there a way to create the shared object such that
all required libraries/methods are contained within? This may not be an
f2py specific question, but I don't see a flag that forces the compiler to
I am developing a set of python scripts which will be distributed for
outside use. Much of what we need to do is already written in Fortran;
hence the desire to use f2py. However, my collaborators cannot use the
shared objects I create, apparently because of missing DLLs. (My
development and target platform is windows.) I took my .pyd file to a test
machine and copied in missing DLLs until it ran, but each environment is
different, and my collaborators still cannot execute with my shared object
file. They can recompile with my signature file and run successfully.
These are the commands I'm using:
f2py -m mask_water -h mask_water.pyf mask_water.f90
f2py --compiler=mingw32 -c mask_water.pyf mask_water.f90
On my machine, I must explicitly specify the C compiler. I'm sure there's a
way to define this somewhere, but it works.
In case it helps, here is what I've installed:
(only installed compiler suite: fortran, c, c++,
My platform is 64 bit Windows 7. I am tied to python 2.6 because this is an
ArcGIS application, and ArcGIS isn't up to 2.7 yet. I installed the 32 bit
versions because ArcGIS is only 32 bit, and this set happened to be an
iteration that worked.
Thank you; I appreciate any insight you can offer!
Research Associate | Colorado State University | 970-491-3606 |
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the f2py-users