[Numpy-discussion] Building f2py extensions on AMD64 with Python 2.7 Numpy 1.5, MSVC 2008 Pro and gfortran

Eric Firing efiring@hawaii....
Mon Aug 16 11:53:15 CDT 2010

On 08/15/2010 11:14 PM, Sturla Molden wrote:
> Two criticial import libraries for mingw-w64 are missing (libpython26.a
> and msvcr90.a). We cannot build C extensions for Python with mingw-w64. If
> you can build with disutils, your are not using mingw-w64 but another C
> compiler.


Have you tried the Equation Solution versions of the gcc tools?


> There are rumors of incompatibility issues between libgfortran and the CRT
> or SciPy on Windows 64. David Cournapeau might know the details.
> It seems f2py on Windows 64 requires a commercial Fortran compiler (the
> ones worth looking at are Absoft, Intel and PGI) and e.g. Microsoft's free
> C/C++ compiler (download Windows 7 SDK for .NET 3.5 -- not any later or
> earlier version). You need to have the environment variables
> DISTUTILS_USE_SDK and MSSdk set to build with the free SDK compiler. f2py
> will enforce the former, the latter comes from running setenv from the
> SDK. The latter is important as you will need to set up the environments
> for the Fortran and the C compiler in the same command window before
> running f2py.
> I also had to remove support for Compaq Visual Fortran from the f2py
> source to  make anything build, as it crashes f2py on Windows 64 (this
> does not happen on 32-bit Windows).
> Building f2py extensions on Windows 64 is a bit more tricky. And I've had
> no luck with gfortran so far.
> Sturla
>> Hi all,
>> Are there any success stories in building f2py extensions on AMD64 with
>> latest versions? Building the same extension on 32 bit works like a charm.
>> I am having trouble finding documentation or examples, is it supposed to
>> be
>> working?
>> Compiling (with distutils) works like a charm, but that does not help when
>> I'm stuck figuring out link dependencies. It seems to me that the gfortran
>> library depends on a mingw that is in conflict with some CRT library.
>> I have to admit, I'm probably in way too deep waters, and should really be
>> satisfied with 32 bit, but still, it would be fun to get it working.
>> GFortran is from  MinGW-w64 project on sourceforge, version 4.5.1
>> prerelease.
>> Any pointers or other experiences?
>> Regards,
>> Åsmund Hjulstad
>> _______________________________________________
>> NumPy-Discussion mailing list
>> NumPy-Discussion@scipy.org
>> http://mail.scipy.org/mailman/listinfo/numpy-discussion
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion@scipy.org
> http://mail.scipy.org/mailman/listinfo/numpy-discussion

More information about the NumPy-Discussion mailing list