INTERFACE_WEAK_FUNCTION(__asan_default_suppressions)
INTERFACE_WEAK_FUNCTION(__asan_on_error)
-#if defined(__x86_64__) && \
- !(defined(SANITIZER_MAC) || defined(SANITIZER_WINDOWS))
+#if defined(__x86_64__) && !defined(__APPLE__) && !defined(SANITIZER_WINDOWS)
# define ASAN_MEMORY_ACCESS_CALLBACK_ADD(s, reg, op) \
INTERFACE_FUNCTION(__asan_check_##op##_add_##s##_##reg)
// If you're changing this file, please also change
// ../Linux/interface_symbols.c
+// This is needed to run the preprocessor to exclude symbols guarded by platform
+// RUN: %clangxx -x c++-header -o - -E %p/../../../../lib/asan/asan_interface.inc \
+// RUN: | sed "s/INTERFACE_FUNCTION/\nINTERFACE_FUNCTION/g" > %t.asan_interface.inc
+
// RUN: %clangxx_asan -dead_strip -O2 %s -o %t.exe
//
// note: we can not use -D on Darwin.
// RUN: > %t.exports
//
// RUN: grep -e "INTERFACE_\(WEAK_\)\?FUNCTION" \
-// RUN: %p/../../../../lib/asan/asan_interface.inc \
+// RUN: %t.asan_interface.inc \
// RUN: %p/../../../../lib/ubsan/ubsan_interface.inc \
// RUN: %p/../../../../lib/sanitizer_common/sanitizer_common_interface.inc \
// RUN: %p/../../../../lib/sanitizer_common/sanitizer_common_interface_posix.inc \