diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-07-23 20:51:24 +0100 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-07-23 20:51:24 +0100 |
commit | fceabcd48faf4c890719a14ac4ed93b6b7993364 (patch) | |
tree | 509e41dc22637aa99b763e5fc14944d8e235c304 /sys-kernel/gentoo-kernel | |
parent | 674b648c65d37f018cecade7f66ab3162ed94a8e (diff) |
gentoo auto-resync : 23:07:2022 - 20:51:24
Diffstat (limited to 'sys-kernel/gentoo-kernel')
-rw-r--r-- | sys-kernel/gentoo-kernel/Manifest | 6 | ||||
-rw-r--r-- | sys-kernel/gentoo-kernel/gentoo-kernel-5.15.57.ebuild | 131 | ||||
-rw-r--r-- | sys-kernel/gentoo-kernel/gentoo-kernel-5.18.14.ebuild | 137 |
3 files changed, 274 insertions, 0 deletions
diff --git a/sys-kernel/gentoo-kernel/Manifest b/sys-kernel/gentoo-kernel/Manifest index 3e52adbaab13..c3f5f4c53da3 100644 --- a/sys-kernel/gentoo-kernel/Manifest +++ b/sys-kernel/gentoo-kernel/Manifest @@ -18,6 +18,8 @@ DIST genpatches-5.15-59.base.tar.xz 2355388 BLAKE2B b7752f0691ff64a0bbffaa262a67 DIST genpatches-5.15-59.extras.tar.xz 3932 BLAKE2B 7438a1bd3f63bd989b93b8d1bcc2474406670958291d7cbffaab792789461336d30465664e6d36c2cc91d77d82fb1ac521d13dfc7cf9691563dc417370dd3107 SHA512 127ab6f173b230c4b0656653af36a5086d021d3ac81d5549a60ca681c1873dba351aa33e3fe96da811dfa6e0a006cab14aa6894f03a9eac1a447df8f724d75cd DIST genpatches-5.15-60.base.tar.xz 2403720 BLAKE2B cc8a8e72894d9139fc2c51412e09c7c7069523ce42ef67f2e6e14230d7ef75bafb58938314f4a93d0e6e1c5e544fea54f70b23f0ab6f7f02156bcadac26bc1ba SHA512 bf345a4ba71d02865344bafc19e996e7d2ce5ef2ff0b9a956b85a2f88a386f786670f569b812eabc0cc4d841c9ed45e050b3865350c6f38a61bad8372180246a DIST genpatches-5.15-60.extras.tar.xz 3932 BLAKE2B 2c9b704aa65d9ba6fab93252cd581efe31324fed7d1886bb118a25efe26daba4dd40d75cb263edf6df89323e9967b6f2277692fdcdbb6a50146e669f45c364c5 SHA512 e63206136bf81d5a9012d71396474f6214cbb7980ff4427fa60e69a7d96dde918174a964a6269e6278b4bad6f5faabfb79c1d0c5e3dfb4efc4f13fbc17979273 +DIST genpatches-5.15-61.base.tar.xz 2438712 BLAKE2B 44a8bff3e2df4203943aab61398ce4f136f5101e10a8764885202e799e8d5a6a1270800c5c8cbec98aac4ede007a49616120356aae66008ef2578698aa25dd3e SHA512 88cc84df8f11c8f714a629cba8b22dc730b1cc90d5285c2c5475ef808715418e4080f421ad268c7e8a34c18dc70962b89fbbb23c73ab5f3c76f30435d98ad0ee +DIST genpatches-5.15-61.extras.tar.xz 3932 BLAKE2B f2579301f9ee4e2dd46dd65472bf208d62642df674863cc905dceb0e91d62cc3e64f1d0d4ed99f0ca9c010108b7df58a12a34b6291eab34f565d9d4ec69c2751 SHA512 17463a7d9e3a2e017654e78dcffba58114ec5cae5e67858f7f3c50bf14a92c1b488f85f4fd5fb61eb53fc74f6a90f0ab152ba9396d0d928050851b4c5ab643d7 DIST genpatches-5.18-12.base.tar.xz 549680 BLAKE2B d6973dfb0d7749fadfc511b1092dedc67b3f8a57e2a117674113f43177bde8608b6106c4c84fbf5f5a161b9710cfad28a3c2fd419fb3c4088d98f9a504ae0cb8 SHA512 c7ad63058bb77c92d3ecf618a41164476a56f2b7b879c667c7fc9666fa1d7f81b599d6ffc5f0fbaa3223e7d399dbb6348ddd511598581083f7b78d505dd81e7c DIST genpatches-5.18-12.extras.tar.xz 3920 BLAKE2B 89642c29bae1b15664749c11e581ebf1d0b42801cbd3e436805faaacc419fa7d946a05e7d37bc8d056e36768d181b2e71dfdd6b28943ea112dad9f17a9c2bde1 SHA512 301cd52af9db5a8ec91891a0258a262261d87cf22cb01c27a531d0274ee23d0e928977abe8f5928d3dcba430d032a3cb418193bd1f3e09a923ca6e8718ec7420 DIST genpatches-5.18-13.base.tar.xz 578484 BLAKE2B 03215db005e5a3668898b1ac4c25aeee5f20d6802d00b11d24d41f506ca9f730f031f5cde187f81406a3c75937d65f854acd3c0e2d2cf9f9cb3ba99454304180 SHA512 bdf29085cf76022aa21faaee63033e3231b9757282633eb5897717128bc340cbf38b12a2918b169b452e85aafc9fadac2645df414f877f43950a3147e00dea68 @@ -28,6 +30,8 @@ DIST genpatches-5.18-15.base.tar.xz 610660 BLAKE2B d3a1d9a432ffc110af26d74e96b04 DIST genpatches-5.18-15.extras.tar.xz 3928 BLAKE2B da2016d84154d129ef32595c04f06f861aa91c7981f9122e8120284a04ac0064785ebb2a4717d544c475f63388e36aa2d2012dc426a9a8f9f66492a507e1755c SHA512 743610e02ce92f053bf41351253d27966de5c3dc0a5499e00328debb2d64f7bb41d29dc5670f11e63dbe2e8baf466a7b99fd2b70ba37a7698f53b25044790196 DIST genpatches-5.18-17.base.tar.xz 670556 BLAKE2B 9f992048a0a964e6a96b077682d6a8412c2f35a15c3b5533c36d474cc724fb9983205fa8f177a9172f5f0c1e26b6127edac3da89b702dc088d3b7bcb24513822 SHA512 d8f38eeebc11f382e0c57f668f213d07f5d2f99c210133d831ee29feef90bfc81eb57c9c9fa173548ef4dba05865990539a879cf0bc1b548ca6a75bdd934e069 DIST genpatches-5.18-17.extras.tar.xz 3924 BLAKE2B 4d8bb90dc2446493cee33f5db27f46f4a5d6cb60dac8137f5677a133d71bf2feb5db6b9ebbf32fb148c39be3024f5f378ce096fb0c21ea584d3dca01862e160f SHA512 b1ccb518b25c7bea5cccbdec03d0d8d42ab0b048f6f10f2f036871699d5e75e3694ec10922a0e8f01f640cb3710d8e38124e878450842cce060f6202359ca090 +DIST genpatches-5.18-18.base.tar.xz 701140 BLAKE2B ee91222d6f6ce56d30cfe02b5546fcf7ee3ba04852c4875e9c98ed4177a7b73311e515e543a20107ddd1542077c9b4e2d13fd9cd0e05d507ade84f8fbb942300 SHA512 57aa8878d165ce05c2981c25e9a381df8ac8004336de88b330f779841683a1998dce79cb0e0c1263c77c81a84f01768630ff5e2385693a79b420b5ba05136a1b +DIST genpatches-5.18-18.extras.tar.xz 3924 BLAKE2B f01ece5d1568a0a760b58108571cfcad343a37be3d344ea728ff89d3fa5c972d7d1c6808ec41ec699ece98a2049ea2c5cc036bae5f44e93cf23528a71e3aa922 SHA512 e810217c00867d3836c4606586e35cc26e8c934382d5927ca188249610b613605437013ca0015217d650e89bede32d67f4daa443bd445dec382832a4e43937ab DIST genpatches-5.4-208.base.tar.xz 4869104 BLAKE2B 3e9038248ddcfd22d67248e65199cca89bd2b8b3aa99aafcee63e5c294dc360c01d7d7eda809e1c18b06a9356363c575339197b2425bcafa8676cad68c17f90e SHA512 880fd09492e5cb0fa8a94e2df5fdf912be59210f1f142a456e3f80c31142e92bee3161bd77038b606616442cf3396b3961a24422de3056f72b4556d06262d3a5 DIST genpatches-5.4-208.extras.tar.xz 1812 BLAKE2B 3e5b8cae462a748eb36af66c4ebc393fc09882a1fa23cce6f82a078ea5598c23c2ecbe7029d6e2060735fe342b3a7bb5c235dcf16081bba0f05a6b88501af991 SHA512 b550dce1b6d090959eaacd523ee1be258fbf9db84309054c3cce9beb0bae710ff2e1c23f480310072fb08f7456bdf825b3ba76d57e999fc1597368df93e65677 DIST genpatches-5.4-209.base.tar.xz 4887256 BLAKE2B 56d7ea7975b228df055d1bd4cfc41b49890d815409a159772230c6e9d081061a9b438b525b5e8542eb03feb0bdfc1841e5bc5e14dd1570aff8f964862b192b00 SHA512 5ea69d50d836dad1f68f000c6c1f5bd8459dcbc4d50a4fbd4ba3241c4c87638850215c0207dfea6fe06cc596957e3cfa61a3dfc00f0b60513596da43d286615f @@ -70,10 +74,12 @@ EBUILD gentoo-kernel-5.15.53.ebuild 3599 BLAKE2B 166a462972d13245f59f4806e490d5d EBUILD gentoo-kernel-5.15.54.ebuild 3599 BLAKE2B 166a462972d13245f59f4806e490d5d753a7f92e424aaf0c749f1cfe2d5767027ed0259862cbaff715800081b7c289a49703968602e663eae7971342fd1c5a6c SHA512 37b83b8e617ee511971e2ac9e911479b6db1f089a4d99e04f5dc3eb80ca08d7557b29b8b21cc91d91613da18182ffac048691eb33b689890f45828253ecfe010 EBUILD gentoo-kernel-5.15.55.ebuild 3599 BLAKE2B 166a462972d13245f59f4806e490d5d753a7f92e424aaf0c749f1cfe2d5767027ed0259862cbaff715800081b7c289a49703968602e663eae7971342fd1c5a6c SHA512 37b83b8e617ee511971e2ac9e911479b6db1f089a4d99e04f5dc3eb80ca08d7557b29b8b21cc91d91613da18182ffac048691eb33b689890f45828253ecfe010 EBUILD gentoo-kernel-5.15.56.ebuild 3599 BLAKE2B 166a462972d13245f59f4806e490d5d753a7f92e424aaf0c749f1cfe2d5767027ed0259862cbaff715800081b7c289a49703968602e663eae7971342fd1c5a6c SHA512 37b83b8e617ee511971e2ac9e911479b6db1f089a4d99e04f5dc3eb80ca08d7557b29b8b21cc91d91613da18182ffac048691eb33b689890f45828253ecfe010 +EBUILD gentoo-kernel-5.15.57.ebuild 3597 BLAKE2B aa37793f8f5d37ae10a7095722e6546df7aa56549233e1b7e04dc1b6dcfd2bf05db9c357c6db3bdf02caa3414ff309ed62d798028ce81949987d9f0f1b70c15d SHA512 a745f61a8c7785de82bd0de381967306e8a58bfd2732438125ed2ac68140bc7300cf7dd0398bcd005f304e4ed809b314705a10c0b4084f78191675bdafa0a6dc EBUILD gentoo-kernel-5.18.10.ebuild 3859 BLAKE2B 39a5bf5ba05e8966d0c154ca944547d1d0fcaa320c278de676259385b59da46c41dad6cfb5a4d384e70283668a6bb8c89e297b55117ac479a307f02ddeff351c SHA512 98446575d30ca3131c36c2642cd14ce6a8e0b4053ad94da0e6cec93c82f92add00ef0c34fc18800643347c9ecbc9830ba6103485f43e991cbd4460ad37f9caa9 EBUILD gentoo-kernel-5.18.11.ebuild 3859 BLAKE2B 39a5bf5ba05e8966d0c154ca944547d1d0fcaa320c278de676259385b59da46c41dad6cfb5a4d384e70283668a6bb8c89e297b55117ac479a307f02ddeff351c SHA512 98446575d30ca3131c36c2642cd14ce6a8e0b4053ad94da0e6cec93c82f92add00ef0c34fc18800643347c9ecbc9830ba6103485f43e991cbd4460ad37f9caa9 EBUILD gentoo-kernel-5.18.12.ebuild 3857 BLAKE2B 0dee6d23887d04b56e4f6228ca833ee0cc87bfa66038ec7c36ee6874a066cd53322d92d0e12715d92843eb37e40bb71da53ee068c70af45bb3d0465d5036a71c SHA512 49bd98f3c1c0d1ad11d6156e59ccb757df9ab31c81d871efa8dc0e59a1f14e726729cd773a27b30237aa14eb0b364d5325a4818f0a8dd418eb9849e939da42b9 EBUILD gentoo-kernel-5.18.13.ebuild 3859 BLAKE2B 7d5e5654d596002eec8478b6f72c3e2b8896acdf1f691f3d329e030b031fc8d2fb46434ec039dea09f1def77086663df6710e5690c0318bc15d8028321d21271 SHA512 3af374c1492526da624dd26511c01d401750fa59a8184f978b8ae28c564644faeb91ce8652f2baffe40a8c8f7d9c59b2a269b8c36ee3636f61f8a9d70093f2da +EBUILD gentoo-kernel-5.18.14.ebuild 3857 BLAKE2B 81b04a8e1a805ba912e4ad3993f5d2915d77f3318e37e39ac95dbed503b965e064be55fd2d8ed6685836eeebb9a50a9aae5f787577cf058098cd002cf8ff9a40 SHA512 b917d360876b37c99d6c43f5884b86910d933e44b095651acef5167e6ef46826004f8f25befe001a6bf42149065a0a3d23a6aff0911d4d17c4bc034be0f89d6c EBUILD gentoo-kernel-5.18.9.ebuild 3859 BLAKE2B 39a5bf5ba05e8966d0c154ca944547d1d0fcaa320c278de676259385b59da46c41dad6cfb5a4d384e70283668a6bb8c89e297b55117ac479a307f02ddeff351c SHA512 98446575d30ca3131c36c2642cd14ce6a8e0b4053ad94da0e6cec93c82f92add00ef0c34fc18800643347c9ecbc9830ba6103485f43e991cbd4460ad37f9caa9 EBUILD gentoo-kernel-5.4.203.ebuild 2799 BLAKE2B faf615c3252cf128099b4b7359422d78b19be5b647e89e4524b519e75e1fe9a8e778398cce27093e6be22c7977f18a996a6f7e72afa813d6a8369fa9f2395e05 SHA512 70a94b7bcb72a3adb27fd4707a7a4b53d952d37857dc22a3523846faa8f77c7309017264e8601f22c4ab01c3b2726a1dbe1b0f5dd2d81c7ea28c5b486265f8d6 EBUILD gentoo-kernel-5.4.204.ebuild 2803 BLAKE2B 8aac73c55ef615de26496e74eb22f0c578f333f2d211535c9a0613f9e2b19f181245a1dcf394ffec75bec308855792ee8edf21c77a9d6c42f3249789cb15bfa6 SHA512 465a4c4f2df9f2332ac7eee6f8e5dc140e02e55ff9fac94bf465604f33d51f3b1cfcad1160bc071233e1a6e40fb15c984a26f1b2377fcdf5d7aa3a9b6536816b diff --git a/sys-kernel/gentoo-kernel/gentoo-kernel-5.15.57.ebuild b/sys-kernel/gentoo-kernel/gentoo-kernel-5.15.57.ebuild new file mode 100644 index 000000000000..0703d999bb5d --- /dev/null +++ b/sys-kernel/gentoo-kernel/gentoo-kernel-5.15.57.ebuild @@ -0,0 +1,131 @@ +# Copyright 2020-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit kernel-build toolchain-funcs + +MY_P=linux-${PV%.*} +GENPATCHES_P=genpatches-${PV%.*}-$(( ${PV##*.} + 4 )) +CONFIG_VER=5.15.19 +CONFIG_HASH=ec69da7a42b5b7c3da91572ef22097b069ddbd01 +GENTOO_CONFIG_VER=g1 + +DESCRIPTION="Linux kernel built with Gentoo patches" +HOMEPAGE="https://www.kernel.org/" +SRC_URI+=" + https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${MY_P}.tar.xz + https://dev.gentoo.org/~alicef/dist/genpatches/${GENPATCHES_P}.base.tar.xz + https://dev.gentoo.org/~alicef/dist/genpatches/${GENPATCHES_P}.extras.tar.xz + https://github.com/mgorny/gentoo-kernel-config/archive/${GENTOO_CONFIG_VER}.tar.gz + -> gentoo-kernel-config-${GENTOO_CONFIG_VER}.tar.gz + amd64? ( + https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-x86_64-fedora.config + -> kernel-x86_64-fedora.config.${CONFIG_VER} + ) + arm64? ( + https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-aarch64-fedora.config + -> kernel-aarch64-fedora.config.${CONFIG_VER} + ) + ppc64? ( + https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-ppc64le-fedora.config + -> kernel-ppc64le-fedora.config.${CONFIG_VER} + ) + x86? ( + https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-i686-fedora.config + -> kernel-i686-fedora.config.${CONFIG_VER} + ) +" +S=${WORKDIR}/${MY_P} + +LICENSE="GPL-2" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~x86" +IUSE="debug hardened" +REQUIRED_USE="arm? ( savedconfig )" + +RDEPEND=" + !sys-kernel/gentoo-kernel-bin:${SLOT} +" +BDEPEND=" + debug? ( dev-util/pahole ) +" +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 +" + +src_prepare() { + local PATCHES=( + # meh, genpatches have no directory + "${WORKDIR}"/*.patch + ) + default + + local biendian=false + + # prepare the default config + case ${ARCH} in + amd64) + cp "${DISTDIR}/kernel-x86_64-fedora.config.${CONFIG_VER}" .config || die + ;; + arm) + return + ;; + arm64) + cp "${DISTDIR}/kernel-aarch64-fedora.config.${CONFIG_VER}" .config || die + biendian=true + ;; + hppa) + return + ;; + ppc) + # assume powermac/powerbook defconfig + # we still package.use.force savedconfig + cp "${WORKDIR}/${MY_P}/arch/powerpc/configs/pmac32_defconfig" .config || die + ;; + ppc64) + cp "${DISTDIR}/kernel-ppc64le-fedora.config.${CONFIG_VER}" .config || die + biendian=true + ;; + x86) + cp "${DISTDIR}/kernel-i686-fedora.config.${CONFIG_VER}" .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-kernel-config-${GENTOO_CONFIG_VER}" + + 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 + + kernel-build_merge_configs "${merge_configs[@]}" +} diff --git a/sys-kernel/gentoo-kernel/gentoo-kernel-5.18.14.ebuild b/sys-kernel/gentoo-kernel/gentoo-kernel-5.18.14.ebuild new file mode 100644 index 000000000000..b0f35a014fbd --- /dev/null +++ b/sys-kernel/gentoo-kernel/gentoo-kernel-5.18.14.ebuild @@ -0,0 +1,137 @@ +# Copyright 2020-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit kernel-build toolchain-funcs + +MY_P=linux-${PV%.*} +GENPATCHES_P=genpatches-${PV%.*}-$(( ${PV##*.} + 4 )) +# https://koji.fedoraproject.org/koji/packageinfo?packageID=8 +# forked to https://github.com/mgorny/fedora-kernel-config-for-gentoo +CONFIG_VER=5.18.9-gentoo +GENTOO_CONFIG_VER=g2 + +DESCRIPTION="Linux kernel built with Gentoo patches" +HOMEPAGE="https://www.kernel.org/" +SRC_URI+=" + https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${MY_P}.tar.xz + https://dev.gentoo.org/~alicef/dist/genpatches/${GENPATCHES_P}.base.tar.xz + https://dev.gentoo.org/~alicef/dist/genpatches/${GENPATCHES_P}.extras.tar.xz + https://github.com/mgorny/gentoo-kernel-config/archive/${GENTOO_CONFIG_VER}.tar.gz + -> gentoo-kernel-config-${GENTOO_CONFIG_VER}.tar.gz + amd64? ( + https://raw.githubusercontent.com/mgorny/fedora-kernel-config-for-gentoo/${CONFIG_VER}/kernel-x86_64-fedora.config + -> kernel-x86_64-fedora.config.${CONFIG_VER} + ) + arm64? ( + https://raw.githubusercontent.com/mgorny/fedora-kernel-config-for-gentoo/${CONFIG_VER}/kernel-aarch64-fedora.config + -> kernel-aarch64-fedora.config.${CONFIG_VER} + ) + ppc64? ( + https://raw.githubusercontent.com/mgorny/fedora-kernel-config-for-gentoo/${CONFIG_VER}/kernel-ppc64le-fedora.config + -> kernel-ppc64le-fedora.config.${CONFIG_VER} + ) + x86? ( + https://raw.githubusercontent.com/mgorny/fedora-kernel-config-for-gentoo/${CONFIG_VER}/kernel-i686-fedora.config + -> kernel-i686-fedora.config.${CONFIG_VER} + ) +" +S=${WORKDIR}/${MY_P} + +LICENSE="GPL-2" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~riscv ~x86" +IUSE="debug hardened" +REQUIRED_USE="arm? ( savedconfig ) + hppa? ( savedconfig ) + riscv? ( savedconfig )" + +RDEPEND=" + !sys-kernel/gentoo-kernel-bin:${SLOT} +" +BDEPEND=" + debug? ( dev-util/pahole ) +" +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 +" + +src_prepare() { + local PATCHES=( + # meh, genpatches have no directory + "${WORKDIR}"/*.patch + ) + default + + local biendian=false + + # prepare the default config + case ${ARCH} in + amd64) + cp "${DISTDIR}/kernel-x86_64-fedora.config.${CONFIG_VER}" .config || die + ;; + arm) + return + ;; + arm64) + cp "${DISTDIR}/kernel-aarch64-fedora.config.${CONFIG_VER}" .config || die + biendian=true + ;; + hppa) + return + ;; + ppc) + # assume powermac/powerbook defconfig + # we still package.use.force savedconfig + cp "${WORKDIR}/${MY_P}/arch/powerpc/configs/pmac32_defconfig" .config || die + ;; + ppc64) + cp "${DISTDIR}/kernel-ppc64le-fedora.config.${CONFIG_VER}" .config || die + biendian=true + ;; + riscv) + return + ;; + x86) + cp "${DISTDIR}/kernel-i686-fedora.config.${CONFIG_VER}" .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-kernel-config-${GENTOO_CONFIG_VER}" + + 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 + + kernel-build_merge_configs "${merge_configs[@]}" +} |