[gimp/wip/Jehan/native-win64-build: 1/4] gitlab-ci, build: testing native Windows build.
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/wip/Jehan/native-win64-build: 1/4] gitlab-ci, build: testing native Windows build.
- Date: Tue, 4 May 2021 21:23:53 +0000 (UTC)
commit 3361b180d1d9ff9fb03f7d2f7885a575b1dcb0ae
Author: Jehan <jehan girinstud io>
Date: Sun May 2 15:43:25 2021 +0200
gitlab-ci, build: testing native Windows build.
Just an initial test to get a hang of the thing, mostly inspired from
GTK gitlab-ci rules adapted to our build.
All in one job (deps, babl, GEGL, GIMP itself) for now, for simplicity
of debugging. We'll see later to break this into CI sub-jobs.
.gitlab-ci.yml | 12 ++++++
build/windows/build-msys2.sh | 97 ++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 109 insertions(+)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 6e2863e4c3..90e7b0584e 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -186,6 +186,18 @@ gimp-clang-debian:
## WINDOWS 64-bit CI ##
+gimp-native-win64:
+ variables:
+ MSYSTEM: "MINGW64"
+ CHERE_INVOKING: "yes"
+ stage: gimp
+ tags:
+ - win32-ps
+ script:
+ - C:\msys64\usr\bin\pacman --noconfirm -Syyuu
+ - C:\msys64\usr\bin\bash -lc "bash -x ./build/windows/build-msys2.sh"
+ needs: []
+
deps-win64:
rules:
- if: '$CI_COMMIT_TAG == null'
diff --git a/build/windows/build-msys2.sh b/build/windows/build-msys2.sh
new file mode 100644
index 0000000000..463f6031ed
--- /dev/null
+++ b/build/windows/build-msys2.sh
@@ -0,0 +1,97 @@
+#!/bin/bash
+
+set -e
+
+if [[ "$MSYSTEM" == "MINGW32" ]]; then
+ export MSYS2_ARCH="i686"
+else
+ export MSYS2_ARCH="x86_64"
+fi
+
+# Update everything
+pacman --noconfirm -Suy
+
+# Install the required packages
+pacman --noconfirm -S --needed \
+ base-devel \
+ mingw-w64-$MSYS2_ARCH-toolchain \
+ mingw-w64-$MSYS2_ARCH-ccache \
+ mingw-w64-$MSYS2_ARCH-pkg-config \
+ mingw-w64-$MSYS2_ARCH-meson \
+ \
+ mingw-w64-$MSYS2_ARCH-asciidoc \
+ mingw-w64-$MSYS2_ARCH-adwaita-icon-theme \
+ mingw-w64-$MSYS2_ARCH-appstream-glib \
+ mingw-w64-$MSYS2_ARCH-atk \
+ mingw-w64-$MSYS2_ARCH-cairo \
+ mingw-w64-$MSYS2_ARCH-drmingw \
+ mingw-w64-$MSYS2_ARCH-gexiv2 \
+ mingw-w64-$MSYS2_ARCH-ghostscript \
+ mingw-w64-$MSYS2_ARCH-glib-networking \
+ mingw-w64-$MSYS2_ARCH-gobject-introspection \
+ mingw-w64-$MSYS2_ARCH-gobject-introspection-runtime \
+ mingw-w64-$MSYS2_ARCH-graphviz \
+ mingw-w64-$MSYS2_ARCH-gtk3 \
+ mingw-w64-$MSYS2_ARCH-gtk-doc \
+ mingw-w64-$MSYS2_ARCH-iso-codes \
+ mingw-w64-$MSYS2_ARCH-json-c \
+ mingw-w64-$MSYS2_ARCH-json-glib \
+ mingw-w64-$MSYS2_ARCH-lcms2 \
+ mingw-w64-$MSYS2_ARCH-lensfun \
+ mingw-w64-$MSYS2_ARCH-libarchive \
+ mingw-w64-$MSYS2_ARCH-libepoxy \
+ mingw-w64-$MSYS2_ARCH-libheif \
+ mingw-w64-$MSYS2_ARCH-libmypaint \
+ mingw-w64-$MSYS2_ARCH-libraw \
+ mingw-w64-$MSYS2_ARCH-libspiro \
+ mingw-w64-$MSYS2_ARCH-libwebp \
+ mingw-w64-$MSYS2_ARCH-libwmf \
+ mingw-w64-$MSYS2_ARCH-luajit \
+ mingw-w64-$MSYS2_ARCH-maxflow \
+ mingw-w64-$MSYS2_ARCH-mypaint-brushes \
+ mingw-w64-$MSYS2_ARCH-openexr \
+ mingw-w64-$MSYS2_ARCH-pango \
+ mingw-w64-$MSYS2_ARCH-poppler \
+ mingw-w64-$MSYS2_ARCH-python3-gobject \
+ mingw-w64-$MSYS2_ARCH-SDL2 \
+ mingw-w64-$MSYS2_ARCH-shared-mime-info \
+ mingw-w64-$MSYS2_ARCH-suitesparse \
+ mingw-w64-$MSYS2_ARCH-vala \
+ mingw-w64-$MSYS2_ARCH-xpm-nox
+
+mkdir -p _ccache
+export CCACHE_BASEDIR="$(pwd)"
+export CCACHE_DIR="${CCACHE_BASEDIR}/_ccache"
+export CC="ccache gcc"
+
+export GIT_DEPTH=1
+export GIMP_PREFIX=`realpath ~/_install`
+export PATH="$GIMP_PREFIX/bin:$PATH"
+export PKG_CONFIG_PATH="${GIMP_PREFIX}/lib/pkgconfig:$PKG_CONFIG_PATH"
+export PKG_CONFIG_PATH="${GIMP_PREFIX}/share/pkgconfig:$PKG_CONFIG_PATH"
+export LD_LIBRARY_PATH="${GIMP_PREFIX}/lib:${LD_LIBRARY_PATH}"
+export ACLOCAL_FLAGS="-I/c/msys64/mingw64/share/aclocal"
+export XDG_DATA_DIRS="${GIMP_PREFIX}/share:/mingw64/share/"
+
+git clone --depth=${GIT_DEPTH} https://gitlab.gnome.org/GNOME/babl.git _babl
+git clone --depth=${GIT_DEPTH} https://gitlab.gnome.org/GNOME/gegl.git _gegl
+
+cd _babl
+meson -Dprefix="${GIMP_PREFIX}" -Dwith-docs=false _build
+ninja -v -C _build
+ninja -C _build install
+cd ../_gegl
+meson -Dprefix="${GIMP_PREFIX}" -Ddocs=false _build
+ninja -C _build
+ninja -C _build install
+cd ..
+
+# Build
+ccache --zero-stats
+ccache --show-stats
+
+./autogen.sh --prefix="${GIMP_PREFIX}"
+make -j4
+make install
+
+ccache --show-stats
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]