FDS/OS 1.0
This commit is contained in:
@@ -0,0 +1,63 @@
|
||||
# Based on rpi5-kernel at the pinned Void commit; upstream stays unchanged.
|
||||
pkgname=fds-kernel
|
||||
version=6.12.87
|
||||
revision=1
|
||||
_githash=ae4d75fb36deba0fe1a986d9bfae65755e082dd0
|
||||
archs="aarch64"
|
||||
wrksrc="linux-${_githash}"
|
||||
hostmakedepends="perl kmod openssl-devel bc bison flex xz python3 cpio"
|
||||
short_desc="FDS Raspberry Pi 5 kernel with built-in boot drivers"
|
||||
maintainer="FDS/OS maintainers"
|
||||
license="GPL-2.0-only"
|
||||
homepage="https://github.com/raspberrypi/linux"
|
||||
distfiles="https://github.com/raspberrypi/linux/archive/${_githash}.tar.gz"
|
||||
checksum=432afe0cbb9370fc9329f67d44bdc892b8e2417a60dd33de8f0cd22e9c697c62
|
||||
python_version=3
|
||||
nodebug=yes
|
||||
nostrip=yes
|
||||
noverifyrdeps=yes
|
||||
noshlibprovides=yes
|
||||
|
||||
export KBUILD_BUILD_TIMESTAMP="Thu Jan 1 00:00:00 UTC 1970"
|
||||
export KBUILD_BUILD_USER=fds
|
||||
export KBUILD_BUILD_HOST=fds-builder
|
||||
_cross="CROSS_COMPILE=aarch64-linux-gnu-"
|
||||
|
||||
do_configure() {
|
||||
make ARCH=arm64 ${_cross} bcm2712_defconfig
|
||||
scripts/kconfig/merge_config.sh -m .config "${FILESDIR}/fds.config"
|
||||
make ARCH=arm64 ${_cross} olddefconfig
|
||||
# Kconfig can silently drop impossible requests. Verify every delta entry.
|
||||
while IFS= read -r setting; do
|
||||
case "$setting" in
|
||||
CONFIG_*=*) grep -Fqx "$setting" .config || return 1 ;;
|
||||
'# CONFIG_'*' is not set')
|
||||
local symbol="${setting#\# }"
|
||||
symbol="${symbol% is not set}"
|
||||
! grep -Eq "^${symbol}=[ym]$" .config || return 1 ;;
|
||||
esac
|
||||
done <"${FILESDIR}/fds.config"
|
||||
}
|
||||
|
||||
do_build() {
|
||||
export LDFLAGS=
|
||||
make ARCH=arm64 ${_cross} ${makejobs} Image modules dtbs
|
||||
}
|
||||
|
||||
do_install() {
|
||||
local release
|
||||
release=$(make -s ARCH=arm64 ${_cross} kernelrelease)
|
||||
vinstall arch/arm64/boot/Image 644 boot kernel_2712.img
|
||||
vinstall .config 644 boot config-fds
|
||||
vinstall System.map 644 boot System.map-fds
|
||||
vmkdir boot/overlays
|
||||
vcopy "arch/arm64/boot/dts/broadcom/bcm2712-*.dtb" boot
|
||||
vcopy "arch/arm64/boot/dts/overlays/*.dtbo" boot/overlays
|
||||
vinstall arch/arm64/boot/dts/overlays/README 644 boot/overlays
|
||||
make ARCH=arm64 ${_cross} ${makejobs} INSTALL_MOD_PATH="${DESTDIR}/usr" \
|
||||
INSTALL_MOD_STRIP=1 DEPMOD=true modules_install
|
||||
rm -f "${DESTDIR}/usr/lib/modules/${release}/build" "${DESTDIR}/usr/lib/modules/${release}/source"
|
||||
depmod -b "${DESTDIR}/usr" "$release"
|
||||
vmkdir usr/share/fds
|
||||
printf '%s\n' "$release" >"${DESTDIR}/usr/share/fds/kernel-release"
|
||||
}
|
||||
Reference in New Issue
Block a user