From dc6c9d618f5de1fb5a219e531c46956858590ef4 Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Tue, 31 Jan 2017 14:45:44 +0100 Subject: [PATCH] Correctly ask link flags to pkg-config. If we are compiling a static binaries, all dependencies (including indirect dependencies) must be present on the command line. To have them, we have to add '--static' option to the pkg-config line. Meson does this for us, but we must ask it to do it with the 'static' argument. --- meson.build | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/meson.build b/meson.build index b47d6e7..ed8b61c 100644 --- a/meson.build +++ b/meson.build @@ -8,9 +8,9 @@ if static_linkage endif thread_dep = dependency('threads') -kiwixlib_dep = dependency('kiwix') -microhttpd_dep = dependency('libmicrohttpd') -z_dep = dependency('zlib') +kiwixlib_dep = dependency('kiwix', static:static_linkage) +microhttpd_dep = dependency('libmicrohttpd', static:static_linkage) +z_dep = dependency('zlib', static:static_linkage) # Idealy we should not have more dependency, however : # We should declare we use ctpp2 in kiwixlib in the pkg-config file.