pmaports/device/testing/linux-postmarketos-qcom-sm8250/APKBUILD

66 lines
1.7 KiB
Text

# Reference: <https://postmarketos.org/vendorkernel>
# Kernel config based on: arch/arm64/configs/defconfig
_flavor="postmarketos-qcom-sm8250"
pkgname=linux-$_flavor
pkgver=6.8.0
pkgrel=0
pkgdesc="Mainline kernel fork for SM8250"
arch="aarch64"
_carch="arm64"
url="https://gitlab.com/sm8250-mainline/linux"
license="GPL-2.0-only"
options="!strip !check !tracedeps
pmb:cross-native
pmb:kconfigcheck-nftables
pmb:kconfigcheck-community
"
makedepends="
bash
bison
findutils
flex
installkernel
openssl-dev
perl
"
# Source
_tag="sm8250-$pkgver"
_config="config-$_flavor.$arch"
source="
$pkgname-$_tag.tar.gz::https://gitlab.com/sm8250-mainline/linux/-/archive/$_tag/linux-$_tag.tar.gz
$_config
"
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
make zinstall 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="
2501de7c4f2911a5045020db694478fe79045b9ce609ba44c32ce34dc95722c83b9c48f2d771d693e39244b07f7286b4ec035f89fadf3e33f3a933c6c2e38eb9 linux-postmarketos-qcom-sm8250-sm8250-6.8.0.tar.gz
d7ec94bf9a20cd5ebfb437844d1e298efbcc29846c0649ab9f7f4cb76e2ae33aa949bce7e739da9a3748663a2e288d74ae5220f28a87134af3643496178b3165 config-postmarketos-qcom-sm8250.aarch64
"