X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/40334ce6fe520b2fa7d1e240716e4f34a5fdc74e..9dbeb2372ad9a123d0558132ebb6e003e10aa641:/buildtools/Cmake/MakeLib.cmake diff --git a/buildtools/Cmake/MakeLib.cmake b/buildtools/Cmake/MakeLib.cmake index 3e3e53816b..838739c03f 100644 --- a/buildtools/Cmake/MakeLib.cmake +++ b/buildtools/Cmake/MakeLib.cmake @@ -33,6 +33,9 @@ endif() # Compute the dependencies of SimGrid ##################################### set(SIMGRID_DEP "-lm") +if (HAVE_BOOST_CONTEXT) + set(SIMGRID_DEP "${SIMGRID_DEP} ${Boost_CONTEXT_LIBRARY}") +endif() if(${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD" AND NOT ${CMAKE_SYSTEM_VERSION} VERSION_LESS 10.0 @@ -55,10 +58,9 @@ else() set(SIMGRID_DEP "${SIMGRID_DEP} -lstdc++") endif() -if(pthread) - if(${CONTEXT_THREADS}) - SET(SIMGRID_DEP "${SIMGRID_DEP} -pthread") - endif() +if(pthread AND ${CONTEXT_THREADS} AND NOT APPLE) + # Clang on recent Mac OS X is not happy about -pthread. + SET(SIMGRID_DEP "${SIMGRID_DEP} -pthread") endif() if(HAVE_LUA)