From 31109635d3dc6692fb7488cf5c658bcd328fbce6 Mon Sep 17 00:00:00 2001 From: Florian Schmaus <flow@cs.fau.de> Date: Mon, 7 Dec 2020 09:55:42 +0100 Subject: [PATCH] [build] Use emper_dep where sensible, introduce emper_full_dep --- apps/meson.build | 6 ++---- emper/meson.build | 5 +++++ tests/meson.build | 7 +++---- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/apps/meson.build b/apps/meson.build index 11145717..7ed455b2 100644 --- a/apps/meson.build +++ b/apps/meson.build @@ -1,13 +1,11 @@ fib_exe = executable( 'fib', 'Main.cpp', - include_directories: emper_all_include, - link_with: [emper], + dependencies: emper_dep, ) worker_sleep_example_exe = executable( 'worker_sleep_example', 'WorkerSleepExample.cpp', - include_directories: emper_all_include, - link_with: [emper], + dependencies: emper_dep, ) diff --git a/emper/meson.build b/emper/meson.build index f73891a7..a175f3b7 100644 --- a/emper/meson.build +++ b/emper/meson.build @@ -71,3 +71,8 @@ emper_c_dep = declare_dependency( include_directories : emper_all_include, link_with : emper_c ) + +emper_full_dep = [ + emper_dep, + emper_c_dep, +] diff --git a/tests/meson.build b/tests/meson.build index c88ddd48..b6cbcd96 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -64,9 +64,9 @@ foreach source, test_dict : tests # The test_name is the name of the source file without the file suffix. test_name = source.split('.')[0] - test_dep = [thread_dep] + test_deps = [thread_dep] if test_dict.has_key('dependencies') - test_dep += test_dict['dependencies'] + test_deps += test_dict['dependencies'] endif test_exe = executable(test_name, @@ -74,8 +74,7 @@ foreach source, test_dict : tests include_directories: emper_all_include, c_args: undef_ndebug, cpp_args: undef_ndebug, - dependencies: emper_dependencies + test_dep, - link_with: [emper, emper_c], + dependencies: [emper_full_dep] + test_deps, ) test(test_name, -- GitLab