Merge branch 'master' of piem.org:/git/aubio/aubio
[aubio.git] / examples / wscript_build
1 if bld.env['SNDFILE']:
2   # build examples
3   sndfileio = bld.new_task_gen(features = 'c',
4       includes = '../src',
5       source = ['sndfileio.c'],
6       target = 'sndfileio')
7
8   utilsio = bld.new_task_gen(features = 'c',
9         includes = '../src',
10         add_objects = 'sndfileio',
11         source = ['utils.c', 'jackio.c'],
12         uselib = ['LASH', 'JACK', 'SNDFILE'],
13         target = 'utilsio')
14
15   # loop over all *.c filenames in examples to build them all
16   for target_name in bld.path.ant_glob('*.c', excl = ['utils.c', 'jackio.c', 'sndfileio.c']):
17     bld.new_task_gen(features = 'c cprogram',
18         add_objects = 'utilsio',
19         includes = '../src',
20         uselib = ['LASH', 'JACK', 'SNDFILE'],
21         use = 'aubio',
22         source = target_name,
23         # program name is filename.c without the .c
24         target = str(target_name).split('.')[0])