summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrancis Ricci <francisjricci@gmail.com>2016-05-18 16:05:52 +0000
committerFrancis Ricci <francisjricci@gmail.com>2016-05-18 16:05:52 +0000
commit233a364bd8c4bd244b675ff2b9dd3381d0e84e4e (patch)
treef35408acc95319059afd00d1ee7193fab4d90e53
parent38af4d6347ebf44c29bfcdef37d3feea058b8fc4 (diff)
downloadbcm5719-llvm-233a364bd8c4bd244b675ff2b9dd3381d0e84e4e.tar.gz
bcm5719-llvm-233a364bd8c4bd244b675ff2b9dd3381d0e84e4e.zip
[sanitizer] Allow dlopen/dlclose interception to be disabled from cmake
Summary: dlopen and dlclose interception are broken when RUNPATH is used: https://llvm.org/bugs/show_bug.cgi?id=27790 Reviewers: kutuzov.viktor.84, samsonov, dvyukov, eugenis, kcc Subscribers: kcc, filcab, kubabrecka, compnerd, llvm-commits Differential Revision: http://reviews.llvm.org/D20333 llvm-svn: 269947
-rw-r--r--compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h b/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
index 75b3a01edb4..d22f0f5f1e2 100644
--- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
@@ -280,8 +280,12 @@
#define SANITIZER_INTERCEPT_OBSTACK SI_LINUX_NOT_ANDROID
#define SANITIZER_INTERCEPT_FFLUSH SI_NOT_WINDOWS
#define SANITIZER_INTERCEPT_FCLOSE SI_NOT_WINDOWS
+
+#ifndef SANITIZER_INTERCEPT_DLOPEN_DLCLOSE
#define SANITIZER_INTERCEPT_DLOPEN_DLCLOSE \
SI_FREEBSD || SI_LINUX_NOT_ANDROID || SI_MAC
+#endif
+
#define SANITIZER_INTERCEPT_GETPASS SI_LINUX_NOT_ANDROID || SI_MAC
#define SANITIZER_INTERCEPT_TIMERFD SI_LINUX_NOT_ANDROID
OpenPOWER on IntegriCloud