Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
add fortran tests from mpich-tests, enforce completion of mpich-tests suite with...
[simgrid.git] / teshsuite / smpi / mpich-test / coll / CMakeLists.txt
index f01537e..357fc78 100644 (file)
@@ -2,7 +2,8 @@ cmake_minimum_required(VERSION 2.6)
 
 if(enable_smpi)
   set(CMAKE_C_COMPILER "${CMAKE_BINARY_DIR}/bin/smpicc")
-
+  set(CMAKE_Fortran_COMPILER "${CMAKE_BINARY_DIR}/bin/smpiff")
+  set(CMAKE_Fortran_LINKER "${CMAKE_BINARY_DIR}/bin/smpicc")
   set(EXECUTABLE_OUTPUT_PATH "${CMAKE_CURRENT_BINARY_DIR}")
   set(MPICH_FLAGS "-DHAVE_STDLIB_H=1 -DHAVE_UNISTD_H=1 -DHAVE_STRING_H=1 -DUSE_STDARG=1 -DHAVE_LONG_DOUBLE=1 -DHAVE_PROTOTYPES=1 -DHAVE_SIGNAL_H=1 -DHAVE_SIGACTION=1 -DHAVE_SLEEP=1 -DHAVE_SYSCONF=1")
 
@@ -38,6 +39,12 @@ if(enable_smpi)
   add_executable(scantst scantst.c test.c)
   add_executable(longuser longuser.c test.c)
 
+  if(SMPI_F2C)
+  add_executable(allredf allredf.f)
+  add_executable(assocf assocf.f)
+  add_executable(allgatherf allgatherf.f)
+  add_executable(bcastlog bcastlog.f)
+  endif(SMPI_F2C)
 
   target_link_libraries(coll1  m simgrid smpi )
   target_link_libraries(coll2 m simgrid smpi )
@@ -68,7 +75,12 @@ if(enable_smpi)
   target_link_libraries(longuser m simgrid smpi )
   target_link_libraries(alltoallv_mpich m simgrid smpi )
   target_link_libraries(scantst m simgrid smpi )
-
+  if(SMPI_F2C)
+  target_link_libraries(allredf m simgrid smpi )
+  target_link_libraries(assocf m simgrid smpi )
+  target_link_libraries(allgatherf m simgrid smpi )
+  target_link_libraries(bcastlog m simgrid smpi )
+  endif(SMPI_F2C)
 
   set_target_properties(coll1 PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
   set_target_properties(coll2 PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
@@ -99,6 +111,13 @@ if(enable_smpi)
   set_target_properties(longuser PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
   set_target_properties(alltoallv_mpich PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
   set_target_properties(scantst PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
+  if(SMPI_F2C)
+  set_target_properties(allredf PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
+  set_target_properties(assocf PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
+  set_target_properties(allgatherf PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
+  set_target_properties(bcastlog PROPERTIES COMPILE_FLAGS "${MPICH_FLAGS}")
+  endif(SMPI_F2C)
+
 endif(enable_smpi)
 
 set(tesh_files
@@ -143,6 +162,12 @@ set(examples_src
   ${CMAKE_CURRENT_SOURCE_DIR}/scantst.c
   ${CMAKE_CURRENT_SOURCE_DIR}/test.c
   ${CMAKE_CURRENT_SOURCE_DIR}/test.h
+  ${CMAKE_CURRENT_SOURCE_DIR}/allgatherf.f
+  ${CMAKE_CURRENT_SOURCE_DIR}/allredf.f
+  ${CMAKE_CURRENT_SOURCE_DIR}/allredf.std
+  ${CMAKE_CURRENT_SOURCE_DIR}/assocf.f
+  ${CMAKE_CURRENT_SOURCE_DIR}/bcastlog.f
+
   PARENT_SCOPE
   )
 set(bin_files