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