File tree Expand file tree Collapse file tree 2 files changed +32
-0
lines changed
Expand file tree Collapse file tree 2 files changed +32
-0
lines changed Original file line number Diff line number Diff line change @@ -227,6 +227,10 @@ jobs:
227227 run : |
228228 cmake --install build --prefix install --config ${{ needs.meta.outputs.build-config }}
229229
230+ if [[ ${{ needs.meta.outputs.build-config }} == RelWithDebInfo ]]; then
231+ tools/split-linux-debug.sh install
232+ fi
233+
230234 cp -r docs install
231235 cp README*.md install
232236
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ INSTALL_PREFIX=$1
4+
5+ if ! [[ -d " $INSTALL_PREFIX " ]]; then
6+ echo " Usage: $0 [install prefix]"
7+ exit 1
8+ fi
9+
10+ INSTALL_PREFIX=` realpath " $INSTALL_PREFIX " `
11+
12+ cd ` dirname " $0 " /..`
13+ PATH=" ` pwd` /source/MaaUtils/MaaDeps/x-tools/llvm/bin:$PATH "
14+
15+ mkdir -p " $INSTALL_PREFIX /symbols"
16+ find $INSTALL_PREFIX /bin -type f | while read BINARY; do
17+ echo " Process $BINARY "
18+ FILE=` basename " $BINARY " `
19+ DEBUG_FILE=" $INSTALL_PREFIX /symbols/$FILE .debug"
20+
21+ cd ` dirname " $BINARY " `
22+
23+ llvm-objcopy --only-keep-debug " $BINARY " " $BINARY .debug"
24+ llvm-objcopy --add-gnu-debuglink=$FILE .debug --strip-unneeded " $BINARY "
25+ mv " $BINARY .debug" " $DEBUG_FILE "
26+
27+ cd - > /dev/null
28+ done
You can’t perform that action at this time.
0 commit comments