From 47b34dd39850b8b157c67887d9b6bf7bd3095796 Mon Sep 17 00:00:00 2001 From: Elliot Ronaghan Date: Thu, 7 Jul 2016 15:06:01 -0700 Subject: [PATCH] Disable irrelevant Cray compiler warnings if cc-silence is enabled Cray is pretty warning-happy, so disable ones that aren't helpful. Each warning has a numeric value instead of having named flags to disable specific warnings. Disable warnings 128 and 1357. 128: Ignore unreachable code warning. Cray warns about `not_reached()` not being reachable in a couple of places because it detects that some loops will never terminate. 1357: Ignore warning about redefinition of malloc and friends With this patch, Cray 8.4.0 and 8.5.1 build cleanly and pass `make check` --- configure.ac | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/configure.ac b/configure.ac index 13ce6860..e1639d51 100644 --- a/configure.ac +++ b/configure.ac @@ -195,6 +195,12 @@ if test "x$CFLAGS" = "x" ; then JE_CFLAGS_APPEND([-hipa2]) JE_CFLAGS_APPEND([-hnognu]) fi + if test "x$enable_cc_silence" != "xno" ; then + dnl ignore unreachable code warning + JE_CFLAGS_APPEND([-hnomessage=128]) + dnl ignore redefinition of "malloc", "free", etc warning + JE_CFLAGS_APPEND([-hnomessage=1357]) + fi fi fi dnl Append EXTRA_CFLAGS to CFLAGS, if defined.