mixed builds correctly reference stubs libs
Bug: 270408757 Test: go test Test: m NeuralNetworksTest_shared_partial --bazel-mode-staging && verify that Ninja commands link libneuralnetworks via stubs Change-Id: I19bf5a829cea7fd00c0f82511ad2bddbc40fae4f
This commit is contained in:
@@ -149,6 +149,7 @@ sharedLibraries = []
|
||||
rootSharedLibraries = []
|
||||
|
||||
shared_info_tag = "//build/bazel/rules/cc:cc_library_shared.bzl%CcSharedLibraryOutputInfo"
|
||||
stubs_tag = "//build/bazel/rules/cc:cc_stub_library.bzl%CcStubInfo"
|
||||
unstripped_tag = "//build/bazel/rules/cc:stripped_cc_common.bzl%CcUnstrippedInfo"
|
||||
unstripped = ""
|
||||
|
||||
@@ -160,6 +161,8 @@ if shared_info_tag in p:
|
||||
unstripped = path
|
||||
if unstripped_tag in p:
|
||||
unstripped = p[unstripped_tag].unstripped.path
|
||||
elif stubs_tag in p:
|
||||
rootSharedLibraries.extend([f.path for f in target.files.to_list()])
|
||||
else:
|
||||
for linker_input in linker_inputs:
|
||||
for library in linker_input.libraries:
|
||||
|
Reference in New Issue
Block a user