aboutsummaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authorAndrew Hsieh <andrewhsieh@google.com>2014-12-17 18:35:18 +0800
committerAndrew Hsieh <andrewhsieh@google.com>2014-12-18 10:47:44 +0800
commite5e7599ff9e946f3d47c6b3150d7265c1e2dab38 (patch)
treeba868aeb9e73d3d894a18e3698775580d44d95d7 /build
parentcde0cb89ada253e9f7f4194de6f7f6af138b7e09 (diff)
downloadndk-e5e7599ff9e946f3d47c6b3150d7265c1e2dab38.tar.gz
Remove GCC 4.6
Change-Id: I840e7a2183e956e27e5dd93357ef2a2dd49fd40b
Diffstat (limited to 'build')
-rw-r--r--build/core/setup-toolchain.mk2
-rw-r--r--build/tools/DEV-SCRIPTS-USAGE.TXT14
-rwxr-xr-xbuild/tools/build-gcc.sh2
-rwxr-xr-xbuild/tools/build-gdbserver.sh2
-rwxr-xr-xbuild/tools/build-host-gcc.sh21
-rwxr-xr-xbuild/tools/deploy-host-mcld.sh2
-rw-r--r--build/tools/dev-defaults.sh20
-rwxr-xr-xbuild/tools/download-toolchain-sources.sh6
-rwxr-xr-xbuild/tools/gen-platforms.sh4
-rwxr-xr-xbuild/tools/make-standalone-toolchain.sh2
-rwxr-xr-xbuild/tools/package-release.sh2
-rw-r--r--build/tools/prebuilt-common.sh12
-rw-r--r--build/tools/toolchain-patches/gcc/0001-Disable-sincos-optimization.patch16
-rw-r--r--build/tools/toolchain-patches/gcc/0002-Enable-C-exceptions-and-RTTI-by-default.patch16
-rw-r--r--build/tools/toolchain-patches/gcc/0003-gcc-prevent-crash-on-Eclair-and-older-platforms.patch25
-rw-r--r--build/tools/toolchain-patches/gcc/0004-Rename-libstdc++.so-to-libgnustl_shared.so.patch24
-rw-r--r--build/tools/toolchain-patches/gcc/0012-Don-t-define-__fp16-for-clang.patch15
17 files changed, 46 insertions, 139 deletions
diff --git a/build/core/setup-toolchain.mk b/build/core/setup-toolchain.mk
index 243df3fbf..d16f0f7e7 100644
--- a/build/core/setup-toolchain.mk
+++ b/build/core/setup-toolchain.mk
@@ -53,7 +53,7 @@ ifndef NDK_TOOLCHAIN
$(call __ndk_error,Aborting)
endif
# Select the last toolchain from the sorted list.
- # For now, this is enough to select by default gcc4.6 for 32-bit, and 4.9 for 64-bit, the the
+ # For now, this is enough to select by default gcc4.8 for 32-bit, and 4.9 for 64-bit, the the
# latest llvm if no gcc
ifneq (,$(filter-out llvm-%,$(TARGET_TOOLCHAIN_LIST)))
TARGET_TOOLCHAIN := $(firstword $(TARGET_TOOLCHAIN_LIST))
diff --git a/build/tools/DEV-SCRIPTS-USAGE.TXT b/build/tools/DEV-SCRIPTS-USAGE.TXT
index 8ad8d6f0e..95a29c9e6 100644
--- a/build/tools/DEV-SCRIPTS-USAGE.TXT
+++ b/build/tools/DEV-SCRIPTS-USAGE.TXT
@@ -282,7 +282,7 @@ to verify that the patches apply cleanly.
The toolchains binaries are typically placed under the directory
$NDK/toolchains/$NAME/prebuilt/$SYSTEM, where $NAME is the toolchain name's
-full name (e.g. arm-linux-androideabi-4.6), and $SYSTEM is the name of the
+full name (e.g. arm-linux-androideabi-4.8), and $SYSTEM is the name of the
host system it is meant to run on (e.g. 'linux-x86', 'windows' or 'darwin-x86')
@@ -311,8 +311,8 @@ For example, to rebuild the arm and x86 prebuilt toolchain binaries in the
current NDK directory (which can be handy if you want to later use them to
rebuild other target prebuilts or run tests), do:
- $NDK/build/tools/build-gcc.sh /tmp/ndk-$USER/src $NDK arm-linux-androideabi-4.6
- $NDK/build/tools/build-gcc.sh /tmp/ndk-$USER/src $NDK x86-4.6
+ $NDK/build/tools/build-gcc.sh /tmp/ndk-$USER/src $NDK arm-linux-androideabi-4.8
+ $NDK/build/tools/build-gcc.sh /tmp/ndk-$USER/src $NDK x86-4.8
Here, we assume you downloaded the toolchain sources in /tmp/ndk-$USER/src
as described in the previous section.
@@ -330,10 +330,10 @@ cross-toolchain (install it with "apt-get install mingw32" on Ubuntu). To do so
use the "--mingw" option, as in:
$NDK/build/tools/build-gcc.sh --mingw \
- /tmp/ndk-$USER/src $NDK arm-linux-androideabi-4.6
+ /tmp/ndk-$USER/src $NDK arm-linux-androideabi-4.8
$NDK/build/tools/build-gcc.sh --mingw \
- /tmp/ndk-$USER/src $NDK x86-4.6
+ /tmp/ndk-$USER/src $NDK x86-4.8
The corresponding binaries are installed under $NDK/toolchains/$NAME/prebuilt/windows
Note that these are native Windows programs, not Cygwin ones.
@@ -383,8 +383,8 @@ The prebuilt binary is placed under $NDK/toolchains/$NAME/prebuilt/gdbserver
in the final NDK installation. You can generate with 'build-gdbserver.sh' and
takes the same parameters than 'build-gcc.sh'. So one can do:
- $NDK/build/tools/build-gcc.sh /tmp/ndk-$USER/src $NDK arm-linux-androideabi-4.6
- $NDK/build/tools/build-gcc.sh /tmp/ndk-$USER/src $NDK x86-4.6
+ $NDK/build/tools/build-gcc.sh /tmp/ndk-$USER/src $NDK arm-linux-androideabi-4.8
+ $NDK/build/tools/build-gcc.sh /tmp/ndk-$USER/src $NDK x86-4.8
III.3. Generating C++ runtime prebuilt binaries:
diff --git a/build/tools/build-gcc.sh b/build/tools/build-gcc.sh
index 4664c615a..47bb1090d 100755
--- a/build/tools/build-gcc.sh
+++ b/build/tools/build-gcc.sh
@@ -28,7 +28,7 @@ PROGRAM_DESCRIPTION=\
Where <src-dir> is the location of toolchain sources, <ndk-dir> is
the top-level NDK installation path and <toolchain> is the name of
-the toolchain to use (e.g. arm-linux-androideabi-4.6)."
+the toolchain to use (e.g. arm-linux-androideabi-4.8)."
RELEASE=`date +%Y%m%d`
BUILD_OUT=/tmp/ndk-$USER/build/toolchain
diff --git a/build/tools/build-gdbserver.sh b/build/tools/build-gdbserver.sh
index a44d81379..a61e8a0dd 100755
--- a/build/tools/build-gdbserver.sh
+++ b/build/tools/build-gdbserver.sh
@@ -28,7 +28,7 @@ PROGRAM_DESCRIPTION=\
Where <src-dir> is the location of the gdbserver sources,
<ndk-dir> is the top-level NDK installation path and <toolchain>
-is the name of the toolchain to use (e.g. arm-linux-androideabi-4.6).
+is the name of the toolchain to use (e.g. arm-linux-androideabi-4.8).
The final binary is placed under:
diff --git a/build/tools/build-host-gcc.sh b/build/tools/build-host-gcc.sh
index 810b12c7a..f9ec1e3d7 100755
--- a/build/tools/build-host-gcc.sh
+++ b/build/tools/build-host-gcc.sh
@@ -33,12 +33,15 @@ If you don't pass any parameter, the script will rebuild all NDK toolchains
for the current host system [$HOST_TAG]. You can otherwise give a list of
toolchains among the following names:
- arm-linux-androideabi-4.4.3
- arm-linux-androideabi-4.6
- x64-4.4.3
- x86-4.6
- mipsel-linux-android-4.4.3
- mipsel-linux-android-4.6
+ arm-linux-androideabi-4.8
+ arm-linux-androideabi-4.9
+ x64-4.8
+ x86-4.9
+ mipsel-linux-android-4.8
+ mipsel-linux-android-4.9
+ aarch64-linux-android-4.9
+ mips64el-linux-android-4.9
+ x86_64-4.9
By default, the script rebuilds the toolchain(s) for you host system [$HOST_TAG],
but you can use --systems=<tag1>,<tag2>,.. to ask binaries that can run on
@@ -58,8 +61,8 @@ for four different systems:
$PROGNAME --toolchain-src-dir=/path/to/toolchain/src \
--systems=linux-x86,linux-x86_64,windows,windows-x86_64 \
- arm-linux-androideabi-4.4.3 \
- arm-linux-androideabi-4.6
+ arm-linux-androideabi-4.8 \
+ arm-linux-androideabi-4.9
You can build Windows binaries on Linux if you have a Windows-targetting
cross-toolchain installed and in your path. Note that the script named
@@ -169,7 +172,7 @@ extract_parameters "$@"
TOOLCHAINS=$PARAMETERS
if [ -z "$TOOLCHAINS" ]; then
- TOOLCHAINS="arm-linux-androideabi-4.6,x86-4.6,mipsel-linux-android-4.6"
+ TOOLCHAINS="arm-linux-androideabi-4.8,x86-4.8,mipsel-linux-android-4.8"
dump "Auto-config: $TOOLCHAINS"
fi
diff --git a/build/tools/deploy-host-mcld.sh b/build/tools/deploy-host-mcld.sh
index 2b2cd1e1b..d5ef9bee4 100755
--- a/build/tools/deploy-host-mcld.sh
+++ b/build/tools/deploy-host-mcld.sh
@@ -37,7 +37,7 @@ ie. {linux, darwin, windows} x {64, 32}
If --systems isn't specified, this script discovers all ld.mcld[.exe] in
toolchains/llvm-$DEFAULT_LLVM_VERSION
-Note that one copy of ld.mcld serves all GCC {4.9, 4.8, 4.7, 4.6, 4.4.3} x {arm, x86, mips} and
+Note that one copy of ld.mcld serves all GCC {4.9, 4.8} x {arm, x86, mips} and
LLVM {3.4, 3.5}.
GCC passes -m flag for ld.mcld to figure out the right target.
diff --git a/build/tools/dev-defaults.sh b/build/tools/dev-defaults.sh
index cf034bca8..ee1ff2340 100644
--- a/build/tools/dev-defaults.sh
+++ b/build/tools/dev-defaults.sh
@@ -47,16 +47,16 @@ SUPPORT_SUBDIR=sources/android/support
TOOLCHAIN_GIT_DATE=now
# The space-separated list of all GCC versions we support in this NDK
-DEFAULT_GCC_VERSION_LIST="4.6 4.8 4.9"
+DEFAULT_GCC_VERSION_LIST="4.8 4.9"
DEFAULT_GCC32_VERSION=4.8
DEFAULT_GCC64_VERSION=4.9
-FIRST_GCC32_VERSION=4.6
+FIRST_GCC32_VERSION=4.8
FIRST_GCC64_VERSION=4.9
DEFAULT_LLVM_GCC32_VERSION=4.8
DEFAULT_LLVM_GCC64_VERSION=4.9
-DEFAULT_BINUTILS_VERSION=2.21
+DEFAULT_BINUTILS_VERSION=2.24
DEFAULT_GDB_VERSION=7.3.x
DEFAULT_MPFR_VERSION=3.1.1
DEFAULT_GMP_VERSION=5.0.5
@@ -188,7 +188,7 @@ get_default_abis_for_arch ()
# Return toolchain name for given architecture and GCC version
# $1: Architecture name (e.g. 'arm')
-# $2: optional, GCC version (e.g. '4.6')
+# $2: optional, GCC version (e.g. '4.8')
# Out: default arch-specific toolchain name (e.g. 'arm-linux-androideabi-$GCC_VERSION')
# Return empty for unknown arch
get_toolchain_name_for_arch ()
@@ -222,7 +222,7 @@ get_default_toolchain_prefix_for_arch ()
# Get the list of all toolchain names for a given architecture
# $1: architecture (e.g. 'arm')
# $2: comma separated versions (optional)
-# Out: list of toolchain names for this arch (e.g. arm-linux-androideabi-4.6 arm-linux-androideabi-4.8)
+# Out: list of toolchain names for this arch (e.g. arm-linux-androideabi-4.8 arm-linux-androideabi-4.9)
# Return empty for unknown arch
get_toolchain_name_list_for_arch ()
{
@@ -264,17 +264,17 @@ get_toolchain_name_list_for_arch ()
# binutils was reverted to 2.19, to ensure at least
# feature/bug compatibility.
#
-# $1: toolchain with version numer (e.g. 'arm-linux-androideabi-4.6')
+# $1: toolchain with version numer (e.g. 'arm-linux-androideabi-4.8')
#
get_default_binutils_version_for_gcc ()
{
case $1 in
mips*) echo "2.24";;
- *-4.6) echo "$DEFAULT_BINUTILS_VERSION";;
+ *-4.6) echo "2.21";;
*-4.4.3) echo "2.19";;
x86*-4.7) echo "2.23";; # Use 2.23 to get x32 support in ld.gold
*-4.7) echo "2.22";;
- *) echo "2.24";;
+ *) echo "$DEFAULT_BINUTILS_VERSION";;
esac
}
@@ -296,7 +296,7 @@ get_default_binutils_version_for_llvm ()
# Return the gdb version to be used by default when building a given
# version of GCC.
#
-# $1: toolchain with version numer (e.g. 'arm-linux-androideabi-4.6')
+# $1: toolchain with version numer (e.g. 'arm-linux-androideabi-4.8')
#
get_default_gdb_version_for_gcc ()
{
@@ -310,7 +310,7 @@ get_default_gdb_version_for_gcc ()
# Return the gdbserver version to be used by default when building a given
# version of GCC.
#
-# $1: toolchain with version numer (e.g. 'arm-linux-androideabi-4.6')
+# $1: toolchain with version numer (e.g. 'arm-linux-androideabi-4.8')
#
get_default_gdbserver_version_for_gcc ()
{
diff --git a/build/tools/download-toolchain-sources.sh b/build/tools/download-toolchain-sources.sh
index 4f105d663..cb0e8d52b 100755
--- a/build/tools/download-toolchain-sources.sh
+++ b/build/tools/download-toolchain-sources.sh
@@ -156,7 +156,7 @@ toolchain_clone ()
# $1: sub-directory
# $2: branch (e.g. 'master')
# $3: repository/clone name (e.g. 'gcc')
-# $4+: sub-path to extract, relative to clone top-level (e.g. 'gcc-4.6')
+# $4+: sub-path to extract, relative to clone top-level (e.g. 'gcc-4.8')
#
toolchain_checkout ()
{
@@ -215,8 +215,8 @@ toolchain_checkout "" $BRANCH cloog .
toolchain_checkout "" $BRANCH isl .
toolchain_checkout "" $BRANCH ppl .
toolchain_checkout "" $BRANCH expat .
-toolchain_checkout "" $BRANCH binutils binutils-2.21 binutils-2.24
-toolchain_checkout "" $BRANCH gcc gcc-4.6 gcc-4.8 gcc-4.9
+toolchain_checkout "" $BRANCH binutils binutils-2.24
+toolchain_checkout "" $BRANCH gcc gcc-4.8 gcc-4.9
toolchain_checkout "" $BRANCH gdb gdb-7.3.x gdb-7.6 gdb-7.7
toolchain_checkout "" $BRANCH python Python-2.7.5
toolchain_checkout "" $BRANCH perl perl-5.16.2
diff --git a/build/tools/gen-platforms.sh b/build/tools/gen-platforms.sh
index 6abca57d3..f93808b72 100755
--- a/build/tools/gen-platforms.sh
+++ b/build/tools/gen-platforms.sh
@@ -388,9 +388,7 @@ get_default_compiler_for_arch()
elif [ -n "$OPTION_GCC_VERSION" -a "$OPTION_GCC_VERSION" != "default" ]; then
GCC_VERSION=$OPTION_GCC_VERSION
else
- # By default we want to use the first gcc (currently 4.6) instead of the default (gcc4.8)
- # for best compatibility, at least before gcc4.6 (now deprecated) is removed from NDK package
- GCC_VERSION=$(get_default_gcc_version_for_arch $ARCH) # $(get_first_gcc_version_for_arch $ARCH)
+ GCC_VERSION=$(get_default_gcc_version_for_arch $ARCH)
fi
for TAG in $HOST_TAG $HOST_TAG32; do
TOOLCHAIN_PREFIX="$NDK_DIR/$(get_toolchain_binprefix_for_arch $ARCH $GCC_VERSION $TAG)"
diff --git a/build/tools/make-standalone-toolchain.sh b/build/tools/make-standalone-toolchain.sh
index 2c1ab22f8..b3f01396f 100755
--- a/build/tools/make-standalone-toolchain.sh
+++ b/build/tools/make-standalone-toolchain.sh
@@ -303,7 +303,7 @@ if [ -n "$LLVM_VERSION" ]; then
fi
# Get GCC_BASE_VERSION. Note that GCC_BASE_VERSION may be slightly different from GCC_VERSION.
-# eg. In gcc4.6 GCC_BASE_VERSION is "4.6.x-google"
+# eg. In gcc4.9 GCC_BASE_VERSION is "4.9.x-google"
LIBGCC_PATH=`$TOOLCHAIN_GCC -print-libgcc-file-name`
LIBGCC_BASE_PATH=${LIBGCC_PATH%/*} # base path of libgcc.a
GCC_BASE_VERSION=${LIBGCC_BASE_PATH##*/} # stuff after the last /
diff --git a/build/tools/package-release.sh b/build/tools/package-release.sh
index 4c20a4d30..9b279e678 100755
--- a/build/tools/package-release.sh
+++ b/build/tools/package-release.sh
@@ -148,7 +148,7 @@ UNKNOWN_ABIS=$(convert_archs_to_abis $UNKNOWN_ARCH)
# Convert comma-separated list to space-separated list
LLVM_VERSION_LIST=$(commas_to_spaces $LLVM_VERSION_LIST)
-# If --arch is used to list x86 as a target architecture, Add x86-4.6 to
+# If --arch is used to list x86 as a target architecture, Add x86-4.8 to
# the list of default toolchains to package. That is, unless you also
# explicitely use --toolchains=<list>
#
diff --git a/build/tools/prebuilt-common.sh b/build/tools/prebuilt-common.sh
index a4024e37b..9c7c75ad3 100644
--- a/build/tools/prebuilt-common.sh
+++ b/build/tools/prebuilt-common.sh
@@ -35,7 +35,7 @@ extract_version ()
echo $1 | tr '-' '\n' | tail -1
}
-# $1: versioned name (e.g. arm-linux-androideabi-4.6)
+# $1: versioned name (e.g. arm-linux-androideabi-4.8)
# Out: major version (e.g. 4)
#
# Examples: arm-linux-androideabi-4.4.3 -> 4
@@ -62,10 +62,10 @@ extract_minor_version ()
# Compare two version numbers and only succeeds if the first one is
# greather or equal than the second one.
#
-# $1: first version (e.g. 4.4.3)
-# $2: second version (e.g. 4.6)
+# $1: first version (e.g. 4.9)
+# $2: second version (e.g. 4.8)
#
-# Example: version_is_at_least 4.6 4.4.3 --> success
+# Example: version_is_at_least 4.9 4.8 --> success
#
version_is_at_least ()
{
@@ -1397,7 +1397,7 @@ convert_archs_to_abis ()
}
# Return the default toolchain binary path prefix for given architecture and gcc version
-# For example: arm 4.6 -> toolchains/arm-linux-androideabi-4.6/prebuilt/<system>/bin/arm-linux-androideabi-
+# For example: arm 4.8 -> toolchains/arm-linux-androideabi-4.8/prebuilt/<system>/bin/arm-linux-androideabi-
# $1: Architecture name
# $2: GCC version
# $3: optional, system name, defaults to $HOST_TAG
@@ -1426,7 +1426,7 @@ get_llvm_toolchain_binprefix ()
}
# Return the default toochain binary path prefix for a given architecture
-# For example: arm -> toolchains/arm-linux-androideabi-4.6/prebuilt/<system>/bin/arm-linux-androideabi-
+# For example: arm -> toolchains/arm-linux-androideabi-4.8/prebuilt/<system>/bin/arm-linux-androideabi-
# $1: Architecture name
# $2: optional, system name, defaults to $HOST_TAG
get_default_toolchain_binprefix_for_arch ()
diff --git a/build/tools/toolchain-patches/gcc/0001-Disable-sincos-optimization.patch b/build/tools/toolchain-patches/gcc/0001-Disable-sincos-optimization.patch
index 5aa35f0af..78077dfcf 100644
--- a/build/tools/toolchain-patches/gcc/0001-Disable-sincos-optimization.patch
+++ b/build/tools/toolchain-patches/gcc/0001-Disable-sincos-optimization.patch
@@ -1,7 +1,7 @@
From 504ba0176a97c9b849fd18c4591a2cfc8d5eb130 Mon Sep 17 00:00:00 2001
From: David 'Digit' Turner <digit@google.com>
Date: Wed, 9 May 2012 17:53:13 +0200
-Subject: gcc-4.6: Disable sincos optimization
+Subject: gcc-4.8: Disable sincos optimization
Ensure that sincos optimization is disabled for NDK toolchain
builds. This ensures that NDK-generated code will always link
@@ -21,23 +21,9 @@ Into machine code that does:
Change-Id: I332bf5788267dd56e93b8cdb0cefa04b970eca88
---
- gcc-4.6/gcc/config/linux.h | 2 +-
gcc-4.8/gcc/config/linux.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
-diff --git a/gcc-4.6/gcc/config/linux.h b/gcc-4.6/gcc/config/linux.h
-index 4e21112..025157f 100644
---- a/gcc-4.6/gcc/config/linux.h
-+++ b/gcc-4.6/gcc/config/linux.h
-@@ -99,7 +99,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
- #define TARGET_C99_FUNCTIONS (OPTION_GLIBC)
-
- /* Whether we have sincos that follows the GNU extension. */
--#define TARGET_HAS_SINCOS (OPTION_GLIBC || OPTION_BIONIC)
-+#define TARGET_HAS_SINCOS (OPTION_GLIBC)
-
- /* Whether we have Bionic libc runtime */
- #undef TARGET_HAS_BIONIC
diff --git a/gcc-4.8/gcc/config/linux.h b/gcc-4.8/gcc/config/linux.h
index 2be1079..b83dc08 100644
--- a/gcc-4.8/gcc/config/linux.h
diff --git a/build/tools/toolchain-patches/gcc/0002-Enable-C-exceptions-and-RTTI-by-default.patch b/build/tools/toolchain-patches/gcc/0002-Enable-C-exceptions-and-RTTI-by-default.patch
index 57324bfba..f74d07284 100644
--- a/build/tools/toolchain-patches/gcc/0002-Enable-C-exceptions-and-RTTI-by-default.patch
+++ b/build/tools/toolchain-patches/gcc/0002-Enable-C-exceptions-and-RTTI-by-default.patch
@@ -6,26 +6,10 @@ Subject: Enable C++ exceptions and RTTI by default.
With this change, -fexceptions and -frtti become default options
when compiling C++ sources.
---
- gcc-4.6/gcc/config/linux-android.h | 4 ++--
gcc-4.8/gcc/config/linux-android.h | 4 ++--
gcc-4.9/gcc/config/linux-android.h | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)
-diff --git a/gcc-4.6/gcc/config/linux-android.h b/gcc-4.6/gcc/config/linux-android.h
-index c19b1c1..6fa4f53 100644
---- a/gcc-4.6/gcc/config/linux-android.h
-+++ b/gcc-4.6/gcc/config/linux-android.h
-@@ -46,8 +46,8 @@
- "%{!fno-pic:%{!fno-PIC:%{!fpic:%{!fPIC: " ANDROID_PIC_DEFAULT "}}}}"
-
- #define ANDROID_CC1PLUS_SPEC \
-- "%{!fexceptions:%{!fno-exceptions: -fno-exceptions}} " \
-- "%{!frtti:%{!fno-rtti: -fno-rtti}}"
-+ "%{!fexceptions:%{!fno-exceptions: -fexceptions}} " \
-+ "%{!frtti:%{!fno-rtti: -frtti}}"
-
- #define ANDROID_ASM_SPEC \
- "--noexecstack"
diff --git a/gcc-4.8/gcc/config/linux-android.h b/gcc-4.8/gcc/config/linux-android.h
index 87957e3..e88ab78 100644
--- a/gcc-4.8/gcc/config/linux-android.h
diff --git a/build/tools/toolchain-patches/gcc/0003-gcc-prevent-crash-on-Eclair-and-older-platforms.patch b/build/tools/toolchain-patches/gcc/0003-gcc-prevent-crash-on-Eclair-and-older-platforms.patch
index b67cd977f..e55a6755d 100644
--- a/build/tools/toolchain-patches/gcc/0003-gcc-prevent-crash-on-Eclair-and-older-platforms.patch
+++ b/build/tools/toolchain-patches/gcc/0003-gcc-prevent-crash-on-Eclair-and-older-platforms.patch
@@ -21,35 +21,10 @@ completely. And we don't need them because the pthread symbols
are all in the C library on Android, unlike legacy Linux systems
which put them in libpthread.so (and provide weak stubs in libc.so).
---
- gcc-4.6/gcc/gthr-posix.h | 13 +++++++++++++
gcc-4.8/libgcc/gthr-posix.h | 13 +++++++++++++
gcc-4.9/libgcc/gthr-posix.h | 13 +++++++++++++
3 files changed, 39 insertions(+)
-diff --git a/gcc-4.6/gcc/gthr-posix.h b/gcc-4.6/gcc/gthr-posix.h
-index ecb06e2..8372c64 100644
---- a/gcc-4.6/gcc/gthr-posix.h
-+++ b/gcc-4.6/gcc/gthr-posix.h
-@@ -38,6 +38,19 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
- #define _REENTRANT 1
- #endif
-
-+/* The following should normally be in a different header file,
-+ * but I couldn't find the right location. The point of the macro
-+ * definition below is to prevent libsupc++ and libstdc++ to reference
-+ * weak symbols in their static C++ constructors. Such code crashes
-+ * when a shared object linked statically to these libraries is
-+ * loaded on Android 2.1 (Eclair) and older platform releases, due
-+ * to a dynamic linker bug.
-+ */
-+#ifdef __ANDROID__
-+#undef GTHREAD_USE_WEAK
-+#define GTHREAD_USE_WEAK 0
-+#endif
-+
- #include <pthread.h>
- #include <unistd.h>
-
diff --git a/gcc-4.8/libgcc/gthr-posix.h b/gcc-4.8/libgcc/gthr-posix.h
index f0d8cd7..1d03af0 100644
--- a/gcc-4.8/libgcc/gthr-posix.h
diff --git a/build/tools/toolchain-patches/gcc/0004-Rename-libstdc++.so-to-libgnustl_shared.so.patch b/build/tools/toolchain-patches/gcc/0004-Rename-libstdc++.so-to-libgnustl_shared.so.patch
index 25314de74..7e322d9ca 100644
--- a/build/tools/toolchain-patches/gcc/0004-Rename-libstdc++.so-to-libgnustl_shared.so.patch
+++ b/build/tools/toolchain-patches/gcc/0004-Rename-libstdc++.so-to-libgnustl_shared.so.patch
@@ -8,34 +8,10 @@ instead of libstdc++.so.3 (or some similar number-versioned name).
Change-Id: I63fb5be818115c6d0c7e96b937ba39f225b475cf
---
- gcc-4.6/libstdc++-v3/src/Makefile.in | 5 ++++-
gcc-4.8/libstdc++-v3/src/Makefile.in | 5 ++++-
gcc-4.9/libstdc++-v3/src/Makefile.in | 5 ++++-
3 files changed, 12 insertions(+), 3 deletions(-)
-diff --git a/gcc-4.6/libstdc++-v3/src/Makefile.in b/gcc-4.6/libstdc++-v3/src/Makefile.in
-index d03acd5..5abd1d2 100644
---- a/gcc-4.6/libstdc++-v3/src/Makefile.in
-+++ b/gcc-4.6/libstdc++-v3/src/Makefile.in
-@@ -340,7 +340,7 @@ WARN_CXXFLAGS = \
- AM_CPPFLAGS = $(GLIBCXX_INCLUDES)
-
- # Cross compiler support.
--toolexeclib_LTLIBRARIES = libstdc++.la
-+toolexeclib_LTLIBRARIES = libgnustl_shared.la
- @ENABLE_SYMVERS_TRUE@CLEANFILES = libstdc++-symbols.ver $(version_dep)
- @ENABLE_SYMVERS_DARWIN_TRUE@@ENABLE_SYMVERS_TRUE@version_arg = -Wl,-exported_symbols_list,libstdc++-symbols.explist
- @ENABLE_SYMVERS_FALSE@version_arg =
-@@ -596,6 +596,9 @@ clean-toolexeclibLTLIBRARIES:
- libstdc++.la: $(libstdc___la_OBJECTS) $(libstdc___la_DEPENDENCIES)
- $(libstdc___la_LINK) -rpath $(toolexeclibdir) $(libstdc___la_OBJECTS) $(libstdc___la_LIBADD) $(LIBS)
-
-+libgnustl_shared.la: $(libstdc___la_OBJECTS) $(libstdc___la_DEPENDENCIES)
-+ $(libstdc___la_LINK) -rpath $(toolexeclibdir) $(libstdc___la_OBJECTS) $(libstdc___la_LIBADD) $(LIBS)
-+
- mostlyclean-compile:
- -rm -f *.$(OBJEXT)
-
diff --git a/gcc-4.8/libstdc++-v3/src/Makefile.in b/gcc-4.8/libstdc++-v3/src/Makefile.in
index 9721ebb..dd3d426 100644
--- a/gcc-4.8/libstdc++-v3/src/Makefile.in
diff --git a/build/tools/toolchain-patches/gcc/0012-Don-t-define-__fp16-for-clang.patch b/build/tools/toolchain-patches/gcc/0012-Don-t-define-__fp16-for-clang.patch
index 0cf541e05..6e191fa40 100644
--- a/build/tools/toolchain-patches/gcc/0012-Don-t-define-__fp16-for-clang.patch
+++ b/build/tools/toolchain-patches/gcc/0012-Don-t-define-__fp16-for-clang.patch
@@ -5,25 +5,10 @@ Subject: [PATCH 2/2] Don't define __fp16 for clang
Change-Id: Ie0131eb5d2158d678d82aaf3e46f78bf8fdd1c7a
---
- gcc-4.6/gcc/config/i386/arm_neon.h | 2 ++
gcc-4.8/gcc/config/i386/arm_neon.h | 2 ++
gcc-4.9/gcc/config/i386/arm_neon.h | 2 ++
3 files changed, 6 insertions(+)
-diff --git a/gcc-4.6/gcc/config/i386/arm_neon.h b/gcc-4.6/gcc/config/i386/arm_neon.h
-index 5f56cbd..873b7d6 100644
---- a/gcc-4.6/gcc/config/i386/arm_neon.h
-+++ b/gcc-4.6/gcc/config/i386/arm_neon.h
-@@ -159,7 +159,9 @@ typedef unsigned long long uint64_t;
- #endif
-
- typedef float float32_t;
-+#if !defined(__clang__)
- typedef float __fp16;
-+#endif
-
- typedef uint8_t poly8_t;
- typedef uint16_t poly16_t;
diff --git a/gcc-4.8/gcc/config/i386/arm_neon.h b/gcc-4.8/gcc/config/i386/arm_neon.h
index 5f56cbd..873b7d6 100644
--- a/gcc-4.8/gcc/config/i386/arm_neon.h