mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-12-08 23:03:46 +00:00
66 lines
2.2 KiB
Bash
66 lines
2.2 KiB
Bash
# U-Boot: Dragonboard 410c
|
|
# Maintainer: Kevin Mihelich <kevin@archlinuxarm.org>
|
|
|
|
buildarch=8
|
|
|
|
pkgname=uboot-dragonboard
|
|
pkgver=2017.03
|
|
firmver=1.4.0
|
|
pkgrel=2
|
|
pkgdesc="U-Boot for Dragonboard 410c"
|
|
arch=('aarch64')
|
|
url='http://www.denx.de/wiki/U-Boot/WebHome'
|
|
license=('GPL' 'custom')
|
|
install=$pkgname.install
|
|
backup=('boot/boot.txt' 'boot/boot.scr')
|
|
makedepends=('bc' 'dtc' 'git' 'skales')
|
|
options=('!strip')
|
|
source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver/rc/-rc}.tar.bz2"
|
|
"https://developer.qualcomm.com/download/db410c/firmware-410c-${firmver}.bin"
|
|
'https://archlinuxarm.org/builder/src/dragonboard/gpt_both0.bin'
|
|
'https://archlinuxarm.org/builder/src/dragonboard/emmc_appsboot.mbn'
|
|
'0001-arch-linux-arm-modifications.patch'
|
|
'boot.txt'
|
|
'mkscr'
|
|
'flashall')
|
|
md5sums=('52fed6ce16e0c4a50e2cd4defdf9097a'
|
|
'be80a375473a9308d8b4b47c4d8ff811'
|
|
'5ffd612a1496e7a497480ff3d3b40776'
|
|
'9a0a5a3defcc4833cbd00fe24526939e'
|
|
'2b5efb7db1444d7f10f19819383db6d1'
|
|
'2bea1d7a70a5f3043b549d860499866c'
|
|
'021623a04afd29ac3f368977140cfbfd'
|
|
'c38dbecb437f8309a29bc04a2296284f')
|
|
|
|
prepare() {
|
|
sh firmware-410c-${firmver}.bin --auto-accept
|
|
|
|
cd u-boot-${pkgver/rc/-rc}
|
|
git apply ../0001-arch-linux-arm-modifications.patch
|
|
}
|
|
|
|
build() {
|
|
cd u-boot-${pkgver/rc/-rc}
|
|
|
|
unset CFLAGS CXXFLAGS CPPFLAGS
|
|
|
|
make distclean
|
|
make dragonboard410c_config
|
|
echo 'CONFIG_IDENT_STRING=" Arch Linux ARM"' >> .config
|
|
make EXTRAVERSION=-${pkgrel}
|
|
}
|
|
|
|
package() {
|
|
install -Dpt "${pkgdir}/boot" linux-board-support-package-v${firmver%.0}/bootloaders-linux/{{hyp,rpm,tz-psci,sbl1}.mbn,NON-HLOS.bin} gpt_both0.bin emmc_appsboot.mbn
|
|
install -D -m644 linux-board-support-package-v${firmver%.0}/LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.firmware"
|
|
|
|
cd u-boot-${pkgver/rc/-rc}
|
|
|
|
touch rd
|
|
dtbTool -o dt.img arch/arm/dts
|
|
mkbootimg --kernel=u-boot-dtb.bin --output=u-boot.img --dt=dt.img --pagesize 2048 --base 0x80000000 --ramdisk=rd --cmdline=""
|
|
cp u-boot.img ${pkgdir}/boot
|
|
|
|
tools/mkimage -A arm -O linux -T script -C none -n "U-Boot boot script" -d ../boot.txt "${pkgdir}"/boot/boot.scr
|
|
cp ../{boot.txt,mkscr,flashall} "${pkgdir}"/boot
|
|
}
|