diff options
author | Allen Byrne <50328838+byrnHDF@users.noreply.github.com> | 2023-11-15 23:32:49 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-15 23:32:49 (GMT) |
commit | af8c1d1d872112ad741bbf05dda792c1626b93fd (patch) | |
tree | 3d2a1bc73ffc10fea7a5eaae2d746afb50597ce5 /hl | |
parent | 07f7ae4991e138b1ba27b84df790a7ad56222921 (diff) | |
download | hdf5-af8c1d1d872112ad741bbf05dda792c1626b93fd.zip hdf5-af8c1d1d872112ad741bbf05dda792c1626b93fd.tar.gz hdf5-af8c1d1d872112ad741bbf05dda792c1626b93fd.tar.bz2 |
Sync fixes for CI and presets (#3855)
* Sync fixes for CI and presets
* Sync the Fortran build changes
* Update fortran test file
* Sync hl/fortran files
* Merge the nvidia compiler flag changes
* Update link
* Update links to doxygen refs for 1.14
Diffstat (limited to 'hl')
-rw-r--r-- | hl/fortran/src/CMakeLists.txt | 18 | ||||
-rw-r--r-- | hl/fortran/src/H5LTff.F90 | 14 |
2 files changed, 14 insertions, 18 deletions
diff --git a/hl/fortran/src/CMakeLists.txt b/hl/fortran/src/CMakeLists.txt index ed469e5..f225eb8 100644 --- a/hl/fortran/src/CMakeLists.txt +++ b/hl/fortran/src/CMakeLists.txt @@ -22,9 +22,6 @@ if (WIN32 AND MSVC) set_target_properties (H5HL_buildiface PROPERTIES COMPILE_FLAGS "/MT") endif () endif () -#set_property(TARGET H5HL_buildiface APPEND PROPERTY -# LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>" -#) if(MSVC) set_property(TARGET H5HL_buildiface PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE") endif() @@ -182,8 +179,6 @@ if (BUILD_STATIC_LIBS) PRIVATE "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) target_link_libraries (${HDF5_HL_F90_LIB_TARGET} PUBLIC ${HDF5_HL_F90_C_LIB_TARGET} ${HDF5_F90_LIB_TARGET}) -# set_property(TARGET ${HDF5_HL_F90_LIB_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") -# set_property(TARGET ${HDF5_HL_F90_LIB_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET ${HDF5_HL_F90_LIB_TARGET} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -198,7 +193,12 @@ if (BUILD_STATIC_LIBS) add_dependencies(${HDF5_HL_F90_LIB_TARGET} H5HLgen) endif () if (BUILD_SHARED_LIBS) - add_library (${HDF5_HL_F90_LIBSH_TARGET} SHARED ${HDF5_HL_F90_F_SOURCES_SHARED}) + if(WIN32) + set(DLLDEF ${HDF5_HL_F90_SRC_BINARY_DIR}/hdf5_hl_fortrandll.def) + else() + set(DLLDEF "") + endif() + add_library (${HDF5_HL_F90_LIBSH_TARGET} SHARED ${DLLDEF} ${HDF5_HL_F90_F_SOURCES_SHARED}) target_include_directories (${HDF5_HL_F90_LIBSH_TARGET} PRIVATE "${HDF5_F90_BINARY_DIR};${CMAKE_Fortran_MODULE_DIRECTORY}/shared;$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_Fortran_INCLUDE_DIRS}>" INTERFACE "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${HDF5_INSTALL_MODULE_DIR}/shared>" @@ -214,12 +214,8 @@ if (BUILD_SHARED_LIBS) PUBLIC ${HDF5_HL_F90_C_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} PRIVATE ${LINK_Fortran_LIBS} ) -# set_property(TARGET ${HDF5_HL_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") -# set_property(TARGET ${HDF5_HL_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") -# set_property(TARGET ${HDF5_HL_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-DLL>") -# set_property(TARGET ${HDF5_HL_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-DEF:${HDF5_HL_F90_SRC_BINARY_DIR}/hdf5_hl_fortrandll.def>") if(MSVC) - set_property(TARGET ${HDF5_HL_F90_LIBSH_TARGET} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS} -DLL -DEF:${HDF5_HL_F90_SRC_BINARY_DIR}/hdf5_hl_fortrandll.def") + set_property(TARGET ${HDF5_HL_F90_LIBSH_TARGET} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() set_target_properties (${HDF5_HL_F90_LIBSH_TARGET} PROPERTIES FOLDER libraries/hl/fortran diff --git a/hl/fortran/src/H5LTff.F90 b/hl/fortran/src/H5LTff.F90 index 8b4e6d3..80e9fe7 100644 --- a/hl/fortran/src/H5LTff.F90 +++ b/hl/fortran/src/H5LTff.F90 @@ -1115,7 +1115,7 @@ CONTAINS f_ptr = C_LOC(buf(1:1)) -#if H5_FORTRAN_HAVE_STORAGE_SIZE!=0 +#ifdef H5_FORTRAN_HAVE_STORAGE_SIZE SizeOf_buf_type = STORAGE_SIZE(buf(1), c_size_t)/STORAGE_SIZE(c_char_'a',c_size_t) #else SizeOf_buf_type = SIZEOF(buf(1)) @@ -1165,7 +1165,7 @@ CONTAINS INTEGER(size_t) :: SizeOf_buf_type f_ptr = C_LOC(buf(1)) -#if H5_FORTRAN_HAVE_STORAGE_SIZE!=0 +#ifdef H5_FORTRAN_HAVE_STORAGE_SIZE SizeOf_buf_type = STORAGE_SIZE(buf(1), c_size_t)/STORAGE_SIZE(c_char_'a',c_size_t) #else SizeOf_buf_type = SIZEOF(buf(1)) @@ -1216,7 +1216,7 @@ CONTAINS f_ptr = C_LOC(buf(1)) -#if H5_FORTRAN_HAVE_STORAGE_SIZE!=0 +#ifdef H5_FORTRAN_HAVE_STORAGE_SIZE SizeOf_buf_type = STORAGE_SIZE(buf(1), c_size_t)/STORAGE_SIZE(c_char_'a',c_size_t) #else SizeOf_buf_type = SIZEOF(buf(1)) @@ -1264,7 +1264,7 @@ CONTAINS f_ptr = C_LOC(buf(1)(1:1)) -#if H5_FORTRAN_HAVE_STORAGE_SIZE!=0 +#ifdef H5_FORTRAN_HAVE_STORAGE_SIZE SizeOf_buf_type = STORAGE_SIZE(buf(1)(1:1), c_size_t)/STORAGE_SIZE(c_char_'a',c_size_t) #else SizeOf_buf_type = SIZEOF(buf(1:1)(1:1)) @@ -1363,7 +1363,7 @@ CONTAINS f_ptr = C_LOC(buf(1)) -#if H5_FORTRAN_HAVE_STORAGE_SIZE!=0 +#ifdef H5_FORTRAN_HAVE_STORAGE_SIZE SizeOf_buf = STORAGE_SIZE(buf(1), c_size_t)/STORAGE_SIZE(c_char_'a',c_size_t) #else SizeOf_buf = SIZEOF(buf(1)) @@ -1407,7 +1407,7 @@ CONTAINS INTEGER(size_t) :: SizeOf_buf f_ptr = C_LOC(buf(1)) -#if H5_FORTRAN_HAVE_STORAGE_SIZE!=0 +#ifdef H5_FORTRAN_HAVE_STORAGE_SIZE SizeOf_buf = STORAGE_SIZE(buf(1), c_size_t)/STORAGE_SIZE(c_char_'a',c_size_t) #else SizeOf_buf = SIZEOF(buf(1)) @@ -1451,7 +1451,7 @@ CONTAINS INTEGER(size_t) :: SizeOf_buf f_ptr = C_LOC(buf(1)) -#if H5_FORTRAN_HAVE_STORAGE_SIZE!=0 +#ifdef H5_FORTRAN_HAVE_STORAGE_SIZE SizeOf_buf = STORAGE_SIZE(buf(1), c_size_t)/STORAGE_SIZE(c_char_'a',c_size_t) #else SizeOf_buf = SIZEOF(buf(1)) |