From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 9C8CA138334 for ; Thu, 23 May 2019 20:34:13 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A2B8CE0894; Thu, 23 May 2019 20:34:12 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 892B1E0894 for ; Thu, 23 May 2019 20:34:12 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 3D972344EEA for ; Thu, 23 May 2019 20:34:11 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id D5CE65F2 for ; Thu, 23 May 2019 20:34:08 +0000 (UTC) From: "Georgy Yakovlev" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Georgy Yakovlev" Message-ID: <1558643640.6a59ed6a7f00b0df0532a1cf69781a87ab44c67a.gyakovlev@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-power/intel-undervolt/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-power/intel-undervolt/intel-undervolt-9999.ebuild X-VCS-Directories: sys-power/intel-undervolt/ X-VCS-Committer: gyakovlev X-VCS-Committer-Name: Georgy Yakovlev X-VCS-Revision: 6a59ed6a7f00b0df0532a1cf69781a87ab44c67a X-VCS-Branch: master Date: Thu, 23 May 2019 20:34:08 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: acad9322-ebc0-4335-a3a7-a886fd9e1b15 X-Archives-Hash: 7bccfe7fe14a3b22b4316741cb0e6a7c commit: 6a59ed6a7f00b0df0532a1cf69781a87ab44c67a Author: Georgy Yakovlev gentoo org> AuthorDate: Thu May 23 20:34:00 2019 +0000 Commit: Georgy Yakovlev gentoo org> CommitDate: Thu May 23 20:34:00 2019 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6a59ed6a sys-power/intel-undervolt: add live ebuild Package-Manager: Portage-2.3.66, Repoman-2.3.12 Signed-off-by: Georgy Yakovlev gentoo.org> .../intel-undervolt/intel-undervolt-9999.ebuild | 62 ++++++++++++++++++++++ 1 file changed, 62 insertions(+) diff --git a/sys-power/intel-undervolt/intel-undervolt-9999.ebuild b/sys-power/intel-undervolt/intel-undervolt-9999.ebuild new file mode 100644 index 00000000000..74c44d3fe53 --- /dev/null +++ b/sys-power/intel-undervolt/intel-undervolt-9999.ebuild @@ -0,0 +1,62 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit linux-info systemd toolchain-funcs + +DESCRIPTION="Intel CPU undervolting and throttling configuration tool" +HOMEPAGE="https://github.com/kitsunyan/intel-undervolt" + +if [ ${PV} == "9999" ] ; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/kitsunyan/${PN}.git" +else + SRC_URI="https://github.com/kitsunyan/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="-* ~amd64" +fi + +LICENSE="GPL-3" +SLOT="0" +IUSE="" + +DEPEND="" +RDEPEND="" +BDEPEND="" + +CONFIG_CHECK="~INTEL_RAPL ~X86_MSR" + +src_prepare() { + # respect CC, CFLAGS and avoid calling pkg-config + sed -i \ + -e 's/^CC=/CC?=/' \ + -e 's/^CFLAGS=/CFLAGS?=/' \ + -e '/^UNITDIR=/d' \ + Makefile || die + + default +} + +src_compile() { + + tc-export CC + + myemakeargs=( + BINDIR="${EPREFIX}"/usr/bin + SYSCONFDIR="${EPREFIX}"/etc + UNITDIR="$(systemd_get_systemunitdir)" + ) + emake "${myemakeargs[@]}" +} + +src_install() { + myemakeargs+=( + DESTDIR="${D}" + ) + emake "${myemakeargs[@]}" install + + newinitd "${FILESDIR}"/initd "${PN}" + newconfd "${FILESDIR}"/confd "${PN}" + + einstalldocs +}