1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
From: PF4Public@users.noreply.github.com
License: BSD
Subject: Fix building with use_bluez=false
This is a quick and dirty fix for building chromium with use_bluez=false
It prevents initialization and usage of Bluetooth by the browser
It is not supposed to be applied for use_bluez=true
WebAuthn is prevented from using Bluetooth, but it might still work with USB
see also https://github.com/PF4Public/gentoo-overlay/issues/254
---
--- a/chrome/browser/chrome_browser_main_linux.cc
+++ b/chrome/browser/chrome_browser_main_linux.cc
@@ -68,8 +68,8 @@ void ChromeBrowserMainPartsLinux::PostCr
#if !BUILDFLAG(IS_CHROMEOS)
#if BUILDFLAG(USE_DBUS)
- bluez::BluezDBusManager::Initialize(
- dbus_thread_linux::GetSharedSystemBus().get());
+ //bluez::BluezDBusManager::Initialize(
+ // dbus_thread_linux::GetSharedSystemBus().get());
#endif // BUILDFLAG(USE_DBUS)
// Set up crypt config. This needs to be done before anything starts the
@@ -137,7 +137,7 @@ void ChromeBrowserMainPartsLinux::PostDe
#if BUILDFLAG(IS_CHROMEOS)
// No-op; per PostBrowserStart() comment, this is done elsewhere.
#else
- bluez::BluezDBusManager::Shutdown();
+ //bluez::BluezDBusManager::Shutdown();
#endif // BUILDFLAG(IS_CHROMEOS)
ChromeBrowserMainPartsPosix::PostDestroyThreads();
--- a/chrome/browser/metrics/bluetooth_metrics_provider.cc
+++ b/chrome/browser/metrics/bluetooth_metrics_provider.cc
@@ -16,9 +16,7 @@ BluetoothMetricsProvider::~BluetoothMetr
bool BluetoothMetricsProvider::ProvideHistograms() {
base::UmaHistogramEnumeration("Bluetooth.StackName",
- floss::features::IsFlossEnabled()
- ? BluetoothStackName::kFloss
- : BluetoothStackName::kBlueZ);
+ BluetoothStackName::kBlueZ);
return true;
}
--- a/device/bluetooth/bluetooth_adapter_factory.cc
+++ b/device/bluetooth/bluetooth_adapter_factory.cc
@@ -48,6 +48,7 @@ static constexpr bool kBluetoothSupporte
bool BluetoothAdapterFactory::IsBluetoothSupported() {
// SetAdapterForTesting() may be used to provide a test or mock adapter
// instance even on platforms that would otherwise not support it.
+ return false;
if (Get()->adapter_) {
return true;
}
@@ -55,6 +56,7 @@ bool BluetoothAdapterFactory::IsBluetoot
}
bool BluetoothAdapterFactory::IsLowEnergySupported() {
+ return false;
if (override_values_) {
return override_values_->GetLESupported();
}
|