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.96.ebuild96
2 files changed, 98 insertions, 0 deletions
diff --git a/sys-kernel/gentoo-kernel/Manifest b/sys-kernel/gentoo-kernel/Manifest
index c1e958f61342..62fe6086ec54 100644
--- a/sys-kernel/gentoo-kernel/Manifest
+++ b/sys-kernel/gentoo-kernel/Manifest
@@ -28,6 +28,8 @@ DIST genpatches-5.4-96.base.tar.xz 3031600 BLAKE2B 9ba35f7958842a1fd4c9a7e7d3666
DIST genpatches-5.4-96.extras.tar.xz 1772 BLAKE2B f33c734139f65245694d3cb98712733a901e89c79d05fab03de42d82d6e45ed3ec41ab4e17f2cd20be2ec31d469cf02a5efc7bad93832c67d3ad0bbf147b07e6 SHA512 8b7d6d058906b9c9afb7addba0c3072d70758bd75ea2989787beab5a3a83725541b4084c34cbb1e90b6cc8bb323a002dfca7065cc88fc834891f04397caa645c
DIST genpatches-5.4-97.base.tar.xz 3041620 BLAKE2B 4b738b0b9dc990d47577b44c4d1931c28727b461891a673eaa82e3add22f56f57494548c76ce6f63872f62d2b58c2c4e1fbdb84d5b4233f1a9df326fe29de60a SHA512 34adda6c55d8fd491c8c667c9ed71deb6afd4f92fcb26999baec619088dd3483be0b665a76bcf72f1f52abfb6b0bb8a0909c2cb549220ec130afdaa0ea482c84
DIST genpatches-5.4-97.extras.tar.xz 1772 BLAKE2B 5c0ed8ac19c10d0e95ff270bb7c2fd559405218f836290df7bdcd5c07ac3cb7e06221d05e40906d97242807ece263c1aa226cba583e5a822d55328608c765d1c SHA512 08cbda97510319fc497b806238c76eb60ad12b35ec7e075ee10ae3cbc6db61b1b3ea061c9c7b3a11f21125fb0d9e111a6a717eed6c3f885a7244d9e63e02c697
+DIST genpatches-5.4-98.base.tar.xz 3049548 BLAKE2B 38d6f3b3c7121721667ae183683e7e2fb9e3edb66d5caccb7a802429c4f6ee68b2cbda5503464064268efbc8f7f3d7fb5c66164f08c815f228c439fc3d55adb4 SHA512 174247357b558834635b90b79346c7c5005a84fd17c0d20cbe09d2405a7d32b0d7e3f14a8683e26f1c12058d510f2827ed0cab5fbb12cb829679a10c317e25bd
+DIST genpatches-5.4-98.extras.tar.xz 1772 BLAKE2B 620bd1c1f60762806ecf90c391f97864567d8ebbf41279bf3a10e1a98de636cefa9616907bdb4922e7ae8c202ef5f3d68a5f551d83af54e70f5252431172730b SHA512 a1c5f239564745bbf1347831995699d52011d856d0965d020cb6f082bb5ca9031f8f9e6fa7d692f04042bbfdcd9aea7e20721198a961021ffa62bd5fcce666a1
DIST gentoo-kernel-config-5.10.7.tar.gz 1146 BLAKE2B f755581e9f3be3122e5f6e6fc133d3e5c3116d4580b53f95ff5b2cee5150233fe82be5cd45637a9792ae4612be5d2cb4dd954506f97fe82c9e96cb8b772cb342 SHA512 8c64768e83d2552e69a29c6c3f958ef6a1e5a767acd04b3bfcd0cd49453ab5d0aa54fcfee76a8c9d07f72abdbf70380b070e3d1584e7b7d05a6daa3399892f51
DIST gentoo-kernel-config-5.4.77-r1.tar.gz 1289 BLAKE2B 6612741cfbf458f4bd8915b476aac3aa6934e8bbab344da877fa4ad52b6133e01f5d44bf0e5d048e79e56c1a351774135ee55f1aa839b230e2418db7c5d9b123 SHA512 2a09dd85af37447b278847aeaad114ef47470726cec015ed5ee1b54b3080f4b2c48de8b2f7b817eeb4e27c753579cf0820053e22caa762cb1552116d8d69eba0
DIST gentoo-kernel-config-5.4.89.tar.gz 1240 BLAKE2B 50bd2e64eb1a62d2f0d67e02b78da56cb507fd7a5993d663b880c94ecd535898285ed01e00d5d07fc1ba0d044657e776456736d8fdcacecf7ca464979a8a1d06 SHA512 ad31f9895b9dd45edd7f8715516edfc303c23600f243f3ca122c7c554c9fdbe3c3aa62970a24ef7291d7937e04c63c0258f6348e796686902a011c055c1bed01
diff --git a/sys-kernel/gentoo-kernel/gentoo-kernel-5.4.96.ebuild b/sys-kernel/gentoo-kernel/gentoo-kernel-5.4.96.ebuild
new file mode 100644
index 000000000000..f26abd9fdf78
--- /dev/null
+++ b/sys-kernel/gentoo-kernel/gentoo-kernel-5.4.96.ebuild
@@ -0,0 +1,96 @@
+# Copyright 2020-2021 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##*.} + 2 ))
+# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
+CONFIG_VER=5.4.21
+CONFIG_HASH=2809b7faa6a8cb232cd825096c146b7bdc1e08ea
+GENTOO_CONFIG_VER=5.4.89
+
+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/v${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.config
+ -> kernel-x86_64.config.${CONFIG_VER}
+ )
+ arm64? (
+ https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-aarch64.config
+ -> kernel-aarch64.config.${CONFIG_VER}
+ )
+ ppc64? (
+ https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-ppc64le.config
+ -> kernel-ppc64le.config.${CONFIG_VER}
+ )
+ x86? (
+ https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-i686.config
+ -> kernel-i686.config.${CONFIG_VER}
+ )"
+S=${WORKDIR}/${MY_P}
+
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86"
+IUSE="debug"
+
+RDEPEND="
+ !sys-kernel/vanilla-kernel:${SLOT}
+ !sys-kernel/vanilla-kernel-bin:${SLOT}"
+BDEPEND="
+ debug? ( dev-util/dwarves )"
+PDEPEND="
+ >=virtual/dist-kernel-${PV}"
+
+pkg_pretend() {
+ ewarn "Starting with 5.4.52, 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.config.${CONFIG_VER}" .config || die
+ ;;
+ arm64)
+ cp "${DISTDIR}/kernel-aarch64.config.${CONFIG_VER}" .config || die
+ ;;
+ ppc64)
+ cp "${DISTDIR}/kernel-ppc64le.config.${CONFIG_VER}" .config || die
+ ;;
+ x86)
+ cp "${DISTDIR}/kernel-i686.config.${CONFIG_VER}" .config || die
+ ;;
+ *)
+ die "Unsupported arch ${ARCH}"
+ ;;
+ esac
+
+ local merge_configs=(
+ "${WORKDIR}/gentoo-kernel-config-${GENTOO_CONFIG_VER}"/base.config
+ )
+ use debug || merge_configs+=(
+ "${WORKDIR}/gentoo-kernel-config-${GENTOO_CONFIG_VER}"/no-debug.config
+ )
+ [[ ${ARCH} == x86 ]] && merge_configs+=(
+ "${WORKDIR}/gentoo-kernel-config-${GENTOO_CONFIG_VER}"/32-bit.config
+ )
+
+ kernel-build_merge_configs "${merge_configs[@]}"
+}