Skip to content

Commit

Permalink
Update for 8.9.0
Browse files Browse the repository at this point in the history
- Update GLib to 2.63.4.
- Update librsvg to 2.47.2.
- Update libwebp to 1.1.0.
- Update ImageMagick to 6.9.10-87.
- Update libde265 to 1.0.5.

MXE Updates:
- Update SQLite to 3.30.1.
  • Loading branch information
kleisauke committed Jan 28, 2020
1 parent 65d883e commit 89feab2
Show file tree
Hide file tree
Showing 11 changed files with 83 additions and 52 deletions.
2 changes: 1 addition & 1 deletion 8.9/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ target="${2:-x86_64-w64-mingw32.shared.win32}"
# Always checkout a particular revision which will successfully build.
# This ensures that it will not suddenly break a build.
# Note: Must be regularly updated.
revision="16952b5f6f85d218c97f2228eba22d9d9be264f2"
revision="433b75cade6189026ffed6583f00f167e0667cf4"
initialize=false

if [ -f "$mxe_dir/Makefile" ]; then
Expand Down
16 changes: 11 additions & 5 deletions 8.9/libde265.mk
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,22 @@ PKG := libde265
$(PKG)_WEBSITE := https://www.libde265.org/
$(PKG)_DESCR := Open h.265 video codec implementation.
$(PKG)_IGNORE :=
$(PKG)_VERSION := 1.0.4
$(PKG)_CHECKSUM := c3f033bd59777624859c8d04a5b7ce4210adbce4a500943d2e211c4d517d0116
$(PKG)_VERSION := 1.0.5
$(PKG)_CHECKSUM := e3f277d8903408615a5cc34718b391b83c97c646faea4f41da93bac5ee08a87f
$(PKG)_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/$(PKG)-[0-9]*.patch)))
$(PKG)_GH_CONF := strukturag/libde265/releases,v
$(PKG)_DEPS := cc
$(PKG)_DEPS := cc mingw-std-threads

define $(PKG)_BUILD
$(if $(findstring win32,$(TARGET)),\
(cd '$(SOURCE_DIR)' && $(PATCH) -p1 -u) < $(realpath $(dir $(lastword $(libde265_PATCHES))))/libde265-mingw-std-threads.patch)

cd '$(BUILD_DIR)' && $(TARGET)-cmake '$(SOURCE_DIR)' \
-DCMAKE_C_FLAGS="-msse4.1" \
-DCMAKE_CXX_FLAGS="-msse4.1" \
-DCMAKE_C_FLAGS="$(CFLAGS) -msse4.1" \
$(if $(findstring win32,$(TARGET)), \
-DCMAKE_CXX_FLAGS='$(CXXFLAGS) -msse4.1 -I$(PREFIX)/$(TARGET)/include/mingw-std-threads' \
$(else), \
-DCMAKE_CXX_FLAGS='$(CXXFLAGS) -msse4.1') \
-DDISABLE_SSE=OFF
$(MAKE) -C '$(BUILD_DIR)' -j '$(JOBS)'
$(MAKE) -C '$(BUILD_DIR)' -j 1 install
Expand Down
42 changes: 19 additions & 23 deletions 8.9/overrides.mk
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,8 @@ matio_FILE := matio-$(matio_VERSION).tar.gz
matio_URL := https://github.com/tbeu/matio/releases/download/v$(matio_VERSION)/$(matio_FILE)

# upstream version is 7, we want ImageMagick 6
imagemagick_VERSION := 6.9.10-83
imagemagick_CHECKSUM := ebc3856fc9bcb128db37c732c7a05154ba3a1391a0821e9b4b423c95d0532670
imagemagick_VERSION := 6.9.10-87
imagemagick_CHECKSUM := 2fc3789fd162c65f3a1e932cd82ef0301d3591cc8406d66dc6dbc4e829002379
imagemagick_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/imagemagick-[0-9]*.patch)))
imagemagick_GH_CONF := ImageMagick/ImageMagick6/tags

Expand Down Expand Up @@ -131,19 +131,17 @@ fribidi_SUBDIR := fribidi-$(fribidi_VERSION)
fribidi_FILE := fribidi-$(fribidi_VERSION).tar.bz2
fribidi_URL := https://github.com/fribidi/fribidi/releases/download/v$(fribidi_VERSION)/$(fribidi_FILE)

# upstream version is 0.83.0
poppler_VERSION := 0.84.0
poppler_CHECKSUM := c7a130da743b38a548f7a21fe5940506fb1949f4ebdd3209f0e5b302fa139731
poppler_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/poppler-[0-9]*.patch)))
poppler_SUBDIR := poppler-$(poppler_VERSION)
poppler_FILE := poppler-$(poppler_VERSION).tar.xz
poppler_URL := https://poppler.freedesktop.org/$(poppler_FILE)

libxml2_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/libxml2-[0-9]*.patch)))
# upstream version is 1.0.3
libwebp_VERSION := 1.1.0
libwebp_CHECKSUM := 98a052268cc4d5ece27f76572a7f50293f439c17a98e67c4ea0c7ed6f50ef043
libwebp_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/libwebp-[0-9]*.patch)))
libwebp_SUBDIR := libwebp-$(libwebp_VERSION)
libwebp_FILE := libwebp-$(libwebp_VERSION).tar.gz
libwebp_URL := http://downloads.webmproject.org/releases/webp/$(libwebp_FILE)

# upstream version is 2.50.2
glib_VERSION := 2.63.3
glib_CHECKSUM := 8a09a2a059eb617d52b6fcd6f25e0243f0849c598612c9aa5074ce3a6ee1c11c
glib_VERSION := 2.63.4
glib_CHECKSUM := d6ba2b0cde747367f43ad64751221d5beb95de1739a89856316df804e3447618
glib_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/glib-[0-9]*.patch)))
glib_SUBDIR := glib-$(glib_VERSION)
glib_FILE := glib-$(glib_VERSION).tar.xz
Expand All @@ -165,10 +163,6 @@ cairo_SUBDIR := cairo-$(cairo_VERSION)
cairo_FILE := cairo-$(cairo_VERSION).tar.xz
cairo_URL := http://cairographics.org/snapshots/$(cairo_FILE)

# zlib will make libzlib.dll, but we want libz.dll so we must
# patch CMakeLists.txt
zlib_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/zlib-[0-9]*.patch)))

# upstream version is 2.2.0
# cannot use GH_CONF:
# openexr_GH_CONF := openexr/openexr/tags
Expand Down Expand Up @@ -221,13 +215,15 @@ hdf5_SUBDIR := hdf5-$(hdf5_VERSION)
hdf5_FILE := hdf5-$(hdf5_VERSION).tar.bz2
hdf5_URL := https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-$(call SHORT_PKG_VERSION,hdf5)/hdf5-$(hdf5_VERSION)/src/$(hdf5_FILE)

# upstream version is 2.0.3
libjpeg-turbo_VERSION := 2.0.4
libjpeg-turbo_CHECKSUM := 33dd8547efd5543639e890efbf2ef52d5a21df81faf41bb940657af916a23406
## Patches that we override with our own

libjpeg-turbo_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/libjpeg-turbo-[0-9]*.patch)))
libjpeg-turbo_SUBDIR := libjpeg-turbo-$(libjpeg-turbo_VERSION)
libjpeg-turbo_FILE := libjpeg-turbo-$(libjpeg-turbo_VERSION).tar.gz
libjpeg-turbo_URL := https://$(SOURCEFORGE_MIRROR)/project/libjpeg-turbo/$(libjpeg-turbo_VERSION)/$(libjpeg-turbo_FILE)
poppler_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/poppler-[0-9]*.patch)))
libxml2_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/libxml2-[0-9]*.patch)))

# zlib will make libzlib.dll, but we want libz.dll so we must
# patch CMakeLists.txt
zlib_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/zlib-[0-9]*.patch)))

## Override sub-dependencies
# HarfBuzz:
Expand Down
26 changes: 26 additions & 0 deletions 8.9/patches/libde265-mingw-std-threads.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
This file is part of MXE. See LICENSE.md for licensing information.

Contains ad hoc patches for cross building.

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Kleis Auke Wolthuizen <[email protected]>
Date: Sat, 25 Jan 2020 17:30:00 +0100
Subject: [PATCH 1/1] Use the mutex helper from mingw-std-threads


diff --git a/libde265/de265.cc b/libde265/de265.cc
index 1111111..2222222 100644
--- a/libde265/de265.cc
+++ b/libde265/de265.cc
@@ -31,7 +31,11 @@
#include <assert.h>
#include <string.h>
#include <stdlib.h>
+#ifdef _WIN32
+#include "mingw.mutex.h"
+#else
#include <mutex>
+#endif


// TODO: should be in some vps.c related header
6 changes: 3 additions & 3 deletions 8.9/plugins/llvm-mingw/llvm-mingw.mk
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ PKG := llvm-mingw
$(PKG)_WEBSITE := https://github.com/mstorsjo/llvm-mingw
$(PKG)_DESCR := An LLVM/Clang/LLD based mingw-w64 toolchain
$(PKG)_IGNORE :=
# https://api.github.com/repos/mstorsjo/llvm-mingw/tarball/57c4f47db3bc93bcc3ec8eb99e11a0ba87b320bc
$(PKG)_VERSION := 57c4f47
$(PKG)_CHECKSUM := 5a7d12479c3e4c67e069d85b2bf584cb008819f08e4febb6fcea4f34c6b7f1e6
# https://api.github.com/repos/mstorsjo/llvm-mingw/tarball/ee894b6f6365425ddafec6e8a01173be820f81bf
$(PKG)_VERSION := ee894b6
$(PKG)_CHECKSUM := c23f741fff77cd4c588b700ce9995271c22ba0e550374dd9afc98378e6513fb0
$(PKG)_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/llvm-mingw-[0-9]*.patch)))
$(PKG)_GH_CONF := mstorsjo/llvm-mingw/branches/master
$(PKG)_DEPS := llvm mingw-w64
Expand Down
2 changes: 1 addition & 1 deletion 8.9/variables.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

vips_package=vips
vips_version=8.9
vips_patch_version=0-rc4
vips_patch_version=0

# build-win64/x.xx dir we are building
work_dir=$(pwd)
Expand Down
8 changes: 4 additions & 4 deletions 8.9/vips-all.mk
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ PKG := vips-all
$(PKG)_WEBSITE := https://libvips.github.io/libvips/
$(PKG)_DESCR := A fast image processing library with low memory needs.
$(PKG)_IGNORE :=
$(PKG)_VERSION := 8.9.0-rc4
$(PKG)_CHECKSUM := 899964dd3fb8ee7567342d7a3d15488a8e03d5fab2eefc54c9b164b6eda42e97
$(PKG)_VERSION := 8.9.0
$(PKG)_CHECKSUM := 97334a5e70aff343d2587f23cb8068fc846a58cd937c89a446142ccf00ea0349
$(PKG)_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/vips-[0-9]*.patch)))
$(PKG)_GH_CONF := libvips/libvips/releases,v,,,,-rc4.tar.gz
$(PKG)_SUBDIR := vips-$(firstword $(subst -, ,$($(PKG)_VERSION)))
$(PKG)_GH_CONF := libvips/libvips/releases,v
$(PKG)_SUBDIR := vips-$($(PKG)_VERSION)
$(PKG)_FILE := vips-$($(PKG)_VERSION).tar.gz
$(PKG)_DEPS := cc matio libwebp librsvg giflib poppler glib pango fftw \
libgsf libjpeg-turbo tiff openslide lcms libexif libheif \
Expand Down
8 changes: 4 additions & 4 deletions 8.9/vips-web.mk
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ PKG := vips-web
$(PKG)_WEBSITE := https://libvips.github.io/libvips/
$(PKG)_DESCR := A fast image processing library with low memory needs.
$(PKG)_IGNORE :=
$(PKG)_VERSION := 8.9.0-rc4
$(PKG)_CHECKSUM := 899964dd3fb8ee7567342d7a3d15488a8e03d5fab2eefc54c9b164b6eda42e97
$(PKG)_VERSION := 8.9.0
$(PKG)_CHECKSUM := 97334a5e70aff343d2587f23cb8068fc846a58cd937c89a446142ccf00ea0349
$(PKG)_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/vips-[0-9]*.patch)))
$(PKG)_GH_CONF := libvips/libvips/releases,v,,,,-rc4.tar.gz
$(PKG)_SUBDIR := vips-$(firstword $(subst -, ,$($(PKG)_VERSION)))
$(PKG)_GH_CONF := libvips/libvips/releases,v
$(PKG)_SUBDIR := vips-$($(PKG)_VERSION)
$(PKG)_FILE := vips-$($(PKG)_VERSION).tar.gz
$(PKG)_DEPS := cc libwebp librsvg giflib glib pango libgsf \
libjpeg-turbo tiff lcms libexif libpng orc
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Experiment with building a libvips binary for Windows with [MXE](https://github.
| [gdk-pixbuf] | 2.40.0 | LGPLv3 |
| [gettext] | 0.20.1 | LGPLv3 |
| [giflib] | 5.1.4 | MIT Licence |
| [glib] | 2.63.3 | LGPLv3 |
| [glib] | 2.63.4 | LGPLv3 |
| [harfbuzz] | 2.6.4 | MIT Licence |
| [lcms] | 2.9 | MIT Licence |
| [libexif] | 0.6.21 | LGPLv3 |
Expand All @@ -22,10 +22,10 @@ Experiment with building a libvips binary for Windows with [MXE](https://github.
| [libiconv] | 1.16 | LGPLv3 |
| [libjpeg-turbo] | 2.0.4 | [zlib License, IJG License] |
| [libpng] | 1.6.37 | [libpng License version 2] |
| [librsvg] | 2.47.1 | LGPLv3 |
| [librsvg] | 2.47.2 | LGPLv3 |
| [libtiff] | 4.1.0 | [libtiff License] (BSD-like) |
| [libvips] | 8.9.0-rc4 | LGPLv3 |
| [libwebp] | 1.0.3 | New BSD License |
| [libvips] | 8.9.0 | LGPLv3 |
| [libwebp] | 1.1.0 | New BSD License |
| [libxml2] | 2.9.10 | MIT Licence |
| [orc] | 0.4.31 | [orc License] (BSD-like) |
| [pango] | 1.44.7 | LGPLv3 |
Expand Down Expand Up @@ -74,16 +74,16 @@ Same as libvips-web + these extra dependencies:
| [cfitsio] | 3.470 | BSD-like |
| [fftw] | 3.3.8 | GPLv2 |
| [hdf5] | 1.10.6 | BSD-like |
| [imagemagick] | 6.9.10-83 | [ImageMagick License] (GPL-like) |
| [libde265] | 1.0.4 | LGPLv3 |
| [imagemagick] | 6.9.10-87 | [ImageMagick License] (GPL-like) |
| [libde265] | 1.0.5 | LGPLv3 |
| [libheif] | 1.6.1 | LGPLv3 |
| [matio] | 1.5.17 | BSD 2-Clause |
| [nifticlib] | 2.0.0 | Public domain |
| [openexr] | 2.4.0 | BSD 3-Clause |
| [openjpeg] | 2.3.1 | BSD 2-Clause |
| [openslide] | 3.4.1 | LGPLv3 |
| [poppler] | 0.84.0 | GPLv2 |
| [sqlite] | 3.30.1 | Public domain |
| [sqlite] | 3.31.0 | Public domain |
| [x265] | 3.2.1 | GPLv2 |

[cfitsio]: https://heasarc.gsfc.nasa.gov/fitsio/
Expand Down
6 changes: 5 additions & 1 deletion TODO.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
## TODO
- [ ] Let Travis build libvips with pre-compiled dependencies.
- [ ] Wait for: https://github.com/mxe/mxe/issues/2021.
- [ ] Wait for: [mxe/mxe#2021](https://github.com/mxe/mxe/issues/2021).
- [ ] Incorporate all new dependencies and patches into [MXE](https://github.com/mxe/mxe).
- [ ] Should we also add libvips-web?
- [ ] Not sure about `librsvg`, because v2.42.0+ requires the Rust toolchain.
- [ ] Try to test the binaries with the Python test suite on Wine.
- [ ] Incorporate the llvm-mingw toolchain plugin into MXE (see [mxe/mxe#2330](https://github.com/mxe/mxe/issues/2330)).
- [ ] Test the `armv7-w64-mingw32` and `aarch64-w64-mingw32` targets. Perhaps there's a VM to test these architectures?
- [ ] Build LLVM for the target architecture (`-DLLVM_TARGETS_TO_BUILD=`) instead of constantly building all four architectures (i686, x86_64, armv7 and arm64).
- [ ] [`libffi`](8.9/libffi-3-fixes.patch), [`openslide`](8.9/openslide-3-fixes.patch) ([mstorsjo/llvm-mingw#67](https://github.com/mstorsjo/llvm-mingw/issues/67)), [`hdf5`](8.9/hdf5-1-fixes.patch) and [`glib`](8.9/glib-2-fixes.patch) needs llvm-mingw specific patches. Fix them upstream or within LLVM.
5 changes: 2 additions & 3 deletions container/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ RUN apt-get update \
RUN pip3 install meson

# TODO: Remove when https://github.com/mesonbuild/meson/pull/5912 is merged
RUN cd `python3 -c "import site; print(site.getsitepackages()[0])"` \
&& curl https://patch-diff.githubusercontent.com/raw/mesonbuild/meson/pull/5912.patch | git apply -v \
&& curl https://gist.githubusercontent.com/kleisauke/a2370bf67d1d8813cf8257c039488a79/raw/9b91bc3d3cd8244fb6c46c710cd85af080cbb166/meson.patch | git apply -v
RUN cd $(dirname `python3 -c "import mesonbuild as _; print(_.__path__[0])"`) \
&& curl https://gist.githubusercontent.com/kleisauke/a2370bf67d1d8813cf8257c039488a79/raw/c99122daaee097430aef0df88b87d449a0b36999/meson-llvm-mingw.patch | git apply -v

ARG ARCH=x86_64

Expand Down

0 comments on commit 89feab2

Please sign in to comment.