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