[Buildroot] [PATCHv2 3/3] toolchain: mark sysroot as 'safe' path for gdb auto-load

Thomas Petazzoni thomas.petazzoni at bootlin.com
Sun Jul 25 21:23:11 UTC 2021


On Tue,  8 Jun 2021 17:18:39 +0200
Thomas De Schampheleire <patrickdepinguin at gmail.com> wrote:

> From: Thomas De Schampheleire <thomas.de_schampheleire at nokia.com>
> 
> gdb can automatically load certain files as described in [1]. Such files
> could install pretty-printers for complex data structures.
> 
> libstdcxx (C++ standard library) provided by gcc, is one example of a
> library for which such auto-load file is available. But there are other
> examples too, like libglib2.
> 
> However, gdb will only auto-load files if the file is located in one of the
> locations treated as 'safe'. The Buildroot sysroot is not by default in that
> list.
> 
> Provide a better debugging experience by adding the sysroot to the 'safe'
> list, via the gdbinit file prepared by Buildroot.
> 
> [1] https://sourceware.org/gdb/onlinedocs/gdb/objfile_002dgdbdotext-file.html
> 
> Signed-off-by: Thomas De Schampheleire <thomas.de_schampheleire at nokia.com>
> ---
>  toolchain/helpers.mk | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)

Applied to master, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com


More information about the buildroot mailing list