config: detect if assembler supports --noexecstack and pass it down [from HEAD].
authorAndy Polyakov <appro@openssl.org>
Fri, 15 Jul 2011 19:59:31 +0000 (19:59 +0000)
committerAndy Polyakov <appro@openssl.org>
Fri, 15 Jul 2011 19:59:31 +0000 (19:59 +0000)
config

diff --git a/config b/config
index b9d1c7aa26885853ec6a11a3b9e9638ba639e481..7a958cb4326585a211881466eaa0f277736529c7 100755 (executable)
--- a/config
+++ b/config
@@ -790,6 +790,10 @@ esac
 #  options="$options -DATALLA"
 #fi
 
+($CC -Wa,--help -c -o /dev/null -x assembler /dev/null 2>&1 | \
+ grep \\--noexecstack) 2>&1 > /dev/null && \
+  options="$options -Wa,--noexecstack"
+
 # gcc < 2.8 does not support -march=ultrasparc
 if [ "$OUT" = solaris-sparcv9-gcc -a $GCCVER -lt 28 ]
 then