Add --sysroot /dev/null to musl compiles
Prevent linking against host glibc libraries by passing --sysroot /dev/null to compile and link rules targeting musl. Bug: 190084016 Test: m USE_HOST_MUSL=true host-native Change-Id: Ief2c9507af9ae7cf5376cb874fcef0f2cbaf9994
This commit is contained in:
parent
a2bcf2c4b8
commit
6745a8ef1d
1 changed files with 2 additions and 0 deletions
|
@ -47,6 +47,7 @@ var (
|
|||
"-D_LIBCPP_HAS_MUSL_LIBC",
|
||||
"-DANDROID_HOST_MUSL",
|
||||
"-nostdlibinc",
|
||||
"--sysroot /dev/null",
|
||||
}
|
||||
|
||||
linuxLdflags = []string{
|
||||
|
@ -65,6 +66,7 @@ var (
|
|||
linuxMuslLdflags = []string{
|
||||
"-nostdlib",
|
||||
"-lgcc", "-lgcc_eh",
|
||||
"--sysroot /dev/null",
|
||||
}
|
||||
|
||||
// Extended cflags
|
||||
|
|
Loading…
Reference in a new issue