Commit 29ecb520 authored by Sergei Trofimovich's avatar Sergei Trofimovich Committed by Ben Gamari

aclocal.m4: drop obsolete -fno-stack-protector

Summary:
Initially -fno-stack-protector was added for openbsd specifically for ghc-6.5:
    changeset:f638fdfe (2006)
and later it was extended to cover osx:
    changeset:c2cd83e7 (2009)

None of the reports hint at exact breakage. I guess both happened
in -fvia-C mode where GHC's Evil Mangler had a chance to mangle
stack canaries generated by fstack-protector.

ghc has no evil mangler anymore and the change is not needed
at least for C codegen.

validated the patch on OpenBSD-6.4. No new failures compared to
clean master branch.
Signed-off-by: default avatarSergei Trofimovich <slyfox@gentoo.org>

Test Plan: validated on OpenBSD

Reviewers: bgamari

Subscribers: rwbarton, erikd, carter

GHC Trac Issues: #16046

Differential Revision: https://phabricator.haskell.org/D5465
parent 942b5019
......@@ -693,15 +693,6 @@ AC_DEFUN([FPTOOLS_SET_C_LD_FLAGS],
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 -f conftest.c conftest.o
AC_MSG_RESULT([done])
])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment