cmake: librt is found only on Linux

This commit is contained in:
Florent Castelli 2017-01-20 22:55:20 +01:00
parent 83dc03416e
commit 56559c51cf

View File

@ -450,7 +450,7 @@ if(ANDROID)
SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
SET(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY) SET(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
elseif(NOT APPLE AND NOT CMAKE_SYSTEM_NAME MATCHES OpenBSD) elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
list(APPEND LIBS rt) list(APPEND LIBS rt)
endif() endif()