scripts/bacula-tray-monitor.desktop \
scripts/logwatch/Makefile \
scripts/logwatch/logfile.bacula.conf \
+ scripts/wxconsole.console_apps \
+ scripts/wxconsole.desktop.consolehelper \
+ scripts/wxconsole.desktop.xsu \
src/Makefile \
src/host.h \
src/console/Makefile \
exit 1
fi
- ac_config_files="$ac_config_files autoconf/Make.common Makefile scripts/startmysql scripts/stopmysql scripts/btraceback scripts/startit scripts/stopit scripts/bconsole scripts/gconsole scripts/bacula scripts/bacula-ctl-dir scripts/bacula-ctl-fd scripts/bacula-ctl-sd scripts/devel_bacula scripts/Makefile scripts/logrotate scripts/bacula.desktop.gnome1 scripts/bacula.desktop.gnome2 scripts/bacula.desktop.gnome1.consolehelper scripts/bacula.desktop.gnome2.consolehelper scripts/bacula.desktop.gnome1.xsu scripts/bacula.desktop.gnome2.xsu scripts/gnome-console.console_apps scripts/mtx-changer scripts/disk-changer scripts/dvd-handler scripts/bacula-tray-monitor.desktop scripts/logwatch/Makefile scripts/logwatch/logfile.bacula.conf src/Makefile src/host.h src/console/Makefile src/console/bconsole.conf src/gnome2-console/Makefile src/gnome2-console/gnome-console.conf src/wx-console/Makefile src/wx-console/wx-console.conf src/tray-monitor/Makefile src/tray-monitor/tray-monitor.conf src/dird/Makefile src/dird/bacula-dir.conf src/lib/Makefile src/stored/Makefile src/stored/bacula-sd.conf src/filed/Makefile src/filed/bacula-fd.conf src/filed/win32/Makefile src/cats/Makefile src/cats/make_catalog_backup src/cats/delete_catalog_backup src/cats/create_postgresql_database src/cats/update_postgresql_tables src/cats/make_postgresql_tables src/cats/grant_postgresql_privileges src/cats/drop_postgresql_tables src/cats/drop_postgresql_database src/cats/create_mysql_database src/cats/update_mysql_tables src/cats/make_mysql_tables src/cats/grant_mysql_privileges src/cats/drop_mysql_tables src/cats/drop_mysql_database src/cats/create_sqlite_database src/cats/update_sqlite_tables src/cats/make_sqlite_tables src/cats/grant_sqlite_privileges src/cats/drop_sqlite_tables src/cats/drop_sqlite_database src/cats/create_sqlite3_database src/cats/update_sqlite3_tables src/cats/make_sqlite3_tables src/cats/grant_sqlite3_privileges src/cats/drop_sqlite3_tables src/cats/drop_sqlite3_database src/cats/sqlite src/cats/mysql src/cats/create_bdb_database src/cats/update_bdb_tables src/cats/make_bdb_tables src/cats/grant_bdb_privileges src/cats/drop_bdb_tables src/cats/drop_bdb_database src/cats/create_bacula_database src/cats/update_bacula_tables src/cats/grant_bacula_privileges src/cats/make_bacula_tables src/cats/drop_bacula_tables src/cats/drop_bacula_database src/findlib/Makefile src/pygtk-console/Makefile src/tools/Makefile src/win32/winbacula.nsi src/win32/baculafd/bacula-fd.conf src/win32/Makefile src/win32/console/bconsole.conf src/win32/wx-console/wx-console.conf src/win32/pebuilder/Makefile po/Makefile.in $PFILES"
+ ac_config_files="$ac_config_files autoconf/Make.common Makefile scripts/startmysql scripts/stopmysql scripts/btraceback scripts/startit scripts/stopit scripts/bconsole scripts/gconsole scripts/bacula scripts/bacula-ctl-dir scripts/bacula-ctl-fd scripts/bacula-ctl-sd scripts/devel_bacula scripts/Makefile scripts/logrotate scripts/bacula.desktop.gnome1 scripts/bacula.desktop.gnome2 scripts/bacula.desktop.gnome1.consolehelper scripts/bacula.desktop.gnome2.consolehelper scripts/bacula.desktop.gnome1.xsu scripts/bacula.desktop.gnome2.xsu scripts/gnome-console.console_apps scripts/mtx-changer scripts/disk-changer scripts/dvd-handler scripts/bacula-tray-monitor.desktop scripts/logwatch/Makefile scripts/logwatch/logfile.bacula.conf scripts/wxconsole.console_apps scripts/wxconsole.desktop.consolehelper scripts/wxconsole.desktop.xsu src/Makefile src/host.h src/console/Makefile src/console/bconsole.conf src/gnome2-console/Makefile src/gnome2-console/gnome-console.conf src/wx-console/Makefile src/wx-console/wx-console.conf src/tray-monitor/Makefile src/tray-monitor/tray-monitor.conf src/dird/Makefile src/dird/bacula-dir.conf src/lib/Makefile src/stored/Makefile src/stored/bacula-sd.conf src/filed/Makefile src/filed/bacula-fd.conf src/filed/win32/Makefile src/cats/Makefile src/cats/make_catalog_backup src/cats/delete_catalog_backup src/cats/create_postgresql_database src/cats/update_postgresql_tables src/cats/make_postgresql_tables src/cats/grant_postgresql_privileges src/cats/drop_postgresql_tables src/cats/drop_postgresql_database src/cats/create_mysql_database src/cats/update_mysql_tables src/cats/make_mysql_tables src/cats/grant_mysql_privileges src/cats/drop_mysql_tables src/cats/drop_mysql_database src/cats/create_sqlite_database src/cats/update_sqlite_tables src/cats/make_sqlite_tables src/cats/grant_sqlite_privileges src/cats/drop_sqlite_tables src/cats/drop_sqlite_database src/cats/create_sqlite3_database src/cats/update_sqlite3_tables src/cats/make_sqlite3_tables src/cats/grant_sqlite3_privileges src/cats/drop_sqlite3_tables src/cats/drop_sqlite3_database src/cats/sqlite src/cats/mysql src/cats/create_bdb_database src/cats/update_bdb_tables src/cats/make_bdb_tables src/cats/grant_bdb_privileges src/cats/drop_bdb_tables src/cats/drop_bdb_database src/cats/create_bacula_database src/cats/update_bacula_tables src/cats/grant_bacula_privileges src/cats/make_bacula_tables src/cats/drop_bacula_tables src/cats/drop_bacula_database src/findlib/Makefile src/pygtk-console/Makefile src/tools/Makefile src/win32/winbacula.nsi src/win32/baculafd/bacula-fd.conf src/win32/Makefile src/win32/console/bconsole.conf src/win32/wx-console/wx-console.conf src/win32/pebuilder/Makefile po/Makefile.in $PFILES"
ac_config_commands="$ac_config_commands default"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
"scripts/bacula-tray-monitor.desktop" ) CONFIG_FILES="$CONFIG_FILES scripts/bacula-tray-monitor.desktop" ;;
"scripts/logwatch/Makefile" ) CONFIG_FILES="$CONFIG_FILES scripts/logwatch/Makefile" ;;
"scripts/logwatch/logfile.bacula.conf" ) CONFIG_FILES="$CONFIG_FILES scripts/logwatch/logfile.bacula.conf" ;;
+ "scripts/wxconsole.console_apps" ) CONFIG_FILES="$CONFIG_FILES scripts/wxconsole.console_apps" ;;
+ "scripts/wxconsole.desktop.consolehelper" ) CONFIG_FILES="$CONFIG_FILES scripts/wxconsole.desktop.consolehelper" ;;
+ "scripts/wxconsole.desktop.xsu" ) CONFIG_FILES="$CONFIG_FILES scripts/wxconsole.desktop.xsu" ;;
"src/Makefile" ) CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
"src/host.h" ) CONFIG_FILES="$CONFIG_FILES src/host.h" ;;
"src/console/Makefile" ) CONFIG_FILES="$CONFIG_FILES src/console/Makefile" ;;
# specifically disallow gconsole if desired
%{?nobuild_gconsole:%define gconsole 0}
+# Should we build wxconsole, only wxWidgets >=2.6 is supported
+# currently only SuSE 10 and FC4
+%define wxconsole 0
+%{?build_wxconsole:%define wxconsole 1}
+
Summary: Bacula - The Network Backup Solution
Name: bacula
Version: @VERSION@
BuildRequires: postgresql-devel >= 7
%endif
+%if %{wxconsole}
+BuildRequires: wxGTK-devel >= 2.6
+%endif
+
%description
Bacula - It comes by night and sucks the vital essence from your computers.
server packages.
%endif
+%if %{wxconsole}
+%package wxconsole
+Summary: Bacula - The Network Backup Solution
+Group: System Environment/Daemons
+Requires: wxGTK >= 2.6, libstdc++, openssl
+%endif
+
+%if %{wxconsole} && %{su10}
+Requires: gtk2 >= 2.8
+%endif
+
+%if %{wxconsole} && %{fc4}
+Requires: gtk2 >= 2.6
+%endif
+
+%if %{wxconsole}
+%description wxconsole
+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.
+Bacula source code has been released under the GPL version 2 license.
+
+This is the WXWindows Console package. It is an add-on to the client or
+server packages.
+%endif
+
%prep
%setup
%endif
%if %{postgresql}
--with-postgresql \
+%endif
+%if %{wxconsole}
+ --enable-wx-console \
%endif
--with-working-dir=%{working_dir} \
--with-pid-dir=/var/run \
cp -p src/tray-monitor/generic.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/bacula-tray-monitor.xpm
cp -p scripts/bacula-tray-monitor.desktop $RPM_BUILD_ROOT/usr/share/applications/bacula-tray-monitor.desktop
%endif
+%if %{wxconsole} && %{su10}
+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} || %{mdk}
%define iftrick 1
%else
cp -p src/tray-monitor/generic.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/bacula-tray-monitor.xpm
cp -p scripts/bacula-tray-monitor.desktop $RPM_BUILD_ROOT/usr/share/applications/bacula-tray-monitor.desktop
%endif
+%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
+%endif
# install sqlite
%if %{sqlite}
cp -p src/filed/static-bacula-fd $RPM_BUILD_ROOT/etc/bacula/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/etc/bacula/wx-console.conf $RPM_BUILD_ROOT/etc/bacula/wxconsole.conf
+%endif
+
# now clean up permissions that are left broken by the install
chmod o-r $RPM_BUILD_ROOT/etc/bacula/query.sql
chmod o-rwx $RPM_BUILD_ROOT/var/bacula
fi
%endif
+%if %{wxconsole}
+%files wxconsole
+%defattr(-,root,root)
+/usr/sbin/wxconsole
+%attr(-, root, %{daemon_group}) %dir /etc/bacula
+%attr(-, root, %{daemon_group}) %config(noreplace) /etc/bacula/wxconsole.conf
+/usr/share/pixmaps/wxwin16x16.xpm
+%endif
+
+%if %{wxconsole}
+/usr/share/applications/wxconsole.desktop
+%endif
+
+%if %{wxconsole} && ! %{su9} && ! %{su10}
+# add the console helper files
+%config(noreplace,missingok) /etc/pam.d/wxconsole
+%config(noreplace,missingok) /etc/security/console.apps/wxconsole
+/usr/bin/wxconsole
+%endif
+
+%if %{wxconsole}
+%pre wxconsole
+# 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 wxconsole
+# generate passwords if needed
+if [ -d /etc/bacula ]; then
+ cd /etc/bacula
+ 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 Apr 16 2006 D. Scott Barninger <barninger@fairfieldcomputers.com>
+- add wxconsole package
* Fri Apr 14 2006 D. Scott Barninger <barninger@fairfieldcomputers.com>
- 1.38.8 release
- dependency update for Mandriva
# specifically disallow gconsole if desired
%{?nobuild_gconsole:%define gconsole 0}
+# Should we build wxconsole, only wxWidgets >=2.6 is supported
+# currently only SuSE 10 and FC4
+%define wxconsole 0
+%{?build_wxconsole:%define wxconsole 1}
+
Summary: Bacula - The Network Backup Solution
Name: bacula
Version: @VERSION@
BuildRequires: postgresql-devel >= 7
%endif
+%if %{wxconsole}
+BuildRequires: wxGTK-devel >= 2.6
+%endif
+
%description
Bacula - It comes by night and sucks the vital essence from your computers.
server packages.
%endif
+%if %{wxconsole}
+%package wxconsole
+Summary: Bacula - The Network Backup Solution
+Group: System Environment/Daemons
+Requires: wxGTK >= 2.6, libstdc++, openssl
+%endif
+
+%if %{wxconsole} && %{su10}
+Requires: gtk2 >= 2.8
+%endif
+
+%if %{wxconsole} && %{fc4}
+Requires: gtk2 >= 2.6
+%endif
+
+%if %{wxconsole}
+%description wxconsole
+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.
+Bacula source code has been released under the GPL version 2 license.
+
+This is the WXWindows Console package. It is an add-on to the client or
+server packages.
+%endif
+
%prep
%setup
%endif
%if %{postgresql}
--with-postgresql \
+%endif
+%if %{wxconsole}
+ --enable-wx-console \
%endif
--with-working-dir=%{working_dir} \
--with-pid-dir=/var/run \
cp -p src/tray-monitor/generic.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/bacula-tray-monitor.xpm
cp -p scripts/bacula-tray-monitor.desktop $RPM_BUILD_ROOT/usr/share/applications/bacula-tray-monitor.desktop
%endif
+%if %{wxconsole} && %{su10}
+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} || %{mdk}
%define iftrick 1
%else
cp -p src/tray-monitor/generic.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/bacula-tray-monitor.xpm
cp -p scripts/bacula-tray-monitor.desktop $RPM_BUILD_ROOT/usr/share/applications/bacula-tray-monitor.desktop
%endif
+%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
+%endif
# install sqlite
%if %{sqlite}
cp -p src/filed/static-bacula-fd $RPM_BUILD_ROOT/etc/bacula/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/etc/bacula/wx-console.conf $RPM_BUILD_ROOT/etc/bacula/wxconsole.conf
+%endif
+
# now clean up permissions that are left broken by the install
chmod o-r $RPM_BUILD_ROOT/etc/bacula/query.sql
chmod o-rwx $RPM_BUILD_ROOT/var/bacula
fi
%endif
+%if %{wxconsole}
+%files wxconsole
+%defattr(-,root,root)
+/usr/sbin/wxconsole
+%attr(-, root, %{daemon_group}) %dir /etc/bacula
+%attr(-, root, %{daemon_group}) %config(noreplace) /etc/bacula/wxconsole.conf
+/usr/share/pixmaps/wxwin16x16.xpm
+%endif
+
+%if %{wxconsole}
+/usr/share/applications/wxconsole.desktop
+%endif
+
+%if %{wxconsole} && ! %{su9} && ! %{su10}
+# add the console helper files
+%config(noreplace,missingok) /etc/pam.d/wxconsole
+%config(noreplace,missingok) /etc/security/console.apps/wxconsole
+/usr/bin/wxconsole
+%endif
+
+%if %{wxconsole}
+%pre wxconsole
+# 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 wxconsole
+# generate passwords if needed
+if [ -d /etc/bacula ]; then
+ cd /etc/bacula
+ 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 Apr 16 2006 D. Scott Barninger <barninger@fairfieldcomputers.com>
+- add wxconsole package
* Fri Apr 14 2006 D. Scott Barninger <barninger@fairfieldcomputers.com>
- 1.38.8 release
- dependency update for Mandriva
# specifically disallow gconsole if desired
%{?nobuild_gconsole:%define gconsole 0}
+# Should we build wxconsole, only wxWidgets >=2.6 is supported
+# currently only SuSE 10 and FC4
+%define wxconsole 0
+%{?build_wxconsole:%define wxconsole 1}
+
Summary: Bacula - The Network Backup Solution
Name: bacula
Version: @VERSION@
BuildRequires: postgresql-devel >= 7
%endif
+%if %{wxconsole}
+BuildRequires: wxGTK-devel >= 2.6
+%endif
+
%description
Bacula - It comes by night and sucks the vital essence from your computers.
server packages.
%endif
+%if %{wxconsole}
+%package wxconsole
+Summary: Bacula - The Network Backup Solution
+Group: System Environment/Daemons
+Requires: wxGTK >= 2.6, libstdc++, openssl
+%endif
+
+%if %{wxconsole} && %{su10}
+Requires: gtk2 >= 2.8
+%endif
+
+%if %{wxconsole} && %{fc4}
+Requires: gtk2 >= 2.6
+%endif
+
+%if %{wxconsole}
+%description wxconsole
+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.
+Bacula source code has been released under the GPL version 2 license.
+
+This is the WXWindows Console package. It is an add-on to the client or
+server packages.
+%endif
+
%prep
%setup
%endif
%if %{postgresql}
--with-postgresql \
+%endif
+%if %{wxconsole}
+ --enable-wx-console \
%endif
--with-working-dir=%{working_dir} \
--with-pid-dir=/var/run \
cp -p src/tray-monitor/generic.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/bacula-tray-monitor.xpm
cp -p scripts/bacula-tray-monitor.desktop $RPM_BUILD_ROOT/usr/share/applications/bacula-tray-monitor.desktop
%endif
+%if %{wxconsole} && %{su10}
+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} || %{mdk}
%define iftrick 1
%else
cp -p src/tray-monitor/generic.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/bacula-tray-monitor.xpm
cp -p scripts/bacula-tray-monitor.desktop $RPM_BUILD_ROOT/usr/share/applications/bacula-tray-monitor.desktop
%endif
+%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
+%endif
# install sqlite
%if %{sqlite}
cp -p src/filed/static-bacula-fd $RPM_BUILD_ROOT/etc/bacula/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/etc/bacula/wx-console.conf $RPM_BUILD_ROOT/etc/bacula/wxconsole.conf
+%endif
+
# now clean up permissions that are left broken by the install
chmod o-r $RPM_BUILD_ROOT/etc/bacula/query.sql
chmod o-rwx $RPM_BUILD_ROOT/var/bacula
fi
%endif
+%if %{wxconsole}
+%files wxconsole
+%defattr(-,root,root)
+/usr/sbin/wxconsole
+%attr(-, root, %{daemon_group}) %dir /etc/bacula
+%attr(-, root, %{daemon_group}) %config(noreplace) /etc/bacula/wxconsole.conf
+/usr/share/pixmaps/wxwin16x16.xpm
+%endif
+
+%if %{wxconsole}
+/usr/share/applications/wxconsole.desktop
+%endif
+
+%if %{wxconsole} && ! %{su9} && ! %{su10}
+# add the console helper files
+%config(noreplace,missingok) /etc/pam.d/wxconsole
+%config(noreplace,missingok) /etc/security/console.apps/wxconsole
+/usr/bin/wxconsole
+%endif
+
+%if %{wxconsole}
+%pre wxconsole
+# 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 wxconsole
+# generate passwords if needed
+if [ -d /etc/bacula ]; then
+ cd /etc/bacula
+ 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 Apr 16 2006 D. Scott Barninger <barninger@fairfieldcomputers.com>
+- add wxconsole package
* Fri Apr 14 2006 D. Scott Barninger <barninger@fairfieldcomputers.com>
- 1.38.8 release
- dependency update for Mandriva
--- /dev/null
+USER=root
+PROGRAM=@sbindir@/wxconsole
+SESSION=true
--- /dev/null
+[Desktop Entry]
+Name=Bacula WX Console
+Comment=Bacula Director Console
+Icon=/usr/share/pixmaps/wxwin16x16.xpm
+Exec=/usr/bin/wxconsole -c @sysconfdir@/wxconsole.conf
+Terminal=false
+Type=Application
+Encoding=UTF-8
+X-Desktop-File-Install-Version=0.3
+Categories=System;Application;Utility;X-Red-Hat-Base;
--- /dev/null
+[Desktop Entry]
+Name=Bacula WX Console
+Comment=Bacula Director Console
+Icon=/usr/share/pixmaps/wxwin16x16.xpm
+Exec=gnomesu -t "Query" -c "@sbindir@/wxconsole -c @sysconfdir@/wxconsole.conf" -d -e -m "In order to run the bacula wx console as root, ^additional information is required."
+Terminal=false
+Type=Application
+Encoding=UTF-8
+X-Desktop-File-Install-Version=0.3
+Categories=System;Application;Utility;X-Red-Hat-Base;
--- /dev/null
+#%PAM-1.0
+auth sufficient pam_rootok.so
+auth sufficient pam_timestamp.so
+auth required pam_stack.so service=system-auth
+session optional pam_xauth.so
+session optional pam_timestamp.so
+account required pam_permit.so