From 6bcc2c187aff025bb8ab35e8454c0a3e1c62e97e Mon Sep 17 00:00:00 2001 From: archshift Date: Thu, 23 Oct 2014 14:58:42 -0700 Subject: Fix linking on OS X, which does not have librt. --- src/OSSupport/CMakeLists.txt | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/OSSupport') diff --git a/src/OSSupport/CMakeLists.txt b/src/OSSupport/CMakeLists.txt index 429949c59..a2f46d656 100644 --- a/src/OSSupport/CMakeLists.txt +++ b/src/OSSupport/CMakeLists.txt @@ -38,7 +38,11 @@ SET (HDRS if(NOT MSVC) add_library(OSSupport ${SRCS} ${HDRS}) - if(UNIX) - target_link_libraries(OSSupport pthread rt) + if(NOT APPLE) + target_link_libraries(OSSupport rt) endif() + + if(UNIX) + target_link_libraries(OSSupport pthread) + endif() endif() -- cgit v1.2.3 From 8ccb729504a866b50907993a71d3e35ad19e96a4 Mon Sep 17 00:00:00 2001 From: archshift Date: Thu, 23 Oct 2014 15:03:54 -0700 Subject: Fixed potential linker errors with mingw, as it isn't MSVC and it isn't APPLE. --- src/OSSupport/CMakeLists.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/OSSupport') diff --git a/src/OSSupport/CMakeLists.txt b/src/OSSupport/CMakeLists.txt index a2f46d656..3c0a3f1a0 100644 --- a/src/OSSupport/CMakeLists.txt +++ b/src/OSSupport/CMakeLists.txt @@ -38,11 +38,11 @@ SET (HDRS if(NOT MSVC) add_library(OSSupport ${SRCS} ${HDRS}) - if(NOT APPLE) - target_link_libraries(OSSupport rt) - endif() - if(UNIX) + if(NOT APPLE) + target_link_libraries(OSSupport rt) + endif() + target_link_libraries(OSSupport pthread) endif() endif() -- cgit v1.2.3 From dd86c1f4a33cc89cf4316105690f4d8d1cb24c4a Mon Sep 17 00:00:00 2001 From: archshift Date: Thu, 23 Oct 2014 23:49:20 -0700 Subject: OSSupport/CMakeLists.txt: fixed indentation --- src/OSSupport/CMakeLists.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/OSSupport') diff --git a/src/OSSupport/CMakeLists.txt b/src/OSSupport/CMakeLists.txt index 3c0a3f1a0..c3eabeef6 100644 --- a/src/OSSupport/CMakeLists.txt +++ b/src/OSSupport/CMakeLists.txt @@ -38,11 +38,11 @@ SET (HDRS if(NOT MSVC) add_library(OSSupport ${SRCS} ${HDRS}) - if(UNIX) + if(UNIX) if(NOT APPLE) target_link_libraries(OSSupport rt) endif() - target_link_libraries(OSSupport pthread) - endif() + target_link_libraries(OSSupport pthread) + endif() endif() -- cgit v1.2.3