void-packages/srcpkgs/cubieboard2-uboot/template

39 lines
1,015 B
Text
Raw Normal View History

# Template file for 'cubieboard2-uboot'
pkgname=cubieboard2-uboot
version=v2013.10
revision=1
wrksrc="u-boot-sunxi-${version/v/}-sunxi"
hostmakedepends="sunxi-tools"
short_desc="Cubieboard2 U-Boot files for SD booting"
maintainer="Juan RP <xtraeme@gmail.com>"
license="GPL-2"
homepage="https://github.com/linux-sunxi/u-boot-sunxi"
distfiles="https://github.com/linux-sunxi/u-boot-sunxi/archive/${version}-sunxi.tar.gz"
checksum=a2a606939574795598d29f04852b1a40ddfcced96e9535d1d31fad30c68e0326
create_srcdir=yes
onlu_for_archs="armv7l"
do_build() {
unset CFLAGS CXXFLAGS LDFLAGS
for i in Cubieboard2; do
mkdir bin_${i}
make distclean
if [ "$CROSS_BUILD" ]; then
make CROSS_COMPILE=${XBPS_CROSS_TRIPLET}- ${i}
else
make ${i}
fi
mv u-boot.bin spl/sunxi-spl.bin bin_${i}
done
}
do_install() {
vmkdir boot
cp bin_Cubieboard2/{u-boot.bin,sunxi-spl.bin} ${DESTDIR}/boot
fex2bin ${FILESDIR}/cubieboard2.fex ${DESTDIR}/boot/script.bin
vinstall ${FILESDIR}/cubieboard2.env 644 boot uEnv.txt
}