Commit 501c13b1 authored by Benoît Lizé's avatar Benoît Lizé Committed by Commit Bot

android: Remove the ability to load multiple library in custom linkers.

This was unused since at least 2016 (see crbug.com/657093). Remove the code to
support this both in LegacyLinker and ModernLinker. In the process, further
unify the two linkers, and refactor state tracking.

Bug: 979638

Change-Id: I4fad98228a841e1959a93f8ef5dbe5d29dfe7f30
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1715485Reviewed-by: default avatarYaron Friedman <yfriedman@chromium.org>
Reviewed-by: default avatarAndrew Grieve <agrieve@chromium.org>
Reviewed-by: default avatarEgor Pasko <pasko@chromium.org>
Commit-Queue: Benoit L <lizeb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#683155}
parent ebf680f8
...@@ -420,22 +420,6 @@ bool LoadNoSharedRelocations(const String& path) { ...@@ -420,22 +420,6 @@ bool LoadNoSharedRelocations(const String& path) {
} // namespace } // namespace
// Get the CPU ABI string for which the linker is running.
//
// The returned string is used to construct the path to libchrome.so when
// loading directly from APK.
//
// |env| is the current JNI environment handle.
// |clazz| is the static class handle for org.chromium.base.Linker,
// and is ignored here.
// Returns the CPU ABI string for which the linker is running.
JNI_GENERATOR_EXPORT jstring
Java_org_chromium_base_library_1loader_ModernLinker_nativeGetCpuAbi(
JNIEnv* env,
jclass clazz) {
return env->NewStringUTF(CURRENT_ABI);
}
JNI_GENERATOR_EXPORT jboolean JNI_GENERATOR_EXPORT jboolean
Java_org_chromium_base_library_1loader_ModernLinker_nativeLoadLibraryCreateRelros( Java_org_chromium_base_library_1loader_ModernLinker_nativeLoadLibraryCreateRelros(
JNIEnv* env, JNIEnv* env,
......
...@@ -83,9 +83,7 @@ public class ContentChildProcessServiceDelegate implements ChildProcessServiceDe ...@@ -83,9 +83,7 @@ public class ContentChildProcessServiceDelegate implements ChildProcessServiceDe
if (LibraryLoader.useChromiumLinker() && !LibraryLoader.getInstance().isLoadedByZygote()) { if (LibraryLoader.useChromiumLinker() && !LibraryLoader.getInstance().isLoadedByZygote()) {
Bundle sharedRelros = connectionBundle.getBundle(Linker.EXTRA_LINKER_SHARED_RELROS); Bundle sharedRelros = connectionBundle.getBundle(Linker.EXTRA_LINKER_SHARED_RELROS);
if (sharedRelros != null) { if (sharedRelros != null) getLinker().provideSharedRelros(sharedRelros);
getLinker().useSharedRelros(sharedRelros);
}
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment