diff options
author | ion- <itornaza@gmail.com> | 2024-09-07 15:06:49 +0300 |
---|---|---|
committer | ion- <itornaza@gmail.com> | 2024-09-08 18:29:01 +0300 |
commit | 0b003e1ff7e09b56cd013b15f1998495994b7211 (patch) | |
tree | 49f8c19bc48030b11085cca87914f2889f72e720 /doc | |
parent | a5fa90706addb3ebc4325b139cfebcf9d7ac3045 (diff) |
docs: Updated debug build instructions for cmake
Diffstat (limited to 'doc')
-rw-r--r-- | doc/developer-notes.md | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/doc/developer-notes.md b/doc/developer-notes.md index ae5513a222..19d32ca8ff 100644 --- a/doc/developer-notes.md +++ b/doc/developer-notes.md @@ -354,8 +354,14 @@ Development tips and tricks ### Compiling for debugging -Run configure with `--enable-debug` to add additional compiler flags that -produce better debugging builds. +When using the default build configuration by running `cmake -B build`, the +`-DCMAKE_BUILD_TYPE` is set to `RelWithDebInfo`. This option adds debug symbols +but also performs some compiler optimizations that may make debugging trickier +as the code may not correspond directly to the source. + +If you need to build exclusively for debugging, set the `-DCMAKE_BUILD_TYPE` +to `Debug` (i.e. `-DCMAKE_BUILD_TYPE=Debug`). You can always check the cmake +build options of an existing build with `ccmake build`. ### Show sources in debugging |