]> git.pld-linux.org Git - packages/nfs-utils.git/blob - nfs-utils.spec
- add hack for heimdal 0.7 (expose internal struct)
[packages/nfs-utils.git] / nfs-utils.spec
1 #
2 # Conditional build:
3 %bcond_without  nfs4            # without NFSv4 support
4 #
5 Summary:        Kernel NFS server
6 Summary(pl):    Dzia³aj±cy na poziomie j±dra serwer NFS
7 Summary(pt_BR): Os utilitários para o cliente e servidor NFS do Linux
8 Summary(ru):    õÔÉÌÉÔÙ ÄÌÑ NFS É ÄÅÍÏÎÙ ÐÏÄÄÅÒÖËÉ ÄÌÑ NFS-ÓÅÒ×ÅÒÁ ÑÄÒÁ
9 Summary(uk):    õÔÉ̦ÔÉ ÄÌÑ NFS ÔÁ ÄÅÍÏÎɠЦÄÔÒÉÍËÉ ÄÌÑ NFS-ÓÅÒ×ÅÒÁ ÑÄÒÁ
10 Name:           nfs-utils
11 Version:        1.0.7
12 Release:        4
13 License:        GPL
14 Group:          Networking/Daemons
15 Source0:        http://dl.sourceforge.net/nfs/%{name}-%{version}.tar.gz
16 # Source0-md5:  8f863120261cd572ad320a9152581e11
17 Source1:        ftp://ftp.linuxnfs.sourceforge.org/pub/nfs/nfs.doc.tar.gz
18 # Source1-md5:  ae7db9c61c5ad04f83bb99e5caed73da
19 Source2:        nfs.init
20 Source3:        nfslock.init
21 Source4:        rquotad.init
22 Source5:        nfs.sysconfig
23 Source6:        nfslock.sysconfig
24 Source7:        rquotad.sysconfig
25 Source8:        nfsfs.init
26 Patch0:         %{name}-paths.patch
27 Patch1:         %{name}-time.patch
28 Patch2:         %{name}-eepro-support.patch
29 Patch3:         %{name}-install.patch
30 Patch4:         %{name}-nolibs.patch
31 Patch5:         %{name}-usn36.patch
32 Patch6:         http://www.citi.umich.edu/projects/nfsv4/linux/nfs-utils-patches/1.0.7-2/nfs-utils-1.0.7-CITI_NFS4_ALL-2.dif
33 Patch7:         %{name}-heimdal-internals.patch
34 URL:            http://nfs.sourceforge.net/
35 BuildRequires:  autoconf
36 %if %{with nfs4}
37 BuildRequires:  heimdal-devel >= 0.7
38 BuildRequires:  libevent-devel
39 BuildRequires:  librpcsecgss-devel
40 BuildRequires:  nfsidmap-devel
41 %endif
42 BuildRequires:  libwrap-devel
43 PreReq:         rc-scripts >= 0.4.0
44 PreReq:         setup >= 2.4.6-7
45 Requires:       %{name}-common = %{version}-%{release}
46 Requires(post,preun):   /sbin/chkconfig
47 Requires(post): fileutils
48 Requires(post): sed
49 Requires:       portmap >= 4.0
50 Provides:       nfsdaemon
51 Obsoletes:      nfsdaemon
52 Obsoletes:      knfsd
53 Obsoletes:      nfs-server
54 Conflicts:      kernel < 2.2.5
55 ExcludeArch:    armv4l
56 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
57
58 %description
59 This is the *new* kernel NFS server and related tools. It provides a
60 much higher level of performance than the traditional Linux user-land
61 NFS server.
62
63 %description -l pl
64 To jest *nowy* dzia³aj±cy na poziomie j±dra serwer NFS oraz zwi±zane z
65 nim narzêdzia. Serwer ten dostarcza znacznie wiêksz± wydajno¶æ ni¿
66 tradycyjny, dzia³aj±cy na poziomie u¿ytkownika serwer NFS.
67
68 %description -l pt_BR
69 O pacote nfs-utils provê os utilitários para o cliente e servidor NFS
70 do Linux.
71
72 %description -l ru
73 ðÁËÅÔ nfs-utils ÐÒÅÄÏÓÔÁ×ÌÑÅÔ ÄÅÍÏÎÁ ÄÌÑ NFS-ÓÅÒ×ÅÒÁ, ×ËÌÀÞÅÎÎÏÇÏ ×
74 ÑÄÒÏ, É ÓÏÐÕÔÓÔ×ÕÀÝÉÅ ÕÔÉÌÉÔÙ, ËÏÔÏÒÙÅ ÏÂÅÓÐÅÞÉ×ÁÀÔ ÎÁÍÎÏÇÏ ÂÏÌØÛÕÀ
75 ÐÒÏÉÚ×ÏÄÉÔÅÌØÎÏÓÔØ, ÞÅÍ ÔÒÁÄÉÃÉÏÎÎÙÅ Linux NFS-ÓÅÒ×ÅÒÁ, ÉÓÐÏÌØÚÕÅÍÙÅ
76 ÂÏÌØÛÉÎÓÔ×ÏÍ ÐÏÌØÚÏ×ÁÔÅÌÅÊ.
77
78 %description -l uk
79 ðÁËÅÔ nfs-utils ÎÁÄÁ¤ ÄÅÍÏÎÁ ÄÌÑ NFS-ÓÅÒ×ÅÒÁ, ×ÂÕÄÏ×ÁÎÏÇÏ × ÑÄÒÏ, ÔÁ
80 ÓÕÐÕÔΦ ÕÔÉ̦ÔÉ, Ñ˦ ÚÁÂÅÚÐÅÞÕÀÔØ ÎÁÂÁÇÁÔϠ¦ÌØÛÕ ÐÒÏÄÕËÔÉ×ΦÓÔØ, Î¦Ö
81 ÔÒÁÄÉæÊΦ Linux NFS-ÓÅÒ×ÅÒÉ, Ñ˦ ×ÉËÏÒÉÓÔÏ×Õ¤ Â¦ÌØÛ¦ÓÔØ ËÏÒÉÓÔÕ×ÁÞ¦×.
82
83 %package clients
84 Summary:        Clients for connecting to a remote NFS server
85 Summary(pl):    Klienci do ³±czenia siê ze zdalnym serwerem NFS
86 Group:          Networking
87 PreReq:         rc-scripts
88 Requires(post,preun):   /sbin/chkconfig
89 Requires:       psmisc
90 Requires:       %{name}-common = %{version}-%{release}
91 Provides:       nfsclient
92 Provides:       nfs-server-clients
93 Obsoletes:      nfsclient
94 Obsoletes:      nfs-server-clients
95 Obsoletes:      knfsd-clients
96
97 %description clients
98 The nfs-server-clients package contains the showmount program.
99 Showmount queries the mount daemon on a remote host for information
100 about the NFS (Network File System) server on the remote host. For
101 example, showmount can display the clients which are mounted on that
102 host. This package is not needed to mount NFS volumes.
103
104 %description clients -l pl
105 Pakiet zawiera program showmount s³u¿±cy do odpytywania serwera NFS.
106 Showmount pyta demona na zdalnej maszynie o informacje NFS na zdalnym
107 ho¶cie. Na przyk³ad, showmount potrafi pokazaæ klientów, którzy s±
108 zamountowani na tym serwerze. Ten pakiet nie jest konieczny do
109 zamountowania zasobów NFS.
110
111 %package lock
112 Summary:        Programs for NFS file locking
113 Summary(pl):    Programy do obs³ugi blokowania plików poprzez NFS (lock)
114 Group:          Networking
115 PreReq:         rc-scripts
116 Requires(post,preun):   /sbin/chkconfig
117 #Requires:      kernel >= 2.2.5
118 Requires:       portmap >= 4.0
119 Provides:       nfslockd
120 Obsoletes:      nfslockd
121 Obsoletes:      knfsd-lock
122
123 %description lock
124 The nfs-lock pacage contains programs which support the NFS file lock.
125 Install nfs-lock if you want to use file lock over NFS.
126
127 %description lock -l pl
128 Ten pakiet zawiera programy umo¿liwiaj±ce wykonywanie blokowania
129 plików (file locking) poprzez NFS.
130
131 %package rquotad
132 Summary:        Remote quota server
133 Summary(pl):    Zdalny serwer quota
134 Group:          Networking/Daemons
135 PreReq:         rc-scripts
136 Requires(post,preun):   /sbin/chkconfig
137 Obsoletes:      quota-rquotad
138
139 %description rquotad
140 rquotad is an rpc(3N) server which returns quotas for a user of a
141 local file system which is mounted by a remote machine over the NFS.
142 The results are used by quota(1) to display user quotas for remote
143 file systems.
144
145 %description rquotad -l pl
146 rquotad jest serverem rpc(3N), który zwraca quoty u¿ytkownika
147 lokalnego systemu plików, który jest zamountowany przez zdaln± maszynê
148 poprzez NFS. Rezultaty s± u¿ywane przez quota(1), aby wy¶wietliæ quotê
149 dla zdalnego systemu plików.
150
151 %package common
152 Summary:        Common programs for NFS
153 Summary(pl):    Wspólne programy do obs³ugi NFS
154 Group:          Networking
155
156 %description common
157 Common programs for NFS.
158
159 %description common -l pl
160 Wspólne programy do obs³ugi NFS.
161
162 %prep
163 %setup -q -a1
164 %patch0 -p1
165 %patch1 -p1
166 %patch2 -p1
167 %patch3 -p1
168 %patch4 -p1
169 %patch5 -p1
170 %patch6 -p1
171 %patch7 -p1
172
173 chmod u+w configure
174
175 %build
176 %if "%{_lib}" == "lib64"
177 sed -i -e 's#/lib/#/%{_lib}/#g' configure.in
178 %endif
179 sed -i -e 's#libroken.a#libroken.so#g' configure.in
180 %{__autoconf}
181 %configure \
182 %if %{with nfs4}
183         --enable-nfsv4 \
184         --enable-gss \
185         --with-krb5=%{_prefix} \
186 %else
187         --disable-gss \
188         --disable-nfsv4 \
189 %endif
190         --enable-nfsv3 \
191         --enable-secure-statd \
192         --with-statedir=/var/lib/nfs
193 %{__make} all
194
195 %install
196 rm -rf $RPM_BUILD_ROOT
197 install -d $RPM_BUILD_ROOT{/sbin,%{_sbindir},%{_mandir}/man{5,8}} \
198         $RPM_BUILD_ROOT{%{_sysconfdir}/{rc.d/init.d,sysconfig},%{_var}/lib/nfs/rpc_pipefs}
199
200 %{__make} install \
201         install_prefix=$RPM_BUILD_ROOT
202
203 install utils/idmapd/idmapd.conf        $RPM_BUILD_ROOT/etc
204 install tools/rpcdebug/rpcdebug $RPM_BUILD_ROOT/sbin
205 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/nfs
206 install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/nfslock
207 install %{SOURCE4} $RPM_BUILD_ROOT/etc/rc.d/init.d/rquotad
208 install %{SOURCE8} $RPM_BUILD_ROOT/etc/rc.d/init.d/nfsfs
209 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/nfsd
210 install %{SOURCE6} $RPM_BUILD_ROOT/etc/sysconfig/nfslock
211 install %{SOURCE7} $RPM_BUILD_ROOT/etc/sysconfig/rquotad
212
213 > $RPM_BUILD_ROOT%{_var}/lib/nfs/rmtab
214 > $RPM_BUILD_ROOT%{_sysconfdir}/exports
215
216 rm -f $RPM_BUILD_ROOT%{_mandir}/man8/rpc.{mountd,nfsd,rquotad,statd,lockd,gssd,idmapd,svcgssd}.8
217 rm -f $RPM_BUILD_ROOT%{_mandir}/man5/rpc.idmapd.conf.5
218 echo ".so lockd.8"   >  $RPM_BUILD_ROOT%{_mandir}/man8/rpc.lockd.8
219 echo ".so mountd.8"  >  $RPM_BUILD_ROOT%{_mandir}/man8/rpc.mountd.8
220 echo ".so nfsd.8"    >  $RPM_BUILD_ROOT%{_mandir}/man8/rpc.nfsd.8
221 echo ".so rquotad.8" >  $RPM_BUILD_ROOT%{_mandir}/man8/rpc.rquotad.8
222 echo ".so statd.8"   >  $RPM_BUILD_ROOT%{_mandir}/man8/rpc.statd.8
223 %if %{with nfs4}
224 echo ".so gssd.8"    >  $RPM_BUILD_ROOT%{_mandir}/man8/rpc.gssd.8
225 echo ".so idmapd.8"  >  $RPM_BUILD_ROOT%{_mandir}/man8/rpc.idmapd.8
226 echo ".so svcgssd.8" >  $RPM_BUILD_ROOT%{_mandir}/man8/rpc.svcgssd.8
227 echo ".so idmapd.conf.5" > $RPM_BUILD_ROOT%{_mandir}/man5/rpc.idmapd.conf.5
228 %endif
229
230 touch $RPM_BUILD_ROOT/var/lib/nfs/xtab
231
232 ln -sf /bin/true $RPM_BUILD_ROOT/sbin/fsck.nfs
233
234 cp -a nfs nfs-copy
235 mv -f nfs-copy/*.ps ./
236 mv -f nfs-copy html
237
238 %clean
239 rm -rf $RPM_BUILD_ROOT
240
241 %post
242 /sbin/chkconfig --add nfs
243 if [ -r /var/lock/subsys/nfs ]; then
244         /etc/rc.d/init.d/nfs restart >&2
245 else
246         echo "Run \"/etc/rc.d/init.d/nfs start\" to start NFS daemon."
247 fi
248 umask 022
249 sed -e 's/NFSDTYPE=.*/NFSDTYPE=K/' /etc/sysconfig/nfsd > /etc/sysconfig/nfsd.new
250 mv -f /etc/sysconfig/nfsd.new /etc/sysconfig/nfsd
251
252 %preun
253 if [ "$1" = "0" ]; then
254         if [ -r /var/lock/subsys/nfs ]; then
255                 /etc/rc.d/init.d/nfs stop >&2
256         fi
257         /sbin/chkconfig --del nfs
258 fi
259
260 %post clients
261 /sbin/chkconfig --add nfsfs
262 if [ -r /var/lock/subsys/nfsfs ]; then
263         /etc/rc.d/init.d/nfsfs restart >&2
264 else
265         echo "Run \"/etc/rc.d/init.d/nfsfs start\" to mount all NFS volumes."
266 fi
267
268 %preun clients
269 if [ "$1" = "0" ]; then
270         if [ -r /var/lock/subsys/nfsfs ]; then
271                 /etc/rc.d/init.d/nfsfs stop >&2
272         fi
273         /sbin/chkconfig --del nfsfs
274 fi
275
276 %post lock
277 /sbin/chkconfig --add nfslock
278 if [ -r /var/lock/subsys/nfslock ]; then
279         /etc/rc.d/init.d/nfslock restart >&2
280 else
281         echo "Run \"/etc/rc.d/init.d/nfslock start\" to start nfslock daemon."
282 fi
283
284 %preun lock
285 if [ "$1" = "0" ]; then
286         if [ -r /var/lock/subsys/nfslock ]; then
287                 /etc/rc.d/init.d/nfslock stop >&2
288         fi
289         /sbin/chkconfig --del nfslock
290 fi
291
292 %post rquotad
293 /sbin/chkconfig --add rquotad
294 if [ -r /var/lock/subsys/rquotad ]; then
295         /etc/rc.d/init.d/rquotad restart >&2
296 else
297         echo "Run \"/etc/rc.d/init.d/rquotad start\" to start NFS quota daemon."
298 fi
299
300 %preun rquotad
301 if [ "$1" = "0" ]; then
302         if [ -r /var/lock/subsys/rquotad ]; then
303                 /etc/rc.d/init.d/rquotad stop >&2
304         fi
305         /sbin/chkconfig --del rquotad
306 fi
307
308 %files
309 %defattr(644,root,root,755)
310 %doc ChangeLog README *.ps html
311 %attr(755,root,root) /sbin/rpcdebug
312 %attr(755,root,root) /sbin/fsck.nfs
313 %attr(755,root,root) %{_sbindir}/exportfs
314 %attr(755,root,root) %{_sbindir}/rpc.mountd
315 %attr(755,root,root) %{_sbindir}/rpc.nfsd
316 %attr(755,root,root) %{_sbindir}/nfsstat
317 %attr(755,root,root) %{_sbindir}/nhfsgraph
318 %attr(755,root,root) %{_sbindir}/nhfsnums
319 %attr(755,root,root) %{_sbindir}/nhfsrun
320 %attr(755,root,root) %{_sbindir}/nhfsstone
321
322 %attr(754,root,root) /etc/rc.d/init.d/nfs
323
324 %attr(664,root,fileshare) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/exports
325 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/nfsd
326 %config(noreplace) %verify(not md5 mtime size) %{_var}/lib/nfs/xtab
327 %config(noreplace) %verify(not md5 mtime size) %{_var}/lib/nfs/etab
328 %config(noreplace) %verify(not md5 mtime size) %{_var}/lib/nfs/rmtab
329
330 %{_mandir}/man5/exports.5*
331 %{_mandir}/man7/nfsd.7*
332 %{_mandir}/man8/exportfs.8*
333 %{_mandir}/man8/mountd.8*
334 %{_mandir}/man8/nhfsgraph.8*
335 %{_mandir}/man8/nhfsnums.8*
336 %{_mandir}/man8/nhfsrun.8*
337 %{_mandir}/man8/nhfsstone.8*
338 %{_mandir}/man8/nfsd.8*
339 %{_mandir}/man8/nfsstat.8*
340 %{_mandir}/man8/rpc.mountd.8*
341 %{_mandir}/man8/rpc.nfsd.8*
342
343 %if %{with nfs4}
344 %attr(755,root,root) %{_sbindir}/rpc.svcgssd
345 %{_mandir}/man8/*svcgss*
346 %endif
347
348 %files lock
349 %defattr(644,root,root,755)
350 %attr(755,root,root) %{_sbindir}/rpc.lockd
351 %attr(755,root,root) %{_sbindir}/rpc.statd
352 %attr(754,root,root) /etc/rc.d/init.d/nfslock
353 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/nfslock
354 %{_mandir}/man8/rpc.lockd.8*
355 %{_mandir}/man8/lockd.8*
356 %{_mandir}/man8/rpc.statd.8*
357 %{_mandir}/man8/statd.8*
358 %config(noreplace) %verify(not md5 mtime size) %{_var}/lib/nfs/state
359
360 %files clients
361 %defattr(644,root,root,755)
362 %attr(754,root,root) /etc/rc.d/init.d/nfsfs
363 %attr(755,root,root) %{_sbindir}/showmount
364 %{_mandir}/man8/showmount.8*
365
366 %if %{with nfs4}
367 %attr(755,root,root) %{_sbindir}/rpc.gssd
368 %{_mandir}/man8/rpc.gssd*
369 %{_mandir}/man8/gssd*
370 %endif
371
372
373 #%files rquotad
374 #%defattr(644,root,root,755)
375 #%attr(755,root,root) %{_sbindir}/rpc.rquotad
376 #%attr(754,root,root) /etc/rc.d/init.d/rquotad
377 #%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rquotad
378 #%%{_mandir}/man8/rpc.rquotad.8*
379
380 %files common
381 %defattr(644,root,root,755)
382 %attr(755,root,root) %dir %{_var}/lib/nfs
383 %attr(755,root,root) %dir %{_var}/lib/nfs/rpc_pipefs
384 %if %{with nfs4}
385 %attr(755,root,root) %{_sbindir}/rpc.idmapd
386 %attr(660,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/idmapd.conf
387 %{_mandir}/man[58]/*idmap*
388 %endif
This page took 0.058706 seconds and 4 git commands to generate.