![]() |
|
Message-ID: <20250425182855.GD288056@port70.net> Date: Fri, 25 Apr 2025 20:28:55 +0200 From: Szabolcs Nagy <nsz@...t70.net> To: Slava Barinov <rayslava@...il.com> Cc: musl@...ts.openwall.com Subject: Re: [PATCH] force -fno-lto for CRT files * Slava Barinov <rayslava@...il.com> [2025-04-26 00:38:18 +0900]: > If the library is built using -flto flag the symbol only referenced in inline > assembly is considered unused and therefore is removed. > > Zig compiler has the same issue: https://github.com/ziglang/zig/issues/10364 cflags like -fno-lto require configure check, see CFLAGS_NOSSP > --- > Makefile | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/Makefile b/Makefile > index 3ad88b35..709c5860 100644 > --- a/Makefile > +++ b/Makefile > @@ -127,7 +127,7 @@ NOSSP_OBJS = $(CRT_OBJS) $(LDSO_OBJS) $(filter \ > , $(LIBC_OBJS)) > $(NOSSP_OBJS) $(NOSSP_OBJS:%.o=%.lo): CFLAGS_ALL += $(CFLAGS_NOSSP) > > -$(CRT_OBJS): CFLAGS_ALL += -DCRT > +$(CRT_OBJS): CFLAGS_ALL += -DCRT -fno-lto > > $(LOBJS) $(LDSO_OBJS): CFLAGS_ALL += -fPIC > > -- > 2.49.0
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.