Wind River Support Network

HomeDefectsLIN9-3121
Fixed

LIN9-3121 : feature/gdb: gdb cannot find source on target

Created: Jan 30, 2017    Updated: Dec 3, 2018
Resolved Date: Feb 6, 2017
Found In Version: unknown
Fix Version: 9.0.0.3
Severity: Standard
Applicable for: Wind River Linux 9
Component/s: Build & Config

Description

Steps to reproduce: 

1) setup with: 
 --machines=intel-x86-64 --kernel=standard --dl-layers --templates feature/gdb

2) . ./environment-setup-x86_64-wrlinuxsdk-linux 

3) . ./oe-init-build-env build_test 

4) add the following in local.conf:
DEBUG_BUILD = "1" 
EXTRA_IMAGE_FEATURES_append = " dbg-pkgs" 

5) 
Start target and use gdb to debug something -- python is an example. 
When it hits a breakpoint at "main", you will not be able to display source.

When running gdb on a target, the sources files for an object cannot be found without running set substitute-path in gdb. 

Workaround

In gdb:
set substitute-path <where-build-was>/tmp/work/<arch> /usr/src/debug

Steps to Reproduce

build glibc-std image setting at the end of local.conf:

DEBUG_BUILD = "1"
WRTEMPLATE_append = " feature/gdb"
EXTRA_IMAGE_FEATURES_append = " dbg-pkgs"

Start target and use gdb to debug something -- python is an example.
When it hits a breakpoint at "main", you will not be able to display source.

Other Downloads


Live chat
Online