|
From: Tapio V. <aa...@us...> - 2010-08-21 14:03:25
|
Module: performous Branch: pass-through Commit: 585f32044b561b4e35acf22eee9abeabe2a5e801 Author: Arto Seppä <za...@us...> Date: Thu Aug 19 09:29:25 2010 +0300 Fixed the bundling script to check for dylibbundler and to create a disk image. --- osx-utils/performous-app-build.sh | 45 ++++++++++++++++++++++++------------ 1 files changed, 30 insertions(+), 15 deletions(-) diff --git a/osx-utils/performous-app-build.sh b/osx-utils/performous-app-build.sh index f775964..6f66224 100755 --- a/osx-utils/performous-app-build.sh +++ b/osx-utils/performous-app-build.sh @@ -1,24 +1,39 @@ +# the very first step is to check that dylibbundler exists, +# without it the bundle would be broken +if which dylibbundler &> /dev/null; then + echo "dylibbundler found!" +else + echo "dylibbundler not found! you need to install it before creating the bundle." + exit +fi + +# first compile performous, build dir shouldn't exist at this stage mkdir build cd build -cmake ../../ -DCMAKE_INSTALL_PREFIX=./Performous.app/Contents +cmake ../../ -DCMAKE_INSTALL_PREFIX=./out/Performous.app/Contents make install -mkdir Performous.app/Contents/MacOS -mkdir Performous.app/Contents/Resources -mkdir Performous.app/Contents/Frameworks +# then create the rest of the app bundle + +mkdir out/Performous.app/Contents/MacOS +mkdir out/Performous.app/Contents/Resources +mkdir out/Performous.app/Contents/Frameworks + +mv out/Performous.app/Contents/bin/* out/Performous.app/Contents/MacOS/ -mv Performous.app/Contents/bin/* Performous.app/Contents/MacOS/ +cp ../resources/performous-launcher out/Performous.app/Contents/MacOS/ +cp ../resources/performous.icns out/Performous.app/Contents/Resources +cp ../resources/Info.plist out/Performous.app/Contents/ +cp -R ../resources/etc out/Performous.app/Contents/Resources -cp ../resources/performous-launcher Performous.app/Contents/MacOS/ -cp ../resources/performous.icns Performous.app/Contents/Resources -cp ../resources/Info.plist Performous.app/Contents/ -cp -R ../resources/etc Performous.app/Contents/Resources +cp -R /Library/Frameworks/SDL.framework out/Performous.app/Contents/Frameworks/SDL.framework -cp -R /Library/Frameworks/SDL.framework Performous.app/Contents/Frameworks/SDL.framework +dylibbundler -od -b -x ./out/Performous.app/Contents/MacOS/performous -d ./out/Performous.app/Contents/libs/ -dylibbundler -od -b -x ./Performous.app/Contents/MacOS/performous -d ./Performous.app/Contents/libs/ -dylibbundler -of -b -x ./Performous.app/Contents/lib/performous/libda-1/libda_audio_dev_jack.so -d ./Performous.app/Contents/libs -dylibbundler -of -b -x ./Performous.app/Contents/lib/performous/libda-1/libda_audio_dev_pa19.so -d ./Performous.app/Contents/libs -dylibbundler -of -b -x ./Performous.app/Contents/lib/performous/libda-1/libda_audio_dev_tone.so -d ./Performous.app/Contents/libs +# then build the disk image +ln -sf /Applications out/Applications +/usr/bin/hdiutil create -srcfolder out -volname Performous -fs HFS+ -fsargs "-c c=64,a=16,e=16" -format UDRW RWPerformous.dmg +/usr/bin/hdiutil convert RWPerformous.dmg -format UDZO -imagekey zlib-level=9 -o Performous.dmg +rm -f RWPerformous.dmg -cd .. +cd .. \ No newline at end of file |