A lib in APK can depend on other libs in the same APK
This hasn't worked because the path /mnt/apk/lib/<abi> wasn't in the
search paths of the linker namespace that the library is loaded (which
is the default namespace).
Fixing that by creating a new linker namespace 'microdroid' that
inherits the settings from the default namespace but adds the library
directory to the search paths, and loading the library from that
namespace.
Bug: N/A
Test: atest MicrodroidHostTestCases
Change-Id: I30c4ce86a48b80fa65e3b5ffeb90561fa1d2544e
diff --git a/launcher/Android.bp b/launcher/Android.bp
index 2c3f093..93cae96 100644
--- a/launcher/Android.bp
+++ b/launcher/Android.bp
@@ -5,5 +5,8 @@
cc_binary {
name: "microdroid_launcher",
srcs: ["main.cpp"],
- shared_libs: ["libdl"],
+ shared_libs: [
+ "libdl",
+ "libdl_android",
+ ],
}