mirror of
https://github.com/HDFGroup/hdf5.git
synced 2025-03-31 17:10:47 +08:00
Merge pull request #784 in HDFFV/hdf5 from ~BYRN/hdf5_adb:hdf5_1_10 to hdf5_1_10
* commit '2e3f1b1600b47ac9b89fa41ec7e2a98a78c8a6b7': replace deleted note HDFFV-10328 fix typos HDFFV-10328 - remove plugin allocation changes HDFFV-10328, HDFFV-10329 Merge from develop Fix snprintf to HDsnprintf usage - breaks windows HDFFV-10329 - add new jira issue. Fix linking of libs
This commit is contained in:
commit
db8b5ca2ca
@ -45,8 +45,8 @@ if (HDF5_ENABLE_Z_LIB_SUPPORT)
|
||||
if (NOT ZLIB_FOUND)
|
||||
find_package (ZLIB) # Legacy find
|
||||
if (ZLIB_FOUND)
|
||||
set (LINK_LIBS ${LINK_LIBS} ${ZLIB_LIBRARIES})
|
||||
set (LINK_SHARED_LIBS ${LINK_SHARED_LIBS} ${ZLIB_LIBRARIES})
|
||||
set (LINK_COMP_LIBS ${LINK_COMP_LIBS} ${ZLIB_LIBRARIES})
|
||||
set (LINK_COMP_SHARED_LIBS ${LINK_COMP_SHARED_LIBS} ${ZLIB_LIBRARIES})
|
||||
endif ()
|
||||
endif ()
|
||||
endif ()
|
||||
@ -78,9 +78,9 @@ if (HDF5_ENABLE_Z_LIB_SUPPORT)
|
||||
set (EXTERNAL_FILTERS "${EXTERNAL_FILTERS} DEFLATE")
|
||||
endif ()
|
||||
if (BUILD_SHARED_LIBS)
|
||||
set (LINK_SHARED_LIBS ${LINK_SHARED_LIBS} ${ZLIB_SHARED_LIBRARY})
|
||||
set (LINK_COMP_SHARED_LIBS ${LINK_COMP_SHARED_LIBS} ${ZLIB_SHARED_LIBRARY})
|
||||
endif ()
|
||||
set (LINK_LIBS ${LINK_LIBS} ${ZLIB_STATIC_LIBRARY})
|
||||
set (LINK_COMP_LIBS ${LINK_COMP_LIBS} ${ZLIB_STATIC_LIBRARY})
|
||||
INCLUDE_DIRECTORIES (${ZLIB_INCLUDE_DIRS})
|
||||
message (STATUS "Filter ZLIB is ON")
|
||||
endif ()
|
||||
@ -96,8 +96,8 @@ if (HDF5_ENABLE_SZIP_SUPPORT)
|
||||
if (NOT SZIP_FOUND)
|
||||
find_package (SZIP) # Legacy find
|
||||
if (SZIP_FOUND)
|
||||
set (LINK_LIBS ${LINK_LIBS} ${SZIP_LIBRARIES})
|
||||
set (LINK_SHARED_LIBS ${LINK_SHARED_LIBS} ${SZIP_LIBRARIES})
|
||||
set (LINK_COMP_LIBS ${LINK_COMP_LIBS} ${SZIP_LIBRARIES})
|
||||
set (LINK_COMP_SHARED_LIBS ${LINK_COMP_SHARED_LIBS} ${SZIP_LIBRARIES})
|
||||
endif ()
|
||||
endif ()
|
||||
endif ()
|
||||
@ -119,9 +119,9 @@ if (HDF5_ENABLE_SZIP_SUPPORT)
|
||||
endif ()
|
||||
endif ()
|
||||
if (BUILD_SHARED_LIBS)
|
||||
set (LINK_SHARED_LIBS ${LINK_SHARED_LIBS} ${SZIP_SHARED_LIBRARY})
|
||||
set (LINK_COMP_SHARED_LIBS ${LINK_COMP_SHARED_LIBS} ${SZIP_SHARED_LIBRARY})
|
||||
endif ()
|
||||
set (LINK_LIBS ${LINK_LIBS} ${SZIP_STATIC_LIBRARY})
|
||||
set (LINK_COMP_LIBS ${LINK_COMP_LIBS} ${SZIP_STATIC_LIBRARY})
|
||||
INCLUDE_DIRECTORIES (${SZIP_INCLUDE_DIRS})
|
||||
message (STATUS "Filter SZIP is ON")
|
||||
if (H5_HAVE_FILTER_SZIP)
|
||||
|
@ -482,7 +482,6 @@ option (BUILD_SHARED_LIBS "Build Shared Libraries" ON)
|
||||
set (H5_ENABLE_SHARED_LIB NO)
|
||||
if (BUILD_SHARED_LIBS)
|
||||
set (H5_ENABLE_SHARED_LIB YES)
|
||||
set (LINK_SHARED_LIBS ${LINK_LIBS})
|
||||
endif ()
|
||||
set (H5_ENABLE_STATIC_LIB YES)
|
||||
set (CMAKE_POSITION_INDEPENDENT_CODE ON)
|
||||
|
@ -126,7 +126,7 @@ set (f90CStub_C_HDRS
|
||||
|
||||
add_library (${HDF5_F90_C_LIB_TARGET} STATIC ${f90CStub_C_SOURCES} ${f90CStub_C_HDRS})
|
||||
TARGET_C_PROPERTIES (${HDF5_F90_C_LIB_TARGET} STATIC " " " ")
|
||||
target_link_libraries (${HDF5_F90_C_LIB_TARGET} ${HDF5_LIB_TARGET} ${LINK_LIBS})
|
||||
target_link_libraries (${HDF5_F90_C_LIB_TARGET} PUBLIC ${HDF5_LIB_TARGET})
|
||||
set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_F90_C_LIB_TARGET}")
|
||||
H5_SET_LIB_OPTIONS (${HDF5_F90_C_LIB_TARGET} ${HDF5_F90_C_LIB_NAME} STATIC)
|
||||
set_target_properties (${HDF5_F90_C_LIB_TARGET} PROPERTIES
|
||||
@ -139,7 +139,7 @@ set (install_targets ${HDF5_F90_C_LIB_TARGET})
|
||||
if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED)
|
||||
add_library (${HDF5_F90_C_LIBSH_TARGET} SHARED ${f90CStub_C_SOURCES} ${f90CStub_C_HDRS})
|
||||
TARGET_C_PROPERTIES (${HDF5_F90_C_LIBSH_TARGET} SHARED " " " ")
|
||||
target_link_libraries (${HDF5_F90_C_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} ${LINK_SHARED_LIBS})
|
||||
target_link_libraries (${HDF5_F90_C_LIBSH_TARGET} PUBLIC ${HDF5_LIBSH_TARGET})
|
||||
set_global_variable (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF5_F90_C_LIBSH_TARGET}")
|
||||
H5_SET_LIB_OPTIONS (${HDF5_F90_C_LIBSH_TARGET} ${HDF5_F90_C_LIB_NAME} SHARED ${HDF5_F_PACKAGE_SOVERSION})
|
||||
set_target_properties (${HDF5_F90_C_LIBSH_TARGET} PROPERTIES
|
||||
@ -241,7 +241,8 @@ endif ()
|
||||
add_library (${HDF5_F90_LIB_TARGET} STATIC ${f90_F_SOURCES})
|
||||
set (SHARED_LINK_FLAGS " ")
|
||||
TARGET_FORTRAN_PROPERTIES (${HDF5_F90_LIB_TARGET} STATIC " " " ")
|
||||
target_link_libraries (${HDF5_F90_LIB_TARGET} ${HDF5_F90_C_LIB_TARGET} ${HDF5_LIB_TARGET} ${LINK_Fortran_LIBS})
|
||||
target_link_libraries (${HDF5_F90_LIB_TARGET} PUBLIC ${HDF5_F90_C_LIB_TARGET})
|
||||
target_link_libraries (${HDF5_F90_LIB_TARGET} PRIVATE ${LINK_Fortran_LIBS})
|
||||
if (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND)
|
||||
target_include_directories (${HDF5_F90_LIB_TARGET} PUBLIC ${MPI_Fortran_INCLUDE_DIRS})
|
||||
endif ()
|
||||
@ -268,7 +269,8 @@ if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED)
|
||||
set (SHARED_LINK_FLAGS "/DLL /DEF:${HDF5_F90_SRC_BINARY_DIR}/hdf5_fortrandll.def")
|
||||
endif ()
|
||||
TARGET_FORTRAN_PROPERTIES (${HDF5_F90_LIBSH_TARGET} SHARED " " ${SHARED_LINK_FLAGS})
|
||||
target_link_libraries (${HDF5_F90_LIBSH_TARGET} ${HDF5_F90_C_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} ${LINK_Fortran_LIBS})
|
||||
target_link_libraries (${HDF5_F90_LIBSH_TARGET} PUBLIC ${HDF5_F90_C_LIBSH_TARGET})
|
||||
target_link_libraries (${HDF5_F90_LIBSH_TARGET} PRIVATE ${LINK_Fortran_LIBS})
|
||||
if (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND)
|
||||
target_include_directories (${HDF5_F90_LIBSH_TARGET} PUBLIC ${MPI_Fortran_INCLUDE_DIRS})
|
||||
endif ()
|
||||
|
@ -231,6 +231,17 @@ Bug Fixes since HDF5-1.10.1 release
|
||||
|
||||
Library
|
||||
-------
|
||||
- filter plugin handling in H5PL.c and H5Z.c
|
||||
|
||||
It was discovered that the dynamic loading process used by
|
||||
filter plugins had issues with library dependencies.
|
||||
|
||||
CMake build process changed to use LINK INTERFACE keywords, which
|
||||
allowed HDF5 C library to make dependent libraries private. The
|
||||
filter plugin libraries no longer require dependent libraries
|
||||
(such as szip or zlib) to be available.
|
||||
(ADB - 2017/11/16, HDFFV-10328)
|
||||
|
||||
- Fix rare object header corruption bug
|
||||
|
||||
In certain cases, such as when converting large attributes to dense
|
||||
@ -307,6 +318,18 @@ Bug Fixes since HDF5-1.10.1 release
|
||||
|
||||
Configuration
|
||||
-------------
|
||||
- cmake
|
||||
|
||||
The hdf5 library used shared szip and zlib, which needlessly required
|
||||
applications to link with the same szip and zlib libraries.
|
||||
|
||||
Changed the target_link_libraries commands to use the static libs.
|
||||
Removed improper link duplication of szip and zlib.
|
||||
Adjusted the link dependencies and the link interface values of
|
||||
the target_link_libraries commands.
|
||||
|
||||
(ADB - 2017/11/14, HDFFV-10329)
|
||||
|
||||
- cmake MPI
|
||||
|
||||
CMake implementation for MPI was problematic and would create incorrect
|
||||
@ -348,6 +371,7 @@ Bug Fixes since HDF5-1.10.1 release
|
||||
|
||||
Too many commands for POST_BUILD step caused command line to be
|
||||
too big on windows.
|
||||
|
||||
Changed foreach of copy command to use a custom command with the
|
||||
use of the HDFTEST_COPY_FILE macro.
|
||||
|
||||
|
@ -881,7 +881,7 @@ set (gen_SRCS ${HDF5_BINARY_DIR}/H5Tinit.c ${HDF5_BINARY_DIR}/H5lib_settings.c)
|
||||
|
||||
add_library (${HDF5_LIB_TARGET} STATIC ${common_SRCS} ${gen_SRCS} ${H5_PUBLIC_HEADERS} ${H5_PRIVATE_HEADERS} ${H5_GENERATED_HEADERS})
|
||||
TARGET_C_PROPERTIES (${HDF5_LIB_TARGET} STATIC " " " ")
|
||||
target_link_libraries (${HDF5_LIB_TARGET} PUBLIC ${LINK_LIBS})
|
||||
target_link_libraries (${HDF5_LIB_TARGET} PRIVATE ${LINK_LIBS} ${LINK_COMP_LIBS})
|
||||
if (NOT WIN32)
|
||||
target_link_libraries (${HDF5_LIB_TARGET} PUBLIC dl)
|
||||
endif ()
|
||||
@ -925,7 +925,7 @@ if (BUILD_SHARED_LIBS)
|
||||
set (shared_gen_SRCS ${HDF5_BINARY_DIR}/shared/H5Tinit.c ${HDF5_BINARY_DIR}/shared/H5lib_settings.c)
|
||||
add_library (${HDF5_LIBSH_TARGET} SHARED ${common_SRCS} ${shared_gen_SRCS} ${H5_PUBLIC_HEADERS} ${H5_PRIVATE_HEADERS} ${H5_GENERATED_HEADERS})
|
||||
TARGET_C_PROPERTIES (${HDF5_LIBSH_TARGET} SHARED " " " ")
|
||||
target_link_libraries (${HDF5_LIBSH_TARGET} PUBLIC ${LINK_SHARED_LIBS})
|
||||
target_link_libraries (${HDF5_LIBSH_TARGET} PRIVATE ${LINK_LIBS} ${LINK_COMP_LIBS})
|
||||
if (NOT WIN32)
|
||||
target_link_libraries (${HDF5_LIBSH_TARGET} PUBLIC dl)
|
||||
endif ()
|
||||
|
@ -283,11 +283,11 @@ H5PL__find_plugin_in_cache(const H5PL_search_params_t *search_params, hbool_t *f
|
||||
|
||||
/* Get the "get plugin info" function from the plugin. */
|
||||
if (NULL == (get_plugin_info_function = (H5PL_get_plugin_info_t)H5PL_GET_LIB_FUNC((H5PL_cache_g[u]).handle, "H5PLget_plugin_info")))
|
||||
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTGET, FAIL, "can't get function for H5PLget_plugin_info")
|
||||
HGOTO_ERROR(H5E_PLUGIN, H5E_CANTGET, FAIL, "can't get function for H5PLget_plugin_info")
|
||||
|
||||
/* Call the "get plugin info" function */
|
||||
if (NULL == (filter_info = (const H5Z_class2_t *)(*get_plugin_info_function)()))
|
||||
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTGET, FAIL, "can't get plugin info")
|
||||
HGOTO_ERROR(H5E_PLUGIN, H5E_CANTGET, FAIL, "can't get plugin info")
|
||||
|
||||
/* Set output parameters */
|
||||
*found = TRUE;
|
||||
|
@ -37,7 +37,7 @@ endif ()
|
||||
if (MINGW)
|
||||
target_link_libraries (${HDF5_TEST_LIB_TARGET} "wsock32.lib")
|
||||
endif ()
|
||||
target_link_libraries (${HDF5_TEST_LIB_TARGET} ${HDF5_LIB_TARGET})
|
||||
target_link_libraries (${HDF5_TEST_LIB_TARGET} ${HDF5_LIB_TARGET} ${LINK_LIBS})
|
||||
H5_SET_LIB_OPTIONS (${HDF5_TEST_LIB_TARGET} ${HDF5_TEST_LIB_NAME} STATIC)
|
||||
set_target_properties (${HDF5_TEST_LIB_TARGET} PROPERTIES
|
||||
FOLDER libraries/test
|
||||
@ -53,7 +53,7 @@ if (BUILD_SHARED_LIBS)
|
||||
if (MINGW)
|
||||
target_link_libraries (${HDF5_TEST_LIBSH_TARGET} "wsock32.lib")
|
||||
endif ()
|
||||
target_link_libraries (${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET})
|
||||
target_link_libraries (${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} ${LINK_LIBS})
|
||||
H5_SET_LIB_OPTIONS (${HDF5_TEST_LIBSH_TARGET} ${HDF5_TEST_LIB_NAME} SHARED ${HDF5_PACKAGE_SOVERSION})
|
||||
set_target_properties (${HDF5_TEST_LIBSH_TARGET} PROPERTIES
|
||||
FOLDER libraries/test
|
||||
|
@ -2087,7 +2087,7 @@ test_get_filter_info(void)
|
||||
#ifdef H5_HAVE_FILTER_SZIP
|
||||
if(H5Zget_filter_info(H5Z_FILTER_SZIP, &flags) < 0) TEST_ERROR
|
||||
|
||||
if(SZ_encoder_enabled()) {
|
||||
if(H5Z_SZIP->encoder_present) {
|
||||
if(((flags & H5Z_FILTER_CONFIG_ENCODE_ENABLED) == 0) ||
|
||||
((flags & H5Z_FILTER_CONFIG_DECODE_ENABLED) == 0))
|
||||
TEST_ERROR
|
||||
|
794
test/tattr.c
794
test/tattr.c
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user