summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2019-01-03 20:47:10 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2019-01-03 20:47:10 (GMT)
commit2a28b92e2bb7748e123a9ee5ccad1c8bcb42462d (patch)
tree4db45250b710e87b5ee8aad2709cde931edd0d21
parent5daddcc2d48be73abb46f4c89e9ff82dc8f68983 (diff)
parentf4516d40feb7ea696e228253bc64a94f55296cbb (diff)
downloadhdf5-2a28b92e2bb7748e123a9ee5ccad1c8bcb42462d.zip
hdf5-2a28b92e2bb7748e123a9ee5ccad1c8bcb42462d.tar.gz
hdf5-2a28b92e2bb7748e123a9ee5ccad1c8bcb42462d.tar.bz2
Merge pull request #1426 in HDFFV/hdf5 from ~BYRN/hdf5_adb:develop to develop
* commit 'f4516d40feb7ea696e228253bc64a94f55296cbb': Fix comment Update toolchain comment Use c99 standard cmake variable Add PGI toolchain
-rw-r--r--MANIFEST1
-rw-r--r--config/cmake/HDFCompilerFlags.cmake6
-rw-r--r--config/toolchain/GCC.cmake3
-rw-r--r--config/toolchain/PGI.cmake11
-rw-r--r--config/toolchain/crayle.cmake3
-rw-r--r--config/toolchain/intel.cmake1
6 files changed, 20 insertions, 5 deletions
diff --git a/MANIFEST b/MANIFEST
index a086a06..7ea34e4 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -3192,6 +3192,7 @@
./config/toolchain/crayle.cmake
./config/toolchain/GCC.cmake
./config/toolchain/intel.cmake
+./config/toolchain/PGI.cmake
./config/cmake/cacheinit.cmake
./config/cmake/CMakeFindJavaCommon.cmake
diff --git a/config/cmake/HDFCompilerFlags.cmake b/config/cmake/HDFCompilerFlags.cmake
index 93ebc3c..0a39568 100644
--- a/config/cmake/HDFCompilerFlags.cmake
+++ b/config/cmake/HDFCompilerFlags.cmake
@@ -9,16 +9,16 @@
# If you do not have access to either file, you may request a copy from
# help@hdfgroup.org.
#
+set(CMAKE_C_STANDARD 99)
+set(CMAKE_C_STANDARD_REQUIRED TRUE)
message (STATUS "Warnings Configuration:")
+set (CMAKE_C_FLAGS "${CMAKE_C99_STANDARD_COMPILE_OPTION} ${CMAKE_C_FLAGS}")
#-----------------------------------------------------------------------------
# Compiler specific flags : Shouldn't there be compiler tests for these
#-----------------------------------------------------------------------------
if (CMAKE_COMPILER_IS_GNUCC)
set (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS}")
- if (NOT CYGWIN)
- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
- endif ()
if (${HDF_CFG_NAME} MATCHES "Debug")
if (NOT CMAKE_C_COMPILER_VERSION VERSION_LESS 5.0)
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Og -ftrapv -fno-common")
diff --git a/config/toolchain/GCC.cmake b/config/toolchain/GCC.cmake
index ddb1641..c41d0ca 100644
--- a/config/toolchain/GCC.cmake
+++ b/config/toolchain/GCC.cmake
@@ -1,5 +1,6 @@
-# Uncomment the following to use cross-compiling
+# Uncomment the following line and the correct system name to use cross-compiling
#set(CMAKE_SYSTEM_NAME Linux)
+
set(CMAKE_COMPILER_VENDOR "GCC")
set(CMAKE_C_COMPILER cc)
diff --git a/config/toolchain/PGI.cmake b/config/toolchain/PGI.cmake
new file mode 100644
index 0000000..ec58cbb
--- /dev/null
+++ b/config/toolchain/PGI.cmake
@@ -0,0 +1,11 @@
+# Uncomment the following to use cross-compiling
+#set(CMAKE_SYSTEM_NAME Linux)
+
+set(CMAKE_COMPILER_VENDOR "PGI")
+
+set(CMAKE_C_COMPILER pgcc)
+set(CMAKE_CXX_COMPILER pgc++)
+set(CMAKE_Fortran_COMPILER pgf90)
+
+# the following is used if cross-compiling
+set(CMAKE_CROSSCOMPILING_EMULATOR "")
diff --git a/config/toolchain/crayle.cmake b/config/toolchain/crayle.cmake
index a83147b..47d8afc 100644
--- a/config/toolchain/crayle.cmake
+++ b/config/toolchain/crayle.cmake
@@ -1,5 +1,6 @@
-# Uncomment the following to use cross-compiling
+# The following line will use cross-compiling
set(CMAKE_SYSTEM_NAME Linux)
+
set(CMAKE_COMPILER_VENDOR "CrayLinuxEnvironment")
set(CMAKE_C_COMPILER cc)
diff --git a/config/toolchain/intel.cmake b/config/toolchain/intel.cmake
index f1a5734..97f6a64 100644
--- a/config/toolchain/intel.cmake
+++ b/config/toolchain/intel.cmake
@@ -1,5 +1,6 @@
# Uncomment the following to use cross-compiling
#set(CMAKE_SYSTEM_NAME Linux)
+
set(CMAKE_COMPILER_VENDOR "intel")
set(CMAKE_C_COMPILER icc)