- Update to mrtg-2.15.0

- Don't use Prereq: for /sbin/service
- Use (sed -i) instead of perl to make the regexps more readable
This commit is contained in:
Miloslav Trmac 2006-12-06 12:17:08 +00:00
parent 68e1b6db64
commit 9afb96d8f8
4 changed files with 64 additions and 9 deletions

View File

@ -1,2 +1,2 @@
mrtg-2.14.7.tar.gz
mrtg-2.14.7.tar.gz.md5.pgp
mrtg-2.15.0.tar.gz
mrtg-2.15.0.tar.gz.md5.pgp

47
mrtg-2.15.0-lib64.patch Normal file
View File

@ -0,0 +1,47 @@
Blech, give us a relatively simple way to drop in "lib" or "lib64", as
appropriate. Needs fixing to be more correct.
--- mrtg-2.15.0/bin/cfgmaker.lib64 2006-12-06 01:10:06.000000000 +0100
+++ mrtg-2.15.0/bin/cfgmaker 2006-12-06 12:35:16.000000000 +0100
@@ -44,7 +44,7 @@
use FindBin;
use lib "${FindBin::Bin}";
-use lib "${FindBin::Bin}${main::SL}..${main::SL}lib${main::SL}mrtg2";
+use lib "${FindBin::Bin}${main::SL}..${main::SL}@@lib@@${main::SL}mrtg2";
use MRTG_lib "2.100015";
use Getopt::Long;
--- mrtg-2.15.0/bin/mrtg-traffic-sum.lib64 2006-12-06 12:37:19.000000000 +0100
+++ mrtg-2.15.0/bin/mrtg-traffic-sum 2006-12-06 12:38:18.000000000 +0100
@@ -23,7 +23,7 @@
use FindBin;
use lib "${FindBin::Bin}";
-use lib "${FindBin::Bin}${main::SL}..${main::SL}lib${main::SL}mrtg2";
+use lib "${FindBin::Bin}${main::SL}..${main::SL}@@lib@@${main::SL}mrtg2";
use MRTG_lib "2.090017";
use POSIX qw(mktime);
--- mrtg-2.15.0/bin/indexmaker.lib64 2006-12-06 01:10:06.000000000 +0100
+++ mrtg-2.15.0/bin/indexmaker 2006-12-06 12:35:16.000000000 +0100
@@ -48,7 +48,7 @@
use FindBin;
use lib "${FindBin::Bin}";
-use lib "${FindBin::Bin}${main::SL}..${main::SL}lib${main::SL}mrtg2";
+use lib "${FindBin::Bin}${main::SL}..${main::SL}@@lib@@${main::SL}mrtg2";
use MRTG_lib "2.100016";
use Getopt::Long;
--- mrtg-2.15.0/bin/mrtg.lib64 2006-12-06 01:10:06.000000000 +0100
+++ mrtg-2.15.0/bin/mrtg 2006-12-06 12:35:16.000000000 +0100
@@ -81,7 +81,7 @@
use FindBin;
use lib "${FindBin::Bin}";
-use lib "${FindBin::Bin}${main::SL}..${main::SL}lib${main::SL}mrtg2";
+use lib "${FindBin::Bin}${main::SL}..${main::SL}@@lib@@${main::SL}mrtg2";
use Getopt::Long;
use Math::BigFloat;

View File

@ -5,7 +5,7 @@
Summary: Multi Router Traffic Grapher
Name: mrtg
Version: 2.14.7
Version: 2.15.0
Release: 1
URL: http://ee-staff.ethz.ch/~oetiker/webtools/mrtg/
Source0: http://people.ee.ethz.ch/~oetiker/webtools/mrtg/pub/mrtg-%{version}.tar.gz
@ -14,11 +14,13 @@ Source2: mrtg.cfg
Source3: filter-requires-mrtg.sh
Source4: mrtg.crond.in
Source5: mrtg-httpd.conf
Patch0: mrtg-2.14.7-lib64.patch
Patch0: mrtg-2.15.0-lib64.patch
Patch1: mrtg-2.10.5-norpath.patch
License: GPL
Group: Applications/Internet
PreReq: vixie-cron, /sbin/service
PreReq: vixie-cron
Requires(post): /sbin/service
Requires(postun): /sbin/service
Requires: perl-Socket6 perl-IO-Socket-INET6
Buildroot: %{_tmppath}/%{name}-%{version}-root
BuildRequires: gd-devel, libpng-devel
@ -72,11 +74,12 @@ chmod 644 $RPM_BUILD_ROOT%{_sysconfdir}/cron.d/mrtg
install -m 644 %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/mrtg.conf
# Add mrtg-traffic-sum here when upstream decides to install it
for i in mrtg cfgmaker indexmaker; do
%{__perl} -pi -e 's;\@\@lib\@\@;%{_lib};g' $RPM_BUILD_ROOT%{_bindir}/$i
sed -i 's;@@lib@@;%{_lib};g' "$RPM_BUILD_ROOT"%{_bindir}/"$i"
done
%{__perl} -pi -e 's;\@\@lib\@\@;%{_lib};g' $RPM_BUILD_ROOT%{_mandir}/man1/*.1
sed -i 's;@@lib@@;%{_lib};g' "$RPM_BUILD_ROOT"%{_mandir}/man1/*.1
# Tell crond to reload its configuration.
%post
@ -112,6 +115,11 @@ rm -rf $RPM_BUILD_ROOT
%dir %{_localstatedir}/lock/mrtg
%changelog
* Wed Dec 6 2006 Miloslav Trmac <mitr@redhat.com> - 2.15.0-1
- Update to mrtg-2.15.0
- Don't use Prereq: for /sbin/service
- Use (sed -i) instead of perl to make the regexps more readable
* Tue Oct 24 2006 Miloslav Trmac <mitr@redhat.com> - 2.14.7-1
- Update to mrtg-2.14.7

View File

@ -1,2 +1,2 @@
12de12dc27388934ce2521af3f914f33 mrtg-2.14.7.tar.gz
3d8c40bf1c056f6618e7183f01b2a2bb mrtg-2.14.7.tar.gz.md5.pgp
3417d8d43c25f5bcdeebff70e68ccb82 mrtg-2.15.0.tar.gz
72d1f2d3731f82963f9b80cfb8cf33d9 mrtg-2.15.0.tar.gz.md5.pgp