2020endif ()
2121
2222set (Boost_USE_MULTI_THREADEDON )
23- find_package ( Boost 1.45 .0 REQUIRED unit_test_frameworksystem regex date_time thread filesystem program_options chrono )
23+ find_package ( Boost 1.54 .0 REQUIRED unit_test_frameworksystem regex date_time thread filesystem program_options chrono )
2424find_package ( OpenSSL )
2525find_package ( Threads )
2626set (CMAKE_VERBOSE_MAKEFILE true )
@@ -37,9 +37,17 @@ endif()
3737if (${CMAKE_CXX_COMPILER_ID} MATCHES GNU)
3838 set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall" )
3939elseif (${CMAKE_CXX_COMPILER_ID} MATCHES Clang)
40- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -ftemplate-depth=256" )
40+ if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin" )
41+ # We want to link in C++11 mode if we're using Clang and on OS X.
42+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -ftemplate-depth=256 -std=c++11 -stdlib=libc++" )
43+ else ()
44+ # We just add the -Wall and a high enough template depth
45+ # flag for Clang in other systems.
46+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -ftemplate-dempth=256" )
47+ endif ()
4148endif ()
4249
50+
4351if (Boost_FOUND)
4452 if (MSVC )
4553 add_definitions (-D_SCL_SECURE_NO_WARNINGS)