configure: Use -Werror to check for existence of -no-pie
authorBen Gamari <bgamari.foss@gmail.com>
Thu, 19 Apr 2018 19:05:50 +0000 (15:05 -0400)
committerBen Gamari <ben@smart-cactus.org>
Thu, 19 Apr 2018 22:06:15 +0000 (18:06 -0400)
commitcbd73bbbb7df080d5204098aa02e5f5d0d48823c
tree444ad64033e36ca256ce6917fc5a343d3d0a726b
parent3c3e73103a45c9acee1682300727bad7b6a62d30
configure: Use -Werror to check for existence of -no-pie

Clang throws a warning instead of an error when it is passed -no-pie,

    clang: warning: argument unused during compilation: '-nopie'
    [-Wunused-command-line-argument]

Consequently configure concludes that it supports -no-pie. However, this
will fail when used with -Werror. The solution is to simply use -Werror
in the configure check.

Thanks to @goldfire for reporting this.

Reviewers: hvr

Subscribers: thomie, carter, goldfire

Differential Revision: https://phabricator.haskell.org/D4557
aclocal.m4