mirror of
https://github.com/void-linux/void-packages.git
synced 2025-07-29 00:42:58 +02:00
odroid-c2-uboot: can only be built from x86_64.
This commit is contained in:
parent
39b9818f2e
commit
62cfad21df
1 changed files with 19 additions and 8 deletions
|
@ -6,6 +6,7 @@ _githash=f416a769454b89c39d5b217d28bd3c9f5d1594df
|
||||||
wrksrc="u-boot-${_githash}"
|
wrksrc="u-boot-${_githash}"
|
||||||
only_for_archs="aarch64 aarch64-musl"
|
only_for_archs="aarch64 aarch64-musl"
|
||||||
conf_files="/boot/boot.ini"
|
conf_files="/boot/boot.ini"
|
||||||
|
hostmakedepends="bc"
|
||||||
short_desc="Odroid C2 U-Boot files for SD booting"
|
short_desc="Odroid C2 U-Boot files for SD booting"
|
||||||
maintainer="Christian Neukirchen <chneukirchen@gmail.com>"
|
maintainer="Christian Neukirchen <chneukirchen@gmail.com>"
|
||||||
license="GPL-2"
|
license="GPL-2"
|
||||||
|
@ -13,23 +14,33 @@ homepage="https://github.com/hardkernel/u-boot"
|
||||||
distfiles="https://github.com/hardkernel/u-boot/archive/${_githash}.tar.gz"
|
distfiles="https://github.com/hardkernel/u-boot/archive/${_githash}.tar.gz"
|
||||||
checksum=da7ca9e6abdfedaa65ac4e0bd378155002bf5d0ccea663ddf03fa839dceb3724
|
checksum=da7ca9e6abdfedaa65ac4e0bd378155002bf5d0ccea663ddf03fa839dceb3724
|
||||||
|
|
||||||
|
case "$XBPS_MACHINE" in
|
||||||
|
x86_64) ;;
|
||||||
|
*) msg_error "Can only be built from x86_64: https://github.com/hardkernel/u-boot/issues/23\n" ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
make_build_args="ARCH=arm"
|
||||||
|
if [ "$CROSS_BUILD" ]; then
|
||||||
|
make_build_args+=" CROSS_COMPILE=${XBPS_CROSS_TRIPLET}-"
|
||||||
|
else
|
||||||
|
make_build_args+=" HOSTARCH=arm"
|
||||||
|
fi
|
||||||
|
|
||||||
post_extract() {
|
post_extract() {
|
||||||
touch include/stddef.h # musl hack
|
touch include/stddef.h # musl hack
|
||||||
|
sed -i '1itypedef unsigned long ulong;' \
|
||||||
|
include/image.h tools/mkimage.h tools/proftool.c
|
||||||
}
|
}
|
||||||
do_configure() {
|
do_configure() {
|
||||||
unset CFLAGS CXXFLAGS LDFLAGS
|
unset CFLAGS CXXFLAGS LDFLAGS
|
||||||
|
|
||||||
make distclean CROSS_COMPILE=${XBPS_CROSS_TRIPLET}-
|
make ${make_build_args} distclean
|
||||||
make odroidc2_config CROSS_COMPILE=${XBPS_CROSS_TRIPLET}-
|
make ${make_build_args} odroidc2_config
|
||||||
}
|
}
|
||||||
do_build() {
|
do_build() {
|
||||||
unset CFLAGS CXXFLAGS LDFLAGS
|
unset CFLAGS CXXFLAGS LDFLAGS
|
||||||
|
|
||||||
if [ "$CROSS_BUILD" ]; then
|
make ${makejobs} ${make_build_args}
|
||||||
make ARCH=arm CROSS_COMPILE=${XBPS_CROSS_TRIPLET}-
|
|
||||||
else
|
|
||||||
make ARCH=arm
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
do_install() {
|
do_install() {
|
||||||
vmkdir boot
|
vmkdir boot
|
||||||
|
|
Loading…
Add table
Reference in a new issue