# Maintainer: Maximilian Luz pkgbase=linux-surface-lts pkgver=4.19.170 pkgrel=1 pkgdesc='LTS Linux' url="https://www.kernel.org/" arch=(x86_64) license=(GPL2) makedepends=( bc kmod libelf cpio perl tar xz python 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-gpe.patch 0009-surface-sam-over-hid.patch 0010-surface-sam.patch 0011-surface-hotplug.patch 0012-surface-typecover.patch ) validpgpkeys=( 'ABAF11C65A2970B130ABE3C479BE3E4300411886' # Linus Torvalds '647F28654894E3BD457199BE38DBBDC86092693E' # Greg Kroah-Hartman ) # https://www.kernel.org/pub/linux/kernel/v4.x/sha256sums.asc sha256sums=('dd0d0264f8ef4363d0080054fd344470a73f07aca2cd673e91bf6e77fbe25b4a' 'SKIP' '4e68572e7cc4c5368f0236e0792660ae8498373988625dca46e509399a7eaea6' 'a13581d3c6dc595206e4fe7fcf6b542e7a1bdbe96101f0f010fc5be49f99baf2' 'a019c4c93bb35d007ab47824f5f9aa542a4c9645563012c1a7dfb542d8adcc1b' '6ee27b4b4223f9fa0ee6c0539bab876819f6887963a784115f5cd4f6df45e5d0' 'c8591d271b2c54498b985c846e3683a9e2f64d14698a7a768e8047b19c001c86' '5898be0466295503ba1e993c34dd4e372c5b0900a31a9c61e77816c9e5ff67f4' '6a9abdf7a56b78df5484239750637c59ce1af8c7c94dc90e079980a9ab8e85df' '4fe0b851838d4423d8d5cb1aa3363e66d0a6579136be00eb3b776d3656ce6312' '7ff5e6e2ab1d1c1484729d2cceea8c70a83fc1f4faeda601ac460a5cd380ed66' 'fde268a68d87133bd7a54f809c595e5c3d07073dab72eb70128d33d9b1f0153e' 'ad7cacfa849b8221d10dc228e6793c4094e2940e828b78aac754162f4a91c28a' '2abf877d692b73b6866c87e6abd514c67f5181b39ee53dcb34429c2fdea5056b' 'fa48d02b774b48773d904d205b4a93a0c92c14a073a6c828e9f7a3969e13bc87' '6bd32d0c5896c4838ed79a3a8ce81e2290e0b6a1e39372f72079b912e97001c4' 'a61357f8028af537250478416d2f5b3c8ce007381c4379377930b8997bedce44') 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" "$(