summaryrefslogtreecommitdiffstats
path: root/Modules/CMakeCCompilerId.c.in
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2011-12-06 20:10:29 (GMT)
committerBrad King <brad.king@kitware.com>2011-12-07 14:39:48 (GMT)
commitb8cfa656ce7a59bc616eda8d4180ea9642291d07 (patch)
tree9c80e6576057a6570512814817c194b1b4d3243f /Modules/CMakeCCompilerId.c.in
parent6dae6660fce095681c41fada1d29ab7c80eb8810 (diff)
downloadCMake-b8cfa656ce7a59bc616eda8d4180ea9642291d07.zip
CMake-b8cfa656ce7a59bc616eda8d4180ea9642291d07.tar.gz
CMake-b8cfa656ce7a59bc616eda8d4180ea9642291d07.tar.bz2
Detect PGI compiler version with its id
Decode decimal digits from __PGIC__ __PGIC_MINOR__ __PGIC_PATCHLEVEL__ to compute version number components.
Diffstat (limited to 'Modules/CMakeCCompilerId.c.in')
-rw-r--r--Modules/CMakeCCompilerId.c.in5
1 files changed, 5 insertions, 0 deletions
diff --git a/Modules/CMakeCCompilerId.c.in b/Modules/CMakeCCompilerId.c.in
index e7738cf..6bae3a2 100644
--- a/Modules/CMakeCCompilerId.c.in
+++ b/Modules/CMakeCCompilerId.c.in
@@ -51,6 +51,11 @@
#elif defined(__PGI)
# define COMPILER_ID "PGI"
+# define COMPILER_VERSION_MAJOR DEC(__PGIC__)
+# define COMPILER_VERSION_MINOR DEC(__PGIC_MINOR__)
+# if defined(__PGIC_PATCHLEVEL__)
+# define COMPILER_VERSION_PATCH DEC(__PGIC_PATCHLEVEL__)
+# endif
#elif defined(__PATHSCALE__)
# define COMPILER_ID "PathScale"