From 757fa01a28163031a6429189e06e45bfa00a2122 Mon Sep 17 00:00:00 2001 From: Christoph Mallon Date: Thu, 15 Mar 2012 10:14:36 +0100 Subject: COMMON: Add GCC_ATLEAST(major, minor) to simplify testing for versions of GCC. --- common/scummsys.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/common/scummsys.h b/common/scummsys.h index 6baab7c16f..85aaa46052 100644 --- a/common/scummsys.h +++ b/common/scummsys.h @@ -23,6 +23,9 @@ #ifndef COMMON_SCUMMSYS_H #define COMMON_SCUMMSYS_H +// This is a convenience macro to test whether the compiler used is a GCC +// version, which is at least major.minor. +#define GCC_ATLEAST(major, minor) (defined __GNUC__ && (__GNUC__ > (major) || (__GNUC__ == (major) && __GNUC_MINOR__ >= (minor)))) #if defined(_WIN32_WCE) && _WIN32_WCE < 300 #define NONSTANDARD_PORT -- cgit v1.2.3