diff options
author | Patrick J Volkerding <volkerdi@slackware.com> | 2011-04-25 13:37:00 +0000 |
---|---|---|
committer | Eric Hameleers <alien@slackware.com> | 2018-05-31 22:45:18 +0200 |
commit | 75a4a592e5ccda30715f93563d741b83e0dcf39e (patch) | |
tree | 502f745607e77a2c4386ad38d818ddcafe81489c /source/n/nfs-utils | |
parent | b76270bf9e6dd375e495fec92140a79a79415d27 (diff) | |
download | current-75a4a592e5ccda30715f93563d741b83e0dcf39e.tar.gz |
Slackware 13.37slackware-13.37
Mon Apr 25 13:37:00 UTC 2011
Slackware 13.37 x86_64 stable is released!
Thanks to everyone who pitched in on this release: the Slackware team,
the folks producing upstream code, and linuxquestions.org for providing
a great forum for collaboration and testing.
The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a
dual-sided
32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware
project by picking up a copy from store.slackware.com. We're taking
pre-orders now, and offer a discount if you sign up for a subscription.
As always, thanks to the Slackware community for testing, suggestions,
and feedback. :-)
Have fun!
Diffstat (limited to 'source/n/nfs-utils')
-rw-r--r-- | source/n/nfs-utils/doinst.sh | 39 | ||||
-rw-r--r-- | source/n/nfs-utils/nfs-utils-1.2.3.tar.sign (renamed from source/n/nfs-utils/nfs-utils-1.2.2.tar.bz2.sign) | 6 | ||||
-rwxr-xr-x | source/n/nfs-utils/nfs-utils.SlackBuild | 59 | ||||
-rw-r--r-- | source/n/nfs-utils/rc.nfsd | 6 |
4 files changed, 67 insertions, 43 deletions
diff --git a/source/n/nfs-utils/doinst.sh b/source/n/nfs-utils/doinst.sh new file mode 100644 index 00000000..214ff1b9 --- /dev/null +++ b/source/n/nfs-utils/doinst.sh @@ -0,0 +1,39 @@ +#!/bin/sh +config() { + NEW="$1" + OLD="$(dirname $NEW)/$(basename $NEW .new)" + # If there's no config file by that name, mv it over: + if [ ! -r $OLD ]; then + mv $NEW $OLD + elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then # toss the redundant copy + rm $NEW + fi + # Otherwise, we leave the .new copy for the admin to consider... +} +config var/lib/nfs/etab.new +config var/lib/nfs/rmtab.new +config var/lib/nfs/state.new +config var/lib/nfs/xtab.new +rm -f var/lib/nfs/*.new +if [ -x etc/rc.d/rc.nfsd ]; then + chmod 755 etc/rc.d/rc.nfsd.new +else + chmod 644 etc/rc.d/rc.nfsd.new +fi +config etc/rc.d/rc.nfsd.new +config etc/nfsmount.conf.new +config etc/exports.new +# If you already had your own /etc/exports, this one is probably useless... +rm -f etc/exports.new +( cd sbin ; rm -rf umount.nfs ) +( cd sbin ; ln -sf mount.nfs umount.nfs ) +( cd usr/man/man8 ; rm -rf rpc.mountd.8.gz ) +( cd usr/man/man8 ; ln -sf mountd.8.gz rpc.mountd.8.gz ) +( cd usr/man/man8 ; rm -rf rpc.nfsd.8.gz ) +( cd usr/man/man8 ; ln -sf nfsd.8.gz rpc.nfsd.8.gz ) +( cd usr/man/man8 ; rm -rf rpc.statd.8.gz ) +( cd usr/man/man8 ; ln -sf statd.8.gz rpc.statd.8.gz ) +( cd usr/man/man8 ; rm -rf rpc.sm-notify.8.gz ) +( cd usr/man/man8 ; ln -sf sm-notify.8.gz rpc.sm-notify.8.gz ) +( cd usr/sbin ; rm -rf rpc.statd ) +( cd usr/sbin ; ln -sf ../../sbin/rpc.statd rpc.statd ) diff --git a/source/n/nfs-utils/nfs-utils-1.2.2.tar.bz2.sign b/source/n/nfs-utils/nfs-utils-1.2.3.tar.sign index a4b95a79..f159e0b6 100644 --- a/source/n/nfs-utils/nfs-utils-1.2.2.tar.bz2.sign +++ b/source/n/nfs-utils/nfs-utils-1.2.3.tar.sign @@ -2,7 +2,7 @@ Version: GnuPG v1.4.9 (GNU/Linux) Comment: See http://www.kernel.org/signature.html for info -iD8DBQBLfTsAyGugalF9Dw4RAgLSAJ0TnlJLHcU7dEWZ80LA775ZuQnrigCgjnWB -bxbY8o9jiBY9G422Fh6b8bA= -=dG1E +iD8DBQBMoeJcyGugalF9Dw4RApKyAJ91WfvKRivOd7XKaUXrNaIDlhwozACfacf5 +b0Maa5t3jk5Pnj+IQqvic+g= +=cnNE -----END PGP SIGNATURE----- diff --git a/source/n/nfs-utils/nfs-utils.SlackBuild b/source/n/nfs-utils/nfs-utils.SlackBuild index 8f3e3ef8..2cf5a150 100755 --- a/source/n/nfs-utils/nfs-utils.SlackBuild +++ b/source/n/nfs-utils/nfs-utils.SlackBuild @@ -1,6 +1,6 @@ #!/bin/sh -# Copyright 2008, 2009, 2010 Patrick J. Volkerding, Sebeka, MN, USA +# Copyright 2008, 2009, 2010, 2011 Patrick J. Volkerding, Sebeka, MN, USA # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -21,8 +21,8 @@ # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -VERSION=1.2.2 -BUILD=${BUILD:-1} +VERSION=1.2.3 +BUILD=${BUILD:-3} # Automatically determine the architecture we're building on: if [ -z "$ARCH" ]; then @@ -64,7 +64,7 @@ chmod 644 $PKG/etc/rc.d/rc.nfsd.new cd $TMP rm -rf nfs-utils-$VERSION -tar xvf $CWD/nfs-utils-$VERSION.tar.bz2 || exit 1 +tar xvf $CWD/nfs-utils-$VERSION.tar.xz || exit 1 cd nfs-utils-$VERSION || exit 1 zcat $CWD/nfs-utils.lwrap.needs.lnsl.diff.gz | patch -p1 --verbose || exit 1 @@ -84,6 +84,7 @@ CFLAGS="$SLKCFLAGS" \ --mandir=/usr/man \ --with-statedir=/var/lib/nfs \ --enable-nfsv3 \ + --enable-mountconfig \ --enable-nfsv4=no \ --enable-gss=no \ --enable-tirpc=no \ @@ -94,6 +95,13 @@ CFLAGS="$SLKCFLAGS" \ make $NUMJOBS || make || exit 1 make install DESTDIR=$PKG || exit 1 +# Add nfsmount.conf and man page: +cat ./utils/mount/nfsmount.conf > $PKG/etc/nfsmount.conf.new +mkdir -p $PKG/usr/man/man5 +cat ./utils/mount/nfsmount.conf.man > $PKG/usr/man/man5/nfsmount.conf.5 +# Set default protocol version 3: +sed -i "s/# Defaultvers=4/Defaultvers=3/g" $PKG/etc/nfsmount.conf.new + # These might be in use: ( cd $PKG/var/lib/nfs for config_file in etab rmtab state xtab ; do @@ -114,13 +122,21 @@ find $PKG | xargs file | grep -e "executable" -e "shared object" \ mkdir -p $PKG/usr/doc/nfs-utils-$VERSION cp -a \ - AUTHORS COPYING INSTALL NEWS README \ + AUTHORS COPYING* INSTALL NEWS README* \ $PKG/usr/doc/nfs-utils-$VERSION mkdir -p $PKG/usr/doc/nfs-utils-$VERSION/statd cp -a \ utils/statd/COPYING utils/statd/COPYRIGHT utils/statd/TODO \ $PKG/usr/doc/nfs-utils-$VERSION/statd +# If there's a ChangeLog, installing at least part of the recent history +# is useful, but don't let it get totally out of control: +if [ -r ChangeLog ]; then + DOCSDIR=$(echo $PKG/usr/doc/*-$VERSION) + cat ChangeLog | head -n 1000 > $DOCSDIR/ChangeLog + touch -r ChangeLog $DOCSDIR/ChangeLog +fi + # Compress and if needed symlink the man pages: if [ -d $PKG/usr/man ]; then ( cd $PKG/usr/man @@ -138,38 +154,7 @@ fi mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc -cat << EOF > $PKG/install/doinst.sh -#!/bin/sh -config() { - NEW="\$1" - OLD="\$(dirname \$NEW)/\$(basename \$NEW .new)" - # If there's no config file by that name, mv it over: - if [ ! -r \$OLD ]; then - mv \$NEW \$OLD - elif [ "\$(cat \$OLD | md5sum)" = "\$(cat \$NEW | md5sum)" ]; then # toss the redundant copy - rm \$NEW - fi - # Otherwise, we leave the .new copy for the admin to consider... -} -EOF -( cd $PKG/var/lib/nfs - for config_file in etab.new rmtab.new state.new xtab.new ; do - if [ -r ${config_file} ]; then - echo "config var/lib/nfs/${config_file}" >> $PKG/install/doinst.sh - fi - done -) -# If these aren't moved into place, they're junk: -echo "rm -f var/lib/nfs/*.new" >> $PKG/install/doinst.sh -cat << EOF >> $PKG/install/doinst.sh -if [ -x etc/rc.d/rc.nfsd ]; then - chmod 755 etc/rc.d/rc.nfsd.new -else - chmod 644 etc/rc.d/rc.nfsd.new -fi -config etc/rc.d/rc.nfsd.new -config etc/exports.new -EOF +zcat $CWD/doinst.sh.gz > $PKG/install/doinst.sh # Build the package: cd $PKG diff --git a/source/n/nfs-utils/rc.nfsd b/source/n/nfs-utils/rc.nfsd index f2113382..b43bd3b8 100644 --- a/source/n/nfs-utils/rc.nfsd +++ b/source/n/nfs-utils/rc.nfsd @@ -16,9 +16,9 @@ nfsd_start() { exit # no uncommented shares in /etc/exports fi - # First, make sure the nfsd kernel module is loaded. You can comment this - # part out if you've built nfsd support directly into the kernel. - if [ -z "`/sbin/lsmod | grep "^nfsd "`" ]; then + # If we do not detect nfsd support built into the kernel (or previously + # loaded as a module), we will try to load the nfsd.ko kernel module: + if [ ! -r /proc/1/net/rpc/nfsd ]; then /sbin/modprobe nfsd fi |