Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CHG: [droid] remove android dload specifics #12282

Merged
merged 1 commit into from Jun 11, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 0 additions & 1 deletion cmake/treedata/android/subdirs.txt
Expand Up @@ -12,4 +12,3 @@ xbmc/windowing/android windowing/android
xbmc/platform/posix posix
xbmc/platform/android/activity android_activity
xbmc/platform/android/bionic_supplement android_bionicsupplement
xbmc/platform/android/loader android_loader
8 changes: 0 additions & 8 deletions tools/android/packaging/xbmc/src/org/xbmc/kodi/Main.java.in
Expand Up @@ -88,14 +88,6 @@ public class Main extends NativeActivity implements Choreographer.FrameCallback
@Override
public void onCreate(Bundle savedInstanceState)
{
// The dynamic linker on droid is a mess.
// Depending on version, it might not be able to properly resolve
try
{
// Surround with try-catch to allow static version (3.0)
System.loadLibrary("smbclient");
}
catch (UnsatisfiedLinkError e) {}
System.loadLibrary("@APP_NAME_LC@");

super.onCreate(savedInstanceState);
Expand Down
4 changes: 0 additions & 4 deletions xbmc/Application.cpp
Expand Up @@ -2801,10 +2801,6 @@ bool CApplication::Cleanup()
CLibcdio::ReleaseInstance();
#endif
#endif
#if defined(TARGET_ANDROID)
// enable for all platforms once it's safe
g_sectionLoader.UnloadAll();
#endif
#ifdef _CRTDBG_MAP_ALLOC
_CrtDumpMemoryLeaks();
while(1); // execution ends
Expand Down
13 changes: 0 additions & 13 deletions xbmc/cores/DllLoader/SoLoader.cpp
Expand Up @@ -22,9 +22,6 @@
#include "SoLoader.h"
#include "filesystem/SpecialProtocol.h"
#include "utils/log.h"
#if defined(TARGET_ANDROID)
#include "platform/android/loader/AndroidDyload.h"
#endif

SoLoader::SoLoader(const std::string &so, bool bGlobal) : LibraryLoader(so)
{
Expand Down Expand Up @@ -53,13 +50,8 @@ bool SoLoader::Load()
else
{
CLog::Log(LOGDEBUG, "Loading: %s\n", strFileName.c_str());
#if defined(TARGET_ANDROID)
CAndroidDyload temp;
m_soHandle = temp.Open(strFileName.c_str());
#else
int flags = RTLD_LAZY;
m_soHandle = dlopen(strFileName.c_str(), flags);
#endif
if (!m_soHandle)
{
CLog::Log(LOGERROR, "Unable to load %s, reason: %s", strFileName.c_str(), dlerror());
Expand All @@ -75,12 +67,7 @@ void SoLoader::Unload()

if (m_soHandle)
{
#if defined(TARGET_ANDROID)
CAndroidDyload temp;
if (temp.Close(m_soHandle) != 0)
#else
if (dlclose(m_soHandle) != 0)
#endif
CLog::Log(LOGERROR, "Unable to unload %s, reason: %s", GetName(), dlerror());
}
m_bLoaded = false;
Expand Down
9 changes: 2 additions & 7 deletions xbmc/cores/DllLoader/exports/emu_msvcrt.cpp
Expand Up @@ -74,9 +74,7 @@
#include "utils/CharsetConverter.h"
#include "utils/URIUtils.h"
#endif
#if defined(TARGET_ANDROID)
#include "platform/android/loader/AndroidDyload.h"
#elif !defined(TARGET_WINDOWS)
#if !defined(TARGET_WINDOWS)
#include <dlfcn.h>
#endif
#include "utils/Environment.h"
Expand Down Expand Up @@ -460,10 +458,7 @@ extern "C"

void *dll_dlopen(const char *filename, int flag)
{
#if defined(TARGET_ANDROID)
CAndroidDyload temp;
return temp.Open(filename);
#elif !defined(TARGET_WINDOWS)
#if !defined(TARGET_WINDOWS)
return dlopen(filename, flag);
#else
return NULL;
Expand Down
4 changes: 0 additions & 4 deletions xbmc/cores/DllLoader/exports/wrapper.c
Expand Up @@ -117,11 +117,7 @@ struct mntent *dll_getmntent(FILE *fp);

void *__wrap_dlopen(const char *filename, int flag)
{
#if defined(TARGET_ANDROID)
return dll_dlopen(filename, flag);
#else
return dlopen(filename, flag);
#endif
}

FILE *__wrap_popen(const char *command, const char *mode)
Expand Down