armbian-build/config/sources/cubox.conf

91 lines
2.3 KiB
Plaintext

BOOTSOURCE='https://github.com/SolidRun/u-boot-imx6'
BOOTBRANCH='branch:imx6-next'
BOOTDIR='u-boot-cubox'
BOOTSCRIPT='boot-cubox.cmd:boot.cmd'
BOOTENV_FILE='cubox-default.txt'
UBOOT_TARGET_MAP=';;SPL u-boot.img'
UBOOT_USE_GCC='< 5.0'
case $BRANCH in
default)
KERNELSOURCE='https://github.com/linux4kix/linux-linaro-stable-mx6'
KERNELBRANCH='branch:linux-linaro-lsk-v3.14-mx6'
KERNELDIR='linux-cubox'
KERNEL_USE_GCC='< 5.0'
;;
next)
KERNELSOURCE=$MAINLINE_KERNEL_SOURCE
KERNELBRANCH='branch:linux-4.14.y'
KERNELDIR=$MAINLINE_KERNEL_DIR
KERNEL_USE_GCC='> 7.0'
;;
dev)
# mainline u-boot
#BOOTSOURCE=$MAINLINE_UBOOT_SOURCE
#BOOTDIR=$MAINLINE_UBOOT_DIR
#BOOTBRANCH='tag:v2018.03'
#BOOTCONFIG="mx6cuboxi_defconfig"
#BOOTPATCHDIR='u-boot-cubox-next'
#UBOOT_USE_GCC='> 7.0'
KERNELSOURCE=$MAINLINE_KERNEL_SOURCE
KERNELBRANCH='branch:linux-4.18.y'
KERNELDIR=$MAINLINE_KERNEL_DIR
KERNEL_USE_GCC='> 7.0'
;;
esac
CPUMIN=396000
CPUMAX=996000
GOVERNOR=interactive
SERIALCON=ttymxc0
if [[ "$BRANCH" == "dev" ]]; then
write_uboot_platform()
{
dd if=$1/SPL of=$2 bs=1K seek=1 status=noxfer > /dev/null 2>&1
dd if=$1/u-boot.img of=$2 bs=1K seek=69 status=noxfer > /dev/null 2>&1
}
else
write_uboot_platform()
{
dd if=$1/SPL of=$2 bs=512 seek=2 status=noxfer > /dev/null 2>&1
dd if=$1/u-boot.img of=$2 bs=1K seek=42 status=noxfer > /dev/null 2>&1
}
fi
if [[ $BOARD == wandboard-quad ]]; then
UBOOT_USE_GCC='> 6.3'
KERNEL_USE_GCC='> 6.3'
CPUMAX=1008000
GOVERNOR=ondemand
BOOTSOURCE=$MAINLINE_UBOOT_SOURCE
BOOTDIR=$MAINLINE_UBOOT_DIR
BOOTBRANCH="branch:v2017.03"
write_uboot_platform()
{
dd if=$1/SPL of=$2 bs=512 seek=2 status=noxfer > /dev/null 2>&1
dd if=$1/u-boot.img of=$2 seek=69 bs=1k status=noxfer > /dev/null 2>&1
}
fi
family_tweaks()
{
# TODO: Fix the workaround in firstrun?
#chroot $SDCARD /bin/bash -c "LC_ALL=C LANG=C update-rc.d brcm4330-patch defaults > /dev/null"
echo ""
}
family_tweaks_bsp()
{
install -m 644 $SRC/packages/bsp/cubox/99-hdmi_fb0.conf $destination/etc/X11/xorg.conf.d/99-hdmi_fb0.conf
install -m 755 $SRC/packages/bsp/cubox/brcm_patchram_plus $destination/usr/bin/brcm_patchram_plus
cp $SRC/packages/bsp/cubox/brcm4330 $destination/etc/default/
# TODO: replace by a systemd service
mkdir $destination/etc/init.d/
install -m 755 $SRC/packages/bsp/cubox/brcm4330-patch $destination/etc/init.d/brcm4330-patch
}