diff --git a/presence/implementation/BUILD b/presence/implementation/BUILD index dec31ae5..b7d5d149 100644 --- a/presence/implementation/BUILD +++ b/presence/implementation/BUILD @@ -74,7 +74,7 @@ cc_library( "service_controller_impl.h", ], defines = select({ - ":norust_or_windows_or_android": ["USE_RUST_LDT=0"], + ":norust_or_windows_or_android": [], "//conditions:default": ["USE_RUST_LDT=1"], }), visibility = [ diff --git a/presence/implementation/advertisement_decoder_test.cc b/presence/implementation/advertisement_decoder_test.cc index 4e8f597a..871f51dc 100644 --- a/presence/implementation/advertisement_decoder_test.cc +++ b/presence/implementation/advertisement_decoder_test.cc @@ -38,7 +38,6 @@ using ::nearby::ByteArray; // NOLINT using ::nearby::internal::IdentityType; using ::nearby::internal::SharedCredential; // NOLINT using ::testing::ElementsAre; -using ::protobuf_matchers::EqualsProto; using ::testing::Matcher; using ::testing::Pointwise; using ::testing::Return; @@ -55,7 +54,7 @@ ScanRequest GetScanRequest() { IdentityType::IDENTITY_TYPE_PROVISIONED}}; } -#if USE_RUST_LDT == 1 +#ifdef USE_RUST_LDT ScanRequest GetScanRequest(std::vector credentials) { LegacyPresenceScanFilter scan_filter = {.remote_public_credentials = credentials}; diff --git a/presence/implementation/advertisement_factory_test.cc b/presence/implementation/advertisement_factory_test.cc index 2631f85c..23ceaaa4 100644 --- a/presence/implementation/advertisement_factory_test.cc +++ b/presence/implementation/advertisement_factory_test.cc @@ -40,7 +40,7 @@ using ::testing::NiceMock; using ::testing::Return; using ::testing::status::StatusIs; -#if USE_RUST_LDT == 1 +#ifdef USE_RUST_LDT LocalCredential CreateLocalCredential(IdentityType identity_type) { // Values copied from LDT tests ByteArray seed({204, 219, 36, 137, 233, 252, 172, 66, 179, 147, 72, diff --git a/presence/implementation/ldt.cc b/presence/implementation/ldt.cc index 898dc677..01126dd2 100644 --- a/presence/implementation/ldt.cc +++ b/presence/implementation/ldt.cc @@ -22,7 +22,7 @@ #include "absl/status/statusor.h" #include "absl/strings/str_format.h" #include "absl/strings/string_view.h" -#if USE_RUST_LDT == 1 +#ifdef USE_RUST_LDT #include "third_party/beto-core/src/nearby/presence/ldt_np_adv_ffi/include/np_ldt.h" #else #include "presence/implementation/np_ldt.h" diff --git a/presence/implementation/ldt.h b/presence/implementation/ldt.h index f9f5c23e..6a563505 100644 --- a/presence/implementation/ldt.h +++ b/presence/implementation/ldt.h @@ -20,7 +20,7 @@ #include "absl/status/statusor.h" #include "absl/strings/string_view.h" -#if USE_RUST_LDT == 1 +#ifdef USE_RUST_LDT #include "third_party/beto-core/src/nearby/presence/ldt_np_adv_ffi/include/np_ldt.h" #else #include "presence/implementation/np_ldt.h" diff --git a/presence/implementation/ldt_test.cc b/presence/implementation/ldt_test.cc index 60423dc3..ff7dc5bc 100644 --- a/presence/implementation/ldt_test.cc +++ b/presence/implementation/ldt_test.cc @@ -29,7 +29,7 @@ namespace { using ::nearby::ByteArray; using ::nearby::internal::SharedCredential; -#if USE_RUST_LDT == 1 +#ifdef USE_RUST_LDT // Test data from Android tests. constexpr absl::string_view kKeySeedBase16 =