diff options
| author | Brent Cook <busterb@gmail.com> | 2018-03-22 21:43:06 -0500 |
|---|---|---|
| committer | Brent Cook <busterb@gmail.com> | 2018-03-22 21:43:06 -0500 |
| commit | 70e6be3d6e82cbdc7a8ca5e9f2a1e0d95ece17c2 (patch) | |
| tree | 7e9d553e849a000aa728fddd80907da94bdf100a | |
| parent | 158281bdfe1664174ea22d7f900a72d8c18887cb (diff) | |
| download | portable-70e6be3d6e82cbdc7a8ca5e9f2a1e0d95ece17c2.tar.gz portable-70e6be3d6e82cbdc7a8ca5e9f2a1e0d95ece17c2.tar.bz2 portable-70e6be3d6e82cbdc7a8ca5e9f2a1e0d95ece17c2.zip | |
move clock_gettime check out
| -rw-r--r-- | CMakeLists.txt | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index a67405a..37ef9c9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
| @@ -283,8 +283,11 @@ endif() | |||
| 283 | if(WIN32) | 283 | if(WIN32) |
| 284 | set(OPENSSL_LIBS ${OPENSSL_LIBS} ws2_32) | 284 | set(OPENSSL_LIBS ${OPENSSL_LIBS} ws2_32) |
| 285 | endif() | 285 | endif() |
| 286 | check_library_exists(rt clock_gettime "time.h" HAVE_CLOCK_GETTIME) | ||
| 287 | if (HAVE_CLOCK_GETTIME) | ||
| 288 | add_definitions(-DHAVE_CLOCK_GETTIME) | ||
| 289 | endif() | ||
| 286 | if(CMAKE_SYSTEM_NAME MATCHES "Linux") | 290 | if(CMAKE_SYSTEM_NAME MATCHES "Linux") |
| 287 | check_library_exists(rt clock_gettime "time.h" HAVE_CLOCK_GETTIME) | ||
| 288 | if (HAVE_CLOCK_GETTIME) | 291 | if (HAVE_CLOCK_GETTIME) |
| 289 | set(OPENSSL_LIBS ${OPENSSL_LIBS} rt) | 292 | set(OPENSSL_LIBS ${OPENSSL_LIBS} rt) |
| 290 | endif() | 293 | endif() |
