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
|
--- services/device/usb/BUILD.gn.orig 2022-10-29 17:50:56 UTC
+++ services/device/usb/BUILD.gn
@@ -103,15 +103,17 @@ static_library("usb") {
deps += [ "//third_party/re2" ]
}
- if (is_mac) {
- sources += [
- "usb_device_handle_mac.cc",
- "usb_device_handle_mac.h",
- "usb_device_mac.cc",
- "usb_device_mac.h",
- "usb_service_mac.cc",
- "usb_service_mac.h",
- ]
+ if (is_mac || is_openbsd) {
+ if (is_mac) {
+ sources += [
+ "usb_device_handle_mac.cc",
+ "usb_device_handle_mac.h",
+ "usb_device_mac.cc",
+ "usb_device_mac.h",
+ "usb_service_mac.cc",
+ "usb_service_mac.h",
+ ]
+ }
# These sources and deps are required for libusb.
# TODO(https://crbug.com/1096743) Remove these sources.
@@ -135,6 +137,13 @@ static_library("usb") {
deps += [ "//third_party/libusb" ]
}
+ if (is_freebsd) {
+ sources += [
+ "usb_service_fake.cc",
+ "usb_service_fake.h",
+ ]
+ }
+
if (is_linux || is_chromeos) {
sources += [
"usb_device_linux.cc",
@@ -152,7 +161,7 @@ static_library("usb") {
deps += [ "//device/udev_linux" ]
}
- if (is_android || is_chromeos || is_linux) {
+ if (is_android || is_chromeos || is_linux && !is_bsd) {
sources += [
"usb_device_handle_usbfs.cc",
"usb_device_handle_usbfs.h",
|