From f6ee1606c56bb497f61231d271f40064decbc38f Mon Sep 17 00:00:00 2001 From: Paul Brossier Date: Thu, 21 Nov 2013 20:09:16 +0100 Subject: [PATCH] examples/wscript_build: simplify --- examples/wscript_build | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/examples/wscript_build b/examples/wscript_build index 1ef6387a..6e5ace8e 100644 --- a/examples/wscript_build +++ b/examples/wscript_build @@ -1,19 +1,20 @@ # vim:set syntax=python: +utils_source = ['utils.c', 'jackio.c'] +programs_source = ctx.path.ant_glob('*.c', excl = utils_source) + # build examples -utilsio = bld( - name = 'utilsio', - features = 'c', - includes = '../src', - source = ['utils.c', 'jackio.c'], - target = 'utilsio') +bld(features = 'c', + source = utils_source, + includes = ['../src'], + target = 'utilsio') # loop over all *.c filenames in examples to build them all -for source_file in ctx.path.ant_glob('*.c', excl = ['utils.c', 'jackio.c']): - bld.program(features = 'c cprogram', +for source_file in programs_source: + bld(features = 'c cprogram', includes = '../src', lib = 'm', use = ['aubio', 'utilsio'], - source = str(source_file), + source = source_file, target = str(source_file).split('.')[0] ) -- 2.11.0