From 5175b88392d39d93f772e280afed5979695afd3d Mon Sep 17 00:00:00 2001 From: Rafal Jeczalik Date: Sun, 17 Feb 2013 18:14:43 +0100 Subject: [PATCH] ycm_core needs to be linked with librt under Linux --- cpp/ycm/CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cpp/ycm/CMakeLists.txt b/cpp/ycm/CMakeLists.txt index 92b7bf47..8be08c76 100644 --- a/cpp/ycm/CMakeLists.txt +++ b/cpp/ycm/CMakeLists.txt @@ -207,6 +207,10 @@ if ( EXTRA_RPATH ) set( CMAKE_INSTALL_RPATH "${EXTRA_RPATH}:${CMAKE_INSTALL_RPATH}" ) endif() +if ( UNIX ) + set( EXTRA_LIBS rt ) +endif() + ############################################################################# # Due to a bug/misconfiguration/stupidity, boost 1.52 and libc++ don't like each @@ -228,6 +232,7 @@ target_link_libraries( ${PROJECT_NAME} BoostParts ${PYTHON_LIBRARIES} ${LIBCLANG_TARGET} + ${EXTRA_LIBS} ) if ( LIBCLANG_TARGET )