X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=configure;h=742ca261ee0257c165b8ab3a2bd5e24892cfbcc8;hb=fda365a53074f97f3213caefe70ea13297acecb2;hp=c277764a05e2655760f7c51ce26faff0e9bc634a;hpb=d4c82d05b8d0ee97f6356d60986799a95ed5bd74;p=musl diff --git a/configure b/configure index c277764a..742ca261 100755 --- a/configure +++ b/configure @@ -329,6 +329,13 @@ printf "yes\n" CFLAGS_C99FSE="$CFLAGS_C99FSE -D__may_alias__=" fi +# +# The GNU toolchain defaults to assuming unmarked files need an +# executable stack, potentially exposing vulnerabilities in programs +# linked with such object files. Fix this. +# +tryflag CFLAGS_C99FSE -Wa,--noexecstack + # # Check for options to disable stack protector, which needs to be # disabled for a few early-bootstrap translation units. If not found, @@ -429,13 +436,6 @@ fi tryflag CFLAGS_AUTO -fno-unwind-tables tryflag CFLAGS_AUTO -fno-asynchronous-unwind-tables -# -# The GNU toolchain defaults to assuming unmarked files need an -# executable stack, potentially exposing vulnerabilities in programs -# linked with such object files. Fix this. -# -tryflag CFLAGS_AUTO -Wa,--noexecstack - # # On x86, make sure we don't have incompatible instruction set # extensions enabled by default. This is bad for making static binaries. @@ -476,10 +476,18 @@ if test "x$visibility" = xauto ; then # - the -include option # - the attributes/pragmas used in vis.h # - linking code that takes the address of protected symbols +# - gcc 3.x bug that wrongly claims declarations mismatch printf "checking whether global visibility preinclude works... " -echo 'int (*fp)(void);' > "$tmpc" -echo 'int foo(void) { }' >> "$tmpc" -echo 'int bar(void) { fp = foo; return foo(); }' >> "$tmpc" +cat > "$tmpc" <