docs: add debug build (#31979)
* docs: add debug build * docs: move debug config document to debugging.md * fix: debug.gn import failed * docs: modify debug.gn folder on doc * docs: imporve gn import path
This commit is contained in:
parent
3d34fd7c91
commit
bc8cfbac59
1 changed files with 22 additions and 0 deletions
|
@ -35,6 +35,28 @@ base::debug::StackTrace().Print();
|
||||||
|
|
||||||
This will allow you to observe call chains and identify potential issue areas.
|
This will allow you to observe call chains and identify potential issue areas.
|
||||||
|
|
||||||
|
## Breakpoint Debugging
|
||||||
|
|
||||||
|
> Note that this will increase the size of the build significantly, taking up around 50G of disk space
|
||||||
|
|
||||||
|
Write the following file to `electron/.git/info/exclude/debug.gn`
|
||||||
|
|
||||||
|
```gn
|
||||||
|
import("//electron/build/args/testing.gn")
|
||||||
|
is_debug = true
|
||||||
|
symbol_level = 2
|
||||||
|
forbid_non_component_debug_builds = false
|
||||||
|
```
|
||||||
|
|
||||||
|
Then execute:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
$ gn gen out/Debug --args="import(\"//electron/.git/info/exclude/debug.gn\") $GN_EXTRA_ARGS"
|
||||||
|
$ ninja -C out/Debug electron
|
||||||
|
```
|
||||||
|
|
||||||
|
Now you can use `LLDB` for breakpoint debugging.
|
||||||
|
|
||||||
## Platform-Specific Debugging
|
## Platform-Specific Debugging
|
||||||
<!-- TODO(@codebytere): add debugging file for Linux-->
|
<!-- TODO(@codebytere): add debugging file for Linux-->
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue