# Maintainer: Minecrell # Kernel config based on: arch/arm64/configs/msm8916_defconfig _flavor="postmarketos-qcom-msm8916" pkgname=linux-$_flavor pkgver=5.11_rc3 pkgrel=0 pkgdesc="Mainline kernel fork for Qualcomm MSM8916 devices" arch="aarch64 armv7" url="https://github.com/msm8916-mainline/linux" license="GPL-2.0-only" options="!strip !check !tracedeps pmb:cross-native pmb:kconfigcheck-anbox" makedepends="bison findutils flex installkernel openssl-dev perl gmp-dev mpc1-dev mpfr-dev" # Architecture case "$CARCH" in aarch64) _carch="arm64" ;; arm*) _carch="arm" ;; esac # Source _tag=v${pkgver//_/-}-msm8916 source=" $pkgname-$_tag.tar.gz::$url/archive/$_tag.tar.gz config-$_flavor.aarch64 config-$_flavor.armv7 " builddir="$srcdir/linux-${_tag#v}" prepare() { default_prepare cp "$srcdir/config-$_flavor.$CARCH" .config } build() { unset LDFLAGS make ARCH="$_carch" CC="${CC:-gcc}" \ KBUILD_BUILD_VERSION=$((pkgrel + 1 )) } package() { mkdir -p "$pkgdir"/boot make zinstall modules_install dtbs_install \ ARCH="$_carch" \ INSTALL_PATH="$pkgdir"/boot \ INSTALL_MOD_PATH="$pkgdir" \ INSTALL_DTBS_PATH="$pkgdir"/usr/share/dtb rm -f "$pkgdir"/lib/modules/*/build "$pkgdir"/lib/modules/*/source install -D "$builddir"/include/config/kernel.release \ "$pkgdir"/usr/share/kernel/$_flavor/kernel.release } sha512sums="28e73646f3099db9c6681932ea10159747bd48a795b468423c5b92f7725bd3c76f24a6d11a1fbadb77a74a62a8bc740d13d810a028305bdd0f0d2844aa47913b linux-postmarketos-qcom-msm8916-v5.11-rc3-msm8916.tar.gz 5879bb06f4c3aa312d5a9df88c8c5565eca9369e3b0ba58a593a226002f3f9c9893643b116d56b2556243b73b837883ad82544df0e08071a87dee2332afae85b config-postmarketos-qcom-msm8916.aarch64 18db35659a7e5b3296feb0e46aa33ba3b96140afeac554d64a7a209460f786114f6369f79e0cad22becc9857521ba71d0cfade02baf85ace7762fe701bbc1a51 config-postmarketos-qcom-msm8916.armv7"