https://github.com/torvalds/linux
Raw File
Tip revision: 39da7c509acff13fc8cb12ec1bb20337c988ed36 authored by Linus Torvalds on 09 April 2017, 16:49:44 UTC
Linux 4.11-rc6
Tip revision: 39da7c5
gcc-x86_64-has-stack-protector.sh
#!/bin/sh

echo "int foo(void) { char X[200]; return 3; }" | $* -S -x c -c -O0 -mcmodel=kernel -fno-PIE -fstack-protector - -o - 2> /dev/null | grep -q "%gs"
if [ "$?" -eq "0" ] ; then
	echo y
else
	echo n
fi
back to top