softflowd.spec 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. # Figure out release tag (e.g. rhel3, fc1) based on redhat-release file
  2. %global _RHTAG %(sed 's/(.*)//;s/ [A-Z]* //;s/[a-z ]*//g' /etc/redhat-release | tr '[:upper:]' '[:lower:]')
  3. Name: softflowd
  4. Summary: Network traffic analyser capable of Cisco NetFlow data export
  5. Version: 1.0.0
  6. Release: 1.%{_RHTAG}
  7. Source: softflowd-%{version}.tar.gz
  8. Group: System/Utilities
  9. License: BSD
  10. BuildRoot: %{_tmppath}/%{name}-root
  11. URL: http://www.mindrot.org/softflowd.html
  12. Vendor: mindrot.org
  13. %description
  14. softflowd is a software implementation of a flow-based network traffic
  15. monitor. softflowd reads network traffic and gathers information about
  16. active traffic flows. A "traffic flow" is communication between two IP
  17. addresses or (if the overlying protocol is TCP or UDP) address/port tuples.
  18. The intended use of softflowd is as a software implementation of Cisco’s
  19. NetFlow traffic account system. softflowd supports data export using
  20. versions 1, 5 or 9 of the NetFlow protocol.
  21. %prep
  22. %setup
  23. %build
  24. %configure
  25. make
  26. %install
  27. rm -rf $RPM_BUILD_ROOT
  28. make install DESTDIR=$RPM_BUILD_ROOT
  29. mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
  30. mkdir -p $RPM_BUILD_ROOT/etc/sysconfig
  31. cp %_sourcedir/softflowd.init $RPM_BUILD_ROOT/etc/rc.d/init.d/softflowd
  32. cp %_sourcedir/softflowd.sysconfig $RPM_BUILD_ROOT/etc/sysconfig/softflowd
  33. %files
  34. %defattr(-,root,root)
  35. /usr/sbin/*
  36. /usr/share/man/*
  37. %attr(0755,root,root) /etc/rc.d/init.d/softflowd
  38. %config(noreplace) %attr(0644,root,root) /etc/sysconfig/softflowd
  39. %doc ChangeLog README TODO
  40. %clean
  41. rm -rf $RPM_BUILD_ROOT