# Maintainer: Jonathan Wright # Contributor: Boohbah # Contributor: Jan Alexander Steffens (heftig) pkgbase=linux-zen-515lts pkgver=5.15.74.r0.ga3f2f5ac9d61 pkgrel=1 pkgdesc='Linux (Git)' url="https://www.kernel.org" arch=(x86_64) license=(GPL2) makedepends=( bc kmod libelf git pahole ) options=('!strip') _srcname=linux source=( 'git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git' config ) sha256sums=('SKIP' 'SKIP') export KBUILD_BUILD_HOST=archlinux export KBUILD_BUILD_USER=$pkgbase export KBUILD_BUILD_TIMESTAMP="$(date -Ru${SOURCE_DATE_EPOCH:+d @$SOURCE_DATE_EPOCH})" pkgver() { cd $_srcname git describe --long | sed -E 's/^v//;s/([^-]*-g)/r\1/;s/-/./g;s/\.rc/rc/' } prepare() { cd $_srcname git reset --hard git checkout v5.15.74 for i in ../../*patch; do echo $i patch -p1 -i $i; done echo "Setting version..." scripts/setlocalversion --save-scmversion echo "-$pkgrel" > localversion.10-pkgrel echo "${pkgbase#linux}" > localversion.20-pkgname local src for src in "${source[@]}"; do src="${src%%::*}" src="${src##*/}" [[ $src = *.patch ]] || continue echo "Applying patch $src..." patch -Np1 < "../$src" done echo "Setting config..." cp ../config .config make olddefconfig make -s kernelrelease > version echo "Prepared $pkgbase version $(