ports

recipes for building multiple softwares
git clone git://z3bra.org/ports
Log | Files | Refs

commit f80ae56096f9f9e2e4067dbafffbb22fb07d64b8
parent 7dd82ff8fb12eee9c94c018787b2ed3ac9cc56d6
Author: z3bra <willyatmailoodotorg>
Date:   Sun Aug 16 16:47:47 2015

iputils: new port

Diffstat:
 iputils/makeme                                                                              | 18 +++++++++++++++-
 iputils/patches/iputils-20070202-no-open-max.patch                                          | 16 ++++++++++++++-
 iputils/patches/net-misc_iputils_files_iputils-20121221-add-bits_types_h.patch              | 94 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 iputils/patches/net-misc_iputils_files_iputils-20121221-crypto-build.patch                  | 35 ++++++++++++++++++++++++++++++-
 iputils/patches/net-misc_iputils_files_iputils-20121221-fix-init-elemnt.patch               | 23 ++++++++++++++++++++-
 iputils/patches/net-misc_iputils_files_iputils-20121221-fix-musl-headers.patch              | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 iputils/patches/net-misc_iputils_files_iputils-20121221-makefile.patch                      | 61 ++++++++++++++++++++++++++++++++++++++++++++++++++++-
 iputils/patches/net-misc_iputils_files_iputils-20121221-openssl.patch                       | 92 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 iputils/patches/net-misc_iputils_files_iputils-20121221-printf-size.patch                   | 64 ++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 iputils/patches/net-misc_iputils_files_iputils-20121221-remove-rdisc-glibc-assumption.patch | 30 ++++++++++++++++++++++++++-
 iputils/patches/time.patch                                                                  | 10 +++++++++-
 11 files changed, 532 insertions(+), 0 deletions(-)

diff --git a/iputils/makeme b/iputils/makeme @@ -0,0 +1,18 @@ +name=iputils +version=s20121221 +source=http://www.skbuff.net/iputils/$name-$version.tar.bz2 + +package() { + curl -# $source | tar xj + cd $name-$version + + cat ../patches/*.patch | patch -Np1 + + make USE_GNUTLS=no CC="$CC" LDFLAGS="$LDFLAGS" + + install -d $WORKDIR/$name/{{s,}bin,usr/{man/man8,sbin}} + install ping{,6} $WORKDIR/$name/bin/ + install arping $WORKDIR/$name/sbin/ + install tracepath{,6} traceroute6 clockdiff rarpd rdisc $WORKDIR/$name/usr/sbin/ + chmod u+s $WORKDIR/$name/bin/ping{,6} $WORKDIR/$name/usr/sbin/traceroute6 +} diff --git a/iputils/patches/iputils-20070202-no-open-max.patch b/iputils/patches/iputils-20070202-no-open-max.patch @@ -0,0 +1,16 @@ +the OPEN_MAX define has been removed in newer kernel headers so use the +proper method of getting the value dynamically + +http://bugs.gentoo.org/195861 + +--- a/rdisc.c ++++ b/rdisc.c +@@ -247,7 +247,7 @@ void do_fork(void) + if ((pid=fork()) != 0) + exit(0); + +- for (t = 0; t < OPEN_MAX; t++) ++ for (t = 0; t < sysconf(_SC_OPEN_MAX); t++) + if (t != s) + close(t); + diff --git a/iputils/patches/net-misc_iputils_files_iputils-20121221-add-bits_types_h.patch b/iputils/patches/net-misc_iputils_files_iputils-20121221-add-bits_types_h.patch @@ -0,0 +1,94 @@ +diff -Naur iputils-s20121221.orig/clockdiff.c iputils-s20121221/clockdiff.c +--- iputils-s20121221.orig/clockdiff.c 2014-01-24 15:32:49.111934548 +0000 ++++ iputils-s20121221/clockdiff.c 2014-01-24 15:32:14.438932610 +0000 +@@ -23,6 +23,8 @@ + #include <sys/capability.h> + #endif + ++#include "types.h" ++ + void usage(void) __attribute__((noreturn)); + + #define MAX_HOSTNAMELEN NI_MAXHOST +diff -Naur iputils-s20121221.orig/ping.c iputils-s20121221/ping.c +--- iputils-s20121221.orig/ping.c 2014-01-24 15:32:49.111934548 +0000 ++++ iputils-s20121221/ping.c 2014-01-24 15:32:14.459932611 +0000 +@@ -59,6 +59,7 @@ + */ + + #include "ping_common.h" ++#include "types.h" + + #include <netinet/ip.h> + #include <netinet/ip_icmp.h> +diff -Naur iputils-s20121221.orig/ping6.c iputils-s20121221/ping6.c +--- iputils-s20121221.orig/ping6.c 2014-01-24 15:32:49.112934549 +0000 ++++ iputils-s20121221/ping6.c 2014-01-24 15:32:14.439932610 +0000 +@@ -67,6 +67,7 @@ + * This program has to run SUID to ROOT to access the ICMP socket. + */ + #include "ping_common.h" ++#include "types.h" + + #include <linux/filter.h> + #include <netinet/ip6.h> +diff -Naur iputils-s20121221.orig/ping_common.c iputils-s20121221/ping_common.c +--- iputils-s20121221.orig/ping_common.c 2014-01-24 15:32:49.112934549 +0000 ++++ iputils-s20121221/ping_common.c 2014-01-24 15:32:14.439932610 +0000 +@@ -1,4 +1,5 @@ + #include "ping_common.h" ++#include "types.h" + #include <ctype.h> + #include <sched.h> + #include <math.h> +diff -Naur iputils-s20121221.orig/ping_common.h iputils-s20121221/ping_common.h +--- iputils-s20121221.orig/ping_common.h 2014-01-24 15:32:14.419932609 +0000 ++++ iputils-s20121221/ping_common.h 2014-01-24 15:33:08.206935616 +0000 +@@ -35,6 +35,7 @@ + #include <linux/errqueue.h> + + #include "SNAPSHOT.h" ++#include "types.h" + + #define DEFDATALEN (64 - 8) /* default data length */ + +diff -Naur iputils-s20121221.orig/rdisc.c iputils-s20121221/rdisc.c +--- iputils-s20121221.orig/rdisc.c 2014-01-24 15:32:49.113934549 +0000 ++++ iputils-s20121221/rdisc.c 2014-01-24 15:32:14.450932610 +0000 +@@ -62,6 +62,7 @@ + #include <syslog.h> + + #include "SNAPSHOT.h" ++#include "types.h" + + struct interface + { +diff -Naur iputils-s20121221.orig/traceroute6.c iputils-s20121221/traceroute6.c +--- iputils-s20121221.orig/traceroute6.c 2014-01-24 15:32:49.113934549 +0000 ++++ iputils-s20121221/traceroute6.c 2014-01-24 15:32:14.440932610 +0000 +@@ -267,6 +267,7 @@ + #include <string.h> + #include <unistd.h> + ++#include "types.h" + #include "SNAPSHOT.h" + + #ifndef SOL_IPV6 +diff -Naur iputils-s20121221.orig/types.h iputils-s20121221/types.h +--- iputils-s20121221.orig/types.h 1970-01-01 00:00:00.000000000 +0000 ++++ iputils-s20121221/types.h 2014-01-24 15:32:14.440932610 +0000 +@@ -0,0 +1,14 @@ ++/* This is a small version of <bits/types.h> from glibc ++ * to take care of type u_char. ++ * ++ * Anthony G. Basile <blueness@gentoo.org> ++ */ ++#ifndef _BITS_TYPES_H ++#define _BITS_TYPES_H 1 ++ ++typedef unsigned char u_char; ++typedef unsigned short int u_short; ++typedef unsigned int u_int; ++typedef unsigned long int u_long; ++ ++#endif /* mini <bits/types.h> */ diff --git a/iputils/patches/net-misc_iputils_files_iputils-20121221-crypto-build.patch b/iputils/patches/net-misc_iputils_files_iputils-20121221-crypto-build.patch @@ -0,0 +1,35 @@ +From 568e990d30fc7e9416e0a6f8c74ea5013921eaec Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven <arjanvandeven@gmail.com> +Date: Wed, 16 Jan 2013 03:12:15 +0900 +Subject: [PATCH [iputils]] ping6: Fix build command line argument with gnutls. + +The ping6 command can use either openssl or gnutls... +and the Makefile has a bunch of setup for defining which of the two to use. + +Unfortunately, the final -D define on the commandline to enable gnutls +inside the ping6.c file didn't actually make it onto the gcc +commandline. +This patch adds the $(DEF_CRYPTO) Makefile variable to fix this gap. + +Signed-off-by: Arjan van de Ven <arjanvandeven@gmail.com> +Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index c62d9df..89249f5 100644 +--- a/Makefile ++++ b/Makefile +@@ -149,7 +149,7 @@ LIB_clockdiff = $(LIB_CAP) + DEF_ping_common = $(DEF_CAP) $(DEF_IDN) + DEF_ping = $(DEF_CAP) $(DEF_IDN) $(DEF_WITHOUT_IFADDRS) + LIB_ping = $(LIB_CAP) $(LIB_IDN) +-DEF_ping6 = $(DEF_CAP) $(DEF_IDN) $(DEF_WITHOUT_IFADDRS) $(DEF_ENABLE_PING6_RTHDR) ++DEF_ping6 = $(DEF_CAP) $(DEF_IDN) $(DEF_WITHOUT_IFADDRS) $(DEF_ENABLE_PING6_RTHDR) $(DEF_CRYPTO) + LIB_ping6 = $(LIB_CAP) $(LIB_IDN) $(LIB_RESOLV) $(LIB_CRYPTO) + + ping: ping_common.o +-- +1.8.0.2 + diff --git a/iputils/patches/net-misc_iputils_files_iputils-20121221-fix-init-elemnt.patch b/iputils/patches/net-misc_iputils_files_iputils-20121221-fix-init-elemnt.patch @@ -0,0 +1,23 @@ +diff -Naur iputils-s20121221.orig/ping.c iputils-s20121221/ping.c +--- iputils-s20121221.orig/ping.c 2014-01-24 15:05:02.082841335 +0000 ++++ iputils-s20121221/ping.c 2014-01-24 15:17:12.975882203 +0000 +@@ -774,9 +774,16 @@ + + do { + static struct iovec iov = {outpack, 0}; +- static struct msghdr m = { &whereto, sizeof(whereto), +- &iov, 1, &cmsg, 0, 0 }; +- m.msg_controllen = cmsg_len; ++ static struct msghdr m; ++ ++ m.msg_name = &whereto; ++ m.msg_namelen = sizeof(whereto); ++ m.msg_iov = &iov; ++ m.msg_iovlen = 1; ++ m.msg_control = &cmsg; ++ m.msg_controllen = sizeof(cmsg); ++ m.msg_flags = 0; ++ + iov.iov_len = cc; + + i = sendmsg(icmp_sock, &m, confirm); diff --git a/iputils/patches/net-misc_iputils_files_iputils-20121221-fix-musl-headers.patch b/iputils/patches/net-misc_iputils_files_iputils-20121221-fix-musl-headers.patch @@ -0,0 +1,89 @@ +diff -Naur iputils-s20121221.orig/arping.c iputils-s20121221/arping.c +--- iputils-s20121221.orig/arping.c 2012-12-21 14:01:07.000000000 +0000 ++++ iputils-s20121221/arping.c 2014-01-23 21:19:57.091268011 +0000 +@@ -16,7 +16,7 @@ + #include <linux/sockios.h> + #include <sys/file.h> + #include <sys/time.h> +-#include <sys/signal.h> ++#include <signal.h> + #include <sys/ioctl.h> + #include <net/if.h> + #include <linux/if_packet.h> +--- iputils-s20121221.orig/clockdiff.c 2012-12-21 14:01:07.000000000 +0000 ++++ iputils-s20121221/clockdiff.c 2014-01-23 21:19:57.093268011 +0000 +@@ -14,7 +14,6 @@ + #include <netinet/ip.h> + #include <netinet/ip_icmp.h> + #define TSPTYPES +-#include <protocols/timed.h> + #include <fcntl.h> + #include <netdb.h> + #include <arpa/inet.h> +diff -Naur iputils-s20121221.orig/ping_common.h iputils-s20121221/ping_common.h +--- iputils-s20121221.orig/ping_common.h 2012-12-21 14:01:07.000000000 +0000 ++++ iputils-s20121221/ping_common.h 2014-01-23 21:27:07.677292088 +0000 +@@ -7,16 +7,17 @@ + #include <linux/sockios.h> + #include <sys/file.h> + #include <sys/time.h> +-#include <sys/signal.h> ++#include <signal.h> + #include <sys/ioctl.h> + #include <net/if.h> + #include <sys/uio.h> +-#include <sys/poll.h> ++#include <poll.h> + #include <ctype.h> + #include <errno.h> + #include <string.h> + #include <netdb.h> + #include <setjmp.h> ++#include <asm-generic/param.h> + + #ifdef CAPABILITIES + #include <sys/prctl.h> +--- iputils-s20121221.orig/rarpd.c 2014-01-24 13:38:46.816551953 +0000 ++++ iputils-s20121221/rarpd.c 2014-01-24 13:36:51.833545524 +0000 +@@ -19,16 +19,17 @@ + #include <netdb.h> + #include <arpa/inet.h> + #include <sys/ioctl.h> +-#include <sys/poll.h> +-#include <sys/errno.h> +-#include <sys/fcntl.h> ++#include <poll.h> ++#include <errno.h> ++#include <fcntl.h> + #include <sys/socket.h> +-#include <sys/signal.h> ++#include <signal.h> + #include <linux/if.h> + #include <linux/if_arp.h> + #include <netinet/in.h> + #include <linux/if_packet.h> + #include <linux/filter.h> ++#include <sys/types.h> + + int do_reload = 1; + +--- iputils-s20121221.orig/tracepath.c 2014-01-24 13:38:46.865551956 +0000 ++++ iputils-s20121221/tracepath.c 2014-01-23 21:19:57.109268012 +0000 +@@ -23,6 +23,7 @@ + #include <sys/time.h> + #include <sys/uio.h> + #include <arpa/inet.h> ++#include <limits.h> + #ifdef USE_IDN + #include <idna.h> + #include <locale.h> +--- iputils-s20121221.orig/tracepath6.c 2014-01-24 13:38:46.865551956 +0000 ++++ iputils-s20121221/tracepath6.c 2014-01-23 21:20:40.316270428 +0000 +@@ -25,6 +25,7 @@ + #include <sys/time.h> + #include <sys/uio.h> + #include <arpa/inet.h> ++#include <limits.h> + + #ifdef USE_IDN + #include <idna.h> diff --git a/iputils/patches/net-misc_iputils_files_iputils-20121221-makefile.patch b/iputils/patches/net-misc_iputils_files_iputils-20121221-makefile.patch @@ -0,0 +1,61 @@ +From c66609d2c830d6fe06f48f5d38c54eb5cc6f2975 Mon Sep 17 00:00:00 2001 +From: Mike Frysinger <vapier@gentoo.org> +Date: Thu, 24 Jan 2013 23:36:16 -0500 +Subject: [PATCH [iputils]] fix handling of CFLAGS + +This defaults CFLAGS to -O3 without clobbering settings people have set +up in the environment already. + +Signed-off-by: Mike Frysinger <vapier@gentoo.org> +--- + Makefile | 13 +++++-------- + 1 file changed, 5 insertions(+), 8 deletions(-) + +diff --git a/Makefile b/Makefile +index 2c49940..ecabac3 100644 +--- a/Makefile ++++ b/Makefile +@@ -2,8 +2,6 @@ + # Configuration + # + +-# CC +-CC=gcc + # Path to parent kernel include files directory + LIBC_INCLUDE=/usr/include + # Libraries +@@ -48,11 +46,10 @@ ENABLE_RDISC_SERVER=no + + # ------------------------------------- + # What a pity, all new gccs are buggy and -Werror does not work. Sigh. +-# CCOPT=-fno-strict-aliasing -Wstrict-prototypes -Wall -Werror -g +-CCOPT=-fno-strict-aliasing -Wstrict-prototypes -Wall -g +-CCOPTOPT=-O3 +-GLIBCFIX=-D_GNU_SOURCE +-DEFINES= ++# CFLAGS+=-fno-strict-aliasing -Wstrict-prototypes -Wall -Werror -g ++CFLAGS?=-O3 -g ++CFLAGS+=-fno-strict-aliasing -Wstrict-prototypes -Wall ++CPPFLAGS+=-D_GNU_SOURCE + LDLIB= + + FUNC_LIB = $(if $(filter static,$(1)),$(LDFLAG_STATIC) $(2) $(LDFLAG_DYNAMIC),$(2)) +@@ -113,7 +110,6 @@ IPV4_TARGETS=tracepath ping clockdiff rdisc arping tftpd rarpd + IPV6_TARGETS=tracepath6 traceroute6 ping6 + TARGETS=$(IPV4_TARGETS) $(IPV6_TARGETS) + +-CFLAGS=$(CCOPTOPT) $(CCOPT) $(GLIBCFIX) $(DEFINES) + LDLIBS=$(LDLIB) $(ADDLIB) + + UNAME_N:=$(shell uname -n) +@@ -132,6 +128,7 @@ all: $(TARGETS) + $(COMPILE.c) $< $(DEF_$(patsubst %.o,%,$@)) -S -o $@ + %.o: %.c + $(COMPILE.c) $< $(DEF_$(patsubst %.o,%,$@)) -o $@ ++LINK.o += $(CFLAGS) + $(TARGETS): %: %.o + $(LINK.o) $^ $(LIB_$@) $(LDLIBS) -o $@ + +-- +1.8.0.2 + diff --git a/iputils/patches/net-misc_iputils_files_iputils-20121221-openssl.patch b/iputils/patches/net-misc_iputils_files_iputils-20121221-openssl.patch @@ -0,0 +1,92 @@ +From b57d77dcfa5cb363b7eba5b331324669a8505ac4 Mon Sep 17 00:00:00 2001 +From: Mike Frysinger <vapier@gentoo.org> +Date: Thu, 24 Jan 2013 23:32:39 -0500 +Subject: [PATCH [iputils]] ping6: allow disabling of openssl support + +Signed-off-by: Mike Frysinger <vapier@gentoo.org> +--- + Makefile | 5 ++++- + ping6.c | 14 +++++++++++++- + 2 files changed, 17 insertions(+), 2 deletions(-) + +diff --git a/Makefile b/Makefile +index 89249f5..2c49940 100644 +--- a/Makefile ++++ b/Makefile +@@ -36,7 +36,7 @@ ARPING_DEFAULT_DEVICE= + + # GNU TLS library for ping6 [yes|no|static] + USE_GNUTLS=yes +-# Crypto library for ping6 [shared|static] ++# Crypto library for ping6 [shared|static|no] + USE_CRYPTO=shared + # Resolv library for ping6 [yes|static] + USE_RESOLV=yes +@@ -63,7 +63,10 @@ ifneq ($(USE_GNUTLS),no) + LIB_CRYPTO = $(call FUNC_LIB,$(USE_GNUTLS),$(LDFLAG_GNUTLS)) + DEF_CRYPTO = -DUSE_GNUTLS + else ++ifneq ($(USE_CRYPTO),no) + LIB_CRYPTO = $(call FUNC_LIB,$(USE_CRYPTO),$(LDFLAG_CRYPTO)) ++ DEF_CRYPTO = -DUSE_OPENSSL ++endif + endif + + # USE_RESOLV: LIB_RESOLV +diff --git a/ping6.c b/ping6.c +index c39864d..f2f90af 100644 +--- a/ping6.c ++++ b/ping6.c +@@ -168,8 +168,10 @@ static int icmp_sock; + + #ifdef USE_GNUTLS + # include <gnutls/openssl.h> +-#else ++# define USE_CRYPTO ++#elif defined USE_OPENSSL + # include <openssl/md5.h> ++# define USE_CRYPTO + #endif + + /* Node Information query */ +@@ -326,6 +328,7 @@ static void niquery_init_nonce(void) + #if !PING6_NONCE_MEMORY + static int niquery_nonce(__u8 *nonce, int fill) + { ++# ifdef USE_CRYPTO + static __u8 digest[MD5_DIGEST_LENGTH]; + static int seq = -1; + +@@ -348,6 +351,10 @@ static int niquery_nonce(__u8 *nonce, int fill) + return -1; + return ntohsp((__u16 *)nonce); + } ++# else ++ fprintf(stderr, "ping6: function not available; crypto disabled\n"); ++ exit(3); ++# endif + } + #endif + +@@ -502,6 +509,7 @@ static int niquery_option_subject_addr_handler(int index, const char *arg) + + static int niquery_option_subject_name_handler(int index, const char *arg) + { ++#ifdef USE_CRYPTO + static char nigroup_buf[INET6_ADDRSTRLEN + 1 + IFNAMSIZ]; + unsigned char *dnptrs[2], **dpp, **lastdnptr; + int n; +@@ -627,6 +635,10 @@ errexit: + free(idn); + free(name); + exit(1); ++#else ++ fprintf(stderr, "ping6: function not available; crypto disabled\n"); ++ exit(3); ++#endif + } + + int niquery_option_help_handler(int index, const char *arg) +-- +1.8.0.2 + diff --git a/iputils/patches/net-misc_iputils_files_iputils-20121221-printf-size.patch b/iputils/patches/net-misc_iputils_files_iputils-20121221-printf-size.patch @@ -0,0 +1,64 @@ +From 23fcb10ae15a96aa9e5a823cfe0b612d9522691c Mon Sep 17 00:00:00 2001 +From: Mike Frysinger <vapier@gentoo.org> +Date: Sat, 14 Aug 2010 01:16:42 -0400 +Subject: [PATCH [iputils]] tracepath: re-use printf return in print_host + +Since the printf funcs already return the length of chars displayed, +use that value instead of re-calculating the length with strlen. + +This also fixes the handling of the strlen return -- it's a size_t, +not an int. + +Signed-off-by: Mike Frysinger <vapier@gentoo.org> +--- + tracepath.c | 11 ++++------- + tracepath6.c | 11 ++++------- + 2 files changed, 8 insertions(+), 14 deletions(-) + +diff --git a/tracepath.c b/tracepath.c +index 8a08f1d..f155816 100644 +--- a/tracepath.c ++++ b/tracepath.c +@@ -73,13 +73,10 @@ void data_wait(int fd) + + void print_host(const char *a, const char *b, int both) + { +- int plen = 0; +- printf("%s", a); +- plen = strlen(a); +- if (both) { +- printf(" (%s)", b); +- plen += strlen(b) + 3; +- } ++ int plen; ++ plen = printf("%s", a); ++ if (both) ++ plen += printf(" (%s)", b); + if (plen >= HOST_COLUMN_SIZE) + plen = HOST_COLUMN_SIZE - 1; + printf("%*s", HOST_COLUMN_SIZE - plen, ""); +diff --git a/tracepath6.c b/tracepath6.c +index 126fadf..bee95c3 100644 +--- a/tracepath6.c ++++ b/tracepath6.c +@@ -86,13 +86,10 @@ void data_wait(int fd) + + void print_host(const char *a, const char *b, int both) + { +- int plen = 0; +- printf("%s", a); +- plen = strlen(a); +- if (both) { +- printf(" (%s)", b); +- plen += strlen(b) + 3; +- } ++ int plen; ++ plen = printf("%s", a); ++ if (both) ++ plen += printf(" (%s)", b); + if (plen >= HOST_COLUMN_SIZE) + plen = HOST_COLUMN_SIZE - 1; + printf("%*s", HOST_COLUMN_SIZE - plen, ""); +-- +1.8.0.2 + diff --git a/iputils/patches/net-misc_iputils_files_iputils-20121221-remove-rdisc-glibc-assumption.patch b/iputils/patches/net-misc_iputils_files_iputils-20121221-remove-rdisc-glibc-assumption.patch @@ -0,0 +1,30 @@ +diff -Naur iputils-s20121221.orig/rdisc.c iputils-s20121221/rdisc.c +--- iputils-s20121221.orig/rdisc.c 2014-01-24 14:59:29.937822762 +0000 ++++ iputils-s20121221/rdisc.c 2014-01-23 21:25:58.760288234 +0000 +@@ -115,26 +114,7 @@ + + #define MAXIFS 32 + +-#if !defined(__GLIBC__) || __GLIBC__ < 2 +-/* For router advertisement */ +-struct icmp_ra +-{ +- u_char icmp_type; /* type of message, see below */ +- u_char icmp_code; /* type sub code */ +- u_short icmp_cksum; /* ones complement cksum of struct */ +- u_char icmp_num_addrs; +- u_char icmp_wpa; /* Words per address */ +- short icmp_lifetime; +-}; +- +-struct icmp_ra_addr +-{ +- __u32 ira_addr; +- __u32 ira_preference; +-}; +-#else + #define icmp_ra icmp +-#endif + + /* Router constants */ + #define MAX_INITIAL_ADVERT_INTERVAL 16 diff --git a/iputils/patches/time.patch b/iputils/patches/time.patch @@ -0,0 +1,10 @@ +--- ./tracepath.c.orig ++++ ./tracepath.c +@@ -12,6 +12,7 @@ + #include <stdio.h> + #include <stdlib.h> + #include <unistd.h> ++#include <time.h> + #include <sys/socket.h> + #include <linux/types.h> + #include <linux/errqueue.h>