Toshihiro Shimizu 890ddd
#!/bin/sh
Toshihiro Shimizu 890ddd

Toshihiro Shimizu 890ddd
echo '   Create Frameworks folder inside toonz 7.1.app/Contents…'
Toshihiro Shimizu 890ddd
mkdir $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd

Toshihiro Shimizu 890ddd
echo '   Copy tnzcore to Frameworks...':
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libtnzcore.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy tnzbase to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libtnzbase.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy tnzext to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libtnzext.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy toonzlib to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libtoonzlib.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy image to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libimage.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy sound to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libsound.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy colorfx to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libcolorfx.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy tnzstdfx to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libtnzstdfx.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy tfarm to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libtfarm.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy tnztools to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libtnztools.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd
echo '   Copy toonzqt to Frameworks...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/libtoonzqt.1.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd

Toshihiro Shimizu 890ddd
echo '   Copy composer...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/tcomposer.app/Contents/MacOS/tcomposer $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/
Toshihiro Shimizu 890ddd
echo '   Copy cleanup...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/tcleanup.app/Contents/MacOS/tcleanup $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/
Toshihiro Shimizu 890ddd
echo '   Copy farmserver...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/tfarmserver.app/Contents/MacOS/tfarmserver $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/
Toshihiro Shimizu 890ddd
echo '   Copy farmcontroller...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/tfarmcontroller.app/Contents/MacOS/tfarmcontroller $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/
Toshihiro Shimizu 890ddd
echo '   Copy converter...'
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/tconverter.app/Contents/MacOS/tconverter $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/
Toshihiro Shimizu 890ddd

Toshihiro Shimizu 890ddd
echo '   Copy t32bitsrv...'
Toshihiro Shimizu 890ddd
lipo -remove x86_64 $BINROOT/bin/t32bitsrv.app/Contents/MacOS/t32bitsrv -output $BINROOT/bin/t32bitsrv.app/Contents/MacOS/t32bitsrv
Toshihiro Shimizu 890ddd
cp -RH $BINROOT/bin/t32bitsrv.app/Contents/MacOS/t32bitsrv $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/
Toshihiro Shimizu 890ddd

Toshihiro Shimizu 890ddd
echo '   Copy QTCore 4.8 Frameworks...'
Toshihiro Shimizu 890ddd
mkdir -p $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtCore.framework/Versions/4
Toshihiro Shimizu 890ddd
cp /Library/Frameworks/QtCore.framework/Versions/4/QtCore $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtCore.framework/Versions/4/
Toshihiro Shimizu 890ddd
echo '   Copy QTGui 4.8 Frameworks...'
Toshihiro Shimizu 890ddd
mkdir -p $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtGui.framework/Versions/4
Toshihiro Shimizu 890ddd
cp /Library/Frameworks/QtGui.framework/Versions/4/QtGui $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtGui.framework/Versions/4/
Toshihiro Shimizu 890ddd
echo '   Copy QTOpenGL 4.8 Frameworks...'
Toshihiro Shimizu 890ddd
mkdir -p $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtOpenGL.framework/Versions/4
Toshihiro Shimizu 890ddd
cp /Library/Frameworks/QtOpenGL.framework/Versions/4/QtOpenGL $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtOpenGL.framework/Versions/4/
Toshihiro Shimizu 890ddd
echo '   Copy QtXml 4.8 Frameworks...'
Toshihiro Shimizu 890ddd
mkdir -p $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtXml.framework/Versions/4
Toshihiro Shimizu 890ddd
cp /Library/Frameworks/QtXml.framework/Versions/4/QtXml $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtXml.framework/Versions/4/
Toshihiro Shimizu 890ddd
echo '   Copy QtSvg 4.8 Frameworks...'
Toshihiro Shimizu 890ddd
mkdir -p $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtSvg.framework/Versions/4
Toshihiro Shimizu 890ddd
cp /Library/Frameworks/QtSvg.framework/Versions/4/QtSvg $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtSvg.framework/Versions/4/
Toshihiro Shimizu 890ddd
echo '   Copy QtNetwork 4.8 Frameworks...'
Toshihiro Shimizu 890ddd
mkdir -p $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtNetwork.framework/Versions/4
Toshihiro Shimizu 890ddd
cp /Library/Frameworks/QtNetwork.framework/Versions/4/QtNetwork $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtNetwork.framework/Versions/4/
Toshihiro Shimizu 890ddd
echo '   Copy QtScript 4.8 Frameworks...'
Toshihiro Shimizu 890ddd
mkdir -p $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtScript.framework/Versions/4
Toshihiro Shimizu 890ddd
cp /Library/Frameworks/QtScript.framework/Versions/4/QtScript $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks/QtScript.framework/Versions/4/
Toshihiro Shimizu 890ddd

Toshihiro Shimizu 890ddd
echo '   Copy Qt plugins...'
Toshihiro Shimizu 890ddd
mkdir -p $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/imageformats
Toshihiro Shimizu 890ddd
cp /Developer/Applications/Qt/plugins/imageformats/libqjpeg.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/imageformats/
Toshihiro Shimizu 890ddd
cp /Developer/Applications/Qt/plugins/imageformats/libqgif.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/imageformats/
Toshihiro Shimizu 890ddd
cp /Developer/Applications/Qt/plugins/imageformats/libqtiff.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/imageformats/
Toshihiro Shimizu 890ddd
cp /Developer/Applications/Qt/plugins/imageformats/libqsvg.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/MacOS/imageformats/
Toshihiro Shimizu 890ddd

Toshihiro Shimizu 890ddd
echo '   Copy GLEW'
Toshihiro Shimizu 890ddd
cp -RH  /depot/sdk/glew/glew-1.9.0/lib/libGLEW.dylib $BINROOT/bin/Toonz\ 7.1.app/Contents/Frameworks
Toshihiro Shimizu 890ddd

Toshihiro Shimizu 890ddd
echo '   Create qt.conf...'
Toshihiro Shimizu 890ddd
mkdir $BINROOT/bin/Toonz\ 7.1.app/Contents/Resources
Toshihiro Shimizu 890ddd
echo 'Prefix = .' > $BINROOT/bin/Toonz\ 7.1.app/Contents/Resources/qt.conf
Toshihiro Shimizu 890ddd
echo '   Copy SystemVar...'
Toshihiro Shimizu 890ddd
cp ./SystemVar.ini $BINROOT/bin/Toonz\ 7.1.app/Contents/Resources/
Toshihiro Shimizu 890ddd
chmod 777 $BINROOT/bin/Toonz\ 7.1.app/Contents/Resources/SystemVar.ini
Toshihiro Shimizu 890ddd
echo '   Copy configfarmroot...'
Toshihiro Shimizu 890ddd
cp ./configfarmroot.txt $BINROOT/bin/Toonz\ 7.1.app/Contents/Resources/
Toshihiro Shimizu 890ddd
chmod 777 $BINROOT/bin/Toonz\ 7.1.app/Contents/Resources/configfarmroot.txt
Toshihiro Shimizu 890ddd
echo '   Copy qt_menu.nib...'
Toshihiro Shimizu 890ddd
cp -R /Library/Frameworks/QtGui.framework/Versions/Current/Resources/qt_menu.nib $BINROOT/bin/Toonz\ 7.1.app/Contents/Resources/