4 Summary: NiceShaper - bandwidth limiting
5 Summary(pl.UTF-8): NiceShaper - dynamiczny podział łącza
10 Group: Networking/Admin
11 Source0: http://niceshaper.jedwabny.net/files/%{name}%{version}%{_rc}.tar.bz2
12 # Source0-md5: 32aab12fe08aa77c4244c9c3db1c082b
13 Source1: %{name}.users
14 Source2: %{name}.config
15 Source3: %{name}.about
17 Patch0: %{name}-includes.patch
18 Patch1: %{name}-iptables-deprecated.patch
19 URL: http://niceshaper.jedwabny.net/
20 BuildRequires: libstdc++-devel
21 BuildRequires: rpmbuild(macros) >= 1.268
22 Requires(post,preun): /sbin/chkconfig
23 Requires: firewall-userspace-tool
25 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28 This program limits bandwidth on the ethernet/ppp interface and
29 divides it between the hosts in the local network.
31 %description -l pl.UTF-8
32 Program opierając się na HTB/IMQ dzieli dostępne pasmo na komputery w
33 sieci, dynamicznie dostosowując się do generowanego przez każdego z
34 użytkowników obciążenia.
44 CPP="%{__cxx} %{rpmcxxflags}"
46 install %{SOURCE1} ./users
47 install %{SOURCE2} ./config
48 install %{SOURCE3} ./about
52 rm -rf $RPM_BUILD_ROOT
54 install -d $RPM_BUILD_ROOT{%{_bindir},%{_sysconfdir}/niceshaper0.6,/etc/rc.d/init.d}
56 install niceshaper $RPM_BUILD_ROOT%{_bindir}
57 install etc/niceshaper0.6/* $RPM_BUILD_ROOT%{_sysconfdir}/niceshaper0.6
58 install niceshaper.init $RPM_BUILD_ROOT/etc/rc.d/init.d/niceshaper
61 rm -rf $RPM_BUILD_ROOT
64 /sbin/chkconfig --add niceshaper
65 %service niceshaper restart "niceshaper daemon"
68 if [ "$1" = "0" ]; then
69 %service niceshaper stop
70 /sbin/chkconfig --del niceshaper
74 %defattr(644,root,root,755)
75 %doc users config about
76 %dir %{_sysconfdir}/%{name}0.6
77 %attr(640,root,root) %verify(not md5 mtime size) %config(noreplace) %{_sysconfdir}/%{name}0.6/*
78 %attr(755,root,root) %{_bindir}/*
79 %attr(754,root,root) /etc/rc.d/init.d/niceshaper