# HG changeset patch # User Michael Schloh von Bennewitz # Date 1238675376 -7200 # Node ID 648dc0227614b7a7cfb348ccd7d764b50a6024e5 # Parent 092213021aa544261c5e8f828f2d1f89b487f0e9 Correct path to geodb.dat, add runcommand logic, and mark config files. diff -r 092213021aa5 -r 648dc0227614 webalizer/rc.webalizer --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/webalizer/rc.webalizer Thu Apr 02 14:29:36 2009 +0200 @@ -0,0 +1,21 @@ +#!@l_prefix@/bin/openpkg rc +## +## rc.webalizer -- Run-Commands +## + +%config + webalizer_enable="$openpkg_rc_def" + +%common + webalizer_etcdir="@l_prefix@/etc/webalizer" + webalizer_webdir="@l_prefix@/web/webalizer" + +%daily + rcService webalizer enable yes || exit 0 + + for cfgfile in $webalizer_etcdir/*.conf; do + [ ".`grep '^disable' $cfgfile`" != . ] && continue + @l_prefix@/bin/webalizer \ + -c $cfgfile || exit $? + done + diff -r 092213021aa5 -r 648dc0227614 webalizer/webalizer.spec --- a/webalizer/webalizer.spec Thu Apr 02 14:03:12 2009 +0200 +++ b/webalizer/webalizer.spec Thu Apr 02 14:29:36 2009 +0200 @@ -36,13 +36,14 @@ Group: Logfile License: GPL Version: %{V_here} -Release: 20090401 +Release: 20090402 # package options %option with_dns no # list of sources Source0: ftp://ftp.mrunix.net/pub/webalizer/webalizer-%{V_real}-src.tgz +Source1: rc.webalizer # build information Prefix: %{l_prefix} @@ -81,6 +82,7 @@ ./configure \ --prefix=%{l_prefix} \ --sysconfdir=%{l_prefix}/etc/%{name} \ + --with-geodb=%{l_prefix}/var/%{name} \ %if "%{with_dns}" == "yes" --enable-dns \ %endif @@ -103,7 +105,10 @@ %{l_shtool} mkdir -f -p -m 755 \ $RPM_BUILD_ROOT%{l_prefix}/bin \ $RPM_BUILD_ROOT%{l_prefix}/man/man1 \ - $RPM_BUILD_ROOT%{l_prefix}/etc/webalizer + $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d \ + $RPM_BUILD_ROOT%{l_prefix}/etc/webalizer \ + $RPM_BUILD_ROOT%{l_prefix}/var/webalizer \ + $RPM_BUILD_ROOT%{l_prefix}/web/webalizer %{l_shtool} install -c -s -m 755 \ webalizer $RPM_BUILD_ROOT%{l_prefix}/bin/ %{l_shtool} install -c -m 644 \ @@ -112,7 +117,11 @@ sample.conf $RPM_BUILD_ROOT%{l_prefix}/etc/webalizer/webalizer.conf ln $RPM_BUILD_ROOT%{l_prefix}/bin/webalizer \ $RPM_BUILD_ROOT%{l_prefix}/bin/webazolver - %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} + %{l_shtool} install -c -m 755 %{l_value -s -a} \ + %{SOURCE rc.webalizer} $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d/ + %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \ + %{l_files_std} \ + '%config %{l_prefix}/etc/webalizer/*' %files -f files