CI: Fix debug info for Linux & Windows

This commit is contained in:
Luke Street 2021-04-07 11:12:50 -04:00
parent 87dc66625c
commit ff528f1fa6
4 changed files with 11 additions and 7 deletions

View File

@ -65,6 +65,9 @@ jobs:
working-directory: ${{github.workspace}}/build
run: cmake --build .
- name: Split debug information
run: ci/split-debug-linux.sh
- name: Upload debug information
if: ${{matrix.name == 'Clang'}}
env:
@ -214,6 +217,7 @@ jobs:
run: cmake --build .
- name: Upload debug information
working-directory: ${{github.workspace}}/build/Binaries
env:
SENTRY_AUTH_TOKEN: ${{secrets.SENTRY_AUTH_TOKEN}}
SENTRY_URL: ${{secrets.SENTRY_URL}}

View File

@ -8,7 +8,6 @@ chmod +x linuxdeploy-$(uname -m).AppImage linuxdeploy-plugin-qt-$(uname -m).AppI
# Build AppImage
mkdir -p appdir/usr/{bin,share/{applications,icons/hicolor}}
cp build/Binaries/{hecl,metaforce-gui,metaforce,visigen} appdir/usr/bin
strip -S appdir/usr/bin/{hecl,metaforce-gui,metaforce,visigen}
cp -r metaforce-gui/platforms/freedesktop/{16x16,32x32,48x48,64x64,128x128,256x256,512x512,1024x1024} appdir/usr/share/icons/hicolor
cp metaforce-gui/platforms/freedesktop/metaforce.desktop appdir/usr/share/applications
VERSION="$METAFORCE_VERSION" ./linuxdeploy-$(uname -m).AppImage --appdir appdir --plugin qt --output appimage
VERSION="$METAFORCE_VERSION" NO_STRIP=1 ./linuxdeploy-$(uname -m).AppImage --appdir appdir --plugin qt --output appimage

6
ci/split-debug-linux.sh Executable file
View File

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

View File

@ -1,7 +1,2 @@
#!/bin/bash -ex
cd build/Binaries
for f in hecl metaforce-gui metaforce visigen; do
objcopy --only-keep-debug --compress-debug-sections=zlib $f $f.dbg
done
strip -S hecl metaforce-gui metaforce visigen
sentry-cli upload-dif --org axiodl --project metaforce {hecl,metaforce-gui,metaforce,visigen}{,.dbg} --include-sources