diff options
author | Sergey Matveev <earthdok@google.com> | 2013-11-25 15:54:31 +0000 |
---|---|---|
committer | Sergey Matveev <earthdok@google.com> | 2013-11-25 15:54:31 +0000 |
commit | 0380ce26879d1bb7a63cdd1f34e0b45fb8ae5544 (patch) | |
tree | b968e3dc7669a2f266b8a1c12a3608482d7874e8 /lib/lsan/lsan_preinit.cc | |
parent | 97c1b2981de0a714d97fe03ff8bca9abacccb4c4 (diff) | |
download | compiler-rt-0380ce26879d1bb7a63cdd1f34e0b45fb8ae5544.tar.gz |
[lsan] Unbreak lsan_testlib.cc.
Also, add missing logging output.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@195652 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/lsan/lsan_preinit.cc')
-rw-r--r-- | lib/lsan/lsan_preinit.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/lsan/lsan_preinit.cc b/lib/lsan/lsan_preinit.cc index a631f9a3e..e6639516d 100644 --- a/lib/lsan/lsan_preinit.cc +++ b/lib/lsan/lsan_preinit.cc @@ -14,7 +14,11 @@ #include "lsan.h" -#if !defined(PIC) +#ifndef LSAN_USE_PREINIT_ARRAY +#define LSAN_USE_PREINIT_ARRAY 1 +#endif + +#if LSAN_USE_PREINIT_ARRAY && !defined(PIC) // We force __lsan_init to be called before anyone else by placing it into // .preinit_array section. __attribute__((section(".preinit_array"), used)) |