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

--- Comment #9 from H.J. Lu <hjl.tools at gmail dot com> ---
(In reply to coypu from comment #8)
> Created attachment 41317 [details]
> Unbreak NetBSD following r243219
> 
> This patch works for me.

This may break Linux.  You may want to investigate if this approach:

commit 6e6c7fc1e15525a10f48d4f5ac2edd853e2f5cb7
Author: nsz <nsz@138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Fri Nov 11 17:31:07 2016 +0000

    [i386][musl] Add cpuinfo to static libgcc only on *-musl*

    The __cpu_indicator_init and __cpu_model symbols are not safe to use
    from shared libgcc_s.so from ifunc resolvers, so since gcc-6, only
    the definitions from static libgcc.a are used, however the symbols
    are kept in libgcc_s as well for backward compatibility (with
    appropriate symbol version).  On targets without such backward
    compatibility concern add cpuinfo to the static library only (this
    avoids running the ctor, reduces libgcc_s size and elf abi concerns
    about the versioned symbols).

works for you.

Reply via email to