summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarco Trevisan (Treviño) <mail@3v1n0.net>2024-05-08 23:11:30 +0200
committerMarco Trevisan (Treviño) <mail@3v1n0.net>2024-05-09 15:48:58 +0200
commit3de5264f2416d3587ad9acc4f489754cd0f6ef14 (patch)
tree31cdb79332e4e07dfcc55733f99d74bc55f3e215
parent5aafaa0cc9dc1b88235165128ff243626772745b (diff)
downloadglib-3de5264f2416d3587ad9acc4f489754cd0f6ef14.tar.gz
girrepository/tests: Add full gir dependencies on tests
Tests may have runtime dependencies that are related to the typelib dependencies, so we need to satify them or the tests will fail at runtime if we're not building their prerequisite for other reasons. That's saying that the tests are currently failing when explicitly running as standalone in meson. Co-Authored-By: Philip Withnall <philip@tecnocode.co.uk>
-rw-r--r--girepository/tests/meson.build40
1 files changed, 31 insertions, 9 deletions
diff --git a/girepository/tests/meson.build b/girepository/tests/meson.build
index 7f5b70964..a8e5b3d19 100644
--- a/girepository/tests/meson.build
+++ b/girepository/tests/meson.build
@@ -12,32 +12,54 @@ girepository_tests = {
# Some tests require GIR files to have been generated
if enable_gir
+ glib_gir_testing_dep = glib_gir
+ gobject_gir_testing_dep = [
+ glib_gir_testing_dep,
+ gobject_gir,
+ ]
+
+ gmodule_gir_testing_dep = [
+ glib_gir_testing_dep,
+ gmodule_gir,
+ ]
+
+ gio_gir_testing_dep = [
+ gobject_gir_testing_dep,
+ gmodule_gir_testing_dep,
+ gio_gir,
+ ]
+
+ girepository_gir_testing_dep = [
+ gio_gir_testing_dep,
+ girepository_gir,
+ ]
+
girepository_tests += {
'function-info' : {
'dependencies': [libffi_dep],
- 'depends': [glib_gir],
+ 'depends': glib_gir_testing_dep,
},
'object-info' : {
- 'depends': [gio_gir],
+ 'depends': gio_gir_testing_dep,
},
'registered-type-info' : {
- 'depends': [gobject_gir],
+ 'depends': gobject_gir_testing_dep,
},
'repository' : {
- 'depends': [glib_gir, gio_gir, gobject_gir],
+ 'depends': gio_gir_testing_dep,
},
'repository-search-paths' : {
'c_args': '-DGOBJECT_INTROSPECTION_LIBDIR="@0@"'.format(glib_libdir),
- 'depends': [glib_gir],
+ 'depends': glib_gir_testing_dep,
},
'struct-info' : {
- 'depends': [gobject_gir],
+ 'depends': gobject_gir_testing_dep,
},
'throws' : {
- 'depends': [glib_gir, gio_gir],
+ 'depends': gio_gir_testing_dep,
},
'union-info' : {
- 'depends': [glib_gir],
+ 'depends': glib_gir_testing_dep,
},
}
@@ -45,7 +67,7 @@ if enable_gir
girepository_tests += {
'autoptr-girepository' : {
'source' : 'autoptr.c',
- 'depends': [glib_gir, gio_gir],
+ 'depends': gio_gir_testing_dep,
},
}
endif