From 655492a44390b017a8b0cf7a2e2f51dc9e1b53cb Mon Sep 17 00:00:00 2001 From: paboyle Date: Thu, 11 May 2017 11:21:11 +0100 Subject: [PATCH] Compiler detection --- lib/util/CompilerCompatible.h | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/lib/util/CompilerCompatible.h b/lib/util/CompilerCompatible.h index 405b4c07..a62ed71f 100644 --- a/lib/util/CompilerCompatible.h +++ b/lib/util/CompilerCompatible.h @@ -1,9 +1,5 @@ #pragma once - -#define COMPILER_FATAL -#define COMPILER_GCC_WARN "Compiler" COMPILER_STRING " is known to not work with Grid under -O3 due to compiler bugs" - #if defined(__clang__) #if __clang_major < 3 @@ -16,14 +12,12 @@ #endif #endif -#endif - // Intel compiler *ALSO* has __GNUC__ defined so must if/else GCC checks -#ifdef __INTEL_COMPILER +#elif defined(__INTEL_COMPILER) -#if __INTEL_COMPILER < 1600 - #error "This icpc version is known to not work with Grid due to compiler bugs" -#endif + #if __INTEL_COMPILER < 1603 + #error "This icpc version is known to not work with Grid due to compiler bugs" + #endif #else @@ -50,6 +44,10 @@ #endif #endif +#else + + #warning "Unknown compiler detected: cannot guarantee compatability since Grid tends to break compilers" + #warning "Ensure to run : make check" #endif