diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2017-07-13 19:26:17 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2017-07-13 19:26:17 +0000 |
commit | e75e363cb71a7339552b9d943e78ac62b737379b (patch) | |
tree | 29ec5bd173694acbbcbb8207114ef7ca189436ba /source/Plugins/Platform/Android/PlatformAndroid.cpp | |
parent | 1b306c26ade71504511d2fa75b03dfaee77f9620 (diff) |
Notes
Diffstat (limited to 'source/Plugins/Platform/Android/PlatformAndroid.cpp')
-rw-r--r-- | source/Plugins/Platform/Android/PlatformAndroid.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/source/Plugins/Platform/Android/PlatformAndroid.cpp b/source/Plugins/Platform/Android/PlatformAndroid.cpp index d896a9f99e63..0f37da60d5d6 100644 --- a/source/Plugins/Platform/Android/PlatformAndroid.cpp +++ b/source/Plugins/Platform/Android/PlatformAndroid.cpp @@ -366,13 +366,17 @@ bool PlatformAndroid::GetRemoteOSVersion() { return m_major_os_version != 0; } -const char *PlatformAndroid::GetLibdlFunctionDeclarations() const { - return R"( +llvm::StringRef PlatformAndroid::GetLibdlFunctionDeclarations() { + // Older platform versions have the dl function symbols mangled + if (GetSdkVersion() < 26) + return R"( extern "C" void* dlopen(const char*, int) asm("__dl_dlopen"); extern "C" void* dlsym(void*, const char*) asm("__dl_dlsym"); extern "C" int dlclose(void*) asm("__dl_dlclose"); extern "C" char* dlerror(void) asm("__dl_dlerror"); )"; + + return PlatformPOSIX::GetLibdlFunctionDeclarations(); } AdbClient::SyncService *PlatformAndroid::GetSyncService(Status &error) { |