[Bug c++/60731] [4.7/4.8/4.9 Regression] dynamic library not getting reinitialized on multiple calls to dlopen()

jason at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Jun 13 16:19:00 GMT 2014


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60731

--- Comment #12 from Jason Merrill <jason at gcc dot gnu.org> ---
(In reply to Dave Johansen from comment #11)
> Can this please be reopened? It was determined in the glibc bugzilla that
> this is a gcc problem because of the incorrect setting of unique flag.

The setting is not incorrect, nor is it an optimization; it is necessary to fix
the behavior of RTLD_LOCAL with multiple loaded objects depending on the same
library, since the glibc developers rejected the other approach that I
suggested (https://www.sourceware.org/ml/libc-alpha/2002-05/msg00222.html).

If you don't need this handling, in 4.9 you can use -fno-gnu-unique to disable
it.  I'll go ahead and backport that switch to 4.8 as well.



More information about the Gcc-bugs mailing list