X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=aclocal.m4;h=d9a14343b701cc2e0e4d68f849cd17198ba52b6b;hb=771d69aa214ae3e5c0722e7a1b3d71e35a6a1df8;hp=e0cae15acf180ca7c82609816725a66c31164935;hpb=22cbec8d2dfbfdb7c6625a093ccb518fedf3a2d7;p=ghc-hetmet.git diff --git a/aclocal.m4 b/aclocal.m4 index e0cae15..d9a1434 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -23,6 +23,15 @@ AC_DEFUN([FPTOOLS_SET_C_LD_FLAGS], $3="$$3 -m64" ;; esac + + # If gcc knows about the stack protector, turn it off. + # Otherwise the stack-smash handler gets triggered. + echo 'int main(void) {return 0;}' > conftest.c + if $CC -c conftest.c -fno-stack-protector > /dev/null 2>&1 + then + $2="$$2 -fno-stack-protector" + fi + rm conftest.c conftest.o ]) @@ -966,9 +975,6 @@ AC_SUBST([GhcPkgCmd]) # reordering things in the module and confusing the manger and/or splitter. # (eg. Trac #1427) # -# If gcc knows about the stack protector, turn it off. -# Otherwise the stack-smash handler gets triggered. -# AC_DEFUN([FP_GCC_EXTRA_FLAGS], [AC_REQUIRE([FP_HAVE_GCC]) AC_CACHE_CHECK([for extra options to pass gcc when compiling via C], [fp_cv_gcc_extra_opts], @@ -994,12 +1000,6 @@ AC_CACHE_CHECK([for extra options to pass gcc when compiling via C], [fp_cv_gcc_ []) ;; esac - echo 'int main(void) {return 0;}' > conftest.c - if $CC -c conftest.c -fno-stack-protector > /dev/null 2>&1 - then - fp_cv_gcc_extra_opts="$fp_cv_gcc_extra_opts -fno-stack-protector" - fi - rm conftest.c conftest.o ]) AC_SUBST([GccExtraViaCOpts],$fp_cv_gcc_extra_opts) ]) @@ -1266,7 +1266,7 @@ if test ! -f utils/ghc-pwd/ghc-pwd && test ! -f utils/ghc-pwd/ghc-pwd.exe; then rm -f *.hi rm -f ghc-pwd rm -f ghc-pwd.exe - "$WithGhc" -v0 --make ghc-pwd -o ghc-pwd + "$WithGhc" -v0 -no-user-package-conf --make ghc-pwd -o ghc-pwd cd ../.. fi