blob: 9049e089822c0b5a19f3d44ad96aef3aa9b500af [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",
Brian Silvermanea2c95f2021-02-10 18:10:26 -080010 "//aos:aos_send",
Austin Schuh91d8d062020-11-02 17:11:13 -080011 "//aos/starter",
Brian Silverman6470f442018-08-05 12:08:16 -070012 ],
13 visibility = ["//visibility:public"],
Austin Schuh1eceeb92015-11-08 21:16:06 -080014)
Austin Schuhc80dd152016-02-29 01:47:44 -080015
16filegroup(
Brian Silverman6470f442018-08-05 12:08:16 -070017 name = "prime_start_binaries",
18 srcs = [
James Kuszmaul38735e82019-12-07 16:42:06 -080019 "//aos/events/logging:logger_main",
Brian Silverman6470f442018-08-05 12:08:16 -070020 ],
21 visibility = ["//visibility:public"],
Austin Schuhc80dd152016-02-29 01:47:44 -080022)
Brian Silverman6470f442018-08-05 12:08:16 -070023
Austin Schuhc80dd152016-02-29 01:47:44 -080024filegroup(
Brian Silverman6470f442018-08-05 12:08:16 -070025 name = "prime_binaries_stripped",
26 srcs = [
Austin Schuh944df342019-12-21 17:08:55 -080027 "//aos:aos_dump.stripped",
Tyler Chatowe6f5bef2020-10-31 14:22:04 -070028 "//aos:aos_dump_autocomplete.sh",
Brian Silvermanea2c95f2021-02-10 18:10:26 -080029 "//aos:aos_send.stripped",
Austin Schuh44e0b142021-10-16 15:51:10 -070030 "//aos/starter:starter_stripped",
Brian Silverman6470f442018-08-05 12:08:16 -070031 ],
32 visibility = ["//visibility:public"],
33)
34
35filegroup(
36 name = "prime_start_binaries_stripped",
37 srcs = [
James Kuszmaul38735e82019-12-07 16:42:06 -080038 "//aos/events/logging:logger_main.stripped",
Brian Silverman6470f442018-08-05 12:08:16 -070039 ],
40 visibility = ["//visibility:public"],
Austin Schuhc80dd152016-02-29 01:47:44 -080041)
Sabina Davis2ed5ea22017-09-26 22:27:42 -070042
43cc_library(
John Park33858a32018-09-28 23:05:48 -070044 name = "math",
45 hdrs = [
46 "commonmath.h",
47 ],
John Park33858a32018-09-28 23:05:48 -070048 visibility = ["//visibility:public"],
49)
50
Brian Silverman6470f442018-08-05 12:08:16 -070051py_library(
52 name = "python_init",
53 srcs = ["__init__.py"],
Philipp Schraderdada1072020-11-24 11:34:46 -080054 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman6470f442018-08-05 12:08:16 -070055 visibility = ["//visibility:public"],
Sabina Davis2ed5ea22017-09-26 22:27:42 -070056)
John Park33858a32018-09-28 23:05:48 -070057
58cc_library(
Austin Schuh972e47e2018-12-20 17:20:58 -080059 name = "macros",
60 hdrs = [
John Park33858a32018-09-28 23:05:48 -070061 "macros.h",
John Park33858a32018-09-28 23:05:48 -070062 ],
63 visibility = ["//visibility:public"],
64)
65
66cc_library(
67 name = "gtest_prod",
68 hdrs = [
69 "gtest_prod.h",
70 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080071 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -070072 visibility = ["//visibility:public"],
73)
74
75cc_library(
John Park33858a32018-09-28 23:05:48 -070076 name = "unique_malloc_ptr",
77 hdrs = [
78 "unique_malloc_ptr.h",
79 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080080 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -070081 visibility = ["//visibility:public"],
82)
83
84cc_library(
85 name = "condition",
86 srcs = [
87 "condition.cc",
88 ],
89 hdrs = [
90 "condition.h",
91 ],
Philipp Schraderdada1072020-11-24 11:34:46 -080092 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -070093 visibility = ["//visibility:public"],
Austin Schuh972e47e2018-12-20 17:20:58 -080094 deps = [
95 "//aos/ipc_lib:aos_sync",
Austin Schuh972e47e2018-12-20 17:20:58 -080096 "//aos/mutex",
Alex Perrycb7da4b2019-08-28 19:35:56 -070097 "@com_github_google_glog//:glog",
Austin Schuh972e47e2018-12-20 17:20:58 -080098 ],
John Park33858a32018-09-28 23:05:48 -070099)
100
101cc_test(
102 name = "condition_test",
103 srcs = [
104 "condition_test.cc",
105 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800106 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -0700107 deps = [
108 ":condition",
109 "//aos:die",
John Park398c74a2018-10-20 21:17:39 -0700110 "//aos/ipc_lib:aos_sync",
111 "//aos/ipc_lib:core_lib",
Austin Schuh972e47e2018-12-20 17:20:58 -0800112 "//aos/logging",
113 "//aos/mutex",
John Park33858a32018-09-28 23:05:48 -0700114 "//aos/testing:googletest",
115 "//aos/testing:prevent_exit",
116 "//aos/testing:test_shm",
Austin Schuh972e47e2018-12-20 17:20:58 -0800117 "//aos/time",
John Park33858a32018-09-28 23:05:48 -0700118 ],
119)
120
121cc_library(
122 name = "die",
123 srcs = [
124 "die.cc",
125 ],
126 hdrs = [
127 "die.h",
128 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800129 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800130 visibility = ["//visibility:public"],
John Park33858a32018-09-28 23:05:48 -0700131 deps = [
132 "//aos:macros",
133 "//aos/libc:aos_strerror",
134 ],
John Park33858a32018-09-28 23:05:48 -0700135)
136
John Park33858a32018-09-28 23:05:48 -0700137cc_test(
138 name = "die_test",
139 srcs = [
140 "die_test.cc",
141 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800142 target_compatible_with = ["@platforms//os:linux"],
John Park33858a32018-09-28 23:05:48 -0700143 deps = [
144 ":die",
145 "//aos/testing:googletest",
146 ],
147)
148
John Park398c74a2018-10-20 21:17:39 -0700149cc_binary(
150 name = "dump_rtprio",
151 srcs = [
152 "dump_rtprio.cc",
153 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800154 target_compatible_with = ["@platforms//os:linux"],
John Park398c74a2018-10-20 21:17:39 -0700155 deps = [
Austin Schuh972e47e2018-12-20 17:20:58 -0800156 "//aos/time",
Brian Silverman3eb60d22021-11-04 19:06:47 -0700157 "@com_github_google_glog//:glog",
John Park398c74a2018-10-20 21:17:39 -0700158 ],
159)
160
161cc_library(
John Park398c74a2018-10-20 21:17:39 -0700162 name = "complex_thread_local",
163 srcs = [
164 "complex_thread_local.cc",
165 ],
166 hdrs = [
167 "complex_thread_local.h",
168 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800169 target_compatible_with = ["@platforms//os:linux"],
John Park398c74a2018-10-20 21:17:39 -0700170 visibility = ["//visibility:public"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800171 deps = [
172 "//aos:die",
John Park65170ac2020-01-08 20:15:24 -0800173 "@com_google_absl//absl/base",
Austin Schuh972e47e2018-12-20 17:20:58 -0800174 ],
John Park398c74a2018-10-20 21:17:39 -0700175)
176
177cc_test(
178 name = "complex_thread_local_test",
179 srcs = [
180 "complex_thread_local_test.cc",
181 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800182 target_compatible_with = ["@platforms//os:linux"],
John Park398c74a2018-10-20 21:17:39 -0700183 deps = [
184 ":complex_thread_local",
185 "//aos/logging",
John Park398c74a2018-10-20 21:17:39 -0700186 "//aos/testing:googletest",
187 ],
188)
189
190cc_library(
191 name = "init",
192 srcs = [
193 "init.cc",
194 ],
195 hdrs = [
196 "init.h",
197 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800198 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800199 visibility = ["//visibility:public"],
John Park398c74a2018-10-20 21:17:39 -0700200 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700201 ":realtime",
John Park398c74a2018-10-20 21:17:39 -0700202 "//aos:die",
Austin Schuh972e47e2018-12-20 17:20:58 -0800203 "//aos/logging:implementations",
John Park398c74a2018-10-20 21:17:39 -0700204 ],
John Park398c74a2018-10-20 21:17:39 -0700205)
206
Alex Perrycb7da4b2019-08-28 19:35:56 -0700207cc_library(
208 name = "realtime",
209 srcs = [
210 "realtime.cc",
211 ],
212 hdrs = [
213 "realtime.h",
214 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800215 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700216 visibility = ["//visibility:public"],
217 deps = [
Austin Schuhcc6070c2020-10-10 20:25:56 -0700218 ":thread_local",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700219 "@com_github_google_glog//:glog",
220 ],
221)
222
Austin Schuhcb108412019-10-13 16:09:54 -0700223flatbuffer_cc_library(
Alex Perrycb7da4b2019-08-28 19:35:56 -0700224 name = "configuration_fbs",
Austin Schuhcb108412019-10-13 16:09:54 -0700225 srcs = ["configuration.fbs"],
James Kuszmaulabb77132020-08-01 19:56:16 -0700226 gen_reflections = 1,
Philipp Schraderdada1072020-11-24 11:34:46 -0800227 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700228 visibility = ["//visibility:public"],
Austin Schuhcb108412019-10-13 16:09:54 -0700229)
230
Alex Perryd5e13572020-02-22 15:15:08 -0800231flatbuffer_ts_library(
232 name = "configuration_ts_fbs",
233 srcs = ["configuration.fbs"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800234 target_compatible_with = ["@platforms//os:linux"],
Alex Perryd5e13572020-02-22 15:15:08 -0800235 visibility = ["//visibility:public"],
236)
237
Brian Silverman28760272020-02-02 13:21:51 -0800238flatbuffer_py_library(
James Kuszmaul7daef362019-12-31 18:28:17 -0800239 name = "configuration_fbs_python",
240 srcs = ["configuration.fbs"],
241 namespace = "aos",
242 tables = [
243 "Configuration",
244 "Channel",
James Kuszmaul84ff3e52020-01-03 19:48:53 -0800245 "Connection",
James Kuszmaul7daef362019-12-31 18:28:17 -0800246 "Map",
247 "Node",
248 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800249 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul7daef362019-12-31 18:28:17 -0800250 visibility = ["//visibility:public"],
251)
252
John Park398c74a2018-10-20 21:17:39 -0700253cc_library(
254 name = "configuration",
255 srcs = [
256 "configuration.cc",
257 ],
258 hdrs = [
259 "configuration.h",
260 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800261 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh972e47e2018-12-20 17:20:58 -0800262 visibility = ["//visibility:public"],
John Park398c74a2018-10-20 21:17:39 -0700263 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700264 ":configuration_fbs",
Austin Schuhcb108412019-10-13 16:09:54 -0700265 ":flatbuffer_merge",
266 ":flatbuffers",
267 ":json_to_flatbuffer",
John Park398c74a2018-10-20 21:17:39 -0700268 "//aos:unique_malloc_ptr",
Austin Schuh217a9782019-12-21 23:02:50 -0800269 "//aos/network:team_number",
Austin Schuhcb108412019-10-13 16:09:54 -0700270 "//aos/util:file",
271 "@com_github_google_glog//:glog",
272 "@com_google_absl//absl/container:btree",
273 "@com_google_absl//absl/strings",
John Park398c74a2018-10-20 21:17:39 -0700274 ],
John Park398c74a2018-10-20 21:17:39 -0700275)
276
James Kuszmaulabb77132020-08-01 19:56:16 -0700277flatbuffer_ts_library(
Brian Silvermanc5105ab2021-02-10 17:55:38 -0800278 name = "json_to_flatbuffer_fbs_ts",
James Kuszmaulabb77132020-08-01 19:56:16 -0700279 srcs = ["json_to_flatbuffer.fbs"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800280 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaulabb77132020-08-01 19:56:16 -0700281 visibility = ["//aos:__subpackages__"],
282)
283
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700284flatbuffer_cc_library(
Brian Silvermanc5105ab2021-02-10 17:55:38 -0800285 name = "json_to_flatbuffer_fbs",
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700286 srcs = ["json_to_flatbuffer.fbs"],
Tyler Chatow5e369a42019-11-23 11:57:31 -0800287 gen_reflections = 1,
Philipp Schraderdada1072020-11-24 11:34:46 -0800288 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaulabb77132020-08-01 19:56:16 -0700289 visibility = ["//aos:__subpackages__"],
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700290)
291
292cc_library(
Austin Schuh43c6a352019-09-30 22:22:10 -0700293 name = "flatbuffer_utils",
294 srcs = ["flatbuffer_utils.cc"],
295 hdrs = ["flatbuffer_utils.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800296 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh43c6a352019-09-30 22:22:10 -0700297 deps = [
298 "@com_github_google_flatbuffers//:flatbuffers",
Brian Silvermancf4fb662021-02-10 17:54:53 -0800299 "@com_github_google_glog//:glog",
Austin Schuh43c6a352019-09-30 22:22:10 -0700300 ],
301)
302
303cc_library(
Austin Schuhd7e252d2019-10-06 13:51:02 -0700304 name = "json_tokenizer",
305 srcs = ["json_tokenizer.cc"],
306 hdrs = ["json_tokenizer.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800307 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhd7e252d2019-10-06 13:51:02 -0700308 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700309 "@com_github_google_glog//:glog",
Austin Schuhd7e252d2019-10-06 13:51:02 -0700310 "@com_google_absl//absl/strings",
311 ],
312)
313
314cc_library(
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700315 name = "json_to_flatbuffer",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800316 srcs = [
317 "flatbuffer_introspection.cc",
318 "json_to_flatbuffer.cc",
319 ],
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700320 hdrs = ["json_to_flatbuffer.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800321 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700322 visibility = ["//visibility:public"],
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700323 deps = [
Tyler Chatowfcf16f42020-07-26 12:41:36 -0700324 ":fast_string_builder",
Austin Schuh43c6a352019-09-30 22:22:10 -0700325 ":flatbuffer_utils",
Austin Schuhe93d8642019-10-13 15:27:07 -0700326 ":flatbuffers",
Austin Schuhd7e252d2019-10-06 13:51:02 -0700327 ":json_tokenizer",
Austin Schuhbba10282021-03-20 22:03:28 -0700328 "//aos/util:file",
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700329 "@com_github_google_flatbuffers//:flatbuffers",
Austin Schuhe93d8642019-10-13 15:27:07 -0700330 "@com_github_google_glog//:glog",
Austin Schuhd339a9b2019-10-05 21:33:32 -0700331 "@com_google_absl//absl/strings",
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700332 ],
333)
334
335cc_test(
336 name = "json_to_flatbuffer_test",
337 srcs = [
338 "json_to_flatbuffer_test.cc",
339 ],
Brian Silvermanc5105ab2021-02-10 17:55:38 -0800340 data = [
341 ":json_to_flatbuffer_fbs_reflection_out",
342 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800343 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700344 deps = [
345 ":json_to_flatbuffer",
Brian Silvermanc5105ab2021-02-10 17:55:38 -0800346 ":json_to_flatbuffer_fbs",
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700347 "//aos/testing:googletest",
Austin Schuh373f1762021-06-02 21:07:09 -0700348 "//aos/testing:path",
Austin Schuh3e95e5d2019-09-20 00:08:54 -0700349 ],
350)
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700351
Tyler Chatow5e369a42019-11-23 11:57:31 -0800352cc_test(
353 name = "flatbuffer_introspection_test",
354 srcs = [
355 "flatbuffer_introspection_test.cc",
356 ],
357 data = [
Brian Silvermanc5105ab2021-02-10 17:55:38 -0800358 ":json_to_flatbuffer_fbs_reflection_out",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800359 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800360 target_compatible_with = ["@platforms//os:linux"],
Tyler Chatow5e369a42019-11-23 11:57:31 -0800361 deps = [
362 ":json_to_flatbuffer",
Brian Silvermanc5105ab2021-02-10 17:55:38 -0800363 ":json_to_flatbuffer_fbs",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800364 "//aos/testing:googletest",
Austin Schuh373f1762021-06-02 21:07:09 -0700365 "//aos/testing:path",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800366 "//aos/util:file",
367 "@com_github_google_flatbuffers//:flatbuffers",
368 ],
369)
370
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700371cc_library(
372 name = "flatbuffer_merge",
373 srcs = ["flatbuffer_merge.cc"],
374 hdrs = ["flatbuffer_merge.h"],
375 copts = ["-Wno-cast-align"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800376 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700377 visibility = ["//visibility:public"],
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700378 deps = [
379 ":flatbuffer_utils",
Austin Schuhe93d8642019-10-13 15:27:07 -0700380 ":flatbuffers",
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700381 "@com_github_google_flatbuffers//:flatbuffers",
382 ],
383)
384
385cc_test(
386 name = "flatbuffer_merge_test",
387 srcs = [
388 "flatbuffer_merge_test.cc",
389 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800390 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700391 deps = [
392 ":flatbuffer_merge",
393 ":json_to_flatbuffer",
Brian Silvermanc5105ab2021-02-10 17:55:38 -0800394 ":json_to_flatbuffer_fbs",
Austin Schuh09d7ffa2019-10-03 23:43:34 -0700395 "//aos/testing:googletest",
396 ],
397)
Austin Schuhe93d8642019-10-13 15:27:07 -0700398
399cc_library(
400 name = "flatbuffers",
Austin Schuh40485ed2019-10-26 21:51:44 -0700401 srcs = [
402 "flatbuffers.cc",
403 ],
Austin Schuhe93d8642019-10-13 15:27:07 -0700404 hdrs = [
405 "flatbuffers.h",
406 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800407 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh40485ed2019-10-26 21:51:44 -0700408 visibility = ["//visibility:public"],
Austin Schuhe93d8642019-10-13 15:27:07 -0700409 deps = [
James Kuszmaulad8a8082020-02-14 21:21:58 -0800410 "//aos:macros",
Brian Silverman354697a2020-09-22 21:06:32 -0700411 "//aos/containers:resizeable_buffer",
Austin Schuhe93d8642019-10-13 15:27:07 -0700412 "@com_github_google_flatbuffers//:flatbuffers",
Austin Schuh40485ed2019-10-26 21:51:44 -0700413 "@com_github_google_glog//:glog",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700414 "@com_google_absl//absl/strings",
Austin Schuh6f3babe2020-01-26 20:34:50 -0800415 "@com_google_absl//absl/types:span",
Austin Schuhe93d8642019-10-13 15:27:07 -0700416 ],
417)
Austin Schuhcb108412019-10-13 16:09:54 -0700418
419cc_test(
420 name = "configuration_test",
421 srcs = [
422 "configuration_test.cc",
423 ],
424 data = [
Austin Schuh14d7d3d2020-09-10 18:14:36 -0700425 "//aos/events:pingpong_config",
Austin Schuh6b9c4152019-11-29 12:45:24 -0800426 "//aos/events:pong.bfbs",
James Kuszmaulc0c08da2020-05-10 18:56:07 -0700427 "//aos/testdata:test_configs",
Austin Schuhcb108412019-10-13 16:09:54 -0700428 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800429 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhcb108412019-10-13 16:09:54 -0700430 deps = [
431 ":configuration",
Austin Schuh1ef01ef2021-02-07 20:40:36 -0800432 "//aos/testing:flatbuffer_eq",
Austin Schuhcb108412019-10-13 16:09:54 -0700433 "//aos/testing:googletest",
Austin Schuh373f1762021-06-02 21:07:09 -0700434 "//aos/testing:path",
Austin Schuhcb108412019-10-13 16:09:54 -0700435 "//aos/testing:test_logging",
436 ],
437)
Alex Perrycb7da4b2019-08-28 19:35:56 -0700438
439cc_binary(
440 name = "config_flattener",
441 srcs = [
442 "config_flattener.cc",
443 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800444 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700445 visibility = ["//visibility:public"],
446 deps = [
447 ":configuration",
448 ":init",
449 "//aos/util:file",
450 "@com_github_google_glog//:glog",
451 ],
452)
Tyler Chatow5e369a42019-11-23 11:57:31 -0800453
Brian Silvermanea2c95f2021-02-10 18:10:26 -0800454cc_library(
455 name = "aos_cli_utils",
456 srcs = [
457 "aos_cli_utils.cc",
458 ],
459 hdrs = [
460 "aos_cli_utils.h",
461 ],
462 target_compatible_with = ["@platforms//os:linux"],
463 visibility = ["//visibility:public"],
464 deps = [
465 ":configuration",
466 "//aos:init",
467 "//aos/events:shm_event_loop",
468 "@com_github_google_glog//:glog",
469 ],
470)
471
Tyler Chatow5e369a42019-11-23 11:57:31 -0800472cc_binary(
Austin Schuh944df342019-12-21 17:08:55 -0800473 name = "aos_dump",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800474 srcs = [
Austin Schuh944df342019-12-21 17:08:55 -0800475 "aos_dump.cc",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800476 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800477 target_compatible_with = ["@platforms//os:linux"],
Tyler Chatow5e369a42019-11-23 11:57:31 -0800478 visibility = ["//visibility:public"],
479 deps = [
Brian Silvermanea2c95f2021-02-10 18:10:26 -0800480 ":aos_cli_utils",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800481 ":configuration",
482 ":json_to_flatbuffer",
483 "//aos:init",
Brian Silvermanea2c95f2021-02-10 18:10:26 -0800484 "@com_github_google_glog//:glog",
485 ],
486)
487
488cc_binary(
489 name = "aos_send",
490 srcs = [
491 "aos_send.cc",
492 ],
493 target_compatible_with = ["@platforms//os:linux"],
494 visibility = ["//visibility:public"],
495 deps = [
496 ":aos_cli_utils",
497 ":configuration",
498 ":init",
499 ":json_to_flatbuffer",
500 "@com_github_gflags_gflags//:gflags",
Tyler Chatow5e369a42019-11-23 11:57:31 -0800501 "@com_github_google_glog//:glog",
502 ],
503)
Brian Silverman79ec7fc2020-06-08 20:11:22 -0500504
Jim Ostrowski17ce54d2020-10-24 17:24:01 -0700505cc_binary(
506 name = "aos_graph_nodes",
507 srcs = [
508 "aos_graph_nodes.cc",
509 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800510 target_compatible_with = ["@platforms//os:linux"],
Jim Ostrowski17ce54d2020-10-24 17:24:01 -0700511 visibility = ["//visibility:public"],
512 deps = [
513 ":configuration",
514 ":json_to_flatbuffer",
515 "//aos:init",
516 "//aos/events:shm_event_loop",
517 "@com_github_google_glog//:glog",
518 ],
519)
520
Brian Silverman79ec7fc2020-06-08 20:11:22 -0500521cc_library(
522 name = "ftrace",
523 srcs = [
524 "ftrace.cc",
525 ],
526 hdrs = [
527 "ftrace.h",
528 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800529 target_compatible_with = ["@platforms//os:linux"],
Brian Silverman79ec7fc2020-06-08 20:11:22 -0500530 visibility = ["//visibility:public"],
531 deps = [
532 "@com_github_google_glog//:glog",
533 ],
534)
Tyler Chatowfcf16f42020-07-26 12:41:36 -0700535
536cc_library(
537 name = "fast_string_builder",
538 srcs = [
539 "fast_string_builder.cc",
540 ],
541 hdrs = [
542 "fast_string_builder.h",
543 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800544 target_compatible_with = ["@platforms//os:linux"],
Tyler Chatowfcf16f42020-07-26 12:41:36 -0700545 deps = [
546 "@com_github_google_glog//:glog",
547 "@com_google_absl//absl/strings",
548 "@com_google_absl//absl/strings:str_format",
549 ],
550)
Brian Silvermanb47f5552020-10-01 15:08:14 -0700551
552cc_library(
553 name = "thread_local",
554 hdrs = [
555 "thread_local.h",
556 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800557 target_compatible_with = ["@platforms//os:linux"],
Brian Silvermanb47f5552020-10-01 15:08:14 -0700558 visibility = ["//visibility:public"],
559)
Austin Schuhcc6070c2020-10-10 20:25:56 -0700560
561cc_test(
562 name = "realtime_test",
563 srcs = [
564 "realtime_test.cc",
565 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800566 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhcc6070c2020-10-10 20:25:56 -0700567 visibility = ["//visibility:public"],
568 deps = [
569 ":realtime",
570 "//aos/testing:googletest",
571 ],
572)
Austin Schuh977a5ed2020-12-02 23:20:04 -0800573
574cc_test(
575 name = "flatbuffers_test",
576 srcs = [
577 "flatbuffers_test.cc",
578 ],
579 deps = [
580 ":flatbuffers",
581 ":json_to_flatbuffer",
Brian Silvermanc5105ab2021-02-10 17:55:38 -0800582 ":json_to_flatbuffer_fbs",
Austin Schuh977a5ed2020-12-02 23:20:04 -0800583 "//aos/testing:googletest",
584 ],
585)
Austin Schuh0de30f32020-12-06 12:44:28 -0800586
587py_binary(
588 name = "flatbuffers_static",
589 srcs = ["flatbuffers_static.py"],
590 visibility = ["//visibility:public"],
591)
Austin Schuh4385b142021-03-14 21:31:13 -0700592
593cc_library(
594 name = "uuid",
595 srcs = ["uuid.cc"],
596 hdrs = ["uuid.h"],
597 target_compatible_with = ["@platforms//os:linux"],
598 visibility = ["//visibility:public"],
599 deps = [
Austin Schuh8902fa52021-03-14 22:39:24 -0700600 "@com_github_gflags_gflags//:gflags",
Austin Schuh4385b142021-03-14 21:31:13 -0700601 "@com_github_google_flatbuffers//:flatbuffers",
602 "@com_github_google_glog//:glog",
603 "@com_google_absl//absl/types:span",
604 ],
605)
606
607cc_test(
608 name = "uuid_test",
609 srcs = ["uuid_test.cc"],
610 target_compatible_with = ["@platforms//os:linux"],
611 deps = [
612 ":uuid",
613 "//aos/testing:googletest",
614 ],
615)
Austin Schuh30f74292021-08-13 17:25:26 -0700616
617cc_binary(
618 name = "aos_graph_channels",
619 srcs = [
620 "aos_graph_channels.cc",
621 ],
622 target_compatible_with = ["@platforms//os:linux"],
623 deps = [
624 "//aos:configuration",
625 "//aos:init",
626 "//aos:json_to_flatbuffer",
627 "//aos/events:simulated_event_loop",
628 "//aos/events/logging:log_reader",
629 "//aos/time",
630 "@com_github_gflags_gflags//:gflags",
631 "@com_github_google_glog//:glog",
632 ],
633)