All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: Lennart Sorensen <lsorense@csclub.uwaterloo.ca>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai] How to get debug symbols in xenomai libraries
Date: Fri, 05 Sep 2014 23:17:32 +0200	[thread overview]
Message-ID: <540A286C.2050803@xenomai.org> (raw)
In-Reply-To: <20140905211515.GR17690@csclub.uwaterloo.ca>

On 09/05/2014 11:15 PM, Lennart Sorensen wrote:
> On Fri, Sep 05, 2014 at 11:04:35PM +0200, Gilles Chanteperdrix wrote:
>> On 09/05/2014 11:03 PM, Lennart Sorensen wrote:
>>> On Fri, Sep 05, 2014 at 10:57:10PM +0200, Gilles Chanteperdrix wrote:
>>>> On 09/05/2014 10:54 PM, Lennart Sorensen wrote:
>>>>> On Fri, Sep 05, 2014 at 10:31:35PM +0200, Gilles Chanteperdrix wrote:
>>>>>> Just tried a fresh build with minimal flags, simply:
>>>>>>
>>>>>> configure --enable-debug CFLAGS="-fomit-frame-pointer"
>>>>>> --host=arm-linux-gnueabihf
>>>>>> make
>>>>>> arm-linux-gnueabihf-gdb src/skins/common/.libs/libxenomai.so.0.0.0
>>>>>>
>>>>>> and gdb says it can find symbols. (-fomit-frame-pointer is needed with
>>>>>> the toolchain I use, otherwise gcc complains that it can not use the r7
>>>>>> register).
>>>>>
>>>>> I tried adding that option, and still gdb says no symbols.
>>>>>
>>>>> Toolchain is debian wheezy's gcc 4.6, and everything is natively compiled.
>>>>>
>>>>
>>>> Do you build the package manually, like I just did? Or do you use the
>>>> debian/rules stuff?
>>>
>>> I use the debian/rules, but I set DEB_CFLAGS_APPEND=-fomit-frame-pointer
>>> and I added --enable-debug to the configure line in debian/rules and I
>>> set DEB_BUILD_OPTIONS=nostrip
>>>
>> Could you try a manual build?
> 
> That makes installing such a pain and the gcc lines had all the right
> arguments (-g -fomit-frame-pointer etc).  And we did want to debug with
> as close to the normal runtime build as possible.
> 
You do not need to run "make install"
Just run configure --enable-debug
Then make
Then try gdb on the compiled libxenomai.so.0.0.0

There are two layers of Makefileries, thee aim is to find where the
problem is coming from, not to use this as a solution.

-- 
                                                                Gilles.


  reply	other threads:[~2014-09-05 21:17 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-05 18:43 [Xenomai] How to get debug symbols in xenomai libraries Lennart Sorensen
2014-09-05 19:10 ` Gilles Chanteperdrix
2014-09-05 19:14   ` Lennart Sorensen
2014-09-05 20:15     ` Gilles Chanteperdrix
2014-09-05 20:21       ` Gilles Chanteperdrix
2014-09-05 20:31         ` Gilles Chanteperdrix
2014-09-05 20:54           ` Lennart Sorensen
2014-09-05 20:57             ` Gilles Chanteperdrix
2014-09-05 21:03               ` Lennart Sorensen
2014-09-05 21:04                 ` Gilles Chanteperdrix
2014-09-05 21:15                   ` Lennart Sorensen
2014-09-05 21:17                     ` Gilles Chanteperdrix [this message]
2014-09-05 21:25                       ` Paul
2014-09-06 13:16                         ` Gilles Chanteperdrix
2014-09-06 15:16                           ` Paul
2014-09-06 16:50                             ` Gilles Chanteperdrix
2014-09-06 16:56                               ` Lennart Sorensen
2014-09-18 13:53                             ` Lennart Sorensen
2014-09-06 16:55                         ` Lennart Sorensen
2014-09-05 21:30                       ` Lennart Sorensen
2014-09-05 21:31                         ` Gilles Chanteperdrix
2014-09-05 21:21                     ` Paul

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=540A286C.2050803@xenomai.org \
    --to=gilles.chanteperdrix@xenomai.org \
    --cc=lsorense@csclub.uwaterloo.ca \
    --cc=xenomai@xenomai.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.