# Maintainer: Maximilian Luz # Maintainer: Blaž Hrastnik # Maintainer: Jan Alexander Steffens (heftig) pkgbase=linux-surface pkgver=6.4.4.arch1 pkgrel=1 pkgdesc='Linux' _shortver=${pkgver%.*} _fullver=${pkgver%.*}-${pkgver##*.} _srctag=v${_fullver} url="https://github.com/archlinux/linux/commits/$_srctag" arch=(x86_64) license=(GPL2) makedepends=( bc cpio gettext git libelf perl tar xz python # we don't need `pahole` as deps because we disable `CONFIG_DEBUG_INFO` # ignoring deps for docs because we don't build docs package ) optdepends=('iptsd: Touchscreen support' 'linux-firmware: Firmware files for Linux' 'linux-firmware-marvell: Firmware files for Marvell WiFi / Bluetooth') options=('!strip') _srcname=archlinux-linux source=( "$_srcname::git+https://github.com/archlinux/linux#tag=$_srctag" config # the main kernel config file surface.config # surface specific options arch.config # config changes for linux-surface kernel 0001-surface3-oemb.patch 0002-mwifiex.patch 0003-ath10k.patch 0004-ipts.patch 0005-ithc.patch 0006-surface-sam-over-hid.patch 0007-surface-button.patch 0008-surface-typecover.patch 0009-surface-shutdown.patch 0010-surface-gpe.patch 0011-cameras.patch 0012-amd-gpio.patch 0013-rtc.patch ) validpgpkeys=( 'ABAF11C65A2970B130ABE3C479BE3E4300411886' # Linus Torvalds '647F28654894E3BD457199BE38DBBDC86092693E' # Greg Kroah-Hartman 'A2FF3A36AAA56654109064AB19802F8B0D70FC30' # Jan Alexander Steffens (heftig) ) sha256sums=('SKIP' 'e8d4bbd63808eeec78680c7de4383333b76ab9d58214042bd4b01d784bbc8ec8' 'c2a412b0203b31bb3c6b64d3c00d7669d3e58c723f542ecdda940016599d342a' '3cabe391cc39dbee88a79f76e9e7a68f7fbcd5518941aa2ab73a77692c87dead' '8a21c474b0c2174e63ab9ef31592b9efb77c82e3783f2f5719a9aed1c6b01738' '580102aba7cd217360bee5106efe21f2d7424ea90810f46c49df40ebbbae4aa0' '36f433951255c38fc6176544292b9ec43a9653c7ee5648909f381032ecf50d4d' '498ca57d183c9463d38d4319bd6718f7ef241fa885d79ff4106be91b3156cfc1' '864bf6e239cd68892004a72d8efc4c089ec61663e1181f201b67a3ecaf764fe2' '03de2bd35f0c6f60584835dde31b19ade096ba18dbe1fafeb046a65b3410313d' '9a1101d647f63006bd84c56ea7b9e6e0e90d605b4b19c5ce5cb69b99e29f9ea7' 'effdcc3f2ca60b848a0355150bc638d788e7c2744fc1754567ec9fcf0e10988f' '563817eb9f41274946f99b25f48c39bd0ed63be1376c94c8011b4efc24d0f9e7' 'e2121a3aa63eaceb957d13eab3ea6cffabeeb66699331055c61bf06c47b432fa' 'ed6fcd3a9d631de1812c43e7cc8fdb97218485fe265d6fdebe34c3b00f5ad9cd' '661856db45150e01f18baf3aa6e69eb5416f8f2706bc6d07b5eda878bd264916' '0f8ef51384ab951b81a775cf023a1aac7899df1fb498c29e3b5883edfa99994b') 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" _make() { test -s version make KERNELRELEASE="$( localversion.10-pkgrel echo "${pkgbase#linux}" > localversion.20-pkgname make defconfig make -s kernelrelease > version make mrproper # setup git git config --local user.email "surfacebot@users.noreply.github.com" git config --local user.name "surfacebot" local src for src in "${source[@]}"; do src="${src%%::*}" src="${src##*/}" [[ $src = *.patch ]] || continue echo "Applying patch $src..." git am -3 "../$src" done echo "Setting config..." # cp ../config .config # merge the two configs together ./scripts/kconfig/merge_config.sh -m ../config ../surface.config ../arch.config _make olddefconfig echo "Prepared $pkgbase version $(