1 # We don't use libtool.
4 Summary: NFS utlilities and supporting daemons for the kernel NFS server.
8 Source0: ftp://nfs.sourceforge.net/pub/nfs/%{name}-%{version}.tar.gz
9 Group: System Environment/Daemons
12 Obsoletes: knfsd-clients
13 Obsoletes: nfs-server-clients
16 Provides: nfs-server-clients
18 Provides: knfsd-clients
21 Buildroot: /var/tmp/%{name}-root
22 Requires: kernel >= 2.2.7, portmap >= 4.0
25 The nfs-utils package provides a daemon for the kernel NFS server and
26 related tools, which provides a much higher level of performance than the
27 traditional Linux NFS server used by most users.
29 This package also contains the showmount program. Showmount queries the
30 mount daemon on a remote host for information about the NFS (Network File
31 System) server on the remote host. For example, showmount can display the
32 clients which are mounted on that host.
38 %if %{_target_cpu} != %{_build_cpu}
40 CXX=%{__cxx}; export CXX
41 BUILD_CC=gcc; export BUILD_CC
42 %configure --build=%{__build_alias}
49 rm -rf $RPM_BUILD_ROOT
50 mkdir -p $RPM_BUILD_ROOT/{/sbin,/usr/sbin}
51 mkdir -p $RPM_BUILD_ROOT%{_mandir}/{man5,man8}
52 mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
53 mkdir -p $RPM_BUILD_ROOT/var/lib/nfs
54 make install_prefix=$RPM_BUILD_ROOT MANDIR=$RPM_BUILD_ROOT%{_mandir} SBINDIR=$RPM_BUILD_ROOT%{_prefix}/sbin install
55 install -s -m 755 tools/rpcdebug/rpcdebug $RPM_BUILD_ROOT/sbin
56 install -m 755 etc/redhat/nfs.init $RPM_BUILD_ROOT/etc/rc.d/init.d/nfs
57 install -m 755 etc/redhat/nfslock.init $RPM_BUILD_ROOT/etc/rc.d/init.d/nfslock
58 touch $RPM_BUILD_ROOT/var/lib/nfs/rmtab
59 mv $RPM_BUILD_ROOT/usr/sbin/{rpc.lockd,rpc.statd} $RPM_BUILD_ROOT/sbin
62 rm -rf $RPM_BUILD_ROOT
65 /sbin/chkconfig --add nfs
66 /sbin/chkconfig --add nfslock
69 if [ "$1" = "0" ]; then
70 /sbin/chkconfig --del nfs
71 /sbin/chkconfig --del nfslock
74 %triggerpostun -- nfs-server
75 /sbin/chkconfig --add nfs
77 %triggerpostun -- knfsd
78 /sbin/chkconfig --add nfs
80 %triggerpostun -- knfsd-clients
81 /sbin/chkconfig --add nfslock
85 %config /etc/rc.d/init.d/nfs
87 %config(noreplace) /var/lib/nfs/xtab
88 %config(noreplace) /var/lib/nfs/etab
89 %config(noreplace) /var/lib/nfs/rmtab
101 %config /etc/rc.d/init.d/nfslock
102 %doc README ChangeLog COPYING