76 lines
2.1 KiB
Bash
76 lines
2.1 KiB
Bash
# Maintainer: Caleb Connolly <caleb@postmarketos.org>
|
|
# Kernel config based on: arch/arm64/configs/defconfig
|
|
|
|
pkgname=linux-next
|
|
pkgver=6.12_git20241001
|
|
pkgrel=2
|
|
_nextver="${pkgver#*_git}"
|
|
pkgdesc="Linux next kernel"
|
|
arch="aarch64"
|
|
_carch="arm64"
|
|
_flavor="generic-trailblazer"
|
|
url="https://kernel.org"
|
|
license="GPL-2.0-only"
|
|
# FIXME: kconfigcheck isn't supported since we use fragments
|
|
options="!strip !check !tracedeps pmb:cross-native"
|
|
source="
|
|
https://gitlab.com/linux-kernel/linux-next/-/archive/next-$_nextver/linux-next-next-$_nextver.tar.gz
|
|
devices.config
|
|
pmos.config
|
|
"
|
|
makedepends="
|
|
bash
|
|
bc
|
|
bison
|
|
devicepkg-dev
|
|
findutils
|
|
flex
|
|
git
|
|
openssl-dev
|
|
perl
|
|
python3
|
|
zstd
|
|
"
|
|
builddir="$srcdir/linux-next-next-$_nextver"
|
|
|
|
prepare() {
|
|
default_prepare
|
|
cp "$srcdir/pmos.config" "$builddir"/arch/"$_carch"/configs/
|
|
cp "$srcdir/devices.config" "$builddir"/arch/"$_carch"/configs/
|
|
|
|
# Generate .config
|
|
unset LDFLAGS
|
|
make ARCH="$_carch" CC="${CC:-gcc}" \
|
|
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-next-$_nextver" \
|
|
defconfig pmos.config devices.config
|
|
}
|
|
|
|
build() {
|
|
unset LDFLAGS
|
|
make O="$_outdir" ARCH="$_carch" CC="${CC:-gcc}" \
|
|
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
|
|
}
|
|
|
|
package() {
|
|
install -Dm644 "$builddir/arch/$_carch/boot/vmlinuz.efi" \
|
|
"$pkgdir/boot/linux.efi"
|
|
|
|
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/next-"$_nextver"/kernel.release
|
|
}
|
|
|
|
sha512sums="
|
|
127c9be0262ba82bfd39977085a70bf0f16d523bde1823dda151a78e9b262b4b33efe5543f27d3f745a4ee4ecf911b57a01adac3970ad306a05582cb61119aef linux-next-next-20241001.tar.gz
|
|
adbb506c0a2d676b1964a5d7c693f72338541ebd0cacee62e4579d43163c468d95607d73bf7439fb55b4d6bfa0dd42578b07ee20965aa03c2a9d8022cb3ae267 devices.config
|
|
a30df186f06519e2f519bfe622bbd46caec6c2473a1fd3df370320a661d53882b49cfb2b3be7edd92fabdb4a8e6e3419194e8d43cca3cf4ab1615275dab4fee4 pmos.config
|
|
"
|