Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 02 Jan 2017 16:16:34 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-threads@FreeBSD.org
Subject:   [Bug 215709] Use of thread_local produces linking errors [now with gcc]
Message-ID:  <bug-215709-16-5EmQrjQw9l@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-215709-16@https.bugs.freebsd.org/bugzilla/>
References:  <bug-215709-16@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D215709

Konstantin Belousov <kib@FreeBSD.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |kib@FreeBSD.org

--- Comment #1 from Konstantin Belousov <kib@FreeBSD.org> ---
This is a bug in gcc.  The libsupc++ configuration assumes that there are
exactly two possibilities: either libc is glibc and implements
__cxa_thread_atexit() using __cxa_thread_atexit_impl(), or libsupc++ must
provide an implementation on its own.  Right solution is to add detection of
__cxa_thread_atexit() in libc, to libstdc++ configure.ac and
libsupc++/atexit_thread.cc.

A workaround for you is might be use of --allow-multiple-definition switch =
to
ld.  But what is not quite clear to me, is why libc  __cxa_thread_atexit was
searched for at all, since static linker should be satisfied with the first
definition it found.  Ensure that libstdc++.a appears strictly before libc.=
a on
the linker invocation' command line.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-215709-16-5EmQrjQw9l>