diff options
author | Dmitry Vyukov <dvyukov@google.com> | 2013-09-03 07:53:49 +0000 |
---|---|---|
committer | Dmitry Vyukov <dvyukov@google.com> | 2013-09-03 07:53:49 +0000 |
commit | 23b80ab87f3bc372fa3a317877d266fc8eff0dd0 (patch) | |
tree | 90e2f1069ec7832a985f7ff701fd0d47a9f723a5 /compiler-rt/lib/interception | |
parent | 59039dc1bfaca145e071331362cd73cedc1bb190 (diff) | |
download | bcm5719-llvm-23b80ab87f3bc372fa3a317877d266fc8eff0dd0.tar.gz bcm5719-llvm-23b80ab87f3bc372fa3a317877d266fc8eff0dd0.zip |
asan: fix android build
android does not have dlvsym
llvm-svn: 189781
Diffstat (limited to 'compiler-rt/lib/interception')
-rw-r--r-- | compiler-rt/lib/interception/interception_linux.cc | 2 | ||||
-rw-r--r-- | compiler-rt/lib/interception/interception_linux.h | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/compiler-rt/lib/interception/interception_linux.cc b/compiler-rt/lib/interception/interception_linux.cc index 67caca32cd2..53f42881016 100644 --- a/compiler-rt/lib/interception/interception_linux.cc +++ b/compiler-rt/lib/interception/interception_linux.cc @@ -24,9 +24,11 @@ bool GetRealFunctionAddress(const char *func_name, uptr *func_addr, return real == wrapper; } +#if !defined(__ANDROID__) // android does not have dlvsym void *GetFuncAddrVer(const char *func_name, const char *ver) { return dlvsym(RTLD_NEXT, func_name, ver); } +#endif // !defined(__ANDROID__) } // namespace __interception diff --git a/compiler-rt/lib/interception/interception_linux.h b/compiler-rt/lib/interception/interception_linux.h index 200a9ae7d41..4c6f97a9d96 100644 --- a/compiler-rt/lib/interception/interception_linux.h +++ b/compiler-rt/lib/interception/interception_linux.h @@ -34,10 +34,12 @@ void *GetFuncAddrVer(const char *func_name, const char *ver); (::__interception::uptr)&(func), \ (::__interception::uptr)&WRAP(func)) +#if !defined(__ANDROID__) // android does not have dlvsym #define INTERCEPT_FUNCTION_VER(func, funcver, symver) \ __asm__(".symver "#funcver","#func"@"#symver); \ ::__interception::real_##funcver = (funcver##_f)(unsigned long) \ ::__interception::GetFuncAddrVer(#func, #symver) +#endif // !defined(__ANDROID__) #endif // INTERCEPTION_LINUX_H #endif // __linux__ |