source: src/wscript_build @ 3bf80b9

feature/autosinkfeature/constantqfeature/pitchshiftfeature/pydocstringsfeature/timestretchpitchshiftsamplertimestretchyinfft+
Last change on this file since 3bf80b9 was 3bf80b9, checked in by Paul Brossier <piem@piem.org>, 3 years ago

src/wscript_build: build static lib first

  • Property mode set to 100644
File size: 1.3 KB
Line 
1# vim:set syntax=python:
2
3uselib = []
4uselib += ['FFTW3', 'FFTW3F']
5uselib += ['SAMPLERATE']
6uselib += ['SNDFILE']
7uselib += ['AVCODEC']
8uselib += ['AVFORMAT']
9uselib += ['AVRESAMPLE']
10uselib += ['AVUTIL']
11uselib += ['BLAS']
12
13# build each source files
14source = ctx.path.ant_glob('*.c **/*.c')
15lib = 'm' if 'CL.exe' not in ctx.env.CC[0] else None
16ctx(features = 'c',
17        source = source,
18        includes = ['.'],
19        uselib = uselib,
20        lib = lib,
21        target = 'lib_objects')
22
23# build libaubio.so (cshlib) and/or libaubio.a (cstlib)
24if ctx.env['DEST_OS'] in ['ios', 'iosimulator']:
25    build_features = ['cstlib', 'cshlib']
26elif ctx.env['DEST_OS'] in ['win32', 'win64']:
27    build_features = ['cstlib', 'cshlib']
28elif ctx.env['DEST_OS'] in ['emscripten']:
29    build_features = ['cstlib']
30else: #linux, darwin, android, mingw, ...
31    build_features = ['cstlib', 'cshlib']
32
33for target in build_features:
34    ctx(features = 'c ' + target,
35            use = ['lib_objects'],
36            uselib = uselib,
37            lib = lib,
38            target = 'aubio',
39            vnum = ctx.env['LIB_VERSION'])
40
41# install headers, except _priv.h ones
42ctx.install_files('${PREFIX}/include/aubio/',
43        ctx.path.ant_glob('**/*.h', excl = ['**_priv.h', 'config.h']),
44        relative_trick=True)
Note: See TracBrowser for help on using the repository browser.