This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[patch] FreeBSD x86 emit note.GNU-stack section
- From: Andreas Tobler <andreast-list at fgznet dot ch>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>, Loren James Rittle <ljrittle at gmail dot com>
- Date: Thu, 15 Dec 2011 13:48:54 +0100
- Subject: [patch] FreeBSD x86 emit note.GNU-stack section
Hi all,
I'd like to commit the below patch to trunk and gcc-4.6.x.
The functionality has been in the FreeBSD base compiler since nearly 12
months now.
Is this ok for trunk, I know we're in stage three?
And for gcc-4.6 branch?
Tested with bootstrap/test (results follow) and 'readelf -l gcc/xgcc':
GNU_STACK 0x0000000000000000 0x0000000000000000 0x0000000000000000
0x0000000000000000 0x0000000000000000 RW 8
Thanks,
Andreas
2011-12-15 Andreas Tobler <andreast@fgznet.ch>
* config/i386/freebsd.h (TARGET_ASM_FILE_END): Define.
Index: config/i386/freebsd.h
===================================================================
--- config/i386/freebsd.h (revision 182359)
+++ config/i386/freebsd.h (working copy)
@@ -145,3 +145,6 @@
#if FBSD_MAJOR >= 6
#define SUBTARGET32_DEFAULT_CPU "i486"
#endif
+
+#define TARGET_ASM_FILE_END file_end_indicate_exec_stack
+