diff options
author | Martin Stjernholm <mast@google.com> | 2021-04-26 23:06:57 +0100 |
---|---|---|
committer | Treehugger Robot <treehugger-gerrit@google.com> | 2021-05-13 15:42:46 +0000 |
commit | b94401e6e15903b64de709fd69863b6880cedd7c (patch) | |
tree | cd1729038943aea0f3f1648109b095bb43d28530 /libnativeloader/public_libraries.cpp | |
parent | 3606cc69f5975d7ae81044a51706a6896d148781 (diff) |
Drop ANDROID_ADDITIONAL_PUBLIC_LIBRARIES.
It's not needed any more since libarttest(d).so is loaded from the ART
linker namespace.
Test: art/test/testrunner/testrunner.py --target --64 --optimizing
Bug: 130340935
Bug: 167578583
Change-Id: I785133e921277cb25360856e9af20fa681b54a3b
Diffstat (limited to 'libnativeloader/public_libraries.cpp')
-rw-r--r-- | libnativeloader/public_libraries.cpp | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/libnativeloader/public_libraries.cpp b/libnativeloader/public_libraries.cpp index b565133d6a..827be5b370 100644 --- a/libnativeloader/public_libraries.cpp +++ b/libnativeloader/public_libraries.cpp @@ -28,7 +28,6 @@ #include <android-base/file.h> #include <android-base/logging.h> -#include <android-base/properties.h> #include <android-base/result.h> #include <android-base/strings.h> #include <log/log.h> @@ -65,11 +64,6 @@ std::string root_dir() { return android_root_env != nullptr ? android_root_env : "/system"; } -bool debuggable() { - static bool debuggable = android::base::GetBoolProperty("ro.debuggable", false); - return debuggable; -} - std::string vndk_version_str(bool use_product_vndk) { if (use_product_vndk) { static std::string product_vndk_version = get_vndk_version(true); @@ -80,16 +74,6 @@ std::string vndk_version_str(bool use_product_vndk) { } } -// For debuggable platform builds use ANDROID_ADDITIONAL_PUBLIC_LIBRARIES environment -// variable to add libraries to the list. This is intended for platform tests only. -std::string additional_public_libraries() { - if (debuggable()) { - const char* val = getenv("ANDROID_ADDITIONAL_PUBLIC_LIBRARIES"); - return val ? val : ""; - } - return ""; -} - // insert vndk version in every {} placeholder void InsertVndkVersionStr(std::string* file_name, bool use_product_vndk) { CHECK(file_name != nullptr); @@ -175,12 +159,6 @@ static std::string InitDefaultPublicLibraries(bool for_preload) { return ""; } - std::string additional_libs = additional_public_libraries(); - if (!additional_libs.empty()) { - auto vec = base::Split(additional_libs, ":"); - std::copy(vec.begin(), vec.end(), std::back_inserter(*sonames)); - } - // If this is for preloading libs, don't remove the libs from APEXes. if (for_preload) { return android::base::Join(*sonames, ':'); @@ -189,11 +167,6 @@ static std::string InitDefaultPublicLibraries(bool for_preload) { // Remove the public libs provided by apexes because these libs are available // from apex namespaces. for (const auto& p : apex_public_libraries()) { - // TODO(b/167578583) remove this `if` block after fixing the bug - // Skip ART APEX to keep behaviors - if (p.first == "com_android_art") { - continue; - } auto public_libs = base::Split(p.second, ":"); sonames->erase(std::remove_if(sonames->begin(), sonames->end(), [&public_libs](const std::string& v) { return std::find(public_libs.begin(), public_libs.end(), v) != public_libs.end(); @@ -472,14 +445,6 @@ Result<std::map<std::string, std::string>> ParseApexLibrariesConfig(const std::s } entries[config_line->apex_namespace] = config_line->library_list; } - - // TODO(b/167578583) remove this `if` block after fixing the bug - if (tag == "public") { - std::string additional_libs = additional_public_libraries(); - if (!additional_libs.empty()) { - entries["com_android_art"] += ':' + additional_libs; - } - } return entries; } |