How to debug "TLS transition from R_X86_64_TLSGD to R_X86_64_GOTTPOFF failed"

H.J. Lu hjl.tools@gmail.com
Tue Jan 15 20:12:00 GMT 2019


On Tue, Jan 15, 2019 at 12:07 PM Antoine Pitrou <antoine@python.org> wrote:
>
>
> Le 15/01/2019 à 20:24, H.J. Lu a écrit :
> > On Tue, Jan 15, 2019 at 11:11 AM Antoine Pitrou <antoine@python.org> wrote:
> >>
> >>
> >> Hello,
> >>
> >> I'm getting this error when trying to compile our C++ project on Ubuntu 16.04
> >> (with gcc 5.4.0 and GNU ld):
> >>
> >> /usr/bin/ld: /home/travis/build/pitrou/arrow/cpp-toolchain/lib/libprotobuf.a(common.o): TLS transition from R_X86_64_TLSGD to R_X86_64_GOTTPOFF against `_ZSt15__once_callable' at 0x38e in section `.text' failed
> >> /home/travis/build/pitrou/arrow/cpp-toolchain/lib/libprotobuf.a: error adding symbols: Bad value
> >>
> >> (full log: https://travis-ci.org/pitrou/arrow/jobs/480030097#L1498)
> >>
> >> The binutils version is 2.26.1-1ubuntu1~16.04.7 (on x86-64).
> > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> >
> > This is a very ancient binutils. Please try binutils 2.31.
>
> First, it's not obvious to me how to install such a newer binutils on
> Ubuntu 16.04.  No official backports seem provided.

There are many many changes in binutils since 2.26.   What you ran into
may have been fixed.   But we will never know if you don't try.

> More importantly, we want to support our users on Ubuntu 16.04 (which is
> a LTS version, still officially supported) without having them upgrade
> the base toolchain (which could be a dangerous operation).  This is why
> I would like some guidance as to how I could debug this issue.

We will make suggestion AFTER you try binutils 2.31.

-- 
H.J.



More information about the Binutils mailing list