[SciPy-Dev] win32 binaries and scipy 0.17.0 release

Tony Kelman tony at kelman.net
Sat Jan 2 19:31:35 EST 2016


Matthew Brett <matthew.brett <at> gmail.com> writes:

> No, you misunderstand me, it's possible to imagine this system built
> on any easily available Python, I was only saying that it's important
> that it should be obvious and easy how to build each individual
> project without having to worry about - for example - the DLL
> configuration of other projects.

I see, sorry for the misunderstanding. This seems like a problem
that isn't really feasible to solve in the absolute most general
case. Maybe the ucrt will help eventually, that was some of its
design motivation, but it's still far too early to tell.

> We could surely benefit from cross-compilation - is there a good
> central place to get going with mingw-w64 cross compiling?

Not that I know of, I had to pick it up by trying it out and lots
of practice. I gave a very short talk at last year's JuliaCon that
touched on this, but there wasn't much time for details. I've been
meaning to record a screencast type tutorial that would be targeted
mainly towards Julia package developers to cover all of the details
starting from getting and using cross-compilers on a number of common
Linux distributions. May also work from OSX, but there isn't a great
standard source of OSX-to-MinGW cross compiler binaries right now.

Debian, Ubuntu, Fedora, OpenSUSE, Arch, and Cygwin all have reasonably
up-to-date mingw-w64 cross-compiler packages readily available
in their repositories. If you pick a library that uses autotools,
it can be as simple as configuring with --host=x86_64-w64-mingw32.
CMake-built libraries also usually work but require a more verbose
set of flags. This covers getting you to a DLL, which is the hardest
part for Julia packages that wrap compiled C/Fortran libraries. I'm
not very familiar with the additional steps that would be needed to
build a Python C extension. You'd probably need an easy way of getting
a Windows copy of libpython and Python.h onto the build machine?

I could work through an example of this, maybe pick a Linux
distribution to build from and a library to build and we could
put together a Docker container that would have all the steps to
produce a Windows DLL.






More information about the SciPy-Dev mailing list