]> git.pld-linux.org Git - packages/amanda.git/blob - amanda.spec
- added trivial tapetype.1 man page from Debian
[packages/amanda.git] / amanda.spec
1 # Conditional build:                                                                 
2 # _with_xfs     - without support for xfsdump
3
4 Summary:        A network-capable tape backup solution
5 Summary(pl):    Sieciowo zorientowany system tworzenia kopii zapasowych
6 Name:           amanda
7 Version:        2.4.2p2
8 Release:        15
9 License:        BSD
10 Group:          Networking/Utilities
11 Source0:        http://prdownloads.sourceforge.net/amanda/%{name}-%{version}.tar.gz
12 Source1:        %{name}-srv.crontab
13 Source2:        %{name}.inetd
14 Source3:        %{name}idx.inetd
15 Source4:        amidxtape.inetd
16 Source5:        %{name}.conf
17 Source6:        tapetype.1
18 Patch0:         %{name}-no_libnsl.patch
19 Patch1:         %{name}-am_fixes.patch
20 Patch2:         %{name}-bug18322.patch
21 Patch3:         %{name}-build_tapetype.patch
22 Patch4:         %{name}-no_private_libtool.m4.patch
23 Patch5:         %{name}-ac25x.patch
24 Patch6:         %{name}-chg-zd-mtx-sh.patch
25 URL:            http://www.amanda.org/
26 BuildRequires:  autoconf
27 BuildRequires:  automake
28 BuildRequires:  cpio
29 BuildRequires:  dump
30 %{?_with_xfs:BuildRequires:     xfsdump}
31 BuildRequires:  flex
32 BuildRequires:  gnuplot
33 BuildRequires:  libtool
34 BuildRequires:  readline-devel >= 4.2
35 BuildRequires:  tar
36 BuildRequires:  samba-client
37 Prereq:         /sbin/ldconfig
38 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39
40 %define         _sysconfdir     /etc
41 %define         _localstatedir  /var/lib
42 %define         _libexecdir     %{_libdir}/amanda
43
44 %description
45 AMANDA, the Advanced Maryland Automatic Network Disk Archiver, is a
46 backup system that allows the administrator of a LAN to set up a
47 single master backup server to back up multiple hosts to a single
48 large capacity tape drive. AMANDA uses native dump and/or GNU tar
49 facilities and can back up a large number of workstations running
50 multiple versions of Unix. Newer versions of AMANDA (including this
51 version) can use SAMBA to back up Microsoft(TM) Windows95/NT hosts.
52 The amanda package contains the core AMANDA programs and will need to
53 be installed on both AMANDA clients and AMANDA servers. Note that you
54 will have to install the amanda-client and amanda-server packages as
55 well.
56
57 %description -l pl
58 AMANDA jest sieciowo zorientowanym systemem tworzenia kopii
59 zapasowych. Umo¿liwia administratorowi sieci tworzenie kopii z kilku
60 hostów na jednej maszynie wyposa¿onej w pojemny dysk lub streamer.
61 Nowsze wersje programu umo¿liwiaj± zabezpieczanie zasobów Microsoft
62 Windows 95/98/NT/2000 przy u¿yciu protoko³u Samba. Ten pakiet zawiera
63 podstawowe pliki programu i powinien byæ zainstalowany zarówno na
64 serwerze jak i na kliencie. Pamiêtaj tak¿e o instalacji pakietów
65 amanda-client i amanda-server!
66
67 %package libs
68 Summary:        Amanda shared libraries
69 Summary(pl):    Biblioteki wspó³dzielone pakietu amanda
70 Group:          Networking/Utilities
71 Prereq:         /usr/bin/getgid
72 Prereq:         /bin/id
73 Prereq:         /usr/sbin/groupadd
74 Prereq:         /usr/sbin/useradd
75 Prereq:         /usr/sbin/groupdel
76 Prereq:         /usr/sbin/userdel
77
78 %description libs
79 Amanda shared libraries.
80
81 %description libs -l pl
82 Biblioteki wspó³dzielone pakietu amanda.
83
84 %package client
85 Summary:        The client side of Amanda
86 Summary(pl):    Klient Amandy
87 Group:          Networking/Utilities
88 Prereq:         /sbin/ldconfig
89 Prereq:         rc-inetd
90 Prereq:         %{name}-libs = %{version}
91 Conflicts:      tar < 1.13
92
93 %description client
94 The Amanda-client package should be installed on any machine that will
95 be backed up by AMANDA (including the server if it also needs to be
96 backed up). You will also need to install the amanda package to each
97 AMANDA client. It requires at least one of dump and GNU tar installed.
98
99 %description client -l pl
100 Ten pakiet powinien byæ zainstalowany ma maszynach, z których
101 zawarto¶ci bêd± tworzone kopie zapasowe. Wymaga zainstalowanego co
102 najmniej jednego z pakietów dump i GNU tar.
103
104 %package server
105 Summary:        The server side of Amanda
106 Summary(pl):    Serwer Amandy
107 Group:          Networking/Utilities
108 Prereq:         rc-inetd
109 Prereq:         /sbin/ldconfig
110 Requires:       gnuplot
111 Requires:       crondaemon
112 Requires:       /etc/cron.d
113 Requires:       mt-st
114 Requires:       mtx
115 Prereq:         rc-inetd
116 Prereq:         %{name}-libs = %{version}
117
118 %description server
119 The amanda-server package should be installed on the AMANDA server,
120 the machine attached to the device (such as a tape drive) where
121 backups will be written. You will also need to install the amanda
122 package to the AMANDA server. And, if the server is also to be backed
123 up, the server also needs to have the amanda-client package installed.
124
125 %description server -l pl
126 Ten pakiet powinien byæ zainstalowanych na maszynach, na których bêd±
127 magazynowane kopie zapasowe (lub do których podpiête s± urz±dzenia
128 typu streamer).
129
130 %prep
131 %setup -q
132 %patch0 -p1
133 %patch1 -p1
134 %patch2 -p1
135 %patch3 -p1
136 %patch4 -p1
137 %patch5 -p1
138 %patch6 -p1
139
140 %build
141 libtoolize --copy --force
142 aclocal
143 autoconf
144 touch COPYING
145 rm -f missing
146 automake -a -c -f
147 %configure \
148         --disable-static \
149         --enable-shared \
150         --with-index-server=localhost \
151         --with-user=amanda \
152         --with-group=amanda \
153         --with-tape-device=/dev/null \
154         --with-ftape-rawdevice=/dev/null \
155         --with-changer-device=/dev/null \
156         --with-fqdn \
157         --with-smbclient=%{_bindir}/smbclient \
158         --with-bsd-security \
159         --with-buffered-dump \
160         --with-amandahosts \
161         --with-debugging=%{_localstatedir}/amanda/debug \
162         --with-gnutar-listdir=%{_localstatedir}/amanda/gnutar-lists \
163         --with-tmpdir=/var/tmp
164
165 %{__make}
166
167 %install
168 rm -rf $RPM_BUILD_ROOT
169 install -d $RPM_BUILD_ROOT%{_sysconfdir}/{amanda,cron.d,sysconfig/rc-inetd} \
170         $RPM_BUILD_ROOT%{_localstatedir}/amanda/gnutar-lists \
171         $RPM_BUILD_ROOT%{_mandir}/man1
172
173 %{__make} install \
174         DESTDIR=$RPM_BUILD_ROOT \
175         SETUID_GROUP=`id -g`
176
177 install %{SOURCE1} $RPM_BUILD_ROOT/etc/cron.d/amanda-srv
178 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/amanda
179 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/amandaidx
180 install %{SOURCE4} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/amidxtape
181
182 install %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/amanda
183 install example/*.ps $RPM_BUILD_ROOT%{_localstatedir}/amanda
184 install %{SOURCE6} $RPM_BUILD_ROOT%{_mandir}/man1/tapetype.1
185
186 > $RPM_BUILD_ROOT%{_sysconfdir}/amandates
187
188 gzip -9nf docs/*
189
190 %clean
191 rm -rf $RPM_BUILD_ROOT
192
193 %triggerpostun -- amanda-libs < 2.4.2p2-3
194 /usr/sbin/chsh -s /bin/sh amanda
195
196 %triggerpostun -- amanda-libs < 2.4.2p2-12
197 /usr/sbin/usermod -G disk amanda
198
199 %pre libs
200 if [ -n "`/usr/bin/getgid amanda`" ]; then
201         if [ "`getgid amanda`" != "80" ]; then
202                 echo "Warning: group amanda haven't gid=80. Correct this before installing amanda-libs" 1>&2
203                 exit 1
204         fi
205 else
206         /usr/sbin/groupadd -g 80 -r -f amanda
207 fi
208 if [ -n "`/bin/id -u amanda 2>/dev/null`" ]; then
209         if [ "`/bin/id -u amanda`" != "80" ]; then
210                 echo "Warning: user amanda haven't uid=80. Correct this before installing amanda-libs" 1>&2
211                 exit 1
212         fi
213 else
214         /usr/sbin/useradd -u 80 -G disk -r -d /var/lib/amanda -s /bin/sh -c "Amanda Backup user" -g amanda amanda 1>&2
215 fi
216
217 %post libs -p /sbin/ldconfig
218
219 %postun libs
220 /sbin/ldconfig
221 if [ "$1" = "0" ]; then
222         /usr/sbin/userdel amanda
223         /usr/sbin/groupdel amanda
224 fi
225
226 %post client
227 /sbin/ldconfig
228 if [ -f /var/lock/subsys/rc-inetd ]; then
229         /etc/rc.d/init.d/rc-inetd restart 1>&2
230 else
231         echo "Type \"/etc/rc.d/init.d/rc-inetd start\" to start inet server" 1>&2
232 fi
233
234 %postun client
235 /sbin/ldconfig
236 if [ -f /var/lock/subsys/rc-inetd ]; then
237         /etc/rc.d/init.d/rc-inetd restart
238 fi
239
240 %post server
241 /sbin/ldconfig
242 if [ -f /var/lock/subsys/rc-inetd ]; then
243         /etc/rc.d/init.d/rc-inetd restart 1>&2
244 else
245         echo "Type \"/etc/rc.d/init.d/rc-inetd start\" to start inet server" 1>&2
246 fi
247 echo "Don't forget to edit /etc/cron.d/amanda-srv" 1>&2
248
249 %postun server
250 /sbin/ldconfig
251 if [ -f /var/lock/subsys/rc-inetd ]; then
252         /etc/rc.d/init.d/rc-inetd restart
253 fi
254
255 %files libs
256 %defattr(644,root,root,755)
257 %attr(755,root,root) %{_libdir}/libamanda*.so
258 %attr(755,root,root) %{_libdir}/libamtape*.so
259 %attr(770,root,amanda) %dir %{_libexecdir}
260 %attr(770,root,amanda) %dir %{_localstatedir}/amanda
261
262
263 %files server
264 %defattr(644,root,root,755)
265 %doc docs/*.gz
266 %config(noreplace) /etc/sysconfig/rc-inetd/amidxtape
267 %config(noreplace) /etc/sysconfig/rc-inetd/amandaidx
268
269 %attr(750,amanda,amanda) %dir %{_sysconfdir}/amanda
270 %config(noreplace) %attr(640,amanda,amanda) %{_sysconfdir}/amanda/*
271
272 %attr(664,amanda,amanda) %{_localstatedir}/amanda/*
273
274 %config(noreplace) %attr(640,root,root) /etc/cron.d/amanda-srv
275
276 %attr(755,root,root) %{_libdir}/libamserver*.so
277 %attr(755,root,root) %{_libexecdir}/amindexd
278 %attr(755,root,root) %{_libexecdir}/amtrmidx
279 %attr(755,root,root) %{_libexecdir}/driver
280 %attr(4754,root,amanda) %{_libexecdir}/dumper
281 %attr(4754,root,amanda) %{_libexecdir}/planner
282 %attr(755,root,root) %{_libexecdir}/amcat.awk
283 %attr(755,root,root) %{_libexecdir}/amcleanupdisk
284 %attr(755,root,root) %{_libexecdir}/amidxtaped
285 %attr(755,root,root) %{_libexecdir}/amlogroll
286 %attr(755,root,root) %{_libexecdir}/amplot.awk
287 %attr(755,root,root) %{_libexecdir}/amplot.g
288 %attr(755,root,root) %{_libexecdir}/amplot.gp
289 %attr(755,root,root) %{_libexecdir}/amtrmlog
290 %attr(755,root,root) %{_libexecdir}/chg-chio
291 %attr(755,root,root) %{_libexecdir}/chg-chs
292 %attr(755,root,root) %{_libexecdir}/chg-manual
293 %attr(755,root,root) %{_libexecdir}/chg-mtx
294 %attr(755,root,root) %{_libexecdir}/chg-multi
295 %attr(755,root,root) %{_libexecdir}/chg-rth
296 %attr(755,root,root) %{_libexecdir}/chg-scsi
297 %attr(755,root,root) %{_libexecdir}/chg-zd-mtx
298 %attr(755,root,root) %{_libexecdir}/selfcheck
299 %attr(755,root,root) %{_libexecdir}/taper
300 %attr(755,root,root) %{_sbindir}/amadmin
301 %attr(4754,root,amanda) %{_sbindir}/amcheck
302 %attr(755,root,root) %{_sbindir}/amcheckdb
303 %attr(755,root,root) %{_sbindir}/amcleanup
304 %attr(755,root,root) %{_sbindir}/amdump
305 %attr(755,root,root) %{_sbindir}/amflush
306 %attr(755,root,root) %{_sbindir}/amgetconf
307 %attr(755,root,root) %{_sbindir}/amlabel
308 %attr(755,root,root) %{_sbindir}/amoverview
309 %attr(755,root,root) %{_sbindir}/amplot
310 %attr(755,root,root) %{_sbindir}/amrmtape
311 %attr(755,root,root) %{_sbindir}/amreport
312 %attr(755,root,root) %{_sbindir}/amstatus
313 %attr(755,root,root) %{_sbindir}/amtape
314 %attr(755,root,root) %{_sbindir}/amtoc
315 %attr(755,root,root) %{_sbindir}/amverify
316 %attr(755,root,root) %{_sbindir}/tapetype
317 %{_mandir}/man1/tapetype.1*
318 %{_mandir}/man8/amadmin.8*
319 %{_mandir}/man8/amrmtape.8*
320 %{_mandir}/man8/amtape.8*
321 %{_mandir}/man8/amtoc.8*
322 %{_mandir}/man8/amanda.8*
323 %{_mandir}/man8/amcheck.8*
324 %{_mandir}/man8/amcleanup.8*
325 %{_mandir}/man8/amdump.8*
326 %{_mandir}/man8/amflush.8*
327 %{_mandir}/man8/amlabel.8*
328 %{_mandir}/man8/amplot.8*
329 %{_mandir}/man8/amreport.8*
330 %{_mandir}/man8/amstatus.8*
331
332 %files client
333 %defattr(644,root,root,755)
334 %config(noreplace) /etc/sysconfig/rc-inetd/amanda
335 %attr(664,root,amanda) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/amandates
336 %attr(755,root,root) %{_libdir}/libamclient*.so
337 %attr(755,root,root) %{_libexecdir}/versionsuffix
338 %attr(755,root,root) %{_libexecdir}/amandad
339 %attr(4754,root,amanda) %{_libexecdir}/calcsize
340 %attr(4754,root,amanda) %{_libexecdir}/rundump
341 %attr(4754,root,amanda) %{_libexecdir}/runtar
342 %attr(4754,root,amanda) %{_libexecdir}/selfcheck
343 %attr(755,root,root) %{_libexecdir}/sendbackup
344 %attr(755,root,root) %{_libexecdir}/sendsize
345 %attr(755,root,root) %{_libexecdir}/patch-system
346 %attr(4754,root,amanda) %{_libexecdir}/killpgrp
347 %attr(755,root,root) %{_sbindir}/amrecover
348 %attr(755,root,root) %{_sbindir}/amrestore
349 %attr(770,amanda,amanda) %dir %{_localstatedir}/amanda/gnutar-lists
350 %{_mandir}/man8/amrecover.8*
351 %{_mandir}/man8/amrestore.8*
This page took 0.147141 seconds and 4 git commands to generate.