blob: 4b3376ba82d7195e66dd801b18a26290cfeca175 [file] [log] [blame]
brians343bc112013-02-10 01:53:46 +00001{
2 'targets': [
3 {
Brian Silverman8a8ee682014-02-12 14:06:06 -08004 'target_name': 'test_queue',
brians343bc112013-02-10 01:53:46 +00005 'type': 'static_library',
6 'sources': [
7 '<(AOS)/common/test_queue.q',
8 ],
9 'variables': {
10 'header_path': 'aos/common',
11 },
12 'dependencies': [
13 '<(AOS)/common/common.gyp:queues',
14 ],
15 'includes': ['../build/queues.gypi'],
16 },
17 {
18 'target_name': 'queue_testutils',
19 'type': 'static_library',
20 'sources': [
21 'queue_testutils.cc',
22 ],
23 'dependencies': [
Brian Silvermanb3616972013-03-05 19:58:10 -080024 '<(AOS)/build/aos.gyp:logging',
25 'once',
26 '<(EXTERNALS):gtest',
Brian Silverman14fd0fb2014-01-14 21:42:01 -080027 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:shared_mem',
brians343bc112013-02-10 01:53:46 +000028 ],
Brian Silvermaneeb62ca2013-09-11 15:08:03 -070029 'export_dependent_settings': [
Brian Silverman14fd0fb2014-01-14 21:42:01 -080030 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:shared_mem',
Brian Silvermaneeb62ca2013-09-11 15:08:03 -070031 ],
brians343bc112013-02-10 01:53:46 +000032 },
33 {
34 'target_name': 'time',
35 'type': 'static_library',
36 'sources': [
37 'time.cc'
38 ],
39 'dependencies': [
Brian Silvermanb0893882014-02-10 14:48:30 -080040 '<(AOS)/build/aos.gyp:logging_interface',
Brian Silverman598800f2013-05-09 17:08:42 -070041 'mutex',
brians343bc112013-02-10 01:53:46 +000042 ],
43 },
44 {
Brian Silverman96395be2014-02-11 18:35:57 -080045 'target_name': 'queue_types',
46 'type': 'static_library',
Brian Silverman1885bd02014-02-13 12:28:12 -080047 'variables': {
48 'print_field_cc': '<(SHARED_INTERMEDIATE_DIR)/print_field.cc',
Brian Silvermanfd5e2a32014-02-22 20:02:39 -080049 'queue_primitives_h': '<(SHARED_INTERMEDIATE_DIR)/aos_queue_primitives/aos/queue_primitives.h',
Brian Silverman1885bd02014-02-13 12:28:12 -080050 },
Brian Silverman96395be2014-02-11 18:35:57 -080051 'sources': [
52 'queue_types.cc',
Brian Silverman1885bd02014-02-13 12:28:12 -080053 '<(print_field_cc)',
Brian Silverman96395be2014-02-11 18:35:57 -080054 ],
Brian Silverman4aeac5f2014-02-11 22:17:07 -080055 'dependencies': [
56 '<(AOS)/build/aos.gyp:logging_interface',
57 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:shared_mem',
58 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:core_lib',
Brian Silverman8a8ee682014-02-12 14:06:06 -080059 'mutex',
Brian Silverman96e6d5a2014-03-24 15:55:40 -070060 'time',
61 ],
62 'export_dependent_settings': [
63 'time',
Brian Silverman4aeac5f2014-02-11 22:17:07 -080064 ],
Brian Silverman1885bd02014-02-13 12:28:12 -080065 'actions': [
66 {
67 'variables': {
68 'script': '<(AOS)/build/queues/print_field.rb',
69 },
70 'action_name': 'gen_print_field',
71 'inputs': [
72 '<(script)',
73 '<!@(find <(AOS)/build/queues/ -name *.rb)',
74 ],
75 'outputs': [
76 '<(print_field_cc)',
77 ],
78 'action': ['ruby', '<(script)', '<(print_field_cc)'],
79 'message': 'Generating print_field.cc',
80 },
Brian Silverman76156ca2014-02-22 13:10:42 -080081 {
82 'variables': {
83 'script': '<(AOS)/build/queues/queue_primitives.rb',
84 },
85 'action_name': 'gen_queue_primitives',
86 'inputs': [
87 '<(script)',
88 '<!@(find <(AOS)/build/queues/ -name *.rb)',
89 ],
90 'outputs': [
91 '<(queue_primitives_h)',
92 ],
93 'action': ['ruby', '<(script)', '<(queue_primitives_h)'],
94 'message': 'Generating queue_primitives.h',
95 },
Brian Silverman1885bd02014-02-13 12:28:12 -080096 ],
Brian Silvermanfd5e2a32014-02-22 20:02:39 -080097 'direct_dependent_settings': {
98 'include_dirs': [
99 '<(SHARED_INTERMEDIATE_DIR)/aos_queue_primitives',
100 ],
101 },
Brian Silverman76156ca2014-02-22 13:10:42 -0800102 'hard_dependency': 1,
Brian Silverman96395be2014-02-11 18:35:57 -0800103 },
104 {
105 'target_name': 'queue_types_test',
106 'type': 'executable',
107 'sources': [
108 'queue_types_test.cc',
109 ],
110 'dependencies': [
111 'queue_types',
112 '<(EXTERNALS):gtest',
Brian Silverman8a8ee682014-02-12 14:06:06 -0800113 'test_queue',
Brian Silverman96395be2014-02-11 18:35:57 -0800114 ],
115 },
116 {
brians343bc112013-02-10 01:53:46 +0000117 'target_name': 'queues',
118 'type': 'static_library',
119 'sources': [
120 'queue.cc',
121 ],
122 'conditions': [
123 ['OS=="crio"', {
124 'dependencies': [
125 '<(EXTERNALS):WPILib',
126 ],
127 },
128 {
129 'dependencies': [
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800130 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:queue',
brians343bc112013-02-10 01:53:46 +0000131 ],
132 'export_dependent_settings': [
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800133 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:queue',
brians343bc112013-02-10 01:53:46 +0000134 ],
135 }]
136 ],
137 'dependencies': [
Brian Silverman3204dd82013-03-12 18:42:01 -0700138 'time',
brians343bc112013-02-10 01:53:46 +0000139 ],
140 'export_dependent_settings': [
Brian Silverman3204dd82013-03-12 18:42:01 -0700141 'time',
brians343bc112013-02-10 01:53:46 +0000142 ],
143 },
144 {
Brian Silverman598800f2013-05-09 17:08:42 -0700145 'target_name': 'scoped_fd',
146 'type': 'static_library',
147 'sources': [
148 # 'scoped_fd.h'
149 ],
150 'dependencies': [
151 '<(AOS)/build/aos.gyp:logging',
152 ],
153 'export_dependent_settings': [
154 '<(AOS)/build/aos.gyp:logging',
155 ],
156 },
157 {
brians343bc112013-02-10 01:53:46 +0000158 'target_name': 'control_loop_queues',
159 'type': 'static_library',
160 'sources': [ '<(AOS)/common/control_loop/control_loops.q' ],
161 'variables': {
162 'header_path': 'aos/common/control_loop',
163 },
164 'dependencies': [
165 '<(AOS)/common/common.gyp:queues',
166 ],
167 'includes': ['../build/queues.gypi'],
168 },
169 {
brians343bc112013-02-10 01:53:46 +0000170 'target_name': 'controls',
171 'type': 'static_library',
Brian Silvermanf665d692013-02-17 22:11:39 -0800172 'sources': [
Brian Silverman15ca9852013-03-17 18:24:15 -0700173 'control_loop/ControlLoop.cc',
Brian Silvermanf665d692013-02-17 22:11:39 -0800174 ],
brians343bc112013-02-10 01:53:46 +0000175 'dependencies': [
Brian Silverman2ac0fbc2014-03-20 19:45:13 -0700176 '<(AOS)/common/messages/messages.gyp:robot_state',
brians343bc112013-02-10 01:53:46 +0000177 '<(AOS)/build/aos.gyp:logging',
Brian3afd6fc2014-04-02 20:41:49 -0700178 '<(AOS)/common/util/util.gyp:phased_loop',
Brian Silverman3204dd82013-03-12 18:42:01 -0700179 'time',
Brian Silverman1e869f32013-10-25 18:00:20 -0700180 'control_loop_queues',
Brian Silvermand6974f42014-02-14 13:39:21 -0800181 '<(AOS)/common/logging/logging.gyp:queue_logging',
Brian Silverman50a9d032014-02-16 17:20:57 -0800182 '<(AOS)/common/util/util.gyp:log_interval',
Austin Schuh3d6e3df2014-02-17 01:51:03 -0800183 '<(DEPTH)/bbb_cape/src/bbb/bbb.gyp:sensor_generation',
brians343bc112013-02-10 01:53:46 +0000184 ],
Brian Silvermanf665d692013-02-17 22:11:39 -0800185 'export_dependent_settings': [
Brian Silverman2ac0fbc2014-03-20 19:45:13 -0700186 '<(AOS)/common/messages/messages.gyp:robot_state',
Brian Silvermanf665d692013-02-17 22:11:39 -0800187 '<(AOS)/build/aos.gyp:logging',
Brian3afd6fc2014-04-02 20:41:49 -0700188 '<(AOS)/common/util/util.gyp:phased_loop',
Brian Silverman3204dd82013-03-12 18:42:01 -0700189 'time',
Brian Silverman1e869f32013-10-25 18:00:20 -0700190 'control_loop_queues',
Brian Silvermand6974f42014-02-14 13:39:21 -0800191 '<(AOS)/common/logging/logging.gyp:queue_logging',
Brian Silverman50a9d032014-02-16 17:20:57 -0800192 '<(AOS)/common/util/util.gyp:log_interval',
Austin Schuh3d6e3df2014-02-17 01:51:03 -0800193 '<(DEPTH)/bbb_cape/src/bbb/bbb.gyp:sensor_generation',
Brian Silvermanf665d692013-02-17 22:11:39 -0800194 ],
brians343bc112013-02-10 01:53:46 +0000195 },
196 {
197 'target_name': 'queue_test',
198 'type': 'executable',
199 'sources': [
Brian Silverman598800f2013-05-09 17:08:42 -0700200 'queue_test.cc',
brians343bc112013-02-10 01:53:46 +0000201 ],
202 'dependencies': [
203 '<(EXTERNALS):gtest',
brians343bc112013-02-10 01:53:46 +0000204 'queue_testutils',
Brian Silverman8a8ee682014-02-12 14:06:06 -0800205 'test_queue',
Brian Silverman798c7782013-03-28 16:48:02 -0700206 '<(AOS)/common/util/util.gyp:thread',
Brian Silverman8d2e56e2013-09-23 17:55:03 -0700207 'die',
Brian Silverman9eaf91a2014-03-24 16:37:44 -0700208 # We want to run it with the assertions etc to try and catch bugs there.
209 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:queue_debug',
brians343bc112013-02-10 01:53:46 +0000210 ],
211 },
212 {
213 'target_name': 'type_traits_test',
Brian Silvermanc88d8152014-03-20 15:28:58 -0700214 'type': 'executable',
brians343bc112013-02-10 01:53:46 +0000215 'sources': [
216 'type_traits_test.cpp',
217 ],
218 'dependencies': [
219 '<(EXTERNALS):gtest',
brians2fdfc072013-02-26 05:35:15 +0000220 ],
221 },
222 {
223 'target_name': 'gtest_prod',
224 'type': 'static_library',
225 'dependencies': [
226 '<(EXTERNALS):gtest_prod',
227 ],
228 'export_dependent_settings': [
229 '<(EXTERNALS):gtest_prod',
230 ],
231 },
232 {
233 'target_name': 'once',
234 'type': 'static_library',
235 'dependencies': [
236 '<(EXTERNALS):gtest_prod',
237 ],
238 'export_dependent_settings': [
239 '<(EXTERNALS):gtest_prod',
240 ],
241 },
242 {
243 'target_name': 'once_test',
Brian Silvermanc88d8152014-03-20 15:28:58 -0700244 'type': 'executable',
brians2fdfc072013-02-26 05:35:15 +0000245 'sources': [
246 'once_test.cc',
247 ],
248 'dependencies': [
249 '<(EXTERNALS):gtest',
Brian Silverman598800f2013-05-09 17:08:42 -0700250 'once',
brians343bc112013-02-10 01:53:46 +0000251 ],
252 },
253 {
254 'target_name': 'time_test',
Brian Silvermanc88d8152014-03-20 15:28:58 -0700255 'type': 'executable',
brians343bc112013-02-10 01:53:46 +0000256 'sources': [
257 'time_test.cc',
258 ],
259 'dependencies': [
260 '<(EXTERNALS):gtest',
Brian Silverman598800f2013-05-09 17:08:42 -0700261 'time',
262 '<(AOS)/build/aos.gyp:logging',
brians343bc112013-02-10 01:53:46 +0000263 ],
264 },
265 {
Brian Silvermanf665d692013-02-17 22:11:39 -0800266 'target_name': 'die',
267 'type': 'static_library',
268 'sources': [
269 'die.cc',
270 ],
271 },
272 {
Brian Silverman08661c72013-09-01 17:24:38 -0700273 'target_name': 'condition',
274 'type': 'static_library',
275 'sources': [
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800276 '<(AOS)/linux_code/ipc_lib/condition.cc',
Brian Silverman08661c72013-09-01 17:24:38 -0700277 ],
278 'dependencies': [
279 'mutex',
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800280 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:aos_sync',
Brian Silvermanb0893882014-02-10 14:48:30 -0800281 '<(AOS)/build/aos.gyp:logging_interface',
Brian Silverman08661c72013-09-01 17:24:38 -0700282 ],
283 'export_dependent_settings': [
284 'mutex',
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800285 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:aos_sync',
Brian Silverman08661c72013-09-01 17:24:38 -0700286 ],
287 },
288 {
Brian Silvermanf665d692013-02-17 22:11:39 -0800289 'target_name': 'mutex',
290 'type': 'static_library',
291 'conditions': [
292 ['OS=="crio"', {
293 'sources': [
294 '<(AOS)/crio/shared_libs/mutex.cpp',
295 ],
296 }, {
297 'sources': [
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800298 '<(AOS)/linux_code/ipc_lib/mutex.cpp',
Brian Silvermanf665d692013-02-17 22:11:39 -0800299 ],
300 'dependencies': [
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800301 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:aos_sync',
Brian Silvermanf665d692013-02-17 22:11:39 -0800302 ],
303 'export_dependent_settings': [
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800304 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:aos_sync',
Brian Silvermanf665d692013-02-17 22:11:39 -0800305 ],
306 }],
307 ],
Brian Silverman598800f2013-05-09 17:08:42 -0700308 'dependencies': [
Brian Silvermanb0893882014-02-10 14:48:30 -0800309 '<(AOS)/build/aos.gyp:logging_interface',
Brian Silverman598800f2013-05-09 17:08:42 -0700310 ],
Brian Silvermanf665d692013-02-17 22:11:39 -0800311 },
312 {
brians343bc112013-02-10 01:53:46 +0000313 'target_name': 'mutex_test',
Brian Silvermanc88d8152014-03-20 15:28:58 -0700314 'type': 'executable',
brians343bc112013-02-10 01:53:46 +0000315 'sources': [
316 'mutex_test.cpp',
317 ],
318 'dependencies': [
319 '<(EXTERNALS):gtest',
Brian Silverman598800f2013-05-09 17:08:42 -0700320 'mutex',
Brian Silverman8d2e56e2013-09-23 17:55:03 -0700321 'die',
brians343bc112013-02-10 01:53:46 +0000322 ],
323 },
324 {
Brian Silverman797e71e2013-09-06 17:29:39 -0700325 'target_name': 'condition_test',
326 'type': 'executable',
327 'sources': [
328 'condition_test.cc',
329 ],
330 'dependencies': [
331 '<(EXTERNALS):gtest',
332 'condition',
333 '<(AOS)/common/util/util.gyp:thread',
334 'time',
335 'mutex',
336 '<(AOS)/build/aos.gyp:logging',
337 'queue_testutils',
Brian Silverman14fd0fb2014-01-14 21:42:01 -0800338 '<(AOS)/linux_code/ipc_lib/ipc_lib.gyp:core_lib',
Brian Silverman8d2e56e2013-09-23 17:55:03 -0700339 'die',
Brian Silverman797e71e2013-09-06 17:29:39 -0700340 ],
341 },
342 {
brians343bc112013-02-10 01:53:46 +0000343 'target_name': 'die_test',
344 'type': 'executable',
345 'sources': [
346 'die_test.cc',
347 ],
348 'dependencies': [
349 '<(EXTERNALS):gtest',
Brian Silverman598800f2013-05-09 17:08:42 -0700350 'die',
brians343bc112013-02-10 01:53:46 +0000351 ],
352 },
brians343bc112013-02-10 01:53:46 +0000353 ],
354}