aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Galenson <jgalenson@google.com>2021-01-21 17:11:20 -0800
committerJoel Galenson <jgalenson@google.com>2021-01-21 17:11:20 -0800
commite5ad1620ff270796902c3fbb0103b5a822dc5607 (patch)
tree52d6ab1d42900fe16e6596b7e6888fe071f6fc41
parent955366c80448cf01ba3c315d446bd677907563e4 (diff)
downloadbt-e5ad1620ff270796902c3fbb0103b5a822dc5607.tar.gz
Explicitly add static dependencies
Soong does not propagate dependencies through static targets, which can cause linker errors. Until this is fixed, add the dependencies explicitly. Test: Build with and without coverage locally Test: Will run TreeHugger and Forrest Change-Id: Icab6568f3cc0783bf2a550ecd15b08f57c0d77b2
-rw-r--r--build/Android.bp6
-rw-r--r--gd/Android.bp38
2 files changed, 43 insertions, 1 deletions
diff --git a/build/Android.bp b/build/Android.bp
index c16c20cf1..46f24ebc9 100644
--- a/build/Android.bp
+++ b/build/Android.bp
@@ -84,7 +84,11 @@ fluoride_defaults {
fluoride_defaults {
name: "fluoride_defaults",
defaults: ["fluoride_defaults_fuzzable", "fluoride_types_defaults"],
- shared_libs: ["libstatslog"],
+ shared_libs: [
+ "libgrpc++",
+ "libgrpc_wrap",
+ "libstatslog"
+ ],
sanitize: {
misc_undefined: ["bounds"],
},
diff --git a/gd/Android.bp b/gd/Android.bp
index 9f5fa8644..64dfd5c87 100644
--- a/gd/Android.bp
+++ b/gd/Android.bp
@@ -163,6 +163,8 @@ cc_defaults {
"libchrome",
"libcrypto",
"libflatbuffers-cpp",
+ "libgrpc++",
+ "libgrpc_wrap",
],
static_libs: [
"libbluetooth-protos",
@@ -237,7 +239,9 @@ cc_binary {
"libbacktrace",
"libchrome",
"libcrypto",
+ "libgrpc++",
"libgrpc++_unsecure",
+ "libgrpc_wrap",
"libprotobuf-cpp-full",
],
target: {
@@ -248,6 +252,10 @@ cc_binary {
"libutils",
"libcutils",
],
+ static_libs: [
+ "libbt_common_sys_prop_cxx",
+ "libbt_hidl_hal_cxx",
+ ],
},
host: {
required: [
@@ -295,6 +303,10 @@ cc_test {
"libutils",
"libcutils",
],
+ static_libs: [
+ "libbt_common_sys_prop_cxx",
+ "libbt_hidl_hal_cxx",
+ ],
},
},
srcs: [
@@ -335,6 +347,8 @@ cc_test {
shared_libs: [
"libchrome",
"libcrypto",
+ "libgrpc++",
+ "libgrpc_wrap",
],
sanitize: {
address: true,
@@ -370,6 +384,24 @@ cc_test {
"libcxxbridge05",
"libchrome",
],
+ shared_libs: [
+ "libgrpc++",
+ "libgrpc_wrap",
+ ],
+ target: {
+ android: {
+ shared_libs: [
+ "android.hardware.bluetooth@1.0",
+ "libhidlbase",
+ "libutils",
+ "libcutils",
+ ],
+ static_libs: [
+ "libbt_common_sys_prop_cxx",
+ "libbt_hidl_hal_cxx",
+ ],
+ },
+ },
}
cc_defaults {
@@ -397,6 +429,8 @@ cc_defaults {
shared_libs: [
"libcrypto",
"libflatbuffers-cpp",
+ "libgrpc++",
+ "libgrpc_wrap",
],
cflags: [
"-DFUZZ_TARGET",
@@ -409,6 +443,10 @@ cc_defaults {
"libhidlbase",
"libutils",
],
+ static_libs: [
+ "libbt_common_sys_prop_cxx",
+ "libbt_hidl_hal_cxx",
+ ],
},
},
}