Relocate the external headers provided by ASan and the common sanitizer
commitd865fecddccebf898ceed24d096fc58fb29a6e57
authorChandler Carruth <chandlerc@gmail.com>
Wed, 29 Aug 2012 02:27:54 +0000 (29 02:27 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Wed, 29 Aug 2012 02:27:54 +0000 (29 02:27 +0000)
tree6aa00a92d9ddfa7e410220474c42c4313746450b
parent60ab090deed8213613643729a7921ef0915ac704
Relocate the external headers provided by ASan and the common sanitizer
library.

These headers are intended to be available to user code when built with
AddressSanitizer (or one of the other sanitizer's in the future) to
interface with the runtime library. As such, they form stable external
C interfaces, and the headers shouldn't be located within the
implementation.

I've pulled them out into what seem like fairly obvious locations and
names, but I'm wide open to further bikeshedding of these names and
locations.

I've updated the code and the build system to cope with the new
locations, both CMake and Makefile. Please let me know if this breaks
anyone's build.

The eventual goal is to install these headers along side the Clang
builtin headers when we build the ASan runtime and install it. My
current thinking is to locate them at:

  <prefix>/lib/clang/X.Y/include/sanitizer/common_interface_defs.h
  <prefix>/lib/clang/X.Y/include/sanitizer/asan_interface.h
  <prefix>/lib/clang/X.Y/include/sanitizer/...

But maybe others have different suggestions?

Fixing the style of the #include between these headers at least unblocks
experimentation with installing them as they now should work when
installed in these locations.

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@162822 91177308-0d34-0410-b5e6-96231b3b80d8
18 files changed:
CMakeLists.txt
include/sanitizer/asan_interface.h [moved from lib/asan/asan_interface.h with 97% similarity]
include/sanitizer/common_interface_defs.h [moved from lib/sanitizer_common/sanitizer_interface_defs.h with 89% similarity]
lib/asan/asan_allocator.cc
lib/asan/asan_flags.h
lib/asan/asan_globals.cc
lib/asan/asan_interceptors.cc
lib/asan/asan_poisoning.cc
lib/asan/asan_report.h
lib/asan/asan_rtl.cc
lib/asan/asan_stack.cc
lib/asan/asan_stats.cc
lib/asan/lit_tests/interface_symbols.c
lib/asan/output_tests/test_output.sh
lib/asan/tests/asan_noinst_test.cc
lib/sanitizer_common/sanitizer_internal_defs.h
lib/sanitizer_common/sanitizer_libc.h
make/config.mk