From c0e4652edfae0bbcdeb481d807c6b1075d9600c7 Mon Sep 17 00:00:00 2001 From: Ivan Molodetskikh Date: Tue, 12 Dec 2023 08:04:41 +0400 Subject: [PATCH] meson: Add tracy_public_deps list Currently functionally identical to before. Will be used in a subsequent commit for libunwind, which appears in a public header. --- meson.build | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/meson.build b/meson.build index 782e2f66..88397aa0 100644 --- a/meson.build +++ b/meson.build @@ -6,6 +6,9 @@ tracy_compile_args = [] # compiler flags shared between the capture library itself and the code using it tracy_common_args = [] +# dependencies that will be propagated to the users of the capture library +tracy_public_deps = [] + if get_option('tracy_enable') tracy_common_args += ['-DTRACY_ENABLE'] endif @@ -103,8 +106,6 @@ if tracy_shared_libs tracy_compile_args += ['-DTRACY_EXPORTS'] endif -threads_dep = dependency('threads') - if host_machine.system() == 'windows' tracy_compile_args += ['-DWINVER=0x0601', '-D_WIN32_WINNT=0x0601'] endif @@ -175,8 +176,10 @@ endif tracy_compile_args += tracy_common_args +tracy_deps = [dependency('threads')] + tracy_public_deps + tracy = library('tracy', tracy_src, tracy_header_files, - dependencies : [ threads_dep ], + dependencies : tracy_deps, include_directories : tracy_public_include_dirs, cpp_args : tracy_compile_args, override_options : override_options, @@ -193,7 +196,9 @@ if tracy_shared_libs endif pkg = import('pkgconfig') -pkg.generate(tracy, extra_cflags: tracy_dep_compile_args) +pkg.generate(tracy, + extra_cflags : tracy_dep_compile_args, + requires : tracy_public_deps) tracy_dep = declare_dependency( compile_args : tracy_dep_compile_args,