diff options
author | Gerald Combs <gerald@wireshark.org> | 2016-10-06 10:38:39 -0700 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2016-10-07 17:54:35 +0000 |
commit | 22d8142ce77fce18f87b1a0242f86bd198623d2f (patch) | |
tree | e4a7c2ad2321ca0df24b2caf0391ca5696975934 /configure.ac | |
parent | 827ae0c722dc686da9980478a6ff3db723993ea5 (diff) | |
download | wireshark-22d8142ce77fce18f87b1a0242f86bd198623d2f.tar.gz |
Disable ASAN when building lemon.
If ASAN is enabled, use "-fno-sanitize=all" when building lemon. This
keeps us from having to set ASAN_OPTIONS=detect_leaks=0 in the
environment in order to build Wireshark.
Change-Id: I36f6d1a4f913ecabaf188f4c2b59216c8430d81a
Reviewed-on: https://code.wireshark.org/review/18098
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 5487dd96a3..a13be50156 100644 --- a/configure.ac +++ b/configure.ac @@ -784,7 +784,21 @@ AC_ARG_ENABLE(asan, # XXX shouldn't this also be added to LDFLAGS? AC_WIRESHARK_COMPILER_FLAGS_CHECK(-fsanitize=address) + # Disable ASAN for build-time tools, e.g. lemon + WS_CFLAGS_saved="$WS_CFLAGS" + WS_LDFLAGS_saved="$WS_LDFLAGS" + AC_WIRESHARK_COMPILER_FLAGS_CHECK(-fno-sanitize=all, C) + if test "x$can_add_to_cflags" = "xyes" + then + NO_SANITIZE_CFLAGS="-fno-sanitize=all" + NO_SANITIZE_LDFLAGS="-fno-sanitize=all" + fi + WS_CFLAGS="$WS_CFLAGS_saved" + WS_LDFLAGS="$WS_LDFLAGS_saved" + ]) +AC_SUBST(NO_SANITIZE_CFLAGS) +AC_SUBST(NO_SANITIZE_LDFLAGS) # Add check hf conflict.. # |