From aecf3810c22ac5e904b0eb7bfe26e3168f3f4f43 Mon Sep 17 00:00:00 2001 From: dimitri staessens Date: Thu, 10 Aug 2017 22:56:12 +0200 Subject: build: Fix compilation on OS X Sierra --- src/ipcpd/CMakeLists.txt | 2 +- src/ipcpd/normal/dht.c | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'src/ipcpd') diff --git a/src/ipcpd/CMakeLists.txt b/src/ipcpd/CMakeLists.txt index e0b375b6..2e8bda23 100644 --- a/src/ipcpd/CMakeLists.txt +++ b/src/ipcpd/CMakeLists.txt @@ -10,5 +10,5 @@ add_subdirectory(normal) add_subdirectory(shim-udp) if (NOT APPLE AND NOT CMAKE_SYSTEM_NAME STREQUAL GNU) add_subdirectory(shim-eth-llc) + add_subdirectory(tests) endif () -add_subdirectory(tests) diff --git a/src/ipcpd/normal/dht.c b/src/ipcpd/normal/dht.c index 5c294c00..e1c34b6f 100644 --- a/src/ipcpd/normal/dht.c +++ b/src/ipcpd/normal/dht.c @@ -46,6 +46,10 @@ typedef KadMsg kad_msg_t; typedef KadContactMsg kad_contact_msg_t; +#ifndef CLOCK_REALTIME_COARSE +#define CLOCK_REALTIME_COARSE CLOCK_REALTIME +#endif + #define DHT_MAX_REQS 2048 /* KAD recommends rnd(), bmp can be changed. */ #define KAD_ALPHA 3 /* Parallel factor, proven optimal value. */ #define KAD_K 8 /* Replication factor, MDHT value. */ -- cgit v1.2.3