# edit these two (and Version and Release) in case of update %global commit 6e476abac7953fe9ed804511d6172ab894f24a11 %global commitdate 20180806 %global githubparent mkogan1 %global shortcommit %(c=%{commit}; echo ${c:0:7}) %global gitversion .%{commitdate}git%{shortcommit} Name: wondershaper Version: 1.4 Release: 0%{gitversion}%{?dist}.1sunshine Summary: Helper utility for limiting an adapter's bandwidth and shaping the traffic. Group: Applications/Utilities License: GPLv2 URL: https://github.com/%{githubparent}/%{name} Source0: https://github.com/%{githubparent}/%{name}/archive/%{commit}.tar.gz BuildArch: noarch # tc: %if 0%{?fedora} >= 25 Requires: iproute-tc %else Requires: iproute %endif # modprobe: %if 0%{?fedora} >= 17 Requires: kmod %else Requires: module-init-tools %endif %description Wonder Shaper is a script that allows the user to limit the bandwidth of one or more network adapters. It does so by using iproute's tc command, but greatly simplifies its operation. This version of Wonder Shaper is from mkogan1's guthub branch. %prep %setup -q -n %{name}-%{commit} %build # nothing to do %install install -d %{buildroot}%{_bindir} install -p -m755 %{name} %{buildroot}%{_bindir} # no systemd support for the time being %files %{!?_licensedir:%global license %%doc} %license COPYING %doc README.md README.old ChangeLog %{_bindir}/%{name} %changelog * Mon Nov 05 2018 Moritz Barsnick 1.4-0.20180806git6e476ab.1sunshine - update to latest git snapshot * Thu Jul 19 2018 Moritz Barsnick 1.4-0.20180712gitfb4ea8e.1sunshine - initial RPM