# Maintainer: Maximilian Luz pkgbase=linux-surface-lts pkgver=4.19.144 pkgrel=1 pkgdesc='LTS Linux' url="https://www.kernel.org/" arch=(x86_64) license=(GPL2) makedepends=( bc kmod libelf xmlto python-sphinx python-sphinx_rtd_theme graphviz imagemagick ) options=('!strip') _srcname=linux-$pkgver source=( https://www.kernel.org/pub/linux/kernel/v${pkgver%%.*}.x/${_srcname}.tar.{xz,sign} config # the main kernel config file 0001-ZEN-Add-sysctl-and-CONFIG-to-disallow-unprivileged-C.patch surface.config 0001-surface3-power.patch 0002-surface3-touchscreen-dma-fix.patch 0003-surface3-oemb.patch 0004-surface-buttons.patch 0005-suspend.patch 0006-ipts.patch 0007-wifi.patch 0008-surface-sam.patch 0009-surface-sam-over-hid.patch 0010-surface-gpe.patch ) validpgpkeys=( 'ABAF11C65A2970B130ABE3C479BE3E4300411886' # Linus Torvalds '647F28654894E3BD457199BE38DBBDC86092693E' # Greg Kroah-Hartman ) # https://www.kernel.org/pub/linux/kernel/v4.x/sha256sums.asc sha256sums=('33bd40c3484d97430190c63015c8479cdfaf552436c35f24a3c917df5631d24a' 'SKIP' '4e68572e7cc4c5368f0236e0792660ae8498373988625dca46e509399a7eaea6' 'a13581d3c6dc595206e4fe7fcf6b542e7a1bdbe96101f0f010fc5be49f99baf2' 'd0fc46eebfb42efdde0b1b1a67f057b56222595b640274b240f5e1cdf36d40c3' '1854aa50c52db18a22069a4fccdfe33326a0323a4aff31bc8f36f3cd1a4a2493' 'd1c0e26c4d6e8cca663e6fd0ff550b69809bdda49e1a9b69499c1544373e1ece' 'f69a3cabe5bc04242e08dd45cd57a1e56f05446f2ed454bea196ca1c86173dab' '031d7e07ccb2cf359afc1bd014c1e12b65a74c57729403b53ce66eb0c6cfb0bd' '011dcc0cd12c4448610b3a2891f07cc06bd790c2e85b8fc22810512a4de08c1f' 'a340db858154cab193d2e4fcb2ab3681c3072bfd3d7e44b7c072ef85f77f808e' '04a13708bdf6f1c42cd3c1bf6aa5f6f1852eee3faf7672992458ebf3943d186b' '3a9627e69fab2027a09cd1d48f080d9973a60d25c49c2693f2d3a752051989c5' '52e5dc499a634442279164deda93cd3ccae7ce4f963c532187cf1da132ac5fcb' 'a797d8ca4840c39d4494d7a3b555d6374a332ed7d91a8411fe56d6a43118160d') export KBUILD_BUILD_HOST=archlinux export KBUILD_BUILD_USER=$pkgbase export KBUILD_BUILD_TIMESTAMP="$(date -Ru${SOURCE_DATE_EPOCH:+d @$SOURCE_DATE_EPOCH})" # optional certificate and key for secure boot signing _mok_crt="$PWD/MOK.crt" _mok_key="$PWD/MOK.key" prepare() { cd $_srcname msg2 "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 msg2 "Applying patch $src..." patch -Np1 < "../$src" done msg2 "Setting config..." # cp ../config .config # merge the two configs together ./scripts/kconfig/merge_config.sh -m ../config ../surface.config make olddefconfig make -s kernelrelease > version msg2 "Prepared %s version %s" "$pkgbase" "$(