blob: 3b96cfd1688c1601c112ad2a9381a76ceae3ee2f [file] [log] [blame]
Brian Silverman6470f442018-08-05 12:08:16 -07001package(default_visibility = ["//visibility:public"])
Brian Silverman100534c2015-09-07 15:51:23 -04002
Brian Silverman246cb222019-02-02 16:38:18 -08003cc_library(
4 name = "bitpacking",
5 hdrs = [
6 "bitpacking.h",
7 ],
8 visibility = ["//visibility:public"],
9 deps = [
Austin Schuhb72be802022-01-02 12:26:28 -080010 "@com_google_absl//absl/types:span",
Brian Silverman246cb222019-02-02 16:38:18 -080011 ],
12)
13
14cc_test(
15 name = "bitpacking_test",
16 srcs = [
17 "bitpacking_test.cc",
18 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080019 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman246cb222019-02-02 16:38:18 -080020 deps = [
21 ":bitpacking",
22 "//aos/testing:googletest",
23 ],
24)
25
Diana Vandenberg19bb9e22016-02-03 21:24:31 -080026py_library(
Brian Silverman6470f442018-08-05 12:08:16 -070027 name = "py_trapezoid_profile",
28 srcs = [
29 "trapezoid_profile.py",
30 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080031 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -070032 deps = [
33 ":python_init",
34 ],
Diana Vandenberg19bb9e22016-02-03 21:24:31 -080035)
36
James Kuszmaul4ed5fb12022-03-22 15:20:04 -070037cc_binary(
38 name = "log_to_mcap",
39 srcs = ["log_to_mcap.cc"],
40 deps = [
41 ":mcap_logger",
42 "//aos:init",
43 "//aos/events/logging:log_reader",
44 "//frc971/control_loops:control_loops_fbs",
45 ],
46)
47
48cc_library(
49 name = "mcap_logger",
50 srcs = ["mcap_logger.cc"],
51 hdrs = ["mcap_logger.h"],
52 target_compatible_with = ["@platforms//os:linux"],
53 deps = [
54 "//aos:configuration_fbs",
55 "//aos:fast_string_builder",
56 "//aos:flatbuffer_utils",
57 "//aos/events:event_loop",
58 "@com_github_nlohmann_json//:json",
59 ],
60)
61
62cc_test(
63 name = "mcap_logger_test",
64 srcs = ["mcap_logger_test.cc"],
65 target_compatible_with = ["@platforms//os:linux"],
66 deps = [
67 ":mcap_logger",
68 "//aos/testing:googletest",
69 "@com_github_nlohmann_json//:json",
70 ],
71)
72
Brian Silverman100534c2015-09-07 15:51:23 -040073cc_library(
James Kuszmaul0af658b2019-01-25 18:36:29 -080074 name = "math",
75 hdrs = ["math.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -080076 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul0af658b2019-01-25 18:36:29 -080077 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -070078 "@org_tuxfamily_eigen//:eigen",
James Kuszmaul0af658b2019-01-25 18:36:29 -080079 ],
80)
81
82cc_test(
83 name = "math_test",
84 srcs = ["math_test.cc"],
Philipp Schraderdada1072020-11-24 11:34:46 -080085 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul0af658b2019-01-25 18:36:29 -080086 deps = [
87 ":math",
88 "//aos/testing:googletest",
89 ],
90)
91
92cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -070093 name = "death_test_log_implementation",
94 hdrs = [
95 "death_test_log_implementation.h",
96 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080097 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -070098 deps = [
John Park33858a32018-09-28 23:05:48 -070099 "//aos/logging:implementations",
Brian Silverman6470f442018-08-05 12:08:16 -0700100 ],
Brian Silverman100534c2015-09-07 15:51:23 -0400101)
102
103cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -0700104 name = "phased_loop",
105 srcs = [
106 "phased_loop.cc",
107 ],
108 hdrs = [
109 "phased_loop.h",
110 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800111 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700112 deps = [
James Kuszmaul0af658b2019-01-25 18:36:29 -0800113 "//aos/time",
Austin Schuhf257f3c2019-10-27 21:00:43 -0700114 "@com_github_google_glog//:glog",
Brian Silverman6470f442018-08-05 12:08:16 -0700115 ],
Brian Silverman100534c2015-09-07 15:51:23 -0400116)
117
118cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -0700119 name = "log_interval",
120 hdrs = [
121 "log_interval.h",
122 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800123 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700124 deps = [
John Park33858a32018-09-28 23:05:48 -0700125 "//aos/logging",
James Kuszmaul0af658b2019-01-25 18:36:29 -0800126 "//aos/time",
Brian Silverman6470f442018-08-05 12:08:16 -0700127 ],
Brian Silverman100534c2015-09-07 15:51:23 -0400128)
129
130cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -0700131 name = "trapezoid_profile",
132 srcs = [
133 "trapezoid_profile.cc",
134 ],
135 hdrs = [
136 "trapezoid_profile.h",
137 ],
138 linkopts = [
139 "-lm",
140 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800141 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700142 deps = [
John Park33858a32018-09-28 23:05:48 -0700143 "//aos/logging",
James Kuszmaul0af658b2019-01-25 18:36:29 -0800144 "//aos/time",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700145 "@org_tuxfamily_eigen//:eigen",
Brian Silverman6470f442018-08-05 12:08:16 -0700146 ],
Brian Silverman100534c2015-09-07 15:51:23 -0400147)
148
149cc_test(
Brian Silverman6470f442018-08-05 12:08:16 -0700150 name = "trapezoid_profile_test",
151 srcs = [
152 "trapezoid_profile_test.cc",
153 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800154 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700155 deps = [
156 ":trapezoid_profile",
157 "//aos/testing:googletest",
158 ],
Brian Silverman100534c2015-09-07 15:51:23 -0400159)
160
161cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -0700162 name = "wrapping_counter",
163 srcs = [
164 "wrapping_counter.cc",
165 ],
166 hdrs = [
167 "wrapping_counter.h",
168 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800169 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman100534c2015-09-07 15:51:23 -0400170)
171
172cc_test(
Brian Silverman6470f442018-08-05 12:08:16 -0700173 name = "wrapping_counter_test",
174 srcs = [
175 "wrapping_counter_test.cc",
176 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800177 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700178 deps = [
179 ":wrapping_counter",
180 "//aos/testing:googletest",
181 ],
Brian Silverman100534c2015-09-07 15:51:23 -0400182)
183
Austin Schuh044e18b2015-10-21 20:17:09 -0700184cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -0700185 name = "options",
186 hdrs = [
187 "options.h",
188 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800189 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh044e18b2015-10-21 20:17:09 -0700190)
191
Brian Silverman100534c2015-09-07 15:51:23 -0400192cc_test(
Brian Silverman6470f442018-08-05 12:08:16 -0700193 name = "options_test",
194 srcs = [
195 "options_test.cc",
196 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800197 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700198 deps = [
199 ":options",
200 "//aos/testing:googletest",
201 ],
Brian Silverman100534c2015-09-07 15:51:23 -0400202)
Brian Silverman3d37a5f2014-09-05 18:42:20 -0400203
204cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -0700205 name = "compiler_memory_barrier",
206 hdrs = [
207 "compiler_memory_barrier.h",
208 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800209 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman3d37a5f2014-09-05 18:42:20 -0400210)
Brian Silverman521e6ba2014-09-04 13:37:46 -0400211
212cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -0700213 name = "global_factory",
214 hdrs = [
215 "global_factory.h",
216 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800217 target_compatible_with = ["@platforms//os:linux"],
Parker Schuh36416692017-02-18 17:34:15 -0800218)
219
220cc_test(
Brian Silverman6470f442018-08-05 12:08:16 -0700221 name = "global_factory_test",
222 srcs = [
223 "global_factory_test.cc",
224 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800225 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700226 deps = [
227 ":global_factory",
228 "//aos/testing:googletest",
229 ],
Parker Schuh36416692017-02-18 17:34:15 -0800230)
231
Brian Silvermandcaa3f72015-11-29 05:32:08 +0000232cc_test(
Brian Silverman6470f442018-08-05 12:08:16 -0700233 name = "phased_loop_test",
234 srcs = [
235 "phased_loop_test.cc",
236 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800237 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700238 deps = [
239 ":phased_loop",
240 "//aos/testing:googletest",
Brian Silverman8babd8f2020-06-23 16:38:50 -0700241 "//aos/time",
Brian Silverman6470f442018-08-05 12:08:16 -0700242 ],
Brian Silvermandcaa3f72015-11-29 05:32:08 +0000243)
Brian Silverman61175fb2016-03-13 15:35:56 -0400244
245cc_library(
Brian Silverman6470f442018-08-05 12:08:16 -0700246 name = "file",
247 srcs = [
248 "file.cc",
249 ],
250 hdrs = [
251 "file.h",
252 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800253 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700254 deps = [
John Park33858a32018-09-28 23:05:48 -0700255 "//aos/scoped:scoped_fd",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700256 "@com_github_google_glog//:glog",
Austin Schuhcb108412019-10-13 16:09:54 -0700257 "@com_google_absl//absl/strings",
davidjevans8b9b52f2021-09-17 08:57:30 -0700258 "@com_google_absl//absl/types:span",
Brian Silverman6470f442018-08-05 12:08:16 -0700259 ],
Brian Silverman61175fb2016-03-13 15:35:56 -0400260)
261
262cc_test(
Brian Silverman6470f442018-08-05 12:08:16 -0700263 name = "file_test",
264 size = "small",
265 srcs = [
266 "file_test.cc",
267 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800268 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700269 deps = [
270 ":file",
271 "//aos/testing:googletest",
Brian Silverman6470f442018-08-05 12:08:16 -0700272 ],
273)
274
James Kuszmaul731a05d2022-01-07 17:59:26 -0800275cc_library(
276 name = "scoped_pipe",
277 srcs = ["scoped_pipe.cc"],
278 hdrs = ["scoped_pipe.h"],
279 target_compatible_with = ["@platforms//os:linux"],
280 deps = [
281 "@com_github_google_glog//:glog",
282 "@com_google_absl//absl/types:span",
283 ],
284)
285
286cc_test(
287 name = "scoped_pipe_test",
288 srcs = ["scoped_pipe_test.cc"],
289 target_compatible_with = ["@platforms//os:linux"],
290 deps = [
291 ":scoped_pipe",
292 "//aos/testing:googletest",
293 ],
294)
295
Ravago Jonese12b7902022-02-04 22:50:44 -0800296cc_library(
297 name = "crc32",
298 srcs = ["crc32.cc"],
299 hdrs = ["crc32.h"],
300 deps = [
301 "@com_google_absl//absl/types:span",
302 ],
303)
304
Brian Silverman6470f442018-08-05 12:08:16 -0700305py_library(
306 name = "python_init",
307 srcs = ["__init__.py"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800308 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -0700309 visibility = ["//visibility:public"],
John Park33858a32018-09-28 23:05:48 -0700310 deps = ["//aos:python_init"],
Brian Silverman61175fb2016-03-13 15:35:56 -0400311)