On Wed, Aug 19, 2009 at 3:12 PM, Joerg Schilling <
Joerg.Schilling at fokus.fraunhofer.de> wrote:

> Vincent Torri <vincent.torri at gmail.com> wrote:
>
> > > > symbol _mcount: referenced symbol not found
> > >
> > > The code was compiles with -xpg and thus you ned to link with
> > > -xpg too.
> > >
> > > See "man gprof"
> > >
> > > which code ? pthread ? Because i don't compile with -pg. I have
> verified.
>
> Try to find out which code need _mcount.
>
> If the linker does not tell you, you may call:
>
> nm -r *.o | grep mcount
>
> then check how this code is compiled. Maybe there is a buggy
> makefile that includes -xpg (note with gcc, this is -pg).


as i said, if i link against pthread lib, mcount symbol is needed, if i
don't link against pthread lib, it's not needed. And in case I use pthread
lib, i only use the mutex API. And pg is not use in the Makefile (It's an
autotooled project, btw)

Vincent Torri
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
<http://mail.opensolaris.org/pipermail/tools-compilers/attachments/20090819/ee5dbb41/attachment.html>

Reply via email to