diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2017-01-10 23:09:53 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2017-01-10 23:10:03 (GMT) |
commit | e1bcae8a6a804490aa941a654e99b1dd18251411 (patch) | |
tree | ef2ea266500b5bfea473b15495d850c5640ab1ed /config/cmake/ConfigureChecks.cmake | |
parent | a4cd30d418838bee49ca112fdfbcc199889b4a21 (diff) | |
download | hdf5-e1bcae8a6a804490aa941a654e99b1dd18251411.zip hdf5-e1bcae8a6a804490aa941a654e99b1dd18251411.tar.gz hdf5-e1bcae8a6a804490aa941a654e99b1dd18251411.tar.bz2 |
Update cmake min version and cmake command convention
Diffstat (limited to 'config/cmake/ConfigureChecks.cmake')
-rw-r--r-- | config/cmake/ConfigureChecks.cmake | 86 |
1 files changed, 43 insertions, 43 deletions
diff --git a/config/cmake/ConfigureChecks.cmake b/config/cmake/ConfigureChecks.cmake index ec0aecf..1745e6c 100644 --- a/config/cmake/ConfigureChecks.cmake +++ b/config/cmake/ConfigureChecks.cmake @@ -6,7 +6,7 @@ include (${HDF_RESOURCES_EXT_DIR}/ConfigureChecks.cmake) if (HDF5_ENABLE_USING_MEMCHECKER) set (H5_USING_MEMCHECKER 1) -endif (HDF5_ENABLE_USING_MEMCHECKER) +endif () #----------------------------------------------------------------------------- # Option for --enable-strict-format-checks @@ -14,7 +14,7 @@ endif (HDF5_ENABLE_USING_MEMCHECKER) option (HDF5_STRICT_FORMAT_CHECKS "Whether to perform strict file format checks" OFF) if (HDF5_STRICT_FORMAT_CHECKS) set (H5_STRICT_FORMAT_CHECKS 1) -endif (HDF5_STRICT_FORMAT_CHECKS) +endif () MARK_AS_ADVANCED (HDF5_STRICT_FORMAT_CHECKS) #----------------------------------------------------------------------------- @@ -23,7 +23,7 @@ MARK_AS_ADVANCED (HDF5_STRICT_FORMAT_CHECKS) option (HDF5_METADATA_TRACE_FILE "Enable metadata trace file collection" OFF) if (HDF5_METADATA_TRACE_FILE) set (H5_METADATA_TRACE_FILE 1) -endif (HDF5_METADATA_TRACE_FILE) +endif () MARK_AS_ADVANCED (HDF5_METADATA_TRACE_FILE) # ---------------------------------------------------------------------- @@ -35,7 +35,7 @@ MARK_AS_ADVANCED (HDF5_METADATA_TRACE_FILE) option (HDF5_WANT_DATA_ACCURACY "IF data accuracy is guaranteed during data conversions" ON) if (HDF5_WANT_DATA_ACCURACY) set (H5_WANT_DATA_ACCURACY 1) -endif (HDF5_WANT_DATA_ACCURACY) +endif () MARK_AS_ADVANCED (HDF5_WANT_DATA_ACCURACY) # ---------------------------------------------------------------------- @@ -47,7 +47,7 @@ MARK_AS_ADVANCED (HDF5_WANT_DATA_ACCURACY) option (HDF5_WANT_DCONV_EXCEPTION "exception handling functions is checked during data conversions" ON) if (HDF5_WANT_DCONV_EXCEPTION) set (H5_WANT_DCONV_EXCEPTION 1) -endif (HDF5_WANT_DCONV_EXCEPTION) +endif () MARK_AS_ADVANCED (HDF5_WANT_DCONV_EXCEPTION) # ---------------------------------------------------------------------- @@ -56,7 +56,7 @@ MARK_AS_ADVANCED (HDF5_WANT_DCONV_EXCEPTION) option (HDF5_ENABLE_CODESTACK "Enable the function stack tracing (for developer debugging)." OFF) if (HDF5_ENABLE_CODESTACK) set (H5_HAVE_CODESTACK 1) -endif (HDF5_ENABLE_CODESTACK) +endif () MARK_AS_ADVANCED (HDF5_ENABLE_CODESTACK) #----------------------------------------------------------------------------- @@ -65,7 +65,7 @@ MARK_AS_ADVANCED (HDF5_ENABLE_CODESTACK) option (HDF5_ENABLE_HSIZET "Enable datasets larger than memory" ON) if (HDF5_ENABLE_HSIZET) set (${HDF_PREFIX}_HAVE_LARGE_HSIZET 1) -endif (HDF5_ENABLE_HSIZET) +endif () # so far we have no check for this set (H5_HAVE_TMPFILE 1) @@ -79,10 +79,10 @@ set (H5_DEFAULT_VFD H5FD_SEC2) if (NOT DEFINED "H5_DEFAULT_PLUGINDIR") if (WINDOWS) set (H5_DEFAULT_PLUGINDIR "%ALLUSERSPROFILE%\\\\hdf5\\\\lib\\\\plugin") - else (WINDOWS) + else () set (H5_DEFAULT_PLUGINDIR "/usr/local/hdf5/lib/plugin") - endif (WINDOWS) -endif (NOT DEFINED "H5_DEFAULT_PLUGINDIR") + endif () +endif () if (WINDOWS) set (H5_HAVE_WINDOWS 1) @@ -91,7 +91,7 @@ if (WINDOWS) # that is, "drive-letter:\" (e.g. "C:") or "drive-letter:/" (e.g. "C:/"). # (This flag should be _unset_ for all machines, except for Windows) set (H5_HAVE_WINDOW_PATH 1) -endif (WINDOWS) +endif () # ---------------------------------------------------------------------- # END of WINDOWS Hard code Values @@ -112,8 +112,8 @@ if (NOT WINDOWS) elseif (CLOCK_GETTIME_IN_LIBPOSIX4) set (H5_HAVE_CLOCK_GETTIME 1) list (APPEND LINK_LIBS posix4) - endif (CLOCK_GETTIME_IN_LIBC) -endif (NOT WINDOWS) + endif () +endif () #----------------------------------------------------------------------------- #----------------------------------------------------------------------------- @@ -131,26 +131,26 @@ if (NOT WINDOWS) OUTPUT_VARIABLE OUTPUT ) if (TEST_DIRECT_VFD_WORKS_COMPILE) - if (TEST_DIRECT_VFD_WORKS_RUN MATCHES 0) + if (TEST_DIRECT_VFD_WORKS_RUN MATCHES 0) HDF_FUNCTION_TEST (HAVE_DIRECT) set (CMAKE_REQUIRED_DEFINITIONS "${CMAKE_REQUIRED_DEFINITIONS} -D_GNU_SOURCE") add_definitions ("-D_GNU_SOURCE") - else (TEST_DIRECT_VFD_WORKS_RUN MATCHES 0) + else () set (TEST_DIRECT_VFD_WORKS "" CACHE INTERNAL ${msg}) message (STATUS "${msg}... no") file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log "Test TEST_DIRECT_VFD_WORKS Run failed with the following output and exit code:\n ${OUTPUT}\n" ) - endif (TEST_DIRECT_VFD_WORKS_RUN MATCHES 0) - else (TEST_DIRECT_VFD_WORKS_COMPILE ) + endif () + else ( ) set (TEST_DIRECT_VFD_WORKS "" CACHE INTERNAL ${msg}) message (STATUS "${msg}... no") file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log "Test TEST_DIRECT_VFD_WORKS Compile failed with the following output:\n ${OUTPUT}\n" ) - endif (TEST_DIRECT_VFD_WORKS_COMPILE) - endif (HDF5_ENABLE_DIRECT_VFD) -endif (NOT WINDOWS) + endif () + endif () +endif () #----------------------------------------------------------------------------- # Check if C has __float128 extension @@ -159,10 +159,10 @@ endif (NOT WINDOWS) CHECK_TYPE_SIZE("__float128" SIZEOF___FLOAT128) if(${HAVE_SIZEOF___FLOAT128}) SET(H5_HAVE_FLOAT128 1) -else (${HAVE_SIZEOF___FLOAT128}) +else () SET(H5_HAVE_FLOAT128 0) SET(SIZEOF___FLOAT128 0) -endif(${HAVE_SIZEOF___FLOAT128}) +endif() #----------------------------------------------------------------------------- # Macro to determine the various conversion capabilities @@ -177,41 +177,41 @@ MACRO (H5ConversionTests TEST msg) OUTPUT_VARIABLE OUTPUT ) if (${TEST}_COMPILE) - if (${TEST}_RUN MATCHES 0) + if (${TEST}_RUN MATCHES 0) set (${TEST} 1 CACHE INTERNAL ${msg}) message (STATUS "${msg}... yes") - else (${TEST}_RUN MATCHES 0) + else () set (${TEST} "" CACHE INTERNAL ${msg}) message (STATUS "${msg}... no") file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log "Test ${TEST} Run failed with the following output and exit code:\n ${OUTPUT}\n" ) - endif (${TEST}_RUN MATCHES 0) - else (${TEST}_COMPILE ) + endif () + else () set (${TEST} "" CACHE INTERNAL ${msg}) message (STATUS "${msg}... no") file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log "Test ${TEST} Compile failed with the following output:\n ${OUTPUT}\n" ) - endif (${TEST}_COMPILE) + endif () - endif ("${TEST}" MATCHES "^${TEST}$") -ENDMACRO (H5ConversionTests) + endif () +ENDMACRO () #----------------------------------------------------------------------------- # Macro to make some of the conversion tests easier to write/read #----------------------------------------------------------------------------- -MACRO (H5MiscConversionTest VAR TEST msg) +MACRO (H5MiscConversionTest VAR TEST msg) if ("${TEST}" MATCHES "^${TEST}$") if (${VAR}) set (${TEST} 1 CACHE INTERNAL ${msg}) message (STATUS "${msg}... yes") - else (${VAR}) + else () set (${TEST} "" CACHE INTERNAL ${msg}) message (STATUS "${msg}... no") - endif (${VAR}) - endif ("${TEST}" MATCHES "^${TEST}$") -ENDMACRO (H5MiscConversionTest) + endif () + endif () +ENDMACRO () #----------------------------------------------------------------------------- # Check various conversion capabilities @@ -219,9 +219,9 @@ ENDMACRO (H5MiscConversionTest) # ---------------------------------------------------------------------- # Set the flag to indicate that the machine is using a special algorithm to convert -# 'long double' to '(unsigned) long' values. (This flag should only be set for -# the IBM Power6 Linux. When the bit sequence of long double is -# 0x4351ccf385ebc8a0bfcc2a3c3d855620, the converted value of (unsigned)long +# 'long double' to '(unsigned) long' values. (This flag should only be set for +# the IBM Power6 Linux. When the bit sequence of long double is +# 0x4351ccf385ebc8a0bfcc2a3c3d855620, the converted value of (unsigned)long # is 0x004733ce17af227f, not the same as the library's conversion to 0x004733ce17af2282. # The machine's conversion gets the correct value. We define the macro and disable # this kind of test until we figure out what algorithm they use. @@ -229,10 +229,10 @@ ENDMACRO (H5MiscConversionTest) H5ConversionTests (H5_LDOUBLE_TO_LONG_SPECIAL "Checking IF your system converts long double to (unsigned) long values with special algorithm") # ---------------------------------------------------------------------- # Set the flag to indicate that the machine is using a special algorithm -# to convert some values of '(unsigned) long' to 'long double' values. -# (This flag should be off for all machines, except for IBM Power6 Linux, -# when the bit sequences are 003fff..., 007fff..., 00ffff..., 01ffff..., -# ..., 7fffff..., the compiler uses a unknown algorithm. We define a +# to convert some values of '(unsigned) long' to 'long double' values. +# (This flag should be off for all machines, except for IBM Power6 Linux, +# when the bit sequences are 003fff..., 007fff..., 00ffff..., 01ffff..., +# ..., 7fffff..., the compiler uses a unknown algorithm. We define a # macro and skip the test for now until we know about the algorithm. # H5ConversionTests (H5_LONG_TO_LDOUBLE_SPECIAL "Checking IF your system can convert (unsigned) long to long double values with special algorithm") @@ -261,7 +261,7 @@ H5ConversionTests (H5_NO_ALIGNMENT_RESTRICTIONS "Checking IF alignment restricti # ----------------------------------------------------------------------- # wrapper script variables -# +# set (prefix ${CMAKE_INSTALL_PREFIX}) set (exec_prefix "\${prefix}") set (libdir "${exec_prefix}/lib") @@ -272,4 +272,4 @@ set (CXX ${CMAKE_CXX_COMPILER}) set (FC ${CMAKE_Fortran_COMPILER}) foreach (LINK_LIB ${LINK_LIBS}) set (LIBS "${LIBS} -l${LINK_LIB}") -endforeach (LINK_LIB ${LINK_LIBS}) +endforeach () |