diff options
author | Sergei Trofimovich <slyfox@gentoo.org> | 2011-09-17 11:29:44 +0100 |
---|---|---|
committer | Ian Lynagh <igloo@earth.li> | 2011-09-17 11:30:04 +0100 |
commit | 607537a8424f580c134d6cf88cf902a81589c41f (patch) | |
tree | 288c0af1afa86594c3b3189ecebcfefc64e459d3 | |
parent | 259ea3e0cc85b771e730928f085503407dc27978 (diff) | |
download | haskell-607537a8424f580c134d6cf88cf902a81589c41f.tar.gz |
Gentoo's scanelf program found executable stack in many resulting binaries:
* RWX --- --- home/prefix/gentoo/usr/lib/ghc-7.2.1/ghc
* !WX --- --- home/prefix/gentoo/usr/lib/ghc-7.2.1/libHSrts.a:AdjustorAsm.o
More info can be found here: http://www.gentoo.org/proj/en/hardened/gnu-stack.xml
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
-rw-r--r-- | rts/AdjustorAsm.S | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/rts/AdjustorAsm.S b/rts/AdjustorAsm.S index 75b83f6947..ca7ae36573 100644 --- a/rts/AdjustorAsm.S +++ b/rts/AdjustorAsm.S @@ -192,3 +192,7 @@ adjustorCode: ret #endif +/* mark stack as nonexecutable */ +#if defined(__linux__) && defined(__ELF__) +.section .note.GNU-stack,"",@progbits +#endif |