Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of https://github.com/mpoquet/simgrid
[simgrid.git] / teshsuite / smpi / mpich3-test / pt2pt / CMakeLists.txt
1 if(enable_smpi AND enable_smpi_MPICH3_testsuite)
2   if(WIN32)
3     set(CMAKE_C_FLAGS "-include ${CMAKE_HOME_DIRECTORY}/include/smpi/smpi_main.h")
4   else()
5     set(CMAKE_C_COMPILER "${CMAKE_BINARY_DIR}/smpi_script/bin/smpicc")
6     set(CMAKE_Fortran_COMPILER "${CMAKE_BINARY_DIR}/smpi_script/bin/smpiff")
7   endif()
8
9   include_directories(BEFORE "${CMAKE_HOME_DIRECTORY}/include/smpi")
10   include_directories("${CMAKE_CURRENT_SOURCE_DIR}/../include/")
11
12   foreach(file anyall bottom eagerdt inactivereq isendself isendselfprobe issendselfcancel mprobe pingping probenull
13           probe-unexp sendall sendflood sendrecv1 sendrecv2 sendrecv3 waitany-null waittestnull)
14     # not compiled files: big_count_status bsend1 bsend2 bsend3 bsend4 bsend5 bsendalign bsendfrag bsendpending
15     # cancelrecv greq1 icsend large_message pscancel rcancel rqfreeb rqstatus scancel2 scancel sendself
16     add_executable(${file} ${file}.c)
17     target_link_libraries(${file} simgrid mtest_c)
18   endforeach()
19 endif()
20
21 if (enable_smpi_MPICH3_testsuite AND HAVE_RAW_CONTEXTS)
22   ADD_TEST(test-smpi-mpich3-pt2pt-raw      ${CMAKE_COMMAND} -E chdir ${CMAKE_BINARY_DIR}/teshsuite/smpi/mpich3-test/pt2pt ${PERL_EXECUTABLE} ${CMAKE_HOME_DIRECTORY}/teshsuite/smpi/mpich3-test/runtests ${TESH_OPTION} -mpiexec=${CMAKE_BINARY_DIR}/smpi_script/bin/smpirun -srcdir=${CMAKE_HOME_DIRECTORY}/teshsuite/smpi/mpich3-test/pt2pt -tests=testlist -execarg=--cfg=contexts/factory:raw -execarg=--cfg=smpi/privatize-global-variables:${HAVE_PRIVATIZATION})
23   SET_TESTS_PROPERTIES(test-smpi-mpich3-pt2pt-raw PROPERTIES PASS_REGULAR_EXPRESSION "tests passed!")
24 endif()
25
26 foreach(file anyall bottom eagerdt inactivereq isendself isendselfprobe issendselfcancel mprobe pingping probenull
27           probe-unexp sendall sendflood sendrecv1 sendrecv2 sendrecv3 waitany-null waittestnull
28           big_count_status bsend1 bsend2 bsend3 bsend4 bsend5 bsendalign bsendfrag bsendpending
29           cancelrecv greq1 icsend large_message pscancel rcancel rqfreeb rqstatus scancel2 scancel sendself)
30   set(examples_src  ${examples_src} ${CMAKE_CURRENT_SOURCE_DIR}/${file}.c)
31 endforeach()
32
33 set(examples_src  ${examples_src}                                        PARENT_SCOPE)
34 set(txt_files     ${txt_files}     ${CMAKE_CURRENT_SOURCE_DIR}/testlist  PARENT_SCOPE)