Skip to content

Commit

Permalink
[build] Fixed ENABLE_MONOTONIC_CLOCK=ON when target is Android
Browse files Browse the repository at this point in the history
  • Loading branch information
ThibaultBee authored and maxsharabayko committed Aug 23, 2021
1 parent 74aff82 commit 8b1be61
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ set_if(LINUX ${CMAKE_SYSTEM_NAME} MATCHES "Linux")
set_if(BSD ${SYSNAME_LC} MATCHES "bsd$")
set_if(MICROSOFT WIN32 AND (NOT MINGW AND NOT CYGWIN))
set_if(GNU ${CMAKE_SYSTEM_NAME} MATCHES "GNU")
set_if(POSIX LINUX OR DARWIN OR BSD OR (CYGWIN AND CYGWIN_USE_POSIX))
set_if(ANDROID ${CMAKE_SYSTEM_NAME} MATCHES "ANDROID")
set_if(POSIX LINUX OR DARWIN OR BSD OR ANDROID OR (CYGWIN AND CYGWIN_USE_POSIX))
set_if(SYMLINKABLE LINUX OR DARWIN OR BSD OR CYGWIN OR GNU)

# Not sure what to do in case of compiling by MSVC.
Expand Down Expand Up @@ -114,7 +115,7 @@ set(ENABLE_MONOTONIC_CLOCK_DEFAULT OFF)
set(MONOTONIC_CLOCK_LINKLIB "")
if (MICROSOFT)
set(ENABLE_STDCXX_SYNC_DEFAULT ON)
elseif (LINUX)
elseif (POSIX)
test_requires_clock_gettime(ENABLE_MONOTONIC_CLOCK_DEFAULT MONOTONIC_CLOCK_LINKLIB)
endif()

Expand Down

0 comments on commit 8b1be61

Please sign in to comment.