Merge "Allow make-standalone-toolchain.sh to generate 64-bit host toolchain"
diff --git a/build/tools/make-standalone-toolchain.sh b/build/tools/make-standalone-toolchain.sh
index c5d9b16..dd856fb 100755
--- a/build/tools/make-standalone-toolchain.sh
+++ b/build/tools/make-standalone-toolchain.sh
@@ -24,8 +24,6 @@
 used as a standalone cross-compiler, e.g. to run configure and
 make scripts."
 
-force_32bit_binaries
-
 # For now, this is the only toolchain that works reliably.
 TOOLCHAIN_NAME=
 register_var_option "--toolchain=<name>" TOOLCHAIN_NAME "Specify toolchain name"
@@ -42,7 +40,8 @@
 NDK_DIR=`dirname $NDK_DIR`
 register_var_option "--ndk-dir=<path>" NDK_DIR "Take source files from NDK at <path>"
 
-SYSTEM=$HOST_TAG
+# Create 32-bit host toolchain by default
+SYSTEM=$HOST_TAG32
 register_var_option "--system=<name>" SYSTEM "Specify host system"
 
 PACKAGE_DIR=/tmp/ndk-$USER
diff --git a/docs/STANDALONE-TOOLCHAIN.html b/docs/STANDALONE-TOOLCHAIN.html
index 2965b43..3763a16 100644
--- a/docs/STANDALONE-TOOLCHAIN.html
+++ b/docs/STANDALONE-TOOLCHAIN.html
@@ -80,7 +80,7 @@
 This will create a directory named /tmp/my-android-toolchain containing a
 copy of the android-5/arch-arm sysroot, and of the toolchain binaries.
 
-Note that by default, the ARM-based GCC 4.6 toolchain will be selected by the script.
+Note that by default, the 32-bit ARM-based GCC 4.6 toolchain will be selected by the script.
 Use the '--arch=x86' option to specify the x86 GCC 4.6, or add '--arch=mips' option
 to specify the MIPS GCC 4.6, or alternatively
 '--toolchain=&lt;name&gt;'.  For example:
@@ -94,6 +94,10 @@
 
   --toolchain=arm-linux-androideabi-clang3.1  # same as --arch=arm --llvm-version=3.1
 
+You may specify --system=linux-x86_64 on 64-bit Linux or --system=darwin-x86_64 on 64-bit
+MacOSX to make 64-bit host toolchain instead of the 32-bit one (default).
+64-bit Windows toolchain isn't available yet.  See IV of NDK-BUILD.html
+
 You can later use it directly with something like:
 
    export PATH=/tmp/my-android-toolchain/bin:$PATH