]> begriffs open source - cmsis-driver-bare/blob - meson.build
Pass cmsis validator test
[cmsis-driver-bare] / meson.build
1 project('cmsis-driver-bare', 'c',
2   version: '1.0.0',
3   license: 'MIT',
4   meson_version: '>=0.60.0')
5
6 subdir('cross/armv7m')
7
8 cmsis_core_dep = subproject('cmsis').get_variable('cmsis_core_dep')
9 cmsis_driver_dep = subproject('cmsis').get_variable('cmsis_driver_dep')
10 cmsis_rtos_dep = subproject('cmsis').get_variable('cmsis_rtos_dep')
11 cmsis_dfp_dep = subproject('cmsis-dfp-stm32f4').get_variable('cmsis_dfp_stm32f4_dep')
12 freertos_dep = subproject('cmsis-freertos').get_variable('cmsis_freertos_dep')
13 cmsis_dv_dep = subproject('cmsis-driver-validation').get_variable('cmsis_dv_dep')
14 internal_inc = include_directories('inc')
15
16 subdir('lib')
17 if get_option('enable_demos')
18   subdir('demo')
19 endif
20 if get_option('enable_tests')
21   subdir('test')
22 endif
23
24 if get_option('enable_demos') and gdb.found() and ocd.found() and objcopy.found()
25   run_target('flash', command: [flash_cmd, demo_gpio])
26   run_target('gdb', command: [gdb_cmd, demo_gpio])
27   if ddd.found()
28     run_target('ddd', command: [ddd_cmd, demo_gpio])
29   endif
30 endif
31
32 if get_option('enable_tests') and gdb.found() and ocd.found() and objcopy.found()
33   run_target('flash-test', command: [flash_cmd, test_cmsis_validate])
34   run_target('gdb-test', command: [gdb_cmd, test_cmsis_validate])
35   if ddd.found()
36     run_target('ddd-test', command: [ddd_cmd, test_cmsis_validate])
37   endif
38 endif
39