blob: 642b827089b904b0244f882dfc257f851b1b276b [file] [log] [blame]
Zane Shelleyad103b92019-07-31 15:57:54 -05001# build simulator
2subdir('simulator')
3
Ben Tynera8126fd2019-08-01 19:40:07 -05004# supporting files that need compiled/linked
Ben Tyner032bf9e2020-05-06 21:27:54 -05005test_src = ['../src/util/hei_bit_string.cpp',
Zane Shelley7649b8b2020-05-08 20:12:35 -05006 'sim_tracing.cpp']
Ben Tynera8126fd2019-08-01 19:40:07 -05007
8# build g-test framework unit tests
Zane Shelley200c3452019-09-26 11:46:30 -05009gtests = [
10 'bit_string_test',
Paul Greenwooddc47e0a2019-11-01 16:22:57 -050011 'flyweight_test'
Zane Shelley200c3452019-09-26 11:46:30 -050012]
Ben Tynera8126fd2019-08-01 19:40:07 -050013
14gtest = dependency('gtest', main : true, required : false, method : 'system')
15
16if gtest.found()
17 foreach g : gtests
18 test(g, executable(g.underscorify(), g + '.cpp', test_src, \
19 dependencies : gtest, \
20 include_directories : incdir))
21 endforeach
22endif
Paul Greenwooddc47e0a2019-11-01 16:22:57 -050023
24# build unit-test framework
25tests = ['hei_operator_register_testcase']
26
27foreach t : tests
28 test(t, executable(t.underscorify(), t + '.cpp', test_src, \
29 include_directories : incdir))
30endforeach