[MIPS] Update build rules

Add  -D_FORTIFY_SOURCE=1 to the default cflags
Update build rule for executable with PRIVATE_ALL_WHOLE_STATIC_LIBRARIES
Use single dash version of -print-whatever
compile everything with relro / bind_now
Enable NX protections

Some other cleanups to reduce differences between ARM and MIPS config files

Change-Id: I30b4de449e6353b581ef7f9437a3bb9be53d5bbf
Signed-off-by: Chris Dearman <chris@mips.com>
build: update fs_config calls for capabilities change.

Change-Id: Ic3c94f990c34a56d84f01c151f1b64f419e16419
We shouldn't use temporary variable in the build recipe.

Use $@ instead.

Change-Id: Ida0960a453b3701383a31f698c3163a297c4bce5
Merge "We shouldn't use temporary variable in the build recipe."
Merge "[MIPS] Update build rules"
Merge "build: update fs_config calls for capabilities change."
Fixed error message for using OpenJDK.

Output a meaningful error message, when OpenJDK is detected
instead of giving the "wrong java version" output.
That output confused several users (from experiences in IRC)
since it gives you an output like "You are using java
version 1.6.0, right version would be Java SE 1.6".

Change-Id: I31ceeb03f1f98524b2b7de9b8be45231985fdb9e
Signed-off-by: Tim Roes <tim.roes88@googlemail.com>
Merge "Fixed error message for using OpenJDK."
Run zipalign after classes.dex is removed from the apk

If LOCAL_DEX_PREOPT is enabled.

Change-Id: Ie2a706fbb77bc31c9fdb01c8435819c5de97ea28
Merge "Run zipalign after classes.dex is removed from the apk"
Specify -msse3 on host as on target.

Make the host and the target x86 build more uniform by using the same machine flags.
Its unlikely Android has ever been built on a machine without SSE3 support.

Bug: 8068608
Change-Id: I19635528b61bf2c6faf02c2e575b1d9bf8025d3a
Merge "Specify -msse3 on host as on target."
CTS: work around ClassLoader limitation

Trying to use reflection on classes loaded from a different ClassLoader
than the system one caused SecurityException since you can't load
certain packages.

Adding them to the boot classpath forces them to be in the same
ClassLoader.

Change-Id: Id518ab0a99da6defac525c0ad430a63f600ce85f
Merge "CTS: work around ClassLoader limitation"
Add module names to emulator PRODUCT_PACKAGES.

Instead of using "LOCAL_MODULE_TAGS := debug" to install them.

Bug: 8276818
Change-Id: I7eba3c4e6c2f07ebe661522cb0e14afcc3ef7e92
BUILD: Use -fasynchronous-unwind-tables instead of -funwind-tables for ensure the quality of backtrace
Don't install all host modules by default.

Instead we should explicitly set up the dependency, if the module will
be used in the build process; Use LOCAL_MODULE_TAGS with eng, debug or
tests if the module is for testing; or add to PRODUCT_PACKAGES if it's
required by a product.

Change-Id: Ic26319c26c1166bc1062dfbcfb4e006af185249a
Merge "Don't install all host modules by default."
Stash TARGET_CPU_VARIANT and print it in dumpvar.

Bug:7961327

Merged from internal master.

Change-Id: Ia78472ba53ae1221de4572119aa5c63246941eeb
Merge "Stash TARGET_CPU_VARIANT and print it in dumpvar."