[gimp/wip/Jehan/native-win64-build: 1/2] build: do not build Windows dependencies with ccache.
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/wip/Jehan/native-win64-build: 1/2] build: do not build Windows dependencies with ccache.
- Date: Tue, 4 May 2021 20:09:14 +0000 (UTC)
commit 37d6decdb82bd3cbaa696874e34f25a9c613b10c
Author: Jehan <jehan girinstud io>
Date: Mon May 3 20:01:29 2021 +0200
build: do not build Windows dependencies with ccache.
The build rules were highly inspired by other projects on GNOME's
Gitlab. All of them used to build with ccache. It worked fine for the
main build, but completely broke GObject Introspection build on both
babl and GEGL. And the worse thing is that meson was absolutely not
displaying the error, just saying it failed (even in verbose mode). A
lot of time wasted trying to debug.
Therefore let's get rid of ccache, but only for babl and GEGL. Keep it
for GIMP itself as it works fine there.
Other minor changes:
* Build from the build dir, rather than source. The other way around
works too, but I actually find commands simpler this way.
* Adding artifacts.
.gitlab-ci.yml | 9 +++++++++
build/windows/build-msys2.sh | 37 ++++++++++++++++++++-----------------
2 files changed, 29 insertions(+), 17 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 90e7b0584e..467088d223 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -196,6 +196,15 @@ gimp-native-win64:
script:
- C:\msys64\usr\bin\pacman --noconfirm -Syyuu
- C:\msys64\usr\bin\bash -lc "bash -x ./build/windows/build-msys2.sh"
+ artifacts:
+ name: "GIMP-Win-native-${CI_COMMIT_SHORT_SHA}"
+ when: always
+ expire_in: 2 days
+ paths:
+ - _install
+ cache:
+ paths:
+ - _ccache/
needs: []
deps-win64:
diff --git a/build/windows/build-msys2.sh b/build/windows/build-msys2.sh
index 68bbe9183e..90a66adee5 100644
--- a/build/windows/build-msys2.sh
+++ b/build/windows/build-msys2.sh
@@ -73,14 +73,7 @@ pacman --noconfirm -S --needed \
mingw-w64-$MSYS2_ARCH-shared-mime-info \
mingw-w64-$MSYS2_ARCH-suitesparse \
mingw-w64-$MSYS2_ARCH-vala \
- mingw-w64-$MSYS2_ARCH-xpm-nox \
- mingw-w64-$MSYS2_ARCH-babl \
- mingw-w64-$MSYS2_ARCH-gegl
-
-mkdir -p _ccache
-export CCACHE_BASEDIR="$(pwd)"
-export CCACHE_DIR="${CCACHE_BASEDIR}/_ccache"
-export CC="ccache gcc"
+ mingw-w64-$MSYS2_ARCH-xpm-nox
export GIT_DEPTH=1
export GIMP_PREFIX=`realpath ~/_install`
@@ -89,21 +82,31 @@ 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 ..
+mkdir _babl/_build
+cd _babl/_build
+meson -Dprefix="${GIMP_PREFIX}" -Dwith-docs=false ..
+ninja
+ninja install
+
+mkdir ../../_gegl/_build
+cd ../../_gegl/_build
+meson -Dprefix="${GIMP_PREFIX}" -Ddocs=false ..
+ninja
+ninja install
+cd ../..
# Build
+
+mkdir -p _ccache
+export CCACHE_BASEDIR="$(pwd)"
+export CCACHE_DIR="${CCACHE_BASEDIR}/_ccache"
+export CC="ccache gcc"
+
ccache --zero-stats
ccache --show-stats
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]