diff options
Diffstat (limited to 'fortran')
-rw-r--r-- | fortran/examples/CMakeLists.txt | 27 | ||||
-rw-r--r-- | fortran/examples/ph5example.f90 | 8 | ||||
-rw-r--r-- | fortran/src/CMakeLists.txt | 24 | ||||
-rw-r--r-- | fortran/src/H5Dff.F90 | 1 | ||||
-rw-r--r-- | fortran/src/H5Pff.F90 | 2 | ||||
-rw-r--r-- | fortran/src/H5Sff.F90 | 2 | ||||
-rw-r--r-- | fortran/src/H5_buildiface.F90 | 1 | ||||
-rw-r--r-- | fortran/test/CMakeLists.txt | 58 | ||||
-rw-r--r-- | fortran/test/tH5D.F90 | 3 | ||||
-rw-r--r-- | fortran/test/tH5G_1_8.F90 | 70 | ||||
-rw-r--r-- | fortran/test/tH5P_F03.F90 | 3 | ||||
-rw-r--r-- | fortran/testpar/CMakeLists.txt | 18 |
12 files changed, 74 insertions, 143 deletions
diff --git a/fortran/examples/CMakeLists.txt b/fortran/examples/CMakeLists.txt index 3a16c23..ff3f299 100644 --- a/fortran/examples/CMakeLists.txt +++ b/fortran/examples/CMakeLists.txt @@ -35,9 +35,12 @@ set (F2003_examples foreach (example ${examples}) add_executable (f90_ex_${example} ${HDF5_F90_EXAMPLES_SOURCE_DIR}/${example}.f90) - target_compile_options(f90_ex_${example} PRIVATE $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}>) -# set_property(TARGET f90_ex_${example} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -# set_property(TARGET f90_ex_${example} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) + target_compile_options(f90_ex_${example} + PRIVATE + "${HDF5_CMAKE_Fortran_FLAGS}" + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>") +# set_property(TARGET f90_ex_${example} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +# set_property(TARGET f90_ex_${example} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET f90_ex_${example} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -76,9 +79,12 @@ endforeach () foreach (example ${F2003_examples}) add_executable (f03_ex_${example} ${HDF5_F90_EXAMPLES_SOURCE_DIR}/${example}.f90) - target_compile_options(f03_ex_${example} PRIVATE $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}>) -# set_property(TARGET f03_ex_${example} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -# set_property(TARGET f03_ex_${example} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) + target_compile_options(f03_ex_${example} + PRIVATE + "${HDF5_CMAKE_Fortran_FLAGS}" + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>") +# set_property(TARGET f03_ex_${example} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +# set_property(TARGET f03_ex_${example} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET f03_ex_${example} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -117,9 +123,12 @@ endforeach () if (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND) add_executable (f90_ex_ph5example ${HDF5_F90_EXAMPLES_SOURCE_DIR}/ph5example.f90) - target_compile_options(f90_ex_ph5example PRIVATE $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}>) -# set_property(TARGET f90_ex_ph5example APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -# set_property(TARGET f90_ex_ph5example APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) + target_compile_options(f90_ex_ph5example + PRIVATE + "${HDF5_CMAKE_Fortran_FLAGS}" + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>") +# set_property(TARGET f90_ex_ph5example APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +# set_property(TARGET f90_ex_ph5example APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET f90_ex_ph5example PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() diff --git a/fortran/examples/ph5example.f90 b/fortran/examples/ph5example.f90 index 05fedbd..138969e 100644 --- a/fortran/examples/ph5example.f90 +++ b/fortran/examples/ph5example.f90 @@ -16,10 +16,10 @@ PROGRAM DATASET USE HDF5 ! This module contains all necessary modules + USE MPI IMPLICIT NONE - INCLUDE 'mpif.h' CHARACTER(LEN=10), PARAMETER :: default_fname = "sds.h5" ! Default name CHARACTER(LEN=8), PARAMETER :: dsetname = "IntArray" ! Dataset name @@ -72,10 +72,8 @@ CALL h5pset_fapl_mpio_f(plist_id, comm, info, error) ! - ! Figure out the filename to use. If your system does not support - ! getenv, comment that statement with this, - ! filename = "" - CALL getenv("HDF5_PARAPREFIX", filename) + ! Figure out the filename to use. + CALL get_environment_variable("HDF5_PARAPREFIX", filename) fnamelen = LEN_TRIM(filename) if ( fnamelen == 0 ) then filename = default_fname diff --git a/fortran/src/CMakeLists.txt b/fortran/src/CMakeLists.txt index 977d036..199a0c8 100644 --- a/fortran/src/CMakeLists.txt +++ b/fortran/src/CMakeLists.txt @@ -48,12 +48,12 @@ set (Fortran_COMPILER_ID CMAKE_Fortran_COMPILER_ID) add_executable (H5_buildiface ${HDF5_F90_SRC_SOURCE_DIR}/H5_buildiface.F90) target_include_directories (H5_buildiface PRIVATE "${HDF5_SRC_BINARY_DIR};${HDF5_F90_BINARY_DIR}") #if (BUILD_SHARED_LIBS) -# target_compile_definitions(H5_buildiface PRIVATE $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:/MT>) +# target_compile_definitions(H5_buildiface PRIVATE "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:/MT>") #endif () if(MSVC) set_property(TARGET H5_buildiface PROPERTY COMPILE_FLAGS "/MT") endif() -#set_property(TARGET H5_buildiface APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) +#set_property(TARGET H5_buildiface APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") if(MSVC) set_property(TARGET H5_buildiface PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE") endif() @@ -332,8 +332,8 @@ if (BUILD_STATIC_LIBS) target_compile_options(${HDF5_F90_LIB_TARGET} PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}") target_compile_definitions(${HDF5_F90_LIB_TARGET} PRIVATE - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:HDF5F90_WINDOWS> - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:HDF5F90_WINDOWS"> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) target_link_libraries (${HDF5_F90_LIB_TARGET} PUBLIC ${HDF5_F90_C_LIB_TARGET} @@ -341,8 +341,8 @@ if (BUILD_STATIC_LIBS) ${LINK_Fortran_LIBS} "$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_Fortran_LIBRARIES}>" ) -# set_property(TARGET ${HDF5_F90_LIB_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -# set_property(TARGET ${HDF5_F90_LIB_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) +# set_property(TARGET ${HDF5_F90_LIB_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +# set_property(TARGET ${HDF5_F90_LIB_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET ${HDF5_F90_LIB_TARGET} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -367,17 +367,17 @@ if (BUILD_SHARED_LIBS) target_compile_definitions(${HDF5_F90_LIBSH_TARGET} PUBLIC "H5_BUILT_AS_DYNAMIC_LIB" PRIVATE - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:BUILD_HDF5_DLL;HDF5F90_WINDOWS> - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:BUILD_HDF5_DLL;HDF5F90_WINDOWS>" + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) target_link_libraries (${HDF5_F90_LIBSH_TARGET} PUBLIC ${HDF5_F90_C_LIBSH_TARGET} PRIVATE ${LINK_Fortran_LIBS} "$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_Fortran_LIBRARIES}>" ) -# set_property(TARGET ${HDF5_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -# set_property(TARGET ${HDF5_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) -# set_property(TARGET ${HDF5_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-DLL">) -# set_property(TARGET ${HDF5_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-DEF:${HDF5_F90_SRC_BINARY_DIR}/hdf5_fortrandll.def">) +# set_property(TARGET ${HDF5_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +# set_property(TARGET ${HDF5_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") +# set_property(TARGET ${HDF5_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-DLL>") +# set_property(TARGET ${HDF5_F90_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-DEF:${HDF5_F90_SRC_BINARY_DIR}/hdf5_fortrandll.def>") if(MSVC) set_property(TARGET ${HDF5_F90_LIBSH_TARGET} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS} /DLL /DEF:${HDF5_F90_SRC_BINARY_DIR}/hdf5_fortrandll.def") endif() diff --git a/fortran/src/H5Dff.F90 b/fortran/src/H5Dff.F90 index f4fe4ac..5d6ff52 100644 --- a/fortran/src/H5Dff.F90 +++ b/fortran/src/H5Dff.F90 @@ -1816,7 +1816,6 @@ CONTAINS SUBROUTINE h5dwrite_reference_dsetreg(dset_id, mem_type_id, buf, dims, hdferr, & mem_space_id, file_space_id, xfer_prp) - USE, INTRINSIC :: ISO_C_BINDING, ONLY : C_PTR IMPLICIT NONE INTEGER(HID_T), INTENT(IN) :: dset_id INTEGER(HID_T), INTENT(IN) :: mem_type_id diff --git a/fortran/src/H5Pff.F90 b/fortran/src/H5Pff.F90 index c4da8f3..bbc7a9d 100644 --- a/fortran/src/H5Pff.F90 +++ b/fortran/src/H5Pff.F90 @@ -4680,7 +4680,7 @@ SUBROUTINE h5pset_attr_phase_change_f(ocpl_id, max_compact, min_dense, hdferr) IMPLICIT NONE INTEGER(HID_T), INTENT(IN) :: prp_id INTEGER(HID_T), INTENT(IN) :: type_id - TYPE(C_PTR) , INTENT(IN) :: fillvalue + TYPE(C_PTR) :: fillvalue INTEGER , INTENT(OUT) :: hdferr hdferr = INT(H5Pget_fill_value(prp_id, type_id, fillvalue)) diff --git a/fortran/src/H5Sff.F90 b/fortran/src/H5Sff.F90 index 5a1ca53..e734c03 100644 --- a/fortran/src/H5Sff.F90 +++ b/fortran/src/H5Sff.F90 @@ -71,7 +71,7 @@ CONTAINS IMPLICIT NONE INTEGER, INTENT(IN) :: rank INTEGER(HSIZE_T), INTENT(IN) :: dims(rank) - INTEGER(HSIZE_T), DIMENSION(:),INTENT(IN) :: maxdims(rank) + INTEGER(HSIZE_T), INTENT(IN) :: maxdims(rank) INTEGER(HID_T), INTENT(OUT) :: space_id END FUNCTION h5screate_simple_c END INTERFACE diff --git a/fortran/src/H5_buildiface.F90 b/fortran/src/H5_buildiface.F90 index cd4580b..62ced23 100644 --- a/fortran/src/H5_buildiface.F90 +++ b/fortran/src/H5_buildiface.F90 @@ -43,7 +43,6 @@ #include <H5config_f.inc> PROGRAM H5_buildiface - USE, INTRINSIC :: ISO_C_BINDING, ONLY : C_PTR, C_CHAR, C_LOC IMPLICIT NONE ! These values are valid REAL KINDs (with corresponding C float) found during configure diff --git a/fortran/test/CMakeLists.txt b/fortran/test/CMakeLists.txt index ff27943..c9dc48f 100644 --- a/fortran/test/CMakeLists.txt +++ b/fortran/test/CMakeLists.txt @@ -13,14 +13,14 @@ target_include_directories (H5_test_buildiface ) #if (BUILD_SHARED_LIBS) # target_compile_definitions(H5_test_buildiface -# PRIVATE $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:/MT> +# PRIVATE "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:/MT>" # ) #endif () if(MSVC) set_property(TARGET H5_test_buildiface PROPERTY COMPILE_FLAGS "/MT") endif() #set_property(TARGET H5_test_buildiface APPEND PROPERTY -# LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE"> +# LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>" #) if(MSVC) set_property(TARGET H5_test_buildiface PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE") @@ -145,12 +145,12 @@ if (NOT BUILD_SHARED_LIBS) target_compile_options(${HDF5_F90_TEST_LIB_TARGET} PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}") target_compile_definitions(${HDF5_F90_TEST_LIB_TARGET} PRIVATE - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:HDF5F90_WINDOWS> - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:HDF5F90_WINDOWS>" + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) target_link_libraries (${HDF5_F90_TEST_LIB_TARGET} PUBLIC ${HDF5_F90_C_TEST_LIB_TARGET} ${HDF5_F90_LIB_TARGET} ${HDF5_LIB_TARGET}) -# set_property(TARGET ${HDF5_F90_TEST_LIB_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -# set_property(TARGET ${HDF5_F90_TEST_LIB_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) +# set_property(TARGET ${HDF5_F90_TEST_LIB_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +# set_property(TARGET ${HDF5_F90_TEST_LIB_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET ${HDF5_F90_TEST_LIB_TARGET} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -171,13 +171,13 @@ else () target_compile_definitions(${HDF5_F90_TEST_LIBSH_TARGET} PUBLIC "H5_BUILT_AS_DYNAMIC_LIB" PRIVATE - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:BUILD_HDF5_TEST_DLL;HDF5F90_WINDOWS> - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:BUILD_HDF5_TEST_DLL;HDF5F90_WINDOWS>" + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) target_link_libraries (${HDF5_F90_TEST_LIBSH_TARGET} PUBLIC ${HDF5_F90_C_TEST_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} ${HDF5_LIBSH_TARGET}) -# set_property(TARGET ${HDF5_F90_TEST_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -# set_property(TARGET ${HDF5_F90_TEST_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) -# set_property(TARGET ${HDF5_F90_TEST_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-DLL">) +# set_property(TARGET ${HDF5_F90_TEST_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +# set_property(TARGET ${HDF5_F90_TEST_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") +# set_property(TARGET ${HDF5_F90_TEST_LIBSH_TARGET} APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-DLL>") if(MSVC) set_property(TARGET ${HDF5_F90_TEST_LIBSH_TARGET} PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS} -DLL") endif() @@ -215,10 +215,10 @@ add_executable (testhdf5_fortran target_compile_options(testhdf5_fortran PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) -#set_property(TARGET testhdf5_fortran APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -#set_property(TARGET testhdf5_fortran APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) +#set_property(TARGET testhdf5_fortran APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +#set_property(TARGET testhdf5_fortran APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET testhdf5_fortran PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -254,10 +254,10 @@ add_executable (testhdf5_fortran_1_8 target_compile_options(testhdf5_fortran_1_8 PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) -#set_property(TARGET testhdf5_fortran_1_8 APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -#set_property(TARGET testhdf5_fortran_1_8 APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) +#set_property(TARGET testhdf5_fortran_1_8 APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +#set_property(TARGET testhdf5_fortran_1_8 APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET testhdf5_fortran_1_8 PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -294,10 +294,10 @@ add_executable (fortranlib_test_F03 target_compile_options(fortranlib_test_F03 PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) -#set_property(TARGET fortranlib_test_F03 APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -#set_property(TARGET fortranlib_test_F03 APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) +#set_property(TARGET fortranlib_test_F03 APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +#set_property(TARGET fortranlib_test_F03 APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET fortranlib_test_F03 PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -326,10 +326,10 @@ add_executable (fflush1 fflush1.F90) target_compile_options(fflush1 PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) -#set_property(TARGET fflush1 APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -#set_property(TARGET fflush1 APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) +#set_property(TARGET fflush1 APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +#set_property(TARGET fflush1 APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET fflush1 PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -358,10 +358,10 @@ add_executable (fflush2 fflush2.F90) target_compile_options (fflush2 PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) -#set_property(TARGET fflush2 APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -#set_property(TARGET fflush2 APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) +#set_property(TARGET fflush2 APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +#set_property(TARGET fflush2 APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET fflush2 PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() @@ -390,10 +390,10 @@ add_executable (vol_connector vol_connector.F90) target_compile_options(vol_connector PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) -#set_property(TARGET vol_connector APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"-SUBSYSTEM:CONSOLE">) -#set_property(TARGET vol_connector APPEND PROPERTY LINK_FLAGS $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_LINK_FLAGS}>) +#set_property(TARGET vol_connector APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:-SUBSYSTEM:CONSOLE>") +#set_property(TARGET vol_connector APPEND PROPERTY LINK_FLAGS "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_LINK_FLAGS}>") if(MSVC) set_property(TARGET vol_connector PROPERTY LINK_FLAGS "/SUBSYSTEM:CONSOLE ${WIN_LINK_FLAGS}") endif() diff --git a/fortran/test/tH5D.F90 b/fortran/test/tH5D.F90 index 8c1484f..c381235 100644 --- a/fortran/test/tH5D.F90 +++ b/fortran/test/tH5D.F90 @@ -644,7 +644,6 @@ CONTAINS INTEGER, PARAMETER :: int_kind_16 = SELECTED_INT_KIND(18) !should map to INTEGER*8 on most modern processors INTEGER(KIND=int_kind_1) , DIMENSION(1:DIM0), TARGET :: data_i1 INTEGER(KIND=int_kind_4) , DIMENSION(1:DIM0), TARGET :: data_i4 - INTEGER(KIND=int_kind_8) , DIMENSION(1:DIM0), TARGET :: data_i8 INTEGER(KIND=int_kind_16), DIMENSION(1:DIM0), TARGET :: data_i16 INTEGER(KIND=int_kind_1) , TARGET :: data0_i1 = 4 INTEGER(KIND=int_kind_4) , TARGET :: data0_i4 = 4 @@ -683,7 +682,6 @@ CONTAINS ! Initialize memory buffer data_i1 = -2 data_i4 = -2 - data_i8 = -2 data_i16 = -2 data_int = -2 #if H5_HAVE_Fortran_INTEGER_SIZEOF_16!=0 @@ -798,7 +796,6 @@ CONTAINS ! Initialize memory buffer data_i1 = -2 data_i4 = -2 - data_i8 = -2 data_i16 = -2 #if H5_HAVE_Fortran_INTEGER_SIZEOF_16!=0 data_i32 = -2 diff --git a/fortran/test/tH5G_1_8.F90 b/fortran/test/tH5G_1_8.F90 index dca4cf2..cd354d8 100644 --- a/fortran/test/tH5G_1_8.F90 +++ b/fortran/test/tH5G_1_8.F90 @@ -192,48 +192,18 @@ SUBROUTINE group_info(cleanup, fapl, total_error) IF(idx_type == H5_INDEX_CRT_ORDER_F)THEN IF(iorder == H5_ITER_INC_F)THEN order = H5_ITER_INC_F -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in increasing order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in increasing order w/o creation order index" -!!$ ENDIF ELSE IF (iorder == H5_ITER_DEC_F) THEN order = H5_ITER_DEC_F -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in decreasing order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in decreasing order w/o creation order index" -!!$ ENDIF ELSE order = H5_ITER_NATIVE_F -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in native order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in native order w/o creation order index" -!!$ ENDIF ENDIF ELSE IF(iorder == H5_ITER_INC_F)THEN order = H5_ITER_INC_F -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in increasing order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in increasing order w/o creation order index" -!!$ ENDIF ELSE IF (iorder == H5_ITER_DEC_F) THEN order = H5_ITER_DEC_F -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in decreasing order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in decreasing order w/o creation order index" -!!$ ENDIF ELSE order = H5_ITER_NATIVE_F -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in native order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"query group info by creation order index in native order w/o creation order index" -!!$ ENDIF ENDIF END IF @@ -1263,56 +1233,16 @@ SUBROUTINE delete_by_idx(cleanup, fapl, total_error) CHARACTER(LEN=2) :: chr2 INTEGER :: error INTEGER :: id_type - ! - ! - ! - CHARACTER(LEN=80) :: fix_filename1 - CHARACTER(LEN=80) :: fix_filename2 INTEGER(HSIZE_T) :: htmp LOGICAL :: cleanup - DO i = 1, 80 - fix_filename1(i:i) = " " - fix_filename2(i:i) = " " - ENDDO - ! Loop over operating on different indices on link fields DO idx_type = H5_INDEX_NAME_F, H5_INDEX_CRT_ORDER_F ! Loop over operating in different orders DO iorder = H5_ITER_INC_F, H5_ITER_DEC_F ! Loop over using index for creation order value DO i = 1, 2 - ! Print appropriate test message -!!$ IF(idx_type == H5_INDEX_CRT_ORDER_F)THEN -!!$ IF(iorder == H5_ITER_INC_F)THEN -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"deleting links by creation order index in increasing order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"deleting links by creation order index in increasing order w/o creation order index" -!!$ ENDIF -!!$ ELSE -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"deleting links by creation order index in decreasing order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"deleting links by creation order index in decreasing order w/o creation order index" -!!$ ENDIF -!!$ ENDIF -!!$ ELSE -!!$ IF(iorder == H5_ITER_INC_F)THEN -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"deleting links by name index in increasing order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"deleting links by name index in increasing order w/o creation order index" -!!$ ENDIF -!!$ ELSE -!!$ IF(use_index(i))THEN -!!$ WRITE(*,'(5x,A)')"deleting links by name index in decreasing order w/creation order index" -!!$ ELSE -!!$ WRITE(*,'(5x,A)')"deleting links by name index in decreasing order w/o creation order index" -!!$ ENDIF -!!$ ENDIF -!!$ ENDIF ! Create file CALL H5Fcreate_f(filename, H5F_ACC_TRUNC_F, file_id, error, access_prp=fapl) diff --git a/fortran/test/tH5P_F03.F90 b/fortran/test/tH5P_F03.F90 index 4f390d5..24934eb 100644 --- a/fortran/test/tH5P_F03.F90 +++ b/fortran/test/tH5P_F03.F90 @@ -146,7 +146,6 @@ SUBROUTINE test_create(total_error) ! Compound datatype test f_ptr = C_LOC(fill_ctype) - CALL H5Pget_fill_value_f(dcpl, comp_type_id, f_ptr, error) CALL check("H5Pget_fill_value_f",error, total_error) @@ -184,6 +183,7 @@ SUBROUTINE test_create(total_error) CALL VERIFY("***ERROR: Returned wrong fill value (real)", rfill, 2.0, total_error) ! For the actual compound type + f_ptr = C_LOC(fill_ctype) CALL H5Pset_fill_value_f(dcpl, comp_type_id, f_ptr, error) CALL check("H5Pget_fill_value_f",error, total_error) @@ -254,7 +254,6 @@ SUBROUTINE test_create(total_error) CALL check("H5Dget_create_plist_f", error, total_error) f_ptr = C_LOC(rd_c) - CALL H5Pget_fill_value_f(dcpl, comp_type_id, f_ptr, error) CALL check("H5Pget_fill_value_f", error, total_error) CALL verify("***ERROR: Returned wrong fill value", rd_c%a, fill_ctype%a, total_error) diff --git a/fortran/testpar/CMakeLists.txt b/fortran/testpar/CMakeLists.txt index ca241f6..e8f0107 100644 --- a/fortran/testpar/CMakeLists.txt +++ b/fortran/testpar/CMakeLists.txt @@ -28,13 +28,13 @@ target_include_directories (parallel_test target_compile_options(parallel_test PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) if (NOT BUILD_SHARED_LIBS) target_link_libraries (parallel_test PRIVATE ${HDF5_F90_TEST_LIB_TARGET} ${HDF5_F90_LIB_TARGET} ${HDF5_LIB_TARGET} ${LINK_Fortran_LIBS} - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"ws2_32.lib"> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:ws2_32.lib>" ) set_target_properties (parallel_test PROPERTIES FOLDER test/fortran @@ -45,7 +45,7 @@ else () target_link_libraries (parallel_test PRIVATE ${HDF5_F90_TEST_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} ${LINK_Fortran_LIBS} - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"ws2_32.lib"> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:ws2_32.lib>" ) set_target_properties (parallel_test PROPERTIES FOLDER test/fortran @@ -68,13 +68,13 @@ target_include_directories (subfiling_test target_compile_options(subfiling_test PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) if (NOT BUILD_SHARED_LIBS) target_link_libraries (subfiling_test PRIVATE ${HDF5_F90_TEST_LIB_TARGET} ${HDF5_F90_LIB_TARGET} ${HDF5_LIB_TARGET} ${LINK_Fortran_LIBS} - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"ws2_32.lib"> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:ws2_32.lib>" ) set_target_properties (subfiling_test PROPERTIES FOLDER test/fortran @@ -85,7 +85,7 @@ else () target_link_libraries (subfiling_test PRIVATE ${HDF5_F90_TEST_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} ${LINK_Fortran_LIBS} - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"ws2_32.lib"> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:ws2_32.lib>" ) set_target_properties (subfiling_test PROPERTIES FOLDER test/fortran @@ -108,13 +108,13 @@ target_include_directories (async_test target_compile_options(async_test PRIVATE "${HDF5_CMAKE_Fortran_FLAGS}" - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:${WIN_COMPILE_FLAGS}> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:${WIN_COMPILE_FLAGS}>" ) if (NOT BUILD_SHARED_LIBS) target_link_libraries (async_test PRIVATE ${HDF5_F90_TEST_LIB_TARGET} ${HDF5_F90_LIB_TARGET} ${HDF5_LIB_TARGET} ${LINK_Fortran_LIBS} - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"ws2_32.lib"> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:ws2_32.lib>" ) set_target_properties (async_test PROPERTIES FOLDER test/fortran @@ -125,7 +125,7 @@ else () target_link_libraries (async_test PRIVATE ${HDF5_F90_TEST_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} ${LINK_Fortran_LIBS} - $<$<STREQUAL:"x${CMAKE_Fortran_SIMULATE_ID}","xMSVC">:"ws2_32.lib"> + "$<$<STREQUAL:x${CMAKE_Fortran_SIMULATE_ID},xMSVC>:ws2_32.lib>" ) set_target_properties (async_test PROPERTIES FOLDER test/fortran |