Add -Wl,-maarch64linux

The "-maarch64linux" switch is needed before aarch64-*4.8 is rebuilt with
backport of upstream patch, see https://android-review.googlesource.com/#/c/91099/

The existing ld.bfd is fine because it's configured to support
aarch64linux only.  ld.mcld (see https://android-review.googlesource.com/#/c/91047)
needs explicit emulation switch because it supports multiple targets

Change-Id: Idc1a491c5722ea9e26db917b667b1000bccc1f60
Merge "Add -Wl,-maarch64linux"
Remove libGLES_android from non-emulator builds; Remove screenrecord from SDK build.

Bug: 11368415
Bug: 14087863
Change-Id: I05d406d174ea1d1bf67c7922c03950e700978baa
Merge "Remove libGLES_android from non-emulator builds; Remove screenrecord from SDK build."
Explicitly link libstdc++.a for static gtest executables.

Change-Id: I29e3a4036264acd00dfa3229c9d0fc52ee20830e
Merge "Explicitly link libstdc++.a for static gtest executables."
Use aarch64-linux-android-4.9 for arm64 build (attempt #3)

GCC: 4.9 (which supports -fstack-protector)
Binutils: 2.24 (which supports gc-sections)
GDB: 7.7

NDK libraries are still picked up from prebuilts/ndk/*/4.8/*
GCC has been patched to disable codegen for calling
__cxa_throw_bad_array_new_length.

Change-Id: Ie0bf38357c0cf3d265d8b5dd3c2b8a8fd83b1de1
Merge "Use aarch64-linux-android-4.9 for arm64 build (attempt #3)"
Revert "Use aarch64-linux-android-4.9 for arm64 build (attempt #3)"

This reverts commit 084a7f83875d030c2e4819bed386c4a16168e731.

GCC 4.9 still has stability issues (b/14160872)

Change-Id: I4d40829dbbfac0e7b6cd7eaf9924744bc5714271
Merge "Revert "Use aarch64-linux-android-4.9 for arm64 build (attempt #3)""
For 64-bit, use 32-bit DEXPREOPT if zygote64 isn't enabled.

Change-Id: Ia95d74517f8182031d6044ae55559010a98ec5ca
Merge "For 64-bit, use 32-bit DEXPREOPT if zygote64 isn't enabled."
Update rules to install JNI libraries.

Previously we have to use LOCAL_REQUIRED_MODULES to install jni
libraries for an apk in bundled build.
With this change, we'll use LOCAL_JNI_SHARED_LIBRARIES alone to
install jni shared libraries.

The new rules are:
- If we are doing unbundled build, or the apk isn't going to be
  installed to system partitions, we'll embed the jni libs in the
  built apk.
- Otherwise, the jni libraries will be installed to the system
  lib path, and symlinks created in the app specific lib path.

Change-Id: Id6bd5301eb632bda3593664acee580f0d8b1d5d4
Merge "Update rules to install JNI libraries."
auto-merger: merge in from aosp/master