libvips / build-win64

build libvips for 64-bit windows
28 stars 14 forks source link

Switch to MXE (M cross environment) #22

Closed kleisauke closed 5 years ago

kleisauke commented 6 years ago

Hi John,

I've done some experiments with building a libvips binary for 64-bit Windows with MXE. See here: https://github.com/kleisauke/build-win64-mxe.

In that repository, I did these things:

The binaries can be downloaded here. I think this repository will benefit when switching to MXE (it's easier to use than JHBuild).

Please let me know what you think! I'm intended to pack these libvips binaries in NetVips.

kleisauke commented 6 years ago

Hi @jcupitt,

I just wanted to let you know that I packed these libvips (web-)binaries in NetVips (since v1.0.3) instead than the 'official' one. Hopefully this distribution will be incorporated in the official libvips binaries. I'm happy to receive your feedback.

For e.g. the ImageMagick dependency (v6.8.9-10) is far behind in this repo (2014-11-01 - that's almost 4 years ago). The latest versions of ImageMagick are continuous fuzzed by OSS-Fuzz, so it'll reduce the attack surface.

jcupitt commented 6 years ago

Hello Kleis, sorry for sitting on this, I've not been thinking about Windows builds.

I'll try to read up on MXE.

jcupitt commented 6 years ago

I've started a branch for 8.7 here:

https://github.com/jcupitt/build-win64-mxe/tree/add-8.7

You've probably done this as well.

I'm fixing up the dockerfile a bit as well, and trying to speed it up. It seems to build gcc 5.5 every time, which is unfortunate. Is it making the win C runtime? I did manage to stop the cmake build.

kleisauke commented 6 years ago

Nice! Yes I did build 8.7 without problems some time ago (branch is located here).

That gcc rebuild problem sounds odd, I do not see that behavior here. MXE creates empty files in installed/ (for e.g. mxe/usr/x86_64-w64-mingw32.shared/installed/gcc), it checks their timestamp to determine if they are out-of-date. So maybe it's a system/docker clock problem.

You could merge upstream/master in your branch, I've just updated some dependencies for the libvips 8.6.5 packaging, see: https://github.com/kleisauke/build-win64-mxe/commit/135e79203d764a3e6fb163ec5911e90dd589aab9

jcupitt commented 6 years ago

OK, I'll do a final test build and make a PR.