diff mbox

[1/1] iputils: resolve musl compatibility

Message ID 1453089044-10391-1-git-send-email-matt@thewebers.ws
State Changes Requested
Headers show

Commit Message

Matt Weber Jan. 18, 2016, 3:50 a.m. UTC
The new upstream and version bump resolves a series of musl build failures
noted in the autobuilder log.

http://autobuild.buildroot.net/results/12cb73f3def95efe706bcd957bc2c091e7931d5a/

Signed-off-by: Matt Weber <matt@thewebers.ws>
---
v1
  - Updated to github upstream, selected merge from Nov 3 2015
    which provided musl fixes (last release was to old, 20150815)
  - Added missing dependencies for kernel capabilies lib
  - Accounted for new consolidated ping (ipv4/6)

Tested against a buildroot arm musl/glibc toolchains, as well as
autobuilder defconfig.

Signed-off-by: Matt Weber <matt@thewebers.ws>
---
 .../0001-ping-ping6-Fix-hang-with-f-option.patch   | 34 ----------------------
 package/iputils/Config.in                          |  3 +-
 package/iputils/iputils.hash                       |  2 ++
 package/iputils/iputils.mk                         | 16 ++++------
 4 files changed, 10 insertions(+), 45 deletions(-)
 delete mode 100644 package/iputils/0001-ping-ping6-Fix-hang-with-f-option.patch

Comments

Thomas Petazzoni Jan. 18, 2016, 12:50 p.m. UTC | #1
Dear Matt Weber,

On Mon, 18 Jan 2016 03:50:44 +0000, Matt Weber wrote:
> The new upstream and version bump resolves a series of musl build failures
> noted in the autobuilder log.
> 
> http://autobuild.buildroot.net/results/12cb73f3def95efe706bcd957bc2c091e7931d5a/
> 
> Signed-off-by: Matt Weber <matt@thewebers.ws>
> ---
> v1
>   - Updated to github upstream, selected merge from Nov 3 2015
>     which provided musl fixes (last release was to old, 20150815)
>   - Added missing dependencies for kernel capabilies lib
>   - Accounted for new consolidated ping (ipv4/6)

Why aren't those comments part of the commit log? They detail the patch
itself, not changes between versions of the patch.

> Tested against a buildroot arm musl/glibc toolchains, as well as
> autobuilder defconfig.

Ditto.

> diff --git a/package/iputils/Config.in b/package/iputils/Config.in
> index 5324639..61681e4 100644
> --- a/package/iputils/Config.in
> +++ b/package/iputils/Config.in
> @@ -1,9 +1,10 @@
>  config BR2_PACKAGE_IPUTILS
>  	bool "iputils"
>  	select BR2_PACKAGE_OPENSSL
> +	select BR2_PACKAGE_LIBCAP

So you need to duplicate the dependencies of libcap in iputils
Config.in file.

Thanks,

Thomas
Thomas Petazzoni Jan. 19, 2016, 9:13 p.m. UTC | #2
Matt,

Some more comments (see below).

On Mon, 18 Jan 2016 03:50:44 +0000, Matt Weber wrote:

> diff --git a/package/iputils/iputils.hash b/package/iputils/iputils.hash
> index 21a2044..fcca52c 100644
> --- a/package/iputils/iputils.hash
> +++ b/package/iputils/iputils.hash
> @@ -1,2 +1,4 @@
> +# Locally computed
> +sha256	0e98cb527fa175d1e08afb969c124e452b30968f10ec2c3b078f1440c8977a94	iputils-c8ff6feaf0442f8efd96ccb415770c54f9e84d47.tar.gz
>  # From http://sourceforge.net/projects/iputils/files/
>  sha1	3e85179746fd93000d6267bd55addfe97f321ba7	iputils-s20121011.tar.bz2

Why are you keeping the hash for the old tarball ?

> diff --git a/package/iputils/iputils.mk b/package/iputils/iputils.mk
> index 7510d99..d427b11 100644
> --- a/package/iputils/iputils.mk
> +++ b/package/iputils/iputils.mk
> @@ -4,13 +4,12 @@
>  #
>  ################################################################################
>  
> -IPUTILS_VERSION = s20121011
> -IPUTILS_SITE = http://www.skbuff.net/iputils
> -IPUTILS_SOURCE = iputils-$(IPUTILS_VERSION).tar.bz2
> -IPUTILS_LICENSE = GPLv2+, BSD-3c
> +IPUTILS_VERSION = c8ff6feaf0442f8efd96ccb415770c54f9e84d47
> +IPUTILS_SITE = $(call github,iputils,iputils,$(IPUTILS_VERSION))

I don't understand why you are moving to github.
http://www.skbuff.net/iputils has some recent tarballs, which
correspond to the releases made on github.
http://www.skbuff.net/iputils/iputils-s20151218.tar.bz2 will most
likely contain the musl fixes.

I'll mark your patch as Changes Requested in patchwork. Can you respin
after fixing the issues raised during the review?

Thanks a lot!

Thomas
Matt Weber Jan. 20, 2016, 3:04 a.m. UTC | #3
Thomas,

On Tue, Jan 19, 2016 at 3:13 PM, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> Matt,
>
> Some more comments (see below).
>
> On Mon, 18 Jan 2016 03:50:44 +0000, Matt Weber wrote:
>
>> diff --git a/package/iputils/iputils.hash b/package/iputils/iputils.hash
>> index 21a2044..fcca52c 100644
>> --- a/package/iputils/iputils.hash
>> +++ b/package/iputils/iputils.hash
>> @@ -1,2 +1,4 @@
>> +# Locally computed
>> +sha256       0e98cb527fa175d1e08afb969c124e452b30968f10ec2c3b078f1440c8977a94        iputils-c8ff6feaf0442f8efd96ccb415770c54f9e84d47.tar.gz
>>  # From http://sourceforge.net/projects/iputils/files/
>>  sha1 3e85179746fd93000d6267bd55addfe97f321ba7        iputils-s20121011.tar.bz2
>
> Why are you keeping the hash for the old tarball ?

No reason, will remove.

>
>> diff --git a/package/iputils/iputils.mk b/package/iputils/iputils.mk
>> index 7510d99..d427b11 100644
>> --- a/package/iputils/iputils.mk
>> +++ b/package/iputils/iputils.mk
>> @@ -4,13 +4,12 @@
>>  #
>>  ################################################################################
>>
>> -IPUTILS_VERSION = s20121011
>> -IPUTILS_SITE = http://www.skbuff.net/iputils
>> -IPUTILS_SOURCE = iputils-$(IPUTILS_VERSION).tar.bz2
>> -IPUTILS_LICENSE = GPLv2+, BSD-3c
>> +IPUTILS_VERSION = c8ff6feaf0442f8efd96ccb415770c54f9e84d47
>> +IPUTILS_SITE = $(call github,iputils,iputils,$(IPUTILS_VERSION))
>
> I don't understand why you are moving to github.
> http://www.skbuff.net/iputils has some recent tarballs, which
> correspond to the releases made on github.
> http://www.skbuff.net/iputils/iputils-s20151218.tar.bz2 will most
> likely contain the musl fixes.

The releases don't match.  The github repository was forked in 2014 to
pull fixes from other distrobutions and centralize the changes after
the upstream seemed to have gone dormant.  So the fork is the only
repo that has the musl and other IPv6 updates.  I should have
referenced the email link.
http://www.spinics.net/lists/netdev/msg279881.html
Thoughts?

>
> I'll mark your patch as Changes Requested in patchwork. Can you respin
> after fixing the issues raised during the review?

Will do.
Thomas Petazzoni Jan. 20, 2016, 8:44 a.m. UTC | #4
Matt,

On Tue, 19 Jan 2016 21:04:23 -0600, Matthew Weber wrote:

> >> diff --git a/package/iputils/iputils.mk b/package/iputils/iputils.mk
> >> index 7510d99..d427b11 100644
> >> --- a/package/iputils/iputils.mk
> >> +++ b/package/iputils/iputils.mk
> >> @@ -4,13 +4,12 @@
> >>  #
> >>  ################################################################################
> >>
> >> -IPUTILS_VERSION = s20121011
> >> -IPUTILS_SITE = http://www.skbuff.net/iputils
> >> -IPUTILS_SOURCE = iputils-$(IPUTILS_VERSION).tar.bz2
> >> -IPUTILS_LICENSE = GPLv2+, BSD-3c
> >> +IPUTILS_VERSION = c8ff6feaf0442f8efd96ccb415770c54f9e84d47
> >> +IPUTILS_SITE = $(call github,iputils,iputils,$(IPUTILS_VERSION))
> >
> > I don't understand why you are moving to github.
> > http://www.skbuff.net/iputils has some recent tarballs, which
> > correspond to the releases made on github.
> > http://www.skbuff.net/iputils/iputils-s20151218.tar.bz2 will most
> > likely contain the musl fixes.
> 
> The releases don't match.  The github repository was forked in 2014 to
> pull fixes from other distrobutions and centralize the changes after
> the upstream seemed to have gone dormant.  So the fork is the only
> repo that has the musl and other IPv6 updates.  I should have
> referenced the email link.
> http://www.spinics.net/lists/netdev/msg279881.html
> Thoughts?

OK, understood. Can you just put this in a comment in the .mk file?

Thanks,

Thomas
Matt Weber Jan. 20, 2016, 12:21 p.m. UTC | #5
Thomas,

On Wed, Jan 20, 2016 at 2:44 AM, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> Matt,
>
> On Tue, 19 Jan 2016 21:04:23 -0600, Matthew Weber wrote:
>
>> >> diff --git a/package/iputils/iputils.mk b/package/iputils/iputils.mk
>> >> index 7510d99..d427b11 100644
>> >> --- a/package/iputils/iputils.mk
>> >> +++ b/package/iputils/iputils.mk
>> >> @@ -4,13 +4,12 @@
>> >>  #
>> >>  ################################################################################
>> >>
>> >> -IPUTILS_VERSION = s20121011
>> >> -IPUTILS_SITE = http://www.skbuff.net/iputils
>> >> -IPUTILS_SOURCE = iputils-$(IPUTILS_VERSION).tar.bz2
>> >> -IPUTILS_LICENSE = GPLv2+, BSD-3c
>> >> +IPUTILS_VERSION = c8ff6feaf0442f8efd96ccb415770c54f9e84d47
>> >> +IPUTILS_SITE = $(call github,iputils,iputils,$(IPUTILS_VERSION))
>> >
>> > I don't understand why you are moving to github.
>> > http://www.skbuff.net/iputils has some recent tarballs, which
>> > correspond to the releases made on github.
>> > http://www.skbuff.net/iputils/iputils-s20151218.tar.bz2 will most
>> > likely contain the musl fixes.
>>
>> The releases don't match.  The github repository was forked in 2014 to
>> pull fixes from other distrobutions and centralize the changes after
>> the upstream seemed to have gone dormant.  So the fork is the only
>> repo that has the musl and other IPv6 updates.  I should have
>> referenced the email link.
>> http://www.spinics.net/lists/netdev/msg279881.html
>> Thoughts?
>
> OK, understood. Can you just put this in a comment in the .mk file?
>

Done, all changes in v3.
diff mbox

Patch

diff --git a/package/iputils/0001-ping-ping6-Fix-hang-with-f-option.patch b/package/iputils/0001-ping-ping6-Fix-hang-with-f-option.patch
deleted file mode 100644
index fe1ab77..0000000
--- a/package/iputils/0001-ping-ping6-Fix-hang-with-f-option.patch
+++ /dev/null
@@ -1,34 +0,0 @@ 
-From 712fddacfb5c4a8a48d9c5debe1870bc051d836c Mon Sep 17 00:00:00 2001
-From: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
-Date: Tue, 6 Nov 2012 02:44:12 +0900
-Subject: [PATCH] ping,ping6: Fix hang with -f option.
-
-Bug was introduced by commit 8feb586c4... (ping,ping6: Check return
-value of write(2) for stdout.).
-
-https://bugs.archlinux.org/task/32306
-
-Patch-by: Jan Synacek <jsynacek@redhat.com>
-Reported-by: Mohammad Alsaleh <msal@tormail.org>
-Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
-Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
----
- ping_common.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/ping_common.h b/ping_common.h
-index d2a2b5c..6726e1b 100644
---- a/ping_common.h
-+++ b/ping_common.h
-@@ -140,7 +140,7 @@ static inline void write_stdout(const char *str, size_t len)
- 	do {
- 		cc = write(STDOUT_FILENO, str + o, len - o);
- 		o += cc;
--	} while (len >= o || cc < 0);
-+	} while (len > o || cc < 0);
- }
- 
- /*
--- 
-2.1.3
-
diff --git a/package/iputils/Config.in b/package/iputils/Config.in
index 5324639..61681e4 100644
--- a/package/iputils/Config.in
+++ b/package/iputils/Config.in
@@ -1,9 +1,10 @@ 
 config BR2_PACKAGE_IPUTILS
 	bool "iputils"
 	select BR2_PACKAGE_OPENSSL
+	select BR2_PACKAGE_LIBCAP
 	depends on BR2_USE_MMU # fork()
 	help
 	  This package is set of small useful utilities for Linux networking.
 	  It includes complete versions of ping, traceroute, etc.
 
-	  http://sourceforge.net/projects/iputils/
+	  https://github.com/iputils/iputils
diff --git a/package/iputils/iputils.hash b/package/iputils/iputils.hash
index 21a2044..fcca52c 100644
--- a/package/iputils/iputils.hash
+++ b/package/iputils/iputils.hash
@@ -1,2 +1,4 @@ 
+# Locally computed
+sha256	0e98cb527fa175d1e08afb969c124e452b30968f10ec2c3b078f1440c8977a94	iputils-c8ff6feaf0442f8efd96ccb415770c54f9e84d47.tar.gz
 # From http://sourceforge.net/projects/iputils/files/
 sha1	3e85179746fd93000d6267bd55addfe97f321ba7	iputils-s20121011.tar.bz2
diff --git a/package/iputils/iputils.mk b/package/iputils/iputils.mk
index 7510d99..d427b11 100644
--- a/package/iputils/iputils.mk
+++ b/package/iputils/iputils.mk
@@ -4,13 +4,12 @@ 
 #
 ################################################################################
 
-IPUTILS_VERSION = s20121011
-IPUTILS_SITE = http://www.skbuff.net/iputils
-IPUTILS_SOURCE = iputils-$(IPUTILS_VERSION).tar.bz2
-IPUTILS_LICENSE = GPLv2+, BSD-3c
+IPUTILS_VERSION = c8ff6feaf0442f8efd96ccb415770c54f9e84d47
+IPUTILS_SITE = $(call github,iputils,iputils,$(IPUTILS_VERSION))
+IPUTILS_LICENSE = GPLv2+, BSD-3c, BSD-4c
 # Only includes a license file for BSD
 IPUTILS_LICENSE_FILES = ninfod/COPYING
-IPUTILS_DEPENDENCIES = openssl
+IPUTILS_DEPENDENCIES = openssl libcap
 
 # Build after busybox so target ends up with this package's full
 # versions of the applications instead of busybox applets.
@@ -19,10 +18,8 @@  IPUTILS_DEPENDENCIES += busybox
 endif
 
 # Disabling CAP_SETPCAP (file capabilities)
-IPUTILS_MAKE_OPTS = $(TARGET_CONFIGURE_OPTS) USE_CAP=no USE_SYSFS=no\
-	CFLAGS="$(TARGET_CFLAGS) -D_GNU_SOURCE" \
-	arping clockdiff ping rarpd rdisc tftpd tracepath \
-	ping6 tracepath6 traceroute6
+IPUTILS_MAKE_OPTS = $(TARGET_CONFIGURE_OPTS) USE_SYSFS=no USE_IDN=no\
+	CFLAGS="$(TARGET_CFLAGS) -D_GNU_SOURCE"
 
 define IPUTILS_BUILD_CMDS
 	$(MAKE) -C $(@D) $(IPUTILS_MAKE_OPTS)
@@ -36,7 +33,6 @@  define IPUTILS_INSTALL_TARGET_CMDS
 	$(INSTALL) -D -m 755 $(@D)/rdisc       $(TARGET_DIR)/sbin/rdisc
 	$(INSTALL) -D -m 755 $(@D)/tftpd       $(TARGET_DIR)/usr/sbin/in.tftpd
 	$(INSTALL) -D -m 755 $(@D)/tracepath   $(TARGET_DIR)/bin/tracepath
-	$(INSTALL) -D -m 755 $(@D)/ping6       $(TARGET_DIR)/bin/ping6
 	$(INSTALL) -D -m 755 $(@D)/tracepath6  $(TARGET_DIR)/bin/tracepath6
 	$(INSTALL) -D -m 755 $(@D)/traceroute6 $(TARGET_DIR)/bin/traceroute6
 endef