]> git.pld-linux.org Git - packages/bacula.git/blame - bacula.spec
Downloads URL changed
[packages/bacula.git] / bacula.spec
CommitLineData
237bfacd 1# TODO:
b0473ed3 2# - update desktop files, think about su-wrappers for console (with .desktop files)
2007449a 3# - fix log file permissions
21838166 4# - check on upgrade (5.0 and 5.2 databases are NOT compatible)
2b68b0cb 5#
f2527d22 6# Conditional build:
6d11b02b 7%bcond_without console_wx # wx-console program
12eebbf8
ER
8%if "%{pld_release}" == "ac"
9%bcond_with bat # bat Qt4 GUI
10%else
6d11b02b 11%bcond_without bat # bat Qt4 GUI
12eebbf8 12%endif
41bc1b6e
JK
13%bcond_without mysql # use MySQL
14%bcond_without pgsql # use PostgreSQL
41bc1b6e 15%bcond_without sqlite3 # use SQLite3
051f919c 16%bcond_without python # Python Scripting support, http://www.bacula.org/3.0.x-manuals/en/concepts/concepts/Python_Scripting.html
819cd4b0 17%bcond_without nagios # build nagios plugin
e979c70d 18%bcond_with rescue
6d11b02b 19%bcond_with sqlite3_sync_off # makes SQLite3 backend much faster, but less reliable
0eba139b 20
8ba087a4 21%if %{without sqlite3}
aeaed87e 22%undefine with_sqlite3_sync_off
23%endif
0eba139b 24
95ed03d9 25%define qtver 4.6.2
bb6e7dc5 26Summary: Bacula - The Network Backup Solution
6a00efc0 27Summary(pl.UTF-8): Bacula - rozwiązanie do wykonywania kopii zapasowych po sieci
bb6e7dc5 28Name: bacula
8edc54f3
AZ
29Version: 5.2.12
30Release: 1
ccb5f851 31License: AGPL v3
52504a6d 32Group: Networking/Utilities
71a8c088 33Source0: http://downloads.sourceforge.net/bacula/%{name}-%{version}.tar.gz
8edc54f3 34# Source0-md5: b04c22b128b73359e4bbc9de06652c38
71a8c088 35Source1: http://downloads.sourceforge.net/bacula/%{name}-docs-%{version}.tar.bz2
8edc54f3 36# Source1-md5: 909b85db6da2dbe6b1099688ad4ec7c3
71a8c088 37Source2: http://downloads.sourceforge.net/bacula/%{name}-rescue-5.0.1.tar.gz
7ed9cb8e 38# Source2-md5: bb194aed8e204f54bf2f61d7e721f257
5ce18635
AM
39Source10: %{name}-dir.init
40Source11: %{name}-fd.init
41Source12: %{name}-sd.init
42Source13: %{name}.logrotate
4280e495
JK
43Source14: %{name}-dir.sysconfig
44Source15: %{name}-fd.sysconfig
45Source16: %{name}-sd.sysconfig
b6e1a6b6
JK
46Source17: %{name}-dir.service
47Source18: %{name}-fd.service
48Source19: %{name}-sd.service
0a03f92d 49Patch0: %{name}-mtx-changer.patch
53a3431c
AM
50Patch1: %{name}-branding.patch
51Patch2: %{name}-conf.patch
52Patch3: %{name}-desktop.patch
53Patch4: make_catalog_backup-setup-home.patch
cec96a88 54Patch5: %{name}-wx-console-build.patch
bb6e7dc5 55URL: http://www.bacula.org/
0819f86f 56BuildRequires: acl-devel
57BuildRequires: autoconf
f2337569 58BuildRequires: automake
0819f86f 59BuildRequires: gettext-devel
f8f434ba 60%{?with_console_wx:BuildRequires: gtk+2-devel}
0819f86f 61BuildRequires: libcap-devel
2ddca527 62BuildRequires: libtool >= 2:2.2
7425cb9d
JK
63%if %{with rescue}
64BuildRequires: fakeroot
65%endif
f183f7ef 66BuildRequires: libwrap-devel
cc01862b 67BuildRequires: ncurses-devel
bb6e7dc5
AM
68BuildRequires: openssl-devel
69BuildRequires: pkgconfig
7425cb9d 70%if %{with python}
e979c70d 71BuildRequires: python-devel
b403dd64 72BuildRequires: python-modules
7425cb9d 73%endif
c19580f6 74%if %{with bat}
304bb97e 75BuildRequires: QtCore-devel
e3dd858d 76BuildRequires: QtGui-devel
95ed03d9
ER
77BuildRequires: qt4-build >= %{qtver}
78BuildRequires: qt4-qmake >= %{qtver}
c19580f6 79%endif
4c7199dc
SP
80%{?with_mysql:BuildRequires: mysql-devel}
81%{?with_pgsql:BuildRequires: postgresql-devel}
bb6e7dc5 82BuildRequires: readline-devel
12eebbf8 83BuildRequires: rpm >= 4.4.9-56
b403dd64 84BuildRequires: rpm-pythonprov
b6e1a6b6 85BuildRequires: rpmbuild(macros) >= 1.644
cc01862b 86BuildRequires: sed >= 4.0
6d11b02b 87%{?with_sqlite3:BuildRequires: sqlite3-devel}
b6e1a6b6 88Requires: systemd-units >= 38
b403dd64 89BuildRequires: which
1376b552 90%if %{with console_wx}
7425cb9d 91BuildRequires: wxGTK2-unicode-devel >= 2.4.0
1376b552 92%endif
bb6e7dc5 93BuildRequires: zlib-devel
bb6e7dc5
AM
94BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
95
d5e827d3 96%define _sysconfdir /etc/%{name}
1a72afd2 97%define _localstatedir /var/lib/%{name}
d5e827d3 98%define nagiosplugindir %{_libdir}/nagios/plugins
bb6e7dc5 99
b8003eec 100# from 'the worst' to 'the best'
53a3431c 101%define databases %{?with_sqlite3:sqlite3} %{?with_mysql:mysql} %{?with_pgsql:postgresql}
41bc1b6e 102
b60fe5cb
ER
103# dependency section is broken. ccache usage is instead to makefiles
104%undefine with_ccache
105
bb6e7dc5
AM
106%description
107Bacula - It comes by night and sucks the vital essence from your
108computers.
109
110Bacula is a set of computer programs that permit you (or the system
111administrator) to manage backup, recovery, and verification of
112computer data across a network of computers of different kinds. In
113technical terms, it is a network client/server based backup program.
114Bacula is relatively easy to use and efficient, while offering many
115advanced storage management features that make it easy to find and
5ce18635 116recover lost or damaged files.
bb6e7dc5 117
192fbfcf
JR
118%description -l pl.UTF-8
119Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
cc01862b 120
192fbfcf
JR
121Bacula to zbiór programów umożliwiających administratorowi na
122zarządzanie kopiami zapasowymi, odzyskiwaniem i weryfikacją danych w
168306e6
ER
123sieci komputerów różnego rodzaju. W terminologii technicznej jest to
124program do kopii zapasowych pracujący w architekturze klient-serwer.
125Bacula jest stosunkowo łatwa w użyciu i wydajna, oferując przy tym
126wiele zaawansowanych możliwości przy zarządzaniu nośnikami,
127ułatwiających znalezienie i odzyskanie utraconych lub uszkodzonych
128plików.
cc01862b 129
5ce18635
AM
130%package common
131Summary: Common files for bacula package
6a00efc0 132Summary(pl.UTF-8): Pliki wspólne dla pakietu bacula
bb6e7dc5 133Group: Networking/Utilities
237bfacd
JK
134Requires(post): openssl-tools
135Requires(post): sed >= 4.0
1bd568e8 136Requires(post,preun): /sbin/chkconfig
65253ffd
JK
137Requires(postun): /usr/sbin/groupdel
138Requires(postun): /usr/sbin/userdel
1b0a2248 139Requires(pre): /usr/sbin/groupadd
140Requires(pre): /usr/sbin/useradd
abdcd1c5
JB
141Conflicts: bacula-console < 0:1.34.6
142Conflicts: bacula-dir < 0:1.34.6
143Conflicts: bacula-fd < 0:1.34.6
144Conflicts: bacula-sd < 0:1.34.6
5c4729e7 145Conflicts: logrotate < 3.8.0
bb6e7dc5 146
5ce18635 147%description common
bb6e7dc5
AM
148Bacula - It comes by night and sucks the vital essence from your
149computers.
150
151Bacula is a set of computer programs that permit you (or the system
152administrator) to manage backup, recovery, and verification of
153computer data across a network of computers of different kinds. In
154technical terms, it is a network client/server based backup program.
155Bacula is relatively easy to use and efficient, while offering many
156advanced storage management features that make it easy to find and
5ce18635 157recover lost or damaged files.
bb6e7dc5 158
192fbfcf
JR
159%description common -l pl.UTF-8
160Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
cc01862b 161
192fbfcf
JR
162Bacula to zbiór programów umożliwiających administratorowi na
163zarządzanie kopiami zapasowymi, odzyskiwaniem i weryfikacją danych w
168306e6
ER
164sieci komputerów różnego rodzaju. W terminologii technicznej jest to
165program do kopii zapasowych pracujący w architekturze klient-serwer.
166Bacula jest stosunkowo łatwa w użyciu i wydajna, oferując przy tym
167wiele zaawansowanych możliwości przy zarządzaniu nośnikami,
168ułatwiających znalezienie i odzyskanie utraconych lub uszkodzonych
169plików.
cc01862b 170
5ce18635
AM
171%package dir
172Summary: Bacula Director and Catalog services
6a00efc0 173Summary(pl.UTF-8): Usługi Bacula Director i Catalog
5ce18635 174Group: Networking/Utilities
237bfacd 175Requires(post): sed >= 4.0
74c2ad1c
ER
176Requires: %{name}-common = %{version}-%{release}
177Requires: bacula(db) = %{version}-%{release}
abdcd1c5 178Obsoletes: bacula-updatedb
bb6e7dc5 179
5ce18635
AM
180%description dir
181Bacula - It comes by night and sucks the vital essence from your
182computers.
183
184Bacula Director is the program that supervises all the backup,
185restore, verify and archive operations. The system administrator uses
186the Bacula Director to schedule backups and to recover files. Catalog
187services are comprised of the software programs responsible for
188maintaining the file indexes and volume databases for all files backed
189up. The Catalog services permit the System Administrator or user to
190quickly locate and restore any desired file, since it maintains a
7533d19f 191record of all Volumes used, all Jobs run, and all Files saved.
5ce18635 192
192fbfcf
JR
193%description dir -l pl.UTF-8
194Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
cc01862b 195
192fbfcf 196Bacula Director to program nadzorujący wszystkie operacje wykonywania
cc01862b 197kopii zapasowych, odzyskiwania, weryfikacji i archiwizowania.
192fbfcf
JR
198Administrator używa Bacula Directora do szeregowania kopii zapasowych
199oraz odzyskiwania plików. Usługi katalogowe (Catalog services) są
168306e6
ER
200używane przez programy odpowiedzialne za zarządzanie indeksami plików
201i bazą danych wolumenów dla wszystkich kopiowanych plików. Usługi
202katalogowe umożliwiają administratorowi lub użytkownikowi szybko
203zlokalizować i odtworzyć dowolny plik, ponieważ utrzymują rekord ze
204wszystkimi używanymi wolumenami, uruchomionymi zadaniami i zapisanymi
205plikami.
cc01862b 206
5ce18635
AM
207%package console
208Summary: Bacula Console
6a00efc0 209Summary(pl.UTF-8): Konsola Baculi
5ce18635 210Group: Networking/Utilities
237bfacd 211Requires(post): sed >= 4.0
74c2ad1c 212Requires: %{name}-common = %{version}-%{release}
5ce18635
AM
213
214%description console
215Bacula - It comes by night and sucks the vital essence from your
216computers.
217
218Bacula Console is the program that allows the administrator or user to
219communicate with the Bacula Director. This is the text only console
220interface.
221
192fbfcf
JR
222%description console -l pl.UTF-8
223Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
cc01862b 224
192fbfcf
JR
225Bacula Console to program umożliwiający administratorowi lub
226użytkownikowi komunikowanie się z programem Bacula Director. To jest
cc01862b
JB
227interfejs czysto tekstowy.
228
5ce18635 229%package console-wx
cc01862b 230Summary: Bacula wxWidgets Console
6a00efc0 231Summary(pl.UTF-8): Konsola Baculi oparta na wxWidgets
5ce18635 232Group: Networking/Utilities
237bfacd 233Requires(post): sed >= 4.0
74c2ad1c 234Requires: %{name}-common = %{version}-%{release}
5ce18635
AM
235
236%description console-wx
237Bacula - It comes by night and sucks the vital essence from your
238computers.
239
240Bacula Console is the program that allows the administrator or user to
cc01862b 241communicate with the Bacula Director. This is the wxWidgets GUI
5ce18635
AM
242interface.
243
192fbfcf
JR
244%description console-wx -l pl.UTF-8
245Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
cc01862b 246
192fbfcf
JR
247Bacula Console to program umożliwiający administratorowi lub
248użytkownikowi komunikowanie się z programem Bacula Director. To jest
cc01862b
JB
249interfejs graficzny oparty na wxWidgets.
250
304bb97e 251%package console-qt4
ece2f4c3
JB
252Summary: Bacula Qt4 Console
253Summary(pl.UTF-8): Konsola Baculi oparta na Qt4
304bb97e
AM
254Group: Networking/Utilities
255Requires(post): sed >= 4.0
74c2ad1c 256Requires: %{name}-common = %{version}-%{release}
12eebbf8 257Requires: QtCore >= %{qtver}
304bb97e
AM
258
259%description console-qt4
260Bacula - It comes by night and sucks the vital essence from your
261computers.
262
263Bacula Console is the program that allows the administrator or user to
ece2f4c3 264communicate with the Bacula Director. This is the Qt4 GUI interface.
304bb97e
AM
265
266%description console-qt4 -l pl.UTF-8
267Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
268
269Bacula Console to program umożliwiający administratorowi lub
270użytkownikowi komunikowanie się z programem Bacula Director. To jest
ece2f4c3 271interfejs graficzny oparty na Qt4.
304bb97e 272
237bfacd
JK
273%package tray-monitor
274Summary: Bacula Tray Monitor
275Group: Networking/Utilities
237bfacd 276Requires(post): sed >= 4.0
74c2ad1c 277Requires: %{name}-common = %{version}-%{release}
237bfacd
JK
278
279%description tray-monitor
280Bacula - It comes by night and sucks the vital essence from your
281computers.
282
1b0a2248 283The Monitor program is typically an icon in the system tray. However,
284once the icon is expanded into a full window, the administrator or
285user can obtain status information about the Director or the backup
286status on the local workstation or any other Bacula daemon that is
287configured.
237bfacd 288
5ce18635
AM
289%package fd
290Summary: Bacula File services (Client)
6a00efc0 291Summary(pl.UTF-8): Usługi Bacula File (klient)
5ce18635 292Group: Networking/Utilities
237bfacd 293Requires(post): sed >= 4.0
74c2ad1c 294Requires: %{name}-common = %{version}-%{release}
5ce18635
AM
295
296%description fd
297Bacula - It comes by night and sucks the vital essence from your
298computers.
299
300Bacula File services (or Client program) is the software program that
301is installed on the machine to be backed up. It is specific to the
302operating system on which it runs and is responsible for providing the
303file attributes and data when requested by the Director. The File
304services are also responsible for the file system dependent part of
305restoring the file attributes and data during a recovery operation.
306This program runs as a daemon on the machine to be backed up, and in
307some of the documentation, the File daemon is referred to as the
308Client (for example in Bacula configuration file).
309
192fbfcf
JR
310%description fd -l pl.UTF-8
311Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
312
168306e6
ER
313Usługi Bacula File (inaczej program kliencki) to oprogramowanie, które
314instaluje się na maszynach, z których mają być wykonywane kopie
315zapasowe. Są one specyficzne dla systemu operacyjnego, pod którym
316działa dana maszyna i odpowiadają za dostarczanie atrybutów i danych
317plików na żądanie Directora. Usługi plikowe są także odpowiedzialne za
318zależną od systemu plików część odzyskiwania atrybutów i danych plików
319podczas operacji odzyskiwania danych. Program działa jako demon na
320maszynie, która ma być backupowana i w części dokumentacji demon ten
321(File) jest nazywany klientem (na przykład w pliku konfiguracyjnym
322Baculi).
cc01862b 323
5ce18635
AM
324%package sd
325Summary: Bacula Storage services
6a00efc0 326Summary(pl.UTF-8): Usługi Bacula Storage
5ce18635 327Group: Networking/Utilities
237bfacd 328Requires(post): sed >= 4.0
74c2ad1c 329Requires: %{name}-common = %{version}-%{release}
329073aa 330Conflicts: dvd+rw-tools <= 5.21.4.10.8-1
5ce18635
AM
331
332%description sd
333Bacula - It comes by night and sucks the vital essence from your
334computers.
335
336Bacula Storage services consist of the software programs that perform
337the storage and recovery of the file attributes and data to the
338physical backup media or volumes. In other words, the Storage daemon
339is responsible for reading and writing your tapes (or other storage
340media, e.g. files). The Storage services runs as a daemon on the
341machine that has the backup device (usually a tape drive).
bb6e7dc5 342
192fbfcf
JR
343%description sd -l pl.UTF-8
344Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
cc01862b 345
192fbfcf
JR
346Usługi Bacula Storage składają się z programów obsługujących
347przechowywanie danych oraz odzyskiwanie atrybutów i danych na
168306e6
ER
348fizycznych nośnikach lub wolumenach. Innymi słowy, demon Storage jest
349odpowiedzialny za odczyt i zapis taśm (lub innych nośników do
350przechowywania danych, np. plików). Usługi Storage działają jako demon
351na maszynie, która zawiera urządzenie backupowe (zwykle napęd
192fbfcf 352taśmowy).
cc01862b 353
41bc1b6e
JK
354%package db-postgresql
355Summary: PostgreSQL database driver for Bacula
356Summary(pl.UTF-8): Sterownik bazy PostgreSQL dla Baculi
357Group: Networking/Utilities
358Requires(post): /sbin/ldconfig
74c2ad1c
ER
359Requires: %{name}-common = %{version}-%{release}
360Provides: bacula(db) = %{version}-%{release}
168306e6 361Obsoletes: bacula(db)
41bc1b6e
JK
362
363%description db-postgresql
364PostgreSQL database driver for Bacula.
365
366%description db-postgresql -l pl.UTF-8
367Sterownik bazy PostgreSQL dla Baculi.
368
369%package db-mysql
370Summary: MySQL database driver for Bacula
371Summary(pl.UTF-8): Sterownik bazy MySQL dla Baculi
372Group: Networking/Utilities
373Requires(post): /sbin/ldconfig
74c2ad1c
ER
374Requires: %{name}-common = %{version}-%{release}
375Provides: bacula(db) = %{version}-%{release}
168306e6 376Obsoletes: bacula(db)
41bc1b6e
JK
377
378%description db-mysql
379MySQL database driver for Bacula.
380
381%description db-mysql -l pl.UTF-8
382Sterownik bazy MySQL dla Baculi.
383
384%package db-sqlite3
385Summary: SQLite database driver for Bacula
386Summary(pl.UTF-8): Sterownik bazy SQLite dla Baculi
387Group: Networking/Utilities
388Requires(post): /sbin/ldconfig
74c2ad1c
ER
389Requires: %{name}-common = %{version}-%{release}
390Provides: bacula(db) = %{version}-%{release}
168306e6 391Obsoletes: bacula(db)
41bc1b6e
JK
392
393%description db-sqlite3
394SQLite database driver for Bacula.
395
396%description db-sqlite3 -l pl.UTF-8
397Sterownik bazy SQLite dla Baculi.
398
5ce18635 399%package rescue
bb6e7dc5 400Summary: Bacula - The Network Backup Solution
6a00efc0 401Summary(pl.UTF-8): Bacula - rozwiązanie do wykonywania kopii zapasowych po sieci
bb6e7dc5 402Group: Networking/Utilities
74c2ad1c 403Requires: %{name}-fd = %{version}-%{release}
bb6e7dc5
AM
404Requires: coreutils
405Requires: util-linux
bb6e7dc5
AM
406
407%description rescue
408Bacula - It comes by night and sucks the vital essence from your
409computers.
410
411Bacula is a set of computer programs that permit you (or the system
412administrator) to manage backup, recovery, and verification of
413computer data across a network of computers of different kinds. In
414technical terms, it is a network client/server based backup program.
415Bacula is relatively easy to use and efficient, while offering many
416advanced storage management features that make it easy to find and
cc01862b 417recover lost or damaged files.
bb6e7dc5
AM
418
419This package installs scripts for disaster recovery and builds rescue
1b0a2248 420floppy disk for bare metal recovery.
237bfacd 421
192fbfcf
JR
422%description rescue -l pl.UTF-8
423Bacula - przychodzi nocą i wysysa żywotny ekstrakt z komputerów.
cc01862b 424
192fbfcf
JR
425Bacula to zbiór programów umożliwiających administratorowi na
426zarządzanie kopiami zapasowymi, odzyskiwaniem i weryfikacją danych w
168306e6
ER
427sieci komputerów różnego rodzaju. W terminologii technicznej jest to
428program do kopii zapasowych pracujący w architekturze klient-serwer.
429Bacula jest stosunkowo łatwa w użyciu i wydajna, oferując przy tym
430wiele zaawansowanych możliwości przy zarządzaniu nośnikami,
431ułatwiających znalezienie i odzyskanie utraconych lub uszkodzonych
432plików.
433
434Ten pakiet zawiera skrypty do odtwarzania po awarii i tworzy dyskietkę
435ratunkowe do odtwarzania systemu od zera.
bb6e7dc5 436
b0473ed3
ER
437%package -n nagios-plugin-check_bacula
438Summary: Nagios plugin to check bacula
439Group: Networking
440Requires: nagios-common
441
442%description -n nagios-plugin-check_bacula
443Nagios plugin to check bacula.
444
77ce6669
AM
445# provided by various db libraries as a symlink
446%define _noautoreq libbaccats-%{version}.so
447
bb6e7dc5 448%prep
7425cb9d 449%setup -q -a 1
0a03f92d 450%patch0 -p1
53a3431c 451%patch1 -p1
cf0cfe65 452%patch2 -p1
ecb9bab1 453%patch3 -p1
e740cd49 454%patch4 -p1
cec96a88 455%patch5 -p1
aa6db71e 456
783dd8b1 457tar -xf %{SOURCE2} && ln -s bacula-rescue-* rescue
cf50297e 458
10650249
AM
459sed -i -e 's#bindir=.*#bindir=%{_bindir}#g' \
460 src/cats/create_* src/cats/delete_* src/cats/drop_* \
461 src/cats/grant_* src/cats/make_* src/cats/update_*
237bfacd 462sed -i -e 's/@hostname@/--hostname--/' src/*/*.conf.in
efb15923 463sed -i -e 's/@basename@/--hostname--/' src/*/*.conf.in
bb6e7dc5
AM
464
465%build
4a39c080
ER
466cd autoconf
467%{__aclocal} -I bacula-macros -I gettext-macros
468# $BUILD_DIR not seen by libtoolize, export it
469BUILD_DIR=.. %{__libtoolize}
470cd ..
cf50297e
AM
471%{__autoconf} --prepend-include=$(pwd)/autoconf autoconf/configure.in > configure
472
dae3a0bd
JK
473CPPFLAGS="-I/usr/include/ncurses -I%{_includedir}/readline"
474
53a3431c 475WXCONFIG=%{_bindir}/wx-gtk2-unicode-config \
5df0c27c 476QMAKE=%{_bindir}/qmake-qt4 \
53a3431c
AM
477%configure \
478 --with-scriptdir=%{_libexecdir}/%{name} \
479 %{?with_bat:--enable-bat} \
480 --disable-conio \
481 --enable-smartalloc \
482 %{?with_console_wx:--enable-bwx-console} \
53a3431c
AM
483 --enable-tray-monitor \
484 %{?with_python:--with-python} \
485 --with-readline \
486 --with-tcp-wrappers \
487 --with-working-dir=%{_var}/lib/%{name} \
488 --with-dump-email="root@localhost" \
489 --with-job-email="root@localhost" \
490 --with-smtp-host=localhost \
491 --with-pid-dir=/var/run \
492 --with-subsys-dir=/var/lock/subsys \
3f7627bd 493 --with-systemd=/lib/systemd/system \
53a3431c
AM
494 --enable-batch-insert \
495 %{?with_pgsql:--with-postgresql} \
496 %{?with_mysql:--with-mysql} \
497 %{?with_sqlite3:--with-sqlite3} \
498 %{?with_sqlite3_sync_off:--enable-extra-sqlite3-init="pragma synchronous=0;"} \
499 --with-dir-password="#FAKE-dir-password#" \
500 --with-fd-password="#FAKE-fd-password#" \
501 --with-sd-password="#FAKE-sd-password#" \
502 --with-mon-dir-password="#FAKE-mon-dir-password#" \
503 --with-mon-fd-password="#FAKE-mon-fd-password#" \
504 --with-mon-sd-password="#FAKE-mon-sd-password#" \
505 --with-openssl
bb6e7dc5 506
b8003eec
JK
507%if %{with bat}
508cd src/qt-console
509qmake-qt4 bat.pro
510cd ../..
511%endif
512
ffb67df4
AM
513%{__make} 2>&1 | tee log
514# check for build errors
515grep "Error in" log && exit 1
b8003eec 516
b0473ed3
ER
517%if %{with nagios}
518# nagios plugin
519%{__make} -C examples/nagios/check_bacula
520%endif
521
2b68b0cb
AM
522%if %{with rescue}
523cd rescue
524%configure \
525 --with-bacula=../
526cd linux/cdrom
527fakeroot %{__make}
528%endif
529
bb6e7dc5
AM
530%install
531rm -rf $RPM_BUILD_ROOT
b6e1a6b6
JK
532install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,logrotate.d,pam.d,sysconfig} \
533 $RPM_BUILD_ROOT%{_sysconfdir}/rescue \
534 $RPM_BUILD_ROOT{%{_pixmapsdir},%{_desktopdir}} \
535 $RPM_BUILD_ROOT{%{_mandir},%{_bindir},/var/log/bacula} \
536 $RPM_BUILD_ROOT%{systemdunitdir}
bb6e7dc5
AM
537
538%{__make} install \
539 DESTDIR=$RPM_BUILD_ROOT
540
21838166
AM
541# create copies of make_catalog_backup for specific databases; zeore default one (will be ghost)
542for database in %{databases}; do
543 sed -e "s#default_db_type=.*#default_db_type=${database}#g" \
544 $RPM_BUILD_ROOT%{_libdir}/%{name}/make_catalog_backup \
545 > $RPM_BUILD_ROOT%{_libdir}/%{name}/make_${database}_catalog_backup
546 chmod 755 $RPM_BUILD_ROOT%{_libdir}/%{name}/make_${database}_catalog_backup
547done
548:> $RPM_BUILD_ROOT%{_libdir}/%{name}/make_catalog_backup
549
5a48616e 550# we use db dependant (at compile time) shell script only
53a3431c 551rm $RPM_BUILD_ROOT%{_libexecdir}/%{name}/make_catalog_backup.pl
5a48616e 552
53a3431c 553## replace with empty file, replaced by ldconfig from each db-* package on intsall
21838166
AM
554rm $RPM_BUILD_ROOT%{_libdir}/libbaccats-%{version}.so
555touch $RPM_BUILD_ROOT%{_libdir}/libbaccats-%{version}.so
aa70ead8 556
8b9ffa69
ER
557install -p %{SOURCE10} $RPM_BUILD_ROOT/etc/rc.d/init.d/bacula-dir
558install -p %{SOURCE11} $RPM_BUILD_ROOT/etc/rc.d/init.d/bacula-fd
559install -p %{SOURCE12} $RPM_BUILD_ROOT/etc/rc.d/init.d/bacula-sd
560cp -a %{SOURCE13} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}-dir
561cp -a %{SOURCE14} $RPM_BUILD_ROOT/etc/sysconfig/bacula-dir
562cp -a %{SOURCE15} $RPM_BUILD_ROOT/etc/sysconfig/bacula-fd
563cp -a %{SOURCE16} $RPM_BUILD_ROOT/etc/sysconfig/bacula-sd
b6e1a6b6
JK
564cp -a %{SOURCE17} $RPM_BUILD_ROOT%{systemdunitdir}/bacula-dir.service
565cp -a %{SOURCE18} $RPM_BUILD_ROOT%{systemdunitdir}/bacula-fd.service
566cp -a %{SOURCE19} $RPM_BUILD_ROOT%{systemdunitdir}/bacula-sd.service
d907cd57 567
cacc89f5
AZ
568%if %{with console_wx}
569# tray-monitor is for regular users
a3c6e4e6 570#mv $RPM_BUILD_ROOT%{_sbindir}/bacula-tray-monitor $RPM_BUILD_ROOT%{_bindir}
cacc89f5 571
b0473ed3 572cp -a scripts/bacula.png $RPM_BUILD_ROOT%{_pixmapsdir}/bacula.png
a3c6e4e6 573#install src/tray-monitor/generic.xpm $RPM_BUILD_ROOT%{_pixmapsdir}/bacula-tray-monitor.xpm
237bfacd 574sed -e 's/gnome-console/wx-console/g;s/Console/Wx Console/g' \
6b824a09 575 scripts/wxconsole.desktop.consolehelper > $RPM_BUILD_ROOT%{_desktopdir}/bacula-wx.desktop
a3c6e4e6
AZ
576#sed -e 's#%{_sbindir}#%{_bindir}#' \
577# scripts/bacula-tray-monitor.desktop > $RPM_BUILD_ROOT%{_desktopdir}/bacula-tray-monitor.desktop
cacc89f5 578%endif
d907cd57 579
304bb97e 580%if %{with bat}
37bd6446
ER
581# qmake somewhy does not always create install_bins target. install our own the bin
582rm -f $RPM_BUILD_ROOT%{_sbindir}/bat
583libtool --silent --mode=install install src/qt-console/bat $RPM_BUILD_ROOT%{_bindir}
8edc54f3 584cp -a scripts/bacula.png $RPM_BUILD_ROOT%{_pixmapsdir}/bacula.png
b0473ed3 585cp -a scripts/bat.desktop $RPM_BUILD_ROOT%{_desktopdir}
304bb97e
AM
586%endif
587
2b68b0cb 588%if %{with rescue}
d907cd57 589# install the rescue stuff, these are the rescue scripts
b0473ed3
ER
590cp -a rescue/linux/floppy/backup.etc.list $RPM_BUILD_ROOT%{_sysconfdir}/rescue
591cp -a rescue/linux/floppy/sfdisk.bz2 $RPM_BUILD_ROOT%{_sysconfdir}/rescue
592install -p rescue/linux/floppy/*_* $RPM_BUILD_ROOT%{_sysconfdir}/rescue
593install -p rescue/linux/floppy/getdiskinfo $RPM_BUILD_ROOT%{_sysconfdir}/rescue
2b68b0cb 594%endif
bb6e7dc5 595
3c0eac7c
AM
596touch $RPM_BUILD_ROOT/var/log/bacula/log
597
2f8e46d4
ER
598# install the updatedb scripts for older versions that last full release
599# 2.0 -> 3.0 : 10_to_11
21838166 600# 5.0 -> 5.2 : 12_to_14
2f8e46d4 601install -p updatedb/update_*_tables_10_to_11 $RPM_BUILD_ROOT%{_libexecdir}/%{name}
21838166
AM
602install -p updatedb/update_*_tables_11_to_12 $RPM_BUILD_ROOT%{_libexecdir}/%{name}
603install -p updatedb/update_*_tables_12_to_14 $RPM_BUILD_ROOT%{_libexecdir}/%{name}
d907cd57 604
237bfacd
JK
605# place for site passwords
606touch $RPM_BUILD_ROOT%{_sysconfdir}/{dir-password,fd-password,sd-password}
607touch $RPM_BUILD_ROOT%{_sysconfdir}/{mon-dir-password,mon-fd-password,mon-sd-password}
bb6e7dc5 608
5a48616e 609mv $RPM_BUILD_ROOT%{_libexecdir}/%{name}/mtx-changer.conf $RPM_BUILD_ROOT%{_sysconfdir}/mtx-changer.conf
0a03f92d 610
1a72afd2
AM
611# some file changes
612rm -f $RPM_BUILD_ROOT%{_libexecdir}/%{name}/{gconsole,startmysql,stopmysql,bacula,bconsole,fd}
8ba087a4 613%if %{without console_wx}
1376b552 614rm -f $RPM_BUILD_ROOT%{_desktopdir}/bacula-wx.desktop
1376b552 615%endif
1a72afd2
AM
616touch $RPM_BUILD_ROOT%{_sysconfdir}/.pw.sed
617
8ba087a4
ER
618rm $RPM_BUILD_ROOT%{_docdir}/bacula/ChangeLog
619rm $RPM_BUILD_ROOT%{_docdir}/bacula/INSTALL
620rm $RPM_BUILD_ROOT%{_docdir}/bacula/LICENSE
621rm $RPM_BUILD_ROOT%{_docdir}/bacula/README
622rm $RPM_BUILD_ROOT%{_docdir}/bacula/ReleaseNotes
623rm $RPM_BUILD_ROOT%{_docdir}/bacula/VERIFYING
624rm $RPM_BUILD_ROOT%{_docdir}/bacula/technotes
625
7545e94f
JK
626# startup scripts, those in /etc/rc.d/init.d are better
627rm $RPM_BUILD_ROOT%{_sbindir}/bacula
628rm $RPM_BUILD_ROOT%{_libexecdir}/%{name}/bacula-ctl-*
629
41bc1b6e 630# unsupported
8fb2ca23 631rm $RPM_BUILD_ROOT%{_libexecdir}/%{name}/btraceback.mdb
41bc1b6e 632
7545e94f
JK
633# rename to avoid possible conflicts
634mv $RPM_BUILD_ROOT%{_sbindir}/{,bacula-}dbcheck
635mv $RPM_BUILD_ROOT%{_mandir}/man8/{,bacula-}dbcheck.8.gz
636
637# no -devel files packaged, so this is also useless
638rm $RPM_BUILD_ROOT%{_libdir}/libbac{,cfg,find,py,sql}.{so,la}
639
b0473ed3 640%if %{with nagios}
819cd4b0 641install -d $RPM_BUILD_ROOT%{nagiosplugindir}
b0473ed3
ER
642%{__make} -C examples/nagios/check_bacula install \
643 sbindir=%{nagiosplugindir} \
403b68c1 644 INSTALL_PROGRAM="libtool --mode=install install -p" \
b0473ed3
ER
645 DESTDIR=$RPM_BUILD_ROOT
646%endif
7545e94f 647
f2337569
JB
648%clean
649rm -rf $RPM_BUILD_ROOT
650
5ce18635 651%pre common
fbc59152
ER
652%groupadd -P %{name}-common -g 136 -r -f bacula
653%useradd -P %{name}-common -u 136 -r -d /var/lib/bacula -s /bin/false -c "Bacula User" -g bacula bacula
5ce18635 654
b8003eec 655%define update_configs \
210f992b 656echo "Updating bacula passwords and names..." | %banner -a %{name} \
5a48616e 657cd %{_sysconfdir} \
2f8e46d4
ER
658for f in *-password; do \
659 if [ ! -s $f ]; then \
b8003eec
JK
660 openssl rand -base64 33 > $f \
661 fi \
2f8e46d4
ER
662 p=$(cat $f) \
663 for cf in *.conf *.conf.rpmnew; do \
b8003eec
JK
664 [ -f $cf ] && sed -i -e"s:#FAKE-$f#:$p:" "$cf" || : \
665 done \
666done \
2f8e46d4 667for cf in *.conf *.conf.rpmnew; do \
b8003eec
JK
668 [ -f $cf ] && sed -i -e"s:--hostname--:`hostname`:" "$cf" || : \
669done
670
237bfacd 671%post common
0a03f92d 672/sbin/ldconfig
b8003eec 673%update_configs
237bfacd 674
5ce18635 675%postun common
0a03f92d 676/sbin/ldconfig
28c9f5d0
AM
677if [ "$1" = "0" ]; then
678 %userremove bacula
679 %groupremove bacula
680fi
5ce18635 681
e31a1707 682%triggerpostun dir -- %{name}-dir < %{version}-0
b8003eec
JK
683%banner bacula-dir -t3 <<EOF
684You have upgraded from an older version of Bacula director.
bb6e7dc5 685
b8003eec
JK
686You will probably need to call %{_libexecdir}/%{name}/update_bacula_tables
687script to upgrade the database.
f0b67fde
ER
688
689Ensure you database partition has enough free space before you run the upgrade,
690i.e check that there is enough room to rebuild 'File' table (it is the largest
691in bacula db).
692
b8003eec 693EOF
237bfacd 694
b8003eec
JK
695%post dir
696%update_configs
1a72afd2 697/sbin/chkconfig --add bacula-dir
52504a6d 698%service bacula-dir restart "Bacula Director daemon"
b6e1a6b6 699%systemd_post bacula-dir.service
bb6e7dc5 700
5ce18635 701%preun dir
1a72afd2 702if [ "$1" = "0" ]; then
52504a6d 703 %service bacula-dir stop
9aa69d51 704 /sbin/chkconfig --del bacula-dir
1a72afd2 705fi
b6e1a6b6
JK
706%systemd_preun bacula-dir.service
707
708%postun dir
709%systemd_reload
bb6e7dc5 710
5ce18635 711%post fd
b8003eec 712%update_configs
1a72afd2 713/sbin/chkconfig --add bacula-fd
52504a6d 714%service bacula-fd restart "Bacula File daemon"
b6e1a6b6 715%systemd_post bacula-fd.service
bb6e7dc5 716
5ce18635 717%preun fd
1a72afd2 718if [ "$1" = "0" ]; then
52504a6d 719 %service bacula-fd stop
9aa69d51 720 /sbin/chkconfig --del bacula-fd
1a72afd2 721fi
b6e1a6b6
JK
722%systemd_preun bacula-fd.service
723
724%postun fd
725%systemd_reload
5ce18635
AM
726
727%post sd
b8003eec 728%update_configs
1a72afd2 729/sbin/chkconfig --add bacula-sd
52504a6d 730%service bacula-sd restart "Bacula Storage daemon"
b6e1a6b6 731%systemd_post bacula-sd.service
bb6e7dc5 732
5ce18635 733%preun sd
1a72afd2 734if [ "$1" = "0" ]; then
52504a6d 735 %service bacula-sd stop
9aa69d51 736 /sbin/chkconfig --del bacula-sd
1a72afd2 737fi
b6e1a6b6
JK
738%systemd_preun bacula-sd.service
739
740%postun sd
741%systemd_reload
5ce18635
AM
742
743%pre console
744if [ -e %{_sysconfdir}/console.conf -a ! -e %{_sysconfdir}/bconsole.conf ]; then
9aa69d51 745 mv %{_sysconfdir}/console.conf %{_sysconfdir}/bconsole.conf
bb6e7dc5
AM
746fi
747
237bfacd 748%post console
b8003eec 749%update_configs
237bfacd
JK
750
751%post console-wx
b8003eec 752%update_configs
237bfacd 753
827db798 754%triggerpostun common -- %{name}-common < 5.0.1-2
44069e22 755find %{_sysconfdir}/bat.conf* -perm /007 -print0 2>/dev/null | xargs -0 -r chmod 600 || :
3a5cd5d7 756
304bb97e 757%post console-qt4
b8003eec 758%update_configs
304bb97e 759
237bfacd 760%post tray-monitor
b8003eec 761%update_configs
bb6e7dc5 762
bb6e7dc5
AM
763%post rescue
764# link our current installed conf file to the rescue directory
f2337569 765ln -sf %{_sysconfdir}/bacula-fd.conf %{_sysconfdir}/rescue/bacula-fd.conf
bb6e7dc5
AM
766
767# run getdiskinfo
768echo "Creating rescue files for this system..."
d907cd57 769cd %{_sysconfdir}/rescue
bb6e7dc5
AM
770./getdiskinfo
771
772%preun rescue
773# remove the files created after the initial rpm installation
f2337569
JB
774if [ "$1" = "0" ]; then
775 rm -f %{_sysconfdir}/rescue/bacula-fd.conf
776 rm -f %{_sysconfdir}/rescue/partition.*
777 rm -f %{_sysconfdir}/rescue/format.*
778 rm -f %{_sysconfdir}/rescue/mount_drives
779 rm -f %{_sysconfdir}/rescue/start_network
780 rm -f %{_sysconfdir}/rescue/sfdisk
781 rm -rf %{_sysconfdir}/rescue/diskinfo/*
782fi
bb6e7dc5 783
41bc1b6e
JK
784%define db_post() \
785/sbin/ldconfig \
b0473ed3 786for name in "create database" "drop tables" "drop database" "grant privileges" "make tables" "update tables"; do \
41bc1b6e
JK
787 prefix="${name%% *}" \
788 suffix="${name#* }" \
b0473ed3 789 ln -sf "${prefix}_%{1}_${suffix}" %{_libexecdir}/%{name}/"${prefix}_bacula_${suffix}" || : \
dae3a0bd 790done \
5a48616e 791ln -sf "make_%{1}_catalog_backup" %{_libexecdir}/%{name}/make_catalog_backup || : \
21838166 792ln -sf libbaccats-%{1}-%{version}.so %{_libdir}/libbaccats-%{version}.so || : \
dae3a0bd
JK
793%service bacula-dir restart "Bacula Director daemon"
794
41bc1b6e
JK
795%post db-postgresql
796%db_post postgresql
797
dfef965d 798%postun db-postgresql -p /sbin/ldconfig
dae3a0bd 799
41bc1b6e
JK
800%post db-mysql
801%db_post mysql
802
dfef965d 803%postun db-mysql -p /sbin/ldconfig
dae3a0bd 804
41bc1b6e
JK
805%post db-sqlite3
806%db_post sqlite3
807
dfef965d 808%postun db-sqlite3 -p /sbin/ldconfig
dae3a0bd 809
5ce18635
AM
810%files common
811%defattr(644,root,root,755)
237bfacd 812%doc LICENSE
051f919c 813%{?with_python:%doc examples/python}
1a72afd2 814%dir %{_sysconfdir}
1b0a2248 815%attr(600,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*-password
7545e94f
JK
816# do not remove bsmtp from files. Fix build if it is not installed.
817%attr(755,root,root) %{_sbindir}/bsmtp
7425cb9d 818%attr(755,root,root) %{_sbindir}/btraceback
6f3f1b78
JK
819%attr(755,root,root) %{_libdir}/libbac-5*.so
820%attr(755,root,root) %{_libdir}/libbaccfg-5*.so
821%attr(755,root,root) %{_libdir}/libbacfind-5*.so
822%attr(755,root,root) %{_libdir}/libbacpy-5*.so
21838166 823%attr(755,root,root) %{_libdir}/libbacsql-5*.so
c74b041d 824%{_mandir}/man8/bacula.8*
7425cb9d
JK
825%{_mandir}/man1/bsmtp.1*
826%{_mandir}/man8/btraceback.8*
5ce18635 827%dir %{_libexecdir}/%{name}
1376b552 828%{_libexecdir}/%{name}/btraceback.dbx
5ce18635 829%{_libexecdir}/%{name}/btraceback.gdb
7545e94f 830%{_libexecdir}/%{name}/bacula_config
d6dbe33c 831%attr(770,root,bacula) %dir %{_localstatedir}
3c0eac7c
AM
832%attr(750,bacula,logs) %dir /var/log/bacula
833%attr(640,bacula,logs) %ghost /var/log/bacula/log
5ce18635
AM
834
835%files dir
bb6e7dc5 836%defattr(644,root,root,755)
237bfacd 837%doc ChangeLog CheckList ReleaseNotes kernstodo LICENSE
28647453 838#%doc examples %{name}-docs-%{version}/manual/{*.pdf,bacula}
cc515592 839%attr(640,root,bacula) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bacula-dir.conf
1a72afd2 840%ghost %{_sysconfdir}/.pw.sed
28c9f5d0 841%attr(640,root,root) %config(noreplace) /etc/logrotate.d/bacula-dir
1a72afd2 842%attr(754,root,root) /etc/rc.d/init.d/bacula-dir
cd23ba7c 843%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/bacula-dir
b6e1a6b6 844%{systemdunitdir}/bacula-dir.service
5ff0b6a3 845%attr(755,root,root) %{_sbindir}/bacula-dir
7545e94f
JK
846%attr(755,root,root) %{_sbindir}/bregex
847%attr(755,root,root) %{_sbindir}/bwild
848%attr(755,root,root) %{_sbindir}/bacula-dbcheck
79d0fef6 849%{_mandir}/man8/bacula-dir.8*
7545e94f 850%{_mandir}/man8/bacula-dbcheck.8*
3f7627bd
AM
851%{_mandir}/man8/bregex.8*
852%{_mandir}/man8/bwild.8*
79d0fef6 853%{_libexecdir}/%{name}/query.sql
5a48616e 854%attr(755,root,root) %{_libexecdir}/%{name}/delete_catalog_backup
41bc1b6e
JK
855
856%files db-postgresql
857%defattr(644,root,root,755)
858%attr(755,root,root) %{_libexecdir}/%{name}/create_postgresql_database
859%attr(755,root,root) %{_libexecdir}/%{name}/drop_postgresql_database
860%attr(755,root,root) %{_libexecdir}/%{name}/drop_postgresql_tables
861%attr(755,root,root) %{_libexecdir}/%{name}/grant_postgresql_privileges
862%attr(755,root,root) %{_libexecdir}/%{name}/make_postgresql_tables
863%attr(755,root,root) %{_libexecdir}/%{name}/update_postgresql_*
21838166 864%attr(755,root,root) %{_libexecdir}/%{name}/make_postgresql_catalog_backup
53a3431c 865%attr(755,root,root) %{_libdir}/libbaccats-postgresql-5*.so
41bc1b6e 866
21838166 867%ghost %attr(755,root,root) %{_libdir}/libbaccats-5*.so
41bc1b6e
JK
868%ghost %{_libexecdir}/%{name}/create_bacula_database
869%ghost %{_libexecdir}/%{name}/drop_bacula_tables
870%ghost %{_libexecdir}/%{name}/drop_bacula_database
871%ghost %{_libexecdir}/%{name}/grant_bacula_privileges
872%ghost %{_libexecdir}/%{name}/make_bacula_tables
873%ghost %{_libexecdir}/%{name}/update_bacula_tables
21838166 874%ghost %{_libexecdir}/%{name}/make_catalog_backup
41bc1b6e
JK
875
876%files db-mysql
877%defattr(644,root,root,755)
aeaed87e 878%attr(755,root,root) %{_libexecdir}/%{name}/create_mysql_database
879%attr(755,root,root) %{_libexecdir}/%{name}/drop_mysql_database
880%attr(755,root,root) %{_libexecdir}/%{name}/drop_mysql_tables
881%attr(755,root,root) %{_libexecdir}/%{name}/grant_mysql_privileges
882%attr(755,root,root) %{_libexecdir}/%{name}/make_mysql_tables
883%attr(755,root,root) %{_libexecdir}/%{name}/update_mysql_*
21838166 884%attr(755,root,root) %{_libexecdir}/%{name}/make_mysql_catalog_backup
53a3431c 885%attr(755,root,root) %{_libdir}/libbaccats-mysql-5*.so
41bc1b6e 886
21838166 887%ghost %attr(755,root,root) %{_libdir}/libbaccats-5*.so
41bc1b6e
JK
888%ghost %{_libexecdir}/%{name}/create_bacula_database
889%ghost %{_libexecdir}/%{name}/drop_bacula_tables
890%ghost %{_libexecdir}/%{name}/drop_bacula_database
891%ghost %{_libexecdir}/%{name}/grant_bacula_privileges
892%ghost %{_libexecdir}/%{name}/make_bacula_tables
893%ghost %{_libexecdir}/%{name}/update_bacula_tables
21838166 894%ghost %{_libexecdir}/%{name}/make_catalog_backup
41bc1b6e
JK
895
896%files db-sqlite3
897%defattr(644,root,root,755)
898%attr(755,root,root) %{_libexecdir}/%{name}/create_sqlite3_database
899%attr(755,root,root) %{_libexecdir}/%{name}/drop_sqlite3_database
900%attr(755,root,root) %{_libexecdir}/%{name}/drop_sqlite3_tables
901%attr(755,root,root) %{_libexecdir}/%{name}/grant_sqlite3_privileges
902%attr(755,root,root) %{_libexecdir}/%{name}/make_sqlite3_tables
903%attr(755,root,root) %{_libexecdir}/%{name}/update_sqlite3_*
21838166 904%attr(755,root,root) %{_libexecdir}/%{name}/make_sqlite3_catalog_backup
53a3431c 905%attr(755,root,root) %{_libdir}/libbaccats-sqlite3-5*.so
41bc1b6e 906
21838166 907%ghost %attr(755,root,root) %{_libdir}/libbaccats-5*.so
41bc1b6e
JK
908%ghost %{_libexecdir}/%{name}/create_bacula_database
909%ghost %{_libexecdir}/%{name}/drop_bacula_tables
910%ghost %{_libexecdir}/%{name}/drop_bacula_database
911%ghost %{_libexecdir}/%{name}/grant_bacula_privileges
912%ghost %{_libexecdir}/%{name}/make_bacula_tables
913%ghost %{_libexecdir}/%{name}/update_bacula_tables
21838166 914%ghost %{_libexecdir}/%{name}/make_catalog_backup
41bc1b6e 915
5ce18635
AM
916%files fd
917%defattr(644,root,root,755)
237bfacd 918%doc LICENSE
efb15923 919%attr(640,root,bacula) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bacula-fd.conf
1a72afd2 920%attr(754,root,root) /etc/rc.d/init.d/bacula-fd
cd23ba7c 921%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/bacula-fd
b6e1a6b6 922%{systemdunitdir}/bacula-fd.service
5ff0b6a3 923%attr(755,root,root) %{_sbindir}/bacula-fd
7545e94f 924%attr(755,root,root) %{_libdir}/bpipe-fd.so
79d0fef6 925%{_mandir}/man8/bacula-fd.8*
5ce18635
AM
926
927%files sd
928%defattr(644,root,root,755)
237bfacd 929%doc LICENSE
efb15923 930%attr(640,root,bacula) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bacula-sd.conf
931%attr(640,root,bacula) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mtx-changer.conf
1a72afd2 932%attr(754,root,root) /etc/rc.d/init.d/bacula-sd
cd23ba7c 933%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/bacula-sd
b6e1a6b6 934%{systemdunitdir}/bacula-sd.service
5ff0b6a3
AM
935%attr(755,root,root) %{_sbindir}/bacula-sd
936%attr(755,root,root) %{_sbindir}/bcopy
937%attr(755,root,root) %{_sbindir}/bextract
938%attr(755,root,root) %{_sbindir}/bls
939%attr(755,root,root) %{_sbindir}/bscan
940%attr(755,root,root) %{_sbindir}/btape
329073aa 941%attr(755,root,root) %{_libexecdir}/%{name}/mtx-changer
150db1c2 942%attr(755,root,root) %{_libexecdir}/%{name}/disk-changer
329073aa 943%attr(755,root,root) %{_libexecdir}/%{name}/dvd-handler
5ce18635 944%{_mandir}/man8/bacula-sd.8*
7425cb9d
JK
945%{_mandir}/man8/bcopy.8*
946%{_mandir}/man8/bextract.8*
947%{_mandir}/man8/bls.8*
948%{_mandir}/man8/bscan.8*
949%{_mandir}/man8/btape.8*
5ce18635
AM
950
951%files console
bb6e7dc5 952%defattr(644,root,root,755)
237bfacd 953%doc LICENSE
efb15923 954%attr(640,root,bacula) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bconsole.conf
1a72afd2 955%attr(755,root,root) %{_sbindir}/bconsole
7425cb9d 956%{_mandir}/man8/bconsole.8*
5ce18635 957
1376b552 958%if %{with console_wx}
5ce18635
AM
959%files console-wx
960%defattr(644,root,root,755)
237bfacd 961%doc LICENSE
1a72afd2 962%{_pixmapsdir}/%{name}.png
237bfacd 963%{_desktopdir}/bacula-wx.desktop
ffb67df4
AM
964%attr(640,root,bacula) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bwx-console.conf
965%attr(755,root,root) %{_sbindir}/bwx-console
e3dd858d 966%{_mandir}/man1/bacula-bwxconsole.1*
1376b552 967%endif
bb6e7dc5 968
304bb97e
AM
969%if %{with bat}
970%files console-qt4
971%defattr(644,root,root,755)
972%doc LICENSE
973%{_pixmapsdir}/%{name}.png
974%{_desktopdir}/bat.desktop
2264d68c 975# Do not make this file world-readable or any user will get full access to the
b0473ed3 976# backup system
2264d68c
JK
977%attr(640,root,bacula) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bat.conf
978%attr(755,root,root) %{_bindir}/bat
304bb97e 979%{_mandir}/man1/bat.1*
7545e94f 980%{_docdir}/%{name}
304bb97e
AM
981%endif
982
cacc89f5 983%if %{with console_wx}
237bfacd
JK
984%files tray-monitor
985%defattr(644,root,root,755)
986%doc LICENSE
8ba087a4
ER
987%attr(755,root,root) %{_sbindir}/bacula-tray-monitor
988#%{_pixmapsdir}/%{name}-tray-monitor.xpm
989#%{_desktopdir}/%{name}-tray-monitor.desktop
cd23ba7c 990%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/tray-monitor.conf
7425cb9d 991%{_mandir}/man1/bacula-tray-monitor.1*
cacc89f5 992%endif
237bfacd 993
2b68b0cb 994%if %{with rescue}
bb6e7dc5
AM
995%files rescue
996%defattr(644,root,root,755)
c741b8e0 997%doc LICENSE
4280e495 998%dir %{_sysconfdir}/rescue
1b0a2248 999%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/backup.etc.list
1000%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/bacula-fd
1001%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/format_floppy
1002%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/getdiskinfo
1003%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/make_rescue_disk
1004%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/restore_bacula
1005%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/restore_etc
1006%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/run_grub
1007%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/run_lilo
1008%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rescue/sfdisk.bz2
2b68b0cb 1009%endif
b0473ed3
ER
1010
1011%if %{with nagios}
1012%files -n nagios-plugin-check_bacula
1013%defattr(644,root,root,755)
1014%attr(755,root,root) %{nagiosplugindir}/check_bacula
1015%endif
This page took 0.337068 seconds and 4 git commands to generate.