From a29c18f96998be3fd3c39f65c765c0a6bfff3e04 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Sun, 8 Aug 2021 04:13:05 +0200 Subject: Toolchain+Ports: Let -nostdlib make us not link against libgcc_s For now this is not a mandatory toolchain rebuild. --- Toolchain/Patches/gcc.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Toolchain/Patches') diff --git a/Toolchain/Patches/gcc.patch b/Toolchain/Patches/gcc.patch index 93a0e85de7..0ba8f449a7 100644 --- a/Toolchain/Patches/gcc.patch +++ b/Toolchain/Patches/gcc.patch @@ -152,7 +152,7 @@ diff -Naur gcc-11.2.0/gcc/config/serenity.h gcc-11.2.0.serenity/gcc/config/seren +#define ENDFILE_SPEC "%{shared|static-pie|!no-pie:crtendS.o%s; :crtend.o%s} crtn.o%s" + +#undef LINK_SPEC -+#define LINK_SPEC "%{shared:-shared} %{static:-static} %{!static: %{rdynamic:-export-dynamic} %{!fbuilding-libgcc:%{!nodefaultlibs:-lgcc_s} -dynamic-linker /usr/lib/Loader.so}}" ++#define LINK_SPEC "%{shared:-shared} %{static:-static} %{!static: %{rdynamic:-export-dynamic} %{!fbuilding-libgcc:%{!nostdlib:%{!nodefaultlibs:-lgcc_s}} -dynamic-linker /usr/lib/Loader.so}}" + +#undef CC1_SPEC +#define CC1_SPEC "-ftls-model=initial-exec %{!fno-pic:%{!fno-PIC:%{!fpic:%{!fPIC: -fPIC}}}} -fno-semantic-interposition" -- cgit v1.2.3