From 5efc88df67d53b3c44f540da6559f6be6c1e43c2 Mon Sep 17 00:00:00 2001 From: Fred Morcos Date: Tue, 8 Aug 2023 13:34:07 +0200 Subject: [PATCH] Meson: Malloc trace --- meson.build | 1 + meson/malloc-trace/meson.build | 4 ++++ meson_options.txt | 1 + 3 files changed, 6 insertions(+) create mode 100644 meson/malloc-trace/meson.build diff --git a/meson.build b/meson.build index 3a8209c758..e5f5103303 100644 --- a/meson.build +++ b/meson.build @@ -71,6 +71,7 @@ subdir('meson/systemd') # Systemd and unit file handling subdir('meson/auto-var-init') # Automatic Variable Initialization # TODO Use meson's -Db_sanitize option? # subdir('meson/sanitizers') # Sanitizers +subdir('meson/malloc-trace') # Malloc-trace # Find or generate pdns/dnslabeltext.cc if not ragel.found() and not fs.exists('pdns/dnslabeltext.cc') diff --git a/meson/malloc-trace/meson.build b/meson/malloc-trace/meson.build new file mode 100644 index 0000000000..1f48637ba8 --- /dev/null +++ b/meson/malloc-trace/meson.build @@ -0,0 +1,4 @@ +# Malloc-trace + +opt_malloc_trace = get_option('malloc-trace') +conf.set10('MALLOC_TRACE', opt_malloc_trace, description: 'Enable malloc-trace') diff --git a/meson_options.txt b/meson_options.txt index 75c71e43b0..e1cd4b10f8 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -55,3 +55,4 @@ option('auto-var-init', type: 'combo', value: 'disabled', choices: ['zero', 'pat # option('sanitizer-thread', type: 'boolean', value: false, description: 'Enable the Thread Sanitizer') # option('sanitizer-leak', type: 'boolean', value: false, description: 'Enable the Leak Sanitizer') # option('sanitizer-undefined', type: 'boolean', value: false, description: 'Enable the Undefined Behavior Sanitizer') +option('malloc-trace', type: 'boolean', value: false, description: 'Enable malloc-trace') -- 2.47.2