• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2024 The Pigweed Authors
2#
3# Licensed under the Apache License, Version 2.0 (the "License"); you may not
4# use this file except in compliance with the License. You may obtain a copy of
5# the License at
6#
7#     https://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12# License for the specific language governing permissions and limitations under
13# the License.
14
15include($ENV{PW_ROOT}/pw_build/pigweed.cmake)
16
17###############################################################################
18##          Everything below here is intended to be emboss only              ##
19##          and will be skipped if emboss isn't enabled.                     ##
20###############################################################################
21if("${dir_pw_third_party_emboss}" STREQUAL "")
22  # Skip emboss defs if it's not configured
23  return()
24endif()
25
26pw_add_library(pw_bluetooth_proxy STATIC
27
28# LINT.IfChange
29  HEADERS
30    public/pw_bluetooth_proxy/basic_l2cap_channel.h
31    public/pw_bluetooth_proxy/gatt_notify_channel.h
32    public/pw_bluetooth_proxy/h4_packet.h
33    public/pw_bluetooth_proxy/internal/acl_data_channel.h
34    public/pw_bluetooth_proxy/internal/gatt_notify_channel_internal.h
35    public/pw_bluetooth_proxy/internal/h4_storage.h
36    public/pw_bluetooth_proxy/internal/hci_transport.h
37    public/pw_bluetooth_proxy/internal/l2cap_aclu_signaling_channel.h
38    public/pw_bluetooth_proxy/internal/l2cap_channel.h
39    public/pw_bluetooth_proxy/internal/l2cap_channel_manager.h
40    public/pw_bluetooth_proxy/internal/l2cap_coc_internal.h
41    public/pw_bluetooth_proxy/internal/l2cap_signaling_channel.h
42    public/pw_bluetooth_proxy/internal/l2cap_status_tracker.h
43    public/pw_bluetooth_proxy/internal/l2cap_leu_signaling_channel.h
44    public/pw_bluetooth_proxy/internal/logical_transport.h
45    public/pw_bluetooth_proxy/internal/multibuf_writer.h
46    public/pw_bluetooth_proxy/internal/rfcomm_fcs.h
47    public/pw_bluetooth_proxy/l2cap_channel_common.h
48    public/pw_bluetooth_proxy/l2cap_coc.h
49    public/pw_bluetooth_proxy/l2cap_status_delegate.h
50    public/pw_bluetooth_proxy/proxy_host.h
51    public/pw_bluetooth_proxy/rfcomm_channel.h
52# LINT.ThenChange(BUILD.bazel, BUILD.gn)
53
54  PUBLIC_INCLUDES
55    public
56
57# LINT.IfChange
58  PUBLIC_DEPS
59    pw_allocator.best_fit
60    pw_allocator.synchronized_allocator
61    pw_bluetooth.emboss_att
62    pw_bluetooth.emboss_hci_commands
63    pw_bluetooth.emboss_hci_common
64    pw_bluetooth.emboss_hci_data
65    pw_bluetooth.emboss_hci_events
66    pw_bluetooth.emboss_hci_h4
67    pw_bluetooth.emboss_l2cap_frames
68    pw_bluetooth.emboss_rfcomm_frames
69    pw_bluetooth.emboss_util
70    pw_containers
71    pw_function
72    pw_log
73    pw_multibuf
74    pw_multibuf.simple_allocator
75    pw_result
76    pw_span
77    pw_span.cast
78    pw_status
79    pw_sync.lock_annotations
80    pw_sync.mutex
81  SOURCES
82    acl_data_channel.cc
83    basic_l2cap_channel.cc
84    gatt_notify_channel.cc
85    h4_storage.cc
86    l2cap_aclu_signaling_channel.cc
87    l2cap_channel.cc
88    l2cap_channel_manager.cc
89    l2cap_coc.cc
90    l2cap_leu_signaling_channel.cc
91    l2cap_signaling_channel.cc
92    l2cap_status_tracker.cc
93    multibuf_writer.cc
94    proxy_host.cc
95    rfcomm_channel.cc
96    rfcomm_fcs.cc
97# LINT.ThenChange(Android.bp, BUILD.bazel, BUILD.gn)
98
99)
100
101pw_add_library(pw_bluetooth_proxy.test_utils STATIC
102
103# LINT.IfChange
104  HEADERS
105    pw_bluetooth_proxy_private/test_utils.h
106  PUBLIC_DEPS
107    pw_bluetooth_proxy
108    pw_third_party.fuchsia.stdcompat
109    pw_bluetooth.emboss_hci_commands
110    pw_bluetooth.emboss_hci_common
111    pw_bluetooth.emboss_hci_events
112    pw_bluetooth.emboss_hci_h4
113    pw_multibuf.testing
114    pw_unit_test
115  SOURCES
116    test_utils.cc
117# LINT.ThenChange(Android.bp, BUILD.bazel, BUILD.gn)
118
119)
120
121pw_add_test(pw_bluetooth_proxy.pw_bluetooth_proxy_test
122
123# LINT.IfChange
124  PRIVATE_DEPS
125    pw_bluetooth_proxy
126    pw_bluetooth_proxy.test_utils
127    pw_third_party.fuchsia.stdcompat
128    pw_bluetooth.emboss_att
129    pw_bluetooth.emboss_hci_commands
130    pw_bluetooth.emboss_hci_common
131    pw_bluetooth.emboss_hci_events
132    pw_bluetooth.emboss_hci_h4
133    pw_multibuf
134  SOURCES
135    gatt_notify_test.cc
136    h4_packet_test.cc
137    l2cap_coc_test.cc
138    multibuf_writer_test.cc
139    proxy_host_test.cc
140    rfcomm_fcs_test.cc
141    rfcomm_test.cc
142    utils_test.cc
143# LINT.ThenChange(Android.bp, BUILD.bazel, BUILD.gn)
144
145  GROUPS
146    modules
147)
148
149
150