aports/main/glib/tests-machine-id.patch
Natanael Copa 66e193260a main/glib: bootstrap with gobject-introspection
glib now needs to be built in two stages, first without gobject
introspection and then a second build with introspection.

Also enable and fix tests

ref: https://gitlab.gnome.org/GNOME/glib/-/issues/3317
ref: https://gitlab.gnome.org/GNOME/glib/-/blob/main/NEWS?ref_type=heads#L296
2024-04-04 20:19:33 +00:00

41 lines
1.5 KiB
Diff

From 5cf08a9a1041a9dc9975371fb62f8f22c3be76c4 Mon Sep 17 00:00:00 2001
From: Natanael Copa <ncopa@alpinelinux.org>
Date: Wed, 3 Apr 2024 21:25:04 +0200
Subject: [PATCH 2/3] tests: skip gio tests which fails with missing machine-id
Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
---
gio/tests/meson.build | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/gio/tests/meson.build b/gio/tests/meson.build
index f04ff43ff..71ec09750 100644
--- a/gio/tests/meson.build
+++ b/gio/tests/meson.build
@@ -46,6 +46,8 @@ if glib_build_shared
subdir('modules')
endif
+have_machine_id = import('fs').is_file('/etc/machine-id')
+
# Test programs buildable on all platforms
gio_tests = {
'application-command-line': {},
@@ -98,7 +100,7 @@ gio_tests = {
'install_rpath' : installed_tests_execdir,
# FIXME: https://gitlab.gnome.org/GNOME/glib/-/issues/1392
# FIXME: https://gitlab.gnome.org/GNOME/glib/-/issues/3148
- 'can_fail' : host_system in ['darwin', 'windows', 'gnu'],
+ 'can_fail' : host_system in ['darwin', 'windows', 'gnu'] or not have_machine_id,
},
'inet-address' : {},
'io-stream' : {},
@@ -147,7 +149,7 @@ gio_tests = {
'extra_programs': host_system != 'windows' ? ['dbus-launch'] : [],
# FIXME: https://gitlab.gnome.org/GNOME/glib/-/issues/1392
# FIXME: https://gitlab.gnome.org/GNOME/glib/-/issues/3148
- 'can_fail' : host_system in ['darwin', 'gnu'],
+ 'can_fail' : host_system in ['darwin', 'gnu'] or not have_machine_id,
},
'win32-appinfo' : {},
}