1#
2#  Copyright 2015 Google, Inc.
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
17static_library("hci") {
18  sources = [
19    "src/buffer_allocator.cc",
20    "src/packet_fragmenter.cc",
21  ]
22
23  include_dirs = [
24    "include",
25    "//bt/system/",
26    "//bt/system/bta/include",
27    "//bt/system/stack/include",
28  ]
29
30  deps = [
31    "//bt/system/common",
32  ]
33
34  configs += [
35    "//bt/system:target_defaults",
36    "//bt/system/log:log_defaults",
37  ]
38}
39
40if (use.test) {
41  executable("net_test_hci") {
42    sources = [
43      "test/packet_fragmenter_test.cc",
44    ]
45
46    include_dirs = [
47      "//bt/system/",
48      "//bt/system/osi/test",
49      "//bt/system/stack/include",
50    ]
51
52    deps = [
53      "//bt/system/hci",
54      "//bt/system/osi",
55      "//bt/system/btcore",
56    ]
57
58    configs += [
59      "//bt/system:target_defaults",
60      "//bt/system:external_gtest_main",
61    ]
62
63    libs = [
64      "pthread",
65      "rt",
66      "dl",
67    ]
68  }
69}
70