source: scripts/build_mingw @ 0c3baa73

feature/autosinkfeature/cnnfeature/cnn_orgfeature/constantqfeature/crepefeature/crepe_orgfeature/pitchshiftfeature/pydocstringsfeature/timestretchfix/ffmpeg5sampleryinfft+
Last change on this file since 0c3baa73 was 6b7f54d, checked in by Paul Brossier <piem@piem.org>, 9 years ago

scripts/build_mingw: add script to cross-compile using mingw

  • Property mode set to 100755
File size: 814 bytes
Line 
1#! /bin/bash
2
3# This script cross compiles aubio for windows using mingw, both for 32 and 64
4# bits. Built binaries will be placed in ./dist-win32 and ./dist-win64.
5
6# On debian or ubuntu, you will want to 'apt-get install gcc-mingw-w64'
7
8set -e
9set -x
10
11WAFOPTS="-v --disable-avcodec --disable-samplerate --disable-jack --disable-sndfile"
12
13[ -d dist-win32 ] && rm -rf dist-win32
14[ -d dist-win64 ] && rm -rf dist-win64
15
16CFLAGS="-Os" \
17  LDFLAGS="" \
18  CC=x86_64-w64-mingw32-gcc \
19  ./waf distclean configure build install --destdir=$PWD/dist-win64 \
20    --testcmd="echo %s" \
21    $WAFOPTS --with-target-platform=win64
22
23CFLAGS="-Os" \
24  LDFLAGS="" \
25  CC=i686-w64-mingw32-gcc \
26  ./waf distclean configure build install --destdir=$PWD/dist-win32 \
27    --testcmd="echo %s" \
28    $WAFOPTS --with-target-platform=win32
Note: See TracBrowser for help on using the repository browser.