diff options
-rw-r--r-- | sys-kernel/gentoo-kernel-bin/Manifest | 6 | ||||
-rw-r--r-- | sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-5.18.19.ebuild | 135 |
2 files changed, 141 insertions, 0 deletions
diff --git a/sys-kernel/gentoo-kernel-bin/Manifest b/sys-kernel/gentoo-kernel-bin/Manifest index 8c390fef5fb8..71cad30dc6d7 100644 --- a/sys-kernel/gentoo-kernel-bin/Manifest +++ b/sys-kernel/gentoo-kernel-bin/Manifest @@ -14,6 +14,8 @@ DIST genpatches-5.18-21.base.tar.xz 786248 BLAKE2B 60d007f0ad81b8c8af63789f98613 DIST genpatches-5.18-21.extras.tar.xz 3924 BLAKE2B 582b7320bf607d925d9b2e88094032b161cc08df1d5118777454f4f6b966812b333235f2bcf016957d7bcecde6d77b4dc7b76047b8374e34b9262e2aad5e4708 SHA512 26aed20e6cc179d10bb017b1707d5bf5d76a92aadd9ab73acc655352dea8c6fd03cc4848da953800077bf43d1d5e1dddeff01ba486d5c2f6524707a236a956b9 DIST genpatches-5.18-22.base.tar.xz 1204144 BLAKE2B ba4067fe632a1d27f3ac63c5bccbd7bd8d96e43436d67bae0162ef1a7b32a05a8b8ee301cdaf00765450a4c83939c11bdee27ebbd31267896bb30f5ee7d0e794 SHA512 83ba19dcbc7e1308039c4352527cdcf21caac9fa0c0e90206ef855d46e4f5d828e8f9a9e7c36a3a043f0789493d6e8df739ce97a225dad00a46e1c94c570dcc4 DIST genpatches-5.18-22.extras.tar.xz 3924 BLAKE2B 757c3a9db4b9f293a2ba903354e4ff2e922f256107a5b050fc4fdf9a0d04c5597761aa4c8c2e015da0d16af2b577521d17f437d3dd796cd0d2ccc74386141e20 SHA512 526a738627ff17c811250aa18b3e10243c0dd492822db60516bf3ce0430bc276a881548f9c6e424398ebb1da3f44270e092692332322ffa9c04457801439e774 +DIST genpatches-5.18-23.base.tar.xz 1206204 BLAKE2B 12a7b9aa7d72f27e64c4cb8f5607529dcc7d535a9375768e065d97d0b70b0726271b70dfa4ea019bb42606ddfd513b70357b2bd5ad95548c9eba9f91041f27b0 SHA512 9a459e3e8cb4a3285f782516fbc176a4a73c151281bea2258f049ec0662b806eefc54cb6e9151cc968e3a9c39789062c207d514920559954db9a10b53a1c2f0e +DIST genpatches-5.18-23.extras.tar.xz 3924 BLAKE2B fad401fd783c72bd695425a106813ce8396c6d15154fc627fb456b16f6ddff1f6326f54e1399c1369b6da5e3f57da89bc9e769bcbb5d4b612465fe187145ea17 SHA512 c25a09e1e2ad091e5f8480419e921e8eede512dcc6aeb46792a92844948eea5890c5ae8d164ae9834356e00216d3978cefe5f07b046cbaa30dfd4af73a1ddaa3 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-214.base.tar.xz 4943544 BLAKE2B 5b7d27e1b520cdaff98dc9fe6ddfe102a9c09fb8a5fd36a57d5f36ebbd7639ce1a59dbeb55e71ede1129a3890318b740b24bc654716f81840d6d2e6d8a95de20 SHA512 6494bb7d1b9ef0e46fa31a164b3c807338463dcd4d8108e5a0c5d944196f1b3e1df51192f733861514a302af3eefee530b1e173dec9b6ddd3bb0120e47714fbf @@ -52,6 +54,10 @@ DIST gentoo-kernel-5.18.18-1.amd64.xpak 72827701 BLAKE2B a9ae7e1aceea06b422a9fe1 DIST gentoo-kernel-5.18.18-1.arm64.xpak 65266650 BLAKE2B de5a490f917a8179021d0c2ed0ca69ae563f39e38f363ab501bd85db1a1cfb4a5edc311f782310c9ba3bdcce6886fed45c2771f1c7e48e44a1c3a94d3e70145a SHA512 a2163de72d85abbaa2756cf8ac0e1dbb1f8a700716570bb2bd42d5dd297f475520bd834b2f7f87ae13aff55b5731c90dea7c742c1d4ff6f72535786817daa63c DIST gentoo-kernel-5.18.18-1.ppc64le.xpak 59452234 BLAKE2B 25acccd37b8402c124ab0308d7f841b54ddcd6fdf460081525c6c28db3afc136187053a15eb4464f62dcac8b56c901884ebab40838bc47c325aeb0db27740c2c SHA512 4f58411a2947a91f81e909664e0c6086529efefae77ee0c10fa5136165ac37b9a37ffdfba084d09c5e5ee40c6909148e08e34c18b607737c988df83870b6f146 DIST gentoo-kernel-5.18.18-1.x86.xpak 62756128 BLAKE2B 18776e78eb93f144135f3e3cc846f7870bbad736bc28390bfa6f6646deac32eb05c8c957476e53643ec72f502f7c213c35db8d1044fbdb225bc3ef665105174b SHA512 19e481a00e66fecb518e3a095e8f8fbf9967a7a0d3406a1f1afb2ccc09300f1da113024e62cea0ace8699d0eacf8dc4a86cf9338e7f9de752c6ed468dd1ec730 +DIST gentoo-kernel-5.18.19-1.amd64.xpak 72942561 BLAKE2B 0717daf1b59d2104cab1f879df588ce3900d34c5819d952bf322bcce3910688b7dfb590dcee73e493e6c9e32b5b59f8067456ac5dabf63f08685e9425c00c5ee SHA512 e0eeb797c0c9123847d291b9cdbaddf125a747d3aa84bf755a6e6b09fde936c211ab6ce632a294b0b88f977f962b3fa974dd5685bf658ddd14a11f7d0b881b35 +DIST gentoo-kernel-5.18.19-1.arm64.xpak 65272358 BLAKE2B dcd3464d63d93e74ade936979ed4cae9e44edd2607ae252ede6f60980902d9ea222d346ef9007a391ff5f2a856062be8261c8e7480605238925228c467931028 SHA512 eff2578748b3da40320adf59db967778e3e5a31d568436ee119bea390a756c050968f7f60c7cc33c5ae270d98d31cdcc9c39fb5ce0cc1b38eda8671325669b09 +DIST gentoo-kernel-5.18.19-1.ppc64le.xpak 59519114 BLAKE2B 9fbe2f5d5f7737901f23ceed8c6124d17ba6fefad96e49b2868030c089822159d857a7dd3c3aaeb4dd15a3f96a8c84afd869bf1da4f06942c7dfdf2dd70337ca SHA512 9c055379dba361cc4433a7972cf49b16f61fa3b35272449e4481e5bba0db6a098a8361b6c4df2c667618c4592da12c39eeebfed81487a4a8fe223a2c4d5ee52a +DIST gentoo-kernel-5.18.19-1.x86.xpak 62836995 BLAKE2B 2f5d390255cc4882235c03c18c706e57f5873ee7d78c92f938ed7d2ed39c024db6c175f8f4f882ecd78ffd89ebbe5652f125267fdcdc0233fb251d78cd6e3cbc SHA512 d6a2f070d57aadbf0e01f5be6b263c6145786d4deda51c1ae15b198c3a868cf0f74f5a75dcac1fada6a8eeec24ae42f0ed9faaf028df96ca22d7b659a688c706 DIST gentoo-kernel-5.4.203-1.amd64.xpak 61567440 BLAKE2B 7cb004bf0d90e517a1636e984afb21be3408da74afcd4ccd886007dea5a221b33bde828ee8dad4e8fcf120d737be2d7ff4a0780f36643300209e69f996921112 SHA512 a79fbd6ce459265e4eda827063aee6557208c73094bf937959eb265d100a0533083e35276d6df77a8b8a7a05161b292232ac42b18b8a903232f2eb065192d0c9 DIST gentoo-kernel-5.4.203-1.arm64.xpak 57698276 BLAKE2B 2bc0a4eba7ef829a4e705706b7ce33496b8a36d33f0808bc315df45b9d7a00e6aabda71274956b484d394f3431bb22be118c9b37711bd5cc74d6d1d6dfa0027b SHA512 d4849d69a3a6134d260945721b164d74604a4b2e590d1545f7444fa9cfac4f7d8419b8d77dd586c87a52ef4bad3620810993a7161083370e2438b9723f249d37 DIST gentoo-kernel-5.4.203-1.ppc64le.xpak 55132763 BLAKE2B bfba496c86aeb1c0e0826e8222e60fa96a0c57b0b66af485c619eea277ed64fe590ffe0c7932da36de2c2f180772ec6dd5d1925bbdca3d52ec2c9e0ed0808113 SHA512 e598776a8d6cf90d6a92f12af3899a28eca53fe037906c0de5e57f5b8a128fdde98d9453b06e0796d4c4b8d27b5b211db1aa777a0f1636b4cfe73e26be96d9fc diff --git a/sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-5.18.19.ebuild b/sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-5.18.19.ebuild new file mode 100644 index 000000000000..cc187009eb97 --- /dev/null +++ b/sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-5.18.19.ebuild @@ -0,0 +1,135 @@ +# Copyright 2020-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit kernel-install toolchain-funcs + +MY_P=linux-${PV%.*} +GENPATCHES_P=genpatches-${PV%.*}-$(( ${PV##*.} + 4 )) +BINPKG=${P/-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/~sam/binpkg/amd64/kernel/sys-kernel/gentoo-kernel/${BINPKG}.xpak + -> ${BINPKG}.amd64.xpak + ) + arm64? ( + https://dev.gentoo.org/~sam/binpkg/arm64/kernel/sys-kernel/gentoo-kernel/${BINPKG}.xpak + -> ${BINPKG}.arm64.xpak + ) + ppc64? ( + https://dev.gentoo.org/~sam/binpkg/ppc64le/kernel/sys-kernel/gentoo-kernel/${BINPKG}.xpak + -> ${BINPKG}.ppc64le.xpak + ) + x86? ( + https://dev.gentoo.org/~sam/binpkg/x86/kernel/sys-kernel/gentoo-kernel/${BINPKG}.xpak + -> ${BINPKG}.x86.xpak + ) +" +S=${WORKDIR} + +LICENSE="GPL-2" +KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86" + +RDEPEND=" + !sys-kernel/gentoo-kernel:${SLOT} +" +PDEPEND=" + >=virtual/dist-kernel-${PV} +" +BDEPEND=" + sys-devel/bc + sys-devel/flex + virtual/libelf + virtual/yacc +" + +QA_PREBUILT='*' + +KV_LOCALVERSION='-gentoo-dist' +KPV=${PV}${KV_LOCALVERSION} + +src_unpack() { + default + # ARCH=ppc64, but tarball is ppc64le. Update if we ever introduce ppc64be binpkg. + ebegin "Unpacking ${BINPKG}.${ARCH/%ppc64/ppc64le}.xpak" + tar -x < <(xz -c -d --single-stream "${DISTDIR}/${BINPKG}.${ARCH/%ppc64/ppc64le}.xpak") + eend ${?} || die "Unpacking ${BINPKG} failed" +} + +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=":" + OBJCOPY="$(tc-getOBJCOPY)" + OBJDUMP="$(tc-getOBJDUMP)" + + # we need to pass it to override colliding Gentoo envvar + ARCH="$(tc-arch-kernel)" + + O="${WORKDIR}"/modprep + ) + + mkdir modprep || die + cp "usr/src/linux-${KPV}/.config" modprep/ || die + emake -C "${MY_P}" "${makeargs[@]}" modules_prepare +} + +src_test() { + kernel-install_test "${KPV}" \ + "${WORKDIR}/usr/src/linux-${KPV}/$(dist-kernel_get_image_path)" \ + "lib/modules/${KPV}" +} + +src_install() { + mv lib usr "${ED}"/ || die + + # FIXME: requires proper mount-boot + if [[ -d boot/dtbs ]]; then + mv 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 +} |