Skip to content

Commit 3274cc4

Browse files
committed
Reland "Add libdl_android to the Runtime (aka Bionic) APEX".
Before this it ended up in /system. Test: build & boot Test: adb shell find system apex -name libdl_android.so | xargs adb shell ls -l => apex/com.android.runtime/lib/bionic/libdl_android.so apex/com.android.runtime/lib64/bionic/libdl_android.so apex/com.android.runtime@1/lib/bionic/libdl_android.so apex/com.android.runtime@1/lib64/bionic/libdl_android.so system/lib/bootstrap/libdl_android.so system/lib/libdl_android.so -> /apex/com.android.runtime/lib/bionic/libdl_android.so system/lib64/bootstrap/libdl_android.so system/lib64/libdl_android.so -> /apex/com.android.runtime/lib64/bionic/libdl_android.so Test: atest CtsBionicTestCases Test: Repro in b/144343305#comment8 together with ag/9754153 Bug: 135753770 Bug: 144343305 Change-Id: I9ccd10b711223ca474e91741711b7b8efd521b2d
1 parent 2a8bca7 commit 3274cc4

File tree

3 files changed

+11
-0
lines changed

3 files changed

+11
-0
lines changed

CleanSpec.mk

+5
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,11 @@ $(call add-clean-step, rm -f $(PRODUCT_OUT)/system/lib64/libGLES*)
5757
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/root/bionic)
5858
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/bionic)
5959

60+
# Ensure libdl_android.so is (only) in the correct locations after the move into
61+
# the Runtime APEX.
62+
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/apex/com.android.runtime/lib{,64})
63+
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/lib{,64})
64+
6065
# ************************************************
6166
# NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST
6267
# ************************************************

apex/Android.bp

+1
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ apex {
2929
"libc",
3030
"libm",
3131
"libdl",
32+
"libdl_android",
3233
"libc_malloc_debug",
3334
"libc_malloc_hooks",
3435
],

libdl/Android.bp

+5
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,11 @@ cc_library {
185185
symbol_file: "libdl_android.map.txt",
186186
versions: ["10000"],
187187
},
188+
189+
apex_available: [
190+
"//apex_available:platform",
191+
"com.android.runtime",
192+
],
188193
}
189194

190195
ndk_library {

0 commit comments

Comments
 (0)