File tree Expand file tree Collapse file tree 3 files changed +15
-8
lines changed Expand file tree Collapse file tree 3 files changed +15
-8
lines changed Original file line number Diff line number Diff line change @@ -21,13 +21,13 @@ include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/hdf5.cmake)
2121
2222if (NOT HDF5OK)
2323 message (STATUS "h5fortran: HDF5 not working" )
24- if (NOT PROJECT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR )
24+ if (PROJECT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR )
25+ message (FATAL_ERROR)
26+ else ()
2527 return ()
2628 endif ()
2729endif ()
2830
29- set (CTEST_TEST_TIMEOUT 15)
30-
3131# --- build
3232
3333add_library (h5fortran)
Original file line number Diff line number Diff line change @@ -54,6 +54,17 @@ if(UNIX)
5454 list (APPEND HDF5_LIBRARIES m)
5555endif ()
5656
57+ if (WIN32 AND MSVC )
58+ # this stanza must be BEFORE if(DEFINED HDF5OK)
59+ if (NOT DEFINED HDF5_ROOT AND DEFINED ENV{HDF5_ROOT})
60+ file (TO_CMAKE_PATH "$ENV{HDF5_ROOT} " HDF5_ROOT)
61+ endif ()
62+
63+ if (DEFINED HDF5_ROOT)
64+ set (ENV{PATH } "${HDF5_ROOT} /bin;$ENV{PATH} " )
65+ endif ()
66+ endif ()
67+
5768if (DEFINED HDF5OK)
5869 return ()
5970endif ()
Original file line number Diff line number Diff line change @@ -50,16 +50,12 @@ set_tests_properties(h5fortran:ShapeCheck PROPERTIES
5050 SKIP_RETURN_CODE 77)
5151
5252if (WIN32 AND MSVC )
53- if (NOT DEFINED HDF5_ROOT AND DEFINED ENV{HDF5_ROOT})
54- file (TO_CMAKE_PATH "$ENV{HDF5_ROOT} " HDF5_ROOT)
55- endif ()
56-
5753 foreach (t h5fortran:minimal h5fortran:ErrorCheck h5fortran:test_exist h5fortran:module h5fortran:deflate h5fortran:ShapeCheck)
5854 set_tests_properties (${t} PROPERTIES ENVIRONMENT "PATH=${HDF5_ROOT} /bin;$ENV{PATH} " )
5955 endforeach ()
6056endif ()
6157
62- # ---
58+ # --- shaky tests
6359if (NOT test_shaky)
6460 return ()
6561endif ()
You can’t perform that action at this time.
0 commit comments