From d18cb3937bdc2efede153abce1cd8ddae941d762 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Sun, 13 May 2018 22:28:24 +0200 Subject: Turn VALGRIND variable into a meson configuration switch Configuration through environment variable is inconvenient with meson, because they cannot be convieniently changed and/or are not preserved during reconfiguration (https://github.com/mesonbuild/meson/issues/1503). This adds -Dvalgrind=true/false, which has the advantage that it can be set at any time with meson configure -Dvalgrind=... and ninja will rebuild targets as necessary. Additional minor advantages are better consistency with the options for hashmap debugging, and typo avoidance with '#if' instead of '#ifdef'. --- meson_options.txt | 2 ++ 1 file changed, 2 insertions(+) (limited to 'meson_options.txt') diff --git a/meson_options.txt b/meson_options.txt index 3b718311a3..e3dea3ebc5 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -50,6 +50,8 @@ option('debug', type : 'array', choices : ['hashmap', 'mmap-cache'], value : [], description : 'enable extra debugging') option('memory-accounting-default', type : 'boolean', description : 'enable MemoryAccounting= by default') +option('valgrind', type : 'boolean', value : false, + description : 'do extra operations to avoid valgrind warnings') option('utmp', type : 'boolean', description : 'support for utmp/wtmp log handling') -- cgit v1.2.1