2022-01-05 08:32:13 +00:00
|
|
|
#!/bin/sh -ex
|
|
|
|
|
|
|
|
cd build || exit 1
|
|
|
|
|
|
|
|
# Gather explicit version number and number of commits
|
|
|
|
COMM_TAG=$(awk '/version{.*}/ { printf("%d.%d.%d", $5, $6, $7) }' ../rpcs3/rpcs3_version.cpp)
|
|
|
|
COMM_COUNT=$(git rev-list --count HEAD)
|
|
|
|
COMM_HASH=$(git rev-parse --short=8 HEAD)
|
|
|
|
|
|
|
|
AVVER="${COMM_TAG}-${COMM_COUNT}"
|
|
|
|
|
|
|
|
# AVVER is used for GitHub releases, it is the version number.
|
|
|
|
echo "AVVER=$AVVER" >> ../.ci/ci-vars.env
|
|
|
|
|
|
|
|
cd bin
|
|
|
|
mkdir "rpcs3.app/Contents/lib/"
|
2023-01-21 20:21:41 +00:00
|
|
|
|
2023-07-03 07:24:04 +00:00
|
|
|
cp "/usr/local/opt/llvm@16/lib/c++/libc++abi.1.0.dylib" "rpcs3.app/Contents/lib/libc++abi.1.dylib"
|
2023-08-29 02:18:36 +00:00
|
|
|
cp "$(realpath /usr/local/lib/libsharpyuv.0.dylib)" "rpcs3.app/Contents/lib/libsharpyuv.0.dylib"
|
|
|
|
cp "$(realpath /usr/local/lib/libintl.8.dylib)" "rpcs3.app/Contents/lib/libintl.8.dylib"
|
2023-01-21 20:21:41 +00:00
|
|
|
|
2022-01-05 08:32:13 +00:00
|
|
|
rm -rf "rpcs3.app/Contents/Frameworks/QtPdf.framework" \
|
|
|
|
"rpcs3.app/Contents/Frameworks/QtQml.framework" \
|
|
|
|
"rpcs3.app/Contents/Frameworks/QtQmlModels.framework" \
|
|
|
|
"rpcs3.app/Contents/Frameworks/QtQuick.framework" \
|
|
|
|
"rpcs3.app/Contents/Frameworks/QtVirtualKeyboard.framework" \
|
|
|
|
"rpcs3.app/Contents/Plugins/platforminputcontexts" \
|
2023-04-30 11:39:40 +00:00
|
|
|
"rpcs3.app/Contents/Plugins/virtualkeyboard" \
|
|
|
|
"rpcs3.app/Contents/Resources/git"
|
2022-01-05 08:32:13 +00:00
|
|
|
|
|
|
|
# Need to do this rename hack due to case insensitive filesystem
|
|
|
|
mv rpcs3.app RPCS3_.app
|
|
|
|
mv RPCS3_.app RPCS3.app
|
|
|
|
|
|
|
|
echo "[InternetShortcut]" > Quickstart.url
|
|
|
|
echo "URL=https://rpcs3.net/quickstart" >> Quickstart.url
|
|
|
|
echo "IconIndex=0" >> Quickstart.url
|
|
|
|
|
|
|
|
DMG_FILEPATH="$BUILD_ARTIFACTSTAGINGDIRECTORY/rpcs3-v${COMM_TAG}-${COMM_COUNT}-${COMM_HASH}_macos.dmg"
|
|
|
|
|
2023-01-21 20:21:41 +00:00
|
|
|
/opt/homebrew/bin/create-dmg --volname RPCS3 \
|
2022-01-05 08:32:13 +00:00
|
|
|
--window-size 800 400 \
|
|
|
|
--icon-size 100 \
|
|
|
|
--icon rpcs3.app 200 190 \
|
|
|
|
--add-file Quickstart.url Quickstart.url 400 20 \
|
|
|
|
--hide-extension rpcs3.app \
|
|
|
|
--hide-extension Quickstart.url \
|
|
|
|
--app-drop-link 600 185 \
|
|
|
|
--skip-jenkins \
|
2023-08-04 20:18:40 +00:00
|
|
|
--format ULMO \
|
2022-01-05 08:32:13 +00:00
|
|
|
"$DMG_FILEPATH" \
|
|
|
|
RPCS3.app
|
|
|
|
|
2023-01-21 20:21:41 +00:00
|
|
|
/opt/homebrew/bin/7z a -mx9 rpcs3-v"${COMM_TAG}"-"${COMM_COUNT}"-"${COMM_HASH}"_macos.7z RPCS3.app
|
2022-01-05 08:32:13 +00:00
|
|
|
|
|
|
|
FILESIZE=$(stat -f %z "$DMG_FILEPATH")
|
|
|
|
SHA256SUM=$(shasum -a 256 "$DMG_FILEPATH" | awk '{ print $1 }')
|
|
|
|
cd ..
|
|
|
|
echo "${SHA256SUM};${FILESIZE}B" > "$RELEASE_MESSAGE"
|
|
|
|
cd bin
|
|
|
|
|
|
|
|
mv ./rpcs3*_macos.7z "$ARTDIR"
|