OSDN Git Service

[automerger skipped] Revert "DO NOT MERGE Separate SDP procedure from bonding state...
[android-x86/system-bt.git] / service / BUILD.gn
1 #
2 #  Copyright 2015 Google
3 #
4 #  Licensed under the Apache License, Version 2.0 (the "License");
5 #  you may not use this file except in compliance with the License.
6 #  You may obtain a copy of the License at:
7 #
8 #  http://www.apache.org/licenses/LICENSE-2.0
9 #
10 #  Unless required by applicable law or agreed to in writing, software
11 #  distributed under the License is distributed on an "AS IS" BASIS,
12 #  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 #  See the License for the specific language governing permissions and
14 #  limitations under the License.
15 #
16
17 source_set("service") {
18   sources = [
19     "adapter.cc",
20     "common/bluetooth/adapter_state.cc",
21     "common/bluetooth/advertise_data.cc",
22     "common/bluetooth/advertise_settings.cc",
23     "common/bluetooth/characteristic.cc",
24     "common/bluetooth/descriptor.cc",
25     "common/bluetooth/scan_filter.cc",
26     "common/bluetooth/scan_result.cc",
27     "common/bluetooth/scan_settings.cc",
28     "common/bluetooth/service.cc",
29     "common/bluetooth/util/atomic_string.cc",
30     "daemon.cc",
31     "gatt_client.cc",
32     "gatt_server.cc",
33     "gatt_server_old.cc",
34     "hal/bluetooth_gatt_interface.cc",
35     "hal/bluetooth_interface.cc",
36     "ipc/dbus/bluetooth_adapter.cc",
37     "ipc/dbus/ipc_handler_dbus.cc",
38     "hal/fake_bluetooth_gatt_interface.cc",
39     "hal/fake_bluetooth_interface.cc",
40     "ipc/ipc_handler.cc",
41     "ipc/ipc_handler_linux.cc",
42     "ipc/ipc_manager.cc",
43     "ipc/linux_ipc_host.cc",
44     "logging_helpers.cc",
45     "low_energy_advertiser.cc",
46     "low_energy_scanner.cc",
47     "low_energy_client.cc",
48     "settings.cc",
49   ]
50
51   include_dirs = [
52     "//",
53     "//include",
54     "//service/common",
55     "//third_party/modp_b64/modp64",
56   ]
57
58   deps = [
59     "//types",
60     "//third_party/libchrome:base",
61   ]
62 }
63
64 executable("bluetoothtbd") {
65   sources = [
66     "main.cc",
67   ]
68
69   deps = [
70     ":service",
71     "//btcore",
72     "//third_party/libchrome:base",
73     "//third_party/modp_b64",
74   ]
75
76   include_dirs = [ "//" ]
77
78   libs = [
79     "-ldl",
80     "-lpthread",
81     "-lrt",
82   ]
83 }
84
85 executable("service_unittests") {
86   testonly = true
87   sources = [
88     "test/fake_hal_util.cc",
89     "test/settings_unittest.cc",
90   ]
91
92   include_dirs = [ "//" ]
93
94   deps = [
95     ":service",
96     "//third_party/googletest:gmock_main",
97     "//third_party/libchrome:base",
98     "//third_party/modp_b64",
99   ]
100 }