diff --git a/srcpkgs/iputils/INSTALL b/srcpkgs/iputils/INSTALL new file mode 100644 index 0000000000..712c4f4f4b --- /dev/null +++ b/srcpkgs/iputils/INSTALL @@ -0,0 +1,6 @@ +case "${ACTION}" in +post) + setcap CAP_NET_RAW+ep usr/bin/iputils-ping + setcap CAP_NET_RAW+ep usr/bin/iputils-ping6 + ;; +esac diff --git a/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20121221-crypto-build.patch b/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20121221-crypto-build.patch deleted file mode 100644 index 1ec3c101d5..0000000000 --- a/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20121221-crypto-build.patch +++ /dev/null @@ -1,35 +0,0 @@ -From 568e990d30fc7e9416e0a6f8c74ea5013921eaec Mon Sep 17 00:00:00 2001 -From: Arjan van de Ven -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 -Signed-off-by: YOSHIFUJI Hideaki ---- - 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/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20121221-printf-size.patch b/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20121221-printf-size.patch deleted file mode 100644 index 6d6c3b7d25..0000000000 --- a/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20121221-printf-size.patch +++ /dev/null @@ -1,64 +0,0 @@ -From 23fcb10ae15a96aa9e5a823cfe0b612d9522691c Mon Sep 17 00:00:00 2001 -From: Mike Frysinger -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 ---- - 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/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20131208-remove-working_recverr-checks.patch b/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20131208-remove-working_recverr-checks.patch deleted file mode 100644 index fd2ccfde72..0000000000 --- a/srcpkgs/iputils/patches/net-misc_iputils_files_iputils-20131208-remove-working_recverr-checks.patch +++ /dev/null @@ -1,42 +0,0 @@ -diff -Naur iputils-s20121221.orig/ping.c iputils-s20121221/ping.c ---- iputils-s20121221.orig/ping.c 2013-12-08 13:41:47.077791445 -0800 -+++ iputils-s20121221/ping.c 2013-12-08 13:43:25.238278205 -0800 -@@ -654,17 +654,6 @@ - - acknowledge(ntohs(icmph.un.echo.sequence)); - -- if (!working_recverr) { -- struct icmp_filter filt; -- working_recverr = 1; -- /* OK, it works. Add stronger filter. */ -- filt.data = ~((1<type != ICMP_SOURCE_QUENCH); - if (error_pkt) { - acknowledge(ntohs(icp1->un.echo.sequence)); -- if (working_recverr) { -- return 0; -- } else { -- static int once; -- /* Sigh, IP_RECVERR for raw socket -- * was broken until 2.4.9. So, we ignore -- * the first error and warn on the second. -- */ -- if (once++ == 1) -- fprintf(stderr, "\rWARNING: kernel is not very fresh, upgrade is recommended.\n"); -- if (once == 1) -- return 0; -- } -+ return 0; - } - nerrors+=error_pkt; - if (options&F_QUIET) diff --git a/srcpkgs/iputils/template b/srcpkgs/iputils/template index 12b81603e7..b20a9fa1fa 100644 --- a/srcpkgs/iputils/template +++ b/srcpkgs/iputils/template @@ -1,16 +1,17 @@ # Template file for 'iputils' pkgname=iputils -version=20121221 -revision=15 +version=20151218 +revision=1 patch_args="-Np1" wrksrc="${pkgname}-s${version}" makedepends="libressl-devel libcap-devel" +depends="libcap-progs" short_desc="IP Configuration Utilities (and ping)" maintainer="Juan RP " -license="BSD" +license="GPL-2, BSD" homepage="http://www.skbuff.net/iputils" distfiles="http://www.skbuff.net/iputils/${pkgname}-s${version}.tar.bz2" -checksum=450f549fc5b620c23c5929aa6d54b7ddfc7ee1cb1e8efdc5e8bb21d8d0c5319f +checksum=549f58d71951e52b46595829134d4e330642f522f50026917fadc349a54825a1 alternatives=" ping:ping:/usr/bin/${pkgname}-ping @@ -20,13 +21,13 @@ alternatives=" do_build() { make CC="$CC" LD="$LD" CCOPTOPT="$CFLAGS" LDFLAGS="$LDFLAGS" \ - USE_GNUTLS=no ${makejobs} \ + USE_GNUTLS=no USE_GCRYPT=no ${makejobs} \ arping clockdiff ping ping6 rdisc tracepath tracepath6 } do_install() { for f in ping ping6; do - vinstall ${f} 4755 usr/bin ${pkgname}-${f} + vbin ${f} ${pkgname}-${f} done for f in clockdiff arping rdisc tracepath tracepath6; do vbin ${f} diff --git a/srcpkgs/iputils/update b/srcpkgs/iputils/update new file mode 100644 index 0000000000..7b1c488b63 --- /dev/null +++ b/srcpkgs/iputils/update @@ -0,0 +1 @@ +pattern='iputils-s\K\d+'