diff options
author | Michał Górny <mgorny@gentoo.org> | 2020-10-17 16:06:51 +0200 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2020-10-17 21:01:20 +0200 |
commit | 8e154ecbafbd745ef9612df45eb1b38345a50198 (patch) | |
tree | bcb02e45efcb2cc3597600faec170bcbc3476730 /sys-kernel | |
parent | sys-kernel/vanilla-kernel: Bump to 5.9.1 (diff) | |
download | gentoo-8e154ecbafbd745ef9612df45eb1b38345a50198.tar.gz gentoo-8e154ecbafbd745ef9612df45eb1b38345a50198.tar.bz2 gentoo-8e154ecbafbd745ef9612df45eb1b38345a50198.zip |
sys-kernel/gentoo-kernel: Bump to 5.9.1
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'sys-kernel')
-rw-r--r-- | sys-kernel/gentoo-kernel/Manifest | 2 | ||||
-rw-r--r-- | sys-kernel/gentoo-kernel/gentoo-kernel-5.9.1.ebuild | 134 |
2 files changed, 136 insertions, 0 deletions
diff --git a/sys-kernel/gentoo-kernel/Manifest b/sys-kernel/gentoo-kernel/Manifest index c0c74aa89b46..b967341a816b 100644 --- a/sys-kernel/gentoo-kernel/Manifest +++ b/sys-kernel/gentoo-kernel/Manifest @@ -24,6 +24,8 @@ DIST genpatches-5.8-19.base.tar.xz 596728 BLAKE2B ceb6cd57b593b5a2c02f00cefc6103 DIST genpatches-5.8-19.extras.tar.xz 1772 BLAKE2B c42390c17040a6557054835df177fe87ee124bcdcea91e1a63d50ed8e07a10044d639616497e02082fbb67a708ed408bd1e94a3c9d5b7c7b0c7daeca2bfc65df SHA512 3ba07566f1e721521676b862ca51654638400eeda4f216cdfb860b0639b7a611b2ff2e9659007486841e9a1afa8c05a9454abae87abbc7dff8af396bd0d7100a DIST genpatches-5.9-1.base.tar.xz 4004 BLAKE2B 8a4577d42262fa901186acc60d28221d00e5c9140886705f018d9989f818d96ee4d9a6586b292e7b1d945bea9e2408e3161a73e0999defe1b7f99d0a339eb7be SHA512 d6ba1051f9561aa30d7b196336c34930285d613e8119b152f1d6cc447cb22db5ac07c25f89d4ceddf58c9370c42699d0250a31449be2da3c591896b0c87d8718 DIST genpatches-5.9-1.extras.tar.xz 1764 BLAKE2B 32d29f0448aef113ba9c9591c5d3b671d00d07abde9f35f365b48168887913bb2da95a8a52b852453307cabb111115a26178be4cbcc016e53a26a31f783a9df7 SHA512 df007dc98c1acdd31773f7dcf8aeb22812aa55e5593e8509b6a8762f2dcf06c95d69ad7cdce992e7a5fe730754bef26242acdc4e4da51ee29206fabb86c9cb0e +DIST genpatches-5.9-2.base.tar.xz 9332 BLAKE2B cfccc2ebc7e067c7326f95627470a01f818f3c64db87ca26406bd3fa71429593a4460cf82d5891961eee69cbce667c850439f512650131013025491804486510 SHA512 af9c158cf65c5aa5d678d4ffeb7395051a9706521684f3a984f47d6ad581652978eb8f0a4de0132a3603b63fa7f34fb8b18a76bca5d4d312672c89f3fa221fa8 +DIST genpatches-5.9-2.extras.tar.xz 1768 BLAKE2B 1e9312bc96d30b85ff628a67bed4bf2ded3eb2231d804158d343d64ce6a1be3d313bcdf84406cfa34045df9aa239ae1ed476f838ff466e0df96b60b28caa15b8 SHA512 58b19bd67b573657c44861d65792fb7fed0c430a554e95b2dc41a3f53ec8a50e68f89130a68ae0167de9ba98076326ae843264d76a178efaecece90121d0f337 DIST kernel-aarch64-fedora.config.5.8.5 215148 BLAKE2B c71380f46c1b37e9e17bab6d78907114369b377bcbdb54afa2c35b6a222937fd061f25309d8de0cc78ef2329ede7192722270acceeaa3da4629a5f58d8fee809 SHA512 e86e2c60e88b1ea5968db1a471d7d928ccb3146fe850f8f2813ef315f2de0cbfa0daa2f6828dee71acb2299f65f05fc0b6f1572a82fb146ae9f53a905fe94e97 DIST kernel-aarch64-fedora.config.5.9.0 217558 BLAKE2B 38e3c31b710c30d29dbf0b5304c2b9e0615af08ec11a01318bc0c4811b91a0803a96483e986f3dd83369b14e9329bdeb0e0d834761af9a644d831eba43eb910d SHA512 d38d05aef2a809207a186eacc365118d68e7ef82939b45ac5b9038cb493c771f8fa10009a0082f36c79c2e6b5b2ec193a6b1f50bc51a6190b77f57ab7cf237a1 DIST kernel-aarch64.config.5.4.21 199104 BLAKE2B 578ad451a76204df2a9bbbe34b5cb27051d2ac5e2c33967f562b01338c43f35da6dc33a4c2cc67ea6c3b32b155729360d3748ec28dcaa750f18449245b2e8a09 SHA512 66e9a437beb350fdc59512c17b8f72c5b5bfacf2b35070d810d77e66f49cf7929026cc28ad44b04a016d61e65d9fb4a10af6996ba09b604bf97e9c467d08f8ff diff --git a/sys-kernel/gentoo-kernel/gentoo-kernel-5.9.1.ebuild b/sys-kernel/gentoo-kernel/gentoo-kernel-5.9.1.ebuild new file mode 100644 index 000000000000..e7a5b2ccc317 --- /dev/null +++ b/sys-kernel/gentoo-kernel/gentoo-kernel-5.9.1.ebuild @@ -0,0 +1,134 @@ +# Copyright 2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit kernel-build + +MY_P=linux-${PV%.*} +GENPATCHES_P=genpatches-${PV%.*}-$(( ${PV##*.} + 1 )) +# https://koji.fedoraproject.org/koji/packageinfo?packageID=8 +CONFIG_VER=5.9.0 +CONFIG_HASH=aa6d9438d030fa4682d5d450481085c901503da5 + +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/~mpagano/dist/genpatches/${GENPATCHES_P}.base.tar.xz + https://dev.gentoo.org/~mpagano/dist/genpatches/${GENPATCHES_P}.extras.tar.xz + 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 ~ppc64 ~x86" +IUSE="debug" +REQUIRED_USE="arm? ( savedconfig )" + +RDEPEND=" + !sys-kernel/vanilla-kernel:${SLOT} + !sys-kernel/vanilla-kernel-bin:${SLOT}" +BDEPEND=" + debug? ( dev-util/dwarves )" + +pkg_pretend() { + ewarn "Starting with 5.7.9, Distribution Kernels are switching from Arch" + ewarn "Linux configs to Fedora. Please keep a backup kernel just in case." + + kernel-install_pkg_pretend +} + +src_prepare() { + local PATCHES=( + # meh, genpatches have no directory + "${WORKDIR}"/*.patch + ) + default + + # 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 + ;; + ppc64) + cp "${DISTDIR}/kernel-ppc64le-fedora.config.${CONFIG_VER}" .config || die + ;; + x86) + cp "${DISTDIR}/kernel-i686-fedora.config.${CONFIG_VER}" .config || die + ;; + *) + die "Unsupported arch ${ARCH}" + ;; + esac + + local config_tweaks=( + # replace (none) with gentoo + -e 's:^CONFIG_DEFAULT_HOSTNAME=:&"gentoo":' + # we do support x32 + -e '/CONFIG_X86_X32/s:.*:CONFIG_X86_X32=y:' + # disable signatures + -e '/CONFIG_MODULE_SIG/d' + -e '/CONFIG_SECURITY_LOCKDOWN/d' + -e '/CONFIG_KEXEC_SIG/d' + -e '/CONFIG_KEXEC_BZIMAGE_VERIFY_SIG/d' + -e '/CONFIG_SYSTEM_EXTRA_CERTIFICATE/d' + -e '/CONFIG_SIGNATURE/d' + # remove massive array of LSMs + -e 's/CONFIG_LSM=.*/CONFIG_LSM="yama"/' + -e 's/CONFIG_DEFAULT_SECURITY_SELINUX=y/CONFIG_DEFAULT_SECURITY_DAC=y/' + # nobody actually wants fips + -e '/CONFIG_CRYPTO_FIPS/d' + # these tests are really not necessary + -e 's/.*CONFIG_CRYPTO_MANAGER_DISABLE_TESTS.*/CONFIG_CRYPTO_MANAGER_DISABLE_TESTS=y/' + # probably not needed by anybody but developers + -e '/CONFIG_CRYPTO_STATS/d' + # 1000hz is excessive for laptops + -e 's/CONFIG_HZ_1000=y/CONFIG_HZ_300=y/' + # nobody is using this kernel on insane super computers + -e 's/CONFIG_NR_CPUS=.*/CONFIG_NR_CPUS=512/' + # we're not actually producing live patches for folks + -e 's/CONFIG_LIVEPATCH=y/CONFIG_LIVEPATCH=n/' + # this slows down networking in general + -e 's/CONFIG_IP_FIB_TRIE_STATS=y/CONFIG_IP_FIB_TRIE_STATS=n/' + # include font for normal and hidpi screens + -e 's/.*CONFIG_FONTS.*/CONFIG_FONTS=y\nCONFIG_FONT_8x16=y\nCONFIG_FONT_TER16x32=y/' + # we don't need to actually install system headers from this ebuild + -e '/CONFIG_HEADERS_INSTALL/d' + # enable /proc/config.gz, used by linux-info.eclass + -e '/CONFIG_IKCONFIG/s:.*:CONFIG_IKCONFIG=y\nCONFIG_IKCONFIG_PROC=y:' + ) + use debug || config_tweaks+=( + -e '/CONFIG_DEBUG_INFO/d' + -e '/CONFIG_DEBUG_RODATA_TEST/d' + -e '/CONFIG_DEBUG_VM/d' + -e '/CONFIG_DEBUG_SHIRQ/d' + -e '/CONFIG_DEBUG_LIST/d' + -e '/CONFIG_BUG_ON_DATA_CORRUPTION/d' + -e '/CONFIG_TORTURE_TEST/d' + -e '/CONFIG_BOOTTIME_TRACING/d' + -e '/CONFIG_RING_BUFFER_BENCHMARK/d' + -e '/CONFIG_X86_DECODER_SELFTEST/d' + -e '/CONFIG_KGDB/d' + ) + sed -i "${config_tweaks[@]}" .config || die +} |