summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-kernel')
-rw-r--r--sys-kernel/gentoo-kernel/Manifest2
-rw-r--r--sys-kernel/gentoo-kernel/gentoo-kernel-5.4.22.ebuild73
2 files changed, 75 insertions, 0 deletions
diff --git a/sys-kernel/gentoo-kernel/Manifest b/sys-kernel/gentoo-kernel/Manifest
index 35202b1744bc..c003b6bb0f23 100644
--- a/sys-kernel/gentoo-kernel/Manifest
+++ b/sys-kernel/gentoo-kernel/Manifest
@@ -4,6 +4,8 @@ DIST genpatches-4.19-105.base.tar.xz 3179988 BLAKE2B 7f85c9011564ccdb368f0bef5b2
DIST genpatches-4.19-105.extras.tar.xz 17496 BLAKE2B 82c72721eca259b0945b7f8ae3271d40f9ff90980de96f015c7c8011cb6ae771c1938b61d76ed1939b2c63002dc388ca5644f360b53da55a9f74a9f5ac9cdf01 SHA512 be72c2c3728f92d644a78fb19e353d24f70aa986b4e316a8788265fabc1fd2bd9412845d5c058fb38b7b538e836126fee3e3c95e3b857a38ff48ec8130361c79
DIST genpatches-5.4-21.base.tar.xz 825640 BLAKE2B 2f6da03c546be189d057dc44b5772f56ab25e8ff50b8775524b93af1387651e98c7a8077dd8f1f1c094767499256ee6336ba6fd28f9fad7dccef3d82f72899bb SHA512 c408a85d4e6929b10f0cda2315c0b0db69afe6916b7fdcf6f86dd9d607b4722fa212e772ec18eb162ff031d2ec0899e4dbef934710d80f17d7c90a8bea8f7e72
DIST genpatches-5.4-21.extras.tar.xz 1744 BLAKE2B c033e92c37a242bb1df4d3f75c7cba258bd51bc918e056632d351e801ee5ec0beb0f63f54be0eea3f45b1e5850cb97579ff287714f0d3d53898b6e57ba0b9641 SHA512 14b17b599ad1fdfa72355ee0450fbe448d28216ce5ed5f96a750bc633539e7a9d1a2547edfd658cfcf9ff8667f929c6c0966c3725fe53f69554a6ae7c2e5e210
+DIST genpatches-5.4-22.base.tar.xz 915300 BLAKE2B d178fedfcfdb604ddf37bc23f1fa6565f8e0cedfdcc632bb20d4683db9161621eee3f998430e9c26df39712065669db4b81471fb3fdbc7b52f457e9bc05ddf37 SHA512 77e0fb0bb06f2fcf5f42141e5386779fc2f83db9f12ceb4e5d9ea3e38b8e32fa3d189432127ae73ceeab08ef0d781a26f39cb5439963e656c72abc31e1b2f750
+DIST genpatches-5.4-22.extras.tar.xz 1744 BLAKE2B f11d59a1f630a1fd8b328d62454575e46029bfa35a0f26579677dfd1bf19e7a4c12870d4d673717570d9ceed81a43d6cac515acee003bfca9bba6f3d526b70c5 SHA512 b05d44f5d0b0f3b77396b2de1a720cda33ebc4114381b6d781eb495f31c586e228abb83a9144198f199f2fa2b237d8212a7195de70171097f71bc19a1d259db0
DIST genpatches-5.5-7.base.tar.xz 227724 BLAKE2B 145760f3866f91db9fc0e17ea0d9590d1a929237904ab673ad1be4e93d70a8edc1e9cb50a3dca71d96bb05299c38e5ef7e47fdf72acf763303f2730512bfaa0b SHA512 14e625f4db186029b6b6cff3e556fcfb56ad62d6d0ab8a9cd26746806d9365ddde1cd6429125343bdb71a8c4822104c54e3aadfe6f2eadeefa046a99fa64bcdb
DIST genpatches-5.5-7.extras.tar.xz 1744 BLAKE2B 98147f7615e0a2e40ba9e0ae877235bc05ad661112ae4a5162a70bc6ede02c448d1c781b29ec2658a24b64155331aebff34fa8885ba7563b1791651fb0039ce0 SHA512 532cfbee8638bb2a524cada24f796d2b7e8aab23fa825c8957c0743d14f2494ee97d7f04f754b3645869a095edbd82ca99b11717df0345e8d79b910cb6dbd8d7
DIST linux-4.19.85-arch1.i686.config 222183 BLAKE2B 03eac77940db0ee6b4f2a006edc600ef34141bbca849f5be4de9b961301a8fc987da6d0e21344aa5d80c29bb7793d56cf5441abb6c8e4057d94e2601c174c1be SHA512 6bd45c9dfd96b1afb8c1ca1ca72722baee6c91894e454d7af937de02242d3bb9d3b6870f5976aa96245c753c6bc1ac637a6356125b0d4c596aadef643b8c3d8d
diff --git a/sys-kernel/gentoo-kernel/gentoo-kernel-5.4.22.ebuild b/sys-kernel/gentoo-kernel/gentoo-kernel-5.4.22.ebuild
new file mode 100644
index 000000000000..49f94f6888a8
--- /dev/null
+++ b/sys-kernel/gentoo-kernel/gentoo-kernel-5.4.22.ebuild
@@ -0,0 +1,73 @@
+# 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##*.}
+# https://git.archlinux.org/svntogit/packages.git/log/trunk/config?h=packages/linux-lts
+AMD64_CONFIG_VER=5.4.18.arch1
+AMD64_CONFIG_HASH=f81c67d74936ab16f9356add6600be0de003abb4
+# https://git.archlinux32.org/packages/log/core/linux-lts/config
+I686_CONFIG_VER=5.4.18.arch1
+I686_CONFIG_HASH=c4c120c5fde43a49d84db7d60a9722e2ca1d1c2a
+
+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://git.archlinux.org/svntogit/packages.git/plain/trunk/config?h=packages/linux-lts&id=${AMD64_CONFIG_HASH}
+ -> linux-${AMD64_CONFIG_VER}.amd64.config
+ )
+ x86? (
+ https://git.archlinux32.org/packages/plain/core/linux-lts/config?id=${I686_CONFIG_HASH}
+ -> linux-${I686_CONFIG_VER}.i686.config
+ )"
+S=${WORKDIR}/${MY_P}
+
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~x86"
+
+RDEPEND="
+ !sys-kernel/vanilla-kernel:${SLOT}
+ !sys-kernel/vanilla-kernel-bin:${SLOT}"
+
+src_prepare() {
+ local PATCHES=(
+ # meh, genpatches have no directory
+ "${WORKDIR}"/*.patch
+ )
+ default
+
+ # prepare the default config
+ case ${ARCH} in
+ amd64)
+ cp "${DISTDIR}"/linux-${AMD64_CONFIG_VER}.amd64.config .config || die
+ ;;
+ x86)
+ cp "${DISTDIR}"/linux-${I686_CONFIG_VER}.i686.config .config || die
+ ;;
+ *)
+ die "Unsupported arch ${ARCH}"
+ ;;
+ esac
+
+ local config_tweaks=(
+ # shove arch under the carpet!
+ -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'
+ # disable compression to allow stripping
+ -e '/CONFIG_MODULE_COMPRESS/d'
+ # disable gcc plugins to unbreak distcc
+ -e '/CONFIG_GCC_PLUGIN_STRUCTLEAK/d'
+ )
+ sed -i "${config_tweaks[@]}" .config || die
+}