diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2011-09-27 14:18:46 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2011-09-27 14:18:46 (GMT) |
commit | c6af94c8edb8bff9f431ec84b1c0de729b6fca48 (patch) | |
tree | 8dc473a4dcd6ac1b2873160e720016467b5f9c1d /fortran | |
parent | 4af3cd2b7a89b2eeed05d5ec0b0641ca7c2545bc (diff) | |
download | hdf5-c6af94c8edb8bff9f431ec84b1c0de729b6fca48.zip hdf5-c6af94c8edb8bff9f431ec84b1c0de729b6fca48.tar.gz hdf5-c6af94c8edb8bff9f431ec84b1c0de729b6fca48.tar.bz2 |
[svn-r21423] Add 2003 fortran to cmake build/configure
Tested: local linux
Diffstat (limited to 'fortran')
-rw-r--r-- | fortran/examples/CMakeLists.txt | 40 |
1 files changed, 39 insertions, 1 deletions
diff --git a/fortran/examples/CMakeLists.txt b/fortran/examples/CMakeLists.txt index ee459e1..6ecfd37 100644 --- a/fortran/examples/CMakeLists.txt +++ b/fortran/examples/CMakeLists.txt @@ -30,6 +30,13 @@ SET (examples compound ) +SET (F2003_examples + rwdset_fortran2003 + nested_derived_type + compound_fortran2003 + compound_complex_fortran2003 +) + FOREACH (example ${examples}) ADD_EXECUTABLE (f90_ex_${example} ${HDF5_F90_EXAMPLES_SOURCE_DIR}/${example}.f90) TARGET_NAMING (f90_ex_${example} ${LIB_TYPE}) @@ -37,7 +44,7 @@ FOREACH (example ${examples}) IF (WIN32 AND NOT CYGWIN) SET_PROPERTY (TARGET f90_ex_${example} APPEND PROPERTY COMPILE_DEFINITIONS - HDF5F90_WINDOWS + HDF5F90_WINDOWS ) ENDIF (WIN32 AND NOT CYGWIN) TARGET_LINK_LIBRARIES (f90_ex_${example} @@ -48,10 +55,41 @@ FOREACH (example ${examples}) IF (BUILD_TESTING) ADD_TEST (NAME f90_ex_${example} COMMAND $<TARGET_FILE:f90_ex_${example}>) + IF (NOT "${last_test}" STREQUAL "") + SET_TESTS_PROPERTIES (f90_ex_${example} PROPERTIES DEPENDS ${last_test}) + ENDIF (NOT "${last_test}" STREQUAL "") + SET (last_test "f90_ex_${example}") ENDIF (BUILD_TESTING) ENDFOREACH (example ${examples}) +FOREACH (example ${F2003_examples}) + ADD_EXECUTABLE (f03_ex_${example} ${HDF5_F90_EXAMPLES_SOURCE_DIR}/${example}.f90) + TARGET_NAMING (f03_ex_${example} ${LIB_TYPE}) + TARGET_FORTRAN_WIN_PROPERTIES (f03_ex_${example} "") + IF (WIN32 AND NOT CYGWIN) + SET_PROPERTY (TARGET f03_ex_${example} + APPEND PROPERTY COMPILE_DEFINITIONS + HDF5F90_WINDOWS + ) + ENDIF (WIN32 AND NOT CYGWIN) + TARGET_LINK_LIBRARIES (f03_ex_${example} + ${HDF5_F90_LIB_TARGET} + ${HDF5_LIB_TARGET} + ) + SET_TARGET_PROPERTIES (f03_ex_${example} PROPERTIES LINKER_LANGUAGE Fortran) + + IF (BUILD_TESTING) + ADD_TEST (NAME f03_ex_${example} COMMAND $<TARGET_FILE:f03_ex_${example}>) + IF (NOT "${last_test}" STREQUAL "") + SET_TESTS_PROPERTIES (f03_ex_${example} PROPERTIES DEPENDS ${last_test}) + ENDIF (NOT "${last_test}" STREQUAL "") + SET (last_test "f03_ex_${example}") + ENDIF (BUILD_TESTING) + +ENDFOREACH (example ${F2003_examples}) + + IF (H5_HAVE_PARALLEL) ADD_EXECUTABLE (f90_ex_ph5example ${HDF5_F90_EXAMPLES_SOURCE_DIR}/ph5example.f90) TARGET_NAMING (f90_ex_ph5example ${LIB_TYPE}) |