diff --git a/meson.build b/meson.build index 4b0e976ff..a3904becc 100644 --- a/meson.build +++ b/meson.build @@ -56,7 +56,8 @@ deps_libpistache = [ ] if get_option('PISTACHE_USE_RAPIDJSON') - deps_libpistache += dependency('RapidJSON', fallback: ['rapidjson', 'rapidjson_dep']) + rapidjson_dep = dependency('RapidJSON', fallback: ['rapidjson', 'rapidjson_dep']) + deps_libpistache += rapidjson_dep endif # Support Brotli compressed Content-Encoding responses... diff --git a/src/meson.build b/src/meson.build index c3a0283b7..309a6d4ae 100644 --- a/src/meson.build +++ b/src/meson.build @@ -76,7 +76,8 @@ libpistache = library( pistache_dep = declare_dependency( compile_args: public_args, include_directories: incl_pistache, - link_with: libpistache + link_with: libpistache, + dependencies: [ rapidjson_dep ] ) if meson.version().version_compare('>=0.54.0')