All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6
@ 2019-08-12 17:37 unixmania at gmail.com
  2019-09-09  8:03 ` Thomas Petazzoni
  0 siblings, 1 reply; 8+ messages in thread
From: unixmania at gmail.com @ 2019-08-12 17:37 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <unixmania@gmail.com>

IPv6 requires libtirpc, so select BR2_PACKAGE_LIBTIRPC inconditionally.

Fixes: https://bugs.busybox.net/show_bug.cgi?id=10806

Signed-off-by: Carlos Santos <unixmania@gmail.com>
---
CC: nathan.renniewaldock at gmail.com
CC: Peter Seiderer <ps.report@gmx.net>
---
 package/nfs-utils/Config.in    |  2 +-
 package/nfs-utils/nfs-utils.mk | 11 ++---------
 2 files changed, 3 insertions(+), 10 deletions(-)

diff --git a/package/nfs-utils/Config.in b/package/nfs-utils/Config.in
index 04ea4db3ed..cfca034019 100644
--- a/package/nfs-utils/Config.in
+++ b/package/nfs-utils/Config.in
@@ -6,7 +6,7 @@ config BR2_PACKAGE_NFS_UTILS
 	bool "nfs-utils"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libtirpc, rpcbind
 	depends on BR2_USE_MMU # fork()
-	select BR2_PACKAGE_LIBTIRPC if !BR2_TOOLCHAIN_HAS_NATIVE_RPC
+	select BR2_PACKAGE_LIBTIRPC # IPv6 requires libtirpc
 	select BR2_PACKAGE_RPCBIND # runtime
 	help
 	  The NFS Linux kernel server.
diff --git a/package/nfs-utils/nfs-utils.mk b/package/nfs-utils/nfs-utils.mk
index dc20942f71..5e2525cdbf 100644
--- a/package/nfs-utils/nfs-utils.mk
+++ b/package/nfs-utils/nfs-utils.mk
@@ -10,7 +10,7 @@ NFS_UTILS_SITE = https://www.kernel.org/pub/linux/utils/nfs-utils/$(NFS_UTILS_VE
 NFS_UTILS_LICENSE = GPL-2.0+
 NFS_UTILS_LICENSE_FILES = COPYING
 NFS_UTILS_AUTORECONF = YES
-NFS_UTILS_DEPENDENCIES = host-pkgconf
+NFS_UTILS_DEPENDENCIES = host-pkgconf libtirpc
 
 NFS_UTILS_CONF_ENV = knfsd_cv_bsd_signals=no
 
@@ -19,7 +19,7 @@ NFS_UTILS_CONF_OPTS = \
 	--disable-nfsv41 \
 	--disable-gss \
 	--disable-uuid \
-	--disable-ipv6 \
+	--enable-tirpc \
 	--without-tcp-wrappers \
 	--with-statedir=/run/nfs \
 	--with-rpcgen=internal
@@ -51,13 +51,6 @@ else
 NFS_UTILS_CONF_OPTS += --disable-caps
 endif
 
-ifeq ($(BR2_PACKAGE_LIBTIRPC),y)
-NFS_UTILS_CONF_OPTS += --enable-tirpc
-NFS_UTILS_DEPENDENCIES += libtirpc
-else
-NFS_UTILS_CONF_OPTS += --disable-tirpc
-endif
-
 define NFS_UTILS_INSTALL_FIXUP
 	cd $(TARGET_DIR) && rm -f $(NFS_UTILS_TARGETS_)
 	touch $(TARGET_DIR)/etc/exports
-- 
2.18.1

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6
  2019-08-12 17:37 [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 unixmania at gmail.com
@ 2019-09-09  8:03 ` Thomas Petazzoni
  2019-09-09  9:16   ` Arnout Vandecappelle
  0 siblings, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2019-09-09  8:03 UTC (permalink / raw)
  To: buildroot

Hello,

Arnout, Peter added in Cc, see below.

On Mon, 12 Aug 2019 14:37:12 -0300
unixmania at gmail.com wrote:

> From: Carlos Santos <unixmania@gmail.com>
> 
> IPv6 requires libtirpc, so select BR2_PACKAGE_LIBTIRPC inconditionally.
> 
> Fixes: https://bugs.busybox.net/show_bug.cgi?id=10806
> 
> Signed-off-by: Carlos Santos <unixmania@gmail.com>

Arnout, Peter, do you have an opinion about this change ?

Basically, this change makes libtirpc mandatory for nfs-utils, because
it is necessary to have IPv6 RPC support.

However, libtirpc is always necessary if you want RPC on IPv6, so if we
take the decision of making libtirpc mandatory for nfs-utils, we should
make it mandatory for all packages that use RPC support, and remove the
support for RPC from the toolchain.

My opinion is that we should keep things are they are today: nfs-utils
uses libtirpc if it's there, and otherwise uses the toolchain RPC
support. If a user wants IPv6 support, he should enable libtirpc.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6
  2019-09-09  8:03 ` Thomas Petazzoni
@ 2019-09-09  9:16   ` Arnout Vandecappelle
  2019-09-09 23:56     ` [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 if libtirpc is selected unixmania at gmail.com
  0 siblings, 1 reply; 8+ messages in thread
From: Arnout Vandecappelle @ 2019-09-09  9:16 UTC (permalink / raw)
  To: buildroot



On 09/09/2019 10:03, Thomas Petazzoni wrote:
> Hello,
> 
> Arnout, Peter added in Cc, see below.
> 
> On Mon, 12 Aug 2019 14:37:12 -0300
> unixmania at gmail.com wrote:
> 
>> From: Carlos Santos <unixmania@gmail.com>
>>
>> IPv6 requires libtirpc, so select BR2_PACKAGE_LIBTIRPC inconditionally.
>>
>> Fixes: https://bugs.busybox.net/show_bug.cgi?id=10806
>>
>> Signed-off-by: Carlos Santos <unixmania@gmail.com>
> 
> Arnout, Peter, do you have an opinion about this change ?

 Yes I do :-)

 This thread was on my todo list of things I still had to reply to...


> Basically, this change makes libtirpc mandatory for nfs-utils, because
> it is necessary to have IPv6 RPC support.
> 
> However, libtirpc is always necessary if you want RPC on IPv6, so if we
> take the decision of making libtirpc mandatory for nfs-utils, we should
> make it mandatory for all packages that use RPC support, and remove the
> support for RPC from the toolchain.
> 
> My opinion is that we should keep things are they are today: nfs-utils
> uses libtirpc if it's there, and otherwise uses the toolchain RPC
> support. If a user wants IPv6 support, he should enable libtirpc.

 I agree with this analysis.

 When we switched to "assume IPv6 support is there", this was about the
toolchain, i.e. we can assume that the libc functions and the kernel have IPv6
support when building packages. It doesn't mean that we will force all packages
to be built with IPv6 support. That is still a case-by-case decision based on
what the size impact is.

 nfs-utils is not that large, but still: with br-arm-full (note that this
toolchain doesn't have native RPC, so libtirpc is built anyway; but native RPC
in uClibc doesn't add much to the size anyway):

toolchain (excluding libstdc++): 763KiB
nfs-utils: 395KiB
libtirpc: 104KiB
rpcbind: 55KiB

 So I would say that 104/395KiB is borderline of what we want to keep
configurable, but just on the side of keeping it configurable.

 In other words, I agree with your analysis that it's better to keep libtirpc
optional.


 Regards,
 Arnout

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 if libtirpc is selected
  2019-09-09  9:16   ` Arnout Vandecappelle
@ 2019-09-09 23:56     ` unixmania at gmail.com
  2019-09-10  7:06       ` Arnout Vandecappelle
  0 siblings, 1 reply; 8+ messages in thread
From: unixmania at gmail.com @ 2019-09-09 23:56 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <unixmania@gmail.com>

IPv6 requires libtirpc but we don't want to select BR2_PACKAGE_LIBTIRPC
inconditionally because it increases the size of system so enable IPv6
only if libtirpc is already selected.

Fixes: https://bugs.busybox.net/show_bug.cgi?id=10806

Signed-off-by: Carlos Santos <unixmania@gmail.com>
---
CC: nathan.renniewaldock at gmail.com
CC: Peter Seiderer <ps.report@gmx.net>
CC: Arnout Vandecappelle <arnout@mind.be>
CC: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
--
Changes v1->v2
- Do not select libtirpc inconditionally
---
 package/nfs-utils/nfs-utils.mk | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/package/nfs-utils/nfs-utils.mk b/package/nfs-utils/nfs-utils.mk
index dc20942f71..3d5f5412cf 100644
--- a/package/nfs-utils/nfs-utils.mk
+++ b/package/nfs-utils/nfs-utils.mk
@@ -19,7 +19,6 @@ NFS_UTILS_CONF_OPTS = \
 	--disable-nfsv41 \
 	--disable-gss \
 	--disable-uuid \
-	--disable-ipv6 \
 	--without-tcp-wrappers \
 	--with-statedir=/run/nfs \
 	--with-rpcgen=internal
@@ -51,11 +50,12 @@ else
 NFS_UTILS_CONF_OPTS += --disable-caps
 endif
 
+# IPv6 requires libtirpc
 ifeq ($(BR2_PACKAGE_LIBTIRPC),y)
-NFS_UTILS_CONF_OPTS += --enable-tirpc
+NFS_UTILS_CONF_OPTS += --enable-tirpc --enable-ipv6
 NFS_UTILS_DEPENDENCIES += libtirpc
 else
-NFS_UTILS_CONF_OPTS += --disable-tirpc
+NFS_UTILS_CONF_OPTS += --disable-tirpc --disable-ipv6
 endif
 
 define NFS_UTILS_INSTALL_FIXUP
-- 
2.18.1

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 if libtirpc is selected
  2019-09-09 23:56     ` [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 if libtirpc is selected unixmania at gmail.com
@ 2019-09-10  7:06       ` Arnout Vandecappelle
  2019-09-10 10:29         ` Carlos Santos
  0 siblings, 1 reply; 8+ messages in thread
From: Arnout Vandecappelle @ 2019-09-10  7:06 UTC (permalink / raw)
  To: buildroot



On 10/09/2019 01:56, unixmania at gmail.com wrote:
> From: Carlos Santos <unixmania@gmail.com>
> 
> IPv6 requires libtirpc but we don't want to select BR2_PACKAGE_LIBTIRPC
> inconditionally because it increases the size of system so enable IPv6

 unconditionally

> only if libtirpc is already selected.
> 
> Fixes: https://bugs.busybox.net/show_bug.cgi?id=10806
> 
> Signed-off-by: Carlos Santos <unixmania@gmail.com>
> ---
> CC: nathan.renniewaldock at gmail.com
> CC: Peter Seiderer <ps.report@gmx.net>
> CC: Arnout Vandecappelle <arnout@mind.be>
> CC: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> --
> Changes v1->v2

 This is v3, actually... v1 did the same as here (but without the
--enable-ipv6), v2 selected LIBTIRPC unconditionally.

> - Do not select libtirpc inconditionally
> ---
>  package/nfs-utils/nfs-utils.mk | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/package/nfs-utils/nfs-utils.mk b/package/nfs-utils/nfs-utils.mk
> index dc20942f71..3d5f5412cf 100644
> --- a/package/nfs-utils/nfs-utils.mk
> +++ b/package/nfs-utils/nfs-utils.mk
> @@ -19,7 +19,6 @@ NFS_UTILS_CONF_OPTS = \
>  	--disable-nfsv41 \
>  	--disable-gss \
>  	--disable-uuid \
> -	--disable-ipv6 \
>  	--without-tcp-wrappers \
>  	--with-statedir=/run/nfs \
>  	--with-rpcgen=internal
> @@ -51,11 +50,12 @@ else
>  NFS_UTILS_CONF_OPTS += --disable-caps
>  endif
>  
> +# IPv6 requires libtirpc

 Just to be sure: IPv6 really requires libtirpc, so the RPC implementation in
glibc is not enough?

 Assuming that this is the case:

Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>


 Finally, a small nitpick remark: it would be good to update the Config.in help
text with this information. E.g.:

 	  The NFS Linux kernel server.
+
+	  For IPv6 support, select the libtirpc package.


 Regards,
 Arnout

>  ifeq ($(BR2_PACKAGE_LIBTIRPC),y)
> -NFS_UTILS_CONF_OPTS += --enable-tirpc
> +NFS_UTILS_CONF_OPTS += --enable-tirpc --enable-ipv6
>  NFS_UTILS_DEPENDENCIES += libtirpc
>  else
> -NFS_UTILS_CONF_OPTS += --disable-tirpc
> +NFS_UTILS_CONF_OPTS += --disable-tirpc --disable-ipv6
>  endif
>  
>  define NFS_UTILS_INSTALL_FIXUP
> 

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 if libtirpc is selected
  2019-09-10  7:06       ` Arnout Vandecappelle
@ 2019-09-10 10:29         ` Carlos Santos
  2019-09-10 10:55           ` Thomas Petazzoni
  0 siblings, 1 reply; 8+ messages in thread
From: Carlos Santos @ 2019-09-10 10:29 UTC (permalink / raw)
  To: buildroot

On Tue, Sep 10, 2019 at 4:06 AM Arnout Vandecappelle <arnout@mind.be> wrote:
>
>
>
> On 10/09/2019 01:56, unixmania at gmail.com wrote:
> > From: Carlos Santos <unixmania@gmail.com>
> >
> > IPv6 requires libtirpc but we don't want to select BR2_PACKAGE_LIBTIRPC
> > inconditionally because it increases the size of system so enable IPv6
>
>  unconditionally
>
> > only if libtirpc is already selected.
> >
> > Fixes: https://bugs.busybox.net/show_bug.cgi?id=10806
> >
> > Signed-off-by: Carlos Santos <unixmania@gmail.com>
> > ---
> > CC: nathan.renniewaldock at gmail.com
> > CC: Peter Seiderer <ps.report@gmx.net>
> > CC: Arnout Vandecappelle <arnout@mind.be>
> > CC: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> > --
> > Changes v1->v2
>
>  This is v3, actually... v1 did the same as here (but without the
> --enable-ipv6), v2 selected LIBTIRPC unconditionally.
>
> > - Do not select libtirpc inconditionally
> > ---
> >  package/nfs-utils/nfs-utils.mk | 6 +++---
> >  1 file changed, 3 insertions(+), 3 deletions(-)
> >
> > diff --git a/package/nfs-utils/nfs-utils.mk b/package/nfs-utils/nfs-utils.mk
> > index dc20942f71..3d5f5412cf 100644
> > --- a/package/nfs-utils/nfs-utils.mk
> > +++ b/package/nfs-utils/nfs-utils.mk
> > @@ -19,7 +19,6 @@ NFS_UTILS_CONF_OPTS = \
> >       --disable-nfsv41 \
> >       --disable-gss \
> >       --disable-uuid \
> > -     --disable-ipv6 \
> >       --without-tcp-wrappers \
> >       --with-statedir=/run/nfs \
> >       --with-rpcgen=internal
> > @@ -51,11 +50,12 @@ else
> >  NFS_UTILS_CONF_OPTS += --disable-caps
> >  endif
> >
> > +# IPv6 requires libtirpc
>
>  Just to be sure: IPv6 really requires libtirpc, so the RPC implementation in
> glibc is not enough?
>
>  Assuming that this is the case:
>
> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
>
>
>  Finally, a small nitpick remark: it would be good to update the Config.in help
> text with this information. E.g.:
>
>           The NFS Linux kernel server.
> +
> +         For IPv6 support, select the libtirpc package.
>
>
>  Regards,
>  Arnout
>
> >  ifeq ($(BR2_PACKAGE_LIBTIRPC),y)
> > -NFS_UTILS_CONF_OPTS += --enable-tirpc
> > +NFS_UTILS_CONF_OPTS += --enable-tirpc --enable-ipv6
> >  NFS_UTILS_DEPENDENCIES += libtirpc
> >  else
> > -NFS_UTILS_CONF_OPTS += --disable-tirpc
> > +NFS_UTILS_CONF_OPTS += --disable-tirpc --disable-ipv6
> >  endif
> >
> >  define NFS_UTILS_INSTALL_FIXUP
> >

2019-09-10T07:22:05 configure: error: '--enable-ipv6' requires TIRPC support.

Quite frankly this is a foolish discussion since nfs-utils selects
rpcbind which in its turn selects libtirpc. Anyway, your project, your
rules...

-- 
Carlos Santos <unixmania@gmail.com>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 if libtirpc is selected
  2019-09-10 10:29         ` Carlos Santos
@ 2019-09-10 10:55           ` Thomas Petazzoni
  2019-09-10 11:03             ` Carlos Santos
  0 siblings, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2019-09-10 10:55 UTC (permalink / raw)
  To: buildroot

On Tue, 10 Sep 2019 07:29:39 -0300
Carlos Santos <unixmania@gmail.com> wrote:

> > >  ifeq ($(BR2_PACKAGE_LIBTIRPC),y)
> > > -NFS_UTILS_CONF_OPTS += --enable-tirpc
> > > +NFS_UTILS_CONF_OPTS += --enable-tirpc --enable-ipv6
> > >  NFS_UTILS_DEPENDENCIES += libtirpc
> > >  else
> > > -NFS_UTILS_CONF_OPTS += --disable-tirpc
> > > +NFS_UTILS_CONF_OPTS += --disable-tirpc --disable-ipv6
> > >  endif
> > >
> > >  define NFS_UTILS_INSTALL_FIXUP
> > >  
> 
> 2019-09-10T07:22:05 configure: error: '--enable-ipv6' requires TIRPC support.

How come this happens ? We only pass --enable-ipv6 when TIRPC is
available.

> Quite frankly this is a foolish discussion since nfs-utils selects
> rpcbind which in its turn selects libtirpc. Anyway, your project, your
> rules...

Ah, but I didn't realize that and you never mentioned it so far I
believe. Indeed, it even makes the current libtirpc condition in
nfs-utils.mk completely useless.

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 if libtirpc is selected
  2019-09-10 10:55           ` Thomas Petazzoni
@ 2019-09-10 11:03             ` Carlos Santos
  0 siblings, 0 replies; 8+ messages in thread
From: Carlos Santos @ 2019-09-10 11:03 UTC (permalink / raw)
  To: buildroot

On Tue, Sep 10, 2019 at 7:55 AM Thomas Petazzoni
<thomas.petazzoni@bootlin.com> wrote:
>
> On Tue, 10 Sep 2019 07:29:39 -0300
> Carlos Santos <unixmania@gmail.com> wrote:
>
> > > >  ifeq ($(BR2_PACKAGE_LIBTIRPC),y)
> > > > -NFS_UTILS_CONF_OPTS += --enable-tirpc
> > > > +NFS_UTILS_CONF_OPTS += --enable-tirpc --enable-ipv6
> > > >  NFS_UTILS_DEPENDENCIES += libtirpc
> > > >  else
> > > > -NFS_UTILS_CONF_OPTS += --disable-tirpc
> > > > +NFS_UTILS_CONF_OPTS += --disable-tirpc --disable-ipv6
> > > >  endif
> > > >
> > > >  define NFS_UTILS_INSTALL_FIXUP
> > > >
> >
> > 2019-09-10T07:22:05 configure: error: '--enable-ipv6' requires TIRPC support.
>
> How come this happens ? We only pass --enable-ipv6 when TIRPC is
> available.

I forced it to happen, just to provide the example. :-)

-- 
Carlos Santos <unixmania@gmail.com>

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2019-09-10 11:03 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-12 17:37 [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 unixmania at gmail.com
2019-09-09  8:03 ` Thomas Petazzoni
2019-09-09  9:16   ` Arnout Vandecappelle
2019-09-09 23:56     ` [Buildroot] [PATCH v2] package/nfs-utils: enable IPv6 if libtirpc is selected unixmania at gmail.com
2019-09-10  7:06       ` Arnout Vandecappelle
2019-09-10 10:29         ` Carlos Santos
2019-09-10 10:55           ` Thomas Petazzoni
2019-09-10 11:03             ` Carlos Santos

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.