Changes in / [5b194f0:2f02d51]
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
.appveyor.yml
r5b194f0 r2f02d51 8 8 # pre-installed python version, see: 9 9 # http://www.appveyor.com/docs/installed-software#python 10 - PYTHON DIR: "C:\\Python27"10 - PYTHON: "C:\\Python27" 11 11 PYTHON_VERSION: "2.7.x" 12 12 PYTHON_ARCH: "32" 13 13 14 - PYTHON DIR: "C:\\Python27-x64"14 - PYTHON: "C:\\Python27-x64" 15 15 PYTHON_VERSION: "2.7.x" 16 16 PYTHON_ARCH: "64" 17 17 18 - PYTHON DIR: "C:\\Python34"18 - PYTHON: "C:\\Python34" 19 19 PYTHON_VERSION: "3.4.x" 20 20 PYTHON_ARCH: "32" 21 21 22 - PYTHON DIR: "C:\\Python34-x64"22 - PYTHON: "C:\\Python34-x64" 23 23 PYTHON_VERSION: "3.4.x" 24 24 PYTHON_ARCH: "64" 25 25 26 - PYTHON DIR: "C:\\Python35"26 - PYTHON: "C:\\Python35" 27 27 PYTHON_VERSION: "3.5.x" 28 28 PYTHON_ARCH: "32" 29 29 30 - PYTHON DIR: "C:\\Python35-x64"30 - PYTHON: "C:\\Python35-x64" 31 31 PYTHON_VERSION: "3.5.x" 32 32 PYTHON_ARCH: "64" … … 40 40 41 41 # Check that we have the expected version and architecture for Python 42 - "%PYTHON DIR%\\python.exe --version"43 - "%PYTHON DIR%\\python.exe -c \"import struct; print(struct.calcsize('P') * 8)\""42 - "%PYTHON%\\python.exe --version" 43 - "%PYTHON%\\python.exe -c \"import struct; print(struct.calcsize('P') * 8)\"" 44 44 45 45 # We need wheel installed to build wheels 46 - "%PYTHON DIR%\\python.exe -m pip install wheel"46 - "%PYTHON%\\python.exe -m pip install wheel" 47 47 48 - "SET PATH=%PATH_EXTRAS%;%PYTHON DIR%;%PYTHONDIR%\\Scripts;%PATH%"48 - "SET PATH=%PATH_EXTRAS%;%PYTHON%;%PYTHON%\\Scripts;%PATH%" 49 49 50 50 - "pip install --disable-pip-version-check --user --upgrade pip" … … 52 52 53 53 before_build: 54 - "bash scripts/get_waf.sh" 54 - curl -fsS -o waf https://waf.io/waf-1.8.22 55 - curl -fsS -o waf.bat https://raw.githubusercontent.com/waf-project/waf/master/utils/waf.bat 55 56 56 57 build_script: … … 62 63 - "nose2 --verbose" 63 64 # clean up 64 - "python waf distclean"65 - waf distclean 65 66 # build libaubio 66 - python waf configure build --verbose --msvc_version="msvc 14.0"67 - waf configure build --verbose 67 68 # build python module using libaubio dll 68 69 - "python setup.py build" -
scripts/build_emscripten
r5b194f0 r2f02d51 1 #! /bin/ bash1 #! /bin/sh 2 2 3 3 function checkprog() { … … 10 10 11 11 # clean 12 ./waf distclean12 emmake ./waf distclean 13 13 14 14 # configure 15 emconfigure ./waf configure -- with-target-platform emscripten $*15 emconfigure ./waf configure --prefix=$EMSCRIPTEN/system/local/ --with-target-platform emscripten 16 16 17 17 # build 18 emmake ./waf build 18 emmake ./waf --testcmd="node %s" 19 20 # intall 21 #emmake ./waf install -
scripts/get_waf.sh
r5b194f0 r2f02d51 1 #! /bin/ bash1 #! /bin/sh 2 2 3 3 set -e 4 4 set -x 5 5 6 WAFVERSION=2.0.1 7 WAFTARBALL=waf-$WAFVERSION.tar.bz2 8 WAFURL=https://waf.io/$WAFTARBALL 6 WAFURL=https://waf.io/waf-2.0.1 9 7 10 WAFBUILDDIR=`mktemp -d` 8 ( which wget > /dev/null && wget -qO waf $WAFURL ) || ( which curl > /dev/null && curl $WAFURL > waf ) 11 9 12 function cleanup () { 13 rm -rf $WAFBUILDDIR 14 } 15 16 trap cleanup SIGINT SIGTERM 17 18 function buildwaf () { 19 pushd $WAFBUILDDIR 20 21 ( which wget > /dev/null && wget -qO $WAFTARBALL $WAFURL ) || ( which curl > /dev/null && curl $WAFURL > $WAFTARBALL ) 22 23 tar xf $WAFTARBALL 24 pushd waf-$WAFVERSION 25 NOCLIMB=1 python waf-light --tools=c_emscripten,syms $* 26 27 popd 28 popd 29 30 cp -prv $WAFBUILDDIR/waf-$WAFVERSION/waf $PWD 31 32 chmod +x waf 33 } 34 35 buildwaf 36 37 cleanup 10 chmod +x waf -
wscript
r5b194f0 r2f02d51 103 103 104 104 def configure(ctx): 105 from waflib import Options 106 ctx.load('compiler_c') 107 ctx.load('waf_unit_test') 108 ctx.load('gnu_dirs') 109 105 110 target_platform = sys.platform 106 111 if ctx.options.target_platform: 107 112 target_platform = ctx.options.target_platform 108 113 109 from waflib import Options110 114 111 115 if target_platform=='emscripten': 112 ctx.load('c_emscripten') 113 else: 114 ctx.load('compiler_c') 115 116 ctx.load('waf_unit_test') 117 ctx.load('gnu_dirs') 118 116 # need to force spaces between flag -o and path 117 # inspired from : 118 # https://github.com/waf-project/waf/blob/master/waflib/extras/c_emscripten.py (#1885) 119 # (OSX /emscripten 1.37.9) 120 ctx.env.CC_TGT_F = ['-c', '-o', ''] 121 ctx.env.CCLNK_TGT_F = ['-o', ''] 119 122 # check for common headers 120 123 ctx.check(header_name='stdlib.h') … … 149 152 else: 150 153 # enable debug symbols 151 ctx.env.CFLAGS += ['/Z7'] 152 # /FS flag available in msvc >= 12 (2013) 153 if 'MSVC_VERSION' in ctx.env and ctx.env.MSVC_VERSION >= 12: 154 ctx.env.CFLAGS += ['/FS'] 154 ctx.env.CFLAGS += ['/Z7', '/FS'] 155 155 ctx.env.LINKFLAGS += ['/DEBUG', '/INCREMENTAL:NO'] 156 156 # configure warnings … … 227 227 228 228 if target_platform == 'emscripten': 229 import os.path 230 ctx.env.CFLAGS += [ '-I' + os.path.join(os.environ['EMSCRIPTEN'], 'system', 'include') ] 231 229 232 if ctx.options.build_type == "debug": 230 233 ctx.env.cshlib_PATTERN = '%s.js' … … 247 250 from python.lib.gen_external import get_c_declarations, get_cpp_objects_from_c_declarations, get_all_func_names_from_lib, generate_lib_from_c_declarations 248 251 c_decls = get_c_declarations(usedouble=False) # emscripten can't use double 249 objects = list(get_cpp_objects_from_c_declarations(c_decls))252 objects = get_cpp_objects_from_c_declarations(c_decls) 250 253 # ensure that aubio structs are exported 251 254 objects += ['fvec_t', 'cvec_t', 'fmat_t'] … … 444 447 # add sub directories 445 448 if bld.env['DEST_OS'] not in ['ios', 'iosimulator', 'android']: 446 if bld.env['DEST_OS']=='emscripten' and not bld.options.testcmd:447 bld.options.testcmd = 'node %s'448 449 bld.recurse('examples') 449 450 bld.recurse('tests')
Note: See TracChangeset
for help on using the changeset viewer.