1#
2#  Copyright 2018 Android Open Source Project
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
17config("avrcp_config") {
18  include_dirs = [
19    "//bt/system/",
20    "//bt/system/stack/include",
21    "//bt/system/profile/avrcp",
22    "//bt/system/packet",
23    "//bt/system/packet/include",
24    "//bt/system/include/hardware/avrcp",
25  ]
26
27  configs = [
28    "//bt/system:target_defaults",
29    "//bt/system/log:log_defaults",
30  ]
31}
32
33static_library("profile_avrcp") {
34  sources = [
35    "connection_handler.cc",
36    "device.cc",
37  ]
38
39  deps = [
40    "//bt/flags:bluetooth_flags_c_lib",
41    "//bt/system/gd/rust/shim:libbluetooth_rust_interop",
42  ]
43
44  configs += [
45    ":avrcp_config"
46  ]
47}
48
49if (use.test) {
50  executable("net_test_avrcp") {
51    sources = [
52      "tests/avrcp_connection_handler_test.cc",
53      "tests/avrcp_device_test.cc",
54    ]
55
56    deps = [
57      ":profile_avrcp",
58      "//bt/system/device:device",
59      "//bt/system/osi:osi",
60      "//bt/system/packet:packet",
61      "//bt/system/types:types",
62    ]
63
64    configs += [
65      "//bt/system:external_gmock_main",
66      ":avrcp_config",
67    ]
68  }
69}
70