summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2020-04-09 16:27:18 +0000
committerRoy Marples <roy@marples.name>2020-04-09 16:27:18 +0000
commitb80ede91ab859c9e74bbbec93cecb4a29032203e (patch)
tree33d91d5f5494f98f3d50b5919ffd8b041afd4011 /src
parented8ee248c69fc67fe868637244f69ec565b8a4bb (diff)
downloaddhcpcd-b80ede91ab859c9e74bbbec93cecb4a29032203e.tar.xz
RTA_PREF was added in kernel-4.1
Diffstat (limited to 'src')
-rw-r--r--src/route.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/route.h b/src/route.h
index a061497c..d94fc25d 100644
--- a/src/route.h
+++ b/src/route.h
@@ -61,7 +61,10 @@
#endif
#ifdef __linux__
-# define HAVE_ROUTE_PREF
+# include <linux/version.h> /* RTA_PREF is only an enum.... */
+# if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 1, 0)
+# define HAVE_ROUTE_PREF
+# endif
#endif
#if defined(__OpenBSD__) || defined (__sun)