From e116a3774a96fdc791f8eaac3c20991b9caf98e4 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Thu, 27 Feb 2025 19:06:46 +0000 Subject: [PATCH 1/4] CI: Avoid hard-coding the version of Expat and GLib in use Signed-off-by: Simon McVittie --- tools/ci-build.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tools/ci-build.sh b/tools/ci-build.sh index 8752904d..40c1598b 100755 --- a/tools/ci-build.sh +++ b/tools/ci-build.sh @@ -214,12 +214,12 @@ case "$ci_host" in fi init_wine \ "${ci_builddir}/bin" \ - "${ci_builddir}/subprojects/expat-2.4.8" \ - "${ci_builddir}/subprojects/glib-2.72.2/gio" \ - "${ci_builddir}/subprojects/glib-2.72.2/glib" \ - "${ci_builddir}/subprojects/glib-2.72.2/gmodule" \ - "${ci_builddir}/subprojects/glib-2.72.2/gobject" \ - "${ci_builddir}/subprojects/glib-2.72.2/gthread" \ + "${ci_builddir}"/subprojects/expat-* \ + "${ci_builddir}"/subprojects/glib-*/gio \ + "${ci_builddir}"/subprojects/glib-*/glib \ + "${ci_builddir}"/subprojects/glib-*/gmodule \ + "${ci_builddir}"/subprojects/glib-*/gobject \ + "${ci_builddir}"/subprojects/glib-*/gthread \ "${dep_prefix}/bin" \ ${libgcc_path:+"$libgcc_path"} fi From 2537199d44127cbdb31b45a0ada1cf30aeb69004 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Thu, 27 Feb 2025 19:26:50 +0000 Subject: [PATCH 2/4] CI: Install meson from bookworm-backports when using GLib subproject Debian 12 'bookworm' has Meson 1.0.1, which is too old for the current stable branch of GLib. Use the version from bookworm-backports when running on Debian and building with a mingw-w64 compiler. We can stop doing this and put meson back in the normal list of packages when we update to the Debian 13 stable release, expected to be released in mid 2025. Signed-off-by: Simon McVittie --- tools/ci-install.sh | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/tools/ci-install.sh b/tools/ci-install.sh index c11665c9..72d2165f 100755 --- a/tools/ci-install.sh +++ b/tools/ci-install.sh @@ -91,9 +91,19 @@ case "$ci_distro" in ;; esac - $sudo apt-get -qq -y update packages=() + case "$ci_host/$ci_suite" in + (*-w64-mingw32/bookworm) + echo "deb https://deb.debian.org/debian bookworm-backports main" >> /etc/apt/sources.list.d/backports.list + packages=("${packages[@]}" meson/bookworm-backports) + ;; + + (*) + packages=("${packages[@]}" meson) + ;; + esac + case "$ci_host" in (i686-w64-mingw32) packages=( @@ -148,7 +158,6 @@ case "$ci_distro" in libsystemd-dev libx11-dev llvm - meson ninja-build sudo valgrind @@ -161,6 +170,7 @@ case "$ci_distro" in zstd ) + $sudo apt-get -qq -y update $sudo apt-get -qq -y --no-install-recommends install "${packages[@]}" packages=( From 5602dace0d45e1697d1c715e88d5b99579765223 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Thu, 27 Feb 2025 17:51:37 +0000 Subject: [PATCH 3/4] subprojects: Update fallback GLib subproject Updated with: meson wrap update We need a newer GLib when building on Windows using Meson, because the removal of distutils in recent versions of Python breaks older GLib. Signed-off-by: Simon McVittie --- subprojects/glib.wrap | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/subprojects/glib.wrap b/subprojects/glib.wrap index 3b1faf10..0dcb0b86 100644 --- a/subprojects/glib.wrap +++ b/subprojects/glib.wrap @@ -1,9 +1,10 @@ [wrap-file] -directory = glib-2.72.2 -source_url = https://download.gnome.org/sources/glib/2.72/glib-2.72.2.tar.xz -source_filename = glib-2.72.2.tar.xz -source_hash = 78d599a133dba7fe2036dfa8db8fb6131ab9642783fc9578b07a20995252d2de -wrapdb_version = 2.72.2-1 +directory = glib-2.82.5 +source_url = https://download.gnome.org/sources/glib/2.82/glib-2.82.5.tar.xz +source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/glib_2.82.5-1/glib-2.82.5.tar.xz +source_filename = glib-2.82.5.tar.xz +source_hash = 05c2031f9bdf6b5aba7a06ca84f0b4aced28b19bf1b50c6ab25cc675277cbc3f +wrapdb_version = 2.82.5-1 [provide] dependency_names = gthread-2.0, gobject-2.0, gmodule-no-export-2.0, gmodule-export-2.0, gmodule-2.0, glib-2.0, gio-2.0, gio-windows-2.0, gio-unix-2.0 From 0a3b1f9d11508b710ac88ea57acaece6561c8383 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Thu, 27 Feb 2025 19:16:02 +0000 Subject: [PATCH 4/4] CI: Never run the test suites of subprojects Some of them fail when run on Windows, and debugging the test suite for a subproject is out-of-scope for dbus. Signed-off-by: Simon McVittie --- .gitlab-ci.yml | 6 +++--- tools/ci-build.sh | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2aaed0cf..3a099c94 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -201,7 +201,7 @@ debian meson clang debug: - tar --strip-components=1 -C test/use-as-subproject/subprojects/dbus -xf $ci_builddir/meson-dist/*.tar.xz - meson setup --wrap-mode=forcefallback test/use-as-subproject/_build test/use-as-subproject - meson compile -C test/use-as-subproject/_build - - meson test -C test/use-as-subproject/_build + - "meson test -C test/use-as-subproject/_build dbus:" debian meson reduced: extends: @@ -387,7 +387,7 @@ windows-meson-mingw-ucrt64: - C:\msys64\usr\bin\bash -lc " meson build && ninja -j1 -C build && - meson test --no-suite=runs-dbus-daemon -C build" + meson test --no-suite=runs-dbus-daemon -C build dbus:" artifacts: reports: junit: "build/meson-logs/testlog.junit.xml" @@ -406,7 +406,7 @@ windows-meson-vs15-x86: - cmd.exe /C "C:\BuildTools\Common7\Tools\VsDevCmd.bat -host_arch=amd64 -arch=x86 && meson --force-fallback-for=expat,glib,zlib build && meson compile -C build && - meson test --no-suite=runs-dbus-daemon -C build" + meson test --no-suite=runs-dbus-daemon -C build dbus:" artifacts: reports: junit: "build/meson-logs/testlog.junit.xml" diff --git a/tools/ci-build.sh b/tools/ci-build.sh index 40c1598b..b258c951 100755 --- a/tools/ci-build.sh +++ b/tools/ci-build.sh @@ -465,7 +465,7 @@ case "$ci_buildsys" in # This is too slow and verbose to keep enabled at the moment export DBUS_TEST_MALLOC_FAILURES=0 - [ "$ci_test" = no ] || meson test --print-errorlogs + [ "$ci_test" = no ] || meson test dbus: --print-errorlogs DESTDIR=DESTDIR meson install ( cd DESTDIR && find . -ls)