Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Include Boost directories once they're found.
[simgrid.git] / buildtools / Cmake / CompleteInFiles.cmake
index 21f068f..37e6ef4 100644 (file)
@@ -9,7 +9,7 @@ set(CMAKE_MODULE_PATH
 
 ### Determine the assembly flavor that we need today
 include(CMakeDetermineSystem)
-IF(CMAKE_SYSTEM_PROCESSOR MATCHES ".86|AMD64")
+IF(CMAKE_SYSTEM_PROCESSOR MATCHES ".86|AMD64|amd64")
   IF(${ARCH_32_BITS})
     message(STATUS "System processor: i686 (${CMAKE_SYSTEM_PROCESSOR}, 32 bits)")
     set(PROCESSOR_i686 1)
@@ -98,6 +98,9 @@ if(enable_ns3)
   include(FindNS3)
 endif()
 
+find_package(Boost REQUIRED)
+include_directories(${Boost_INCLUDE_DIRS})
+
 # Checks for header libraries functions.
 CHECK_LIBRARY_EXISTS(pthread pthread_create          "" pthread)
 CHECK_LIBRARY_EXISTS(pthread sem_init                "" HAVE_SEM_INIT_LIB)
@@ -148,7 +151,6 @@ CHECK_FUNCTION_EXISTS(asprintf HAVE_ASPRINTF)
 CHECK_FUNCTION_EXISTS(vasprintf HAVE_VASPRINTF)
 CHECK_FUNCTION_EXISTS(makecontext HAVE_MAKECONTEXT)
 CHECK_FUNCTION_EXISTS(mmap HAVE_MMAP)
-CHECK_FUNCTION_EXISTS(mergesort HAVE_MERGESORT)
 
 #Check if __thread is defined
 execute_process(
@@ -217,9 +219,9 @@ else()
   SET(MMALLOC_WANT_OVERRIDE_LEGACY 0)
 endif()
 
-# must come after having set HAVE_MC (FindGFortran uses it)
 if(enable_smpi)
   include(FindF2c)
+  # FindGFortran must come after FindF2C, and after having set HAVE_MC
   include(FindGFortran)
   SET(HAVE_SMPI 1)
 endif()
@@ -809,6 +811,7 @@ if(HAVE_NS3_LIB)
 endif()
 set(CMAKE_SMPI_COMMAND "${CMAKE_SMPI_COMMAND}:\${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}\"")
 
+file(READ ${CMAKE_HOME_DIRECTORY}/src/smpi/smpitools.sh SMPITOOLS_SH)
 configure_file(${CMAKE_HOME_DIRECTORY}/include/smpi/mpif.h.in ${CMAKE_BINARY_DIR}/include/smpi/mpif.h @ONLY)
 configure_file(${CMAKE_HOME_DIRECTORY}/include/smpi/smpif.h.in ${CMAKE_BINARY_DIR}/include/smpi/smpif.h @ONLY)
 configure_file(${CMAKE_HOME_DIRECTORY}/src/smpi/smpicc.in ${CMAKE_BINARY_DIR}/bin/smpicc @ONLY)