3 %bcond_without xfs # without (possible) support for xfsdump
4 %bcond_without samba # without smbclient support
5 %bcond_without client # without client package
6 %bcond_without server # without server package
8 Summary: A network-capable tape backup solution
9 Summary(pl.UTF-8): Sieciowo zorientowany system tworzenia kopii zapasowych
14 Group: Networking/Utilities
15 Source0: http://dl.sourceforge.net/amanda/%{name}-%{version}.tar.gz
16 # Source0-md5: c347c1e573c33018f234750ac6435156
17 Source1: %{name}-srv.crontab
18 Source2: %{name}.inetd
19 Source3: %{name}idx.inetd
20 Source4: amidxtape.inetd
21 Patch0: %{name}-no_libnsl.patch
22 Patch1: %{name}-chg-zd-mtx-sh.patch
23 Patch2: %{name}-tar.patch
24 Patch3: %{name}-bashizm.patch
25 Patch4: %{name}-as_needed.patch
26 Patch5: %{name}-tapetypes.patch
27 Patch6: %{name}-FHS.patch
28 URL: http://www.amanda.org/
29 BuildRequires: autoconf >= 2.53
30 BuildRequires: automake
31 BuildRequires: curl-devel
34 BuildRequires: glib2-devel
35 # curl is broken, see curl-config --libs
36 BuildRequires: keyutils-devel
37 BuildRequires: krb5-devel >= 1.6-4
38 BuildRequires: libtool
39 BuildRequires: libxslt-progs
40 BuildRequires: ncurses-devel
41 BuildRequires: openssh-clients
42 BuildRequires: openssl-devel
43 BuildRequires: perl-devel
44 BuildRequires: pkgconfig
45 BuildRequires: readline-devel >= 4.2
46 BuildRequires: rpmbuild(macros) >= 1.268
47 %{?with_samba:BuildRequires: samba-client}
49 %{?with_xfs:BuildRequires: xfsdump}
50 Conflicts: shadow < 1:4.0.4.1-4
51 Conflicts: pwdutils < 3.1.2-2
52 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
55 AMANDA, the Advanced Maryland Automatic Network Disk Archiver, is a
56 backup system that allows the administrator of a LAN to set up a
57 single master backup server to back up multiple hosts to a single
58 large capacity tape drive. AMANDA uses native dump and/or GNU tar
59 facilities and can back up a large number of workstations running
60 multiple versions of Unix. Newer versions of AMANDA (including this
61 version) can use SAMBA to back up Microsoft(TM) Windows95/NT hosts.
62 The amanda package contains the core AMANDA programs and will need to
63 be installed on both AMANDA clients and AMANDA servers. Note that you
64 will have to install the amanda-client and amanda-server packages as
67 %description -l pl.UTF-8
68 AMANDA jest sieciowo zorientowanym systemem tworzenia kopii
69 zapasowych. Umożliwia administratorowi sieci tworzenie kopii z kilku
70 hostów na jednej maszynie wyposażonej w pojemny dysk lub streamer.
71 Nowsze wersje programu umożliwiają zabezpieczanie zasobów Microsoft
72 Windows 95/98/NT/2000 przy użyciu protokołu Samba. Ten pakiet zawiera
73 podstawowe pliki programu i powinien być zainstalowany zarówno na
74 serwerze jak i na kliencie. Pamiętaj także o instalacji pakietów
75 amanda-client i amanda-server!
78 Summary: Amanda shared libraries
79 Summary(pl.UTF-8): Biblioteki współdzielone pakietu amanda
80 Group: Networking/Utilities
81 Requires(postun): /usr/sbin/groupdel
82 Requires(postun): /usr/sbin/userdel
83 Requires(pre): /bin/id
84 Requires(pre): /usr/bin/chsh
85 Requires(pre): /usr/bin/getgid
86 Requires(pre): /usr/sbin/groupadd
87 Requires(pre): /usr/sbin/useradd
88 Provides: group(amanda)
89 Provides: user(amanda)
92 Amanda shared libraries.
94 %description libs -l pl.UTF-8
95 Biblioteki współdzielone pakietu amanda.
98 Summary: The client side of Amanda
99 Summary(pl.UTF-8): Klient Amandy
100 Group: Networking/Utilities
101 Requires: %{name}-libs = %{version}-%{release}
103 Conflicts: tar < 1.13
106 The Amanda-client package should be installed on any machine that will
107 be backed up by AMANDA (including the server if it also needs to be
108 backed up). You will also need to install the amanda package to each
109 AMANDA client. It requires at least one of dump and GNU tar installed.
111 %description client -l pl.UTF-8
112 Ten pakiet powinien być zainstalowany ma maszynach, z których
113 zawartości będą tworzone kopie zapasowe. Wymaga zainstalowanego co
114 najmniej jednego z pakietów dump i GNU tar.
117 Summary: The server side of Amanda
118 Summary(pl.UTF-8): Serwer Amandy
119 Group: Networking/Utilities
120 Requires: %{name}-libs = %{version}-%{release}
121 Requires: /etc/cron.d
133 The amanda-server package should be installed on the AMANDA server,
134 the machine attached to the device (such as a tape drive) where
135 backups will be written. You will also need to install the amanda
136 package to the AMANDA server. And, if the server is also to be backed
137 up, the server also needs to have the amanda-client package installed.
139 %description server -l pl.UTF-8
140 Ten pakiet powinien być zainstalowany na maszynach, na których będą
141 magazynowane kopie zapasowe (lub do których podpięte są urządzenia
145 Summary: Perl bindings for amanda
146 Summary(pl.UTF-8): Wiązania perla dla Amandy
147 Group: Networking/Utilities
148 Requires: %{name}-libs = %{version}-%{release}
151 Perl bindings for amanda.
153 %description perl -l pl.UTF-8
154 Wiązania perla dla Amandy.
157 Summary: Perl bindings for amanda server
158 Summary(pl.UTF-8): Wiązania perla dla serwera Amandy
159 Group: Networking/Utilities
160 Requires: %{name}-perl = %{version}-%{release}
161 Requires: %{name}-server = %{version}-%{release}
163 %description perl-server
164 Perl bindings for amanda server.
166 %description perl-server -l pl.UTF-8
167 Wiązania perla dla serwera Amandy.
181 %{__aclocal} -I config -I config/gettext-macros -I config/gnulib -I config/amanda -I config/macro-archive
186 GNUPLOT=/usr/bin/gnuplot \
192 RESTORE=/sbin/restore \
194 %{?with_xfs:XFSDUMP=/sbin/xfsdump} \
195 %{?with_xfs:XFSRESTORE=/sbin/xfsrestore} \
198 %{!?with_server:--without-server} \
199 %{!?with_client:--without-client} \
200 --with-index-server=localhost \
202 --with-group=amanda \
203 --with-tape-device=/dev/null \
204 --with-ftape-rawdevice=/dev/null \
205 --with-changer-device=/dev/null \
207 %{?with_samba:--with-smbclient=%{_bindir}/smbclient} \
208 --with-bsd-security \
209 --with-ssh-security \
210 --with-krb5-security \
211 --without-krb4-security \
212 --with-buffered-dump \
214 --with-configdir=%{_sysconfdir}/amanda \
215 --with-gnutar-listdir=%{_sharedstatedir}/gnutar-lists \
216 --with-amandates=%{_sharedstatedir}/amanda/amandates \
217 --with-debugging=%{_sharedstatedir}/amanda/debug \
218 --with-tmpdir=/var/tmp \
219 --with-amperldir=%{perl_vendorarch} \
220 --disable-installperms
225 rm -rf $RPM_BUILD_ROOT
226 install -d $RPM_BUILD_ROOT%{_sysconfdir}/{amanda,cron.d,sysconfig/rc-inetd} \
227 $RPM_BUILD_ROOT%{_sharedstatedir}/amanda/gnutar-lists \
228 $RPM_BUILD_ROOT%{_sharedstatedir}/amanda/debug/{amandad,client,server}
231 DESTDIR=$RPM_BUILD_ROOT
233 install %{SOURCE1} $RPM_BUILD_ROOT/etc/cron.d/amanda-srv
234 sed -e 's|/usr/lib|%{_libdir}|' %{SOURCE2} >$RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/amanda
235 sed -e 's|/usr/lib|%{_libdir}|' %{SOURCE3} >$RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/amandaidx
236 sed -e 's|/usr/lib|%{_libdir}|' %{SOURCE4} >$RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/amidxtape
238 install example/amanda.conf $RPM_BUILD_ROOT%{_sysconfdir}/amanda
239 install example/amanda-client.conf $RPM_BUILD_ROOT%{_sysconfdir}/amanda
240 touch $RPM_BUILD_ROOT%{_sharedstatedir}/amanda/.amandahosts
242 > $RPM_BUILD_ROOT%{_sharedstatedir}/amanda/amandates
244 find $RPM_BUILD_ROOT -name \*.la | xargs rm -f
247 rm -rf $RPM_BUILD_ROOT
249 %triggerpostun libs -- %{name}-libs < 2.5.1p2-1
250 echo "Adding amanda to disk and backup groups"
251 /usr/sbin/usermod -G disk,backup amanda
252 echo "Setting amanda shell to /bin/sh"
253 /usr/bin/chsh -s /bin/sh amanda
254 if [ -f %{_sharedstatedir}/amanda/.amandahosts ]; then
255 echo "Fixing permissions of %{_sharedstatedir}/amanda/.amandahosts file"
256 chown amanda:amanda %{_sharedstatedir}/amanda/.amandahosts
257 chmod 600 %{_sharedstatedir}/amanda/.amandahosts
261 %groupadd -P %{name}-libs -g 80 amanda
262 %useradd -P %{name}-libs -u 80 -G disk,backup -d /var/lib/amanda -s /bin/sh -c "Amanda Backup user" -g amanda amanda
265 if [ "$1" = "0" ]; then
271 %service -q rc-inetd reload
274 if [ "$1" = 0 ]; then
275 %service -q rc-inetd reload
279 %service -q rc-inetd reload
280 if [ "$1" = "1" ]; then
281 echo "Don't forget to edit /etc/cron.d/amanda-srv." 1>&2
285 if [ "$1" = 0 ]; then
286 %service -q rc-inetd reload
290 %defattr(644,root,root,755)
291 %doc AUTHORS COPYRIGHT ChangeLog NEWS README ReleaseNotes UPGRADING
292 %attr(755,root,root) %{_libdir}/amanda/libamanda*.so
293 %attr(750,amanda,amanda) %dir %{_sysconfdir}/amanda
294 %dir %{_libdir}/amanda
295 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda
296 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda/debug
297 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda/debug/amandad
298 %attr(600,amanda,amanda) %config(noreplace) %verify(not md5 mtime size) %{_sharedstatedir}/amanda/.amandahosts
302 %defattr(644,root,root,755)
303 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/amidxtape
304 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/amandaidx
306 %config(noreplace) %verify(not md5 mtime size) %attr(640,amanda,amanda) %{_sysconfdir}/amanda/amanda.conf
308 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda/example
309 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda/example/label-templates
310 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda/template.d
311 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda/debug/server
312 %attr(640,amanda,amanda) %{_sharedstatedir}/amanda/example/*amanda*
313 %attr(640,amanda,amanda) %{_sharedstatedir}/amanda/example/label-templates/*.ps
314 %attr(640,amanda,amanda) %{_sharedstatedir}/amanda/template.d/*
316 %config(noreplace) %attr(640,root,root) /etc/cron.d/amanda-srv
318 %dir %{_libdir}/amanda/application
319 %attr(755,root,root) %{_libdir}/amanda/application/amgtar
320 %attr(644,root,root) %{_libdir}/amanda/application/generic-dumper
322 %attr(755,root,root) %{_libdir}/amanda/libamdevice*.so
323 %attr(755,root,root) %{_libdir}/amanda/libamserver*.so
324 %attr(755,root,root) %{_libdir}/amanda/libamtape*.so
325 %attr(755,root,root) %{_libdir}/amanda/librestore*.so
327 %{_libdir}/amanda/amanda-sh-lib.sh
328 %attr(755,root,root) %{_libdir}/amanda/amcat.awk
329 %attr(755,root,root) %{_libdir}/amanda/amcleanupdisk
330 %attr(755,root,root) %{_libdir}/amanda/amidxtaped
331 %attr(755,root,root) %{_libdir}/amanda/amindexd
332 %attr(755,root,root) %{_libdir}/amanda/amlogroll
333 %attr(755,root,root) %{_libdir}/amanda/amplot.awk
334 %attr(755,root,root) %{_libdir}/amanda/amplot.g
335 %attr(755,root,root) %{_libdir}/amanda/amplot.gp
336 %attr(755,root,root) %{_libdir}/amanda/amtrmidx
337 %attr(755,root,root) %{_libdir}/amanda/amtrmlog
338 %attr(755,root,root) %{_libdir}/amanda/chg-chio
339 %attr(755,root,root) %{_libdir}/amanda/chg-chs
340 %attr(755,root,root) %{_libdir}/amanda/chg-disk
341 %attr(755,root,root) %{_libdir}/amanda/chg-iomega
342 %attr(755,root,root) %{_libdir}/amanda/chg-juke
343 %attr(755,root,root) %{_libdir}/amanda/chg-lib.sh
344 %attr(755,root,root) %{_libdir}/amanda/chg-manual
345 %attr(755,root,root) %{_libdir}/amanda/chg-mcutil
346 %attr(755,root,root) %{_libdir}/amanda/chg-mtx
347 %attr(755,root,root) %{_libdir}/amanda/chg-multi
348 %attr(755,root,root) %{_libdir}/amanda/chg-null
349 %attr(755,root,root) %{_libdir}/amanda/chg-rait
350 %attr(755,root,root) %{_libdir}/amanda/chg-rth
351 %attr(755,root,root) %{_libdir}/amanda/chg-scsi
352 %attr(755,root,root) %{_libdir}/amanda/chg-zd-mtx
353 %attr(755,root,root) %{_libdir}/amanda/chunker
354 %attr(755,root,root) %{_libdir}/amanda/driver
355 %attr(4750,root,amanda) %{_libdir}/amanda/dumper
356 %attr(755,root,root) %{_libdir}/amanda/patch-system
357 %attr(4750,root,amanda) %{_libdir}/amanda/planner
358 %attr(755,root,root) %{_libdir}/amanda/taper
360 %attr(755,root,root) %{_sbindir}/amaddclient
361 %attr(755,root,root) %{_sbindir}/amadmin
362 %attr(755,root,root) %{_sbindir}/amaespipe
363 %attr(4750,root,amanda) %{_sbindir}/amcheck
364 %attr(755,root,root) %{_sbindir}/amcheckdb
365 %attr(755,root,root) %{_sbindir}/amcheckdump
366 %attr(755,root,root) %{_sbindir}/amcleanup
367 %attr(755,root,root) %{_sbindir}/amcrypt*
368 %attr(755,root,root) %{_sbindir}/amdd
369 %attr(755,root,root) %{_sbindir}/amdevcheck
370 %attr(755,root,root) %{_sbindir}/amdump
371 %attr(755,root,root) %{_sbindir}/amfetchdump
372 %attr(755,root,root) %{_sbindir}/amflush
373 %attr(755,root,root) %{_sbindir}/amgetconf
374 %attr(755,root,root) %{_sbindir}/amgpgcrypt
375 %attr(755,root,root) %{_sbindir}/amlabel
376 %attr(755,root,root) %{_sbindir}/ammt
377 %attr(755,root,root) %{_sbindir}/amoverview
378 %attr(755,root,root) %{_sbindir}/amplot
379 %attr(755,root,root) %{_sbindir}/amreport
380 %attr(755,root,root) %{_sbindir}/amrestore
381 %attr(755,root,root) %{_sbindir}/amrmtape
382 %attr(755,root,root) %{_sbindir}/amserverconfig
383 %attr(755,root,root) %{_sbindir}/amstatus
384 %attr(755,root,root) %{_sbindir}/amtape
385 %attr(755,root,root) %{_sbindir}/amtapetype
386 %attr(755,root,root) %{_sbindir}/amtoc
387 %attr(755,root,root) %{_sbindir}/amverify
388 %attr(755,root,root) %{_sbindir}/amverifyrun
389 %{_mandir}/man5/amanda.conf.5*
390 %{_mandir}/man8/amaddclient.8*
391 %{_mandir}/man8/amadmin.8*
392 %{_mandir}/man8/amaespipe.8*
393 %{_mandir}/man8/amanda.8*
394 %{_mandir}/man8/amcheck.8*
395 %{_mandir}/man8/amcheckdb.8*
396 %{_mandir}/man8/amcheckdump.8*
397 %{_mandir}/man8/amcleanup.8*
398 %{_mandir}/man8/amcrypt*.8*
399 %{_mandir}/man8/amdd.8*
400 %{_mandir}/man8/amdevcheck.8*
401 %{_mandir}/man8/amdump.8*
402 %{_mandir}/man8/amfetchdump.8*
403 %{_mandir}/man8/amflush.8*
404 %{_mandir}/man8/amgetconf.8*
405 %{_mandir}/man8/amgpgcrypt.8*
406 %{_mandir}/man8/amlabel.8*
407 %{_mandir}/man8/ammt.8*
408 %{_mandir}/man8/amoverview.8*
409 %{_mandir}/man8/amplot.8*
410 %{_mandir}/man8/amreport.8*
411 %{_mandir}/man8/amrestore.8*
412 %{_mandir}/man8/amrmtape.8*
413 %{_mandir}/man8/amserverconfig.8*
414 %{_mandir}/man8/amstatus.8*
415 %{_mandir}/man8/amtape.8*
416 %{_mandir}/man8/amtapetype.8*
417 %{_mandir}/man8/amtoc.8*
418 %{_mandir}/man8/amverify.8*
419 %{_mandir}/man8/amverifyrun.8*
424 %defattr(644,root,root,755)
425 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/amanda
426 %config(noreplace) %verify(not md5 mtime size) %attr(640,root,amanda) %{_sysconfdir}/amanda/amanda-client.conf
427 %attr(640,amanda,amanda) %config(noreplace) %verify(not md5 mtime size) %{_sharedstatedir}/amanda/amandates
428 %attr(755,root,root) %{_libdir}/amanda/libamclient*.so
429 %attr(755,root,root) %{_libdir}/amanda/amandad
430 %attr(755,root,root) %{_libdir}/amanda/noop
431 %attr(755,root,root) %{_libdir}/amanda/sendbackup
432 %attr(755,root,root) %{_libdir}/amanda/sendsize
433 %attr(755,root,root) %{_libdir}/amanda/versionsuffix
434 %attr(4750,root,amanda) %{_libdir}/amanda/calcsize
435 %attr(4750,root,amanda) %{_libdir}/amanda/killpgrp
436 %attr(4750,root,amanda) %{_libdir}/amanda/rundump
437 %attr(4750,root,amanda) %{_libdir}/amanda/runtar
438 %attr(755,root,root) %{_libdir}/amanda/selfcheck
439 %attr(755,root,root) %{_sbindir}/amoldrecover
440 %attr(755,root,root) %{_sbindir}/amrecover
441 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda/gnutar-lists
442 %attr(750,amanda,amanda) %dir %{_sharedstatedir}/amanda/debug/client
443 %{_mandir}/man5/amanda-client.conf.5*
444 %{_mandir}/man8/amrecover.8*
448 %defattr(644,root,root,755)
449 %attr(755,root,root) %{_libdir}/amanda/libamglue*.so
450 %dir %{perl_vendorarch}/Amanda
451 %{perl_vendorarch}/Amanda/Config.pm
452 %{perl_vendorarch}/Amanda/Debug.pm
453 %{perl_vendorarch}/Amanda/Paths.pm
454 %{perl_vendorarch}/Amanda/Types.pm
455 %{perl_vendorarch}/Amanda/Util.pm
456 %dir %{perl_vendorarch}/auto/Amanda
457 %dir %{perl_vendorarch}/auto/Amanda/Config
458 %dir %{perl_vendorarch}/auto/Amanda/Debug
459 %dir %{perl_vendorarch}/auto/Amanda/Types
460 %dir %{perl_vendorarch}/auto/Amanda/Util
461 %attr(755,root,root) %{perl_vendorarch}/auto/Amanda/Config/*.so
462 %attr(755,root,root) %{perl_vendorarch}/auto/Amanda/Debug/*.so
463 %attr(755,root,root) %{perl_vendorarch}/auto/Amanda/Types/*.so
464 %attr(755,root,root) %{perl_vendorarch}/auto/Amanda/Util/*.so
467 %defattr(644,root,root,755)
468 %{perl_vendorarch}/Amanda/Changer.pm
469 %{perl_vendorarch}/Amanda/Cmdline.pm
470 %{perl_vendorarch}/Amanda/Device.pm
471 %{perl_vendorarch}/Amanda/Logfile.pm
472 %{perl_vendorarch}/Amanda/Tapefile.pm
473 %dir %{perl_vendorarch}/auto/Amanda/Cmdline
474 %dir %{perl_vendorarch}/auto/Amanda/Device
475 %dir %{perl_vendorarch}/auto/Amanda/Logfile
476 %dir %{perl_vendorarch}/auto/Amanda/Tapefile
477 %attr(755,root,root) %{perl_vendorarch}/auto/Amanda/Cmdline/*.so
478 %attr(755,root,root) %{perl_vendorarch}/auto/Amanda/Device/*.so
479 %attr(755,root,root) %{perl_vendorarch}/auto/Amanda/Logfile/*.so
480 %attr(755,root,root) %{perl_vendorarch}/auto/Amanda/Tapefile/*.so