All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] package/libnfsidmap: new package
@ 2019-02-06 16:06 kostap at marvell.com
  2019-02-06 16:06 ` [Buildroot] [PATCH 2/2] package/nfs-utils: enable support of NFSv4 kostap at marvell.com
  2019-02-06 16:16 ` [Buildroot] [PATCH 1/2] package/libnfsidmap: new package Thomas Petazzoni
  0 siblings, 2 replies; 5+ messages in thread
From: kostap at marvell.com @ 2019-02-06 16:06 UTC (permalink / raw)
  To: buildroot

From: Konstantin Porotchkin <kostap@marvell.com>

Reqired for NFSv4 support.
Taken from git at github.com:openstack/manila-test-image.git
/patches/nfs-utils-enable-nfsv4.patch

Signed-off-by: Konstantin Porotchkin <kostap@marvell.com>
---
 package/Config.in                  |  1 +
 package/libnfsidmap/Config.in      |  7 +++++++
 package/libnfsidmap/libnfsidmap.mk | 13 +++++++++++++
 3 files changed, 21 insertions(+)
 create mode 100644 package/libnfsidmap/Config.in
 create mode 100644 package/libnfsidmap/libnfsidmap.mk

diff --git a/package/Config.in b/package/Config.in
index 28d3ef82a7..b7867299f6 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -1533,6 +1533,7 @@ menu "Networking"
 	source "package/libnetfilter_log/Config.in"
 	source "package/libnetfilter_queue/Config.in"
 	source "package/libnfnetlink/Config.in"
+	source "package/libnfsidmap/Config.in"
 	source "package/libnftnl/Config.in"
 	source "package/libnice/Config.in"
 	source "package/libnl/Config.in"
diff --git a/package/libnfsidmap/Config.in b/package/libnfsidmap/Config.in
new file mode 100644
index 0000000000..12dbf505a5
--- /dev/null
+++ b/package/libnfsidmap/Config.in
@@ -0,0 +1,7 @@
+config BR2_PACKAGE_LIBNFSIDMAP
+	bool "libnfsidmap"
+	help
+	  Library used by the NFSv4 server to do userid mapping.
+
+	  http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap
+
diff --git a/package/libnfsidmap/libnfsidmap.mk b/package/libnfsidmap/libnfsidmap.mk
new file mode 100644
index 0000000000..2c3bd812de
--- /dev/null
+++ b/package/libnfsidmap/libnfsidmap.mk
@@ -0,0 +1,13 @@
+#
+# libnfsidmap
+#
+
+LIBNFSIDMAP_VERSION = 0.25
+LIBNFSIDMAP_SITE = http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap
+LIBNFSIDMAP_SOURCE = libnfsidmap-$(LIBNFSIDMAP_VERSION).tar.gz
+LIBNFSIDMAP_INSTALL_STAGING = YES
+LIBNFSIDMAP_LICENSE = BSD-like
+LIBNFSIDMAP_LICENSE_FILES = COPYING
+
+$(eval $(autotools-package))
+$(eval $(host-autotools-package))
-- 
2.17.1

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

* [Buildroot] [PATCH 2/2] package/nfs-utils: enable support of NFSv4
  2019-02-06 16:06 [Buildroot] [PATCH 1/2] package/libnfsidmap: new package kostap at marvell.com
@ 2019-02-06 16:06 ` kostap at marvell.com
  2019-02-12 10:33   ` Thomas Petazzoni
  2019-02-06 16:16 ` [Buildroot] [PATCH 1/2] package/libnfsidmap: new package Thomas Petazzoni
  1 sibling, 1 reply; 5+ messages in thread
From: kostap at marvell.com @ 2019-02-06 16:06 UTC (permalink / raw)
  To: buildroot

From: Konstantin Porotchkin <kostap@marvell.com>

Taken from git at github.com:openstack/manila-test-image.git
/patches/nfs-utils-enable-nfsv4.patch

Signed-off-by: Konstantin Porotchkin <kostap@marvell.com>
---
 package/nfs-utils/Config.in       | 10 ++++++++++
 package/nfs-utils/S60nfs          | 27 +++++++++++++++++++++++----
 package/nfs-utils/etc-idmapd.conf |  9 +++++++++
 package/nfs-utils/nfs-utils.mk    | 19 ++++++++++++++++---
 4 files changed, 58 insertions(+), 7 deletions(-)
 create mode 100644 package/nfs-utils/etc-idmapd.conf

diff --git a/package/nfs-utils/Config.in b/package/nfs-utils/Config.in
index 055b711f0d..08c0f4caae 100644
--- a/package/nfs-utils/Config.in
+++ b/package/nfs-utils/Config.in
@@ -30,4 +30,14 @@ config BR2_PACKAGE_NFS_UTILS_RPC_RQUOTAD
 	help
 	  NFS remote quota server
 
+config BR2_PACKAGE_NFS_UTILS_NFS4
+	bool "NFSv4 support"
+	select BR2_PACKAGE_LIBEVENT
+	select BR2_PACKAGE_LIBNFSIDMAP
+	help
+	  Enable support for NFSv4.
+
+comment "nfs-utils requires a toolchain with RPC and LARGEFILE support"
+	depends on !BR2_INET_RPC || !BR2_LARGEFILE
+
 endif
diff --git a/package/nfs-utils/S60nfs b/package/nfs-utils/S60nfs
index 4183ff6268..bec7307653 100755
--- a/package/nfs-utils/S60nfs
+++ b/package/nfs-utils/S60nfs
@@ -3,6 +3,8 @@
 # nfs           This shell script takes care of starting and stopping
 #               the NFS services. Stolen from RedHat FC5.
 
+ENABLEv4=yes
+
 mkdir -p /var/lock/subsys
 mkdir -p /run/nfs/sm
 mkdir -p /run/nfs/sm.bak
@@ -15,13 +17,26 @@ if [ -f "${CFG_FILE}" ]; then
 	. "${CFG_FILE}"
 fi
 
+if [ $ENABLEv4 == "yes" ]; then
+	pipefs_dir="`sed -n 's/^ *Pipefs-Directory *= *//p' /etc/idmapd.conf`"
+fi
 
 start() {
 	# Start daemons.
+	if [ $ENABLEv4 == "yes" ]; then
+		printf "Starting NFS idmapd: "
+		[ -d /var/lib/nfs/v4recovery ] || mkdir -p /var/lib/nfs/v4recovery
+		[ -d "$pipefs_dir" ] || mkdir -p "$pipefs_dir"
+		if ! ( grep -q "on $pipefs_dir type rpc_pipefs" /proc/mounts ); then
+			mount -t rpc_pipefs sunrpc "$pipefs_dir"
+		fi
+		rpc.idmapd
+		echo "done"
+	fi
+
 	printf "Starting NFS statd: "
 	rpc.statd
 	[ $? = 0 ] && echo "OK" || echo "FAIL"
-	touch /var/lock/subsys/nfslock
 
 	printf "Starting NFS services: "
 	/usr/sbin/exportfs -r
@@ -34,11 +49,17 @@ start() {
 	printf "Starting NFS mountd: "
 	rpc.mountd
 	[ $? = 0 ] && echo "OK" || echo "FAIL"
-	touch /var/lock/subsys/nfs
 }
 
 stop() {
 	# Stop daemons.
+	if [ $ENABLEv4 == "yes" ]; then
+		printf "Shutting down NFS idmapd: "
+		killall -q rpc.idmapd
+		umount "$pipefs_dir"
+		echo "done"
+	fi
+
 	printf "Shutting down NFS mountd: "
 	killall -q rpc.mountd 2>/dev/null
 	[ $? = 0 ] && echo "OK" || echo "FAIL"
@@ -56,7 +77,6 @@ stop() {
 	[ $? = 0 ] && echo "OK" || echo "FAIL"
 	rm -f /var/lock/subsys/nfs
 	rm -f /var/run/rpc.statd.pid
-	rm -f /var/lock/subsys/nfslock
 }
 
 # See how we were called.
@@ -73,7 +93,6 @@ case "$1" in
 		;;
 	reload)
 		/usr/sbin/exportfs -r
-		touch /var/lock/subsys/nfs
 		;;
 	*)
 		echo "Usage: $0 {start|stop|restart|reload}"
diff --git a/package/nfs-utils/etc-idmapd.conf b/package/nfs-utils/etc-idmapd.conf
new file mode 100644
index 0000000000..0288c0ce03
--- /dev/null
+++ b/package/nfs-utils/etc-idmapd.conf
@@ -0,0 +1,9 @@
+[General]
+Verbosity = 0
+Pipefs-Directory = /var/lib/nfs/rpc_pipefs
+Domain = localdomain
+
+[Mapping]
+Nobody-User = nobody
+Nobody-Group = nogroup
+
diff --git a/package/nfs-utils/nfs-utils.mk b/package/nfs-utils/nfs-utils.mk
index 9fa7ae200b..517ec19bea 100644
--- a/package/nfs-utils/nfs-utils.mk
+++ b/package/nfs-utils/nfs-utils.mk
@@ -15,15 +15,19 @@ NFS_UTILS_DEPENDENCIES = host-pkgconf
 NFS_UTILS_CONF_ENV = knfsd_cv_bsd_signals=no
 
 NFS_UTILS_CONF_OPTS = \
-	--disable-nfsv4 \
-	--disable-nfsv41 \
 	--disable-gss \
 	--disable-uuid \
-	--disable-ipv6 \
 	--without-tcp-wrappers \
 	--with-statedir=/run/nfs \
 	--with-rpcgen=internal
 
+ifeq ($(BR2_PACKAGE_LIBNFSIDMAP),y)
+NFS_UTILS_DEPENDENCIES += libevent libnfsidmap lvm2 sqlite
+NFS_UTILS_CONF_OPTS += --enable-nfsv4 --enable-nfsv41
+else
+NFS_UTILS_CONF_OPTS += --disable-nfsv4 --disable-nfsv41
+endif
+
 HOST_NFS_UTILS_CONF_OPTS = \
 	--disable-nfsv4 \
 	--disable-nfsv41 \
@@ -62,7 +66,16 @@ define NFS_UTILS_INSTALL_FIXUP
 	$(INSTALL) -D -m 644 \
 		$(@D)/utils/mount/nfsmount.conf $(TARGET_DIR)/etc/nfsmount.conf
 endef
+
+define NFS_UTILS_INSTALL_IDMAPD_CONF
+	$(INSTALL) -m 0644 package/nfs-utils/etc-idmapd.conf \
+		$(TARGET_DIR)/etc/idmapd.conf
+endef
+
 NFS_UTILS_POST_INSTALL_TARGET_HOOKS += NFS_UTILS_INSTALL_FIXUP
+ifeq ($(BR2_PACKAGE_NFS_UTILS_NFS4),y)
+	NFS_UTILS_POST_INSTALL_TARGET_HOOKS += NFS_UTILS_INSTALL_IDMAPD_CONF
+endif
 
 ifeq ($(BR2_INIT_SYSTEMD),y)
 NFS_UTILS_CONF_OPTS += --with-systemd=/usr/lib/systemd/system
-- 
2.17.1

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

* [Buildroot] [PATCH 1/2] package/libnfsidmap: new package
  2019-02-06 16:06 [Buildroot] [PATCH 1/2] package/libnfsidmap: new package kostap at marvell.com
  2019-02-06 16:06 ` [Buildroot] [PATCH 2/2] package/nfs-utils: enable support of NFSv4 kostap at marvell.com
@ 2019-02-06 16:16 ` Thomas Petazzoni
  2019-02-06 16:29   ` [Buildroot] [EXT] " Kostya Porotchkin
  1 sibling, 1 reply; 5+ messages in thread
From: Thomas Petazzoni @ 2019-02-06 16:16 UTC (permalink / raw)
  To: buildroot

Hello Kostya,

On Wed, 6 Feb 2019 18:06:00 +0200
<kostap@marvell.com> wrote:

> From: Konstantin Porotchkin <kostap@marvell.com>
> 
> Reqired for NFSv4 support.

Required

> Taken from git at github.com:openstack/manila-test-image.git
> /patches/nfs-utils-enable-nfsv4.patch

What is taken from there ?

>  package/Config.in                  |  1 +
>  package/libnfsidmap/Config.in      |  7 +++++++
>  package/libnfsidmap/libnfsidmap.mk | 13 +++++++++++++
>  3 files changed, 21 insertions(+)

An entry to the DEVELOPERS file should be added, and a .hash file is
needed.


> diff --git a/package/libnfsidmap/Config.in b/package/libnfsidmap/Config.in
> new file mode 100644
> index 0000000000..12dbf505a5
> --- /dev/null
> +++ b/package/libnfsidmap/Config.in
> @@ -0,0 +1,7 @@
> +config BR2_PACKAGE_LIBNFSIDMAP
> +	bool "libnfsidmap"

No dependencies at all ? Did you test this package
with ./utils/test-pkg ?

> +	help
> +	  Library used by the NFSv4 server to do userid mapping.
> +
> +	  http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap
> +

Unneeded empty new line at the end of the file.

> diff --git a/package/libnfsidmap/libnfsidmap.mk b/package/libnfsidmap/libnfsidmap.mk
> new file mode 100644
> index 0000000000..2c3bd812de
> --- /dev/null
> +++ b/package/libnfsidmap/libnfsidmap.mk
> @@ -0,0 +1,13 @@
> +#
> +# libnfsidmap
> +#

Please use the standard header for packages.

> +
> +LIBNFSIDMAP_VERSION = 0.25
> +LIBNFSIDMAP_SITE = http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap
> +LIBNFSIDMAP_SOURCE = libnfsidmap-$(LIBNFSIDMAP_VERSION).tar.gz

Not needed, this is the default value. Have you run "make
check-package" ?

> +LIBNFSIDMAP_INSTALL_STAGING = YES
> +LIBNFSIDMAP_LICENSE = BSD-like

This is not a proper license, see https://spdx.org/licenses/ for a
proper list of SPDX license codes.

> +LIBNFSIDMAP_LICENSE_FILES = COPYING
> +
> +$(eval $(autotools-package))
> +$(eval $(host-autotools-package))

You're not using the host version of this package, so it shouldn't be
added.

Thanks!

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

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

* [Buildroot] [EXT] Re: [PATCH 1/2] package/libnfsidmap: new package
  2019-02-06 16:16 ` [Buildroot] [PATCH 1/2] package/libnfsidmap: new package Thomas Petazzoni
@ 2019-02-06 16:29   ` Kostya Porotchkin
  0 siblings, 0 replies; 5+ messages in thread
From: Kostya Porotchkin @ 2019-02-06 16:29 UTC (permalink / raw)
  To: buildroot

Hi, Thomas,

> -----Original Message-----
> From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> Sent: Wednesday, February 6, 2019 18:16
> To: Kostya Porotchkin <kostap@marvell.com>
> Cc: buildroot at buildroot.org
> Subject: [EXT] Re: [Buildroot] [PATCH 1/2] package/libnfsidmap: new
> package
> 
> External Email
> 
> ----------------------------------------------------------------------
> Hello Kostya,
> 
> On Wed, 6 Feb 2019 18:06:00 +0200
> <kostap@marvell.com> wrote:
> 
> > From: Konstantin Porotchkin <kostap@marvell.com>
> >
> > Reqired for NFSv4 support.
> 
> Required
> 
> > Taken from git at github.com:openstack/manila-test-image.git
> > /patches/nfs-utils-enable-nfsv4.patch
> 
> What is taken from there ?
[KP] Someone already made this package, but not submitted to the mainline
So I do not know the author, probably it was ported from 2011 patch series...
> 
> >  package/Config.in                  |  1 +
> >  package/libnfsidmap/Config.in      |  7 +++++++
> >  package/libnfsidmap/libnfsidmap.mk | 13 +++++++++++++
> >  3 files changed, 21 insertions(+)
> 
> An entry to the DEVELOPERS file should be added, and a .hash file is needed.
[KP] OK
> 
> 
> > diff --git a/package/libnfsidmap/Config.in
> > b/package/libnfsidmap/Config.in new file mode 100644 index
> > 0000000000..12dbf505a5
> > --- /dev/null
> > +++ b/package/libnfsidmap/Config.in
> > @@ -0,0 +1,7 @@
> > +config BR2_PACKAGE_LIBNFSIDMAP
> > +	bool "libnfsidmap"
> 
> No dependencies at all ? Did you test this package with ./utils/test-pkg ?
[KP] Not, sorry, will do it.
> 
> > +	help
> > +	  Library used by the NFSv4 server to do userid mapping.
> > +
> > +	  http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap
> > +
> 
> Unneeded empty new line at the end of the file.
[KP] OK
> 
> > diff --git a/package/libnfsidmap/libnfsidmap.mk
> > b/package/libnfsidmap/libnfsidmap.mk
> > new file mode 100644
> > index 0000000000..2c3bd812de
> > --- /dev/null
> > +++ b/package/libnfsidmap/libnfsidmap.mk
> > @@ -0,0 +1,13 @@
> > +#
> > +# libnfsidmap
> > +#
> 
> Please use the standard header for packages.
[KP] OK
> 
> > +
> > +LIBNFSIDMAP_VERSION = 0.25
> > +LIBNFSIDMAP_SITE =
> > +http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap
> > +LIBNFSIDMAP_SOURCE = libnfsidmap-$(LIBNFSIDMAP_VERSION).tar.gz
> 
> Not needed, this is the default value. Have you run "make check-package" ?
[KP] Not, sorry again, just tried to add these 2 patches as a quick fix to the NFSv4 support requirement
> 
> > +LIBNFSIDMAP_INSTALL_STAGING = YES
> > +LIBNFSIDMAP_LICENSE = BSD-like
> 
> This is not a proper license, see https://spdx.org/licenses/ for a proper list of
> SPDX license codes.
[KP] OK, will fix
> 
> > +LIBNFSIDMAP_LICENSE_FILES = COPYING
> > +
> > +$(eval $(autotools-package))
> > +$(eval $(host-autotools-package))
> 
> You're not using the host version of this package, so it shouldn't be added.
[KP] I used it for host build, but later found this unnecessary and did not remove the reminder
> 
> Thanks!
> 
> Thomas
[KP]  Thank you for review and sorry for lazy patches - I did not have time to invest into them yet.

Regards
Kosta

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

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

* [Buildroot] [PATCH 2/2] package/nfs-utils: enable support of NFSv4
  2019-02-06 16:06 ` [Buildroot] [PATCH 2/2] package/nfs-utils: enable support of NFSv4 kostap at marvell.com
@ 2019-02-12 10:33   ` Thomas Petazzoni
  0 siblings, 0 replies; 5+ messages in thread
From: Thomas Petazzoni @ 2019-02-12 10:33 UTC (permalink / raw)
  To: buildroot

Hello Kostya,

Thanks for this work, very useful to have this.

On Wed, 6 Feb 2019 18:06:01 +0200
<kostap@marvell.com> wrote:

> From: Konstantin Porotchkin <kostap@marvell.com>
> 
> Taken from git at github.com:openstack/manila-test-image.git
> /patches/nfs-utils-enable-nfsv4.patch

Nice, I didn't know Openstack was using Buildroot for some stuff.

> diff --git a/package/nfs-utils/Config.in b/package/nfs-utils/Config.in
> index 055b711f0d..08c0f4caae 100644
> --- a/package/nfs-utils/Config.in
> +++ b/package/nfs-utils/Config.in
> @@ -30,4 +30,14 @@ config BR2_PACKAGE_NFS_UTILS_RPC_RQUOTAD
>  	help
>  	  NFS remote quota server
>  
> +config BR2_PACKAGE_NFS_UTILS_NFS4
> +	bool "NFSv4 support"
> +	select BR2_PACKAGE_LIBEVENT
> +	select BR2_PACKAGE_LIBNFSIDMAP
> +	help
> +	  Enable support for NFSv4.
> +
> +comment "nfs-utils requires a toolchain with RPC and LARGEFILE support"
> +	depends on !BR2_INET_RPC || !BR2_LARGEFILE

Why are you adding this comment ? nfs-utils already has the appropriate
comment. Furthermore, neither BR2_INET_RPC nor BR2_LARGEFILE exist in
Buildroot nowadays.

> diff --git a/package/nfs-utils/S60nfs b/package/nfs-utils/S60nfs
> index 4183ff6268..bec7307653 100755
> --- a/package/nfs-utils/S60nfs
> +++ b/package/nfs-utils/S60nfs
> @@ -3,6 +3,8 @@
>  # nfs           This shell script takes care of starting and stopping
>  #               the NFS services. Stolen from RedHat FC5.
>  
> +ENABLEv4=yes

This seems weird. Why is it unconditional ? I guess it won't work if
BR2_PACKAGE_NFS_UTILS_NFS4 is disabled. Perhaps put this
in /etc/default/nfsd, and generate it in
package/nfs-utils/nfs-utils.mk ?

> +
>  mkdir -p /var/lock/subsys
>  mkdir -p /run/nfs/sm
>  mkdir -p /run/nfs/sm.bak
> @@ -15,13 +17,26 @@ if [ -f "${CFG_FILE}" ]; then
>  	. "${CFG_FILE}"
>  fi
>  
> +if [ $ENABLEv4 == "yes" ]; then
> +	pipefs_dir="`sed -n 's/^ *Pipefs-Directory *= *//p' /etc/idmapd.conf`"
> +fi
>  
>  start() {
>  	# Start daemons.
> +	if [ $ENABLEv4 == "yes" ]; then
> +		printf "Starting NFS idmapd: "
> +		[ -d /var/lib/nfs/v4recovery ] || mkdir -p /var/lib/nfs/v4recovery
> +		[ -d "$pipefs_dir" ] || mkdir -p "$pipefs_dir"
> +		if ! ( grep -q "on $pipefs_dir type rpc_pipefs" /proc/mounts ); then
> +			mount -t rpc_pipefs sunrpc "$pipefs_dir"
> +		fi
> +		rpc.idmapd
> +		echo "done"
> +	fi
> +
>  	printf "Starting NFS statd: "
>  	rpc.statd
>  	[ $? = 0 ] && echo "OK" || echo "FAIL"
> -	touch /var/lock/subsys/nfslock
>  
>  	printf "Starting NFS services: "
>  	/usr/sbin/exportfs -r
> @@ -34,11 +49,17 @@ start() {
>  	printf "Starting NFS mountd: "
>  	rpc.mountd
>  	[ $? = 0 ] && echo "OK" || echo "FAIL"
> -	touch /var/lock/subsys/nfs
>  }
>  
>  stop() {
>  	# Stop daemons.
> +	if [ $ENABLEv4 == "yes" ]; then
> +		printf "Shutting down NFS idmapd: "
> +		killall -q rpc.idmapd
> +		umount "$pipefs_dir"
> +		echo "done"
> +	fi
> +
>  	printf "Shutting down NFS mountd: "
>  	killall -q rpc.mountd 2>/dev/null
>  	[ $? = 0 ] && echo "OK" || echo "FAIL"
> @@ -56,7 +77,6 @@ stop() {
>  	[ $? = 0 ] && echo "OK" || echo "FAIL"
>  	rm -f /var/lock/subsys/nfs
>  	rm -f /var/run/rpc.statd.pid
> -	rm -f /var/lock/subsys/nfslock

Any reason why this is being removed ?

>  }
>  
>  # See how we were called.
> @@ -73,7 +93,6 @@ case "$1" in
>  		;;
>  	reload)
>  		/usr/sbin/exportfs -r
> -		touch /var/lock/subsys/nfs

Any reason why this is being removed ?

>  		;;
>  	*)
>  		echo "Usage: $0 {start|stop|restart|reload}"
> diff --git a/package/nfs-utils/etc-idmapd.conf b/package/nfs-utils/etc-idmapd.conf
> new file mode 100644
> index 0000000000..0288c0ce03
> --- /dev/null
> +++ b/package/nfs-utils/etc-idmapd.conf
> @@ -0,0 +1,9 @@
> +[General]
> +Verbosity = 0
> +Pipefs-Directory = /var/lib/nfs/rpc_pipefs
> +Domain = localdomain
> +
> +[Mapping]
> +Nobody-User = nobody
> +Nobody-Group = nogroup
> +
> diff --git a/package/nfs-utils/nfs-utils.mk b/package/nfs-utils/nfs-utils.mk
> index 9fa7ae200b..517ec19bea 100644
> --- a/package/nfs-utils/nfs-utils.mk
> +++ b/package/nfs-utils/nfs-utils.mk
> @@ -15,15 +15,19 @@ NFS_UTILS_DEPENDENCIES = host-pkgconf
>  NFS_UTILS_CONF_ENV = knfsd_cv_bsd_signals=no
>  
>  NFS_UTILS_CONF_OPTS = \
> -	--disable-nfsv4 \
> -	--disable-nfsv41 \
>  	--disable-gss \
>  	--disable-uuid \
> -	--disable-ipv6 \

I'm not sure why we are disabling IPv6 here. Changing this is
definitely OK, but it should be in a separate patch, as it's not
related.

>  	--without-tcp-wrappers \
>  	--with-statedir=/run/nfs \
>  	--with-rpcgen=internal
>  
> +ifeq ($(BR2_PACKAGE_LIBNFSIDMAP),y)
> +NFS_UTILS_DEPENDENCIES += libevent libnfsidmap lvm2 sqlite

If lvm2 and sqlite are dependencies, they should be selected from the
Config.in file. Any idea why lvm2 is needed ?

> +NFS_UTILS_CONF_OPTS += --enable-nfsv4 --enable-nfsv41
> +else
> +NFS_UTILS_CONF_OPTS += --disable-nfsv4 --disable-nfsv41
> +endif
> +
>  HOST_NFS_UTILS_CONF_OPTS = \
>  	--disable-nfsv4 \
>  	--disable-nfsv41 \
> @@ -62,7 +66,16 @@ define NFS_UTILS_INSTALL_FIXUP
>  	$(INSTALL) -D -m 644 \
>  		$(@D)/utils/mount/nfsmount.conf $(TARGET_DIR)/etc/nfsmount.conf
>  endef
> +
> +define NFS_UTILS_INSTALL_IDMAPD_CONF
> +	$(INSTALL) -m 0644 package/nfs-utils/etc-idmapd.conf \
> +		$(TARGET_DIR)/etc/idmapd.conf
> +endef

Please enclose this hook definition inside the ifeq
($(BR2_PACKAGE_NFS_UTILS_NFS4),y) condition.

> +
>  NFS_UTILS_POST_INSTALL_TARGET_HOOKS += NFS_UTILS_INSTALL_FIXUP
> +ifeq ($(BR2_PACKAGE_NFS_UTILS_NFS4),y)
> +	NFS_UTILS_POST_INSTALL_TARGET_HOOKS += NFS_UTILS_INSTALL_IDMAPD_CONF

Please don't indent.

Thanks!

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

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

end of thread, other threads:[~2019-02-12 10:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-06 16:06 [Buildroot] [PATCH 1/2] package/libnfsidmap: new package kostap at marvell.com
2019-02-06 16:06 ` [Buildroot] [PATCH 2/2] package/nfs-utils: enable support of NFSv4 kostap at marvell.com
2019-02-12 10:33   ` Thomas Petazzoni
2019-02-06 16:16 ` [Buildroot] [PATCH 1/2] package/libnfsidmap: new package Thomas Petazzoni
2019-02-06 16:29   ` [Buildroot] [EXT] " Kostya Porotchkin

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.