From d118b8b389b680abf5d23ed5e66eabda418b89e0 Mon Sep 17 00:00:00 2001 From: Alex Neundorf Date: Wed, 4 Jan 2012 21:36:49 +0100 Subject: [PATCH] Add IAR to the CMakeDetectC(XX)CompilerID.c(pp).in With the AVR IAR compiler this can't be found, but it works e.g. for the ARM AVR compiler. Alex --- Modules/CMakeCCompilerId.c.in | 7 +++---- Modules/CMakeCXXCompilerId.cpp.in | 5 +++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/Modules/CMakeCCompilerId.c.in b/Modules/CMakeCCompilerId.c.in index c25df0cb5..66a558265 100644 --- a/Modules/CMakeCCompilerId.c.in +++ b/Modules/CMakeCCompilerId.c.in @@ -160,10 +160,9 @@ # define COMPILER_ID "ADSP" /* IAR Systems compiler for embedded systems. - http://www.iar.com - Not supported yet by CMake -#elif defined(__IAR_SYSTEMS_ICC__) -# define COMPILER_ID "IAR" */ + http://www.iar.com */ +#elif defined(__IAR_SYSTEMS_ICC__ ) || defined(__IAR_SYSTEMS_ICC) +# define COMPILER_ID "IAR" /* sdcc, the small devices C compiler for embedded systems, http://sdcc.sourceforge.net */ diff --git a/Modules/CMakeCXXCompilerId.cpp.in b/Modules/CMakeCXXCompilerId.cpp.in index e2119c2bf..5e87715c0 100644 --- a/Modules/CMakeCXXCompilerId.cpp.in +++ b/Modules/CMakeCXXCompilerId.cpp.in @@ -161,6 +161,11 @@ #elif defined(__ADSPBLACKFIN__) || defined(__ADSPTS__) || defined(__ADSP21000__) # define COMPILER_ID "ADSP" +/* IAR Systems compiler for embedded systems. + http://www.iar.com */ +#elif defined(__IAR_SYSTEMS_ICC__ ) || defined(__IAR_SYSTEMS_ICC) +# define COMPILER_ID "IAR" + #elif defined(_SGI_COMPILER_VERSION) || defined(_COMPILER_VERSION) # define COMPILER_ID "MIPSpro" # if defined(_SGI_COMPILER_VERSION)