wscript: check for 64bit using sys.maxsize (closes #3)
[vamp-aubio-plugins.git] / build_osx.sh
1 #! /bin/sh
2
3 # instructions to build vamp-aubio-plugins for mac os x
4
5 . $PWD/VERSION
6 VAMP_AUBIO_VERSION=$VAMP_AUBIO_MAJOR_VERSION.$VAMP_AUBIO_MINOR_VERSION.$VAMP_AUBIO_PATCH_VERSION$VAMP_AUBIO_VERSION_STATUS
7
8 if [ "$1" = 'dist' ]
9 then
10   rm -rf contrib/
11 fi
12
13 # get waf
14 ./scripts/get_waf.sh
15
16 # fetch Vamp SDK
17 ./scripts/get_deps_osx.sh
18
19 # fetch and build aubio
20 ./scripts/get_aubio.sh
21
22 # configure and build plugin
23 ./waf configure
24
25 ./waf build -v
26
27 # install in user's home directory
28 # ./waf install --destdir=$HOME
29
30 # system-wide installation
31 # sudo ./waf install
32
33 if [ "$1" = 'dist' ]
34 then
35   DESTDIR=vamp-aubio-plugins-$VAMP_AUBIO_VERSION-osx
36   rm -rf $DESTDIR $DESTDIR.zip
37   mkdir $DESTDIR
38   cp -prv contrib/aubio*/README.md $DESTDIR/README.aubio.md
39   cp -prv README.md $DESTDIR
40   cp -prv build/vamp-aubio.dylib $DESTDIR
41   strip $DESTDIR/vamp-aubio.dylib
42   cp -prv vamp-aubio.cat vamp-aubio.n3 $DESTDIR
43   tar jcvf $DESTDIR.tar.bz2 $DESTDIR
44 fi