aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2022-04-20 06:13:13 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2022-04-20 06:13:13 +0000
commit290db7ffda2590ff26037056c50d367583af0069 (patch)
tree217027f9e7c9b6816d51c110ad4ce50ccf8dd5f9
parent290a1979eb2d43b7b086862ad236d20020a2c1ab (diff)
parent4a185dd7b5c398710893c68560d18264369b89c2 (diff)
downloadmusl-290db7ffda2590ff26037056c50d367583af0069.tar.gz
Add more files to the musl sysroot for rustc builds am: 76db034975 am: 8d59cc3dff am: 4a185dd7b5t_frc_odp_330442040t_frc_odp_330442000t_frc_ase_330444010android13-frc-odp-releaseandroid13-dev
Original change: https://android-review.googlesource.com/c/platform/external/musl/+/2063092 Change-Id: Ic905f777b016b7e1f2d1b4920bda725d5ab73daa Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
-rw-r--r--Android.bp13
1 files changed, 13 insertions, 0 deletions
diff --git a/Android.bp b/Android.bp
index 4dcff0c4..d6d7c642 100644
--- a/Android.bp
+++ b/Android.bp
@@ -723,6 +723,7 @@ cc_genrule {
":libc_musl_static",
":libc++abi",
":libc++",
+ ":libc++_static",
// Objects
":libc_musl_crti",
@@ -730,6 +731,8 @@ cc_genrule {
":libc_musl_crt1",
":libc_musl_rcrt1",
":libc_musl_Scrt1",
+ ":clang_rt.crtbegin",
+ ":clang_rt.crtend",
// Embedded linker objects and linker scripts
":libc_musl_linker_object",
@@ -796,10 +799,14 @@ cc_genrule {
" -f $(location :libc_musl_sysroot_static_empty) " +
" -f $(genDir)/Scrt1.ld " +
" -f $(location :libc_musl_Scrt1) " +
+ " -f $(location :libc++_static) " +
+ " -f $(location :clang_rt.crtbegin) " +
+ " -f $(location :clang_rt.crtend) " +
" && " +
"$(location zip2zip) -i $(genDir)/libs.zip -o $(genDir)/libs_renamed.zip " +
// rename libs from module names to desired names in sysroot
" lib/libc_musl_static.a:lib/libc.a " +
+ " lib/libc++_static.a:lib/libc++.a " +
// Swap in linker script for Scrt1.o
" lib/Scrt1.o:lib/Scrt1-real.o " +
" lib/Scrt1.ld:lib/Scrt1.o " +
@@ -812,6 +819,12 @@ cc_genrule {
" lib/libc_musl_sysroot_static_empty.a:lib/librt.a " +
" lib/libc_musl_sysroot_static_empty.a:lib/libutil.a " +
" lib/libc_musl_sysroot_static_empty.a:lib/libxnet.a " +
+ // rename clang crt objects to gcc names
+ " lib/clang_rt.crtbegin.o:lib/crtbegin.o " +
+ " lib/clang_rt.crtbegin.o:lib/crtbeginS.o " +
+ " lib/clang_rt.crtbegin.o:lib/crtbeginT.o " +
+ " lib/clang_rt.crtend.o:lib/crtend.o " +
+ " lib/clang_rt.crtend.o:lib/crtendS.o " +
" && " +
"$(location merge_zips) -ignore-duplicates $(out) " +
" $(location :libc_musl_sysroot_bionic_headers) " +