diff options
author | Alexey Neyman <stilor@att.net> | 2018-09-24 22:46:14 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-24 22:46:14 -0700 |
commit | eb65ba65ba761f2ff613342498fd58fcefdc606e (patch) | |
tree | 0214a8714de680394c4b57cfbf605bd177373207 /scripts/build/libc | |
parent | a6580b8e8b55345a5a342b5bd96e42c83e640ac5 (diff) | |
parent | b0e7b57c4ab11bfbafed98cff63990292c510b12 (diff) | |
download | crosstool-ng-eb65ba65ba761f2ff613342498fd58fcefdc606e.tar.gz crosstool-ng-eb65ba65ba761f2ff613342498fd58fcefdc606e.tar.bz2 crosstool-ng-eb65ba65ba761f2ff613342498fd58fcefdc606e.zip |
Merge pull request #1029 from stilor/fix-bionic-build
Restore *-android build
Diffstat (limited to 'scripts/build/libc')
-rw-r--r-- | scripts/build/libc/bionic.sh | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/scripts/build/libc/bionic.sh b/scripts/build/libc/bionic.sh index 573b8d4e..93dcea0c 100644 --- a/scripts/build/libc/bionic.sh +++ b/scripts/build/libc/bionic.sh @@ -26,7 +26,13 @@ do_libc() { fi CT_DoStep INFO "Installing C library binaries" CT_DoExecLog ALL cp -r "${CT_SRC_DIR}/android-ndk/platforms/android-${CT_ANDROID_API}/arch-${arch}/usr" "${CT_SYSROOT_DIR}" - CT_EnvModify CT_ALL_TARGET_CFLAGS "${CT_ALL_TARGET_CFLAGS} -D__ANDROID_API__=${CT_ANDROID_API}" + + # NB: Modifying CT_TARGET_CFLAGS here, not CT_ALL_TARGET_CFLAGS: the __ANDROID_API__ + # definition needs to be passed into GCC build, or the resulting libstdc++ gets + # miscompiled (attempt to link against it results in unresolved symbols to stdout/...). + # And since __ANDROID_API__ is a user config option, placing it with other user-supplied + # options isn't completely out of character. + CT_EnvModify CT_TARGET_CFLAGS "${CT_TARGET_CFLAGS} -D__ANDROID_API__=${CT_ANDROID_API}" } do_libc_post_cc() { |