diff --git a/Modules/CMakeCCompilerId.c.in b/Modules/CMakeCCompilerId.c.in index 7a0a39de1..a999e8db5 100644 --- a/Modules/CMakeCCompilerId.c.in +++ b/Modules/CMakeCCompilerId.c.in @@ -25,7 +25,13 @@ # define COMPILER_ID "Compaq" #elif defined(__IBMC__) -# define COMPILER_ID "VisualAge" +# if defined(__COMPILER_VER__) +# define COMPILER_ID "zOS" +# elif __IBMC__ >= 800 +# define COMPILER_ID "XL" +# else +# define COMPILER_ID "VisualAge" +# endif #elif defined(__PGI) # define COMPILER_ID "PGI" diff --git a/Modules/CMakeCXXCompilerId.cpp.in b/Modules/CMakeCXXCompilerId.cpp.in index 77a6247c3..2c8aa3c3c 100644 --- a/Modules/CMakeCXXCompilerId.cpp.in +++ b/Modules/CMakeCXXCompilerId.cpp.in @@ -27,7 +27,13 @@ # define COMPILER_ID "Compaq" #elif defined(__IBMCPP__) -# define COMPILER_ID "VisualAge" +# if defined(__COMPILER_VER__) +# define COMPILER_ID "zOS" +# elif __IBMCPP__ >= 800 +# define COMPILER_ID "XL" +# else +# define COMPILER_ID "VisualAge" +# endif #elif defined(__PGI) # define COMPILER_ID "PGI" diff --git a/Modules/CMakeFortranCompilerId.F.in b/Modules/CMakeFortranCompilerId.F.in index 63d3e438d..51f4e91d0 100644 --- a/Modules/CMakeFortranCompilerId.F.in +++ b/Modules/CMakeFortranCompilerId.F.in @@ -8,8 +8,14 @@ PRINT *, 'INFO:compiler[SunPro]' #elif defined(__GNUC__) PRINT *, 'INFO:compiler[GNU]' -#elif defined(__IBM__) || defined(__IBMC__) +#elif defined(__IBMC__) +# if defined(__COMPILER_VER__) + PRINT *, 'INFO:compiler[zOS]' +# elif __IBMC__ >= 800 + PRINT *, 'INFO:compiler[XL]' +# else PRINT *, 'INFO:compiler[VisualAge]' +# endif #elif defined(__PGI) PRINT *, 'INFO:compiler[PGI]' #elif defined(_SGI_COMPILER_VERSION) || defined(_COMPILER_VERSION) diff --git a/Modules/Compiler/VisualAge-C.cmake b/Modules/Compiler/VisualAge-C.cmake index 3120478e6..40b609e9a 100644 --- a/Modules/Compiler/VisualAge-C.cmake +++ b/Modules/Compiler/VisualAge-C.cmake @@ -1 +1 @@ -SET(CMAKE_C_VERBOSE_FLAG "-V") +include(Compiler/XL-C) diff --git a/Modules/Compiler/VisualAge-CXX.cmake b/Modules/Compiler/VisualAge-CXX.cmake index 618ff5ade..2509b4396 100644 --- a/Modules/Compiler/VisualAge-CXX.cmake +++ b/Modules/Compiler/VisualAge-CXX.cmake @@ -1 +1 @@ -SET(CMAKE_CXX_VERBOSE_FLAG "-V") +include(Compiler/XL-CXX) diff --git a/Modules/Compiler/VisualAge-Fortran.cmake b/Modules/Compiler/VisualAge-Fortran.cmake index 49d6bb2f3..3ef3178d9 100644 --- a/Modules/Compiler/VisualAge-Fortran.cmake +++ b/Modules/Compiler/VisualAge-Fortran.cmake @@ -1,2 +1 @@ -SET(CMAKE_Fortran_VERBOSE_FLAG "-V") -SET(CMAKE_Fortran_DEFINE_FLAG "-WF,-D") +include(Compiler/XL-Fortran) diff --git a/Modules/Compiler/XL-C.cmake b/Modules/Compiler/XL-C.cmake new file mode 100644 index 000000000..3120478e6 --- /dev/null +++ b/Modules/Compiler/XL-C.cmake @@ -0,0 +1 @@ +SET(CMAKE_C_VERBOSE_FLAG "-V") diff --git a/Modules/Compiler/XL-CXX.cmake b/Modules/Compiler/XL-CXX.cmake new file mode 100644 index 000000000..618ff5ade --- /dev/null +++ b/Modules/Compiler/XL-CXX.cmake @@ -0,0 +1 @@ +SET(CMAKE_CXX_VERBOSE_FLAG "-V") diff --git a/Modules/Compiler/XL-Fortran.cmake b/Modules/Compiler/XL-Fortran.cmake new file mode 100644 index 000000000..49d6bb2f3 --- /dev/null +++ b/Modules/Compiler/XL-Fortran.cmake @@ -0,0 +1,2 @@ +SET(CMAKE_Fortran_VERBOSE_FLAG "-V") +SET(CMAKE_Fortran_DEFINE_FLAG "-WF,-D") diff --git a/Modules/Platform/Linux-VisualAge-C.cmake b/Modules/Platform/Linux-VisualAge-C.cmake index 295226bbe..0622b63c3 100644 --- a/Modules/Platform/Linux-VisualAge-C.cmake +++ b/Modules/Platform/Linux-VisualAge-C.cmake @@ -1,2 +1 @@ -SET(CMAKE_SHARED_LIBRARY_C_FLAGS "") -SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") +include(Platform/Linux-XL-C) diff --git a/Modules/Platform/Linux-VisualAge-Fortran.cmake b/Modules/Platform/Linux-VisualAge-Fortran.cmake index 295226bbe..1939a8a2f 100644 --- a/Modules/Platform/Linux-VisualAge-Fortran.cmake +++ b/Modules/Platform/Linux-VisualAge-Fortran.cmake @@ -1,2 +1 @@ -SET(CMAKE_SHARED_LIBRARY_C_FLAGS "") -SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") +include(Platform/Linux-XL-Fortran) diff --git a/Modules/Platform/Linux-XL-C.cmake b/Modules/Platform/Linux-XL-C.cmake new file mode 100644 index 000000000..08370e246 --- /dev/null +++ b/Modules/Platform/Linux-XL-C.cmake @@ -0,0 +1,2 @@ +SET(CMAKE_SHARED_LIBRARY_C_FLAGS "") +SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") diff --git a/Modules/Platform/Linux-XL-Fortran.cmake b/Modules/Platform/Linux-XL-Fortran.cmake new file mode 100644 index 000000000..08370e246 --- /dev/null +++ b/Modules/Platform/Linux-XL-Fortran.cmake @@ -0,0 +1,2 @@ +SET(CMAKE_SHARED_LIBRARY_C_FLAGS "") +SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "")