yolobs-studio/CI/install/osx/packageApp.sh

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

78 lines
4.7 KiB
Bash
Raw Normal View History

2020-03-25 08:07:22 +00:00
# Exit if something fails
set -e
2019-12-10 19:31:54 +00:00
rm -rf ./OBS.app
mkdir OBS.app
mkdir OBS.app/Contents
mkdir OBS.app/Contents/MacOS
2020-03-25 08:07:22 +00:00
mkdir OBS.app/Contents/PlugIns
2019-12-10 19:31:54 +00:00
mkdir OBS.app/Contents/Resources
2019-12-24 09:07:22 +00:00
cp -R rundir/RelWithDebInfo/bin/ ./OBS.app/Contents/MacOS
cp -R rundir/RelWithDebInfo/data ./OBS.app/Contents/Resources
2019-12-10 19:31:54 +00:00
cp ../CI/install/osx/obs.icns ./OBS.app/Contents/Resources
2020-03-25 08:07:22 +00:00
cp -R rundir/RelWithDebInfo/obs-plugins/ ./OBS.app/Contents/PlugIns
2019-12-10 19:31:54 +00:00
cp ../CI/install/osx/Info.plist ./OBS.app/Contents
../CI/install/osx/dylibBundler -b -cd -d ./OBS.app/Contents/Frameworks -p @executable_path/../Frameworks/ \
-s ./OBS.app/Contents/MacOS \
-s /usr/local/opt/mbedtls/lib/ \
2020-03-25 08:07:22 +00:00
-x ./OBS.app/Contents/PlugIns/coreaudio-encoder.so \
-x ./OBS.app/Contents/PlugIns/decklink-ouput-ui.so \
-x ./OBS.app/Contents/PlugIns/frontend-tools.so \
-x ./OBS.app/Contents/PlugIns/image-source.so \
-x ./OBS.app/Contents/PlugIns/linux-jack.so \
-x ./OBS.app/Contents/PlugIns/mac-avcapture.so \
-x ./OBS.app/Contents/PlugIns/mac-capture.so \
-x ./OBS.app/Contents/PlugIns/mac-decklink.so \
-x ./OBS.app/Contents/PlugIns/mac-syphon.so \
-x ./OBS.app/Contents/PlugIns/mac-vth264.so \
-x ./OBS.app/Contents/PlugIns/obs-browser.so \
-x ./OBS.app/Contents/PlugIns/obs-browser-page \
-x ./OBS.app/Contents/PlugIns/obs-ffmpeg.so \
-x ./OBS.app/Contents/PlugIns/obs-filters.so \
-x ./OBS.app/Contents/PlugIns/obs-transitions.so \
-x ./OBS.app/Contents/PlugIns/obs-vst.so \
-x ./OBS.app/Contents/PlugIns/rtmp-services.so \
2019-12-10 19:31:54 +00:00
-x ./OBS.app/Contents/MacOS/obs \
-x ./OBS.app/Contents/MacOS/obs-ffmpeg-mux \
-x ./OBS.app/Contents/MacOS/obslua.so \
2020-03-25 08:07:22 +00:00
-x ./OBS.app/Contents/PlugIns/obs-x264.so \
-x ./OBS.app/Contents/PlugIns/text-freetype2.so \
-x ./OBS.app/Contents/PlugIns/obs-libfdk.so
2020-10-01 20:15:25 +00:00
# -x ./OBS.app/Contents/MacOS/_obspython.so \
2020-03-25 08:07:22 +00:00
# -x ./OBS.app/Contents/PlugIns/obs-outputs.so \
2019-12-10 19:31:54 +00:00
2020-03-25 08:07:22 +00:00
/usr/local/Cellar/qt/5.14.1/bin/macdeployqt ./OBS.app
2019-12-10 19:31:54 +00:00
mv ./OBS.app/Contents/MacOS/libobs-opengl.so ./OBS.app/Contents/Frameworks
2020-03-25 08:07:22 +00:00
rm -f -r ./OBS.app/Contents/Frameworks/QtNetwork.framework
2019-12-10 19:31:54 +00:00
# put qt network in here becasuse streamdeck uses it
2019-12-24 09:07:22 +00:00
cp -R /usr/local/opt/qt/lib/QtNetwork.framework ./OBS.app/Contents/Frameworks
chmod -R +w ./OBS.app/Contents/Frameworks/QtNetwork.framework
rm -r ./OBS.app/Contents/Frameworks/QtNetwork.framework/Headers
rm -r ./OBS.app/Contents/Frameworks/QtNetwork.framework/Versions/5/Headers/
chmod 644 ./OBS.app/Contents/Frameworks/QtNetwork.framework/Versions/5/Resources/Info.plist
install_name_tool -id @executable_path/../Frameworks/QtNetwork.framework/Versions/5/QtNetwork ./OBS.app/Contents/Frameworks/QtNetwork.framework/Versions/5/QtNetwork
2020-03-25 08:07:22 +00:00
install_name_tool -change /usr/local/Cellar/qt/5.14.1/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/Frameworks/QtNetwork.framework/Versions/5/QtNetwork
2019-12-10 19:31:54 +00:00
2019-12-24 09:07:22 +00:00
2019-12-10 19:31:54 +00:00
# decklink ui qt
2020-03-25 08:07:22 +00:00
install_name_tool -change /usr/local/opt/qt/lib/QtGui.framework/Versions/5/QtGui @executable_path/../Frameworks/QtGui.framework/Versions/5/QtGui ./OBS.app/Contents/PlugIns/decklink-ouput-ui.so
install_name_tool -change /usr/local/opt/qt/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/PlugIns/decklink-ouput-ui.so
install_name_tool -change /usr/local/opt/qt/lib/QtWidgets.framework/Versions/5/QtWidgets @executable_path/../Frameworks/QtWidgets.framework/Versions/5/QtWidgets ./OBS.app/Contents/PlugIns/decklink-ouput-ui.so
2019-12-10 19:31:54 +00:00
# frontend tools qt
2020-03-25 08:07:22 +00:00
install_name_tool -change /usr/local/opt/qt/lib/QtGui.framework/Versions/5/QtGui @executable_path/../Frameworks/QtGui.framework/Versions/5/QtGui ./OBS.app/Contents/PlugIns/frontend-tools.so
install_name_tool -change /usr/local/opt/qt/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/PlugIns/frontend-tools.so
install_name_tool -change /usr/local/opt/qt/lib/QtWidgets.framework/Versions/5/QtWidgets @executable_path/../Frameworks/QtWidgets.framework/Versions/5/QtWidgets ./OBS.app/Contents/PlugIns/frontend-tools.so
2019-12-10 19:31:54 +00:00
# vst qt
2020-03-25 08:07:22 +00:00
install_name_tool -change /usr/local/opt/qt/lib/QtGui.framework/Versions/5/QtGui @executable_path/../Frameworks/QtGui.framework/Versions/5/QtGui ./OBS.app/Contents/PlugIns/obs-vst.so
install_name_tool -change /usr/local/opt/qt/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/PlugIns/obs-vst.so
install_name_tool -change /usr/local/opt/qt/lib/QtWidgets.framework/Versions/5/QtWidgets @executable_path/../Frameworks/QtWidgets.framework/Versions/5/QtWidgets ./OBS.app/Contents/PlugIns/obs-vst.so
install_name_tool -change /usr/local/opt/qt/lib/QtMacExtras.framework/Versions/5/QtMacExtras @executable_path/../Frameworks/QtMacExtras.framework/Versions/5/QtMacExtras ./OBS.app/Contents/PlugIns/obs-vst.so