sys-kernel/gentoo-kernel: Remove old

Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
Michał Górny
2026-05-19 08:02:16 +02:00
parent fd11e5677e
commit 5135586cf6
8 changed files with 0 additions and 1069 deletions
-13
View File
@@ -1,4 +1,3 @@
DIST gentoo-kernel-config-g17.tar.bz2 5551 BLAKE2B af2c06a14d214b8cd9d4dff6dcc4a3aed4e56dcd75e35238d42e06d3c05cb0d59859c5f70a423d78d91290c1479b8b1729ad3eea3f352d2cf85a0b023e2eb11d SHA512 78e56d699fe5b65bab144b7713f0a9785b6f00643eafd0171a2395f56e34d91a34fce8dd234427b8c18a7ae12bb52bb39e0f282c11de6451b2737fc61f183034
DIST gentoo-kernel-config-g18.tar.bz2 5604 BLAKE2B 172d733748afb252f6a01eee53258d48565a6961f96195c6731938897346c35ef88fb239b7eb50cae260f0251977c5c9499102d64ad63d7c81488968f3975927 SHA512 7384add589554097249bc1815a2353d45e17dbac15b1dadbcdc7c8ebbbaa4e13f05c69d91dfa56f7602692b3f400a01a689d7f0eb2de34b8a8cb261a5c1353b6
DIST kernel-5.10.12-gentoo.tar.bz2 756570 BLAKE2B 3448fac74ca3d3f373ab6b77a76ca9e44aed3a484a0e4c22761fcaa60e9097706fb8bed9b83b024218918528bac10253e824787b6737d6272da65a49250bca69 SHA512 0cddbcdc00e5d8f54276c0295106401d66983a72b5bca30b7a8bef8be6cd0448622c885d4ac6c75271809b45a1231dc5eed8e3102e5cfff7ea54829c5c5daa96
DIST kernel-6.1.102-gentoo.tar.bz2 599178 BLAKE2B 01763e0db371bca986de92e82e307c27c1fa48f1ea33c2d3c5db2a1d6138104b941e9d23c2ae0f8b7496c9519f3975517141a39ead99345e3a6f936c2e8d577d SHA512 15da1ce895048fcd2f7b9be0895ddfcce7f8140443762e45507e3b8edd1307a841b19f45b979125766d7bc397be735df9c93fc0483861f893dee6e548b132f87
@@ -16,30 +15,18 @@ DIST linux-6.6.tar.xz 140064536 BLAKE2B 5f02fd8696d42f7ec8c5fbadec8e7270bdcfcb1f
DIST linux-6.x-sha256sums-20260515.asc 224721 BLAKE2B 1c16fa8a2653fd7dcb462515d35f3a41305ade7085455ea3a375caf7154a4468c3d8b305a19c66d4f8ce0a43cb940a009cbdd8ea8517d95791da5845ae53ca1b SHA512 182cc5ded68b8c6cde842db5b5b4856dc2bd979c902a9aef228a11a22fb3251ad0b8b2074b486988630aee2c6eea1a14195f4517822779230aa6ef2a91178337
DIST linux-6.x-sha256sums-20260517.asc 225744 BLAKE2B 322cf510b2326393a3e2d4fdbf5178d0bc4a169a8a47d37acbdf6d1670800ce1fa2b3a7e39e0a4cb45d2e864b79f4f69706270a8bdf1b422ad4b947049952556 SHA512 9c2b2f1d7d3553ea815bfaff19005b2947fcbc3a71777544020370d3d56197b218d24e8daa3d1cdd1e90d90c412d7e92d0568c083848d0f209e7e04c7f5db7e2
DIST linux-7.0.tar.xz 157143652 BLAKE2B 3d9795083c8938f80f480de0d10bfd9c525640e59d5c7f22983de3f12ee42c84c31be902cafb05579ddb1c32bac5ed06b0d4953f9705450be185bd2d9ab08f89 SHA512 8c85b708342f8f09ca25b2234b22e93b62b144a9ef919fbb21827f52fa47498e778c79db1559524dd7fb360f95b2ce174171443c1859656c281be41d2b6c5a0b
DIST linux-7.x-sha256sums-20260515.asc 3871 BLAKE2B f1ae72a144c142ad41c89896ec924ef7e86de8f6a1f1ba0a74846e0c05226876d76542e9cfcdbbd93634ccce4d157bdeb9bf489cfcf5806a14726a63a381f616 SHA512 524d06663da096101fcf614c354f504d5038230bd014539aa79915334f92f23cd10b09049808210bb4aba602239e30bb393a3c55d46d4e8b6a377c378bade4bb
DIST linux-7.x-sha256sums-20260517.asc 4204 BLAKE2B bb66ae5418c51971d59363eb7d13cf257a2663450fc9225d51ee3f21620eba8a883f202ee0fb492abb124f0cad5a3a96c0ced94f6f2c097d0296d6aa9a7df47d SHA512 88433e4e9ba10807f84effeba345f61269596bf06bb0e60eb38c27403104935bdea071db504970df16dc881103805eb792cb70457bfd264f4d7af2c26276b8af
DIST linux-gentoo-patches-5.10.256.tar.xz 15572 BLAKE2B 6ac97966446a3f7e6a7f30ef5aa528f721788e8e9d7f80308e367cd0e4a9804f68d96ee8650d1f5ae4cf75e5c0747682a1b410cd74950203ed5858eb41e586f6 SHA512 b9f51044752a1fdc8d148a9d7a83de557529df92f0765d818c44d087c5a9c21ec431f86c97231118bb4de2935479712d8fbd7b71a9c29816f9696f1330308ecc
DIST linux-gentoo-patches-5.10.256_p1.tar.xz 16244 BLAKE2B 5e5af3e6a86cb084d97ce64f0f1c6efac8cc4ae85fd5eadced1f55be8756652b66544973959fa88188fb4b00a98d2bd9991c0bb56dfe50ed3ada9ca072601439 SHA512 7efee811cb948d1e72ee1be09de05fc7b3e3e3d6a25676323465a7ee7ea30cbe52bb05bd9ee69fe6a435e3944f755e2ca5d7a1a613b02b653374c1348783dfea
DIST linux-gentoo-patches-5.15.207.tar.xz 12972 BLAKE2B 027a094ffdfd134747c00d54360a68c0c4d368dd3cce1fcb25d8261b86e3ee9440639a0fa5bcefa2f54b2948164a273c45849401a050092ebdea93dd8d79f000 SHA512 c3fd68eaa72c76c9e9586492008601c9e76870b4a1f2ed81a26e62aee5dce08478385c76e7bbcb27e508d449a91956cba5a48fe87ade8a08158ae5dfc8e0c59c
DIST linux-gentoo-patches-5.15.207_p1.tar.xz 13768 BLAKE2B c7dd9ae34e806706c0ff4f0f59be8cfefb9f60788321d7605f8629ce874caf7db09c079fe040ec3f1add99785655801cecb2bec36115578c90ca6586efc1190d SHA512 9c9f51ffbdf80e6cb0fd3bb543222124545310f932b5a059d02a52c3709ab80c3ebf115a36ddfeac6f17044183e11f921f4c7be08326c74f93d46dd337a2a09c
DIST linux-gentoo-patches-6.1.173.tar.xz 14900 BLAKE2B 4f2efa5bbcb162893dfac60eaccb1fa403377d92333877a049831a16f7daa1c23d7a1ac815d3a82299aa41cc097395fdf7f378e6bf31f73e3fb11169c7f02545 SHA512 5aae5d8ffff24e2c4f3138922285205453a0714c7aaa1d3729b2e3a8955f6ded8735fce6c38be74dfece21ed86267d1111c108bc156daa45fbb5f1e76d24b799
DIST linux-gentoo-patches-6.1.173_p1.tar.xz 15408 BLAKE2B 70968590dbbb208ddd5d8a1ac09bb1be030d065377b84a837d36e318a841572bce69e37ac896e4ab9771d424da5135d9eae49a725cc03948308b48fe70960225 SHA512 546fcf0a27b6eaaa780d0779d6322847febe3192a44dde770d8e4f931ec5bed97bf7412b84018fe63a55f37485e2122c6af09468a88df1b423687bdead900404
DIST linux-gentoo-patches-6.12.89.tar.xz 17588 BLAKE2B b9fe96404233e6d64efa6e6cf54c6990799f7cf70d10b2155c637bba014b14a911165972bcb36d3d9374c16480738009bca675126ccdc109208191c51ac34782 SHA512 bb07df033c2f71c5f196e7f3be3391c427e4abe8df44dc4269334d97c0f01ec3c76cc256acf725519ab3ba68fdc768207dd0f5a38119ab92df712cefdf7750c1
DIST linux-gentoo-patches-6.12.90.tar.xz 18204 BLAKE2B b91f9743c88e90e56d269ffcea0e0d53db8b3651f5e15b28b5974cd1a5f3eb98c0de9911c031b46dcd701fb5e31783515fb291301ec7562d5f5d983e69a99e89 SHA512 92c61c8ff31c92d226a52c2bdcf679c9051bafb7d81bd76439f019de5de67d0ce33d32967590db69f65f1af971371050742875d48cd287dbfe0ba905cef19849
DIST linux-gentoo-patches-6.18.31.tar.xz 13828 BLAKE2B ee99055c2e1f636963486c1bb44ac9a12cd1d9790504e975354afdcbde0616ab67921954362e035fb47b504421239be3cca3a92f854fa00a9d98f39e75fb8891 SHA512 7ae7c58dd69dcd1e0eb331c3f3ec3bc5d1e29d83dff691f89e47da9923f23146f5001bcc77a8c4a776d36c65f3426c2b80204ad6aa7e4e5cdc225107924ab89f
DIST linux-gentoo-patches-6.18.32.tar.xz 16576 BLAKE2B c94123ab9883ed793c2d45766739604a0d8b857731363d6dde516f07817d5fd583a4469e15049dea92693eae79bd81747bf4c3ceb106377773f13ef7759154c6 SHA512 b1001893b5b959d3d4f9309c952e7e1e33d8bb41be9c9947ce9beb75bb3bf70b1621e905d1feb1aafcab8bfe2da29cee194e82f600e0823768be9f475f4a1509
DIST linux-gentoo-patches-6.6.139.tar.xz 40300 BLAKE2B 0c972fa1e7baaa0c392740073caca26ad731fe8a5edd22938bc5b9f1fde9158d415998b82cdd882a2fa090ec3ad625c7a5962ca9bc060ecd5ae6e1cd1fd0acbe SHA512 7bdff4a752a4f424e19e03554f6f7ef1cc41d30f0b681f90a18dacc8c6700940306ae275068ebf7bd7e723969e38c24a60359c44622b076a2ebb3fb55a7765a9
DIST linux-gentoo-patches-6.6.140.tar.xz 44008 BLAKE2B 5c60bce4c98adf35ed00191507d2681dd3ef79607274ccdd7cc041cdef37f06e2797755438da1f44621defdf042c1a58d441f6d9c7a045c895478f5f732db040 SHA512 c7e9e8552010bd2b2bf4f69d7b64379c957d3cefe468a909718808f4817320e85fdb903cb9c95896ca80b6987d5b186ae0dd8a15a5405f6b3b16ef14035910c1
DIST linux-gentoo-patches-7.0.8.tar.xz 12576 BLAKE2B 0e920ef82a8ca28a604cb257f961a0f8598730bee0af3a516d57638a37f5c9a905ce2e86d8bb08986e100443cd5dddb06584f65d882c5f476c1faa76384c567c SHA512 f1ebdd8746e19de6d4c7adcacd83446619fa371f2e9573fe8c8c6ddd78fa36412b8860b0a32f01fc92e8f2be5938ce2c38d6d276ecc47b3ffd9d565cb5041344
DIST linux-gentoo-patches-7.0.9.tar.xz 13924 BLAKE2B 118596008363c6714c81c10f9c63f5645ac86e5d5fad17cf491b7fc2588037ad3c8f116eb771d145abe55391247f757b578901c552bdb695582f82879003ab41 SHA512 27a848006bef68533646e212493122b4f79633b184683c7ba86b98f996a13b2f06af516f520c1e9a9b9382ccbf3eead6fd7a4e1562289f08a6e04d3d85f1cbe6
DIST patch-5.10.256.xz 7255852 BLAKE2B eb5cf0d144968e873ba968a1d4a51590953dd6c7665b5d7ea3794ebd97278946a73973fbb57227642c347a1afa8ac46cfc9a30796bc5af1c22aad71b3a5b3f7a SHA512 1b722f5fa41ce53c36a9d75097b56131374958ede1643b06a9f73df05de40367c09bba766e72e25a1d416e335c14f97b467f9f9235ea29ce460c7ea26aa2296e
DIST patch-5.15.207.xz 7682032 BLAKE2B fbb16a8f064c1d05394904805d77cca1a408f7219fc8add42c3a21ca43c3eab051be03724113cef46093c52a7cc153d1349e292c5044a82219e418e4d56a10bb SHA512 6a85e5ab1e45819bfbd079b6291d49009c96a496337a1b8727fa3e5ed9447dfed01bdc2fc1cc94cf6d4ebddea26f9d9d6fd6f853daab14bf357b2bbb2aa23eab
DIST patch-6.1.173.xz 7324404 BLAKE2B fd1fe5d5bfb3933d31ec27b63785710418cfa4c1fa0b933937582514d8a1e6568c5d03f9cb4e9bb780cb788ef293892946470d9b943eb49f6e235e44f47b0f24 SHA512 310c6c1f224d6fb7739a6a77b8cef008d0a9d618efb76c92627f9ee765aa27546dffeeb0ef2772c2a63822e5e0bff6cee36125d95ddeee81f44c09a655ef5e59
DIST patch-6.12.89.xz 4465556 BLAKE2B 0c2be8f36d6c51b87d76241dc9fa48a24374e07ba8776aa3990225fbf221eb176b2174d76676225903ff86e99171675952b35069fc62ceddedca0c03cf94243d SHA512 dd2dc66b9afd789bf55eaf4f64176f83f21346e587af84aaa7ad27689c29d6d195317d7ab91a8a7da6112e2b63886f3030cfb6738e7c5e56773b2843f31f09ca
DIST patch-6.12.90.xz 4487592 BLAKE2B 56cac27027faff3fdf6235c416b90435d68f4cda1fa5b130688718c470d3bac305089ef051d62fc05d43ff0eeb02da6074e6fd02ac8ab3113e793e4cd9dc400a SHA512 26c834fe8391ff24503b908c5faf7785bf04c7c02f82e2b7b1e17b74731e3ebdb93bce02c77ea3cbdd6a21974e2d72a69fdbd62f60b4f8d09c6cf0c6e3956230
DIST patch-6.18.31.xz 1667280 BLAKE2B e42423e54915e941ee93da3df57e076df4c27c981a8b5163f9170a25e7fbab99ad956090908b73859f6418ccc4d5e648e90f2d811b955ab19bcb3628af11a9ff SHA512 8b21d3cfb5371e359919bf37b21a41a2566da3ac7fc0e5ac3ce8156119c4b4dd1c5902b12480ab8f99eee18e947ca3862d2ebc93e1bf03ae061928c0305d5131
DIST patch-6.18.32.xz 1721736 BLAKE2B 0cc3b3d819872744278073790a2a1d5dcb0eb75ceeafa10b30b5c0f45144f7447bf1baf9f88f1291a934fb41f30bbf1a7463e7ed1a3c64174b6c86f478b2ba5b SHA512 1eb31359d8c6778f8386f02a6bc76a77efd9bfd6f60057d9c41100e722ebfb5c06742682a7dd2ca04dfdbb3cb40f27b1053652647fca2441dbede4741e8b2f92
DIST patch-6.6.139.xz 5911480 BLAKE2B cf5caf631591c6c4d2f3df4eedf729a1b12401b462889a63acba77a083a70097a3b26ea58e2b3ca05a331a5de334d877ffae0124b24c9788bc1a7c47657a3caa SHA512 be5430f02d536db2d02eaaf90bc4a0b102e89fcac40b40a41124ef9311f94347a1cecab8b8cba9ee533f7b61663a5ec4fdcfc317e648a35cb7aebf98b0deb34f
DIST patch-6.6.140.xz 6006828 BLAKE2B 5f80ef79b458d94f43cdede32691d96f55f452762d9ff98ca7a62ff6606b26468312b3a46df48b021374de78b8cb4aa75fa9d0e725818848c7bd89acd094cda0 SHA512 d21f4d1f2a83040f4de8094d2266e2e2ddc694ffaa13b81d7b0860f263858c1f6a06471cd6070badda317c61b1fbe94f64ca181e183ac52422c3757b0764c946
DIST patch-7.0.8.xz 237664 BLAKE2B 2319ac8124eadae186895fbe54612a5ed8642e63fe5e59c9d957241e08350f0283d78990c03af3b16b198d21ace6dca02cac271068e9e5f87cfbae62ca489c1b SHA512 cd7fbd0834ae8558fc0e9ff75591cb60cb4e1aa6beb65976ea515be1c002d9158c134a4f5b7cff56ee53639a3d20d390b2accc44a4b229e8a3a913b8c556fb15
DIST patch-7.0.9.xz 282588 BLAKE2B 1b77a6a14a02e5b7167f042ee13123027ddfe425966a775c2d81f0fc16e77b9db72ff6f8765a606ea685a3b35ead0f193c7df1e749c04a1ee3e3b3e5a0cc0ea9 SHA512 1a161507d59c389e945dbb7cfb1456df2edf14c8376290584a905e0b602ed79e717f8fe154402f56a8d64a20243772129976884effa140fb25151856a7e3630f
@@ -1,146 +0,0 @@
# Copyright 2020-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit kernel-build toolchain-funcs verify-sig
BASE_P=linux-${PV%.*}
PATCH_PV=${PV%_p*}
PATCHSET=linux-gentoo-patches-${PV}
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
# forked to git.gentoo.org:fork/fedora/kernel
CONFIG_VER=5.10.12-gentoo
GENTOO_CONFIG_P=gentoo-kernel-config-g17
SHA256SUM_DATE=20260515
DESCRIPTION="Linux kernel built with Gentoo patches"
HOMEPAGE="
https://wiki.gentoo.org/wiki/Project:Distribution_Kernel
https://www.kernel.org/
"
SRC_URI+="
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${BASE_P}.tar.xz
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/patch-${PATCH_PV}.xz
https://distfiles.gentoo.org/pub/proj/dist-kernel/patchsets/$(ver_cut 1-2)/${PATCHSET}.tar.xz
https://gitweb.gentoo.org/proj/dist-kernel/gentoo-kernel-config.git/snapshot/${GENTOO_CONFIG_P}.tar.bz2
https://gitweb.gentoo.org/fork/fedora/kernel.git/snapshot/kernel-${CONFIG_VER}.tar.bz2
verify-sig? (
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/sha256sums.asc
-> linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc
)
"
S=${WORKDIR}/${BASE_P}
KEYWORDS="amd64 ~arm arm64 ~hppa ppc ppc64 ~sparc x86"
IUSE="debug hardened"
REQUIRED_USE="
arm? ( savedconfig )
hppa? ( savedconfig )
sparc? ( savedconfig )
"
RDEPEND="
!sys-kernel/gentoo-kernel-bin:${SLOT}
"
BDEPEND="
debug? ( dev-util/pahole )
verify-sig? ( >=sec-keys/openpgp-keys-kernel-20250702 )
"
PDEPEND="
>=virtual/dist-kernel-${PV}
"
QA_FLAGS_IGNORED="
usr/src/linux-.*/scripts/gcc-plugins/.*.so
usr/src/linux-.*/vmlinux
usr/src/linux-.*/arch/powerpc/kernel/vdso.*/vdso.*.so.dbg
"
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kernel.org.asc
src_unpack() {
if use verify-sig; then
cd "${DISTDIR}" || die
verify-sig_verify_signed_checksums \
"linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc" \
sha256 "${BASE_P}.tar.xz patch-${PATCH_PV}.xz"
cd "${WORKDIR}" || die
fi
default
}
src_prepare() {
local patch
eapply "${WORKDIR}/patch-${PATCH_PV}"
eapply "${WORKDIR}/${PATCHSET}"
default
# add Gentoo patchset version
local extraversion=${PV#${PATCH_PV}}
sed -i -e "s:^\(EXTRAVERSION =\).*:\1 ${extraversion/_/-}:" Makefile || die
local biendian=false
# prepare the default config
case ${ARCH} in
arm | hppa | sparc)
> .config || die
;;
amd64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-x86_64-fedora.config" .config || die
;;
arm64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-aarch64-fedora.config" .config || die
biendian=true
;;
ppc)
# assume powermac/powerbook defconfig
# we still package.use.force savedconfig
cp "arch/powerpc/configs/pmac32_defconfig" .config || die
;;
ppc64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-ppc64le-fedora.config" .config || die
biendian=true
;;
x86)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-i686-fedora.config" .config || die
;;
*)
die "Unsupported arch ${ARCH}"
;;
esac
local myversion="-gentoo-dist"
use hardened && myversion+="-hardened"
echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die
local dist_conf_path="${WORKDIR}/${GENTOO_CONFIG_P}"
local merge_configs=(
"${T}"/version.config
"${dist_conf_path}"/base.config
)
use debug || merge_configs+=(
"${dist_conf_path}"/no-debug.config
)
if use hardened; then
merge_configs+=( "${dist_conf_path}"/hardened-base.config )
tc-is-gcc && merge_configs+=( "${dist_conf_path}"/hardened-gcc-plugins.config )
if [[ -f "${dist_conf_path}/hardened-${ARCH}.config" ]]; then
merge_configs+=( "${dist_conf_path}/hardened-${ARCH}.config" )
fi
fi
# this covers ppc64 and aarch64_be only for now
if [[ ${biendian} == true && $(tc-endian) == big ]]; then
merge_configs+=( "${dist_conf_path}/big-endian.config" )
fi
use secureboot && merge_configs+=( "${dist_conf_path}/secureboot.config" )
kernel-build_merge_configs "${merge_configs[@]}"
}
@@ -1,146 +0,0 @@
# Copyright 2020-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit kernel-build toolchain-funcs verify-sig
BASE_P=linux-${PV%.*}
PATCH_PV=${PV%_p*}
PATCHSET=linux-gentoo-patches-${PV}
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
# forked to git.gentoo.org:fork/fedora/kernel
CONFIG_VER=6.1.102-gentoo
GENTOO_CONFIG_P=gentoo-kernel-config-g17
SHA256SUM_DATE=20260515
DESCRIPTION="Linux kernel built with Gentoo patches"
HOMEPAGE="
https://wiki.gentoo.org/wiki/Project:Distribution_Kernel
https://www.kernel.org/
"
SRC_URI+="
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${BASE_P}.tar.xz
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/patch-${PATCH_PV}.xz
https://distfiles.gentoo.org/pub/proj/dist-kernel/patchsets/$(ver_cut 1-2)/${PATCHSET}.tar.xz
https://gitweb.gentoo.org/proj/dist-kernel/gentoo-kernel-config.git/snapshot/${GENTOO_CONFIG_P}.tar.bz2
https://gitweb.gentoo.org/fork/fedora/kernel.git/snapshot/kernel-${CONFIG_VER}.tar.bz2
verify-sig? (
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/sha256sums.asc
-> linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc
)
"
S=${WORKDIR}/${BASE_P}
KEYWORDS="amd64 ~arm arm64 ~hppa ppc ppc64 ~sparc x86"
IUSE="debug hardened"
REQUIRED_USE="
arm? ( savedconfig )
hppa? ( savedconfig )
sparc? ( savedconfig )
"
RDEPEND="
!sys-kernel/gentoo-kernel-bin:${SLOT}
"
BDEPEND="
debug? ( dev-util/pahole )
verify-sig? ( >=sec-keys/openpgp-keys-kernel-20250702 )
"
PDEPEND="
>=virtual/dist-kernel-${PV}
"
QA_FLAGS_IGNORED="
usr/src/linux-.*/scripts/gcc-plugins/.*.so
usr/src/linux-.*/vmlinux
usr/src/linux-.*/arch/powerpc/kernel/vdso.*/vdso.*.so.dbg
"
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kernel.org.asc
src_unpack() {
if use verify-sig; then
cd "${DISTDIR}" || die
verify-sig_verify_signed_checksums \
"linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc" \
sha256 "${BASE_P}.tar.xz patch-${PATCH_PV}.xz"
cd "${WORKDIR}" || die
fi
default
}
src_prepare() {
local patch
eapply "${WORKDIR}/patch-${PATCH_PV}"
eapply "${WORKDIR}/${PATCHSET}"
default
# add Gentoo patchset version
local extraversion=${PV#${PATCH_PV}}
sed -i -e "s:^\(EXTRAVERSION =\).*:\1 ${extraversion/_/-}:" Makefile || die
local biendian=false
# prepare the default config
case ${ARCH} in
arm | hppa | sparc)
> .config || die
;;
amd64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-x86_64-fedora.config" .config || die
;;
arm64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-aarch64-fedora.config" .config || die
biendian=true
;;
ppc)
# assume powermac/powerbook defconfig
# we still package.use.force savedconfig
cp "arch/powerpc/configs/pmac32_defconfig" .config || die
;;
ppc64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-ppc64le-fedora.config" .config || die
biendian=true
;;
x86)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-i686-fedora.config" .config || die
;;
*)
die "Unsupported arch ${ARCH}"
;;
esac
local myversion="-gentoo-dist"
use hardened && myversion+="-hardened"
echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die
local dist_conf_path="${WORKDIR}/${GENTOO_CONFIG_P}"
local merge_configs=(
"${T}"/version.config
"${dist_conf_path}"/base.config
)
use debug || merge_configs+=(
"${dist_conf_path}"/no-debug.config
)
if use hardened; then
merge_configs+=( "${dist_conf_path}"/hardened-base.config )
tc-is-gcc && merge_configs+=( "${dist_conf_path}"/hardened-gcc-plugins.config )
if [[ -f "${dist_conf_path}/hardened-${ARCH}.config" ]]; then
merge_configs+=( "${dist_conf_path}/hardened-${ARCH}.config" )
fi
fi
# this covers ppc64 and aarch64_be only for now
if [[ ${biendian} == true && $(tc-endian) == big ]]; then
merge_configs+=( "${dist_conf_path}/big-endian.config" )
fi
use secureboot && merge_configs+=( "${dist_conf_path}/secureboot.config" )
kernel-build_merge_configs "${merge_configs[@]}"
}
@@ -1,147 +0,0 @@
# Copyright 2020-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit kernel-build toolchain-funcs verify-sig
BASE_P=linux-${PV%.*}
PATCH_PV=${PV%_p*}
PATCHSET=linux-gentoo-patches-${PV}
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
# forked to git.gentoo.org:fork/fedora/kernel
CONFIG_VER=6.1.102-gentoo
GENTOO_CONFIG_P=gentoo-kernel-config-g17
SHA256SUM_DATE=20260515
DESCRIPTION="Linux kernel built with Gentoo patches"
HOMEPAGE="
https://wiki.gentoo.org/wiki/Project:Distribution_Kernel
https://www.kernel.org/
"
SRC_URI+="
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${BASE_P}.tar.xz
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/patch-${PATCH_PV}.xz
https://distfiles.gentoo.org/pub/proj/dist-kernel/patchsets/$(ver_cut 1-2)/${PATCHSET}.tar.xz
https://gitweb.gentoo.org/proj/dist-kernel/gentoo-kernel-config.git/snapshot/${GENTOO_CONFIG_P}.tar.bz2
https://gitweb.gentoo.org/fork/fedora/kernel.git/snapshot/kernel-${CONFIG_VER}.tar.bz2
verify-sig? (
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/sha256sums.asc
-> linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc
)
"
S=${WORKDIR}/${BASE_P}
KEYWORDS="amd64 ~arm arm64 ~hppa ~loong ppc ppc64 ~riscv ~sparc x86"
IUSE="debug hardened"
REQUIRED_USE="
arm? ( savedconfig )
hppa? ( savedconfig )
riscv? ( savedconfig )
sparc? ( savedconfig )
"
RDEPEND="
!sys-kernel/gentoo-kernel-bin:${SLOT}
"
BDEPEND="
debug? ( dev-util/pahole )
verify-sig? ( >=sec-keys/openpgp-keys-kernel-20250702 )
"
PDEPEND="
>=virtual/dist-kernel-${PV}
"
QA_FLAGS_IGNORED="
usr/src/linux-.*/scripts/gcc-plugins/.*.so
usr/src/linux-.*/vmlinux
usr/src/linux-.*/arch/powerpc/kernel/vdso.*/vdso.*.so.dbg
"
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kernel.org.asc
src_unpack() {
if use verify-sig; then
cd "${DISTDIR}" || die
verify-sig_verify_signed_checksums \
"linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc" \
sha256 "${BASE_P}.tar.xz patch-${PATCH_PV}.xz"
cd "${WORKDIR}" || die
fi
default
}
src_prepare() {
local patch
eapply "${WORKDIR}/patch-${PATCH_PV}"
eapply "${WORKDIR}/${PATCHSET}"
default
# add Gentoo patchset version
local extraversion=${PV#${PATCH_PV}}
sed -i -e "s:^\(EXTRAVERSION =\).*:\1 ${extraversion/_/-}:" Makefile || die
local biendian=false
# prepare the default config
case ${ARCH} in
arm | hppa | loong | riscv | sparc)
> .config || die
;;
amd64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-x86_64-fedora.config" .config || die
;;
arm64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-aarch64-fedora.config" .config || die
biendian=true
;;
ppc)
# assume powermac/powerbook defconfig
# we still package.use.force savedconfig
cp "arch/powerpc/configs/pmac32_defconfig" .config || die
;;
ppc64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-ppc64le-fedora.config" .config || die
biendian=true
;;
x86)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-i686-fedora.config" .config || die
;;
*)
die "Unsupported arch ${ARCH}"
;;
esac
local myversion="-gentoo-dist"
use hardened && myversion+="-hardened"
echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die
local dist_conf_path="${WORKDIR}/${GENTOO_CONFIG_P}"
local merge_configs=(
"${T}"/version.config
"${dist_conf_path}"/base.config
)
use debug || merge_configs+=(
"${dist_conf_path}"/no-debug.config
)
if use hardened; then
merge_configs+=( "${dist_conf_path}"/hardened-base.config )
tc-is-gcc && merge_configs+=( "${dist_conf_path}"/hardened-gcc-plugins.config )
if [[ -f "${dist_conf_path}/hardened-${ARCH}.config" ]]; then
merge_configs+=( "${dist_conf_path}/hardened-${ARCH}.config" )
fi
fi
# this covers ppc64 and aarch64_be only for now
if [[ ${biendian} == true && $(tc-endian) == big ]]; then
merge_configs+=( "${dist_conf_path}/big-endian.config" )
fi
use secureboot && merge_configs+=( "${dist_conf_path}/secureboot.config" )
kernel-build_merge_configs "${merge_configs[@]}"
}
@@ -1,155 +0,0 @@
# Copyright 2020-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
KERNEL_IUSE_GENERIC_UKI=1
inherit kernel-build toolchain-funcs verify-sig
BASE_P=linux-${PV%.*}
PATCH_PV=${PV%_p*}
PATCHSET=linux-gentoo-patches-${PV}
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
# forked to git.gentoo.org:fork/fedora/kernel
CONFIG_VER=6.12.41-gentoo
GENTOO_CONFIG_P=gentoo-kernel-config-g18
SHA256SUM_DATE=20260515
DESCRIPTION="Linux kernel built with Gentoo patches"
HOMEPAGE="
https://wiki.gentoo.org/wiki/Project:Distribution_Kernel
https://www.kernel.org/
"
SRC_URI+="
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${BASE_P}.tar.xz
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/patch-${PATCH_PV}.xz
https://distfiles.gentoo.org/pub/proj/dist-kernel/patchsets/$(ver_cut 1-2)/${PATCHSET}.tar.xz
https://gitweb.gentoo.org/proj/dist-kernel/gentoo-kernel-config.git/snapshot/${GENTOO_CONFIG_P}.tar.bz2
https://gitweb.gentoo.org/fork/fedora/kernel.git/snapshot/kernel-${CONFIG_VER}.tar.bz2
verify-sig? (
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/sha256sums.asc
-> linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc
)
"
S=${WORKDIR}/${BASE_P}
KEYWORDS="amd64 ~arm arm64 ~hppa ~loong ppc ppc64 ~riscv ~sparc x86"
IUSE="debug hardened"
REQUIRED_USE="
arm? ( savedconfig )
hppa? ( savedconfig )
sparc? ( savedconfig )
"
RDEPEND="
!sys-kernel/gentoo-kernel-bin:${SLOT}
"
BDEPEND="
debug? ( dev-util/pahole )
verify-sig? ( >=sec-keys/openpgp-keys-kernel-20250702 )
"
PDEPEND="
>=virtual/dist-kernel-${PV}
"
QA_FLAGS_IGNORED="
usr/src/linux-.*/scripts/gcc-plugins/.*.so
usr/src/linux-.*/vmlinux
usr/src/linux-.*/arch/powerpc/kernel/vdso.*/vdso.*.so.dbg
"
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kernel.org.asc
src_unpack() {
if use verify-sig; then
cd "${DISTDIR}" || die
verify-sig_verify_signed_checksums \
"linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc" \
sha256 "${BASE_P}.tar.xz patch-${PATCH_PV}.xz"
cd "${WORKDIR}" || die
fi
default
}
src_prepare() {
local patch
eapply "${WORKDIR}/patch-${PATCH_PV}"
eapply "${WORKDIR}/${PATCHSET}"
default
# add Gentoo patchset version
local extraversion=${PV#${PATCH_PV}}
sed -i -e "s:^\(EXTRAVERSION =\).*:\1 ${extraversion/_/-}:" Makefile || die
local biendian=false
# prepare the default config
case ${ARCH} in
arm | hppa | loong | sparc)
> .config || die
;;
amd64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-x86_64-fedora.config" .config || die
;;
arm64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-aarch64-fedora.config" .config || die
biendian=true
;;
ppc)
# assume powermac/powerbook defconfig
# we still package.use.force savedconfig
cp "arch/powerpc/configs/pmac32_defconfig" .config || die
;;
ppc64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-ppc64le-fedora.config" .config || die
biendian=true
;;
riscv)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-riscv64-fedora.config" .config || die
;;
x86)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-i686-fedora.config" .config || die
;;
*)
die "Unsupported arch ${ARCH}"
;;
esac
local myversion="-gentoo-dist"
use hardened && myversion+="-hardened"
echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die
local dist_conf_path="${WORKDIR}/${GENTOO_CONFIG_P}"
local merge_configs=(
"${T}"/version.config
"${dist_conf_path}"/base.config
"${dist_conf_path}"/6.12+.config
)
use debug || merge_configs+=(
"${dist_conf_path}"/no-debug.config
)
if use hardened; then
merge_configs+=( "${dist_conf_path}"/hardened-base.config )
tc-is-gcc && merge_configs+=( "${dist_conf_path}"/hardened-gcc-plugins.config )
if [[ -f "${dist_conf_path}/hardened-${ARCH}.config" ]]; then
merge_configs+=( "${dist_conf_path}/hardened-${ARCH}.config" )
fi
fi
# this covers ppc64 and aarch64_be only for now
if [[ ${biendian} == true && $(tc-endian) == big ]]; then
merge_configs+=( "${dist_conf_path}/big-endian.config" )
fi
use secureboot && merge_configs+=(
"${dist_conf_path}/secureboot.config"
"${dist_conf_path}/zboot.config"
)
kernel-build_merge_configs "${merge_configs[@]}"
}
@@ -1,155 +0,0 @@
# Copyright 2020-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
KERNEL_IUSE_GENERIC_UKI=1
inherit kernel-build toolchain-funcs verify-sig
BASE_P=linux-${PV%.*}
PATCH_PV=${PV%_p*}
PATCHSET=linux-gentoo-patches-${PV}
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
# forked to git.gentoo.org:fork/fedora/kernel
CONFIG_VER=6.18.12-gentoo
GENTOO_CONFIG_P=gentoo-kernel-config-g18
SHA256SUM_DATE=20260515
DESCRIPTION="Linux kernel built with Gentoo patches"
HOMEPAGE="
https://wiki.gentoo.org/wiki/Project:Distribution_Kernel
https://www.kernel.org/
"
SRC_URI+="
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${BASE_P}.tar.xz
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/patch-${PATCH_PV}.xz
https://distfiles.gentoo.org/pub/proj/dist-kernel/patchsets/$(ver_cut 1-2)/${PATCHSET}.tar.xz
https://gitweb.gentoo.org/proj/dist-kernel/gentoo-kernel-config.git/snapshot/${GENTOO_CONFIG_P}.tar.bz2
https://gitweb.gentoo.org/fork/fedora/kernel.git/snapshot/kernel-${CONFIG_VER}.tar.bz2
verify-sig? (
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/sha256sums.asc
-> linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc
)
"
S=${WORKDIR}/${BASE_P}
KEYWORDS="amd64 ~arm arm64 ~hppa ~loong ppc ppc64 ~riscv ~sparc x86"
IUSE="debug hardened"
REQUIRED_USE="
arm? ( savedconfig )
hppa? ( savedconfig )
sparc? ( savedconfig )
"
RDEPEND="
!sys-kernel/gentoo-kernel-bin:${SLOT}
"
BDEPEND="
debug? ( dev-util/pahole )
verify-sig? ( >=sec-keys/openpgp-keys-kernel-20250702 )
"
PDEPEND="
>=virtual/dist-kernel-${PV}
"
QA_FLAGS_IGNORED="
usr/src/linux-.*/scripts/gcc-plugins/.*.so
usr/src/linux-.*/vmlinux
usr/src/linux-.*/arch/powerpc/kernel/vdso.*/vdso.*.so.dbg
"
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kernel.org.asc
src_unpack() {
if use verify-sig; then
cd "${DISTDIR}" || die
verify-sig_verify_signed_checksums \
"linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc" \
sha256 "${BASE_P}.tar.xz patch-${PATCH_PV}.xz"
cd "${WORKDIR}" || die
fi
default
}
src_prepare() {
local patch
eapply "${WORKDIR}/patch-${PATCH_PV}"
eapply "${WORKDIR}/${PATCHSET}"
default
# add Gentoo patchset version
local extraversion=${PV#${PATCH_PV}}
sed -i -e "s:^\(EXTRAVERSION =\).*:\1 ${extraversion/_/-}:" Makefile || die
local biendian=false
# prepare the default config
case ${ARCH} in
arm | hppa | loong | sparc)
> .config || die
;;
amd64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-x86_64-fedora.config" .config || die
;;
arm64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-aarch64-fedora.config" .config || die
biendian=true
;;
ppc)
# assume powermac/powerbook defconfig
# we still package.use.force savedconfig
cp "arch/powerpc/configs/pmac32_defconfig" .config || die
;;
ppc64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-ppc64le-fedora.config" .config || die
biendian=true
;;
riscv)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-riscv64-fedora.config" .config || die
;;
x86)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-i686-fedora.config" .config || die
;;
*)
die "Unsupported arch ${ARCH}"
;;
esac
local myversion="-gentoo-dist"
use hardened && myversion+="-hardened"
echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die
local dist_conf_path="${WORKDIR}/${GENTOO_CONFIG_P}"
local merge_configs=(
"${T}"/version.config
"${dist_conf_path}"/base.config
"${dist_conf_path}"/6.12+.config
)
use debug || merge_configs+=(
"${dist_conf_path}"/no-debug.config
)
if use hardened; then
merge_configs+=( "${dist_conf_path}"/hardened-base.config )
tc-is-gcc && merge_configs+=( "${dist_conf_path}"/hardened-gcc-plugins.config )
if [[ -f "${dist_conf_path}/hardened-${ARCH}.config" ]]; then
merge_configs+=( "${dist_conf_path}/hardened-${ARCH}.config" )
fi
fi
# this covers ppc64 and aarch64_be only for now
if [[ ${biendian} == true && $(tc-endian) == big ]]; then
merge_configs+=( "${dist_conf_path}/big-endian.config" )
fi
use secureboot && merge_configs+=(
"${dist_conf_path}/secureboot.config"
"${dist_conf_path}/zboot.config"
)
kernel-build_merge_configs "${merge_configs[@]}"
}
@@ -1,152 +0,0 @@
# Copyright 2020-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
KERNEL_IUSE_GENERIC_UKI=1
inherit kernel-build toolchain-funcs verify-sig
BASE_P=linux-${PV%.*}
PATCH_PV=${PV%_p*}
PATCHSET=linux-gentoo-patches-${PV}
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
# forked to git.gentoo.org:fork/fedora/kernel
CONFIG_VER=6.6.12-gentoo
GENTOO_CONFIG_P=gentoo-kernel-config-g17
SHA256SUM_DATE=20260515
DESCRIPTION="Linux kernel built with Gentoo patches"
HOMEPAGE="
https://wiki.gentoo.org/wiki/Project:Distribution_Kernel
https://www.kernel.org/
"
SRC_URI+="
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${BASE_P}.tar.xz
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/patch-${PATCH_PV}.xz
https://distfiles.gentoo.org/pub/proj/dist-kernel/patchsets/$(ver_cut 1-2)/${PATCHSET}.tar.xz
https://gitweb.gentoo.org/proj/dist-kernel/gentoo-kernel-config.git/snapshot/${GENTOO_CONFIG_P}.tar.bz2
https://gitweb.gentoo.org/fork/fedora/kernel.git/snapshot/kernel-${CONFIG_VER}.tar.bz2
verify-sig? (
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/sha256sums.asc
-> linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc
)
"
S=${WORKDIR}/${BASE_P}
KEYWORDS="amd64 ~arm arm64 ~hppa ~loong ppc ppc64 ~riscv ~sparc x86"
IUSE="debug hardened"
REQUIRED_USE="
arm? ( savedconfig )
hppa? ( savedconfig )
riscv? ( savedconfig )
sparc? ( savedconfig )
"
RDEPEND="
!sys-kernel/gentoo-kernel-bin:${SLOT}
"
BDEPEND="
debug? ( dev-util/pahole )
verify-sig? ( >=sec-keys/openpgp-keys-kernel-20250702 )
"
PDEPEND="
>=virtual/dist-kernel-${PV}
"
QA_FLAGS_IGNORED="
usr/src/linux-.*/scripts/gcc-plugins/.*.so
usr/src/linux-.*/vmlinux
usr/src/linux-.*/arch/powerpc/kernel/vdso.*/vdso.*.so.dbg
"
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kernel.org.asc
src_unpack() {
if use verify-sig; then
cd "${DISTDIR}" || die
verify-sig_verify_signed_checksums \
"linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc" \
sha256 "${BASE_P}.tar.xz patch-${PATCH_PV}.xz"
cd "${WORKDIR}" || die
fi
default
}
src_prepare() {
local patch
eapply "${WORKDIR}/patch-${PATCH_PV}"
eapply "${WORKDIR}/${PATCHSET}"
default
# add Gentoo patchset version
local extraversion=${PV#${PATCH_PV}}
sed -i -e "s:^\(EXTRAVERSION =\).*:\1 ${extraversion/_/-}:" Makefile || die
local biendian=false
# prepare the default config
case ${ARCH} in
arm | hppa | loong | riscv | sparc)
> .config || die
;;
amd64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-x86_64-fedora.config" .config || die
;;
arm64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-aarch64-fedora.config" .config || die
biendian=true
;;
ppc)
# assume powermac/powerbook defconfig
# we still package.use.force savedconfig
cp "arch/powerpc/configs/pmac32_defconfig" .config || die
;;
ppc64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-ppc64le-fedora.config" .config || die
biendian=true
;;
x86)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-i686-fedora.config" .config || die
;;
*)
die "Unsupported arch ${ARCH}"
;;
esac
local myversion="-gentoo-dist"
use hardened && myversion+="-hardened"
echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die
local dist_conf_path="${WORKDIR}/${GENTOO_CONFIG_P}"
local merge_configs=(
"${T}"/version.config
"${dist_conf_path}"/base.config
)
use debug || merge_configs+=(
"${dist_conf_path}"/no-debug.config
)
if use hardened; then
merge_configs+=( "${dist_conf_path}"/hardened-base.config )
tc-is-gcc && merge_configs+=( "${dist_conf_path}"/hardened-gcc-plugins.config )
if [[ -f "${dist_conf_path}/hardened-${ARCH}.config" ]]; then
merge_configs+=( "${dist_conf_path}/hardened-${ARCH}.config" )
fi
fi
# this covers ppc64 and aarch64_be only for now
if [[ ${biendian} == true && $(tc-endian) == big ]]; then
merge_configs+=( "${dist_conf_path}/big-endian.config" )
fi
use secureboot && merge_configs+=(
"${dist_conf_path}/secureboot.config"
"${dist_conf_path}/zboot.config"
)
kernel-build_merge_configs "${merge_configs[@]}"
}
@@ -1,155 +0,0 @@
# Copyright 2020-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
KERNEL_IUSE_GENERIC_UKI=1
inherit kernel-build toolchain-funcs verify-sig
BASE_P=linux-${PV%.*}
PATCH_PV=${PV%_p*}
PATCHSET=linux-gentoo-patches-${PV}
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
# forked to git.gentoo.org:fork/fedora/kernel
CONFIG_VER=7.0.8-gentoo
GENTOO_CONFIG_P=gentoo-kernel-config-g18
SHA256SUM_DATE=20260515
DESCRIPTION="Linux kernel built with Gentoo patches"
HOMEPAGE="
https://wiki.gentoo.org/wiki/Project:Distribution_Kernel
https://www.kernel.org/
"
SRC_URI+="
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${BASE_P}.tar.xz
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/patch-${PATCH_PV}.xz
https://distfiles.gentoo.org/pub/proj/dist-kernel/patchsets/$(ver_cut 1-2)/${PATCHSET}.tar.xz
https://gitweb.gentoo.org/proj/dist-kernel/gentoo-kernel-config.git/snapshot/${GENTOO_CONFIG_P}.tar.bz2
https://gitweb.gentoo.org/fork/fedora/kernel.git/snapshot/kernel-${CONFIG_VER}.tar.bz2
verify-sig? (
https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/sha256sums.asc
-> linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc
)
"
S=${WORKDIR}/${BASE_P}
KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"
IUSE="debug hardened"
REQUIRED_USE="
arm? ( savedconfig )
hppa? ( savedconfig )
sparc? ( savedconfig )
"
RDEPEND="
!sys-kernel/gentoo-kernel-bin:${SLOT}
"
BDEPEND="
debug? ( dev-util/pahole )
verify-sig? ( >=sec-keys/openpgp-keys-kernel-20250702 )
"
PDEPEND="
>=virtual/dist-kernel-${PV}
"
QA_FLAGS_IGNORED="
usr/src/linux-.*/scripts/gcc-plugins/.*.so
usr/src/linux-.*/vmlinux
usr/src/linux-.*/arch/powerpc/kernel/vdso.*/vdso.*.so.dbg
"
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kernel.org.asc
src_unpack() {
if use verify-sig; then
cd "${DISTDIR}" || die
verify-sig_verify_signed_checksums \
"linux-$(ver_cut 1).x-sha256sums-${SHA256SUM_DATE}.asc" \
sha256 "${BASE_P}.tar.xz patch-${PATCH_PV}.xz"
cd "${WORKDIR}" || die
fi
default
}
src_prepare() {
local patch
eapply "${WORKDIR}/patch-${PATCH_PV}"
eapply "${WORKDIR}/${PATCHSET}"
default
# add Gentoo patchset version
local extraversion=${PV#${PATCH_PV}}
sed -i -e "s:^\(EXTRAVERSION =\).*:\1 ${extraversion/_/-}:" Makefile || die
local biendian=false
# prepare the default config
case ${ARCH} in
arm | hppa | loong | sparc)
> .config || die
;;
amd64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-x86_64-fedora.config" .config || die
;;
arm64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-aarch64-fedora.config" .config || die
biendian=true
;;
ppc)
# assume powermac/powerbook defconfig
# we still package.use.force savedconfig
cp "arch/powerpc/configs/pmac32_defconfig" .config || die
;;
ppc64)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-ppc64le-fedora.config" .config || die
biendian=true
;;
riscv)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-riscv64-fedora.config" .config || die
;;
x86)
cp "${WORKDIR}/kernel-${CONFIG_VER}/kernel-i686-fedora.config" .config || die
;;
*)
die "Unsupported arch ${ARCH}"
;;
esac
local myversion="-gentoo-dist"
use hardened && myversion+="-hardened"
echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die
local dist_conf_path="${WORKDIR}/${GENTOO_CONFIG_P}"
local merge_configs=(
"${T}"/version.config
"${dist_conf_path}"/base.config
"${dist_conf_path}"/6.12+.config
)
use debug || merge_configs+=(
"${dist_conf_path}"/no-debug.config
)
if use hardened; then
merge_configs+=( "${dist_conf_path}"/hardened-base.config )
tc-is-gcc && merge_configs+=( "${dist_conf_path}"/hardened-gcc-plugins.config )
if [[ -f "${dist_conf_path}/hardened-${ARCH}.config" ]]; then
merge_configs+=( "${dist_conf_path}/hardened-${ARCH}.config" )
fi
fi
# this covers ppc64 and aarch64_be only for now
if [[ ${biendian} == true && $(tc-endian) == big ]]; then
merge_configs+=( "${dist_conf_path}/big-endian.config" )
fi
use secureboot && merge_configs+=(
"${dist_conf_path}/secureboot.config"
"${dist_conf_path}/zboot.config"
)
kernel-build_merge_configs "${merge_configs[@]}"
}