Skip to content

Commit

Permalink
Prefix remaining CMake options except for CMake BUILD* variables (#4990)
Browse files Browse the repository at this point in the history
  • Loading branch information
byrnHDF authored Oct 22, 2024
1 parent 720b005 commit baa1e8e
Show file tree
Hide file tree
Showing 21 changed files with 108 additions and 99 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/cmake-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ jobs:
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_BUILD_CPP_LIB:BOOL=ON")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_BUILD_FORTRAN:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SANITIZERS:BOOL=ON")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DUSE_SANITIZER:STRING=Leak")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_USE_SANITIZER:STRING=Leak")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SZIP_ENCODING:BOOL=OFF")
Expand Down Expand Up @@ -295,7 +295,7 @@ jobs:
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_BUILD_CPP_LIB:BOOL=ON")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_BUILD_FORTRAN:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SANITIZERS:BOOL=ON")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DUSE_SANITIZER:STRING=Address")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_USE_SANITIZER:STRING=Address")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SZIP_ENCODING:BOOL=OFF")
Expand Down Expand Up @@ -395,7 +395,7 @@ jobs:
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_BUILD_CPP_LIB:BOOL=ON")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_BUILD_FORTRAN:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SANITIZERS:BOOL=ON")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DUSE_SANITIZER:STRING=Undefined")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_USE_SANITIZER:STRING=Undefined")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF")
set (ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF5_ENABLE_SZIP_ENCODING:BOOL=OFF")
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/main-cmake-spc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
-DHDF5_ENABLE_DIRECT_VFD:BOOL=ON \
-DHDF5_ENABLE_ROS3_VFD:BOOL=ON \
-DH5_NO_DEPRECATED_SYMBOLS:BOOL=OFF \
-DDEFAULT_API_VERSION:STRING=v16 \
-DHDF5_DEFAULT_API_VERSION:STRING=v16 \
$GITHUB_WORKSPACE
shell: bash

Expand Down Expand Up @@ -121,7 +121,7 @@ jobs:
-DHDF5_ENABLE_DIRECT_VFD:BOOL=ON \
-DHDF5_ENABLE_ROS3_VFD:BOOL=ON \
-DH5_NO_DEPRECATED_SYMBOLS:BOOL=OFF \
-DDEFAULT_API_VERSION:STRING=v18 \
-DHDF5_DEFAULT_API_VERSION:STRING=v18 \
$GITHUB_WORKSPACE
shell: bash

Expand Down Expand Up @@ -181,7 +181,7 @@ jobs:
-DHDF5_ENABLE_DIRECT_VFD:BOOL=ON \
-DHDF5_ENABLE_ROS3_VFD:BOOL=ON \
-DH5_NO_DEPRECATED_SYMBOLS:BOOL=OFF \
-DDEFAULT_API_VERSION:STRING=v110 \
-DHDF5_DEFAULT_API_VERSION:STRING=v110 \
$GITHUB_WORKSPACE
shell: bash

Expand Down Expand Up @@ -241,7 +241,7 @@ jobs:
-DHDF5_ENABLE_DIRECT_VFD:BOOL=ON \
-DHDF5_ENABLE_ROS3_VFD:BOOL=ON \
-DH5_NO_DEPRECATED_SYMBOLS:BOOL=OFF \
-DDEFAULT_API_VERSION:STRING=v112 \
-DHDF5_DEFAULT_API_VERSION:STRING=v112 \
$GITHUB_WORKSPACE
shell: bash

Expand Down Expand Up @@ -301,7 +301,7 @@ jobs:
-DHDF5_ENABLE_DIRECT_VFD:BOOL=ON \
-DHDF5_ENABLE_ROS3_VFD:BOOL=ON \
-DH5_NO_DEPRECATED_SYMBOLS:BOOL=OFF \
-DDEFAULT_API_VERSION:STRING=v114 \
-DHDF5_DEFAULT_API_VERSION:STRING=v114 \
$GITHUB_WORKSPACE
shell: bash

Expand Down Expand Up @@ -361,7 +361,7 @@ jobs:
-DHDF5_ENABLE_DIRECT_VFD:BOOL=ON \
-DHDF5_ENABLE_ROS3_VFD:BOOL=ON \
-DH5_NO_DEPRECATED_SYMBOLS:BOOL=OFF \
-DDEFAULT_API_VERSION:STRING=v116 \
-DHDF5_DEFAULT_API_VERSION:STRING=v116 \
$GITHUB_WORKSPACE
shell: bash

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vol_adios2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
-DHDF5_TEST_API_ENABLE_ASYNC:BOOL=ON \
-DHDF5_ENABLE_PARALLEL:BOOL=ON \
-DHDF5_ENABLE_THREADSAFE:BOOL=ON \
-DALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF \
${{ github.workspace }}/hdf5
cat src/libhdf5.settings
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vol_async.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ jobs:
-DHDF5_TEST_API_ENABLE_ASYNC:BOOL=ON \
-DHDF5_ENABLE_PARALLEL:BOOL=ON \
-DHDF5_ENABLE_THREADSAFE:BOOL=ON \
-DALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF \
-DHDF5_VOL_ALLOW_EXTERNAL:STRING="GIT" \
-DHDF5_VOL_URL01:STRING="https://github.com/HDFGroup/vol-async.git" \
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vol_cache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ jobs:
-DHDF5_TEST_API_ENABLE_ASYNC:BOOL=ON \
-DHDF5_ENABLE_PARALLEL:BOOL=ON \
-DHDF5_ENABLE_THREADSAFE:BOOL=ON \
-DALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF \
-DHDF5_VOL_ALLOW_EXTERNAL:STRING="GIT" \
-DHDF5_VOL_URL01:STRING="https://github.com/HDFGroup/vol-async.git" \
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vol_log.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
-DHDF5_TEST_API_ENABLE_ASYNC:BOOL=ON \
-DHDF5_ENABLE_PARALLEL:BOOL=ON \
-DHDF5_ENABLE_THREADSAFE:BOOL=ON \
-DALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF \
${{ github.workspace }}/hdf5
cat src/libhdf5.settings
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vol_rest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ jobs:
-DBUILD_STATIC_LIBS=OFF \
-DHDF5_BUILD_HL_LIB:BOOL=ON \
-DHDF5_TEST_API:BOOL=ON \
-DALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ALLOW_UNSUPPORTED:BOOL=ON \
-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF \
-DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=OFF \
-DHDF5_VOL_ALLOW_EXTERNAL:STRING="GIT" \
Expand Down
58 changes: 29 additions & 29 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -147,8 +147,8 @@ if (HDF5_USE_FOLDERS)
endif ()
option (HDF5_NO_PACKAGES "CPACK - Disable packaging" OFF)
mark_as_advanced (HDF5_NO_PACKAGES)
option (ALLOW_UNSUPPORTED "Allow unsupported combinations of configure options" OFF)
mark_as_advanced (ALLOW_UNSUPPORTED)
option (HDF5_ALLOW_UNSUPPORTED "Allow unsupported combinations of configure options" OFF)
mark_as_advanced (HDF5_ALLOW_UNSUPPORTED)

#-----------------------------------------------------------------------------
# Set the core names of all the libraries CORENAME is the base library name
Expand Down Expand Up @@ -519,8 +519,8 @@ endif ()
#-----------------------------------------------------------------------------
# Option to Build Shared and Static libs, default is both
#-----------------------------------------------------------------------------
option (ONLY_SHARED_LIBS "Only Build Shared Libraries" OFF)
mark_as_advanced (ONLY_SHARED_LIBS)
option (HDF5_ONLY_SHARED_LIBS "Only Build Shared Libraries" OFF)
mark_as_advanced (HDF5_ONLY_SHARED_LIBS)
option (BUILD_STATIC_LIBS "Build Static Libraries" ON)
set (H5_ENABLE_STATIC_LIB NO)
option (BUILD_SHARED_LIBS "Build Shared Libraries" ON)
Expand All @@ -530,11 +530,11 @@ option (HDF5_BUILD_STATIC_TOOLS "Build Static Tools NOT Shared Tools" OFF)

# only shared libraries/tools is true if user forces static OFF
if (NOT BUILD_STATIC_LIBS)
set (ONLY_SHARED_LIBS ON CACHE BOOL "Only Build Shared Libraries" FORCE)
set (HDF5_ONLY_SHARED_LIBS ON CACHE BOOL "Only Build Shared Libraries" FORCE)
endif ()

# only shared libraries is set ON by user then force settings
if (ONLY_SHARED_LIBS)
if (HDF5_ONLY_SHARED_LIBS)
set (H5_ENABLE_STATIC_LIB NO)
set (BUILD_SHARED_LIBS ON CACHE BOOL "Build Shared Libraries" FORCE)
set (BUILD_STATIC_LIBS OFF CACHE BOOL "Build Static Libraries" FORCE)
Expand Down Expand Up @@ -858,64 +858,64 @@ if (HDF5_ENABLE_SUBFILING_VFD)
endif()


set (DEFAULT_API_VERSION "v118" CACHE STRING "Enable v1.16 API (v16, v18, v110, v112, v114, v116, v118)")
set_property (CACHE DEFAULT_API_VERSION PROPERTY STRINGS v16 v18 v110 v112 v114 v116 v118)
set (HDF5_DEFAULT_API_VERSION "v118" CACHE STRING "Enable v1.16 API (v16, v18, v110, v112, v114, v116, v118)")
set_property (CACHE HDF5_DEFAULT_API_VERSION PROPERTY STRINGS v16 v18 v110 v112 v114 v116 v118)
#-----------------------------------------------------------------------------
# Option to use 1.6.x API
#-----------------------------------------------------------------------------
set (H5_USE_16_API_DEFAULT 0)
if (DEFAULT_API_VERSION MATCHES "v16")
if (HDF5_DEFAULT_API_VERSION MATCHES "v16")
set (H5_USE_16_API_DEFAULT 1)
endif ()

#-----------------------------------------------------------------------------
# Option to use 1.8.x API
#-----------------------------------------------------------------------------
set (H5_USE_18_API_DEFAULT 0)
if (DEFAULT_API_VERSION MATCHES "v18")
if (HDF5_DEFAULT_API_VERSION MATCHES "v18")
set (H5_USE_18_API_DEFAULT 1)
endif ()

#-----------------------------------------------------------------------------
# Option to use 1.10.x API
#-----------------------------------------------------------------------------
set (H5_USE_110_API_DEFAULT 0)
if (DEFAULT_API_VERSION MATCHES "v110")
if (HDF5_DEFAULT_API_VERSION MATCHES "v110")
set (H5_USE_110_API_DEFAULT 1)
endif ()

#-----------------------------------------------------------------------------
# Option to use 1.12.x API
#-----------------------------------------------------------------------------
set (H5_USE_112_API_DEFAULT 0)
if (DEFAULT_API_VERSION MATCHES "v112")
if (HDF5_DEFAULT_API_VERSION MATCHES "v112")
set (H5_USE_112_API_DEFAULT 1)
endif ()

#-----------------------------------------------------------------------------
# Option to use 1.14.x API
#-----------------------------------------------------------------------------
set (H5_USE_114_API_DEFAULT 0)
if (DEFAULT_API_VERSION MATCHES "v114")
if (HDF5_DEFAULT_API_VERSION MATCHES "v114")
set (H5_USE_114_API_DEFAULT 1)
endif ()

#-----------------------------------------------------------------------------
# Option to use 1.16.x API
#-----------------------------------------------------------------------------
set (H5_USE_116_API_DEFAULT 0)
if (DEFAULT_API_VERSION MATCHES "v116")
if (HDF5_DEFAULT_API_VERSION MATCHES "v116")
set (H5_USE_116_API_DEFAULT 1)
endif ()

#-----------------------------------------------------------------------------
# Option to use 1.18.x API
#-----------------------------------------------------------------------------
if (NOT DEFAULT_API_VERSION)
set (DEFAULT_API_VERSION "v118")
if (NOT HDF5_DEFAULT_API_VERSION)
set (HDF5_DEFAULT_API_VERSION "v118")
endif ()
set (H5_USE_118_API_DEFAULT 0)
if (DEFAULT_API_VERSION MATCHES "v118")
if (HDF5_DEFAULT_API_VERSION MATCHES "v118")
set (H5_USE_118_API_DEFAULT 1)
endif ()

Expand Down Expand Up @@ -956,29 +956,29 @@ if (HDF5_ENABLE_THREADSAFE)
endif ()
endif ()
if (HDF_ENABLE_PARALLEL)
if (NOT ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** Parallel and thread-safety options are not supported, override with ALLOW_UNSUPPORTED option **** ")
if (NOT HDF5_ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** Parallel and thread-safety options are not supported, override with HDF5_ALLOW_UNSUPPORTED option **** ")
else ()
message (VERBOSE " **** Allowing unsupported parallel and thread-safety options **** ")
endif ()
endif ()
if (HDF5_BUILD_FORTRAN)
if (NOT ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** Fortran and thread-safety options are not supported, override with ALLOW_UNSUPPORTED option **** ")
if (NOT HDF5_ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** Fortran and thread-safety options are not supported, override with HDF5_ALLOW_UNSUPPORTED option **** ")
else ()
message (VERBOSE " **** Allowing unsupported Fortran and thread-safety options **** ")
endif ()
endif ()
if (HDF5_BUILD_CPP_LIB)
if (NOT ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** C++ and thread-safety options are not supported, override with ALLOW_UNSUPPORTED option **** ")
if (NOT HDF5_ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** C++ and thread-safety options are not supported, override with HDF5_ALLOW_UNSUPPORTED option **** ")
else ()
message (VERBOSE " **** Allowing unsupported C++ and thread-safety options **** ")
endif ()
endif ()
if (HDF5_BUILD_HL_LIB)
if (NOT ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** HL and thread-safety options are not supported, override with ALLOW_UNSUPPORTED option **** ")
if (NOT HDF5_ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** HL and thread-safety options are not supported, override with HDF5_ALLOW_UNSUPPORTED option **** ")
else ()
message (VERBOSE " **** Allowing unsupported HL and thread-safety options **** ")
endif ()
Expand Down Expand Up @@ -1093,7 +1093,7 @@ endif ()
#-----------------------------------------------------------------------------
# Include filter plugins
#-----------------------------------------------------------------------------
if (${H5_LIBVER_DIR} EQUAL 16 OR DEFAULT_API_VERSION MATCHES "v16")
if (${H5_LIBVER_DIR} EQUAL 16 OR HDF5_DEFAULT_API_VERSION MATCHES "v16")
set (HDF5_ENABLE_PLUGIN_SUPPORT OFF CACHE BOOL "" FORCE)
message (VERBOSE "Filter PLUGINs cannot be used with 1.6 API")
else ()
Expand Down Expand Up @@ -1186,8 +1186,8 @@ if (EXISTS "${HDF5_SOURCE_DIR}/c++" AND IS_DIRECTORY "${HDF5_SOURCE_DIR}/c++")
if (HDF5_BUILD_CPP_LIB)
# check for unsupported options
if (HDF5_ENABLE_PARALLEL)
if (NOT ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** Parallel and C++ options are mutually exclusive, override with ALLOW_UNSUPPORTED option **** ")
if (NOT HDF5_ALLOW_UNSUPPORTED)
message (FATAL_ERROR " **** Parallel and C++ options are mutually exclusive, override with HDF5_ALLOW_UNSUPPORTED option **** ")
else ()
message (VERBOSE " **** Allowing unsupported Parallel and C++ options **** ")
endif ()
Expand Down Expand Up @@ -1229,7 +1229,7 @@ configure_file (${HDF_RESOURCES_DIR}/H5pubconf.h.in ${HDF5_SRC_BINARY_DIR}/H5pub
#-----------------------------------------------------------------------------
if (EXISTS "${HDF5_SOURCE_DIR}/HDF5Examples" AND IS_DIRECTORY "${HDF5_SOURCE_DIR}/HDF5Examples")
option (HDF5_BUILD_EXAMPLES "Build HDF5 Library Examples" ON)
if (HDF5_BUILD_EXAMPLES AND NOT USE_SANITIZER)
if (HDF5_BUILD_EXAMPLES AND NOT HDF5_USE_SANITIZER)
include (${HDF_RESOURCES_DIR}/HDF5ExampleCache.cmake)
set (HDF5_VERSION ${HDF5_PACKAGE_VERSION})
add_subdirectory (HDF5Examples)
Expand Down
10 changes: 5 additions & 5 deletions config/cmake-presets/hidden-presets.json
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@
"hidden": true,
"inherits": "ci-x64-Debug-MSVC",
"cacheVariables": {
"USE_SANITIZER": "Address",
"HDF5_USE_SANITIZER": "Address",
"HDF5_ENABLE_SANITIZERS": "ON"
}
},
Expand All @@ -278,7 +278,7 @@
"hidden": true,
"inherits": "ci-x64-Debug-GNUC",
"cacheVariables": {
"USE_SANITIZER": "Address",
"HDF5_USE_SANITIZER": "Address",
"HDF5_ENABLE_SANITIZERS": "ON"
}
},
Expand All @@ -287,7 +287,7 @@
"hidden": true,
"inherits": "ci-x64-Debug-GNUC",
"cacheVariables": {
"USE_SANITIZER": "Thread",
"HDF5_USE_SANITIZER": "Thread",
"HDF5_ENABLE_SANITIZERS": "ON"
}
},
Expand All @@ -296,7 +296,7 @@
"hidden": true,
"inherits": "ci-x64-Debug-GNUC",
"cacheVariables": {
"USE_SANITIZER": "Leak",
"HDF5_USE_SANITIZER": "Leak",
"HDF5_ENABLE_SANITIZERS": "ON"
}
},
Expand All @@ -305,7 +305,7 @@
"hidden": true,
"inherits": "ci-x64-Debug-GNUC",
"cacheVariables": {
"USE_SANITIZER": "Undefined",
"HDF5_USE_SANITIZER": "Undefined",
"HDF5_ENABLE_SANITIZERS": "ON"
}
}
Expand Down
16 changes: 8 additions & 8 deletions config/cmake/HDF5ExampleCache.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -26,22 +26,22 @@ set (EXAMPLES_EXTERNALLY_CONFIGURED ON CACHE BOOL "Examples build is used in ano
set (EXAMPLE_VARNAME "H5")
set (H5EX_RESOURCES_DIR ${HDF_RESOURCES_DIR})
message (STATUS "HDF5 Example H5EX_RESOURCES_DIR: ${H5EX_RESOURCES_DIR}")
if (DEFAULT_API_VERSION MATCHES "v16")
if (HDF5_DEFAULT_API_VERSION MATCHES "v16")
set (H5_USE_16_API ON)
elseif (DEFAULT_API_VERSION MATCHES "v18")
elseif (HDF5_DEFAULT_API_VERSION MATCHES "v18")
set (H5_USE_18_API ON)
elseif (DEFAULT_API_VERSION MATCHES "v110")
elseif (HDF5_DEFAULT_API_VERSION MATCHES "v110")
set (H5_USE_110_API ON)
elseif (DEFAULT_API_VERSION MATCHES "v112")
elseif (HDF5_DEFAULT_API_VERSION MATCHES "v112")
set (H5_USE_112_API ON)
elseif (DEFAULT_API_VERSION MATCHES "v114")
elseif (HDF5_DEFAULT_API_VERSION MATCHES "v114")
set (H5_USE_114_API ON)
elseif (DEFAULT_API_VERSION MATCHES "v116")
elseif (HDF5_DEFAULT_API_VERSION MATCHES "v116")
set (H5_USE_116_API ON)
elseif (DEFAULT_API_VERSION MATCHES "v118")
elseif (HDF5_DEFAULT_API_VERSION MATCHES "v118")
set (H5_USE_118_API ON)
endif ()
message (STATUS "HDF5 H5_LIBVER_DIR: ${H5_LIBVER_DIR} HDF5_API_VERSION: ${DEFAULT_API_VERSION}")
message (STATUS "HDF5 H5_LIBVER_DIR: ${H5_LIBVER_DIR} HDF5_API_VERSION: ${HDF5_DEFAULT_API_VERSION}")

if (NOT BUILD_SHARED_LIBS AND BUILD_STATIC_LIBS)
set (USE_SHARED_LIBS OFF CACHE BOOL "Use Shared Libraries for Examples" FORCE)
Expand Down
Loading

0 comments on commit baa1e8e

Please sign in to comment.