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