From: quassel Date: Fri, 13 Mar 2009 15:44:07 +0000 (+0000) Subject: Handle empty LINK_EXTRA X-Git-Tag: 0.5-rc1~303 X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=commitdiff_plain;h=a097148feeb46a612c594e77a7a1b620aae2f851 Handle empty LINK_EXTRA --- diff --git a/CMakeLists.txt b/CMakeLists.txt index dbafc334..6a2cf835 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -79,8 +79,10 @@ endif(WIN32) # Define a comma-separated list here # e.g. for pgsql, we need -DLINK_EXTRA=pq;crypt set(LINK_EXTRA "" CACHE STRING "Semicolon-separated list of libraries to be linked") -string(REPLACE "," ";" LINK_EXTRA ${LINK_EXTRA}) -link_libraries(${LINK_EXTRA}) +if(LINK_EXTRA) + string(REPLACE "," ";" LINK_EXTRA ${LINK_EXTRA}) + link_libraries(${LINK_EXTRA}) +endif(LINK_EXTRA) # Build Type # We need to make sure it's not empty