Files
pmaports-rtwo/device/testing/linux-postmarketos-qcom-msm8994/APKBUILD
T
Aster Boese f3eb5b5e4e linux-postmarketos-qcom-msm8994: build with LLVM
Building with LLVM is a requirement for every category higher than downstream,
so this kernel must be built with LLVM. This is part of a larger distro-wide
effort to build with LLVM.

- Builds with LLVM
- Fixes style errors
- Updates kconfig

Signed-off-by: Aster Boese <asterboese@mailbox.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/9039>
2026-07-17 21:45:22 +00:00

75 lines
1.9 KiB
Bash

# Kernel config based on: arch/arm64/configs/defconfig
maintainer="Petr Vorel <petr.vorel@gmail.com>"
_flavor="postmarketos-qcom-msm8994"
pkgname=linux-$_flavor
pkgver=6.16
pkgrel=1
pkgdesc="Mainline kernel for Qualcomm MSM8994/MSM8992 devices"
arch="aarch64"
_carch="arm64"
url="https://kernel.org"
license="GPL-2.0-only"
options="
!check
!strip
!tracedeps
pmb:cross-native
pmb:kconfigcheck-nftables
pmb:kconfigcheck-zram
"
makedepends="
bison
clang
elfutils-dev
findutils
flex
linux-headers
lld
llvm
openssl-dev
pahole
perl
postmarketos-installkernel
python3
"
_tag=${pkgver//_/-}
source="
https://git.kernel.org/torvalds/t/linux-$_tag.tar.gz
config-$_flavor.$arch
0001-arm64-dts-qcom-msm8994-huawei-angler-Add-regulators.patch
"
builddir="$srcdir/linux-${_tag#v}"
prepare() {
default_prepare
cp "$srcdir/config-$_flavor.$arch" .config
}
build() {
unset LDFLAGS
make ARCH="$_carch" LLVM=1 HOSTLDFLAGS="-fuse-ld=lld" \
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-$_flavor"
}
package() {
mkdir -p "$pkgdir"/boot
make dtbs_install modules_install zinstall \
ARCH="$_carch" \
LLVM=1 \
INSTALL_PATH="$pkgdir"/boot \
INSTALL_MOD_PATH="$pkgdir"/usr \
INSTALL_MOD_STRIP=1 \
INSTALL_DTBS_PATH="$pkgdir"/boot/dtbs
rm -f "$pkgdir"/usr/lib/modules/*/build "$pkgdir"/usr/lib/modules/*/source
install -D "$builddir"/include/config/kernel.release \
"$pkgdir"/usr/share/kernel/"$_flavor"/kernel.release
}
sha512sums="
9b6ff9b707d9e9b3d1a20ad1b65efd029911856a6f7890af4755b702c67ccb85c3ce4c4efe739fd3435e45d8f5bdd7ae7c0131c35fbf1c409034134dfedad1bd linux-6.16.tar.gz
626c314589cb8d4fc9852457e404db715b231c903f75ee9d4acce4ece31351afb4b2434f05a34f6d808ffa0c33feab9a20b88ce9a60a37726a93f80c5a460bf2 config-postmarketos-qcom-msm8994.aarch64
c2561ffe00687a1fc2ea4a1dec8e132c9c47f522a587cb9d7511a0de9378abe8a5a08428a21822cff8d103c5e61c116182d5adb52e334d69bfc425579bb52f32 0001-arm64-dts-qcom-msm8994-huawei-angler-Add-regulators.patch
"