All of lore.kernel.org
 help / color / mirror / Atom feed
From: Darren Hart <dvhart@linux.intel.com>
To: Khem Raj <raj.khem@gmail.com>
Cc: Yocto Project <yocto@yoctoproject.org>
Subject: Re: Debug with gdbserver
Date: Tue, 31 Jul 2012 20:47:47 -0700	[thread overview]
Message-ID: <5018A6E3.1020704@linux.intel.com> (raw)
In-Reply-To: <C4B37B65-466E-4F99-8904-C12877973E20@gmail.com>



On 07/31/2012 08:13 PM, Khem Raj wrote:
> 
> On Jul 31, 2012, at 7:46 PM, Darren Hart <dvhart@linux.intel.com> wrote:
> 
>> I am trying to debug a userpsace application that misbehaves under
>> poky-tiny. My current approach is use gdbserver on the target and attach
>> to the offending process, then connect to it on the client using the
>> yocto-built native gdb for the target.
>>
>> I can easily add gdbserver to the target image, and can successfully
>> connect it to the process:
>>
>> # From the target (qemux86) root shell:
>> # dropbearkey -t rsa -f ./rsa
>> # dropbear -r ./rsa
>> # DBPID=$(ps | grep dropbear | head -n1 | cut -f4 -d ' ')
>> # gdbserver 127.0.0.1:1234 --attach $DBPID
>>
>> Now on the host machine (amd64) I want to:
>> $ gdb????
>> (gdb) target extended-remote 127.0.0.1:1234
>>
>> Which package do I need to build to get the appropriate gdb for the host
>> to remote debug processes on the target?
> 
> bake cross-gdb for your arch and use it same way as above

ERROR: Nothing PROVIDES 'cross-gdb'

gdb-cross maybe?

Ah that gets a lot farther... and then do_compile fails.

| libgdb.a(python.o): In function `gdbpy_target_wide_charset':
| python.c:(.text+0x1c7): undefined reference to `PyUnicodeUCS4_Decode'

And a lot more similar to that. I'm doing this on poky-tiny (so a
minimal target libc... shouldn't impact native bits though right?


Will beat on it some more in the morning.

-- 
Darren Hart
Intel Open Source Technology Center
Yocto Project - Technical Lead - Linux Kernel


  reply	other threads:[~2012-08-01  3:49 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-01  2:46 Debug with gdbserver Darren Hart
2012-08-01  3:13 ` Khem Raj
2012-08-01  3:47   ` Darren Hart [this message]
2012-08-01  4:55     ` Khem Raj
2012-08-01  6:15     ` Martin Jansa
2012-08-01 16:22       ` Darren Hart
2012-08-01 17:09         ` Khem Raj
2012-08-01 17:16           ` Darren Hart
2012-08-01 22:34             ` Khem Raj
2012-08-01 22:35               ` Darren Hart

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5018A6E3.1020704@linux.intel.com \
    --to=dvhart@linux.intel.com \
    --cc=raj.khem@gmail.com \
    --cc=yocto@yoctoproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.