如何调试通过 Flatpak 安装的 Qt 应用程序

如何调试通过 Flatpak 安装的 Qt 应用程序

我正在尝试为通过 Flatpak 安装的 QOwnNotes 应用程序启用调试(遵循本教程:调试 Flatpak 应用程序)。

我已经安装了应用程序本身并为其 Sdk 和本身调试了部分:

$ flatpak install flathub org.qownnotes.QOwnNotes
$ flatpak install flathub org.qownnotes.QOwnNotes.Debug
$ flatpak install flathub org.kde.Sdk.Debug//5.14

然后启动应用程序:

$ flatpak run --command=sh --devel org.qownnotes.QOwnNotes

并通过以下方式运行它gdb

sh-5.0$ gdb /app/bin/QOwnNotes 
GNU gdb (GDB) 8.3.1
Copyright (C) 2019 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /app/bin/QOwnNotes...
(No debugging symbols found in /app/bin/QOwnNotes)
(gdb) r
Starting program: /app/bin/QOwnNotes 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff27be700 (LWP 9)]
[Detaching after fork from child process 10]

但它无法找到调试符号。

相关内容