summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorPeter Trommler <ptrommler@acm.org>2017-11-06 15:35:30 -0500
committerBen Gamari <ben@smart-cactus.org>2017-11-06 16:39:20 -0500
commit59de290928e6903337f31c1f8107ac8a98ea145d (patch)
tree7c8cd1ebd75bd1bb0f11b0ac24965f82cc4d74f8 /mk
parent8613e61de62178e76cd0f8915bd1fbe9c200a039 (diff)
downloadhaskell-59de290928e6903337f31c1f8107ac8a98ea145d.tar.gz
Update autoconf test for gcc to require 4.7 and up
Fixing #14244 required the newer gcc atomic built-ins that are provided from 4.7 and up. This updates the test to check for minimum gcc version 4.7. The version tests for 3.4 (!), 4.4, and 4.6 are no longer needed and can be removed. This makes the build system simpler. Test Plan: validate Reviewers: austin, bgamari, hvr, simonmar Reviewed By: bgamari Subscribers: rwbarton, thomie, erikd Differential Revision: https://phabricator.haskell.org/D4165
Diffstat (limited to 'mk')
-rw-r--r--mk/config.mk.in3
-rw-r--r--mk/warnings.mk6
2 files changed, 1 insertions, 8 deletions
diff --git a/mk/config.mk.in b/mk/config.mk.in
index 92661a32d1..b046abe112 100644
--- a/mk/config.mk.in
+++ b/mk/config.mk.in
@@ -522,9 +522,6 @@ GccVersion = @GccVersion@
# TargetPlatformFull retains the string passed to configure so we have it in
# the necessary format to pass to libffi's configure.
TargetPlatformFull = @TargetPlatformFull@
-GccLT34 = @GccLT34@
-GccLT44 = @GccLT44@
-GccLT46 = @GccLT46@
GccIsClang = @GccIsClang@
CC = @CC@
diff --git a/mk/warnings.mk b/mk/warnings.mk
index 85cb1a0283..69990a75c5 100644
--- a/mk/warnings.mk
+++ b/mk/warnings.mk
@@ -20,21 +20,17 @@ GhcStage2HcOpts += -Wcpp-undef
ifneq "$(GccIsClang)" "YES"
# Debian doesn't turn -Werror=unused-but-set-variable on by default, so
-# we turn it on explicitly for consistency with other users
-ifeq "$(GccLT46)" "NO"
+# we turn it on explicitly for consistency with other users.
# Never set the flag on Windows as the host gcc may be too old.
ifneq "$(HostOS_CPP)" "mingw32"
SRC_CC_WARNING_OPTS += -Werror=unused-but-set-variable
endif
-endif
-ifeq "$(GccLT44)" "NO"
# Suppress the warning about __sync_fetch_and_nand (#9678).
libraries/ghc-prim/cbits/atomic_CC_OPTS += -Wno-sync-nand
# gcc 4.6 gives 3 warnings for giveCapabilityToTask not being inlined
# gcc 4.4 gives 2 warnings for lockClosure not being inlined
SRC_CC_WARNING_OPTS += -Wno-error=inline
-endif
else