summaryrefslogtreecommitdiffstats
path: root/config/cmake
diff options
context:
space:
mode:
authorLarry Knox <lrknox@hdfgroup.org>2019-01-05 13:41:12 (GMT)
committerLarry Knox <lrknox@hdfgroup.org>2019-01-05 13:41:12 (GMT)
commitcceb9f06b8f213ef1cb360a4ef900536669a8dad (patch)
tree1b0a48f66337d7d0c8f7e9a31a9663e8ce0754e5 /config/cmake
parentf9736d817e4b2e1c5ced39b232323c3b3f87d46a (diff)
parent0e34f0feaaeb6d2286f87f695f25fae45c070a42 (diff)
downloadhdf5-cceb9f06b8f213ef1cb360a4ef900536669a8dad.zip
hdf5-cceb9f06b8f213ef1cb360a4ef900536669a8dad.tar.gz
hdf5-cceb9f06b8f213ef1cb360a4ef900536669a8dad.tar.bz2
Merging in latest from upstream (HDFFV/hdf5:refs/heads/develop)
* commit '0e34f0feaaeb6d2286f87f695f25fae45c070a42': (26 commits) HDFFV-10664 update reference file HDFFV-10664 update reference files HDFFV-10664 add missing function and check for restriction Remove "bad" statements at end of TEST_ERROR. Formerly arguments to FAIL_PUTS_ERROR Add RELEASE.txt entry for HDFFV-10596. Add semicolon at end of TEST_ERROR() invocation for consistency. Uninstall should remove the libhdf5_hl_fortran links. Add symlinks named libhdf5_hl_fortran* to libhdf5hl_fortran in Makefile.am to match cmake install and the name pattern for other hl lib files. Change FAIL_PUTS_ERROR to TEST_ERROR. Cleaned up the parallel flush test and set t_pflush1 to always fail. Also set CMake to handle this. Update calls: H5Dcreate to H5Dcreate2, H5Acreate to H5Acreate2. Removed a comment. Fix comment Align H5Lcreate_ud behavior with documentation for NULL udata pointer Update toolchain comment Use c99 standard cmake variable Add PGI toolchain Correction based on code review. HDFFV-10664 add check for state before set call HDFFV-10546 refactor variable name ...
Diffstat (limited to 'config/cmake')
-rw-r--r--config/cmake/HDF5UseFortran.cmake16
-rw-r--r--config/cmake/HDFCompilerFlags.cmake6
2 files changed, 6 insertions, 16 deletions
diff --git a/config/cmake/HDF5UseFortran.cmake b/config/cmake/HDF5UseFortran.cmake
index 157befd..a24b2e1 100644
--- a/config/cmake/HDF5UseFortran.cmake
+++ b/config/cmake/HDF5UseFortran.cmake
@@ -18,16 +18,6 @@ ENABLE_LANGUAGE (Fortran)
set (HDF_PREFIX "H5")
include (CheckFortranFunctionExists)
-## Check for non-standard extenstion quadmath.h
-
-CHECK_INCLUDE_FILES(quadmath.h C_HAVE_QUADMATH)
-
-if (${C_HAVE_QUADMATH})
- set(${HDF_PREFIX}_HAVE_QUADMATH_H 1)
-else ()
- set(${HDF_PREFIX}_HAVE_QUADMATH_H 0)
-endif ()
-
# The provided CMake Fortran macros don't provide a general compile/run function
# so this one is used.
#-----------------------------------------------------------------------------
@@ -40,7 +30,7 @@ macro (FORTRAN_RUN FUNCTION_NAME SOURCE_CODE RUN_RESULT_VAR1 COMPILE_RESULT_VAR1
TRY_RUN (RUN_RESULT_VAR COMPILE_RESULT_VAR
${CMAKE_BINARY_DIR}
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompiler1.f90
- LINK_LIBRARIES "${CMAKE_REQUIRED_LIBRARIES}"
+ LINK_LIBRARIES "${HDF5_REQUIRED_LIBRARIES}"
)
if (${COMPILE_RESULT_VAR})
@@ -367,9 +357,9 @@ ENABLE_LANGUAGE (C)
#-----------------------------------------------------------------------------
macro (C_RUN FUNCTION_NAME SOURCE_CODE RETURN_VAR)
message (STATUS "Detecting C ${FUNCTION_NAME}")
- if (CMAKE_REQUIRED_LIBRARIES)
+ if (HDF5_REQUIRED_LIBRARIES)
set (CHECK_FUNCTION_EXISTS_ADD_LIBRARIES
- "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}")
+ "-DLINK_LIBRARIES:STRING=${HDF5_REQUIRED_LIBRARIES}")
else ()
set (CHECK_FUNCTION_EXISTS_ADD_LIBRARIES)
endif ()
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")