CI: Compress Linux/macOS debug files

Installs Intel IPP on Ubuntu and macOS runners
Updates boo to fix FindIPP for new *nix path
This commit is contained in:
Luke Street 2021-04-07 12:39:26 -04:00
parent 3b59eac508
commit 4247e38349
5 changed files with 46 additions and 20 deletions

View File

@ -32,13 +32,18 @@ jobs:
- name: Install dependencies - name: Install dependencies
run: | run: |
sudo apt-get update wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
rm GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
sudo add-apt-repository "deb https://apt.repos.intel.com/oneapi all main"
sudo apt-get -y install build-essential curl git cmake ninja-build llvm-dev libclang-dev clang lld \ sudo apt-get -y install build-essential curl git cmake ninja-build llvm-dev libclang-dev clang lld \
zlib1g-dev libglu1-mesa-dev libdbus-1-dev libvulkan-dev libxi-dev libxrandr-dev libasound2-dev \ zlib1g-dev libglu1-mesa-dev libdbus-1-dev libvulkan-dev libxi-dev libxrandr-dev libasound2-dev \
libpulse-dev libudev-dev libpng-dev libncurses5-dev libx11-xcb-dev python3 python-is-python3 qt5-default \ libpulse-dev libudev-dev libpng-dev libncurses5-dev libx11-xcb-dev python3 python-is-python3 qt5-default \
libcurl4-openssl-dev libcurl4-openssl-dev intel-oneapi-ipp-devel
yarn global add @sentry/cli yarn global add @sentry/cli
echo "$(yarn global bin)" >> $GITHUB_PATH echo "$(yarn global bin)" >> $GITHUB_PATH
# free up disk space # free up disk space
# https://github.com/actions/virtual-environments/issues/2840#issuecomment-790492173 # https://github.com/actions/virtual-environments/issues/2840#issuecomment-790492173
echo Before echo Before
@ -84,7 +89,7 @@ jobs:
name: metaforce-${{env.METAFORCE_VERSION}}-linux-${{matrix.cc}}-x86_64 name: metaforce-${{env.METAFORCE_VERSION}}-linux-${{matrix.cc}}-x86_64
path: | path: |
Metaforce-*.AppImage Metaforce-*.AppImage
build/Binaries/*.dbg debug.tar.*
build-macos: build-macos:
name: Build macOS (AppleClang x86_64) name: Build macOS (AppleClang x86_64)
@ -101,6 +106,17 @@ jobs:
brew link qt@5 brew link qt@5
yarn global add create-dmg yarn global add create-dmg
- name: Install Intel IPP
env:
IPP_VERSION: 2021.2.0.192
run: |
NAME="m_ipp_oneapi_p_${IPP_VERSION}_offline"
curl -LSfs https://registrationcenter-download.intel.com/akdlm/irc_nas/17606/$NAME.dmg -o /tmp/$NAME.dmg
sudo hdiutil attach /tmp/$NAME.dmg -quiet
sudo /Volumes/$NAME/bootstrapper.app/Contents/MacOS/install.sh -c --action install --eula accept
sudo hdiutil detach /Volumes/$NAME -quiet
rm /tmp/$NAME.dmg
- name: Create build directory - name: Create build directory
run: cmake -E make_directory ${{github.workspace}}/build run: cmake -E make_directory ${{github.workspace}}/build
@ -129,23 +145,20 @@ jobs:
keychain-password: ${{ secrets.MACOS_KEYCHAIN_PASSWORD }} keychain-password: ${{ secrets.MACOS_KEYCHAIN_PASSWORD }}
- name: Deploy & codesign application - name: Deploy & codesign application
working-directory: build/Binaries env:
run: | ASC_USERNAME: ${{secrets.MACOS_ASC_USERNAME}}
mv metaforce-gui.app Metaforce.app ASC_PASSWORD: ${{secrets.MACOS_ASC_PASSWORD}}
for i in visigen hecl metaforce crashpad_handler; do ASC_TEAM_ID: ${{secrets.MACOS_ASC_TEAM_ID}}
codesign --timestamp --options runtime -s "${{secrets.MACOS_CODESIGN_IDENT}}" Metaforce.app/Contents/MacOS/$i CODESIGN_IDENT: ${{secrets.MACOS_CODESIGN_IDENT}}
done run: ci/build-dmg.sh
macdeployqt Metaforce.app -sign-for-notarization="${{secrets.MACOS_CODESIGN_IDENT}}" -no-strip
create-dmg Metaforce.app --identity="${{secrets.MACOS_CODESIGN_IDENT}}"
xcrun altool -t osx -f *.dmg --primary-bundle-id com.axiodl.URDE --notarize-app \
-u "${{secrets.MACOS_ASC_USERNAME}}" -p "${{secrets.MACOS_ASC_PASSWORD}}" \
--team-id "${{secrets.MACOS_ASC_TEAM_ID}}"
- name: Upload artifacts - name: Upload artifacts
uses: actions/upload-artifact@v2 uses: actions/upload-artifact@v2
with: with:
name: metaforce-${{env.METAFORCE_VERSION}}-macos-appleclang-x86_64 name: metaforce-${{env.METAFORCE_VERSION}}-macos-appleclang-x86_64
path: build/Binaries/*.dmg path: |
Metaforce *.dmg
debug.tar.*
build-windows-msvc: build-windows-msvc:
name: Build Windows (MSVC x86_64) name: Build Windows (MSVC x86_64)
@ -275,7 +288,7 @@ jobs:
# $TempDir = "$env:RUNNER_WORKSPACE\temp" # $TempDir = "$env:RUNNER_WORKSPACE\temp"
# $Filename = "w_ipp_oneapi_p_${env:IPP_VERSION}_offline.exe" # $Filename = "w_ipp_oneapi_p_${env:IPP_VERSION}_offline.exe"
# New-Item -Path "$TempDir" -ItemType Directory -ea 0 # New-Item -Path "$TempDir" -ItemType Directory -ea 0
# (New-Object Net.WebClient).DownloadFile("https://registrationcenter-download.intel.com/akdlm/irc_nas/$Filename", "$TempDir\$Filename") # (New-Object Net.WebClient).DownloadFile("https://registrationcenter-download.intel.com/akdlm/irc_nas/17739/$Filename", "$TempDir\$Filename")
# Start-Process "$TempDir\$Filename" -ArgumentList "--x --s --f $TempDir\ipp" -Wait # Start-Process "$TempDir\$Filename" -ArgumentList "--x --s --f $TempDir\ipp" -Wait
# Start-Process "$TempDir\ipp\bootstrapper.exe" -ArgumentList "--eula accept -c --action install" -Wait # Start-Process "$TempDir\ipp\bootstrapper.exe" -ArgumentList "--eula accept -c --action install" -Wait

11
ci/build-dmg.sh Normal file
View File

@ -0,0 +1,11 @@
#!/bin/bash -ex
cd build/Binaries
mv metaforce-gui.app Metaforce.app
# order is important
for i in visigen hecl metaforce crashpad_handler; do
codesign --timestamp --options runtime -s "$CODESIGN_IDENT" Metaforce.app/Contents/MacOS/$i
done
macdeployqt Metaforce.app -sign-for-notarization="$CODESIGN_IDENT" -no-strip
create-dmg Metaforce.app --identity="$CODESIGN_IDENT" "$GITHUB_WORKSPACE"
xcrun altool -t osx -f "$GITHUB_WORKSPACE"/*.dmg --primary-bundle-id com.axiodl.URDE --notarize-app \
-u "$ASC_USERNAME" -p "$ASC_PASSWORD" --team-id "$ASC_TEAM_ID"

View File

@ -1,6 +1,7 @@
#!/bin/bash -ex #!/bin/bash -ex
cd build/Binaries cd build/Binaries
for f in hecl metaforce-gui metaforce visigen; do for f in hecl metaforce-gui metaforce visigen; do
objcopy --only-keep-debug --compress-debug-sections=zlib $f $f.dbg objcopy --only-keep-debug $f $f.dbg
objcopy --strip-debug --add-gnu-debuglink=$f.dbg $f objcopy --strip-debug --add-gnu-debuglink=$f.dbg $f
done done
tar acfv "$GITHUB_WORKSPACE"/debug.tar.xz -- *.dbg

View File

@ -2,7 +2,8 @@
cd build/Binaries/metaforce-gui.app/Contents/MacOS cd build/Binaries/metaforce-gui.app/Contents/MacOS
for f in hecl metaforce-gui metaforce visigen; do for f in hecl metaforce-gui metaforce visigen; do
dsymutil $f dsymutil $f
strip -S $f
done done
strip -S hecl metaforce-gui metaforce visigen crashpad_handler
sentry-cli upload-dif --org axiodl --project metaforce {hecl,metaforce-gui,metaforce,visigen}{,.dSYM} --include-sources sentry-cli upload-dif --org axiodl --project metaforce {hecl,metaforce-gui,metaforce,visigen}{,.dSYM} --include-sources
tar acfv "$GITHUB_WORKSPACE"/debug.tar.xz -- *.dSYM
rm -r -- *.dSYM rm -r -- *.dSYM

2
extern/boo vendored

@ -1 +1 @@
Subproject commit fa89c9c1380bb8b5bfee329e45ede41c86e7c825 Subproject commit 6335cb09fe5046984e8baa9b5a65de837037e70c