import os, glob, sys options = Options('options.cache', ARGUMENTS) options.Add(PathOption('clam_prefix', 'The prefix where CLAM was installed', '')) env = Environment(ENV=os.environ, options=options) options.Save('options.cache', env) Help(options.GenerateHelpText(env)) env.SConsignFile() # Single signature file CLAMInstallDir = env['clam_prefix'] clam_sconstoolspath = os.path.join(CLAMInstallDir,'share','clam','sconstools') env.Tool('clam', toolpath=[clam_sconstoolspath]) env.EnableClamModules([ 'clam_core', 'clam_audioio', 'clam_processing', ] , CLAMInstallDir) mainSources = { 'MyProgram' :'./main.cxx', } if sys.platform=='win32' : env.Append(CPPFLAGS=['-D_USE_MATH_DEFINES']) # to have M_PI defined if sys.platform=='linux2' : env.Append( CCFLAGS=['-g','-O3','-Wall'] ) programs = [ env.Program(target=program, source = [main] ) for program, main in mainSources.items()] env.Default(programs)