aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2023-03-14 01:09:00 +0000
committerAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2023-03-14 01:09:00 +0000
commit64cbdd61d8a68650d32ba216783d809a7375463a (patch)
treeb9db03691594a729d4bcaf31e35bbc5d8ac3c6fc
parenta5cd8837f48c433cffb92b4745527ea0ebbb10e0 (diff)
parentb49e87fad15e445f36805fe952aac8310c66ec6b (diff)
downloadorchestrator-64cbdd61d8a68650d32ba216783d809a7375463a.tar.gz
Snap for 9737996 from b49e87fad15e445f36805fe952aac8310c66ec6b to udc-d1-release
Change-Id: Icd91fdefa4beb3525851d5e4b21ad032907ea196
-rw-r--r--core/cc/api_assembly.py1
-rw-r--r--core/cc/library.py6
2 files changed, 6 insertions, 1 deletions
diff --git a/core/cc/api_assembly.py b/core/cc/api_assembly.py
index 73d0bf1..8bc4ea3 100644
--- a/core/cc/api_assembly.py
+++ b/core/cc/api_assembly.py
@@ -317,6 +317,7 @@ class CcApiAssemblyContext(object):
out=output_so,
frontend=context.tools.clang_cxx(),
)
+ link_context.add_implicits(api_deps)
self._linker.link(ninja, link_context)
# TODO: Short term hack to make the stub library available to
diff --git a/core/cc/library.py b/core/cc/library.py
index f7c908b..fb3576b 100644
--- a/core/cc/library.py
+++ b/core/cc/library.py
@@ -59,6 +59,10 @@ class LinkContext():
self.flags = flags
self.out = out
self.frontend = frontend
+ self.implicits = [frontend]
+
+ def add_implicits(self, implicits: List[str]):
+ self.implicits.extend(implicits)
class Linker():
@@ -76,7 +80,7 @@ class Linker():
link_action = BuildAction(output=link_context.out,
inputs=link_context.objs,
rule=link_rule.name,
- implicits=[link_context.frontend]
+ implicits=link_context.implicits,
)
link_action.add_variable("ldFrontend", link_context.frontend)
link_action.add_variable("ldFlags", link_context.flags)