--
Best regards,
LIU Hao
From cd3802aae66bc7c8caaa2cd44473a9e9455ab136 Mon Sep 17 00:00:00 2001
From: LIU Hao <lh_mo...@126.com>
Date: Mon, 8 Jan 2024 21:58:04 +0800
Subject: [PATCH] crt: Remove section attributes from declarations

This patch is generated by

  sed -Ei '/\<extern\>/s/\<_CRTALLOC\([^)]+\) +//' $(git grep -Flr _CRTALLOC)

in order to get rid of warnings like

  crt/crtexe.c:58:1: warning: 'used' attribute ignored [-Wattributes]
  extern _CRTALLOC(".CRT$XIA") _PIFV __xi_a[];

Signed-off-by: LIU Hao <lh_mo...@126.com>
---
 mingw-w64-crt/crt/crtdll.c | 8 ++++----
 mingw-w64-crt/crt/crtexe.c | 8 ++++----
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/mingw-w64-crt/crt/crtdll.c b/mingw-w64-crt/crt/crtdll.c
index e264d4e96..0f08a1a50 100644
--- a/mingw-w64-crt/crt/crtdll.c
+++ b/mingw-w64-crt/crt/crtdll.c
@@ -35,10 +35,10 @@
 extern void __cdecl _initterm(_PVFV *,_PVFV *);
 extern void __main ();
 extern void _pei386_runtime_relocator (void);
-extern _CRTALLOC(".CRT$XIA") _PIFV __xi_a[];
-extern _CRTALLOC(".CRT$XIZ") _PIFV __xi_z[];
-extern _CRTALLOC(".CRT$XCA") _PVFV __xc_a[];
-extern _CRTALLOC(".CRT$XCZ") _PVFV __xc_z[];
+extern _PIFV __xi_a[];
+extern _PIFV __xi_z[];
+extern _PVFV __xc_a[];
+extern _PVFV __xc_z[];
 
 
 /* TLS initialization hook.  */
diff --git a/mingw-w64-crt/crt/crtexe.c b/mingw-w64-crt/crt/crtexe.c
index 03bda5912..1ca9815ef 100644
--- a/mingw-w64-crt/crt/crtexe.c
+++ b/mingw-w64-crt/crt/crtexe.c
@@ -50,10 +50,10 @@ extern _CRTIMP void __cdecl _initterm(_PVFV *, _PVFV *);
 
 static int __cdecl check_managed_app (void);
 
-extern _CRTALLOC(".CRT$XIA") _PIFV __xi_a[];
-extern _CRTALLOC(".CRT$XIZ") _PIFV __xi_z[];
-extern _CRTALLOC(".CRT$XCA") _PVFV __xc_a[];
-extern _CRTALLOC(".CRT$XCZ") _PVFV __xc_z[];
+extern _PIFV __xi_a[];
+extern _PIFV __xi_z[];
+extern _PVFV __xc_a[];
+extern _PVFV __xc_z[];
 
 
 /* TLS initialization hook.  */
-- 
2.43.0

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature

_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to