Skip to content

Commit

Permalink
Merge logging and types build targets
Browse files Browse the repository at this point in the history
Both "types" and "logging" build targets included "logging.h"
Merging them together avoids circular dependencies.

PiperOrigin-RevId: 555262816
  • Loading branch information
jgsobczak authored and copybara-github committed Aug 10, 2023
1 parent d19f21e commit 5393daf
Show file tree
Hide file tree
Showing 30 changed files with 23 additions and 74 deletions.
2 changes: 0 additions & 2 deletions connections/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ cc_library(
"//internal/analytics:event_logger",
"//internal/interop:device",
"//internal/platform:base",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/strings",
"@com_google_absl//absl/time",
Expand Down Expand Up @@ -102,7 +101,6 @@ cc_test(
"//connections/implementation:internal_test",
"//connections/v3:v3_types",
"//internal/platform:base",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform/implementation/g3", # build_cleaner: keep
"@com_github_protobuf_matchers//protobuf-matchers",
Expand Down
2 changes: 1 addition & 1 deletion connections/c/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ cc_test(
],
deps = [
"//connections:core",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform/implementation/windows",
"@com_github_protobuf_matchers//protobuf-matchers",
"@com_google_googletest//:gtest_main",
Expand Down
2 changes: 0 additions & 2 deletions connections/implementation/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,6 @@ cc_library(
"//internal/platform:comm",
"//internal/platform:connection_info",
"//internal/platform:error_code_recorder",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform:util",
"//internal/platform/implementation:comm",
Expand Down Expand Up @@ -236,7 +235,6 @@ cc_test(
"//internal/interop:device",
"//internal/platform:base",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform/implementation/g3", # build_cleaner: keep
Expand Down
2 changes: 0 additions & 2 deletions connections/implementation/analytics/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ cc_library(
"//connections:core_types",
"//internal/analytics:event_logger",
"//internal/platform:error_code_recorder",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform/implementation:types",
"//internal/proto/analytics:connections_log_cc_proto",
Expand Down Expand Up @@ -61,7 +60,6 @@ cc_test(
"//internal/platform:base",
"//internal/platform:comm",
"//internal/platform:error_code_recorder",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform/implementation/g3", # build_cleaner: keep
"//internal/proto/analytics:connections_log_cc_proto",
Expand Down
1 change: 0 additions & 1 deletion connections/implementation/mediums/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ cc_library(
"//internal/platform:base",
"//internal/platform:cancellation_flag",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform:uuid",
"//proto/mediums:web_rtc_signaling_frames_cc_proto",
Expand Down
1 change: 0 additions & 1 deletion connections/implementation/mediums/ble_v2/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ cc_library(
"//internal/flags:nearby_flags",
"//internal/platform:base",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform:util",
"//internal/platform:uuid",
Expand Down
1 change: 0 additions & 1 deletion connections/implementation/mediums/webrtc/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ cc_library(
"//connections/implementation/mediums:utils",
"//internal/platform:base",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:types",
"//proto/mediums:web_rtc_signaling_frames_cc_proto",
# TODO: Support WebRTC
Expand Down
1 change: 0 additions & 1 deletion fastpair/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,6 @@ cc_test(
"//fastpair/plugins:fake_fast_pair_plugin",
"//internal/account:test_support",
"//internal/network:types",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform/implementation/g3", # build_cleaner: keep
Expand Down
2 changes: 1 addition & 1 deletion fastpair/common/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ cc_library(
deps = [
"//fastpair/proto:fastpair_cc_proto",
"//internal/crypto_cros",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/preferences",
"@com_google_absl//absl/base:core_headers",
"@com_google_absl//absl/container:flat_hash_map",
Expand Down
2 changes: 1 addition & 1 deletion fastpair/crypto/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ cc_library(
"//fastpair/common",
"//internal/base:bluetooth_address",
"//internal/platform:base",
"//internal/platform:logging",
"//internal/platform:types",
"@boringssl//:crypto",
"@com_google_absl//absl/log:check",
],
Expand Down
2 changes: 1 addition & 1 deletion fastpair/dataparser/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ cc_library(
"//fastpair/crypto",
"//internal/base:bluetooth_address",
"//internal/platform:base",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/functional:any_invocable",
"@com_google_absl//absl/strings",
],
Expand Down
3 changes: 0 additions & 3 deletions fastpair/handshake/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ cc_library(
"//fastpair/repository",
"//internal/base:bluetooth_address",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform:uuid",
"@boringssl//:crypto",
Expand Down Expand Up @@ -89,7 +88,6 @@ cc_test(
"//fastpair/internal/mediums",
"//fastpair/repository:test_support",
"//fastpair/testing",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform/implementation/g3", # build_cleaner: keep
"@com_github_protobuf_matchers//protobuf-matchers",
Expand Down Expand Up @@ -164,7 +162,6 @@ cc_test(
":handshake",
"//fastpair/common",
"//fastpair/internal/mediums",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform/implementation/g3", # build_cleaner: keep
Expand Down
1 change: 0 additions & 1 deletion fastpair/internal/mediums/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ cc_library(
deps = [
"//fastpair/common",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform/implementation:comm",
"@com_google_absl//absl/base:core_headers",
Expand Down
4 changes: 0 additions & 4 deletions fastpair/message_stream/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ cc_library(
"//fastpair/common",
"//internal/platform:base",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform:uuid",
Expand Down Expand Up @@ -106,7 +105,6 @@ cc_library(
":message_stream",
"//fastpair/common",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"@com_google_absl//absl/status",
Expand All @@ -128,7 +126,6 @@ cc_test(
":message_stream",
"//fastpair/common",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform/implementation/g3", # build_cleaner: keep
Expand All @@ -153,7 +150,6 @@ cc_test(
":message_stream",
"//fastpair/common",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform/implementation:types",
Expand Down
4 changes: 2 additions & 2 deletions fastpair/proto/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ cc_library(
deps = [
":fastpair_cc_proto",
"//fastpair/common",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/strings",
"@nlohmann_json//:json",
],
Expand All @@ -57,7 +57,7 @@ cc_library(
":fastpair_cc_proto",
"//fastpair/common",
"//fastpair/repository",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/time",
],
)
Expand Down
2 changes: 0 additions & 2 deletions fastpair/repository/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ cc_library(
"//fastpair/proto:proto_builder",
"//fastpair/server_access",
"//internal/base",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/status",
"@com_google_absl//absl/strings",
Expand All @@ -62,7 +61,6 @@ cc_library(
deps = [
"//fastpair/common",
"//internal/base",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/functional:any_invocable",
],
Expand Down
2 changes: 1 addition & 1 deletion fastpair/retroactive/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ cc_test(
"//internal/base:bluetooth_address",
"//internal/platform:base",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform/implementation/g3", # build_cleaner: keep
"@com_github_protobuf_matchers//protobuf-matchers",
"@com_google_absl//absl/status",
Expand Down
1 change: 0 additions & 1 deletion fastpair/scanning/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ cc_library(
"//fastpair/repository:device_repository",
"//fastpair/scanning/fastpair:scanning",
"//internal/base",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/functional:bind_front",
],
Expand Down
1 change: 0 additions & 1 deletion fastpair/scanning/fastpair/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ cc_library(
"//internal/base",
"//internal/platform:base",
"//internal/platform:comm",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/functional:any_invocable",
"@com_google_absl//absl/functional:bind_front",
Expand Down
1 change: 0 additions & 1 deletion fastpair/server_access/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ cc_library(
"//internal/auth:types",
"//internal/base",
"//internal/network:types",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/status:statusor",
"@com_google_absl//absl/strings",
Expand Down
2 changes: 1 addition & 1 deletion fastpair/ui/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ cc_library(
"//fastpair/common",
"//fastpair/repository",
"//internal/base",
"//internal/platform:logging",
"//internal/platform:types",
"@com_google_absl//absl/functional:any_invocable",
"@com_google_absl//absl/strings",
],
Expand Down
2 changes: 1 addition & 1 deletion internal/data/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ cc_library(
"memory_data_set.h",
],
deps = [
"//internal/platform:logging",
"//internal/platform:types",
"//third_party/leveldb:db",
"//third_party/leveldb:table",
"//third_party/leveldb:util",
Expand Down
1 change: 0 additions & 1 deletion internal/network/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ cc_library(
],
deps = [
":types",
"//internal/platform:logging",
"//internal/platform:types",
"//internal/platform/implementation:platform",
"@com_google_absl//absl/base:core_headers",
Expand Down
39 changes: 8 additions & 31 deletions internal/platform/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -94,31 +94,6 @@ cc_library(
],
)

cc_library(
name = "logging",
hdrs = [
"logging.h",
],
copts = ["-DCORE_ADAPTER_DLL"],
visibility = [
"//connections:__subpackages__",
"//fastpair:__subpackages__",
"//internal/auth:__subpackages__",
"//internal/auth/credential_store:__subpackages__",
"//internal/data:__subpackages__",
"//internal/network:__subpackages__",
"//internal/platform:__subpackages__",
"//internal/proto/analytics:__subpackages__",
"//location/nearby/analytics/cpp:__subpackages__",
"//presence:__subpackages__",
],
deps = [
"//internal/platform/implementation:platform",
"//internal/platform/implementation:types",
"@com_google_glog//:glog",
],
)

cc_library(
name = "cancellation_flag",
srcs = [
Expand Down Expand Up @@ -161,7 +136,7 @@ cc_library(
"//presence:__subpackages__",
],
deps = [
":logging",
":types",
"//proto:connections_enums_cc_proto",
"@com_google_absl//absl/status",
"@com_google_absl//absl/status:statusor",
Expand All @@ -182,7 +157,7 @@ cc_library(
],
visibility = ["//connections/implementation:__subpackages__"],
deps = [
":logging",
":types",
"//proto:connections_enums_cc_proto",
"//proto/errorcode:error_code_enums_cc_proto",
"@com_google_absl//absl/functional:any_invocable",
Expand Down Expand Up @@ -227,7 +202,6 @@ cc_library(
],
deps = [
":base",
":logging",
":types",
":uuid",
"//internal/base",
Expand Down Expand Up @@ -355,23 +329,28 @@ cc_library(
"//connections:__subpackages__",
"//fastpair:__subpackages__",
"//internal/account:__subpackages__",
"//internal/auth:__subpackages__",
"//internal/auth/credential_store:__subpackages__",
"//internal/base:__subpackages__",
"//internal/data:__subpackages__",
"//internal/flags:__subpackages__",
"//internal/interop:__pkg__",
"//internal/network:__subpackages__",
"//internal/platform:__subpackages__",
"//internal/platform/implementation/g3:__pkg__",
"//internal/platform/implementation/windows:__subpackages__",
"//internal/preferences:__subpackages__",
"//internal/proto/analytics:__subpackages__",
"//internal/test:__subpackages__",
"//internal/weave:__subpackages__",
"//location/nearby/analytics/cpp:__subpackages__",
"//location/nearby/cpp:__subpackages__",
"//location/nearby/testing/nearby_native:__subpackages__",
"//presence:__subpackages__",
"//third_party/nearby/sharing:__subpackages__",
],
deps = [
":base",
":logging",
":util",
"//internal/crypto_cros",
"//internal/platform/implementation:platform",
Expand Down Expand Up @@ -427,7 +406,6 @@ cc_library(
deps = [
":base",
":cancellation_flag",
":logging",
":types",
":uuid",
"//internal/base",
Expand Down Expand Up @@ -488,7 +466,6 @@ cc_test(
":base",
":comm",
":connection_info",
":logging",
":test_util",
":types",
":uuid",
Expand Down
3 changes: 1 addition & 2 deletions internal/platform/implementation/g3/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ cc_library(
deps = [
":preferences_repository",
"//internal/platform:base",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform:util",
"//internal/platform/implementation:types",
"//internal/platform/implementation/shared:count_down_latch",
Expand Down Expand Up @@ -103,7 +103,6 @@ cc_library(
"@com_google_absl//absl/synchronization",
"//internal/platform:base",
"//internal/platform:cancellation_flag",
"//internal/platform:logging",
"//internal/platform:test_util",
"//internal/platform:types",
"//internal/platform:uuid",
Expand Down
Loading

0 comments on commit 5393daf

Please sign in to comment.