edk2: Fix compilation errors on latest Android

1) Update HOST tools with CLANG, since gcc is no longer supported.
2) Suppress the warnings of shift negative values.
3) Use Python & LD from prebuilds.
4) Backward compatible with existing baselines.

Change-Id: I9fdeaec7d4cdc95997f07fd05a47c67c1177cb2d
diff --git a/AndroidBoot.mk b/AndroidBoot.mk
index 4b55d0d..4270e2f 100644
--- a/AndroidBoot.mk
+++ b/AndroidBoot.mk
@@ -13,10 +13,17 @@
   ABL_USE_SDLLVM := true
 endif
 
+# LD is not available for older Android versions
+ifeq (1,$(filter 1,$(shell echo "$$(( $(PLATFORM_SDK_VERSION) > 27 ))" )))
+LDOPT="-fuse-ld=$(ANDROID_TOP)/$(SOONG_LLVM_PREBUILTS_PATH)/ld.lld"
+endif
+
 # Use host tools from prebuilts. Partner should determine the correct host tools to use
-PREBUILT_HOST_TOOLS := CC=$(ANDROID_TOP)/$(HOST_CC)\ \
-		       CXX=$(ANDROID_TOP)/$(HOST_CXX)\ \
+PREBUILT_HOST_TOOLS := CC=$(ANDROID_TOP)/$(CLANG)\ \
+		       CXX=$(ANDROID_TOP)/$(CLANG_CXX)\ \
+		       LDPATH=$(LDOPT)\ \
 		       AR=$(ANDROID_TOP)/$(HOST_AR)
+PREBUILT_PYTHON_PATH=$(ANDROID_TOP)/prebuilts/python/linux-x86/2.7.5/bin/python2
 
 DISABLE_PARALLEL_DOWNLOAD_FLASH := DISABLE_PARALLEL_DOWNLOAD_FLASH=0
 ifeq ($(PRODUCTS.$(INTERNAL_PRODUCT).PRODUCT_SUPPORTS_VERITY),true)
@@ -98,6 +105,7 @@
 		BOOTLOADER_OUT=../../../$(ABL_OUT) \
 		all \
 		PREBUILT_HOST_TOOLS=$(PREBUILT_HOST_TOOLS) \
+		PREBUILT_PYTHON_PATH=$(PREBUILT_PYTHON_PATH) \
 		$(BUILD_SYSTEM_ROOT_IMAGE) \
 		$(VERIFIED_BOOT) \
 		$(VERIFIED_BOOT_2) \