This is the mail archive of the mailing list for the binutils project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Help: GOLD unable to find logf() in when sysroot is enabled

>> gold only warns about undefined references from shared libraries in
>> specific circumstances.  See
>> Symbol_table::warn_about_undefined_dynobj_symbol in  I
>> think that particularly relevant here is that gold does not warn about
>> an undefined reference in a shared library that it finds in a "system
>> directory", which basically means a directory found in the sysroot.
>> I'm guessing that that is somehow the difference between your two
>> links.  But I don't know why the definition of logf found in
>> is not satisfying the references from the other shared libraries.
>> Could there be any versions involved?
> No.  I checked and the reference and definition are both unversioned.
> I did find however that I spoke too soon about this problem not being
> fixed in the mainline sources.  It seems that somehow the bug is fixed.
> I am currently checking to make sure that this is correct and not just
> me mucking up the testing again, but using a VM makes the whole process
> very slow.

This does sound like a recent bug fix. See if this commit is what
makes the difference:

commit e3f07b5b750554bbbbee1bddc34bb77fd7d31eeb
Author: Cary Coutant <>
Date:   Tue Sep 27 12:08:19 2016 -0700

    Don't treat as separate symbols if unversioned symbol is undefined.

    When we see an unversioned symbol reference in a shared library, followed
    by a default definition of the symbol in another shared library, we were
    treating them as separate symbols. That should only happen when both are

            PR gold/20238
            * (Symbol_table::define_default_version): Check that
            unversioned symbol is defined.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]