diff options
-rw-r--r-- | PKGBUILD | 54 | ||||
-rw-r--r-- | uboot-pinebook.install | 24 |
2 files changed, 30 insertions, 48 deletions
@@ -1,45 +1,51 @@ -# U-Boot: Pinebook, based on Pine64 PKGBUILD -# Maintainer: Dan Johansen <strit@manjaro.org> +# Maintainer: Jaron Kent-Dobias <jaron@kent-dobias.com> +# Contributor: Dan Johansen <strit@manjaro.org> # Contributor: Kevin Mihelich <kevin@archlinuxarm.org> +_tfaver=2.4 +_crustver=0.3 + pkgname=uboot-pinebook -pkgver=2020.10 -pkgrel=1 -_tfaver=2.3 +pkgver=2021.01 +pkgrel=3 pkgdesc="U-Boot for Pinebook" -arch=('aarch64') +arch=(aarch64) url='http://www.denx.de/wiki/U-Boot/WebHome' license=('GPL') -makedepends=('bc' 'git' 'python' 'swig' 'dtc') +makedepends=('bc' 'git' 'python' 'swig' 'dtc' 'or1k-elf-gcc' 'or1k-elf-binutils' 'aarch64-linux-gnu-gcc' 'aarch64-linux-gnu-binutils') provides=('uboot') conflicts=('uboot') install=${pkgname}.install -source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver/rc/-rc}.tar.bz2" - "https://git.trustedfirmware.org/TF-A/trusted-firmware-a.git/snapshot/trusted-firmware-a-$_tfaver.tar.gz") -md5sums=('14656f08aa73a8dbbde2424fe78bbe3b' - '628a32a3c3b3f0c567d1ea6ee5582807') +source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver}.tar.bz2" + "https://github.com/ARM-software/arm-trusted-firmware/archive/v${_tfaver}.tar.gz" + "https://github.com/crust-firmware/crust/archive/v${_crustver}.tar.gz" +) +sha256sums=('b407e1510a74e863b8b5cb42a24625344f0e0c2fc7582d8c866bd899367d0454' + '4bfda9fdbe5022f2e88ad3344165f7d38a8ae4a0e2d91d44d9a1603425cc642d' + 'cf02f227b909f40bcfc33a94088fce12356dab41bc7459c22b7b333b305d4c72') + +export ARCH=arm64 +export CROSS_COMPILE=aarch64-linux-gnu- build() { unset CFLAGS CXXFLAGS CPPFLAGS LDFLAGS - cd trusted-firmware-a-$_tfaver - - make PLAT=sun50i_a64 DEBUG=1 bl31 - cp build/sun50i_a64/debug/bl31.bin ../u-boot-${pkgver/rc/-rc} + cd "$srcdir/arm-trusted-firmware-$_tfaver" + make PLAT=sun50i_a64 bl31 + export BL31="$srcdir/arm-trusted-firmware-$_tfaver/build/sun50i_a64/release/bl31.bin" - cd ../u-boot-${pkgver/rc/-rc} + cd "$srcdir/crust-$_crustver" + CROSS_COMPILE=or1k-elf- make pinebook_defconfig + CROSS_COMPILE=or1k-elf- make scp + export SCP="$srcdir/crust-$_crustver/build/scp/scp.bin" + cd "$srcdir/u-boot-$pkgver" make distclean make pinebook_defconfig - echo 'CONFIG_IDENT_STRING=" Manjaro ARM"' >> .config - make EXTRAVERSION=-${pkgrel} - cat spl/sunxi-spl.bin u-boot.itb > u-boot-sunxi-with-spl-pinebook.bin + echo 'CONFIG_IDENT_STRING=" Archlinux"' >> .config + make EXTRAVERSION=-$pkgrel } package() { - cd u-boot-${pkgver/rc/-rc} - - mkdir -p "${pkgdir}"/boot/extlinux - - cp u-boot-sunxi-with-spl-pinebook.bin "${pkgdir}"/boot + install -Dm644 u-boot-$pkgver/u-boot-sunxi-with-spl.bin "${pkgdir}/boot/u-boot-sunxi-with-spl-pinebook.bin" } diff --git a/uboot-pinebook.install b/uboot-pinebook.install index 9159889..cbc5fef 100644 --- a/uboot-pinebook.install +++ b/uboot-pinebook.install @@ -6,32 +6,8 @@ flash_uboot() { post_install() { flash_uboot - if [ -f /boot/extlinux/extlinux.conf.pacsave ]; then - mv /boot/extlinux/extlinux.conf.pacsave /boot/extlinux/extlinux.conf - fi - if [ -f /boot/extlinux/extlinux.conf ]; then - echo "Keeping old extlinux.conf file..." - else - mkdir -p /boot/extlinux/ - echo "LABEL Manjaro ARM -KERNEL /Image -FDT /dtbs/allwinner/sun50i-a64-pinebook.dtb -APPEND initrd=/initramfs-linux.img console=tty1 console=ttyS0,115200 root=LABEL=ROOT_MNJRO rw rootwait bootsplash.bootfile=bootsplash-themes/manjaro/bootsplash" > /boot/extlinux/extlinux.conf - fi } post_upgrade() { flash_uboot - if [ -f /boot/extlinux/extlinux.conf.pacsave ]; then - mv /boot/extlinux/extlinux.conf.pacsave /boot/extlinux/extlinux.conf - fi - if [ -f /boot/extlinux/extlinux.conf ]; then - echo "Keeping old extlinux.conf file..." - else - mkdir -p /boot/extlinux/ - echo "LABEL Manjaro ARM -KERNEL /Image -FDT /dtbs/allwinner/sun50i-a64-pinebook.dtb -APPEND initrd=/initramfs-linux.img console=tty1 console=ttyS0,115200 root=LABEL=ROOT_MNJRO rw rootwait bootsplash.bootfile=bootsplash-themes/manjaro/bootsplash" > /boot/extlinux/extlinux.conf - fi } |