summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Korsgaard <peter@korsgaard.com>2014-08-11 09:37:05 +0200
committerThomas Haller <thaller@redhat.com>2014-08-11 13:16:22 +0200
commit123322c6d61b8db9e8e7a627c80d8d4df43a5c8d (patch)
tree55f40af14188d4e55a1209958f2b21e5b04f4dd6
parent2bd5cf51b809f9593930d951af6cc7487c4330f8 (diff)
core: fix build with toolchains not exporting CLOCK_BOOTTIME
E.G. uClibc 0.9.33 and earlier. https://bugzilla.gnome.org/show_bug.cgi?id=734599 Signed-off-by: Peter Korsgaard <peter@korsgaard.com> Signed-off-by: Thomas Haller <thaller@redhat.com>
-rw-r--r--src/NetworkManagerUtils.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/NetworkManagerUtils.c b/src/NetworkManagerUtils.c
index aa689ce05f..fc85b0040c 100644
--- a/src/NetworkManagerUtils.c
+++ b/src/NetworkManagerUtils.c
@@ -45,6 +45,15 @@
#include "nm-posix-signals.h"
/*
+ * Some toolchains (E.G. uClibc 0.9.33 and earlier) don't export
+ * CLOCK_BOOTTIME even though the kernel supports it, so provide a
+ * local definition
+ */
+#ifndef CLOCK_BOOTTIME
+#define CLOCK_BOOTTIME 7
+#endif
+
+/*
* nm_ethernet_address_is_valid
*
* Compares an Ethernet address against known invalid addresses.