Remove hardcoded "-fsanitize=address"

"-fsanitize=address" which pulls in asan does not work with other
sanitizers like msan/tsan etc.

Based on original change by manojgupta@chromium.org.

Signed-off-by: David Riley <davidriley@chromium.org>
Reviewed-by: Lepton Wu <lepton@chromium.org>
macos/master
David Riley 5 years ago committed by Lepton Wu
parent 0a97971cee
commit 10854be913
  1. 1
      tests/fuzzer/Makefile.am
  2. 4
      tests/fuzzer/meson.build
  3. 1
      vtest/Makefile.am
  4. 4
      vtest/meson.build

@ -11,7 +11,6 @@ AM_CFLAGS = \
$(EPOXY_CFLAGS) \
$(VISIBILITY_CFLAGS) \
$(CODE_COVERAGE_CFLAGS) \
-fsanitize=address \
-fsanitize=fuzzer
if FUZZER

@ -27,7 +27,7 @@ assert(cc.has_argument('-fsanitize=fuzzer'),
virgl_fuzzer = executable(
'virgl_fuzzer',
'virgl_fuzzer.c',
c_args : [ '-fsanitize=address', '-fsanitize=fuzzer' ],
link_args : [ '-fsanitize=address', '-fsanitize=fuzzer' ],
c_args : [ '-fsanitize=fuzzer' ],
link_args : [ '-fsanitize=fuzzer' ],
dependencies : [libvirglrenderer_dep, gallium_dep, epoxy_dep]
)

@ -50,7 +50,6 @@ vtest_fuzzer_CFLAGS = \
$(EPOXY_CFLAGS) \
$(VISIBILITY_CFLAGS) \
$(CODE_COVERAGE_CFLAGS) \
-fsanitize=address \
-fsanitize=fuzzer
vtest_fuzzer_LDADD = $(top_builddir)/src/gallium/auxiliary/libgallium.la $(top_builddir)/src/libvirglrenderer.la

@ -52,8 +52,8 @@ if with_fuzzer
vtest_fuzzer = executable(
'vtest_fuzzer',
'vtest_fuzzer.c',
c_args : [ '-fsanitize=address', '-fsanitize=fuzzer' ],
link_args : [ '-fsanitize=address', '-fsanitize=fuzzer' ],
c_args : [ '-fsanitize=fuzzer' ],
link_args : [ '-fsanitize=fuzzer' ],
objects : vtest_obj,
dependencies : libvirglrenderer_dep
)

Loading…
Cancel
Save