source: src/wscript_build @ 1e2811c

Last change on this file since 1e2811c was df2de24, checked in by Paul Brossier <piem@piem.org>, 12 months ago

[waf] remove avresample from wscript_build

  • Property mode set to 100644
File size: 1.6 KB
Line 
1# vim:set syntax=python:
2
3uselib = []
4uselib += ['M']
5uselib += ['FFTW3', 'FFTW3F']
6uselib += ['INTEL_IPP']
7uselib += ['SAMPLERATE']
8uselib += ['SNDFILE']
9uselib += ['RUBBERBAND']
10uselib += ['AVCODEC']
11uselib += ['AVFORMAT']
12uselib += ['SWRESAMPLE']
13uselib += ['AVUTIL']
14uselib += ['VORBISENC']
15uselib += ['FLAC']
16uselib += ['BLAS']
17
18source = ctx.path.ant_glob('*.c **/*.c')
19
20ctx(features = 'c',
21        source = source,
22        includes = ['.'],
23        use = uselib,
24        target = 'lib_objects')
25
26# build libaubio.so (cshlib) and/or libaubio.a (cstlib)
27if ctx.env['DEST_OS'] in ['ios', 'iosimulator']:
28    build_features = ['cstlib', 'cshlib']
29elif ctx.env['DEST_OS'] in ['win32', 'win64']:
30    build_features = ['cstlib', 'cshlib gensyms']
31elif ctx.env['DEST_OS'] in ['emscripten']:
32    build_features = ['cstlib','cshlib']
33elif '--static' in ctx.env['LDFLAGS'] or '--static' in ctx.env['LINKFLAGS']:
34    # static in cflags, ...
35    build_features = ['cstlib']
36else:
37    # linux, darwin, android, mingw, ...
38    build_features = ['cstlib', 'cshlib']
39
40# also install static lib
41from waflib.Tools.c import cstlib
42cstlib.inst_to = '${LIBDIR}'
43
44for target in build_features:
45    ctx(features = 'c ' + target,
46            use = uselib + ['lib_objects'],
47            target = 'aubio',
48            export_symbols_regex=r'(?:.*aubio|fvec|lvec|cvec|fmat|new|del)_.*',
49            vnum = ctx.env['LIB_VERSION'])
50
51# install headers, except _priv.h ones
52ctx.install_files('${INCLUDEDIR}/aubio/',
53        ctx.path.ant_glob('**/*.h', excl = ['**_priv.h', 'config.h']),
54        relative_trick=True)
Note: See TracBrowser for help on using the repository browser.