summaryrefslogtreecommitdiffstats
path: root/config/cmake/HDFCompilerFlags.cmake
diff options
context:
space:
mode:
authorVailin Choi <vchoi@jam.ad.hdfgroup.org>2018-01-23 22:00:31 (GMT)
committerVailin Choi <vchoi@jam.ad.hdfgroup.org>2018-01-23 22:00:31 (GMT)
commitbe77e5935356f13daef03af1562476b516131c18 (patch)
tree40103d28749e572a7f84bbb0a72ba27d51c9e3b6 /config/cmake/HDFCompilerFlags.cmake
parent8427eefafe7af83dbc133975c3ac2368cf1b08d6 (diff)
parentc5e311897444abe43b9dafcf0225e9fb880a3e2b (diff)
downloadhdf5-be77e5935356f13daef03af1562476b516131c18.zip
hdf5-be77e5935356f13daef03af1562476b516131c18.tar.gz
hdf5-be77e5935356f13daef03af1562476b516131c18.tar.bz2
Merge branch 'develop' into bugfix/version_bounds
Keep the branch up-to-date.
Diffstat (limited to 'config/cmake/HDFCompilerFlags.cmake')
-rw-r--r--config/cmake/HDFCompilerFlags.cmake6
1 files changed, 3 insertions, 3 deletions
diff --git a/config/cmake/HDFCompilerFlags.cmake b/config/cmake/HDFCompilerFlags.cmake
index eeb4b97..a414cea 100644
--- a/config/cmake/HDFCompilerFlags.cmake
+++ b/config/cmake/HDFCompilerFlags.cmake
@@ -13,12 +13,12 @@
# Compiler specific flags : Shouldn't there be compiler tests for these
#-----------------------------------------------------------------------------
if (CMAKE_COMPILER_IS_GNUCC)
- if (HDF5_BUILD_TYPE MATCHES Debug)
+ if (${HDF_CFG_NAME} MATCHES "Debug")
set (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -std=c99")
if (NOT CMAKE_C_COMPILER_VERSION VERSION_LESS 5.0)
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Og -ftrapv -fno-common")
endif ()
- else (HDF5_BUILD_TYPE MATCHES Debug)
+ else ()
set (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -std=c99")
if (NOT CMAKE_C_COMPILER_VERSION VERSION_LESS 5.0)
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fstdarg-opt")
@@ -26,7 +26,7 @@ if (CMAKE_COMPILER_IS_GNUCC)
endif ()
endif ()
if (CMAKE_COMPILER_IS_GNUCXX AND CMAKE_CXX_COMPILER_LOADED)
- if (HDF5_BUILD_TYPE MATCHES Debug)
+ if (${HDF_CFG_NAME} MATCHES "Debug")
set (CMAKE_CXX_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_CXX_FLAGS}")
if (NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.0)
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Og -ftrapv -fno-common")