pmaports/device/testing/linux-postmarketos-qcom-sdm670/APKBUILD
Richard Acayan 83213f3ebc
linux-postmarketos-qcom-sdm670: upgrade to 6.5.4 (MR 4412)
Now that the modem firmware is installed in the referenced location, the
firmware patch is not needed, so remove that as well.

Also backport a fix for the Pixel 3a XL so a kernel upgrade isn't needed
for that.
2023-09-30 14:44:29 +02:00

62 lines
2 KiB
Text

# Maintainer: Richard Acayan <mailingradian@gmail.com>
# Stable Linux kernel with patches for SDM670 devices
# Kernel config based on: arch/arm64/configs/{defconfig,sdm{670,845}.config}
_flavor="postmarketos-qcom-sdm670"
pkgname=linux-$_flavor
pkgver=6.5.4
pkgrel=0
pkgdesc="Mainline Kernel fork for SDM670 devices"
arch="aarch64"
_carch="arm64"
url="https://gitlab.com/sdm670-mainline/linux"
license="GPL-2.0-only"
options="!strip !check !tracedeps
pmb:cross-native"
makedepends="bash bison findutils flex installkernel openssl-dev perl zstd"
_config="config-$_flavor.$arch"
_tag="sdm670-v$pkgver"
# Source
source="
https://gitlab.com/sdm670-mainline/linux/-/archive/$_tag/linux-$_tag.tar.gz
$_config
0001-drm-panel-samsung-sofef00-bonito-add-enable-function.patch
"
builddir="$srcdir/linux-$_tag"
prepare() {
default_prepare
cp "$srcdir/config-$_flavor.$arch" .config
}
build() {
unset LDFLAGS
make ARCH="$_carch" CC="${CC:-gcc}" \
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-$_flavor"
}
package() {
mkdir -p "$pkgdir"/boot
install -Dm644 "$builddir/arch/$_carch/boot/Image.gz" \
"$pkgdir/boot/vmlinuz"
make modules_install dtbs_install \
ARCH="$_carch" \
INSTALL_PATH="$pkgdir"/boot/ \
INSTALL_MOD_PATH="$pkgdir" \
INSTALL_MOD_STRIP=1 \
INSTALL_DTBS_PATH="$pkgdir"/boot/dtbs
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="
8bf50096ba05b963fe89f14efe9dc5f3e371bcc4b3a98e17e84e00fcddcc912e7f1f9247472b23c170b3d5a26041d9969f611d370450534849eafe2357d3c02a linux-sdm670-v6.5.4.tar.gz
e7553a637249cb2015a9db027817d60622bdfc98e46b13d49a8bee547d7cf2525442e529cf8d6f588735645497aa1d2ae80d88a6c6cd49c4d39fbc5abcb9227d config-postmarketos-qcom-sdm670.aarch64
170ccb5ba925e635d88d5a033620bd1c68fdb18b3781e42cd4d5304279d61952f2dbc88212a601507890d227c09b5b6293ae0089fa66b8652047cfedd709d27f 0001-drm-panel-samsung-sofef00-bonito-add-enable-function.patch
"