public inbox for crossgcc@sourceware.org
 help / color / mirror / Atom feed
From: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
To: crossgcc@sourceware.org
Cc: ANDY KENNEDY <ANDY.KENNEDY@adtran.com>
Subject: Re: libelf.so.1?
Date: Thu, 28 Jul 2011 21:55:00 -0000	[thread overview]
Message-ID: <201107282355.05115.yann.morin.1998@anciens.enib.fr> (raw)
In-Reply-To: <F9C551623D2CBB4C9488801D14F864C6048B1D@ex-mb1.corp.adtran.com>

Andy, All,

On Thursday 28 July 2011 22:32:25 ANDY KENNEDY wrote:
> This may be a buildroot issue, but I don't know.  Looking around shows
> that this is supposed to be part of ???binutils??? though the pkg name
> that produces results in Google is bfd.

libelf.so comes from the package named, guess it... libelf ! :-)
    http://www.mr511.de/software/

> The question:  I'm attempting to get a shared libelf, however, the only
> one that ends up in my sysroot (I think from the buildroot bastardized
> install I do to put libs back into the toolchain) is libelf.a. I was
> half-way tasked to find the shared object.  So, where does that puppy
> live?

That should ultimately be a question for the buildroot guys. But see below.

> Looking at the GNU website, there is a bfd which redirects to
> binutills.  Rock!  I say to myself, I should be able to get that.  Next
> I open up my good ole ct-ng menuconfig and see an option in Binutils
> "install libs in target".  Excellent! I says to myself again.  But,
> alas, that doesn't give me what I want.

Indeed. libelf is not from binutils, but from libelf. ;-)
crosstool-NG builds a static-only version of libelf for the target,
because it is needed by ltrace.

Only the static version is built, because I don't see it as being a system
library. ltrace is here as a debug tool, and it goes along with the other
debug tools. And as lbelf is not a system lib, we just use the static
version to link ltrace against it. Deselect ltrace, you won't get libelf.

The error was to install libelf in the sysroot in the first place. It
should not have gone there, it should have been in a temporary place that
gets trashed after ltrace is built.

Again: libelf is *not* a system library. The existence of the static version
in the sysroot is just hapenstance, and a side effect of ltrace being there.

You should not rely on libelf's presence in the sysroot.

> The ultimate goal is to get mpatrol in the toolchain so we can track
> down this memory leak we have.  Though, I'm only working on this like
> 2% of my time.  Hoping someone out there knows the answer to my pain.

Buildroot (which it seems you are using) already has a libelf package.
Use that.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

--
For unsubscribe information see http://sourceware.org/lists.html#faq

  reply	other threads:[~2011-07-28 21:55 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-28 20:33 libelf.so.1? ANDY KENNEDY
2011-07-28 21:55 ` Yann E. MORIN [this message]
2011-07-29  3:52   ` libelf.so.1? ANDY KENNEDY
2011-07-29  7:08     ` libelf.so.1? Bryan Hundven
2011-07-29  7:27     ` libelf.so.1? Yann E. MORIN
2011-07-29 21:29       ` libelf.so.1? ANDY KENNEDY

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=201107282355.05115.yann.morin.1998@anciens.enib.fr \
    --to=yann.morin.1998@anciens.enib.fr \
    --cc=ANDY.KENNEDY@adtran.com \
    --cc=crossgcc@sourceware.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).