From 6f390f2036c50bab71374f5afd83321779c6cfea Mon Sep 17 00:00:00 2001 From: projectmoon Date: Tue, 1 Oct 2024 23:41:26 +0200 Subject: [PATCH] libre-kernel: 6.6.51; drop old kernal versions --- .../libre-kernel/libre-kernel-6.6.51.ebuild | 148 ++++++++++++++++++ .../dist-kernel/dist-kernel-5.15.137.ebuild | 20 --- .../dist-kernel/dist-kernel-5.15.142.ebuild | 20 --- .../dist-kernel/dist-kernel-5.15.147.ebuild | 17 -- .../dist-kernel/dist-kernel-5.15.148.ebuild | 17 -- .../dist-kernel/dist-kernel-5.15.151.ebuild | 17 -- .../dist-kernel/dist-kernel-5.15.158.ebuild | 17 -- .../dist-kernel/dist-kernel-5.15.160.ebuild | 17 -- .../dist-kernel/dist-kernel-5.15.161.ebuild | 17 -- .../dist-kernel/dist-kernel-5.15.163.ebuild | 17 -- ...5.145.ebuild => dist-kernel-6.6.51.ebuild} | 0 11 files changed, 148 insertions(+), 159 deletions(-) create mode 100644 sys-kernel/libre-kernel/libre-kernel-6.6.51.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.137.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.142.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.147.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.148.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.151.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.158.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.160.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.161.ebuild delete mode 100644 virtual/dist-kernel/dist-kernel-5.15.163.ebuild rename virtual/dist-kernel/{dist-kernel-5.15.145.ebuild => dist-kernel-6.6.51.ebuild} (100%) diff --git a/sys-kernel/libre-kernel/libre-kernel-6.6.51.ebuild b/sys-kernel/libre-kernel/libre-kernel-6.6.51.ebuild new file mode 100644 index 0000000..b04538e --- /dev/null +++ b/sys-kernel/libre-kernel/libre-kernel-6.6.51.ebuild @@ -0,0 +1,148 @@ +# Copyright 2020-2024 Gentoo Authors, projectmoon +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit kernel-build verify-sig + +BASE_VER="$(ver_cut 1).$(ver_cut 2).$(ver_cut 3)" +RESTRICT="mirror" + +GENPATCHES_P=genpatches-${PV%.*}-$(( ${PV##*.} + 7 )) +CONFIG_VER=6.6.12-gentoo +#CONFIG_HASH=ec69da7a42b5b7c3da91572ef22097b069ddbd01 +GENTOO_CONFIG_VER=g13 + +DESCRIPTION="GNU Linux-libre kernel built from upstream sources" +HOMEPAGE="https://www.fsfla.org/ikiwiki/selibre/linux-libre/" +SRC_URI+=" + https://git.agnos.is/projectmoon/projectmoon-overlay-files/media/branch/main/sys-kernel/libre-kernel/linux-libre-${BASE_VER}-gnu.tar.xz + https://linux-libre.fsfla.org/pub/linux-libre/releases/${BASE_VER}-gnu/linux-libre-${BASE_VER}-gnu.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 + https://github.com/projg2/gentoo-kernel-config/archive/${GENTOO_CONFIG_VER}.tar.gz + -> gentoo-kernel-config-${GENTOO_CONFIG_VER}.tar.gz + verify-sig? ( + https://git.agnos.is/projectmoon/projectmoon-overlay-files/media/branch/main/sys-kernel/libre-kernel/linux-libre-${BASE_VER}-gnu.tar.xz.sign + https://linux-libre.fsfla.org/pub/linux-libre/releases/${BASE_VER}-gnu/linux-libre-${BASE_VER}-gnu.tar.xz.sign + ) + amd64? ( + https://raw.githubusercontent.com/projg2/fedora-kernel-config-for-gentoo/${CONFIG_VER}/kernel-x86_64-fedora.config + -> kernel-x86_64-fedora.config.${CONFIG_VER} + ) +" + +# Workdir is named linux-PV. +MY_P=linux-${PV} +S=${WORKDIR}/${MY_P} + +LICENSE="GPL-2" +KEYWORDS="amd64" +IUSE="debug +gentoo" + +BDEPEND=" + debug? ( dev-util/pahole ) + verify-sig? ( sec-keys/openpgp-keys-linux-libre ) +" +PDEPEND=" + >=virtual/dist-kernel-${PV} +" + +VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linux-libre.asc + +pkg_pretend() { + if has_version -d sys-kernel/linux-firmware[redistributable]; then + ewarn "sys-kernel/linux-firmware was found installed on your system," + ewarn "but it is configured to install non-Free firmware files." + ewarn "The non-Free firmware files may be required for some hardware" + ewarn "work. The Linux-libre kernel cannot load non-Free firmware." + ewarn "To install only the Free firmware, set the -redistributable" + ewarn "USE flag on sys-kernel/linux-firmware." + + if use initramfs; then + elog + elog "If you decide to change or remove linux-firmware later, you" + elog "can rebuild the initramfs via issuing a command equivalent to:" + elog + elog " emerge --config ${CATEGORY}/${PN}:${SLOT}" + fi + else + if ! has_version -d sys-kernel/linux-firmware; then + ewarn "sys-kernel/linux-firmware[-redistributable] not found installed" + ewarn "on your system. This package provides various firmware files that" + ewarn "may be needed for your hardware to work. If in doubt, it is recommended" + ewarn "to pause or abort the build process and install it before" + ewarn "resuming." + + if use initramfs; then + elog + elog "If you decide to install linux-firmware later, you can rebuild" + elog "the initramfs via issuing a command equivalent to:" + elog + elog " emerge --config ${CATEGORY}/${PN}:${SLOT}" + fi + fi + fi +} + +src_unpack() { + if use verify-sig; then + FILE="${DISTDIR}"/linux-libre-${PV}-gnu.tar.xz + SIGFILE="${DISTDIR}"/linux-libre-${PV}-gnu.tar.xz.sign + verify-sig_verify_detached $FILE $SIGFILE + fi + + default +} + +src_prepare() { + local PATCHES + if use gentoo; then + # Fiters out the kernel incremental version upgrade patches, + # leaving only the Gentoo bug fix/functionality changes. The + # regex removes any patches starting with 10XX to 14XX. + MY_PATCHES=$(find "${WORKDIR}"/*.patch -printf "%f\n" | grep -v -E -e '^1[01234][[:digit:]][[:digit:]]_.+.patch') + PATCHES=$(echo "$MY_PATCHES" | sed 's|^|'"${WORKDIR}/"'|g') + else + # If no patches are to be applied, apply only the config changes + # for a Gentoo installation, as this does not change any actual + # Kernel functionality. + PATCHES="${WORKDIR}/4567_distro-Gentoo-Kconfig.patch" + fi + + default + + local biendian=false + + # prepare the default config + case ${ARCH} in + amd64) + cp "${DISTDIR}/kernel-x86_64-fedora.config.${CONFIG_VER}" .config || die + ;; + *) + die "Unsupported arch ${ARCH}" + ;; + esac + + sed -i 's/EXTRAVERSION = -gnu/EXTRAVERSION = /' "${S}"/Makefile || \ + die 'could not remove EXTRAVERSION' + + local myversion="-gnu-dist" + echo "CONFIG_LOCALVERSION=\"${myversion}\"" > "${T}"/version.config || die + local dist_conf_path="${WORKDIR}/gentoo-kernel-config-${GENTOO_CONFIG_VER}" + + local merge_configs=( + "${T}"/version.config + "${dist_conf_path}"/base.config + ) + use debug || merge_configs+=( + "${dist_conf_path}"/no-debug.config + ) + + # this covers ppc64 and aarch64_be only for now + if [[ ${biendian} == true && $(tc-endian) == big ]]; then + merge_configs+=( "${dist_conf_path}/big-endian.config" ) + fi + + kernel-build_merge_configs "${merge_configs[@]}" +} diff --git a/virtual/dist-kernel/dist-kernel-5.15.137.ebuild b/virtual/dist-kernel/dist-kernel-5.15.137.ebuild deleted file mode 100644 index c80b79e..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.137.ebuild +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright 2021-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -HOMEPAGE="" -SRC_URI="" - -LICENSE="" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - )" diff --git a/virtual/dist-kernel/dist-kernel-5.15.142.ebuild b/virtual/dist-kernel/dist-kernel-5.15.142.ebuild deleted file mode 100644 index c80b79e..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.142.ebuild +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright 2021-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -HOMEPAGE="" -SRC_URI="" - -LICENSE="" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - )" diff --git a/virtual/dist-kernel/dist-kernel-5.15.147.ebuild b/virtual/dist-kernel/dist-kernel-5.15.147.ebuild deleted file mode 100644 index 6980dd4..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.147.ebuild +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 2021-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - ) -" diff --git a/virtual/dist-kernel/dist-kernel-5.15.148.ebuild b/virtual/dist-kernel/dist-kernel-5.15.148.ebuild deleted file mode 100644 index 6980dd4..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.148.ebuild +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 2021-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - ) -" diff --git a/virtual/dist-kernel/dist-kernel-5.15.151.ebuild b/virtual/dist-kernel/dist-kernel-5.15.151.ebuild deleted file mode 100644 index 6980dd4..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.151.ebuild +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 2021-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - ) -" diff --git a/virtual/dist-kernel/dist-kernel-5.15.158.ebuild b/virtual/dist-kernel/dist-kernel-5.15.158.ebuild deleted file mode 100644 index 6980dd4..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.158.ebuild +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 2021-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - ) -" diff --git a/virtual/dist-kernel/dist-kernel-5.15.160.ebuild b/virtual/dist-kernel/dist-kernel-5.15.160.ebuild deleted file mode 100644 index 6980dd4..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.160.ebuild +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 2021-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - ) -" diff --git a/virtual/dist-kernel/dist-kernel-5.15.161.ebuild b/virtual/dist-kernel/dist-kernel-5.15.161.ebuild deleted file mode 100644 index 6980dd4..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.161.ebuild +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 2021-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - ) -" diff --git a/virtual/dist-kernel/dist-kernel-5.15.163.ebuild b/virtual/dist-kernel/dist-kernel-5.15.163.ebuild deleted file mode 100644 index 6980dd4..0000000 --- a/virtual/dist-kernel/dist-kernel-5.15.163.ebuild +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 2021-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Virtual to depend on any Distribution Kernel" -SLOT="0/${PVR}" -KEYWORDS="amd64 ~arm arm64 ~hppa ~ppc ppc64 ~sparc x86" - -RDEPEND=" - || ( - ~sys-kernel/gentoo-kernel-${PV} - ~sys-kernel/gentoo-kernel-bin-${PV} - ~sys-kernel/vanilla-kernel-${PV} - ~sys-kernel/libre-kernel-${PV} - ) -" diff --git a/virtual/dist-kernel/dist-kernel-5.15.145.ebuild b/virtual/dist-kernel/dist-kernel-6.6.51.ebuild similarity index 100% rename from virtual/dist-kernel/dist-kernel-5.15.145.ebuild rename to virtual/dist-kernel/dist-kernel-6.6.51.ebuild