Merge branch 'OOP' of https://scm.cri.ensmp.fr/git/Faustine into OOP
[Faustine.git] / interpretor / faust-0.9.47mr3 / tools / faust2appls / faust2jackserver
1 #!/bin/bash
2
3 if [[ $(uname) == Darwin ]]; then
4 #On Darwin build a Jack QT4 application using xcode
5 for f in $@; do
6
7 CUR=$(pwd)
8 TMP=/var/tmp/${f%.dsp}
9
10 rm -rf $TMP
11 install -d $TMP
12
13 faust -a jack-qt.cpp $f -o $TMP/${f%.dsp}.cpp
14
15 cd $TMP; qmake -project "INCLUDEPATH+=$CUR" "INCLUDEPATH+=/usr/local/lib/faust/" "LIBS+=-ljackserver" "HEADERS+=/usr/local/lib/faust/gui/faustqt.h"
16 cd $TMP; qmake
17 echo toto
18 cd $TMP; xcodebuild -project ${f%.dsp}.xcodeproj
19 echo titi
20 cd $CUR; rm -rf ${f%.dsp}.app
21 cd $CUR; mv $TMP/build/Default/${f%.dsp}.app ${f%.dsp}.app
22 rm -rf $TMP
23
24 done
25
26
27 else
28 #On Linux (default) build a jack gtk application
29 for f in $@; do
30 faust -a jack-gtk.cpp $f -o $f.cpp
31 ${CXX=g++} ${CXXFLAGS=-O3} `pkg-config --cflags --libs jack gtk+-2.0` $f.cpp -o ${f%.dsp}
32 done
33
34 fi