summaryrefslogtreecommitdiffstats
path: root/Modules/CMakeFortranCompilerABI.F
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-04-10 16:55:22 (GMT)
committerBrad King <brad.king@kitware.com>2014-04-10 16:57:02 (GMT)
commiteb8cb2c6c203418a23551ca85afa6292dededa81 (patch)
tree8331bc3f9c630bab3a36b1ae657ec0e8e5af4365 /Modules/CMakeFortranCompilerABI.F
parenta48de7d8506325e7f27c9dada578744e1ff3fb35 (diff)
downloadCMake-eb8cb2c6c203418a23551ca85afa6292dededa81.zip
CMake-eb8cb2c6c203418a23551ca85afa6292dededa81.tar.gz
CMake-eb8cb2c6c203418a23551ca85afa6292dededa81.tar.bz2
Fortran: Detect pointer size on Intel archs with PGI (#14870)
The PGI compiler does not define __SIZEOF_POINTER__ so use the __x86_64__ or __i386__ CPU macros to select a pointer size instead.
Diffstat (limited to 'Modules/CMakeFortranCompilerABI.F')
-rw-r--r--Modules/CMakeFortranCompilerABI.F4
1 files changed, 4 insertions, 0 deletions
diff --git a/Modules/CMakeFortranCompilerABI.F b/Modules/CMakeFortranCompilerABI.F
index 21ca7ff..b34c284 100644
--- a/Modules/CMakeFortranCompilerABI.F
+++ b/Modules/CMakeFortranCompilerABI.F
@@ -10,11 +10,15 @@
PRINT *, 'INFO:sizeof_dptr[8]'
#elif defined(_M_AMD64)
PRINT *, 'INFO:sizeof_dptr[8]'
+#elif defined(__x86_64__)
+ PRINT *, 'INFO:sizeof_dptr[8]'
#elif defined(_ILP32)
PRINT *, 'INFO:sizeof_dptr[4]'
#elif defined(_M_IX86)
PRINT *, 'INFO:sizeof_dptr[4]'
+#elif defined(__i386__)
+ PRINT *, 'INFO:sizeof_dptr[4]'
#elif defined(__SIZEOF_POINTER__) && __SIZEOF_POINTER__ == 8
PRINT *, 'INFO:sizeof_dptr[8]'