]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Only include linux/if_addr.h for 2.6.19 kernels and better
authorRoy Marples <roy@marples.name>
Mon, 4 Dec 2006 12:40:14 +0000 (12:40 +0000)
committerRoy Marples <roy@marples.name>
Mon, 4 Dec 2006 12:40:14 +0000 (12:40 +0000)
ChangeLog
interface.c

index 720928787ea2beab46e0f38af0527743ab68180f..4032b02683ea14aabeb96bee7e47434fb1ebe4d4 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,4 @@
-Include linux/if_addr.h so we compile on 2.6.19 kernels, thanks to AlexExtreme.
+Include linux/if_addr.h for 2.6.19+ kernels, thanks to AlexExtreme.
 
 dhcpcd-3.0.2
 Linux systems without glibc-2.3 don't have getifaddrs, so we define our own.
index 2ec8f8c50b25239b3e0911105e5ce3bef0ac0873..16d4ed48d1366865c6ad9a41778b3e227bbb31c3 100644 (file)
 #ifdef __linux__ 
 #include <asm/types.h> /* Needed for 2.4 kernels */
 #include <features.h>
+#include <linux/version.h>
+#if LINUX_VERSION_CODE >= KERNEL_VERSION (2,6,19)
 #include <linux/if_addr.h>
+#endif
 #include <linux/netlink.h>
 #include <linux/rtnetlink.h>
 #include <netinet/ether.h>