From 2855a9ff7b423140237c9e988252fde0cbacd0a1 Mon Sep 17 00:00:00 2001 From: Stefan Radomski Date: Wed, 21 Nov 2012 01:36:13 +0100 Subject: Order of libraries matters with some gcc versions --- CMakeLists.txt | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index b2ba238..a7f5b6b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -281,7 +281,7 @@ foreach( OUTPUT_CONFIG ${CMAKE_CONFIGURATION_TYPES} ) endforeach() ############################################################ -# Dependandent libraries +# Dependent libraries ############################################################ set(USCXML_LIBS) @@ -292,10 +292,6 @@ if (NOT WIN32) find_package(LibXml2 REQUIRED) include_directories(${LIBXML2_INCLUDE_DIR}) list (APPEND USCXML_LIBS ${LIBXML2_LIBRARIES}) - if (UNIX AND NOT APPLE) - list (APPEND USCXML_LIBS "pthread") - list (APPEND USCXML_LIBS "rt") - endif() elseif(WIN32) list (APPEND USCXML_LIBS "Ws2_32") list (APPEND USCXML_LIBS "Winmm") @@ -416,6 +412,12 @@ list (APPEND USCXML_FILES ${USCXML_INTERPRETER}) include_directories(src) +# order of libraries matters with some gcc versions?! +if (UNIX AND NOT APPLE) + list (APPEND USCXML_LIBS "pthread") + list (APPEND USCXML_LIBS "rt") +endif() + ############################################################ # Binaries and tests ############################################################ -- cgit v0.12