diff --git a/CI/before-deploy-osx.sh b/CI/before-deploy-osx.sh index 36dc78629..0e67b671a 100755 --- a/CI/before-deploy-osx.sh +++ b/CI/before-deploy-osx.sh @@ -1,18 +1,37 @@ # Exit if something fails set -e +# Generate file name variables export GIT_HASH=$(git rev-parse --short HEAD) export FILE_DATE=$(date +%Y-%m-%d.%H:%M:%S) export FILENAME=$FILE_DATE-$GIT_HASH-osx.pkg -mkdir nightly + cd ./build + +# Move the CEF plugin out before running build_app so that it doesn't get packaged twice mv ./rundir/RelWithDebInfo/obs-plugins/CEF.app ./ mv ./rundir/RelWithDebInfo/obs-plugins/obs-browser.so ./ -sudo python ../CI/install/osx/build_app.py + +# Package everything into a nice .app +sudo python ../CI/install/osx/build_app.py --public-key ../CI/install/osx/OBSPublicDSAKey.pem --sparkle-framework ../../sparkle/Sparkle.framework #--base-url=https://obsappcasturlhere + +# Move the CEF plugin back to where it belongs mv ./CEF.app ./rundir/RelWithDebInfo/obs-plugins/ mv ./obs-browser.so ./rundir/RelWithDebInfo/obs-plugins/ +# Package app packagesbuild ../CI/install/osx/CMakeLists.pkgproj -sudo cp OBS.pkg ./$FILENAME +# Signing stuff +openssl aes-256-cbc -K $encrypted_dd3c7f5e9db9_key -iv $encrypted_dd3c7f5e9db9_iv -in ../CI/osxcert/cert.p12.enc -out cert.p12 -d +openssl aes-256-cbc -K $encrypted_dd3c7f5e9db9_key -iv $encrypted_dd3c7f5e9db9_iv -in ../CI/osxcert/pk.p12.enc -out pk.p12 -d +security create-keychain -p mysecretpassword build.keychain +security default-keychain -s build.keychain +security unlock-keychain -p mysecretpassword build.keychain +security import cert.p12 -k build.keychain -T /usr/bin/codesign +security import pk.p12 -k build.keychain -T /usr/bin/codesign +productsign --sign 'Developer ID Installer: Hugh Bailey (2MMRE5MTB8)' ./OBS.pkg ./$FILENAME + +# Move to the folder that travis uses to upload artifacts from +mkdir ../nightly sudo mv ./$FILENAME ../nightly diff --git a/CI/install-dependencies-osx.sh b/CI/install-dependencies-osx.sh index 5d1b78665..a5e02e08b 100755 --- a/CI/install-dependencies-osx.sh +++ b/CI/install-dependencies-osx.sh @@ -6,6 +6,8 @@ git fetch --tags # Leave obs-studio folder cd ../ +# Install Packages app so we can build a package later +# http://s.sudre.free.fr/Software/Packages/about.html curl -L -O https://s3-us-west-2.amazonaws.com/obs-nightly/Packages.pkg -f --retry 5 -C - sudo installer -pkg ./Packages.pkg -target / @@ -14,12 +16,19 @@ brew update #Base OBS Deps brew install qt5 +# Fetch and untar prebuilt OBS deps that are compatible with older versions of OSX curl -L -O https://s3-us-west-2.amazonaws.com/obs-nightly/osx-deps.tar.gz -f --retry 5 -C - tar -xf ./osx-deps.tar.gz -C /tmp +# Fetch vlc codebase curl -L -o vlc-master.zip https://github.com/videolan/vlc/archive/master.zip -f --retry 5 -C - unzip -q ./vlc-master.zip +# Get sparkle +curl -L -o ./sparkle.tar.bz2 https://github.com/sparkle-project/Sparkle/releases/download/1.16.0/Sparkle-1.16.0.tar.bz2 +mkdir ./sparkle +tar -xf ./sparkle.tar.bz2 -C ./sparkle + # CEF Stuff curl -kLO http://opensource.spotify.com/cefbuilds/cef_binary_3.2883.1540.gedbfb20_macosx64.tar.bz2 -f --retry 5 -C - tar -xf ./cef_binary_3.2883.1540.gedbfb20_macosx64.tar.bz2 diff --git a/CI/osxcert/cert.p12.enc b/CI/osxcert/cert.p12.enc new file mode 100644 index 000000000..38a1ac2dd Binary files /dev/null and b/CI/osxcert/cert.p12.enc differ diff --git a/CI/osxcert/pk.p12.enc b/CI/osxcert/pk.p12.enc new file mode 100644 index 000000000..fe9bc1fcf Binary files /dev/null and b/CI/osxcert/pk.p12.enc differ