File bacula.spec of Package bacula
#
# spec file for package bacula (Version 2.4.2)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# norootforbuild
Name: bacula
%define _fwdefdir /etc/sysconfig/SuSEfirewall2.d/services
BuildRequires: gcc-c++ libacl-devel mysql-devel openssl-devel readline-devel tcpd-devel xorg-x11-devel
License: GPL v2 or later
Group: Productivity/Archiving/Backup
AutoReqProv: on
Version: 2.4.2
Release: 1
Summary: Bacula--The Network Backup Solution: Client Part
Url: http://www.bacula.org
Source0: %{name}-%{version}.tar.bz2
Source10: bacula-dir.init
Source11: bacula-fd.init
Source12: bacula-sd.init
Source20: bacula-dir.fw
Source21: bacula-fd.fw
Source22: bacula-sd.fw
Patch: %{name}-%{version}-cflags.diff
Patch1: %{name}-%{version}-python.diff
Patch2: %{name}-%{version}-fortify.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
Bacula comes by night and sucks the vital essence from your computers.
Bacula is a set of computer programs that permit you (or the system
administrator) to manage backup, recovery, and verification of computer
data across a network of computers of different kinds. In technical
terms, it is a network client/server-based backup program. Bacula is
relatively easy to use and efficient, while offering many advanced
storage management features that make it easy to find and recover lost
or damaged files.
%package server
License: GPL v2 or later
Summary: Bacula - The Network Backup Solution - server part
Group: Productivity/Archiving/Backup
Requires: bacula = %{version}
AutoReqProv: on
%description server
Bacula - It comes by night and sucks the vital essence from your
computers. Bacula is a set of computer programs that permit you (or the
system administrator) to manage backup, recovery, and verification of
computer data across a network of computers of different kinds. In
technical terms, it is a network client/server based backup program.
Bacula is relatively easy to use and efficient, while offering many
advanced storage management features that make it easy to find and
recover lost or damaged files. This package contains Bacula server
daemons.
%prep
%setup -q
%patch
%patch1
%patch2
%build
CFLAGS="-fno-strict-aliasing $RPM_OPT_FLAGS $(ncurses5-config --cflags)" LDFLAGS="-L/usr/%{_lib}/mysql $(ncurses5-config --libs)" ./configure \
--prefix=%{_prefix} \
--libexecdir=%{_libdir} \
--sbindir=%{_sbindir} \
--bindir=%{_bindir} \
--libdir=%{_libdir} \
--infodir=%{_infodir} \
--mandir=%{_mandir} \
--sysconfdir=%{_sysconfdir}/bacula \
--with-working-dir=/var/lib/bacula/working \
--with-mysql \
--with-openssl \
--with-tcp-wrappers
make CFLAGS="$RPM_OPT_FLAGS"
%install
make DESTDIR=$RPM_BUILD_ROOT install
mkdir -p $RPM_BUILD_ROOT/etc/init.d
install -m 755 %SOURCE10 $RPM_BUILD_ROOT/etc/init.d/bacula-dir
install -m 755 %SOURCE11 $RPM_BUILD_ROOT/etc/init.d/bacula-fd
install -m 755 %SOURCE12 $RPM_BUILD_ROOT/etc/init.d/bacula-sd
ln -sf ../../etc/init.d/bacula-fd $RPM_BUILD_ROOT/%{_sbindir}/rcbacula-fd
ln -sf ../../etc/init.d/bacula-sd $RPM_BUILD_ROOT/%{_sbindir}/rcbacula-sd
ln -sf ../../etc/init.d/bacula-dir $RPM_BUILD_ROOT/%{_sbindir}/rcbacula-dir
# remove /etc/bacula/startmysql
# and /etc/bacula/stopmysql
# as they are not needed (bug #145310)
rm $RPM_BUILD_ROOT/etc/bacula/startmysql $RPM_BUILD_ROOT/etc/bacula/stopmysql
rm $RPM_BUILD_ROOT/etc/bacula/bacula-ctl-dir $RPM_BUILD_ROOT/etc/bacula/bacula-ctl-fd $RPM_BUILD_ROOT/etc/bacula/bacula-ctl-sd
#install fw definitions
mkdir -p $RPM_BUILD_ROOT/%{_fwdefdir}/
install -m 755 %SOURCE20 $RPM_BUILD_ROOT/%{_fwdefdir}/bacula-dir
install -m 755 %SOURCE21 $RPM_BUILD_ROOT/%{_fwdefdir}/bacula-fd
install -m 755 %SOURCE22 $RPM_BUILD_ROOT/%{_fwdefdir}/bacula-sd
%clean
rm -rf $RPM_BUILD_ROOT
%preun
%stop_on_removal bacula-fd
%postun
%restart_on_update bacula-fd
%insserv_cleanup
%preun server
%stop_on_removal bacula-dir bacula-sd
%postun server
%restart_on_update bacula-dir bacula-sd
%insserv_cleanup
%files
%defattr(-,root,root)
%config /etc/init.d/bacula-fd
%doc ABOUT-NLS COPYING INSTALL LICENSE README VERIFYING ReleaseNotes projects
%{_sbindir}/bacula-fd
%{_sbindir}/rcbacula-fd
%{_sbindir}/bconsole
%{_sbindir}/btraceback
%config(noreplace) /etc/bacula/bacula-fd.conf
%config /etc/bacula/bconsole
%config(noreplace) /etc/bacula/bconsole.conf
%config /etc/bacula/btraceback.dbx
%config /etc/bacula/btraceback.gdb
%config /etc/bacula/gconsole
%config /etc/bacula/mtx-changer
%config /etc/bacula/bacula
%config /etc/bacula/dvd-handler
%config /etc/bacula/disk-changer
%dir /etc/bacula
%dir /var/lib/bacula
%dir /var/lib/bacula/working
%config %{_fwdefdir}/bacula-fd
%doc %{_mandir}/man?/*
%files server
%defattr(-,root,root)
%config /etc/init.d/bacula-sd
%config /etc/init.d/bacula-dir
%{_sbindir}/*
%config(noreplace) /etc/bacula/bacula-dir.conf
%config(noreplace) /etc/bacula/bacula-sd.conf
%config /etc/bacula/create*
%config /etc/bacula/delete*
%config /etc/bacula/drop*
%config /etc/bacula/grant*
%config /etc/bacula/make*
%config /etc/bacula/update*
%config /etc/bacula/query.sql
%config %{_fwdefdir}/bacula-dir
%config %{_fwdefdir}/bacula-sd
%dir /etc/bacula
%dir /var/lib/bacula
%dir /var/lib/bacula/working
%changelog
* Wed Sep 10 2008 anicka@suse.cz
- update to 2.4.2
* When a migration job actually runs, re-check the Job record
and skip if the job is already migrated.
* Implement a set_dcr_from_vol subroutine in acquire.c for
reading volumes.
* Ensure that SD tried to mount a volume not in an autochanger
at least once before asking for operator intervention.
* bugfixes
* Sat Aug 30 2008 cthiel@suse.de
- fix build with latests ncurses
* Wed Aug 20 2008 anicka@suse.cz
- update to 2.4.1
* Generally clean up the manual tape loading code. The main
conceptial change is that when a volume is marked to be unloaded,
its volume name is retained, and it is only marked as unloaded
when either the autoloader says it is unloaded or another tape
is read on that drive.
* Add dbuser to DIR conf file (replaces user).
* Add --with-db-password to ./configure
* Make DEVICE Slot private and access it via a method.
Allows better control over when it is set and cleared.
* Add debug code to SD.
* If operator has rewind tape, print warning, release tape and
try once more. If tape is positioned somewhere, something went
wrong, so mark the tape in error and try once more. Previously
this error was fatal, now it produces an error message.
* Implement regression that explicitly tests swapping a Volume
from one drive to another.
* Move final volume swapping code to DCR method and
call it from acquire_for_read().
* When wrong volume is mounted during read, unload_autochanger.
* Stop searching for Volumes in SD askdir if DIR returns the
same volume name twice in a row.
* Redefine CURES in lib/parse_conf to be URES and move it all
into lib/parse_conf.c -- this responds to bug #1042, but does
not fix it. The fix is not to compile with FORTIFY_SOURCE.
* many bugfixes
- fix firewall definitions (bnc#414957)
* Tue Jan 22 2008 anicka@suse.cz
- fix problems detected by FORTIFY_SOURCE [#354872]
* Tue Jan 15 2008 anicka@suse.cz
- update to 2.2.7
* implement double quoting include names in conf files,
and also allow piping input by having the first character
be a vertical bar (|).
* implement %%f in RunScripts to pass the FileSet name.
* bugfixes
* Wed Nov 21 2007 anicka@suse.cz
- update to 2.2.6
* many new features (new major release)
* fix of serious bug that could cause data loss
* Tue Jun 12 2007 anicka@suse.cz
- update to 2.0.3
* bugfixes
* Add smartctl call to bacula-sd.conf as an example of getting
tape alert info.
* Add Client Connect Wait to Storage daemon to permit users to
modify the time the SD waits for a FD connection.
* Mon Mar 05 2007 anicka@suse.cz
- fix path for firewall definitions
* Thu Feb 22 2007 anicka@suse.cz
- add firewall definitions [#247362]
* Fri Feb 02 2007 anicka@suse.cz
- update to 2.0.2
* Implement the include JobID in spool file name project.
* Reorder projects file in order determined by Jan 2007 vote.
* Fix open of SQLite3 db where user does not have write
permission so that DIR does not crash.
* Change 'Device not configured to autolabel' from INFO
to WARNING.
* Fix jobq.c to restart failed jobs when Reschedule Times = 0
which should restart an indefinite # of times.
* Fix Job restart on error bug that promotes an Inc to a Full
backup.
* Return JobId in db_get_job_record() when JobId==0.
* Do not release source pointers when restarting a failed job.
* Modify USTORE constructor to set an empty store_source string,
and don't copy the store_source string in a cancel.
* Correct the Options scanner in the FD to correctly handle
SHA1 option, which was eating the next option.
* Add code to indicate when the SD is spooling, spool wait, and
despooling.
* Tue Jan 23 2007 anicka@suse.cz
- build with $RPM_OPT_FLAGS
* Fri Jan 05 2007 anicka@suse.cz
- update to 2.0.0
* new major release, merged code from beta,
see ChangeLog file for detailed information
* Sat Sep 02 2006 aj@suse.de
- Cleanup BuildRequires.
* Wed Jul 19 2006 anicka@suse.cz
- update to 1.38.11
* added documentation translations, change license to FDL
* bugfixes
- rename tee variable in console.c
* Fri May 19 2006 anicka@suse.cz
- update to 1.38.9:
- various bugfixes and minor improvements,
see Changelog for more information
* Tue Jan 31 2006 anicka@suse.cz
- add noreplace to all .conf files (#146150)
* Fri Jan 27 2006 anicka@suse.cz
- remove unneeded files (#145310)
* Wed Jan 25 2006 mls@suse.de
- converted neededforbuild to BuildRequires
* Thu Jan 05 2006 anicka@suse.cz
- update to 1.38.3
* Fri Dec 09 2005 anicka@suse.cz
- package documentation files (#137127)
* Fri Dec 02 2005 anicka@suse.cz
- build with -fno-strict-aliasing
* Thu Nov 24 2005 mt@suse.de
- update to 1.38.2
- enabled ACL, TLS and tcp wrapper support
- fixed to use separate preun postun scripts
for bacula and bacula server subpackages
* Fri Nov 11 2005 anicka@suse.cz
- update to 1.38.0
- add rcbacula-fd, -sd, -dir links
* Mon Oct 03 2005 anicka@suse.cz
- update to 1.37.40
* Tue Jul 19 2005 anicka@suse.cz
- use proper lib (lib64 on biarch)
* Wed Jul 13 2005 anicka@suse.cz
- package created