diff options
-rw-r--r-- | sys-kernel/gentoo-kernel-bin/Manifest | 6 | ||||
-rw-r--r-- | sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-6.6.35.ebuild | 161 |
2 files changed, 167 insertions, 0 deletions
diff --git a/sys-kernel/gentoo-kernel-bin/Manifest b/sys-kernel/gentoo-kernel-bin/Manifest index 65f251e1c82f..e0f04b5ac4c5 100644 --- a/sys-kernel/gentoo-kernel-bin/Manifest +++ b/sys-kernel/gentoo-kernel-bin/Manifest @@ -22,6 +22,8 @@ DIST genpatches-6.6-40.base.tar.xz 2364536 BLAKE2B 53bf04c020921c8d0c2e7ff8466db DIST genpatches-6.6-40.extras.tar.xz 4052 BLAKE2B e3e882483caa9222b702b1387c1cd5a1888b6466611b3dca23f9368f423040f27006c8889e477a4ef52719213433e4ad6187322e80ea236ff390aa306b4a5e33 SHA512 509bfb18a8218c6a7eec28543cad0db44b5a693c50465dfda09b92dd176a5102c3c2fd064a7426c0b33d4acd1dd58b77483babcd44389999bbfbc5757cd0fac9 DIST genpatches-6.6-41.base.tar.xz 2399184 BLAKE2B 5765835d442a0afe00be3070b1780107331959538c7a9a7b7d8107e9c9bd563b0dc25f031db926ae3b24f2ea4126d1c8e29837e5993f647896ca6ed620158274 SHA512 7601b25d287627373f69628de865658305471f428ba20bd41d9e2cc3762e2ee4648675f899843ea6c4b6b68c108cd3a5d049bae249ddfc089f2988ee69ed1491 DIST genpatches-6.6-41.extras.tar.xz 4052 BLAKE2B a3ed97dd21f02f8b5a8b2e315b9581780310177da774123c7cfdb30c13485e1ec8379b57e10749e3abbd1860f7e52a5111ac5f63250d015e9aec5e64386d4571 SHA512 39932e2c61d1687ceb64698186551ac5e8c184f58e24692f6b22cde65644da5375c58f26dd7cb0e1bf5f21a737b6fcc6ffbd86372e5c055c8dd2ae001efcaf6c +DIST genpatches-6.6-42.base.tar.xz 2474752 BLAKE2B 074b24c3848ba0b2521d364d67222ab324cfacc3036b2c3b9ceebebf03afcf21d963921841f6f987422e904be35653f9dafc2a795ed6eaa050d6a37595bdd111 SHA512 6ce7c93c92a5f2951c9a60b7a058560dec8c3f9c16f00ac4b58c23f88ceaf9cbc519653320bc95f45039219eecb068247f3c27ac448c8695ed8c9e93022fdc37 +DIST genpatches-6.6-42.extras.tar.xz 4048 BLAKE2B 0d86f11ef43c33b1014423a4417be73e4ace2eb5d9c38c7a63e8bc424eff7399137239138de1b89a70247f1b174766c9672cb05743aeaa14ea66d8bab67593bc SHA512 5d264209a734c4cbc48dab228b7d8570b735748b1c01f80beb2803dca3027ed78303ff937aecb1d8e3e6f2e2d4722aa0c1b5c77a4d45f2a9c53cfe1c0ac0affd DIST genpatches-6.9-5.base.tar.xz 275240 BLAKE2B cb961b8245eaa58405bf758f4432f1ad98b767d7f9ea8e45fb440bd2616e67c6e12cff6ec3af89748f19043c9b0b58b634e28e7bcdc469fcc4daf2f752b3a438 SHA512 60fb3290eabe8289fc4acb4f1df809ace44d7678188683b64ef2ec92edb8c2ac0d757280ebb63087145fd068e64619a3b0a9227fd5f3061099d287e8e8dd5720 DIST genpatches-6.9-5.extras.tar.xz 4052 BLAKE2B e72e5a5195db42f38ed671899217d7609eb8a5d9f954ebbc36a53a88fcadd1cadecf7257b33a880661e949f2c7b176a5762ecc1e56be0195e6768d8be8ae5fc4 SHA512 3d9315afb5c45cf24f6e5287048d49f6969e49ba2c8f339d9f4da0f5a08708ffa65636c3d24efdcfd246f6d28c72535089078971e97f7aefeb75119a67cee11d DIST genpatches-6.9-6.base.tar.xz 319896 BLAKE2B 8b58a70db0844a8455fb413de046cf0998c19c2ace54918a3408f9d31eae6bf276d6a86f5db835cc3ac87335d908c2ba853fd2f334e80cd06e7e72847483d3de SHA512 fa3f1efa0886a6df0ce8006a4433a8bf91731069aed6040e1e4ac9002dbb879ed644f2ba1b258a92ae8550709b85a3c1d2657df000cc6dfe4f79d32c991efcb6 @@ -74,6 +76,10 @@ DIST gentoo-kernel-6.6.34-1.amd64.gpkg.tar 147261440 BLAKE2B 8e6ed75198b4882ecfe DIST gentoo-kernel-6.6.34-1.arm64.gpkg.tar 119203840 BLAKE2B fcfe329412c32e779cc6bc049d5cf1edb50af7582cd76300033a6295ba9fcaaab66548102b95475a1d4663463f8cacebb9779e8df9cc0f2b1b15826643682e25 SHA512 cffb4ba0ce3fe462c3954df016cfaf0f7878dd736518d4d21d2d60aa140c694840d56dd0bbe036acb64f7a46b3640fc086f06453cbdae4af9b66f3055a838d52 DIST gentoo-kernel-6.6.34-1.ppc64le.gpkg.tar 64235520 BLAKE2B 1a3ab1bf89c10350a1825ce5b782f44beb6d5ea7f407fffba98d2f6155f68e5a8505a2e8ba9a86257dc98beae3804556b8f9d82636f5953deabb8af53e9780ea SHA512 a1462d44657d5808bc8b6249346f6cebf8d1007ff6b8eebdfd31050a02b5060e6b576dbb6251177d00d03e7865a85da273b44ce0b1f0908b348f81ecc9d7833c DIST gentoo-kernel-6.6.34-1.x86.gpkg.tar 68259840 BLAKE2B 7b2fd356724edbaf3a2ecd38bc05f03aa1213895cf43264e2574494f0265e5c99978a08c93b62a56d7f946c2fd00f1f42272c3609b3d83057b733286c5a8feb1 SHA512 3ea663d49deb2bd5661a64555dd13451c285f1f13c82c38ebd38fe79a05e86da397cf9d89d5c290c7628ac086528aa268d415efabebc6568b391b9656f73c5ce +DIST gentoo-kernel-6.6.35-1.amd64.gpkg.tar 147220480 BLAKE2B 45178fff1c0cdf75499f735666eb89ef0a6248ab6182b3e4e9d85688aa2eca5322310363038f64d1d932a6fac244fb16d64b05b146471fa663f6f0350c647832 SHA512 91f81fd1ffc6ed01bbfc94fe52395c8c5f3bc10c7f7445df2c1d6c982c81b0154ea7638c5322089c2119363c8a810498b111d6e9562e6de7ce0672a41509e95e +DIST gentoo-kernel-6.6.35-1.arm64.gpkg.tar 119214080 BLAKE2B 3342aba4c25236a26179d92a24938ff96c771c6b2da0e3590c37a06a5516d8005a7ac97fa076dcab8191abd2d8b07813b59b4f48fc71e885de2714b681e8930a SHA512 183c5557d19e6690bb02eb5f55bb1bd8bf16bbda9e69533b84d00c61d75e4b62d66842c753f4a9a8294c8e6127d428f3958f7d14661620e9c6866862546a73d3 +DIST gentoo-kernel-6.6.35-1.ppc64le.gpkg.tar 64256000 BLAKE2B 89441b1e5b8b5de47e2e1b176e3cc51d1a4b19b8d7200c5168d40a3268b7e5a8b5af2a858ae567306ae2e4ada44046a55a72a1dfe7a3c6133592c897f2a28d77 SHA512 38a106716a3169e9a316d458ae541069594b21c494476876aa99661c3061f34e62ace80e2ed6028111790b9d504788c5b1c8a7494ee8f9b66b6ba52f37864896 +DIST gentoo-kernel-6.6.35-1.x86.gpkg.tar 68259840 BLAKE2B 9e5fc0f1aec739679e96819a3607148697f04af277d69464eccc515fca2f3b499d3811600eb29e27cdd4d2dab186d8e047302acaf8de2f8f2c81c871e702f83d SHA512 d3fffe7209444cda7754e47f80f0e01d844c91de4761103dc9625a643ec568029c0037777259e49d1a016dab82e99cbbd8e4210fe0b544b530a9c19400a0dfa5 DIST gentoo-kernel-6.9.4-1.amd64.gpkg.tar 159006720 BLAKE2B 9e2189d7ea4546bf9d3a937ff0f3cd95929749931b4850a198c543b753a76e6e2305492fa4cd03ca3221c070107b6b1e76cee3eb5c066ca273d0b8b4b2f67efc SHA512 87b26e414a79051271531e6152b10ac11b6834983e9bd500056a4d95aead6efd2bcd45ec0456973cd464ee4b66349929e0db1cacbab50a7b8e30484293377166 DIST gentoo-kernel-6.9.4-1.arm64.gpkg.tar 129740800 BLAKE2B aaffce5d2f922f53de6b4ebebd23ce2edf40731e79a325bf07502f0b61f440edf85d6551ac70f6d96f539ff3636091e7aeb478e74b7e45fc0adb5b8add5f31e9 SHA512 61ebb357a3a4d4cb80f90bdcb5e8ab02c810b1a39ca4aa95a2bb3be56e85435625c427f3ddf93313623e42ad81aac7a206c14eec60865ed7d661d1451779dfd8 DIST gentoo-kernel-6.9.4-1.ppc64le.gpkg.tar 70737920 BLAKE2B 02097895e96decedf998bffaf2c442623e27c9a530c7f57dc6a6bbe7bc566142215d90a71055ea383e63d146d77cb4c3b0b3d017156f4f8f1cba22ad46bc2f0a SHA512 9057f864de4f15e7b1911f91e21cc71c888e95c26035ea3246e0f116d5a7817266ecea2e08cf1f9eb09bf41481be570034638ee1775f09e39901c599bd6b4d90 diff --git a/sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-6.6.35.ebuild b/sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-6.6.35.ebuild new file mode 100644 index 000000000000..ecc98612a7de --- /dev/null +++ b/sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-6.6.35.ebuild @@ -0,0 +1,161 @@ +# Copyright 2020-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +KERNEL_EFI_ZBOOT=1 +KERNEL_IUSE_GENERIC_UKI=1 +KERNEL_IUSE_SECUREBOOT=1 + +inherit kernel-install toolchain-funcs unpacker + +MY_P=linux-${PV%.*} +GENPATCHES_P=genpatches-${PV%.*}-$(( ${PV##*.} + 7 )) +BINPKG=${PF/-bin}-1 + +DESCRIPTION="Pre-built Linux kernel 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://dev.gentoo.org/~mgorny/binpkg/amd64/kernel/sys-kernel/gentoo-kernel/${BINPKG}.gpkg.tar + -> ${BINPKG}.amd64.gpkg.tar + ) + arm64? ( + https://dev.gentoo.org/~mgorny/binpkg/arm64/kernel/sys-kernel/gentoo-kernel/${BINPKG}.gpkg.tar + -> ${BINPKG}.arm64.gpkg.tar + ) + ppc64? ( + https://dev.gentoo.org/~mgorny/binpkg/ppc64le/kernel/sys-kernel/gentoo-kernel/${BINPKG}.gpkg.tar + -> ${BINPKG}.ppc64le.gpkg.tar + ) + x86? ( + https://dev.gentoo.org/~mgorny/binpkg/x86/kernel/sys-kernel/gentoo-kernel/${BINPKG}.gpkg.tar + -> ${BINPKG}.x86.gpkg.tar + ) +" +S=${WORKDIR} + +KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86" + +RDEPEND=" + !sys-kernel/gentoo-kernel:${SLOT} +" +PDEPEND=" + >=virtual/dist-kernel-${PV} +" +BDEPEND=" + app-alternatives/bc + app-alternatives/lex + virtual/libelf + app-alternatives/yacc +" + +QA_PREBUILT='*' + +KV_LOCALVERSION='-gentoo-dist' +KPV=${PV}${KV_LOCALVERSION} + +src_prepare() { + local PATCHES=( + # meh, genpatches have no directory + "${WORKDIR}"/*.patch + ) + cd "${MY_P}" || die + default +} + +src_configure() { + # force ld.bfd if we can find it easily + local LD="$(tc-getLD)" + if type -P "${LD}.bfd" &>/dev/null; then + LD+=.bfd + fi + + tc-export_build_env + local makeargs=( + V=1 + + HOSTCC="$(tc-getBUILD_CC)" + HOSTCXX="$(tc-getBUILD_CXX)" + HOSTCFLAGS="${BUILD_CFLAGS}" + HOSTLDFLAGS="${BUILD_LDFLAGS}" + + CROSS_COMPILE=${CHOST}- + AS="$(tc-getAS)" + CC="$(tc-getCC)" + LD="${LD}" + AR="$(tc-getAR)" + NM="$(tc-getNM)" + STRIP="$(tc-getSTRIP)" + OBJCOPY="$(tc-getOBJCOPY)" + OBJDUMP="$(tc-getOBJDUMP)" + + # we need to pass it to override colliding Gentoo envvar + ARCH="$(tc-arch-kernel)" + + O="${WORKDIR}"/modprep + ) + + local kernel_dir="${BINPKG}/image/usr/src/linux-${KPV}" + local image="${kernel_dir}/$(dist-kernel_get_image_path)" + local uki="${image%/*}/uki.efi" + if [[ -s ${uki} ]]; then + # We need to extract the plain image for the test phase + # and USE=-generic-uki. + kernel-install_extract_from_uki linux "${uki}" "${image}" + fi + + mkdir modprep || die + cp "${kernel_dir}/.config" modprep/ || die + emake -C "${MY_P}" "${makeargs[@]}" modules_prepare +} + +src_test() { + local kernel_dir="${BINPKG}/image/usr/src/linux-${KPV}" + kernel-install_test "${KPV}" \ + "${WORKDIR}/${kernel_dir}/$(dist-kernel_get_image_path)" \ + "${BINPKG}/image/lib/modules/${KPV}" +} + +src_install() { + local kernel_dir="${BINPKG}/image/usr/src/linux-${KPV}" + local image="${kernel_dir}/$(dist-kernel_get_image_path)" + local uki="${image%/*}/uki.efi" + if [[ -s ${uki} ]]; then + # Keep the kernel image type we don't want out of install tree + # Replace back with placeholder + if use generic-uki; then + > "${image}" || die + else + > "${uki}" || die + fi + fi + + mv "${BINPKG}"/image/{lib,usr} "${ED}"/ || die + + # FIXME: requires proper mount-boot + if [[ -d ${BINPKG}/image/boot/dtbs ]]; then + mv "${BINPKG}"/image/boot "${ED}"/ || die + fi + + # strip out-of-source build stuffs from modprep + # and then copy built files + find modprep -type f '(' \ + -name Makefile -o \ + -name '*.[ao]' -o \ + '(' -name '.*' -a -not -name '.config' ')' \ + ')' -delete || die + rm modprep/source || die + cp -p -R modprep/. "${ED}/usr/src/linux-${KPV}"/ || die + + # Update timestamps on all modules to ensure cleanup works correctly + # when switching USE=modules-compress. + find "${ED}/lib" -name '*.ko' -exec touch {} + || die + + # Modules were already stripped before signing + dostrip -x /lib/modules + kernel-install_compress_modules +} |