Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-kernel/gentoo-kernel/
Date: Thu, 20 Jan 2022 16:12:08
Message-Id: 1642695108.e0512ad89f6886041de0904c9fdd3b717a8892be.mgorny@gentoo
1 commit: e0512ad89f6886041de0904c9fdd3b717a8892be
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Thu Jan 20 13:44:11 2022 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Thu Jan 20 16:11:48 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e0512ad8
7
8 sys-kernel/gentoo-kernel: Bump to 5.10.93
9
10 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
11
12 sys-kernel/gentoo-kernel/Manifest | 2 +
13 .../gentoo-kernel/gentoo-kernel-5.10.93.ebuild | 127 +++++++++++++++++++++
14 2 files changed, 129 insertions(+)
15
16 diff --git a/sys-kernel/gentoo-kernel/Manifest b/sys-kernel/gentoo-kernel/Manifest
17 index 262caabfeb6d..d3808ee76f09 100644
18 --- a/sys-kernel/gentoo-kernel/Manifest
19 +++ b/sys-kernel/gentoo-kernel/Manifest
20 @@ -1,3 +1,5 @@
21 +DIST genpatches-5.10-100.base.tar.xz 2822696 BLAKE2B 8958af480d9babf927d8b1ac5ff0198549b6052b1c2b4cfad900c63e50b8ac7c396b3a8d3cec59406192f578eb871ba580b14398a5b6ad4ccb9d2f379d181b8a SHA512 27fed61b21ebf39e7c16d2d0a447160d0abf0ac50fbfcb924f1adb38a51d6683f70f911d3f8e62c084d2555ea14dedf8335f25ac9140066f88812c47d5f9b0ab
22 +DIST genpatches-5.10-100.extras.tar.xz 3852 BLAKE2B 7ac718b6080adb6a641ef7b976185b09ddf7f225fcaede25afbf6a15bf855eb6dbbe44416fcddf1ea466c36433e04736c68f032a1c79bde858434427c6658a1b SHA512 558c9fc3279d7fb507ac8251369966dd40282776890da045d96eab328fd7300a93dab12afbfabc3dd52f61d49c0020b87cd4087d4c8f840f3443ed8ffe89c81d
23 DIST genpatches-5.10-95.base.tar.xz 2769920 BLAKE2B 5de95da15985c9188801c6dfc413faa7fae2c534ccbc17ca3e8e3f70ff1422e00819b177cc4e1828eb6234ec110930af6e747089482e8efca010c1dd7fffa098 SHA512 4f6d6196406af59c3f9b7d9d069cf0d2186e45f10bccdaac0c1473520ed67606fd363d97b64eb53cb76c08c4d8e4198d67744af34a60e78419cc7c6ffe28a26f
24 DIST genpatches-5.10-95.extras.tar.xz 3852 BLAKE2B 1deb0958934dfe7b0092ffe9254269fc8ca900cb526f4805e38d7c69e8d4d587b50a169b1a54d32ed83fdf481626f853ae56e007a21554d82a7befc598d571b2 SHA512 f3c5ca1aaa1f7ba0743fe0d0f3046e411547c09d3590766b76778dbdbe1221ffd3542f3231e6ac6a77773caf3327d28aaa7bcb767cdf132a4fac7cf8afd3e86c
25 DIST genpatches-5.10-96.base.tar.xz 2787744 BLAKE2B 0d845fc9e5eb4cee41eb60756661d5220da31ea438a16a415431415a54503278b0fcd69cb8562e1c7c47ae794df4d0691a92ef034aa5650ece4b0ea29f56c73d SHA512 5424bb5c20f6b918abfa8b308ceae9dc321d1a8621e311ec1c492b9efd9bde41f695d12085b0c8eea16b8113832580b1ad831ff18a5354e5cac2e275d99bfdab
26
27 diff --git a/sys-kernel/gentoo-kernel/gentoo-kernel-5.10.93.ebuild b/sys-kernel/gentoo-kernel/gentoo-kernel-5.10.93.ebuild
28 new file mode 100644
29 index 000000000000..98f0c8eaf074
30 --- /dev/null
31 +++ b/sys-kernel/gentoo-kernel/gentoo-kernel-5.10.93.ebuild
32 @@ -0,0 +1,127 @@
33 +# Copyright 2020-2022 Gentoo Authors
34 +# Distributed under the terms of the GNU General Public License v2
35 +
36 +EAPI=7
37 +
38 +inherit kernel-build toolchain-funcs
39 +
40 +MY_P=linux-${PV%.*}
41 +GENPATCHES_P=genpatches-${PV%.*}-$(( ${PV##*.} + 7 ))
42 +# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
43 +CONFIG_VER=5.10.12
44 +CONFIG_HASH=836165dd2dff34e4f2c47ca8f9c803002c1e6530
45 +GENTOO_CONFIG_VER=5.15.5
46 +
47 +DESCRIPTION="Linux kernel built with Gentoo patches"
48 +HOMEPAGE="https://www.kernel.org/"
49 +SRC_URI+="
50 + https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${MY_P}.tar.xz
51 + https://dev.gentoo.org/~mpagano/dist/genpatches/${GENPATCHES_P}.base.tar.xz
52 + https://dev.gentoo.org/~mpagano/dist/genpatches/${GENPATCHES_P}.extras.tar.xz
53 + https://github.com/mgorny/gentoo-kernel-config/archive/v${GENTOO_CONFIG_VER}.tar.gz
54 + -> gentoo-kernel-config-${GENTOO_CONFIG_VER}.tar.gz
55 + amd64? (
56 + https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-x86_64-fedora.config
57 + -> kernel-x86_64-fedora.config.${CONFIG_VER}
58 + )
59 + arm64? (
60 + https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-aarch64-fedora.config
61 + -> kernel-aarch64-fedora.config.${CONFIG_VER}
62 + )
63 + ppc64? (
64 + https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-ppc64le-fedora.config
65 + -> kernel-ppc64le-fedora.config.${CONFIG_VER}
66 + )
67 + x86? (
68 + https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-i686-fedora.config
69 + -> kernel-i686-fedora.config.${CONFIG_VER}
70 + )"
71 +S=${WORKDIR}/${MY_P}
72 +
73 +LICENSE="GPL-2"
74 +KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
75 +IUSE="debug hardened"
76 +REQUIRED_USE="arm? ( savedconfig )"
77 +
78 +RDEPEND="
79 + !sys-kernel/gentoo-kernel-bin:${SLOT}"
80 +BDEPEND="
81 + debug? ( dev-util/pahole )"
82 +PDEPEND="
83 + >=virtual/dist-kernel-${PV}"
84 +
85 +QA_FLAGS_IGNORED="
86 + usr/src/linux-.*/scripts/gcc-plugins/.*.so
87 + usr/src/linux-.*/vmlinux
88 +"
89 +
90 +src_prepare() {
91 + local PATCHES=(
92 + # meh, genpatches have no directory
93 + "${WORKDIR}"/*.patch
94 + )
95 + default
96 +
97 + local biendian=false
98 +
99 + # prepare the default config
100 + case ${ARCH} in
101 + amd64)
102 + cp "${DISTDIR}/kernel-x86_64-fedora.config.${CONFIG_VER}" .config || die
103 + ;;
104 + arm)
105 + return
106 + ;;
107 + arm64)
108 + cp "${DISTDIR}/kernel-aarch64-fedora.config.${CONFIG_VER}" .config || die
109 + biendian=true
110 + ;;
111 + hppa)
112 + return
113 + ;;
114 + ppc)
115 + # assume powermac/powerbook defconfig
116 + # we still package.use.force savedconfig
117 + cp "${WORKDIR}/${MY_P}/arch/powerpc/configs/pmac32_defconfig" .config || die
118 + ;;
119 + ppc64)
120 + cp "${DISTDIR}/kernel-ppc64le-fedora.config.${CONFIG_VER}" .config || die
121 + biendian=true
122 + ;;
123 + x86)
124 + cp "${DISTDIR}/kernel-i686-fedora.config.${CONFIG_VER}" .config || die
125 + ;;
126 + *)
127 + die "Unsupported arch ${ARCH}"
128 + ;;
129 + esac
130 +
131 + local myversion="-gentoo-dist"
132 + use hardened && myversion+="-hardened"
133 + echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die
134 + local dist_conf_path="${WORKDIR}/gentoo-kernel-config-${GENTOO_CONFIG_VER}"
135 +
136 + local merge_configs=(
137 + "${T}"/version.config
138 + "${dist_conf_path}"/base.config
139 + )
140 + use debug || merge_configs+=(
141 + "${dist_conf_path}"/no-debug.config
142 + )
143 + if use hardened; then
144 + merge_configs+=( "${dist_conf_path}"/hardened-base.config )
145 +
146 + tc-is-gcc && merge_configs+=( "${dist_conf_path}"/hardened-gcc-plugins.config )
147 +
148 + if [[ -f "${dist_conf_path}/hardened-${ARCH}.config" ]]; then
149 + merge_configs+=( "${dist_conf_path}/hardened-${ARCH}.config" )
150 + fi
151 + fi
152 +
153 + # this covers ppc64 and aarch64_be only for now
154 + if [[ ${biendian} == true && $(tc-endian) == big ]]; then
155 + merge_configs+=( "${dist_conf_path}/big-endian.config" )
156 + fi
157 +
158 + kernel-build_merge_configs "${merge_configs[@]}"
159 +}