LOCAL_SDK_VERSION is not emitted for recovery variant
recovery variants are not built with NDK (useSdk() is false for
recovery). So LOCAL_SDK_VERSION shouldn't be emitted for the recovery
variants as well.
Test: m -j liblzma.recovery does not show any link type check error
Change-Id: Icb6c4fc766060e3f1555c405d5785ef5a015c629
diff --git a/cc/androidmk.go b/cc/androidmk.go
index f417de0..263f0f3 100644
--- a/cc/androidmk.go
+++ b/cc/androidmk.go
@@ -71,7 +71,7 @@
fmt.Fprintln(w, "LOCAL_SHARED_LIBRARIES := "+strings.Join(c.Properties.AndroidMkSharedLibs, " "))
}
if c.Target().Os == android.Android &&
- String(c.Properties.Sdk_version) != "" && !c.useVndk() {
+ String(c.Properties.Sdk_version) != "" && !c.useVndk() && !c.inRecovery() {
fmt.Fprintln(w, "LOCAL_SDK_VERSION := "+String(c.Properties.Sdk_version))
fmt.Fprintln(w, "LOCAL_NDK_STL_VARIANT := none")
} else {