blob: 20f257daedbb6703eb75d04b14a27faf7f65b844 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-apps/microcode-ctl/microcode-ctl-1.26.ebuild,v 1.2 2014/11/02 09:49:37 swift Exp $
EAPI="5"
inherit linux-info toolchain-funcs
MY_P=${PN/-/_}-${PV}
DESCRIPTION="Intel processor microcode update utility"
HOMEPAGE="https://fedorahosted.org/microcode_ctl/"
SRC_URI="https://fedorahosted.org/released/${PN/-/_}/${MY_P}.tar.xz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="-* ~amd64 ~x86"
IUSE="selinux"
DEPEND=""
RDEPEND=">=sys-apps/microcode-data-20090330
selinux? ( sec-policy/selinux-cpucontrol )"
S=${WORKDIR}/${MY_P}
src_compile() {
emake \
CC="$(tc-getCC)" \
CFLAGS="${CFLAGS} ${CPPFLAGS} ${LDFLAGS}"
}
src_install() {
dosbin microcode_ctl
doman microcode_ctl.8
dodoc Changelog README
newinitd "${FILESDIR}"/microcode_ctl.rc-r1 microcode_ctl
newconfd "${FILESDIR}"/microcode_ctl.conf.d microcode_ctl
}
pkg_postinst() {
# Just a friendly warning
if ! linux_config_exists || ! linux_chkconfig_present MICROCODE; then
echo
ewarn "Your kernel must include microcode update support."
ewarn " Processor type and features --->"
ewarn " <*> /dev/cpu/microcode - microcode support"
echo
fi
elog "Microcode updates will be lost at every reboot."
elog "You can use the init.d script to update at boot time."
}
|