PKGBUILDs/alarm/uboot-dragonboard410c/PKGBUILD

72 lines
2.6 KiB
Bash
Raw Permalink Normal View History

2016-10-16 00:16:10 +00:00
# U-Boot: Dragonboard 410c
# Maintainer: Kevin Mihelich <kevin@archlinuxarm.org>
buildarch=8
pkgname=uboot-dragonboard410c
pkgver=2018.01
firmver=r1032.1.1
pkgrel=1
2016-10-16 00:16:10 +00:00
pkgdesc="U-Boot for Dragonboard 410c"
arch=('aarch64')
url='http://www.denx.de/wiki/U-Boot/WebHome'
2017-03-26 21:44:57 +00:00
license=('GPL' 'custom')
2016-10-16 00:16:10 +00:00
install=$pkgname.install
backup=('boot/boot.txt' 'boot/boot.scr')
makedepends=('bc' 'git' 'skales' 'dtc145')
replaces=('uboot-dragonboard')
2017-03-26 21:44:57 +00:00
options=('!strip')
2016-10-16 00:16:10 +00:00
source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver/rc/-rc}.tar.bz2"
"http://builds.96boards.org/releases/dragonboard410c/qualcomm/firmware/linux-board-support-package-${firmver}.zip"
'git+https://git.linaro.org/landing-teams/working/qualcomm/signlk.git'
2017-03-26 21:44:57 +00:00
'https://archlinuxarm.org/builder/src/dragonboard/gpt_both0.bin'
'https://archlinuxarm.org/builder/src/dragonboard/emmc_appsboot.mbn'
'0001-arch-linux-arm-modifications.patch'
'0002-mmc-sdhci-don-t-clear-SDHCI_INT_STATUS-register-duri.patch'
2016-10-16 00:16:10 +00:00
'boot.txt'
2017-03-26 21:44:57 +00:00
'mkscr'
'flashall')
md5sums=('b42e45813369f4ae84490a481e531768'
'9dd72a683385079e3012cf1a8a1912df'
'SKIP'
2017-03-26 21:44:57 +00:00
'5ffd612a1496e7a497480ff3d3b40776'
'9a0a5a3defcc4833cbd00fe24526939e'
'f9ae23c4939dd249a75747e54714ee81'
'0a757c79e81798fbef08cb05908d3572'
'62f2de6878125f6f3190dc2b23e400ec'
2017-03-26 21:44:57 +00:00
'021623a04afd29ac3f368977140cfbfd'
'8705acaec674dd15117ec329088a7819')
2017-03-26 21:44:57 +00:00
prepare() {
cd u-boot-${pkgver/rc/-rc}
git apply ../0001-arch-linux-arm-modifications.patch
git apply ../0002-mmc-sdhci-don-t-clear-SDHCI_INT_STATUS-register-duri.patch
2017-03-26 21:44:57 +00:00
}
2016-10-16 00:16:10 +00:00
build() {
cd u-boot-${pkgver/rc/-rc}
unset CFLAGS CXXFLAGS CPPFLAGS
make distclean
make dragonboard410c_config
2017-01-15 23:56:28 +00:00
echo 'CONFIG_IDENT_STRING=" Arch Linux ARM"' >> .config
2016-10-16 00:16:10 +00:00
make EXTRAVERSION=-${pkgrel}
}
package() {
install -Dpt "${pkgdir}/boot" linux-board-support-package-${firmver}/bootloaders-linux/{{hyp,rpm,tz,sbl1}.mbn,NON-HLOS.bin} gpt_both0.bin
install -D -m644 linux-board-support-package-${firmver}/LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.firmware"
signlk/signlk.sh -i=emmc_appsboot.mbn -o="${pkgdir}/boot/emmc_appsboot.mbn" -d
2016-10-16 00:16:10 +00:00
2017-03-26 21:44:57 +00:00
cd u-boot-${pkgver/rc/-rc}
2016-10-16 00:16:10 +00:00
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
2017-04-02 00:13:04 +00:00
cp ../{boot.txt,mkscr,flashall} "${pkgdir}"/boot
2016-10-16 00:16:10 +00:00
}