[packages/ipband] - updated to 0.8.1
qboosh
qboosh at pld-linux.org
Sat Jun 28 19:48:29 CEST 2025
commit d1457fae141107300ec4ef122c6815146e5024fc
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Sat Jun 28 19:49:48 2025 +0200
- updated to 0.8.1
ipband-DESTDIR.patch | 17 -----------------
ipband-PLD_rc.patch | 2 +-
ipband-paths.patch | 13 ++++++-------
ipband.spec | 31 +++++++++++++++++--------------
4 files changed, 24 insertions(+), 39 deletions(-)
---
diff --git a/ipband.spec b/ipband.spec
index 03364a9..a824271 100644
--- a/ipband.spec
+++ b/ipband.spec
@@ -1,13 +1,12 @@
Summary: IP bandwidth watchdog
Summary(pl.UTF-8): Monitor ruchu IP
Name: ipband
-Version: 0.8
-Release: 2
-License: GPL
+Version: 0.8.1
+Release: 1
+License: GPL v2+
Group: Networking/Utilities
Source0: http://ipband.sourceforge.net/%{name}-%{version}.tgz
-# Source0-md5: a43dc863c044e7e5665d3e16d4c49770
-Patch0: %{name}-DESTDIR.patch
+# Source0-md5: 23aa932a6b97be3e831a3f8b31d21e6f
Patch1: %{name}-PLD_rc.patch
Patch2: %{name}-paths.patch
URL: http://ipband.sourceforge.net/
@@ -17,8 +16,6 @@ Requires(post,preun): /sbin/chkconfig
Requires: rc-scripts
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-%define _sysconfdir /etc/ipband
-
%description
ipband is pcap based IP traffic monitor. It listens to a network
interface in promiscuous mode, tallies per-subnet traffic and
@@ -43,20 +40,26 @@ poprawne pakiety.
%prep
%setup -q
-%patch -P0 -p1
%patch -P1 -p1
%patch -P2 -p1
%build
+# -fcommon: all global variables are defined in ipband.h
%{__make} \
- CC="%{__cc}"
+ CC="%{__cc}" \
+ CFLAGS="%{rpmcflags} -Wall -fcommon" \
+ CPPFLAGS="%{rpmcppflags} -I/usr/include/pcap"
%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT/var/log
%{__make} install \
- DESTDIR=$RPM_BUILD_ROOT
+ DESTDIR=$RPM_BUILD_ROOT \
+ RCDIR=/etc/rc.d/init.d \
+ SYSCONFDIR=%{_sysconfdir}/ipband
+
+%{__mv} $RPM_BUILD_ROOT%{_sysconfdir}/ipband/ipband{.sample,}.conf
touch $RPM_BUILD_ROOT/var/log/ipband.log
@@ -76,9 +79,9 @@ fi
%files
%defattr(644,root,root,755)
%doc CHANGELOG README
-%attr(755,root,root) %{_bindir}/ipband
-%dir %{_sysconfdir}
-%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ipband.conf
+%attr(755,root,root) %{_sbindir}/ipband
+%dir %{_sysconfdir}/ipband
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ipband/ipband.conf
%attr(754,root,root) /etc/rc.d/init.d/ipband
%attr(640,root,root) %ghost /var/log/ipband.log
-%{_mandir}/man1/ipband.1*
+%{_mandir}/man8/ipband.8*
diff --git a/ipband-DESTDIR.patch b/ipband-DESTDIR.patch
deleted file mode 100644
index 4fc23d5..0000000
--- a/ipband-DESTDIR.patch
+++ /dev/null
@@ -1,17 +0,0 @@
---- ipband-0.8/Makefile 2006-10-02 21:28:20.000000000 +0200
-+++ ipband-0.8.new/Makefile 2006-10-03 10:25:53.778650000 +0200
-@@ -58,10 +58,10 @@
- mkdir -p $(DESTDIR)$(BINDIR) $(DESTDIR)$(MAN1DIR)
- mkdir -p $(DESTDIR)$(SYSCONFDIR)
- mkdir -p $(DESTDIR)$(RCDIR)
-- install -D ipband $(DESTDIR)$(BINDIR)/ipband
-- install -D ipband.1 $(DESTDIR)$(MAN1DIR)/ipband.1
-- install -D ipband.sample.conf $(DESTDIR)$(SYSCONFDIR)/ipband.sample.conf
-- install -D ipband.rc $(DESTDIR)$(RCDIR)/ipband
-+ install -D ipband $(DESTDIR)/usr/bin/ipband
-+ install -D ipband.1 $(DESTDIR)/usr/share/man/man1/ipband.1
-+ install -D ipband.sample.conf $(DESTDIR)/etc/ipband/ipband.conf
-+ install -D ipband.rc $(DESTDIR)/etc/rc.d/init.d/ipband
-
-
- clean:
diff --git a/ipband-PLD_rc.patch b/ipband-PLD_rc.patch
index 6b06152..cb20a10 100644
--- a/ipband-PLD_rc.patch
+++ b/ipband-PLD_rc.patch
@@ -56,7 +56,7 @@ diff -urN ipband-0.7/ipband.rc ipband-0.7.dzikus/ipband.rc
- start
+ if [ ! -f /var/lock/subsys/ipband ]; then
+ msg_starting ipband
-+ daemon /usr/bin/ipband -c /etc/ipband/ipband.conf -F
++ daemon /usr/sbin/ipband -c /etc/ipband/ipband.conf -F
+ RETVAL=$?
+ [ $RETVAL -eq 0 ] && touch /var/lock/subsys/ipband
+ else
diff --git a/ipband-paths.patch b/ipband-paths.patch
index 53dfd68..ce0db0d 100644
--- a/ipband-paths.patch
+++ b/ipband-paths.patch
@@ -1,19 +1,18 @@
-diff -ur ipband-0.8/ipband.h ipband-0.8.new/ipband.h
---- ipband-0.8/ipband.h 2006-10-02 21:28:20.000000000 +0200
-+++ ipband-0.8.new/ipband.h 2006-10-03 10:21:10.498650000 +0200
-@@ -61,9 +61,9 @@
+--- ipband-0.8.1/ipband.h.orig 2008-06-17 19:23:19.000000000 +0200
++++ ipband-0.8.1/ipband.h 2025-06-28 19:43:16.112722990 +0200
+@@ -61,9 +61,9 @@ Defines
#undef DUMP
/* Defaults */
-#define CONFIG_DEF "/etc/ipband.conf"
-+#define CONFIG_DEF "/etc/ipband/ipband.conf"
- #define MTASTR_DEF "/usr/sbin/sendmail -t -ba"
+-#define MTASTR_DEF "/usr/sbin/sendmail -t -oi"
-#define REPFILE_DEF "ipband.txt"
++#define CONFIG_DEF "/etc/ipband/ipband.conf"
++#define MTASTR_DEF "/usr/lib/sendmail -t -oi"
+#define REPFILE_DEF "/var/log/ipband.log"
#define HTMLFILE_DEF "ipband.html"
#define HTMLTITLE_DEF "My bandwidth"
-diff -ur ipband-0.8/ipband.sample.conf ipband-0.8.new/ipband.sample.conf
--- ipband-0.8/ipband.sample.conf 2006-10-02 21:28:20.000000000 +0200
+++ ipband-0.8.new/ipband.sample.conf 2006-10-03 10:21:51.568650000 +0200
@@ -22,7 +22,7 @@
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/ipband.git/commitdiff/d1457fae141107300ec4ef122c6815146e5024fc
More information about the pld-cvs-commit
mailing list