Expose host AvailableLibraries to Make
Test: Check out/soong/make_vars-aosp_arm64_ab.mk
Change-Id: I8410942698f3c142b03a2e1e447c880184ab82bf
diff --git a/cc/makevars.go b/cc/makevars.go
index 8bdcf9f..2c6af70 100644
--- a/cc/makevars.go
+++ b/cc/makevars.go
@@ -259,6 +259,10 @@
ctx.Strict(makePrefix+"NDK_TRIPLE", toolchain.ClangTriple())
}
+ if target.Os.Class == android.Host || target.Os.Class == android.HostCross {
+ ctx.Strict(makePrefix+"AVAILABLE_LIBRARIES", strings.Join(toolchain.AvailableLibraries(), " "))
+ }
+
ctx.Strict(makePrefix+"TOOLCHAIN_ROOT", toolchain.GccRoot())
ctx.Strict(makePrefix+"TOOLS_PREFIX", gccCmd(toolchain, ""))
ctx.Strict(makePrefix+"SHLIB_SUFFIX", toolchain.ShlibSuffix())