Define READELF_FOR_TARGET in gcc build

Otherwise realelf won't be found in darwin, and cause
some backend to misbehave.

READELF_FOR_TARGET appears in gcc-4.7, but is backported
to gcc-4.6 as well.

Change-Id: Ia45b3ce046cc68a40862be8f5a906606d2fd0665
Fix GCC 4.8 mingw build

Export CXX_FOR_BUILD otherwise the default g++ can have different
bitness than libiberty.a which is always built in 32-bit for now.
Didn't happen prior to GCC 4.8 because GCC was in C only.  GCC from
4.8 now uses C++ as its implementation language

Change-Id: I318a2e469e1f1ce5cea71654ca5387d26cee5b73
Add aarch64

Change-Id: I0575d428472c12b56e10367abb73a2b5fd794a08
Fix for GCC 4.8 with graphite

GCC 4.8 needs cloog-0.18.0 and isl-0.11.1 for graphite
framework.

Change-Id: I45a6f34f9981a489d65cc23a0f20e439c11100b2
Python GDB intergration work for the build system.

Adds a --with-python=</path/to/python-config.sh> option.
Don't build GDB in canadian build->target

In canadian build->target is built first (eg. in order to build/run
executable on build system to generate table), then host->target.

Don't build GDB in build->target, because GDB doens't need it.  Besides,
--with-python= pointing to "host" header can fail "build"'s gcc.

Change-Id: Ic1a8a9d6fe5974a6747ca4342a336beea9987f47
Add x86_64 target configure defaults

It includes:
-march=atom/-mtune=atom to focus on Atom instructions/optimizations;
-fpmath=sse to generate sse math instructions instead of i387
-m32/-m64/-mx32 support to be able to generate 32/64/x32 code with
single toolchain.

Change-Id: I1a650b4cf572322baa5648a97e1731922571a132
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
Replace -march=atom with -march=x86-64 for better host compatibility

Change-Id: Iefaa3ed65333c58484975326bfadd47ddaa92ce3
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
Change the triplet to aarch64-linux-android for aarch64-gcc.

Change-Id: I0d8803b45b5085379e01d616a1056201453bda9f
Switch x86/x86-64 -mtune from "atom" to more generic "intel"

-mtune=intel is tradeoff tuning between top IA archs whereas "atom" is
best on atom only.

Change-Id: I27668e4f48f26b00742d117a9a2a38e8903e22d5
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
Remove libbfd.a build for host

Due to tricky configuration it cannot be build well when building 64-bit
targets. I didn't find any place in current AOSP tree where we are using
host libbfd.a so probably it's not required anymore?

build-host-gcc.sh doesn't build it either.

Change-Id: I9ed62c2d16bcb393e61bf913b6bab222bb783403
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
Propagate -j in make calls for better parallelization

Also fix deps for parallel build.
It should speed up full NDK build.

Change-Id: Id62b4ba6b2d09fd28a2724c285eb0069b79b13fb
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
Avoid host toolchain copy to target toolchain dir in canadian build

After https://android-review.googlesource.com/#/c/88662/ in mingw build
host toolchain put into the same directory as target. This patch fixes
this issue.

Change-Id: I8cb08fdfc9f8a3eb1b88ba982ebeb79c851b25d8
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
Fix binutils-2.24 detection

Starting from binutils-2.24, version is contained in AC_INIT
instead of M_INIT_AUTOMAKE

Change-Id: I447affb61d73069593aacc3cae3a0b99186e506f
Add initial support for objective-c and libobcj
Use static libgcc and libstdc++ while builing binutils on darwin
Set defautl PPL version to 1.0_1
Remove obsolete code related to old binuitls

binutils prior to version 2.21 had different arguments to --enable-gold
option.

Also add aarch64 target into configure.ac file.
Regenerate from the new configure.ac