tuned-2.7.0.ebuild 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. # Copyright 1999-2016 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. PYTHON_COMPAT=( python2_7 )
  5. inherit python-single-r1 systemd
  6. DESCRIPTION="Daemon for monitoring and adaptive tuning of system devices"
  7. HOMEPAGE="https://fedorahosted.org/tuned/"
  8. SRC_URI="https://fedorahosted.org/releases/t/u/tuned/${P}.tar.bz2"
  9. LICENSE="GPL-2"
  10. SLOT="0"
  11. KEYWORDS="~amd64 ~x86"
  12. IUSE=""
  13. COMMON_DEPEND="${PYTHON_DEPS}
  14. dev-python/configobj[${PYTHON_USEDEP}]
  15. dev-python/decorator[${PYTHON_USEDEP}]
  16. dev-python/pyudev[${PYTHON_USEDEP}]
  17. dev-python/dbus-python[${PYTHON_USEDEP}]
  18. dev-python/pygobject:3[${PYTHON_USEDEP}]
  19. "
  20. DEPEND="${COMMON_DEPEND}"
  21. RDEPEND="${COMMON_DEPEND}
  22. sys-apps/dbus
  23. sys-power/powertop
  24. dev-util/systemtap
  25. "
  26. REQUIRED_USE="${PYTHON_REQUIRED_USE}"
  27. src_prepare() {
  28. epatch "${FILESDIR}"/${P}-upstream.patch
  29. sed -i \
  30. -e "/^UNITDIR = /s:\$(shell rpm --eval '%{_unitdir}'):$(systemd_get_unitdir):" \
  31. -e "/\$(DESTDIR)\/run\/tuned/d" \
  32. Makefile ||die
  33. }
  34. src_install() {
  35. default
  36. newinitd "${FILESDIR}"/tuned.initd tuned
  37. python_fix_shebang "${ED}"
  38. }