Downstream report you should read, http://bugs.gentoo.org/show_bug.cgi?id=511634 Basically Makefile's are always including src/x86/win32.S even on a non-windows system, and win32.S is missing the GNU stack marking other files already have: Makefile.am has: if X86 nodist_libffi_la_SOURCES += src/x86/ffi.c src/x86/sysv.S src/x86/win32.S endif and it doesn't have the #if defined __ELF__ && defined __linux__ .section .note.GNU-stack,"",@progbits #endif other files like sysv.S, unix64.S, freebsd.S, already have The attached patch fixes the executable stack in libffi.so.6