X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=bacula%2Fplatforms%2Fredhat%2Fbacula.spec.in;h=4e67593ca1480d1120e83a87c1e6b3f5b3185649;hb=4d06a55913c582458dcfad1642e1ee2cb091b1bf;hp=6eb90603b439d7e32f651bcd6db477a7e40bafc7;hpb=a9253721d49fb1b6bd5a7792d2461a5ec3b98c7f;p=bacula%2Fbacula diff --git a/bacula/platforms/redhat/bacula.spec.in b/bacula/platforms/redhat/bacula.spec.in index 6eb90603b4..4e67593ca1 100644 --- a/bacula/platforms/redhat/bacula.spec.in +++ b/bacula/platforms/redhat/bacula.spec.in @@ -6,14 +6,13 @@ # basic defines for every build %define _version @VERSION@ %define _release 1 -%define depkgs_version 04Jan07 -%define _rescuever 2.0.0 +%define depkgs_version 09Sep07 +%define _rescuever @VERSION@ %define docs_version @VERSION@ # any patches for this release # be sure to check the setup section for patch macros - #-------------------------------------------------------------------------- # it should not be necessary to change anything below here for a release # except for patch macros in the setup section @@ -97,6 +96,8 @@ Packager: %{_packager} %{?build_fc5:%define fc5 1} %define fc6 0 %{?build_fc6:%define fc6 1} +%define fc7 0 +%{?build_fc7:%define fc7 1} # Whitebox Enterprise build %define wb3 0 %{?build_wb3:%define wb3 1} @@ -107,6 +108,9 @@ Packager: %{_packager} %define rhel4 0 %{?build_rhel4:%define rhel4 1} %{?build_rhel4:%define fc3 1} +%define rhel5 0 +%{?build_rhel5:%define rhel5 1} +%{?build_rhel5:%define fc6 1} # CentOS build %define centos3 0 %{?build_centos3:%define centos3 1} @@ -114,6 +118,9 @@ Packager: %{_packager} %define centos4 0 %{?build_centos4:%define centos4 1} %{?build_centos4:%define fc3 1} +%define centos5 0 +%{?build_centos5:%define centos5 1} +%{?build_centos5:%define fc6 1} # SL build %define sl3 0 %{?build_sl3:%define sl3 1} @@ -121,6 +128,9 @@ Packager: %{_packager} %define sl4 0 %{?build_sl4:%define sl4 1} %{?build_sl4:%define fc3 1} +%define sl5 0 +%{?build_sl5:%define sl5 1} +%{?build_sl5:%define fc6 1} # SuSE build %define su9 0 %{?build_su9:%define su9 1} @@ -140,7 +150,7 @@ Packager: %{_packager} %{?build_client_only:%define client_only 1} # test for a platform definition -%if ! %{rh7} && ! %{rh8} && ! %{rh9} && ! %{fc1} && ! %{fc3} && ! %{fc4} && ! %{fc5} && ! %{fc6} && ! %{wb3} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{mdk} +%if ! %{rh7} && ! %{rh8} && ! %{rh9} && ! %{fc1} && ! %{fc3} && ! %{fc4} && ! %{fc5} && ! %{fc6} && ! %{fc7} && ! %{wb3} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{mdk} %{error: You must specify a platform. Please examine the spec file.} exit 1 %endif @@ -185,21 +195,24 @@ exit 1 %{?build_x86_64:%define x86_64 1} # check what distribution we are -%if %{rh7} || %{rh8} || %{rh9} || %{rhel3} || %{rhel4} +%if %{rh7} || %{rh8} || %{rh9} || %{rhel3} || %{rhel4} || %{rhel5} %define _dist %(grep Red /etc/redhat-release) %endif -%if %{fc1} || %{fc4} || %{fc5} || %{fc6} +%if %{fc1} || %{fc4} || %{fc5} || %{fc7} %define _dist %(grep Fedora /etc/redhat-release) %endif -%if %{centos4} || %{centos3} +%if %{centos5} || %{centos4} || %{centos3} %define _dist %(grep CentOS /etc/redhat-release) %endif -%if %{sl4} || %{sl3} +%if %{sl5} ||%{sl4} || %{sl3} %define _dist %(grep 'Scientific Linux' /etc/redhat-release) %endif %if %{fc3} && ! %{rhel4} && ! %{centos4} && ! %{sl4} %define _dist %(grep Fedora /etc/redhat-release) %endif +%if %{fc6} && ! %{rhel5} && ! %{centos5} && ! %{sl5} +%define _dist %(grep Fedora /etc/redhat-release) +%endif %if %{wb3} && ! %{rhel3} && ! %{centos3} && ! %{sl3} %define _dist %(grep White /etc/whitebox-release) %endif @@ -213,9 +226,11 @@ Distribution: %{_dist} # Should we build gconsole, possible only if gtk= >= 2.4 available. # leaving all the BuildRequires and Requires in place below for now. +# su10, fc3 and fc4 now nobuild, tray monitor fails to build as of 2.2.1 +# release as it needs 2.10 %define gconsole 1 -%if %{rh7} || %{rh8} || %{rh9} || %{wb3} || %{fc1} || %{su9} +%if %{rh7} || %{rh8} || %{rh9} || %{wb3} || %{fc1} || %{fc3} || %{fc4} || %{su9} || %{su10} %define gconsole 0 %endif %if %{mdk} && ! %{mdv} @@ -230,6 +245,11 @@ Distribution: %{_dist} %define wxconsole 0 %{?build_wxconsole:%define wxconsole 1} +# Should we build bat +# requires >= Qt-4.2 +%define bat 0 +%{?build_bat:%define bat 1} + # should we turn on python support %define python 0 %{?build_python:%define python 1} @@ -266,6 +286,20 @@ BuildRequires: python, python-devel %if %{gconsole} BuildRequires: pkgconfig, pango-devel, atk-devel %endif + +# Rh qt4 packages don't provide, guess what, qt! +# so fix for broken rh +%define broken_rh 0 +%if %{rhel5} || %{centos5} || %{sl5} || %{fc5} || %{fc6} || %{fc7} +%define broken_rh 1" +%endif +%if %{bat} && ! %{broken_rh} +BuildRequires: qt-devel >= 4.2 +%endif +%if %{bat} && %{broken_rh} +BuildRequires: qt4-devel >= 4.2 +%endif + %if %{rh7} BuildRequires: libtermcap-devel BuildRequires: glibc-devel >= 2.2 @@ -413,11 +447,25 @@ BuildRequires: libbonoboui-devel >= 2.16 BuildRequires: GConf2-devel BuildRequires: freetype-devel %endif -%if ! %{rh7} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{mdk} && ! %{fc3} && ! %{fc4} && ! %{fc5} && ! %{fc6} +%if %{fc7} +BuildRequires: libtermcap-devel +BuildRequires: glibc-devel >= 2.5 +%endif +%if %{fc7} && %{gconsole} +BuildRequires: gtk2-devel >= 2.10 +BuildRequires: libgnomeui-devel >= 2.18 +BuildRequires: ORBit2-devel +BuildRequires: libart_lgpl-devel >= 2.3 +BuildRequires: libbonobo-devel >= 2.18 +BuildRequires: libbonoboui-devel >= 2.18 +BuildRequires: GConf2-devel +BuildRequires: freetype-devel +%endif +%if ! %{rh7} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{mdk} && ! %{fc3} && ! %{fc4} && ! %{fc5} && ! %{fc6} && ! %{fc7} BuildRequires: libtermcap-devel BuildRequires: glibc-devel >= 2.3 %endif -%if ! %{rh7} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{mdk} && ! %{fc3} && ! %{fc4} && ! %{fc5} && ! %{fc6} && %{gconsole} +%if ! %{rh7} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{mdk} && ! %{fc3} && ! %{fc4} && ! %{fc5} && ! %{fc6} && ! %{fc7} && %{gconsole} BuildRequires: gtk2-devel >= 2.0 BuildRequires: libgnomeui-devel >= 2.0 BuildRequires: ORBit2-devel @@ -499,7 +547,7 @@ Requires: termcap Requires: glibc >= 2.5 Requires: termcap %endif -%if ! %{rh7} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{fc5} && ! %{fc6} +%if ! %{rh7} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{fc5} && ! %{fc6} && ! %{fc7} Requires: glibc >= 2.3 Requires: libtermcap %endif @@ -507,7 +555,7 @@ Requires: libtermcap Requires: glibc >= 2.4 Requires: libtermcap %endif -%if %{fc6} +%if %{fc6} || %{fc7} Requires: glibc >= 2.5 Requires: libtermcap %endif @@ -647,7 +695,7 @@ Requires: libtermcap Requires: glibc >= 2.4 Requires: libtermcap %endif -%if %{fc6} +%if %{fc6} || %{fc7} Requires: glibc >= 2.5 Requires: libtermcap %endif @@ -817,7 +865,18 @@ Requires: libbonoboui >= 2.16 Requires: GConf2 Requires: freetype %endif -%if %{gconsole} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{mdk} && ! %{fc3} && ! %{fc4} && ! %{fc5} && ! %{fc6} +%if %{gconsole} && %{fc7} +Requires: gtk2 >= 2.10 +Requires: libgnomeui >= 2.18 +Requires: glibc >= 2.5 +Requires: ORBit2 +Requires: libart_lgpl >= 2.3 +Requires: libbonobo >= 2.18 +Requires: libbonoboui >= 2.18 +Requires: GConf2 +Requires: freetype +%endif +%if %{gconsole} && ! %{su9} && ! %{su10} && ! %{su102} && ! %{mdk} && ! %{fc3} && ! %{fc4} && ! %{fc5} && ! %{fc6} && ! %{fc7} Requires: gtk2 >= 2.0 Requires: libgnomeui >= 2.0 Requires: glibc >= 2.3 @@ -890,6 +949,10 @@ Requires: gtk2 >= 2.8 Requires: gtk2 >= 2.10 %endif +%if %{wxconsole} && %{fc7} +Requires: gtk2 >= 2.10 +%endif + %if %{wxconsole} %description wxconsole %{blurb} @@ -906,6 +969,88 @@ This is the WXWindows Console package. It is an add-on to the client or server packages. %endif +%if %{bat} +%package bat +Summary: Bacula - The Network Backup Solution +Group: System Environment/Daemons +%endif + +%if %{bat} && %{su10} +Requires: openssl +Requires: glibc >= 2.4 +Requires: fontconfig +Requires: freetype2 +Requires: libgcc +Requires: libpng +Requires: qt >= 4.2 +Requires: libstdc++ +Requires: zlib +%endif + +%if %{bat} && %{su102} +Requires: openssl +Requires: glibc >= 2.5 +Requires: fontconfig +Requires: freetype2 +Requires: libgcc +Requires: libpng +Requires: qt >= 4.2 +Requires: libstdc++ +Requires: zlib +%endif + +%if %{bat} && %{fc5} +Requires: openssl +Requires: glibc >= 2.4 +Requires: fontconfig +Requires: freetype +Requires: libgcc +Requires: libpng +Requires: qt4 >= 4.2 +Requires: libstdc++ +Requires: zlib +%endif + +%if %{bat} && %{fc6} +Requires: openssl +Requires: glibc >= 2.5 +Requires: fontconfig +Requires: freetype +Requires: libgcc +Requires: libpng +Requires: qt4 >= 4.2 +Requires: libstdc++ +Requires: zlib +%endif + +%if %{bat} && %{fc7} +Requires: openssl +Requires: glibc >= 2.5 +Requires: fontconfig +Requires: freetype +Requires: libgcc +Requires: libpng +Requires: qt4 >= 4.2 +Requires: libstdc++ +Requires: zlib +%endif + +%if %{bat} +%description bat +%{blurb} + +%{blurb2} +%{blurb3} +%{blurb4} +%{blurb5} +%{blurb6} +%{blurb7} +%{blurb8} + +This is the Bacula Administration Tool package. It is an add-on to +the client or server packages. +%endif + %prep %setup @@ -928,6 +1073,9 @@ make sqlite %if ! %{client_only} make mtx %endif +%if %{bat} +make qwt +%endif cd ${cwd} # patches for the bundled sqlite scripts @@ -969,6 +1117,18 @@ export LDFLAGS="${LDFLAGS} -L/usr/lib64/mysql" export LDFLAGS="${LDFLAGS} -L/usr/lib64/python%{pyver}" %endif +# Red Hat's 64 bit installation of QT4 appears to be broken so: +%define qt_path 0 +%if %{rhel5} || %{centos5} || %{sl5} +%define qt_path 1 +%endif +%if %{bat} && %{qt_path} && %{x86_64} +export PATH=/usr/lib64/qt4/bin/:$PATH +export QTDIR=/usr/lib64/qt4/ +export QTINC=/usr/lib64/qt4/include/ +export QTLIB=/usr/lib64/qt4/ +%endif + %configure \ --prefix=/usr \ --sbindir=/usr/sbin \ @@ -1009,13 +1169,20 @@ make --with-postgresql \ %endif %if %{wxconsole} - --enable-wx-console \ + --enable-bwx-console \ +%endif +%if %{bat} + --enable-bat \ + --with-qwt=${cwd}/%{depkgs}/qwt \ %endif %if %{python} --with-python \ %endif %if %{client_only} --enable-client-only \ +%endif +%if %{rh7} || %{rh8} || %{rh9} || %{fc1} || %{fc3} || %{wb3} + --disable-batch-insert \ %endif --mandir=%{_mandir} \ --with-subsys-dir=/var/lock/subsys \ @@ -1046,12 +1213,12 @@ mkdir -p $RPM_BUILD_ROOT/etc/log.d/conf/services mkdir -p $RPM_BUILD_ROOT/etc/log.d/scripts/services mkdir -p $RPM_BUILD_ROOT%{script_dir}/updatedb -%if %{gconsole} || %{wxconsole} +%if %{gconsole} || %{wxconsole} || %{bat} mkdir -p $RPM_BUILD_ROOT/usr/share/applications mkdir -p $RPM_BUILD_ROOT/usr/share/pixmaps %endif -%if %{gconsole} || %{wxconsole} +%if %{gconsole} || %{wxconsole} || %{bat} %define usermode_iftrick 1 %else %define usermode_iftrick 0 @@ -1094,22 +1261,25 @@ cd ${cwd} # make install in manpages installs _everything_ shotgun style # so now delete what we will not be packaging %if ! %{wxconsole} -rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bacula-wxconsole.1.gz +rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bacula-bwxconsole.1.%{manpage_ext} +%endif +%if ! %{bat} +rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bat.1.%{manpage_ext} %endif %if ! %{gconsole} -rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bacula-console-gnome.1.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bacula-tray-monitor.1.gz +rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bacula-bgnome-console.1.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bacula-tray-monitor.1.%{manpage_ext} %endif %if %{client_only} -rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bsmtp.1.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bacula-dir.8.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bacula-sd.8.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bcopy.8.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bextract.8.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bls.8.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bscan.8.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man8/btape.8.gz -rm -f $RPM_BUILD_ROOT%{_mandir}/man8/dbcheck.8.gz +rm -f $RPM_BUILD_ROOT%{_mandir}/man1/bsmtp.1.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bacula-dir.8.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bacula-sd.8.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bcopy.8.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bextract.8.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bls.8.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man8/bscan.8.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man8/btape.8.%{manpage_ext} +rm -f $RPM_BUILD_ROOT%{_mandir}/man8/dbcheck.8.%{manpage_ext} %endif # fixme - make installs the mysql scripts for sqlite build @@ -1181,7 +1351,11 @@ cp -p scripts/wxconsole.desktop.xsu $RPM_BUILD_ROOT/usr/share/applications/wxcon cp -p src/wx-console/wxwin16x16.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/wxwin16x16.xpm cp -p scripts/wxconsole.desktop.xsu $RPM_BUILD_ROOT/usr/share/applications/wxconsole.desktop %endif -%if %{rh8} || %{rh9} || %{wb3} || %{fc1} || %{fc3} || %{fc4} || %{fc5} || %{mdk} +%if %{bat} && %{su102} +cp -p src/qt-console/images/bat_icon.png $RPM_BUILD_ROOT/usr/share/pixmaps/bat_icon.png +cp -p scripts/bat.desktop.xsu $RPM_BUILD_ROOT/usr/share/applications/bat.desktop +%endif +%if %{rh8} || %{rh9} || %{wb3} || %{fc1} || %{fc3} || %{fc4} || %{fc5} || %{fc6} || %{fc7} || %{mdk} %define iftrick 1 %else %define iftrick 0 @@ -1189,9 +1363,9 @@ cp -p scripts/wxconsole.desktop.xsu $RPM_BUILD_ROOT/usr/share/applications/wxcon %if %{gconsole} && %{iftrick} cp -p scripts/bacula.png $RPM_BUILD_ROOT/usr/share/pixmaps/bacula.png cp -p scripts/bacula.desktop.gnome2.consolehelper $RPM_BUILD_ROOT/usr/share/applications/bacula.desktop -cp -p scripts/gnome-console.console_apps $RPM_BUILD_ROOT/etc/security/console.apps/gnome-console -cp -p scripts/gnome-console.pamd $RPM_BUILD_ROOT/etc/pam.d/gnome-console -ln -sf consolehelper $RPM_BUILD_ROOT/usr/bin/gnome-console +cp -p scripts/bgnome-console.console_apps $RPM_BUILD_ROOT/etc/security/console.apps/bgnome-console +cp -p scripts/bgnome-console.pamd $RPM_BUILD_ROOT/etc/pam.d/bgnome-console +ln -sf consolehelper $RPM_BUILD_ROOT/usr/bin/bgnome-console %endif %if %{gconsole} && ! %{rh8} cp -p src/tray-monitor/generic.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/bacula-tray-monitor.xpm @@ -1200,9 +1374,16 @@ cp -p scripts/bacula-tray-monitor.desktop $RPM_BUILD_ROOT/usr/share/applications %if %{wxconsole} && %{iftrick} cp -p src/wx-console/wxwin16x16.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/wxwin16x16.xpm cp -p scripts/wxconsole.desktop.consolehelper $RPM_BUILD_ROOT/usr/share/applications/wxconsole.desktop -cp -p scripts/wxconsole.console_apps $RPM_BUILD_ROOT/etc/security/console.apps/wxconsole -cp -p scripts/wxconsole.pamd $RPM_BUILD_ROOT/etc/pam.d/wxconsole -ln -sf consolehelper $RPM_BUILD_ROOT/usr/bin/wxconsole +cp -p scripts/wxconsole.console_apps $RPM_BUILD_ROOT/etc/security/console.apps/bwx-console +cp -p scripts/wxconsole.pamd $RPM_BUILD_ROOT/etc/pam.d/bwx-console +ln -sf consolehelper $RPM_BUILD_ROOT/usr/bin/bwx-console +%endif +%if %{bat} && %{iftrick} +cp -p src/qt-console/images/bat_icon.png $RPM_BUILD_ROOT/usr/share/pixmaps/bat_icon.png +cp -p scripts/bat.desktop.consolehelper $RPM_BUILD_ROOT/usr/share/applications/bat.desktop +cp -p scripts/bat.console_apps $RPM_BUILD_ROOT/etc/security/console.apps/bat +cp -p scripts/bat.pamd $RPM_BUILD_ROOT/etc/pam.d/bat +ln -sf consolehelper $RPM_BUILD_ROOT/usr/bin/bat %endif # install sqlite @@ -1240,9 +1421,10 @@ touch $RPM_BUILD_ROOT%{sysconf_dir}/rescue/linux/cdrom/rpm_release cp -p src/filed/static-bacula-fd $RPM_BUILD_ROOT%{sysconf_dir}/rescue/linux/cdrom/bacula/bin/bacula-fd rm -f src/filed/static-bacula-fd -%if %{wxconsole} -mv $RPM_BUILD_ROOT/usr/sbin/wx-console $RPM_BUILD_ROOT/usr/sbin/wxconsole -mv $RPM_BUILD_ROOT%{sysconf_dir}/wx-console.conf $RPM_BUILD_ROOT%{sysconf_dir}/wxconsole.conf +# install bat since make doesn't at the moment +%if %{bat} +cp -p src/qt-console/bat $RPM_BUILD_ROOT/usr/sbin/bat +cp -p src/qt-console/bat.conf $RPM_BUILD_ROOT%{sysconf_dir}/bat.conf %endif # now clean up permissions that are left broken by the install @@ -1540,6 +1722,7 @@ else echo "Hmm, doesn't look like you have an existing database." echo "Creating SQLite database..." %{script_dir}/create_sqlite_database + chown %{director_daemon_user}.%{daemon_group} %{working_dir}/bacula.db echo "Creating the SQLite tables..." %{script_dir}/make_sqlite_tables fi @@ -1616,10 +1799,13 @@ fi %attr(-, root, %{storage_daemon_group}) /usr/sbin/mtx %attr(-, root, %{storage_daemon_group}) /usr/sbin/scsitape %attr(-, root, %{storage_daemon_group}) /usr/sbin/tapeinfo +%attr(-, root, %{storage_daemon_group}) /usr/sbin/nsmhack +%attr(-, root, %{storage_daemon_group}) /usr/sbin/scsieject %{_mandir}/man1/loaderinfo.1.%{manpage_ext} %{_mandir}/man1/mtx.1.%{manpage_ext} %{_mandir}/man1/scsitape.1.%{manpage_ext} %{_mandir}/man1/tapeinfo.1.%{manpage_ext} +%{_mandir}/man1/scsieject.1.%{manpage_ext} %endif %files client @@ -1722,13 +1908,13 @@ echo "The database update scripts were installed to %{script_dir}/updatedb" %if %{gconsole} %files gconsole %defattr(-,root,root) -/usr/sbin/gnome-console +/usr/sbin/bgnome-console %attr(-, root, %{daemon_group}) %dir %{script_dir} %attr(-, root, %{daemon_group}) %{script_dir}/gconsole -%attr(-, root, %{daemon_group}) %config(noreplace) %{sysconf_dir}/gnome-console.conf +%attr(-, root, %{daemon_group}) %config(noreplace) %{sysconf_dir}/bgnome-console.conf /usr/share/pixmaps/bacula.png /usr/share/applications/bacula.desktop -%{_mandir}/man1/bacula-console-gnome.1.%{manpage_ext} +%{_mandir}/man1/bacula-bgnome-console.1.%{manpage_ext} %endif %if %{gconsole} && ! %{rh8} @@ -1741,9 +1927,9 @@ echo "The database update scripts were installed to %{script_dir}/updatedb" %if %{gconsole} && ! %{su9} && ! %{su10} && ! %{su102} # add the console helper files -%config(noreplace,missingok) /etc/pam.d/gnome-console -%config(noreplace,missingok) /etc/security/console.apps/gnome-console -/usr/bin/gnome-console +%config(noreplace,missingok) /etc/pam.d/bgnome-console +%config(noreplace,missingok) /etc/security/console.apps/bgnome-console +/usr/bin/bgnome-console %endif %if %{gconsole} @@ -1776,19 +1962,19 @@ fi %if %{wxconsole} %files wxconsole %defattr(-,root,root) -/usr/sbin/wxconsole +/usr/sbin/bwx-console %attr(-, root, %{daemon_group}) %dir %{sysconf_dir} -%attr(-, root, %{daemon_group}) %config(noreplace) %{sysconf_dir}/wxconsole.conf +%attr(-, root, %{daemon_group}) %config(noreplace) %{sysconf_dir}/bwx-console.conf /usr/share/pixmaps/wxwin16x16.xpm /usr/share/applications/wxconsole.desktop -%{_mandir}/man1/bacula-wxconsole.1.%{manpage_ext} +%{_mandir}/man1/bacula-bwxconsole.1.%{manpage_ext} %endif %if %{wxconsole} && ! %{su9} && ! %{su10} && ! %{su102} # add the console helper files -%config(noreplace,missingok) /etc/pam.d/wxconsole -%config(noreplace,missingok) /etc/security/console.apps/wxconsole -/usr/bin/wxconsole +%config(noreplace,missingok) /etc/pam.d/bwx-console +%config(noreplace,missingok) /etc/security/console.apps/bwx-console +/usr/bin/bwx-console %endif %if %{wxconsole} @@ -1818,7 +2004,81 @@ if [ -d %{sysconf_dir} ]; then fi %endif +%if %{bat} +%files bat +%defattr(-,root,root) +/usr/sbin/bat +%attr(-, root, %{daemon_group}) %dir %{sysconf_dir} +%attr(-, root, %{daemon_group}) %config(noreplace) %{sysconf_dir}/bat.conf +/usr/share/pixmaps/bat_icon.png +/usr/share/applications/bat.desktop +%{_mandir}/man1/bat.1.%{manpage_ext} +%endif + +%if %{bat} && ! %{su9} && ! %{su10} && ! %{su102} +# add the console helper files +%config(noreplace,missingok) /etc/pam.d/bat +%config(noreplace,missingok) /etc/security/console.apps/bat +/usr/bin/bat +%endif + +%if %{bat} +%pre bat +# create the daemon group +HAVE_BACULA=`grep %{daemon_group} %{group_file} 2>/dev/null` +if [ -z "$HAVE_BACULA" ]; then + %{groupadd} -r %{daemon_group} > /dev/null 2>&1 + echo "The group %{daemon_group} has been added to %{group_file}." + echo "See the manual chapter \"Running Bacula\" for details." +fi + +%post bat +# generate passwords if needed +if [ -d %{sysconf_dir} ]; then + cd %{sysconf_dir} + for file in *.conf; do + for string in XXX_REPLACE_WITH_DIRECTOR_PASSWORD_XXX XXX_REPLACE_WITH_CLIENT_PASSWORD_XXX XXX_REPLACE_WITH_STORAGE_PASSWORD_XXX XXX_REPLACE_WITH_DIRECTOR_MONITOR_PASSWORD_XXX XXX_REPLACE_WITH_CLIENT_MONITOR_PASSWORD_XXX XXX_REPLACE_WITH_STORAGE_MONITOR_PASSWORD_XXX; do + need_password=`grep $string $file 2>/dev/null` + if [ -n "$need_password" ]; then + pass=`openssl rand -base64 33` + sed "s-$string-$pass-g" $file > $file.new + cp -f $file.new $file; rm -f $file.new + fi + done + done +fi +%endif + %changelog +* Sun Nov 04 2007 D. Scott Barninger +- fix dist defines for rhel5 and clones +- fix rhel broken 64 bit QT4 paths +- rh qt4 packages don't provide qt so fix that too +* Mon Oct 29 2007 D. Scott Barninger +- correct ownership when creating sqlite db file in post script +* Sun Sep 16 2007 D. Scott Barninger +- fix disable-batch-insert +* Fri Sep 14 2007 D. Scott Barninger +- 2.2.4 release +- turn off gconsole build for fc3, tray monitor fails to build +- add new files for mtx package (09Sep07 depkgs update) +* Sat Sep 08 2007 D. Scott Barninger +- add --disable-batch-insert for older platforms +- add build targets for rhel5 and clones +* Mon Sep 03 2007 D. Scott Barninger +- 2.2.1 release +- turn off gconsole build for su10 & fc4, tray monitor fails to build +* Sat Jul 14 2007 D. Scott Barninger +- 2.1.26 add make of qwt in depkgs for bat +* Sat Jun 02 2007 D. Scott Barninger +- upgrade Qt requirement for bat to 4.2 +* Sun May 06 2007 D. Scott Barninger +- add fc7 build target +* Sun Apr 29 2007 D. Scott Barninger +- 2.1.8 +- gnome-console now bgnome-console +- wxconsole now bwx-console +- add build option for bat * Sat Apr 08 2007 D. Scott Barninger - merge Otto Mueller's patch but keep script dir set to /etc/bacula - add build tag for Scientific Linux per Jon Peatfield