This is the mail archive of the
libffi-discuss@sourceware.org
mailing list for the libffi project.
Re: Mark libffi as not requiring executable stack on FreeBSD
- From: Brad Smith <brad at comstyle dot com>
- To: libffi-discuss at sourceware dot org
- Date: Mon, 04 Nov 2013 18:36:41 -0500
- Subject: Re: Mark libffi as not requiring executable stack on FreeBSD
- Authentication-results: sourceware.org; auth=none
- References: <20120729011435 dot GN2676 at deviant dot kiev dot zoral dot com dot ua>
On 28/07/12 9:14 PM, Konstantin Belousov wrote:
Hi,
libffi on FreeBSD uses assembler source src/x86/freebsd.S which lacks
.note.GNU-stack section. As result, libffi shared library and any code
that links with libffi statically ends up with executable stack.
Patch below fixes the issue. Please apply.
ping.
commit 2b8152f633c6debae0b6076b0c39eb326ceb09e2
Author: Konstantin Belousov <kib-h+KGxgPPiopAfugRpC6u6w@public.gmane.org>
Date: Sun Jul 29 04:06:39 2012 +0300
On FreeBSD, mark the assembler source as not requiring executable stack.
diff --git a/src/x86/freebsd.S b/src/x86/freebsd.S
index afde513..ee6fc45 100644
--- a/src/x86/freebsd.S
+++ b/src/x86/freebsd.S
@@ -456,3 +456,4 @@ ffi_closure_raw_SYSV:
#endif
#endif /* ifndef __x86_64__ */
+ .section .note.GNU-stack,"",%progbits
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.