Support cc_library as LLNDK without llndk_library
Allow cc_library modules to configure themselves as an LLNDK library
using llndk.symbol_file instead of llndk_stubs pointing to an
llndk_library module.
Bug: 170784825
Test: TestEmbeddedLlndkLibrary
Change-Id: Id884cdada7094bbea6809a98e687e039778c5dc6
diff --git a/cc/cc.go b/cc/cc.go
index 9eebbae..98df545 100644
--- a/cc/cc.go
+++ b/cc/cc.go
@@ -1145,12 +1145,7 @@
func (c *Module) isImplementationForLLNDKPublic() bool {
library, _ := c.library.(*libraryDecorator)
return library != nil && library.hasLLNDKStubs() &&
- (!Bool(library.Properties.Llndk.Private) ||
- // TODO(b/170784825): until the LLNDK properties are moved into the cc_library,
- // the non-Vendor variants of the cc_library don't know if the corresponding
- // llndk_library set private: true. Since libft2 is the only private LLNDK
- // library, hardcode it during the transition.
- c.BaseModuleName() != "libft2")
+ !Bool(library.Properties.Llndk.Private)
}
// Returns true for LLNDK-private, VNDK-SP-private, and VNDK-core-private.