armbian-build/config/sources/cubox.conf
2018-02-27 16:12:50 +01:00

91 lines
2.4 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'
HAS_UUID_SUPPORT=yes
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)
# mainline u-boot
# BOOTSOURCE=$MAINLINE_UBOOT_SOURCE
# BOOTDIR=$MAINLINE_UBOOT_DIR
# BOOTBRANCH='tag:v2017.11'
# BOOTCONFIG="mx6cuboxi_defconfig"
# BOOTPATCHDIR='u-boot-cubox-next'
KERNELSOURCE=$MAINLINE_KERNEL_SOURCE
KERNELBRANCH='branch:linux-4.15.y'
KERNELDIR=$MAINLINE_KERNEL_DIR
KERNEL_USE_GCC='> 7.0'
;;
dev)
KERNELSOURCE='https://github.com/SolidRun/linux-fslc'
KERNELBRANCH='branch:solidrun-imx_4.9.x_1.0.0_ga'
KERNELDIR='linux-cubox-bsp'
KERNEL_USE_GCC='> 7.0'
;;
esac
CPUMIN=396000
CPUMAX=996000
GOVERNOR=interactive
SERIALCON=ttymxc0
if [[ "$BRANCH" == "next" ]]; 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
HAS_UUID_SUPPORT=yes
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
install -m 755 $SRC/packages/bsp/cubox/brcm4330-patch $destination/etc/init.d/brcm4330-patch
}