| 1 |
project('myexe', 'c', version: '0.1') |
| 2 |
sub = subproject('sub') |
| 3 |
|
| 4 |
prog = find_program('foobar', version : '>= 2.0', required : false) |
| 5 |
assert(not prog.found()) |
| 6 |
|
| 7 |
prog = find_program('foobar', version : '>= 1.0') |
| 8 |
custom1 = custom_target('custom1', |
| 9 |
build_by_default : true, |
| 10 |
input : [], |
| 11 |
output : 'main1.c', |
| 12 |
command : [prog, '@OUTPUT@']) |
| 13 |
gen = generator(prog, |
| 14 |
output : '@[email protected]', |
| 15 |
arguments : ['@OUTPUT@']) |
| 16 |
custom2 = gen.process('main2.input') |
| 17 |
|
| 18 |
message(prog.full_path()) |
| 19 |
|
| 20 |
executable('e1', custom1) |
| 21 |
executable('e2', custom2) |