blob: 617b91cb95757843ee0ad3b7ec822262734dd1b2 [file] [log] [blame]
Alex Perryd5e13572020-02-22 15:15:08 -08001load("@com_github_google_flatbuffers//:build_defs.bzl", "flatbuffer_cc_library", "flatbuffer_py_library", "flatbuffer_ts_library")
Austin Schuh972e47e2018-12-20 17:20:58 -08002
Austin Schuh00e302a2020-12-21 11:53:30 -08003exports_files(["aos_dump_autocomplete.sh"])
4
Brian Silverman258b9172015-09-19 14:32:57 -04005filegroup(
Brian Silverman6470f442018-08-05 12:08:16 -07006 name = "prime_binaries",
7 srcs = [
Austin Schuh944df342019-12-21 17:08:55 -08008 "//aos:aos_dump",
Tyler Chatowe6f5bef2020-10-31 14:22:04 -07009 "//aos:aos_dump_autocomplete.sh",
Austin Schuh91d8d062020-11-02 17:11:13 -080010 "//aos/starter",
Brian Silverman6470f442018-08-05 12:08:16 -070011 ],
12 visibility = ["//visibility:public"],
Austin Schuh1eceeb92015-11-08 21:16:06 -080013)
Austin Schuhc80dd152016-02-29 01:47:44 -080014
15filegroup(
Brian Silverman6470f442018-08-05 12:08:16 -070016 name = "prime_start_binaries",
17 srcs = [
James Kuszmaul38735e82019-12-07 16:42:06 -080018 "//aos/events/logging:logger_main",
Brian Silverman6470f442018-08-05 12:08:16 -070019 ],
20 visibility = ["//visibility:public"],
Austin Schuhc80dd152016-02-29 01:47:44 -080021)
Brian Silverman6470f442018-08-05 12:08:16 -070022
Austin Schuhc80dd152016-02-29 01:47:44 -080023filegroup(
Brian Silverman6470f442018-08-05 12:08:16 -070024 name = "prime_binaries_stripped",
25 srcs = [
26 # starter is hard coded to look for a non-stripped core...
Austin Schuh944df342019-12-21 17:08:55 -080027 "//aos:aos_dump.stripped",
John Park398c74a2018-10-20 21:17:39 -070028 "//aos/starter",
Tyler Chatowe6f5bef2020-10-31 14:22:04 -070029 "//aos:aos_dump_autocomplete.sh",
Brian Silverman6470f442018-08-05 12:08:16 -070030 ],
31 visibility = ["//visibility:public"],
32)
33
34filegroup(
35 name = "prime_start_binaries_stripped",
36 srcs = [
James Kuszmaul38735e82019-12-07 16:42:06 -080037 "//aos/events/logging:logger_main.stripped",
Brian Silverman6470f442018-08-05 12:08:16 -070038 ],
39 visibility = ["//visibility:public"],
Austin Schuhc80dd152016-02-29 01:47:44 -080040)
Sabina Davis2ed5ea22017-09-26 22:27:42 -070041
42cc_library(
John Park33858a32018-09-28 23:05:48 -070043 name = "math",
44 hdrs = [
45 "commonmath.h",
46 ],
John Park33858a32018-09-28 23:05:48 -070047 visibility = ["//visibility:public"],
48)
49
50cc_library(
John Park33858a32018-09-28 23:05:48 -070051 name = "byteorder",
52 hdrs = [
53 "byteorder.h",
54 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080055 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -070056 visibility = ["//visibility:public"],
57)
58
Brian Silverman6470f442018-08-05 12:08:16 -070059py_library(
60 name = "python_init",
61 srcs = ["__init__.py"],
Philipp Schraderdada1072020-11-24 11:34:46 -080062 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -070063 visibility = ["//visibility:public"],
Sabina Davis2ed5ea22017-09-26 22:27:42 -070064)
John Park33858a32018-09-28 23:05:48 -070065
66cc_library(
Austin Schuh972e47e2018-12-20 17:20:58 -080067 name = "macros",
68 hdrs = [
John Park33858a32018-09-28 23:05:48 -070069 "macros.h",
John Park33858a32018-09-28 23:05:48 -070070 ],
71 visibility = ["//visibility:public"],
72)
73
74cc_library(
75 name = "gtest_prod",
76 hdrs = [
77 "gtest_prod.h",
78 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080079 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -070080 visibility = ["//visibility:public"],
81)
82
83cc_library(
84 name = "network_port",
85 hdrs = [
86 "network_port.h",
87 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080088 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -070089 visibility = ["//visibility:public"],
90)
91
John Park33858a32018-09-28 23:05:48 -070092cc_library(
93 name = "unique_malloc_ptr",
94 hdrs = [
95 "unique_malloc_ptr.h",
96 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080097 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -070098 visibility = ["//visibility:public"],
99)
100
101cc_library(
102 name = "condition",
103 srcs = [
104 "condition.cc",
105 ],
106 hdrs = [
107 "condition.h",
108 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800109 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -0700110 visibility = ["//visibility:public"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800111 deps = [
112 "//aos/ipc_lib:aos_sync",
Austin Schuh972e47e2018-12-20 17:20:58 -0800113 "//aos/mutex",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700114 "@com_github_google_glog//:glog",
Austin Schuh972e47e2018-12-20 17:20:58 -0800115 ],
John Park33858a32018-09-28 23:05:48 -0700116)
117
118cc_test(
119 name = "condition_test",
120 srcs = [
121 "condition_test.cc",
122 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800123 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -0700124 deps = [
125 ":condition",
126 "//aos:die",
John Park398c74a2018-10-20 21:17:39 -0700127 "//aos/ipc_lib:aos_sync",
128 "//aos/ipc_lib:core_lib",
Austin Schuh972e47e2018-12-20 17:20:58 -0800129 "//aos/logging",
130 "//aos/mutex",
John Park33858a32018-09-28 23:05:48 -0700131 "//aos/testing:googletest",
132 "//aos/testing:prevent_exit",
133 "//aos/testing:test_shm",
Austin Schuh972e47e2018-12-20 17:20:58 -0800134 "//aos/time",
John Park33858a32018-09-28 23:05:48 -0700135 ],
136)
137
138cc_library(
139 name = "die",
140 srcs = [
141 "die.cc",
142 ],
143 hdrs = [
144 "die.h",
145 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800146 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800147 visibility = ["//visibility:public"],
John Park33858a32018-09-28 23:05:48 -0700148 deps = [
149 "//aos:macros",
150 "//aos/libc:aos_strerror",
151 ],
John Park33858a32018-09-28 23:05:48 -0700152)
153
John Park33858a32018-09-28 23:05:48 -0700154cc_test(
155 name = "die_test",
156 srcs = [
157 "die_test.cc",
158 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800159 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -0700160 deps = [
161 ":die",
162 "//aos/testing:googletest",
163 ],
164)
165
166cc_library(
167 name = "event",
168 srcs = [
169 "event.cc",
170 ],
171 hdrs = [
172 "event.h",
173 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800174 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -0700175 visibility = ["//visibility:public"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800176 deps = [
177 "//aos/ipc_lib:aos_sync",
Austin Schuh972e47e2018-12-20 17:20:58 -0800178 "//aos/time",
Austin Schuh91d8d062020-11-02 17:11:13 -0800179 "//aos/type_traits",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700180 "@com_github_google_glog//:glog",
Austin Schuh972e47e2018-12-20 17:20:58 -0800181 ],
John Park33858a32018-09-28 23:05:48 -0700182)
183
184cc_test(
185 name = "event_test",
186 srcs = [
187 "event_test.cc",
Austin Schuh972e47e2018-12-20 17:20:58 -0800188 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800189 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -0700190 deps = [
191 ":event",
John Park33858a32018-09-28 23:05:48 -0700192 "//aos/testing:googletest",
193 "//aos/testing:test_logging",
Austin Schuh972e47e2018-12-20 17:20:58 -0800194 "//aos/time",
John Park33858a32018-09-28 23:05:48 -0700195 ],
196)
John Park398c74a2018-10-20 21:17:39 -0700197
198cc_binary(
199 name = "dump_rtprio",
200 srcs = [
201 "dump_rtprio.cc",
202 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800203 target_compatible_with = ["@platforms//os:linux"],
John Park398c74a2018-10-20 21:17:39 -0700204 deps = [
John Park398c74a2018-10-20 21:17:39 -0700205 "//aos/logging",
206 "//aos/logging:implementations",
Austin Schuh972e47e2018-12-20 17:20:58 -0800207 "//aos/time",
John Park398c74a2018-10-20 21:17:39 -0700208 ],
209)
210
211cc_library(
John Park398c74a2018-10-20 21:17:39 -0700212 name = "complex_thread_local",
213 srcs = [
214 "complex_thread_local.cc",
215 ],
216 hdrs = [
217 "complex_thread_local.h",
218 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800219 target_compatible_with = ["@platforms//os:linux"],
John Park398c74a2018-10-20 21:17:39 -0700220 visibility = ["//visibility:public"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800221 deps = [
222 "//aos:die",
John Park65170ac2020-01-08 20:15:24 -0800223 "@com_google_absl//absl/base",
Austin Schuh972e47e2018-12-20 17:20:58 -0800224 ],
John Park398c74a2018-10-20 21:17:39 -0700225)
226
227cc_test(
228 name = "complex_thread_local_test",
229 srcs = [
230 "complex_thread_local_test.cc",
231 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800232 target_compatible_with = ["@platforms//os:linux"],
John Park398c74a2018-10-20 21:17:39 -0700233 deps = [
234 ":complex_thread_local",
235 "//aos/logging",
John Park398c74a2018-10-20 21:17:39 -0700236 "//aos/testing:googletest",
237 ],
238)
239
240cc_library(
241 name = "init",
242 srcs = [
243 "init.cc",
244 ],
245 hdrs = [
246 "init.h",
247 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800248 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800249 visibility = ["//visibility:public"],
John Park398c74a2018-10-20 21:17:39 -0700250 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700251 ":realtime",
John Park398c74a2018-10-20 21:17:39 -0700252 "//aos:die",
Austin Schuh972e47e2018-12-20 17:20:58 -0800253 "//aos/logging:implementations",
John Park398c74a2018-10-20 21:17:39 -0700254 ],
John Park398c74a2018-10-20 21:17:39 -0700255)
256
Alex Perrycb7da4b2019-08-28 19:35:56 -0700257cc_library(
258 name = "realtime",
259 srcs = [
260 "realtime.cc",
261 ],
262 hdrs = [
263 "realtime.h",
264 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800265 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700266 visibility = ["//visibility:public"],
267 deps = [
Austin Schuhcc6070c2020-10-10 20:25:56 -0700268 ":thread_local",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700269 "@com_github_google_glog//:glog",
270 ],
271)
272
Austin Schuhcb108412019-10-13 16:09:54 -0700273flatbuffer_cc_library(
Alex Perrycb7da4b2019-08-28 19:35:56 -0700274 name = "configuration_fbs",
Austin Schuhcb108412019-10-13 16:09:54 -0700275 srcs = ["configuration.fbs"],
James Kuszmaulabb77132020-08-01 19:56:16 -0700276 gen_reflections = 1,
Philipp Schraderdada1072020-11-24 11:34:46 -0800277 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700278 visibility = ["//visibility:public"],
Austin Schuhcb108412019-10-13 16:09:54 -0700279)
280
Alex Perryd5e13572020-02-22 15:15:08 -0800281flatbuffer_ts_library(
282 name = "configuration_ts_fbs",
283 srcs = ["configuration.fbs"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800284 target_compatible_with = ["@platforms//os:linux"],
Alex Perryd5e13572020-02-22 15:15:08 -0800285 visibility = ["//visibility:public"],
286)
287
Brian Silverman28760272020-02-02 13:21:51 -0800288flatbuffer_py_library(
James Kuszmaul7daef362019-12-31 18:28:17 -0800289 name = "configuration_fbs_python",
290 srcs = ["configuration.fbs"],
291 namespace = "aos",
292 tables = [
293 "Configuration",
294 "Channel",
James Kuszmaul84ff3e52020-01-03 19:48:53 -0800295 "Connection",
James Kuszmaul7daef362019-12-31 18:28:17 -0800296 "Map",
297 "Node",
298 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800299 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul7daef362019-12-31 18:28:17 -0800300 visibility = ["//visibility:public"],
301)
302
John Park398c74a2018-10-20 21:17:39 -0700303cc_library(
304 name = "configuration",
305 srcs = [
306 "configuration.cc",
307 ],
308 hdrs = [
309 "configuration.h",
310 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800311 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800312 visibility = ["//visibility:public"],
John Park398c74a2018-10-20 21:17:39 -0700313 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700314 ":configuration_fbs",
Austin Schuhcb108412019-10-13 16:09:54 -0700315 ":flatbuffer_merge",
316 ":flatbuffers",
317 ":json_to_flatbuffer",
John Park398c74a2018-10-20 21:17:39 -0700318 "//aos:unique_malloc_ptr",
Austin Schuh217a9782019-12-21 23:02:50 -0800319 "//aos/network:team_number",
Austin Schuhcb108412019-10-13 16:09:54 -0700320 "//aos/util:file",
321 "@com_github_google_glog//:glog",
322 "@com_google_absl//absl/container:btree",
323 "@com_google_absl//absl/strings",
John Park398c74a2018-10-20 21:17:39 -0700324 ],
John Park398c74a2018-10-20 21:17:39 -0700325)
326
Brian Silvermanf819b442019-01-20 16:51:04 -0800327cc_library(
328 name = "make_unique",
329 hdrs = [
330 "make_unique.h",
331 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800332 target_compatible_with = ["@platforms//os:linux"],
Brian Silvermanf819b442019-01-20 16:51:04 -0800333 visibility = ["//visibility:public"],
334)
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700335
James Kuszmaulabb77132020-08-01 19:56:16 -0700336flatbuffer_ts_library(
337 name = "json_to_flatbuffer_flatbuffer_ts",
338 srcs = ["json_to_flatbuffer.fbs"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800339 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaulabb77132020-08-01 19:56:16 -0700340 visibility = ["//aos:__subpackages__"],
341)
342
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700343flatbuffer_cc_library(
344 name = "json_to_flatbuffer_flatbuffer",
345 srcs = ["json_to_flatbuffer.fbs"],
Tyler Chatow5e369a42019-11-23 11:57:31 -0800346 gen_reflections = 1,
Philipp Schraderdada1072020-11-24 11:34:46 -0800347 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaulabb77132020-08-01 19:56:16 -0700348 visibility = ["//aos:__subpackages__"],
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700349)
350
351cc_library(
Austin Schuh43c6a352019-09-30 22:22:10 -0700352 name = "flatbuffer_utils",
353 srcs = ["flatbuffer_utils.cc"],
354 hdrs = ["flatbuffer_utils.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800355 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh43c6a352019-09-30 22:22:10 -0700356 deps = [
357 "@com_github_google_flatbuffers//:flatbuffers",
358 ],
359)
360
361cc_library(
Austin Schuhd7e252d2019-10-06 13:51:02 -0700362 name = "json_tokenizer",
363 srcs = ["json_tokenizer.cc"],
364 hdrs = ["json_tokenizer.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800365 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhd7e252d2019-10-06 13:51:02 -0700366 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700367 "@com_github_google_glog//:glog",
Austin Schuhd7e252d2019-10-06 13:51:02 -0700368 "@com_google_absl//absl/strings",
369 ],
370)
371
372cc_library(
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700373 name = "json_to_flatbuffer",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800374 srcs = [
375 "flatbuffer_introspection.cc",
376 "json_to_flatbuffer.cc",
377 ],
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700378 hdrs = ["json_to_flatbuffer.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800379 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700380 visibility = ["//visibility:public"],
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700381 deps = [
Tyler Chatowfcf16f42020-07-26 12:41:36 -0700382 ":fast_string_builder",
Austin Schuh43c6a352019-09-30 22:22:10 -0700383 ":flatbuffer_utils",
Austin Schuhe93d8642019-10-13 15:27:07 -0700384 ":flatbuffers",
Austin Schuhd7e252d2019-10-06 13:51:02 -0700385 ":json_tokenizer",
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700386 "@com_github_google_flatbuffers//:flatbuffers",
Austin Schuhe93d8642019-10-13 15:27:07 -0700387 "@com_github_google_glog//:glog",
Austin Schuhd339a9b2019-10-05 21:33:32 -0700388 "@com_google_absl//absl/strings",
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700389 ],
390)
391
392cc_test(
393 name = "json_to_flatbuffer_test",
394 srcs = [
395 "json_to_flatbuffer_test.cc",
396 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800397 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700398 deps = [
399 ":json_to_flatbuffer",
400 ":json_to_flatbuffer_flatbuffer",
401 "//aos/testing:googletest",
402 ],
403)
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700404
Tyler Chatow5e369a42019-11-23 11:57:31 -0800405cc_test(
406 name = "flatbuffer_introspection_test",
407 srcs = [
408 "flatbuffer_introspection_test.cc",
409 ],
410 data = [
411 ":json_to_flatbuffer_flatbuffer_reflection_out",
412 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800413 target_compatible_with = ["@platforms//os:linux"],
Tyler Chatow5e369a42019-11-23 11:57:31 -0800414 deps = [
415 ":json_to_flatbuffer",
416 ":json_to_flatbuffer_flatbuffer",
417 "//aos/testing:googletest",
418 "//aos/util:file",
419 "@com_github_google_flatbuffers//:flatbuffers",
420 ],
421)
422
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700423cc_library(
424 name = "flatbuffer_merge",
425 srcs = ["flatbuffer_merge.cc"],
426 hdrs = ["flatbuffer_merge.h"],
427 copts = ["-Wno-cast-align"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800428 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700429 visibility = ["//visibility:public"],
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700430 deps = [
431 ":flatbuffer_utils",
Austin Schuhe93d8642019-10-13 15:27:07 -0700432 ":flatbuffers",
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700433 "@com_github_google_flatbuffers//:flatbuffers",
434 ],
435)
436
437cc_test(
438 name = "flatbuffer_merge_test",
439 srcs = [
440 "flatbuffer_merge_test.cc",
441 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800442 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700443 deps = [
444 ":flatbuffer_merge",
445 ":json_to_flatbuffer",
446 ":json_to_flatbuffer_flatbuffer",
447 "//aos/testing:googletest",
448 ],
449)
Austin Schuhe93d8642019-10-13 15:27:07 -0700450
451cc_library(
452 name = "flatbuffers",
Austin Schuh40485ed2019-10-26 21:51:44 -0700453 srcs = [
454 "flatbuffers.cc",
455 ],
Austin Schuhe93d8642019-10-13 15:27:07 -0700456 hdrs = [
457 "flatbuffers.h",
458 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800459 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh40485ed2019-10-26 21:51:44 -0700460 visibility = ["//visibility:public"],
Austin Schuhe93d8642019-10-13 15:27:07 -0700461 deps = [
James Kuszmaulad8a8082020-02-14 21:21:58 -0800462 "//aos:macros",
Brian Silverman354697a2020-09-22 21:06:32 -0700463 "//aos/containers:resizeable_buffer",
Austin Schuhe93d8642019-10-13 15:27:07 -0700464 "@com_github_google_flatbuffers//:flatbuffers",
Austin Schuh40485ed2019-10-26 21:51:44 -0700465 "@com_github_google_glog//:glog",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700466 "@com_google_absl//absl/strings",
Austin Schuh6f3babe2020-01-26 20:34:50 -0800467 "@com_google_absl//absl/types:span",
Austin Schuhe93d8642019-10-13 15:27:07 -0700468 ],
469)
Austin Schuhcb108412019-10-13 16:09:54 -0700470
471cc_test(
472 name = "configuration_test",
473 srcs = [
474 "configuration_test.cc",
475 ],
476 data = [
Austin Schuh14d7d3d2020-09-10 18:14:36 -0700477 "//aos/events:pingpong_config",
Austin Schuh6b9c4152019-11-29 12:45:24 -0800478 "//aos/events:pong.bfbs",
James Kuszmaulc0c08da2020-05-10 18:56:07 -0700479 "//aos/testdata:test_configs",
Austin Schuhcb108412019-10-13 16:09:54 -0700480 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800481 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhcb108412019-10-13 16:09:54 -0700482 deps = [
483 ":configuration",
484 "//aos/testing:googletest",
485 "//aos/testing:test_logging",
486 ],
487)
Alex Perrycb7da4b2019-08-28 19:35:56 -0700488
489cc_binary(
490 name = "config_flattener",
491 srcs = [
492 "config_flattener.cc",
493 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800494 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700495 visibility = ["//visibility:public"],
496 deps = [
497 ":configuration",
498 ":init",
499 "//aos/util:file",
500 "@com_github_google_glog//:glog",
501 ],
502)
Tyler Chatow5e369a42019-11-23 11:57:31 -0800503
504cc_binary(
Austin Schuh944df342019-12-21 17:08:55 -0800505 name = "aos_dump",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800506 srcs = [
Austin Schuh944df342019-12-21 17:08:55 -0800507 "aos_dump.cc",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800508 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800509 target_compatible_with = ["@platforms//os:linux"],
Tyler Chatow5e369a42019-11-23 11:57:31 -0800510 visibility = ["//visibility:public"],
511 deps = [
512 ":configuration",
513 ":json_to_flatbuffer",
514 "//aos:init",
515 "//aos/events:shm_event_loop",
516 "@com_github_google_glog//:glog",
517 ],
518)
Brian Silverman79ec7fc2020-06-08 20:11:22 -0500519
Jim Ostrowski17ce54d2020-10-24 17:24:01 -0700520cc_binary(
521 name = "aos_graph_nodes",
522 srcs = [
523 "aos_graph_nodes.cc",
524 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800525 target_compatible_with = ["@platforms//os:linux"],
Jim Ostrowski17ce54d2020-10-24 17:24:01 -0700526 visibility = ["//visibility:public"],
527 deps = [
528 ":configuration",
529 ":json_to_flatbuffer",
530 "//aos:init",
531 "//aos/events:shm_event_loop",
532 "@com_github_google_glog//:glog",
533 ],
534)
535
Brian Silverman79ec7fc2020-06-08 20:11:22 -0500536cc_library(
537 name = "ftrace",
538 srcs = [
539 "ftrace.cc",
540 ],
541 hdrs = [
542 "ftrace.h",
543 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800544 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman79ec7fc2020-06-08 20:11:22 -0500545 visibility = ["//visibility:public"],
546 deps = [
547 "@com_github_google_glog//:glog",
548 ],
549)
Tyler Chatowfcf16f42020-07-26 12:41:36 -0700550
551cc_library(
552 name = "fast_string_builder",
553 srcs = [
554 "fast_string_builder.cc",
555 ],
556 hdrs = [
557 "fast_string_builder.h",
558 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800559 target_compatible_with = ["@platforms//os:linux"],
Tyler Chatowfcf16f42020-07-26 12:41:36 -0700560 deps = [
561 "@com_github_google_glog//:glog",
562 "@com_google_absl//absl/strings",
563 "@com_google_absl//absl/strings:str_format",
564 ],
565)
Brian Silvermanb47f5552020-10-01 15:08:14 -0700566
567cc_library(
568 name = "thread_local",
569 hdrs = [
570 "thread_local.h",
571 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800572 target_compatible_with = ["@platforms//os:linux"],
Brian Silvermanb47f5552020-10-01 15:08:14 -0700573 visibility = ["//visibility:public"],
574)
Austin Schuhcc6070c2020-10-10 20:25:56 -0700575
576cc_test(
577 name = "realtime_test",
578 srcs = [
579 "realtime_test.cc",
580 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800581 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhcc6070c2020-10-10 20:25:56 -0700582 visibility = ["//visibility:public"],
583 deps = [
584 ":realtime",
585 "//aos/testing:googletest",
586 ],
587)
Austin Schuh977a5ed2020-12-02 23:20:04 -0800588
589cc_test(
590 name = "flatbuffers_test",
591 srcs = [
592 "flatbuffers_test.cc",
593 ],
594 deps = [
595 ":flatbuffers",
596 ":json_to_flatbuffer",
597 ":json_to_flatbuffer_flatbuffer",
598 "//aos/testing:googletest",
599 ],
600)
Austin Schuh0de30f32020-12-06 12:44:28 -0800601
602py_binary(
603 name = "flatbuffers_static",
604 srcs = ["flatbuffers_static.py"],
605 visibility = ["//visibility:public"],
606)