dnetstats-1.2.6-r3.ebuild 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. # Copyright 1999-2014 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. inherit eutils qt4-r2
  5. MY_PN="DNetStats"
  6. MY_P="${MY_PN}-v${PV}-release"
  7. DESCRIPTION="Qt4 network monitor utility"
  8. HOMEPAGE="http://qt-apps.org/content/show.php/DNetStats?content=107467"
  9. SRC_URI="http://qt-apps.org/CONTENT/content-files/107467-${MY_P}.tar.bz2"
  10. LICENSE="GPL-3"
  11. SLOT="0"
  12. KEYWORDS="amd64 x86"
  13. IUSE="policykit"
  14. DEPEND="
  15. dev-qt/qtcore:4
  16. dev-qt/qtgui:4
  17. "
  18. RDEPEND="${DEPEND}
  19. policykit? ( sys-auth/polkit )
  20. "
  21. S="${WORKDIR}/${MY_P}"
  22. src_prepare() {
  23. qt4-r2_src_prepare
  24. # clueless upstream ships generated files...
  25. rm -rf moc_* qrc_* || die
  26. }
  27. src_install() {
  28. newbin mythread ${PN}
  29. dodoc ReadMe
  30. newicon resource/energy.png ${PN}.png
  31. make_desktop_entry ${PN} DNetStats ${PN} 'Qt;Network;Dialup'
  32. if use policykit; then
  33. insinto /usr/share/polkit-1/actions
  34. doins "${FILESDIR}/org.gentoo.pkexec.${PN}.policy"
  35. sed -i -e 's/^Exec=/&pkexec /' \
  36. "${ED}"usr/share/applications/${PN}*.desktop \
  37. || die
  38. fi
  39. }