diff options
| author | Matt Valentine-House <matt@eightbitraptor.com> | 2024-06-10 16:41:12 +0100 |
|---|---|---|
| committer | Matt Valentine-House <matt@eightbitraptor.com> | 2024-06-11 14:03:58 +0100 |
| commit | ad9fe6f3765007477364479ad6ebbe1099108293 (patch) | |
| tree | b44dd4b21e70f65023207d52d4213512dc9174cb /include/ruby | |
| parent | 47322b592a0d75477a65e6e4ddaed2eb6549c32c (diff) | |
Allow gdb to search source path for required files
When doing out-of-source builds I often end up wanting to use gdb from
inside a build directory.
Currently if I do that the `.gdbinit` in the ruby source directory is
not read.
Attempting to manually load the `.gdbinit` from the Ruby source
directory errors because of hard coded file-paths that assume we're
running gdb from inside the source tree.
Adding the `-s` flag to the `source` command when loading relative files
signals to gdb to search in the source search path for the required
file, rather than just the current directory.
This allows me to use a custom `.gdbinit` from my build directory that
sets the correct source directory and then loads the Ruby `.gdbinit`.
```
dir ../src
source ../src/.gdbinit
```
Diffstat (limited to 'include/ruby')
0 files changed, 0 insertions, 0 deletions
