Add documentation regarding how to build Ruby for debugging. (#8290)
Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
This commit is contained in:
parent
439f069b4b
commit
b2d1c720ec
Notes:
git
2023-08-25 22:00:08 +00:00
Merged-By: ioquatix <samuel@codeotaku.com>
@ -157,6 +157,14 @@ with the Ruby script you'd like to run. You can use the following make targets:
|
||||
* `make lldb-ruby`: Runs `test.rb` using Ruby in lldb
|
||||
* `make gdb-ruby`: Runs `test.rb` using Ruby in gdb
|
||||
|
||||
### Compiling for Debugging
|
||||
|
||||
You should configure Ruby without optimization and other flags that may interfere with debugging:
|
||||
|
||||
``` shell
|
||||
./configure --enable-debug-env optflags="-O0 -fno-omit-frame-pointer"
|
||||
```
|
||||
|
||||
### Building with Address Sanitizer
|
||||
|
||||
Using the address sanitizer is a great way to detect memory issues.
|
||||
|
Loading…
x
Reference in New Issue
Block a user