[cfe-dev] Compiler flag to toggle NX (NonExec) bit

Kangkook Jee aixer77 at gmail.com
Thu May 15 20:22:46 PDT 2014


Hi all, 

I’m trying to find Clang's option equivalent to GNU binutil’s “-z execstack or
-z noexecstack”  which is to toggle NX bit of output binary.  For instance,
something similar to the following. 

$ gcc -z execstack -o main main.c
$ execstack -q main
X main

Thanks for your help in advance. 

/Kangkook



More information about the cfe-dev mailing list