summaryrefslogtreecommitdiff
path: root/net-fs
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2007-05-12 11:27:06 +0000
committerMike Frysinger <vapier@gentoo.org>2007-05-12 11:27:06 +0000
commit0a2d5f31f5448834f9ba273d78c29833fc1db832 (patch)
tree2d8425338ad5b9b04d6c3ec643f9a72cad9aed0f /net-fs
parentStable on ppc64; bug #169372 (diff)
downloadgentoo-2-0a2d5f31f5448834f9ba273d78c29833fc1db832.tar.gz
gentoo-2-0a2d5f31f5448834f9ba273d78c29833fc1db832.tar.bz2
gentoo-2-0a2d5f31f5448834f9ba273d78c29833fc1db832.zip
Version bump.
(Portage version: 2.1.2.7)
Diffstat (limited to 'net-fs')
-rw-r--r--net-fs/nfs-utils/ChangeLog9
-rw-r--r--net-fs/nfs-utils/files/digest-nfs-utils-1.1.03
-rwxr-xr-xnet-fs/nfs-utils/files/nfs.initd36
-rwxr-xr-xnet-fs/nfs-utils/files/nfsmount.initd28
-rwxr-xr-xnet-fs/nfs-utils/files/rpc.gssd.initd20
-rwxr-xr-xnet-fs/nfs-utils/files/rpc.idmapd.initd19
-rwxr-xr-xnet-fs/nfs-utils/files/rpc.statd.initd20
-rw-r--r--net-fs/nfs-utils/nfs-utils-1.1.0.ebuild104
8 files changed, 214 insertions, 25 deletions
diff --git a/net-fs/nfs-utils/ChangeLog b/net-fs/nfs-utils/ChangeLog
index d298e1088fa3..f93fdbf4ac46 100644
--- a/net-fs/nfs-utils/ChangeLog
+++ b/net-fs/nfs-utils/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for net-fs/nfs-utils
# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/ChangeLog,v 1.102 2007/05/06 10:21:57 genone Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/ChangeLog,v 1.103 2007/05/12 11:27:06 vapier Exp $
+
+*nfs-utils-1.1.0 (12 May 2007)
+
+ 12 May 2007; Mike Frysinger <vapier@gentoo.org> files/nfs.initd,
+ files/nfsmount.initd, files/rpc.gssd.initd, files/rpc.idmapd.initd,
+ files/rpc.statd.initd, +nfs-utils-1.1.0.ebuild:
+ Version bump.
06 May 2007; Marius Mauch <genone@gentoo.org> nfs-utils-1.0.6-r6.ebuild:
Replacing einfo with elog
diff --git a/net-fs/nfs-utils/files/digest-nfs-utils-1.1.0 b/net-fs/nfs-utils/files/digest-nfs-utils-1.1.0
new file mode 100644
index 000000000000..19624e56f342
--- /dev/null
+++ b/net-fs/nfs-utils/files/digest-nfs-utils-1.1.0
@@ -0,0 +1,3 @@
+MD5 df88c6fe88a26f9797e74cb2d3291a2a nfs-utils-1.1.0.tar.gz 781661
+RMD160 6751ad3c9e98f96204cc94c837ea9e5d3dcefa05 nfs-utils-1.1.0.tar.gz 781661
+SHA256 fb42cc0f79ab76c3ab786a207685d30bae42663a31cc8edd113753caa106a682 nfs-utils-1.1.0.tar.gz 781661
diff --git a/net-fs/nfs-utils/files/nfs.initd b/net-fs/nfs-utils/files/nfs.initd
index 161f2a6d5faa..558222b565fb 100755
--- a/net-fs/nfs-utils/files/nfs.initd
+++ b/net-fs/nfs-utils/files/nfs.initd
@@ -1,15 +1,7 @@
#!/sbin/runscript
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/nfs.initd,v 1.4 2007/04/15 20:50:08 vapier Exp $
-
-#---------------------------------------------------------------------------
-# This script starts/stops the following
-# rpc.nfsd
-# rpc.mountd
-#---------------------------------------------------------------------------
-
-# NB: Config is in /etc/conf.d/nfs
+# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/nfs.initd,v 1.5 2007/05/12 11:27:06 vapier Exp $
opts="reload"
@@ -21,6 +13,7 @@ restarting=no
exportfs=/usr/sbin/exportfs
mountd=/usr/sbin/rpc.mountd
nfsd=/usr/sbin/rpc.nfsd
+smnotify=/usr/sbin/sm-notify
depend() {
local myneed="" myuse=""
@@ -48,14 +41,7 @@ waitfor_exportfs() {
wait $1
}
-start_it() {
- ebegin "Starting NFS $1"
- shift
- "$@"
- eend $?
- ret=$((ret + $?))
-}
-start() {
+mount_nfsd() {
# Make sure nfs support is loaded in the kernel #64709
if [ -e /proc/modules ] && ! grep -qs nfsd /proc/filesystems ; then
modprobe nfsd &> /dev/null
@@ -65,12 +51,21 @@ start() {
if grep -qs nfsd /proc/filesystems ; then
if ! grep -qs "nfsd /proc/fs/nfs" /proc/mounts ; then
ebegin "Mounting nfsd filesystem in /proc"
- mount -t nfsd nfsd /proc/fs/nfs
+ mount -t nfsd -o nodev,noexec,nosuid nfsd /proc/fs/nfs
eend $?
fi
fi
- # now that nfsd is mounted inside /proc, we can safely start mountd later
+}
+start_it() {
+ ebegin "Starting NFS $1"
+ shift
+ "$@"
+ eend $?
+ ret=$((ret + $?))
+}
+start() {
+ mount_nfsd
mkdir_nfsdirs
# Exportfs likes to hang if networking isn't working.
@@ -84,8 +79,9 @@ start() {
fi
local ret=0
- start_it daemon ${nfsd} ${OPTS_RPC_NFSD}
start_it mountd ${mountd} ${OPTS_RPC_MOUNTD}
+ start_it daemon ${nfsd} ${OPTS_RPC_NFSD}
+ [ -x "${smnotify}" ] && start_it smnotify ${smnotify} ${OPTS_SMNOTIFY}
return ${ret}
}
diff --git a/net-fs/nfs-utils/files/nfsmount.initd b/net-fs/nfs-utils/files/nfsmount.initd
index 74777a8fcdfa..7386f8c81ee6 100755
--- a/net-fs/nfs-utils/files/nfsmount.initd
+++ b/net-fs/nfs-utils/files/nfsmount.initd
@@ -1,7 +1,9 @@
#!/sbin/runscript
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/nfsmount.initd,v 1.2 2007/04/15 20:50:08 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/nfsmount.initd,v 1.3 2007/05/12 11:27:06 vapier Exp $
+
+[ -e /etc/conf.d/nfs ] && . /etc/conf.d/nfs
depend() {
local myneed="" myuse=""
@@ -15,7 +17,31 @@ depend() {
use ypbind dns ${myuse}
}
+mount_nfsd() {
+ # Make sure nfs support is loaded in the kernel #64709
+ if [ -e /proc/modules ] && ! grep -qs nfsd /proc/filesystems ; then
+ modprobe nfsd &> /dev/null
+ fi
+
+ # This is the new "kernel 2.6 way" to handle the exports file
+ if grep -qs nfsd /proc/filesystems ; then
+ if ! grep -qs "nfsd /proc/fs/nfs" /proc/mounts ; then
+ ebegin "Mounting nfsd filesystem in /proc"
+ mount -t nfsd -o nodev,noexec,nosuid nfsd /proc/fs/nfs
+ eend $?
+ fi
+ fi
+}
+
start() {
+ mount_nfsd
+
+ if [ -x /usr/sbin/sm-notify ] ; then
+ ebegin "Starting NFS sm-notify"
+ /usr/sbin/sm-notify ${OPTS_SMNOTIFY}
+ eend $?
+ fi
+
ebegin "Mounting NFS filesystems"
mount -a -t nfs,nfs4
eend $?
diff --git a/net-fs/nfs-utils/files/rpc.gssd.initd b/net-fs/nfs-utils/files/rpc.gssd.initd
index 5dc1a50663d4..955f54c7bbdd 100755
--- a/net-fs/nfs-utils/files/rpc.gssd.initd
+++ b/net-fs/nfs-utils/files/rpc.gssd.initd
@@ -1,7 +1,7 @@
#!/sbin/runscript
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/rpc.gssd.initd,v 1.3 2007/04/07 11:05:15 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/rpc.gssd.initd,v 1.4 2007/05/12 11:27:06 vapier Exp $
[ -e /etc/conf.d/nfs ] && . /etc/conf.d/nfs
@@ -14,6 +14,22 @@ depend() {
after quota
}
+mount_nfsd() {
+ # Make sure nfs support is loaded in the kernel #64709
+ if [ -e /proc/modules ] && ! grep -qs nfsd /proc/filesystems ; then
+ modprobe nfsd &> /dev/null
+ fi
+
+ # This is the new "kernel 2.6 way" to handle the exports file
+ if grep -qs nfsd /proc/filesystems ; then
+ if ! grep -qs "nfsd /proc/fs/nfs" /proc/mounts ; then
+ ebegin "Mounting nfsd filesystem in /proc"
+ mount -t nfsd -o nodev,noexec,nosuid nfsd /proc/fs/nfs
+ eend $?
+ fi
+ fi
+}
+
start_it() {
ebegin "Starting $1"
shift
@@ -22,6 +38,8 @@ start_it() {
ret=$((ret + $?))
}
start() {
+ mount_nfsd
+
local ret=0
start_it gssd ${gssd} ${OPTS_RPC_GSSD}
start_it svcgssd ${svcgssd} ${OPTS_RPC_SVCGSSD}
diff --git a/net-fs/nfs-utils/files/rpc.idmapd.initd b/net-fs/nfs-utils/files/rpc.idmapd.initd
index 49a323aa981e..5bb00ee95195 100755
--- a/net-fs/nfs-utils/files/rpc.idmapd.initd
+++ b/net-fs/nfs-utils/files/rpc.idmapd.initd
@@ -1,7 +1,7 @@
#!/sbin/runscript
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/rpc.idmapd.initd,v 1.2 2007/04/02 12:28:30 uberlord Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/rpc.idmapd.initd,v 1.3 2007/05/12 11:27:06 vapier Exp $
[ -e /etc/conf.d/nfs ] && . /etc/conf.d/nfs
@@ -37,7 +37,24 @@ umount_pipefs() {
fi
}
+mount_nfsd() {
+ # Make sure nfs support is loaded in the kernel #64709
+ if [ -e /proc/modules ] && ! grep -qs nfsd /proc/filesystems ; then
+ modprobe nfsd &> /dev/null
+ fi
+
+ # This is the new "kernel 2.6 way" to handle the exports file
+ if grep -qs nfsd /proc/filesystems ; then
+ if ! grep -qs "nfsd /proc/fs/nfs" /proc/mounts ; then
+ ebegin "Mounting nfsd filesystem in /proc"
+ mount -t nfsd -o nodev,noexec,nosuid nfsd /proc/fs/nfs
+ eend $?
+ fi
+ fi
+}
+
start() {
+ mount_nfsd
mount_pipefs
ebegin "Starting idmapd"
diff --git a/net-fs/nfs-utils/files/rpc.statd.initd b/net-fs/nfs-utils/files/rpc.statd.initd
index 59ba10055958..fb60de7c1bd5 100755
--- a/net-fs/nfs-utils/files/rpc.statd.initd
+++ b/net-fs/nfs-utils/files/rpc.statd.initd
@@ -1,7 +1,7 @@
#!/sbin/runscript
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/rpc.statd.initd,v 1.2 2007/04/02 12:28:30 uberlord Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/rpc.statd.initd,v 1.3 2007/05/12 11:27:06 vapier Exp $
[ -e /etc/conf.d/nfs ] && . /etc/conf.d/nfs
@@ -14,6 +14,22 @@ depend() {
after quota
}
+mount_nfsd() {
+ # Make sure nfs support is loaded in the kernel #64709
+ if [ -e /proc/modules ] && ! grep -qs nfsd /proc/filesystems ; then
+ modprobe nfsd &> /dev/null
+ fi
+
+ # This is the new "kernel 2.6 way" to handle the exports file
+ if grep -qs nfsd /proc/filesystems ; then
+ if ! grep -qs "nfsd /proc/fs/nfs" /proc/mounts ; then
+ ebegin "Mounting nfsd filesystem in /proc"
+ mount -t nfsd -o nodev,noexec,nosuid nfsd /proc/fs/nfs
+ eend $?
+ fi
+ fi
+}
+
is_running() {
# Don't start rpc.statd if already started by someone else ...
# Don't try and kill it if it's already dead ...
@@ -21,6 +37,8 @@ is_running() {
}
start() {
+ mount_nfsd
+
is_running && return 0
ebegin "Starting NFS statd"
start-stop-daemon --start --quiet --exec ${rpc_bin} -- ${OPTS_RPC_STATD}
diff --git a/net-fs/nfs-utils/nfs-utils-1.1.0.ebuild b/net-fs/nfs-utils/nfs-utils-1.1.0.ebuild
new file mode 100644
index 000000000000..c75a3b51a4ec
--- /dev/null
+++ b/net-fs/nfs-utils/nfs-utils-1.1.0.ebuild
@@ -0,0 +1,104 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/nfs-utils-1.1.0.ebuild,v 1.1 2007/05/12 11:27:06 vapier Exp $
+
+inherit eutils flag-o-matic multilib
+
+DESCRIPTION="NFS client and server daemons"
+HOMEPAGE="http://nfs.sourceforge.net/"
+SRC_URI="mirror://sourceforge/nfs/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
+IUSE="nonfsv4 tcpd kerberos"
+
+# kth-krb doesn't provide the right include
+# files, and nfs-utils doesn't build against heimdal either,
+# so don't depend on virtual/krb.
+# (04 Feb 2005 agriffis)
+RDEPEND="tcpd? ( sys-apps/tcp-wrappers )
+ >=net-nds/portmap-5b-r6
+ !nonfsv4? (
+ >=dev-libs/libevent-1.0b
+ >=net-libs/libnfsidmap-0.16
+ )
+ kerberos? (
+ net-libs/librpcsecgss
+ app-crypt/mit-krb5
+ )"
+DEPEND="${RDEPEND}"
+
+src_unpack() {
+ unpack ${P}.tar.gz
+ cd "${S}"
+ #epatch "${DISTDIR}"/nfs-utils-${PV}-CITI_NFS4_ALL-1.dif
+}
+
+src_compile() {
+ econf \
+ --mandir=/usr/share/man \
+ --with-statedir=/var/lib/nfs \
+ --disable-rquotad \
+ --enable-nfsv3 \
+ --enable-secure-statd \
+ $(use_with tcpd tcp-wrappers) \
+ $(use_enable !nonfsv4 nfsv4) \
+ $(use_enable kerberos gss) \
+ || die "Configure failed"
+
+ emake || die "Failed to compile"
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die
+
+ # Don't overwrite existing xtab/etab, install the original
+ # versions somewhere safe... more info in pkg_postinst
+ dodir /usr/lib/nfs
+ keepdir /var/lib/nfs/{sm,sm.bak}
+ mv "${D}"/var/lib/nfs/* "${D}"/usr/lib/nfs
+ keepdir /var/lib/nfs
+
+ # Install some client-side binaries in /sbin
+ dodir /sbin
+ mv "${D}"/usr/sbin/rpc.statd "${D}"/sbin/ || die
+
+ dodoc ChangeLog README
+ docinto linux-nfs ; dodoc linux-nfs/*
+
+ insinto /etc
+ doins "${FILESDIR}"/exports
+
+ local f list=""
+ use !nonfsv4 && list="${list} rpc.idmapd"
+ use kerberos && list="${list} rpc.gssd"
+ for f in nfs nfsmount rpc.statd ${list} ; do
+ newinitd "${FILESDIR}"/${f}.initd ${f} || die "doinitd ${f}"
+ done
+ newconfd "${FILESDIR}"/nfs.confd nfs
+ use !nonfsv4 && doins utils/idmapd/idmapd.conf
+
+ # uClibc doesn't provide rpcgen like glibc, so lets steal it from nfs-utils
+ if ! use elibc_glibc ; then
+ dobin tools/rpcgen/rpcgen || die "rpcgen"
+ newdoc tools/rpcgen/README README.rpcgen
+ fi
+}
+
+pkg_preinst() {
+ [[ -s ${ROOT}/etc/exports ]] && rm -f "${D}"/etc/exports
+}
+
+pkg_postinst() {
+ # Install default xtab and friends if there's none existing.
+ # In src_install we put them in /usr/lib/nfs for safe-keeping, but
+ # the daemons actually use the files in /var/lib/nfs. This fixes
+ # bug 30486
+ local f
+ for f in "${ROOT}"/usr/$(get_libdir)/nfs/*; do
+ [[ -e ${ROOT}/var/lib/nfs/${f##*/} ]] && continue
+ einfo "Copying default ${f##*/} from /usr/$(get_libdir)/nfs to /var/lib/nfs"
+ cp -pPR "${f}" "${ROOT}"/var/lib/nfs/
+ done
+}