[Dnsmasq-discuss] dnsmasq failing to compile

Simon Kelley simon at thekelleys.org.uk
Tue Dec 5 14:42:51 GMT 2006


Philip Wall wrote:
> Switched to kernel sources 2.6.18.1 and it built fine so must be an 
> issue between dnsmasq and the 2.6.19 kernel.
> 
> Philip Wall
> 

The following patch seems to fix it.



Cheers,

Simon.

--- src/netlink.c.orig  2006-12-05 14:37:43.000000000 +0000
+++ src/netlink.c       2006-12-05 14:36:56.000000000 +0000
@@ -18,6 +18,14 @@
 #include <linux/netlink.h>
 #include <linux/rtnetlink.h>

+/* linux 2.6.19 buggers up the headers, patch it up here. */
+#ifndef IFA_RTA
+#  define IFA_RTA(r)  \
+       ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct
ifaddrmsg))))
+
+#  include <linux/if_addr.h>
+#endif
+
 static struct iovec iov;

 static void nl_err(struct nlmsghdr *h);






More information about the Dnsmasq-discuss mailing list