meson: Fix DLL search path during test execution on Windows
authorJakub Adam <jakub.adam@collabora.com>
Wed, 2 Jan 2019 11:55:02 +0000 (12:55 +0100)
committerJakub Adam <jakub.adam@collabora.com>
Wed, 2 Jan 2019 12:06:10 +0000 (13:06 +0100)
Meson needs to see all libraries a target depends on so that it can add
each to PATH when running "meson test".

Avoids "*.dll was not found" errors.

nice/meson.build
stun/tests/meson.build

index 12b99b2..9c0cdd4 100644 (file)
@@ -52,7 +52,8 @@ endif
 libnice_dep = declare_dependency(link_with : libnice,
   include_directories : [agent_include, nice_include],
   # Everything that uses libnice needs this built to compile
-  sources : nice_gen_sources)
+  sources : nice_gen_sources,
+  dependencies: nice_deps)
 
 # pkg-config file
 pkg = import('pkgconfig')
index 591cb4e..6018073 100644 (file)
@@ -2,7 +2,7 @@ foreach t : ['parse', 'format', 'bind', 'conncheck', 'hmac']
   test_name = 'test-@0@'.format(t)
   exe = executable(test_name, test_name + '.c',
     include_directories: nice_incs,
-    dependencies: syslibs,
+    dependencies: [syslibs, crypto_dep],
     link_with: libstun)
   test(test_name, exe)
 endforeach