spectools-2011.08.1-r2.ebuild 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. # Copyright 1999-2012 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=4
  4. inherit udev toolchain-funcs
  5. MY_PN=${PN}
  6. MY_PV=${PV/\./-}
  7. MY_PV=${MY_PV/./-R}
  8. MY_P="${MY_PN}-${MY_PV}"
  9. S=${WORKDIR}/${MY_P}
  10. if [[ ${PV} == "9999" ]] ; then
  11. ESVN_REPO_URI="https://www.kismetwireless.net/code/svn/tools/${PN}"
  12. inherit subversion
  13. KEYWORDS=""
  14. else
  15. SRC_URI="http://www.kismetwireless.net/code/${MY_P}.tar.gz"
  16. KEYWORDS="amd64 arm ~ppc x86"
  17. fi
  18. DESCRIPTION="Spectrum Analyzer for Meta-Geek Wi-Spy and GSG Ubertooth hardware"
  19. HOMEPAGE="http://www.kismetwireless.net/spectools/"
  20. LICENSE="GPL-2"
  21. SLOT="0"
  22. IUSE="ncurses gtk"
  23. RDEPEND="virtual/libusb:0
  24. ncurses? ( sys-libs/ncurses )
  25. gtk? ( x11-libs/gtk+:2 )"
  26. DEPEND="${RDEPEND}
  27. virtual/pkgconfig"
  28. # Upstream has still not migrated to the libusb-1 line.
  29. # Maemo: Add hildon and bbus
  30. # Please note that upstream removed the --with-gtk-version option
  31. # and GTK is now automagical. GTK1 support was also removed.
  32. src_compile() {
  33. emake depend
  34. emake spectool_net spectool_raw
  35. if use ncurses; then
  36. emake spectool_curses
  37. fi
  38. if use gtk; then
  39. emake spectool_gtk
  40. fi
  41. #if use maemo; then
  42. # emake spectool_hildon usbcontrol \
  43. # || die "emake spectool_hildon usbcontrol failed"
  44. #fi
  45. }
  46. src_install() {
  47. dobin spectool_net spectool_raw
  48. use ncurses && dobin spectool_curses
  49. use gtk && dobin spectool_gtk
  50. udev_dorules 99-wispy.rules
  51. dodoc README
  52. #if use maemo; then
  53. # dobin spectool_hildon
  54. # dosbin usbcontrol
  55. #fi
  56. }