| 1 |
project('cmakeSubTest', ['c', 'cpp']) |
| 2 |
|
| 3 |
cm = import('cmake') |
| 4 |
|
| 5 |
sub_pro = cm.subproject('cmMod') |
| 6 |
sub_dep = sub_pro.dependency('cmModLib++', include_type: 'system') |
| 7 |
|
| 8 |
assert(sub_pro.found(), 'found() method reports not found, but should be found') |
| 9 |
assert(sub_pro.target_list() == ['cmModLib++'], 'There should be exactly one target') |
| 10 |
assert(sub_pro.target_type('cmModLib++') == 'shared_library', 'Target type should be shared_library') |
| 11 |
assert(sub_dep.include_type() == 'system', 'the include_type kwarg of dependency() works') |
| 12 |
|
| 13 |
exe1 = executable('main', ['main.cpp'], dependencies: [sub_dep]) |
| 14 |
test('test1', exe1) |