python-ethtool-vl.spec 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
  2. %{!?python_ver: %define python_ver %(%{__python} -c "import sys ; print sys.version[:3]")}
  3. Summary: Ethernet settings python bindings
  4. Summary(ja): ethtool の python バインディング
  5. Name: python-ethtool
  6. Version: 0.3
  7. Release: 2%{?_dist_release}
  8. URL: http://git.kernel.org/?p=linux/kernel/git/acme/python-ethtool.git
  9. Source: http://userweb.kernel.org/~acme/python-ethtool/%{name}-%{version}.tar.bz2
  10. License: GPLv2
  11. Group: System Environment/Libraries
  12. BuildRequires: python-devel
  13. BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
  14. %description
  15. Python bindings for the ethtool kernel interface, that allows querying and
  16. changing of ethernet card settings, such as speed, port, autonegotiation, and
  17. PCI locations.
  18. %prep
  19. %setup -q
  20. %build
  21. %{__python} setup.py build
  22. %install
  23. rm -rf %{buildroot}
  24. %{__python} setup.py install --skip-build --root %{buildroot}
  25. mkdir -p %{buildroot}%{_sbindir}
  26. cp -p pethtool.py %{buildroot}%{_sbindir}/pethtool
  27. cp -p pifconfig.py %{buildroot}%{_sbindir}/pifconfig
  28. %clean
  29. rm -rf %{buildroot}
  30. %files
  31. %defattr(-,root,root)
  32. %doc COPYING
  33. %{_sbindir}/pethtool
  34. %{_sbindir}/pifconfig
  35. %{python_sitearch}/ethtool.so
  36. %if "%{python_ver}" >= "2.5"
  37. %{python_sitearch}/*.egg-info
  38. %endif
  39. %changelog
  40. * Tue Feb 02 2010 Shu KONNO <owa@bg.wakwak.com> 0.3-2
  41. - rebuild with python-2.6
  42. * Wed Sep 23 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 0.3-1
  43. - initial build for Vine Linux
  44. * Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3-5
  45. - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
  46. * Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3-4
  47. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  48. * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.3-3
  49. - Rebuild for Python 2.6
  50. * Fri Sep 5 2008 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.3-2
  51. - Rewrote build and install sections as part of the fedora review process
  52. BZ #459549
  53. * Tue Aug 26 2008 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.3-1
  54. - Add get_flags method from the first python-ethtool contributor, yay
  55. - Add pifconfig command, that mimics the ifconfig tool using the
  56. bindings available
  57. * Wed Aug 20 2008 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.2-1
  58. - Expand description and summary fields, as part of the fedora
  59. review process.
  60. * Tue Jun 10 2008 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.1-3
  61. - add dist to the release tag
  62. * Tue Dec 18 2007 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.1-2
  63. - First build into MRG repo
  64. * Tue Dec 18 2007 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.1-1
  65. - Get ethtool code from rhpl 0.212