aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.0.bb
diff options
context:
space:
mode:
authorChen Qi <Qi.Chen@windriver.com>2014-11-07 16:47:19 +0800
committerAndreas Oberritter <obi@opendreambox.org>2015-10-12 15:13:35 +0200
commit851869df4ecca8c1397f37e2ff4d0de4bb972081 (patch)
tree9473e12a31c5cc36acee80a11e91e64c443e08cb /meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.0.bb
parent93c563a47710f6a6667c735f1a2dd9582e771ee0 (diff)
downloadopenembedded-core-contrib-851869df4ecca8c1397f37e2ff4d0de4bb972081.tar.gz
nfs-utils: change owner/group of directories in do_install
Previously, the owners/groups of directories like /var/lib/nfs/statd are changed in the init script, /etc/init.d/nfscommon. This is actually a workaround. We need to change them at do_install time. This patch fixes the above problem by changing owners/groups at do_install time. Besides, configuration option '--with-staduser=nobody' is changed to be '--with-statduser=rpcuser'. And /var/lib/nfs/statd/state is modified to have permission 0644, just like other distros (ubuntu, fedora, etc.) do. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> (cherry picked from commit 8c27a1e25ae42a435ab7d290cab40f94f9286243) Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Diffstat (limited to 'meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.0.bb')
-rw-r--r--meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.0.bb7
1 files changed, 5 insertions, 2 deletions
diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.0.bb b/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.0.bb
index 7c3f21874f..a92af91e9d 100644
--- a/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.0.bb
+++ b/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.0.bb
@@ -57,7 +57,7 @@ SYSTEMD_SERVICE_${PN} = "nfs-server.service nfs-mountd.service"
SYSTEMD_SERVICE_${PN}-client = "nfs-statd.service"
# --enable-uuid is need for cross-compiling
-EXTRA_OECONF = "--with-statduser=nobody \
+EXTRA_OECONF = "--with-statduser=rpcuser \
--enable-mountconfig \
--enable-libmount-mount \
--disable-nfsv41 \
@@ -101,7 +101,6 @@ do_compile_prepend() {
do_install_append () {
install -d ${D}${sysconfdir}/init.d
- install -d ${D}${localstatedir}/lib/nfs/statd
install -m 0755 ${WORKDIR}/nfsserver ${D}${sysconfdir}/init.d/nfsserver
install -m 0755 ${WORKDIR}/nfscommon ${D}${sysconfdir}/init.d/nfscommon
@@ -117,6 +116,10 @@ do_install_append () {
# kernel code as of 3.8 hard-codes this path as a default
install -d ${D}/var/lib/nfs/v4recovery
+ # chown the directories and files
+ chown -R rpcuser:rpcuser ${D}${localstatedir}/lib/nfs/statd
+ chmod 0644 ${D}${localstatedir}/lib/nfs/statd/state
+
# the following are built by CC_FOR_BUILD
rm -f ${D}${sbindir}/rpcdebug
rm -f ${D}${sbindir}/rpcgen