2017-01-11 07:09:53 +08:00
|
|
|
cmake_minimum_required (VERSION 3.2.2)
|
2010-09-01 04:15:13 +08:00
|
|
|
PROJECT (HDF5_FORTRAN_TESTPAR C CXX Fortran)
|
|
|
|
|
|
|
|
#-----------------------------------------------------------------------------
|
|
|
|
# Setup include Directories
|
|
|
|
#-----------------------------------------------------------------------------
|
2015-03-26 06:08:46 +08:00
|
|
|
INCLUDE_DIRECTORIES (${HDF5_F90_BINARY_DIR} ${HDF5_F90_SRC_DIR}/src)
|
2010-09-01 04:15:13 +08:00
|
|
|
|
|
|
|
#-----------------------------------------------------------------------------
|
|
|
|
# Add Tests
|
|
|
|
#-----------------------------------------------------------------------------
|
|
|
|
|
|
|
|
#-- Adding test for parallel_test
|
2014-03-12 05:14:57 +08:00
|
|
|
add_executable (parallel_test
|
2010-09-01 04:15:13 +08:00
|
|
|
ptest.f90
|
|
|
|
hyper.f90
|
|
|
|
mdset.f90
|
|
|
|
)
|
2015-08-05 23:56:58 +08:00
|
|
|
TARGET_NAMING (parallel_test STATIC)
|
|
|
|
TARGET_FORTRAN_PROPERTIES (parallel_test STATIC " " " ")
|
2017-01-11 07:09:53 +08:00
|
|
|
target_link_libraries (parallel_test
|
2010-09-01 04:15:13 +08:00
|
|
|
${HDF5_F90_TEST_LIB_TARGET}
|
|
|
|
${HDF5_F90_LIB_TARGET}
|
|
|
|
${HDF5_LIB_TARGET}
|
2011-11-04 05:06:37 +08:00
|
|
|
${MPI_Fortran_LIBRARIES}
|
2010-09-01 04:15:13 +08:00
|
|
|
)
|
2014-03-12 05:14:57 +08:00
|
|
|
if (WIN32 AND MSVC)
|
|
|
|
target_link_libraries (parallel_test "ws2_32.lib")
|
2017-01-11 07:09:53 +08:00
|
|
|
endif ()
|
2015-08-05 23:56:58 +08:00
|
|
|
target_include_directories (parallel_test PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static)
|
2014-03-12 05:14:57 +08:00
|
|
|
set_target_properties (parallel_test PROPERTIES LINKER_LANGUAGE Fortran)
|
|
|
|
set_target_properties (parallel_test PROPERTIES FOLDER test/fortran)
|
2010-09-01 04:15:13 +08:00
|
|
|
|
2014-03-12 05:14:57 +08:00
|
|
|
include (CMakeTests.cmake)
|