|
@@ -3,21 +3,17 @@
|
|
Disable IPv6 support code when building with uClibc configured without IPv6
|
|
Disable IPv6 support code when building with uClibc configured without IPv6
|
|
support.
|
|
support.
|
|
|
|
|
|
|
|
+[Gustavo: update for iproute2 3.10.0]
|
|
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
|
|
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
|
|
----
|
|
|
|
- ip/ip6tunnel.c | 6 ++++++
|
|
|
|
- ip/ipprefix.c | 8 ++++++++
|
|
|
|
- ip/iptunnel.c | 6 ++++++
|
|
|
|
- 3 files changed, 20 insertions(+)
|
|
|
|
|
|
+Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
|
|
|
|
|
|
-Index: iproute2-2.6.37-orig/ip/ip6tunnel.c
|
|
|
|
-===================================================================
|
|
|
|
---- iproute2-2.6.37-orig.orig/ip/ip6tunnel.c
|
|
|
|
-+++ iproute2-2.6.37-orig/ip/ip6tunnel.c
|
|
|
|
|
|
+diff -Nura iproute2-3.10.0.orig/ip/ip6tunnel.c iproute2-3.10.0/ip/ip6tunnel.c
|
|
|
|
+--- iproute2-3.10.0.orig/ip/ip6tunnel.c 2013-08-14 09:17:56.538089916 -0300
|
|
|
|
++++ iproute2-3.10.0/ip/ip6tunnel.c 2013-08-14 09:18:02.952298534 -0300
|
|
@@ -20,6 +20,10 @@
|
|
@@ -20,6 +20,10 @@
|
|
* Masahide NAKAMURA @USAGI
|
|
* Masahide NAKAMURA @USAGI
|
|
*/
|
|
*/
|
|
-
|
|
|
|
|
|
+
|
|
+#include <features.h>
|
|
+#include <features.h>
|
|
+#if defined(__UCLIBC__) && !defined (__UCLIBC_HAS_IPV6__)
|
|
+#if defined(__UCLIBC__) && !defined (__UCLIBC_HAS_IPV6__)
|
|
+#else
|
|
+#else
|
|
@@ -25,36 +21,36 @@ Index: iproute2-2.6.37-orig/ip/ip6tunnel.c
|
|
#include <stdio.h>
|
|
#include <stdio.h>
|
|
#include <string.h>
|
|
#include <string.h>
|
|
#include <stdlib.h>
|
|
#include <stdlib.h>
|
|
-@@ -410,3 +414,5 @@ int do_ip6tunnel(int argc, char **argv)
|
|
|
|
|
|
+@@ -425,3 +429,5 @@
|
|
fprintf(stderr, "Command \"%s\" is unknown, try \"ip -f inet6 tunnel help\".\n", *argv);
|
|
fprintf(stderr, "Command \"%s\" is unknown, try \"ip -f inet6 tunnel help\".\n", *argv);
|
|
exit(-1);
|
|
exit(-1);
|
|
}
|
|
}
|
|
+
|
|
+
|
|
+#endif /* no ipv6 */
|
|
+#endif /* no ipv6 */
|
|
-Index: iproute2-2.6.37-orig/ip/ipprefix.c
|
|
|
|
-===================================================================
|
|
|
|
---- iproute2-2.6.37-orig.orig/ip/ipprefix.c
|
|
|
|
-+++ iproute2-2.6.37-orig/ip/ipprefix.c
|
|
|
|
-@@ -22,11 +22,17 @@
|
|
|
|
- * Authors:
|
|
|
|
|
|
+diff -Nura iproute2-3.10.0.orig/ip/ipprefix.c iproute2-3.10.0/ip/ipprefix.c
|
|
|
|
+--- iproute2-3.10.0.orig/ip/ipprefix.c 2013-08-14 09:17:56.539089949 -0300
|
|
|
|
++++ iproute2-3.10.0/ip/ipprefix.c 2013-08-14 09:19:29.065099291 -0300
|
|
|
|
+@@ -23,11 +23,18 @@
|
|
* Masahide NAKAMURA @USAGI
|
|
* Masahide NAKAMURA @USAGI
|
|
*/
|
|
*/
|
|
|
|
+
|
|
+#include <features.h>
|
|
+#include <features.h>
|
|
+#if defined(__UCLIBC__) && !defined (__UCLIBC_HAS_IPV6__)
|
|
+#if defined(__UCLIBC__) && !defined (__UCLIBC_HAS_IPV6__)
|
|
+#define NO_IPV6
|
|
+#define NO_IPV6
|
|
+#endif
|
|
+#endif
|
|
-
|
|
|
|
|
|
++
|
|
#include <stdio.h>
|
|
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
#include <stdlib.h>
|
|
#include <string.h>
|
|
#include <string.h>
|
|
|
|
+ #include <sys/socket.h>
|
|
+#ifndef NO_IPV6
|
|
+#ifndef NO_IPV6
|
|
#include <netinet/icmp6.h>
|
|
#include <netinet/icmp6.h>
|
|
+#endif
|
|
+#endif
|
|
|
|
+
|
|
#include "utils.h"
|
|
#include "utils.h"
|
|
-
|
|
|
|
- /* prefix flags; see kernel's net/ipv6/addrconf.c and include/net/if_inet6.h */
|
|
|
|
-@@ -62,10 +68,12 @@ int print_prefix(const struct sockaddr_n
|
|
|
|
- fprintf(stderr, "wrong family %d\n", prefix->prefix_family);
|
|
|
|
|
|
+ #include "ip_common.h"
|
|
|
|
+@@ -65,10 +72,12 @@
|
|
|
|
+ fprintf(stderr, "incorrect protocol family: %d\n", prefix->prefix_family);
|
|
return 0;
|
|
return 0;
|
|
}
|
|
}
|
|
+#ifdef ND_OPT_PREFIX_INFORMATION
|
|
+#ifdef ND_OPT_PREFIX_INFORMATION
|
|
@@ -63,13 +59,12 @@ Index: iproute2-2.6.37-orig/ip/ipprefix.c
|
|
return 0;
|
|
return 0;
|
|
}
|
|
}
|
|
+#endif
|
|
+#endif
|
|
-
|
|
|
|
|
|
+
|
|
parse_rtattr(tb, RTA_MAX, RTM_RTA(prefix), len);
|
|
parse_rtattr(tb, RTA_MAX, RTM_RTA(prefix), len);
|
|
-
|
|
|
|
-Index: iproute2-2.6.37-orig/ip/iptunnel.c
|
|
|
|
-===================================================================
|
|
|
|
---- iproute2-2.6.37-orig.orig/ip/iptunnel.c
|
|
|
|
-+++ iproute2-2.6.37-orig/ip/iptunnel.c
|
|
|
|
|
|
+
|
|
|
|
+diff -Nura iproute2-3.10.0.orig/ip/iptunnel.c iproute2-3.10.0/ip/iptunnel.c
|
|
|
|
+--- iproute2-3.10.0.orig/ip/iptunnel.c 2013-08-14 09:17:56.538089916 -0300
|
|
|
|
++++ iproute2-3.10.0/ip/iptunnel.c 2013-08-14 09:18:02.953298566 -0300
|
|
@@ -9,6 +9,10 @@
|
|
@@ -9,6 +9,10 @@
|
|
* Authors: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru>
|
|
* Authors: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru>
|
|
*
|
|
*
|
|
@@ -78,10 +73,10 @@ Index: iproute2-2.6.37-orig/ip/iptunnel.c
|
|
+#if defined(__UCLIBC__) && !defined (__UCLIBC_HAS_IPV6__)
|
|
+#if defined(__UCLIBC__) && !defined (__UCLIBC_HAS_IPV6__)
|
|
+#define NO_IPV6
|
|
+#define NO_IPV6
|
|
+#endif
|
|
+#endif
|
|
-
|
|
|
|
|
|
+
|
|
#include <stdio.h>
|
|
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
#include <stdlib.h>
|
|
-@@ -601,8 +605,10 @@ int do_iptunnel(int argc, char **argv)
|
|
|
|
|
|
+@@ -634,8 +638,10 @@
|
|
* protocol-independent because of unarranged structure between
|
|
* protocol-independent because of unarranged structure between
|
|
* IPv4 and IPv6.
|
|
* IPv4 and IPv6.
|
|
*/
|
|
*/
|
|
@@ -90,5 +85,5 @@ Index: iproute2-2.6.37-orig/ip/iptunnel.c
|
|
return do_ip6tunnel(argc, argv);
|
|
return do_ip6tunnel(argc, argv);
|
|
+#endif
|
|
+#endif
|
|
default:
|
|
default:
|
|
- fprintf(stderr, "Unsupported family:%d\n", preferred_family);
|
|
|
|
|
|
+ fprintf(stderr, "Unsupported protocol family: %d\n", preferred_family);
|
|
exit(-1);
|
|
exit(-1);
|