3 |
3 |
|
4 |
4 |
EAPI=8
|
5 |
5 |
|
6 |
|
inherit kernel-build toolchain-funcs verify-sig
|
|
6 |
KERNEL_IUSE_MODULES_SIGN=1
|
|
7 |
|
|
8 |
inherit git-r3 kernel-build toolchain-funcs
|
7 |
9 |
|
8 |
|
MY_P=linux-${PV%.*}
|
9 |
10 |
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
|
10 |
11 |
CONFIG_VER=5.10.12
|
11 |
12 |
CONFIG_HASH=836165dd2dff34e4f2c47ca8f9c803002c1e6530
|
12 |
13 |
GENTOO_CONFIG_VER=g16
|
13 |
|
SHA256SUM_DATE=20250701
|
14 |
14 |
|
15 |
15 |
DESCRIPTION="Linux kernel built from vanilla upstream sources"
|
16 |
16 |
HOMEPAGE="
|
... | ... | |
18 |
18 |
https://www.kernel.org/
|
19 |
19 |
"
|
20 |
20 |
SRC_URI+="
|
21 |
|
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${MY_P}.tar.xz
|
22 |
|
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/patch-${PV}.xz
|
23 |
21 |
https://github.com/projg2/gentoo-kernel-config/archive/${GENTOO_CONFIG_VER}.tar.gz
|
24 |
22 |
-> gentoo-kernel-config-${GENTOO_CONFIG_VER}.tar.gz
|
25 |
|
verify-sig? (
|
26 |
|
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/sha256sums.asc
|
27 |
|
-> linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc
|
28 |
|
)
|
29 |
23 |
amd64? (
|
30 |
24 |
https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-x86_64-fedora.config
|
31 |
25 |
-> kernel-x86_64-fedora.config.${CONFIG_VER}
|
... | ... | |
43 |
37 |
-> kernel-i686-fedora.config.${CONFIG_VER}
|
44 |
38 |
)
|
45 |
39 |
"
|
46 |
|
S=${WORKDIR}/${MY_P}
|
|
40 |
|
|
41 |
EGIT_REPO_URI=(
|
|
42 |
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
|
|
43 |
https://github.com/gregkh/linux/
|
|
44 |
)
|
|
45 |
EGIT_BRANCH="linux-${PV/.9999/.y}"
|
47 |
46 |
|
48 |
47 |
LICENSE="GPL-2"
|
49 |
|
KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~x86"
|
50 |
48 |
IUSE="debug hardened"
|
51 |
49 |
REQUIRED_USE="arm? ( savedconfig )"
|
52 |
50 |
|
53 |
51 |
BDEPEND="
|
54 |
52 |
debug? ( dev-util/pahole )
|
55 |
|
verify-sig? ( >=sec-keys/openpgp-keys-kernel-20250702 )
|
56 |
53 |
"
|
57 |
54 |
PDEPEND="
|
58 |
|
>=virtual/dist-kernel-${PV}
|
|
55 |
>=virtual/dist-kernel-$(ver_cut 1-2)
|
59 |
56 |
"
|
60 |
57 |
|
61 |
58 |
QA_FLAGS_IGNORED="
|
... | ... | |
63 |
60 |
usr/src/linux-.*/vmlinux
|
64 |
61 |
"
|
65 |
62 |
|
66 |
|
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kernel.org.asc
|
67 |
|
|
68 |
63 |
src_unpack() {
|
69 |
|
if use verify-sig; then
|
70 |
|
cd "${DISTDIR}" || die
|
71 |
|
verify-sig_verify_signed_checksums \
|
72 |
|
"linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc" \
|
73 |
|
sha256 "${MY_P}.tar.xz patch-${PV}.xz"
|
74 |
|
cd "${WORKDIR}" || die
|
75 |
|
fi
|
76 |
|
|
|
64 |
git-r3_src_unpack
|
77 |
65 |
default
|
78 |
66 |
}
|
79 |
67 |
|
80 |
68 |
src_prepare() {
|
81 |
|
eapply "${WORKDIR}/patch-${PV}"
|
82 |
69 |
default
|
83 |
70 |
|
84 |
71 |
local biendian=false
|
... | ... | |
139 |
126 |
merge_configs+=( "${dist_conf_path}/big-endian.config" )
|
140 |
127 |
fi
|
141 |
128 |
|
|
129 |
use secureboot && merge_configs+=( "${dist_conf_path}/secureboot.config" )
|
|
130 |
|
|
131 |
# 5.10 series: No ZBOOT, disable explicitly to not confuse the eclass
|
|
132 |
echo "# CONFIG_EFI_ZBOOT is not set" > "${dist_conf_path}/secureboot.config" || die
|
|
133 |
|
142 |
134 |
kernel-build_merge_configs "${merge_configs[@]}"
|
143 |
135 |
}
|