diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2020-06-04 08:48:26 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2020-06-04 10:33:59 +0200 |
commit | c9bc4f1eec5d66db36b6f9d845eb1a2d46e732bb (patch) | |
tree | 60a6d69d5e019835690febda4b1680d699797afe /solenv | |
parent | ea59cd05e84849c3fde514b7070081af4a052360 (diff) |
Print out the guessed executable name that is actually passed to the debugger
...to avoid confusion, when the log reads e.g.
[...]
> It looks like /home/tdf/lode/jenkins/workspace/lo_tb_master_linux_dbg/instdir/program/soffice.bin generated /home/tdf/lode/jenkins/workspace/lo_tb_master_linux_dbg/workdir/UITest/calc_demo/done.core/core.10572
[...]
> Core was generated by `/home/tdf/lode/jenkins/workspace/lo_tb_master_linux_dbg/instdir/program/python.'.
[...]
(<https://ci.libreoffice.org/job/lo_tb_master_linux_dbg/29831/>).
Change-Id: I59f544c6739329620064315c2a54c21e29865b68
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95480
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'solenv')
-rwxr-xr-x | solenv/bin/gdb-core-bt.sh | 10 | ||||
-rwxr-xr-x | solenv/bin/lldb-core-bt.sh | 6 |
2 files changed, 8 insertions, 8 deletions
diff --git a/solenv/bin/gdb-core-bt.sh b/solenv/bin/gdb-core-bt.sh index 2216e2aba5e5..b48a5a4405cc 100755 --- a/solenv/bin/gdb-core-bt.sh +++ b/solenv/bin/gdb-core-bt.sh @@ -20,15 +20,15 @@ then do if [ -f "$COREFILE" ] then - printf '\nIt looks like %s generated %s\nBacktraces:\n' \ - "$EXECUTABLE" "$COREFILE" - GDBCOMMANDFILE=$(mktemp) - printf "info registers\nthread apply all backtrace full\n" \ - >"$GDBCOMMANDFILE" guess=$(file "$COREFILE") guess=${guess#* execfn: \'} guess=${guess%%\'*} if [ ! -x "$guess" ]; then guess=$EXECUTABLE; fi + printf '\nIt looks like %s generated %s\nBacktraces:\n' \ + "$guess" "$COREFILE" + GDBCOMMANDFILE=$(mktemp) + printf "info registers\nthread apply all backtrace full\n" \ + >"$GDBCOMMANDFILE" gdb -iex "add-auto-load-safe-path ${INSTDIR?}" -x "$GDBCOMMANDFILE" --batch "$guess" \ "$COREFILE" && found=x rm "$GDBCOMMANDFILE" diff --git a/solenv/bin/lldb-core-bt.sh b/solenv/bin/lldb-core-bt.sh index 2bd982ec21e9..def4a8939db0 100755 --- a/solenv/bin/lldb-core-bt.sh +++ b/solenv/bin/lldb-core-bt.sh @@ -20,13 +20,13 @@ then do if [ -f "$COREFILE" ] then - printf '\nIt looks like %s generated %s\nBacktraces:\n' \ - "$EXECUTABLE" "$COREFILE" - $LLDBCOMMANDFILE=$(mktemp) guess=$(file "$COREFILE") guess=${guess#* execfn: \'} guess=${guess%%\'*} if [ ! -x "$guess" ]; then guess=$EXECUTABLE; fi + printf '\nIt looks like %s generated %s\nBacktraces:\n' \ + "$guess" "$COREFILE" + $LLDBCOMMANDFILE=$(mktemp) printf "target create -c $COREFILE $guess\nthread backtrace all\nquit\n" >"$LLDBCOMMANDFILE" lldb -s "$LLDBCOMMANDFILE" --batch \ && found=x |