summaryrefslogtreecommitdiff
path: root/service
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2018-08-21 22:44:51 +0100
committerEmmanuele Bassi <ebassi@gnome.org>2018-08-21 22:47:12 +0100
commitbf103302332603a637f1c33e603c93b82aa1dc0b (patch)
tree080adc464ab417ad277ae6a278ef9bb6e0fedb8e /service
parenta060755f30e5c89882b160e7f284eee003a960ec (diff)
downloaddconf-bf103302332603a637f1c33e603c93b82aa1dc0b.tar.gz
Declare libdconf_service as a dependency
The dconf-service internal static library depends on generated files, and we need to make sure that those files are available by the time we build the tests that depend on them, as Meson builds everything in parallel. If we don't do that, in cases of massive parallelised builders, we will end up with errors like: ``` ccache cc -Itests/tests@@writer@exe -Itests -I../tests -I. -I../ -Itests/../service -I../tests/../service -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -O0 -g '-DSYSCONFDIR="/etc"' -fno-common -Wmissing-prototypes -Wwrite-strings -O2 -g -m64 -mtune=generic '-DSRCDIR="/ostbuild/source/dconf/tests"' -MD -MQ 'tests/tests@@writer@exe/writer.c.o' -MF 'tests/tests@@writer@exe/writer.c.o.d' -o 'tests/tests@@writer@exe/writer.c.o' -c ../tests/writer.c ../tests/writer.c:24:37: fatal error: service/dconf-generated.h: No such file or directory ``` Reviewed-by: nobody Signed-off-by: Emmanuele Bassi <ebassi@gnome.org>
Diffstat (limited to 'service')
-rw-r--r--service/meson.build10
1 files changed, 9 insertions, 1 deletions
diff --git a/service/meson.build b/service/meson.build
index 35ee23a..7d54805 100644
--- a/service/meson.build
+++ b/service/meson.build
@@ -23,13 +23,15 @@ sources = [
'main.c',
]
-lib_sources += gnome.gdbus_codegen(
+dconf_generated = gnome.gdbus_codegen(
'dconf-generated',
dconf_namespace + '.xml',
interface_prefix: dconf_namespace + '.',
namespace: 'DConfDBus',
)
+lib_sources += dconf_generated
+
libdconf_service = static_library(
'dconf-service',
sources: lib_sources,
@@ -43,6 +45,12 @@ libdconf_service = static_library(
],
)
+libdconf_service_dep = declare_dependency(
+ link_with: libdconf_service,
+ dependencies: gio_unix_dep,
+ sources: dconf_generated,
+)
+
executable(
'dconf-service',
sources,