Skip to content

Commit c3b96fa

Browse files
committed
docs: debugging
1 parent 603ffe0 commit c3b96fa

File tree

2 files changed

+22
-6
lines changed

2 files changed

+22
-6
lines changed
19.2 KB
Loading

docs/src/content/docs/debugging.mdx

Lines changed: 22 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,30 @@ hide_title: true
55

66
import { Advanced, Charts, Details, Modal, Steps, Tabs, TabItem, Card, CardGrid, LinkCard, Aside, Icon } from "/src/components/global.jsx"
77

8-
To properly debug a segfault the build will need to have been built with libtorrent and qbitorrent debug symbols.
8+
:::note
9+
By default the static builds are built with the debug symbols stripped out to reduce the file size.
10+
:::
911

10-
One of the issues here is that with the static build the libtorrent debug symbols can add 100MB to the file size.
12+
To properly debug a segfault we need to use a build with libtorrent and qBittorrent debug symbols included.
1113

12-
This can be done using the `-d` flag or `export qbt_build_debug=on`.
14+
Some reasons I don't release them here:
15+
- static builds using `b2` the libtorrent debug symbols can add 100MB to the file size.
16+
- static builds using `cmake` are about 15MB larger and potentially slower.
17+
- It doubles the build time.
18+
- It's not needed for most users.
1319

14-
The easiest way to get this is to fork the repo - https://github.com/userdocs/qbittorrent-nox-static/fork
20+
The easiest way to get a debug build is to build it yourself by
1521

16-
Then use the `matrix_multi_build_and_release_qbt_workflow_files_debug.yml` via the actions section of your fork and it will build the debug version for you and upload it to the releases section of your fork.
22+
- [forking the repo](https://github.com/userdocs/qbittorrent-nox-static/fork) the repo and running the `ci-main-reusable-caller.yml` workflow with the debug flag enabled.
1723

18-
Then you can download the debug version and use it to debug the segfault.
24+
![](/qbittorrent-nox-static/docs_images/reusable_workflow_inputs-debug.png)
25+
26+
:::tip
27+
The builds will be uploaded as artifacts to the workflow run and can be downloaded from there.
28+
:::
29+
30+
- Build it yourself locally
31+
32+
This can be done when building locally by using the `-d` flag or `export qbt_build_debug=on`
33+
34+
Then you will have a debug build with the debug symbols included to get a stack traces using [gdb](https://www.gnu.org/software/gdb/).

0 commit comments

Comments
 (0)