From 8fb0d8bd6fc9836e1268017ccdd57a914d96c400 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Sun, 20 Jan 2019 04:13:32 -0500 Subject: [PATCH] more uboot bash shortcuts Signed-off-by: Jeff Carr --- u-boot/uboot | 20 ++++++++++++++++++++ u-boot/uboot-bash-completion | 2 +- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/u-boot/uboot b/u-boot/uboot index 1258486..6d6fd52 100755 --- a/u-boot/uboot +++ b/u-boot/uboot @@ -14,6 +14,24 @@ case "$1" in echo fucking clean echo fucking clean ;; + deps) + apt install -f libpython-dev + if [ ! -f /usr/bin/bison ]; then + apt install -f bison + fi + if [ ! -f /usr/bin/flex ]; then + apt install -f flex + fi + if [ ! -f /usr/bin/swig ]; then + apt install -f swig + fi + if [ ! -f /usr/bin/dtc ]; then + apt install -f device-tree-compiler + fi + ;; + cross) + echo export CROSS_COMPILE=/home/pinebook/cross-compilers/gcc-linaro/bin/aarch64-linux-gnu- + ;; build) make pinebook_defconfig cp ../jcarr-pinebook/u-boot/bl31.bin . @@ -50,6 +68,8 @@ case "$1" in *) echo echo 'uboot branches -- shows the git repos and branches' + echo 'uboot deps -- install all the build dependancies' + echo 'uboot cross -- set up the x86 cross compiler needed env. lame.' echo 'uboot clean -- purges more or less absolutely everything except .*' echo 'uboot build -- builds uboot for the pinebook' echo 'uboot flash -- flashes uboot onto the host "witserial"' diff --git a/u-boot/uboot-bash-completion b/u-boot/uboot-bash-completion index d0b41f9..5ce542e 100644 --- a/u-boot/uboot-bash-completion +++ b/u-boot/uboot-bash-completion @@ -5,7 +5,7 @@ _uboot() local cur prev words cword _init_completion || return - COMPREPLY=( $( compgen -W "branches build flash clean" -- "$cur" ) ) + COMPREPLY=( $( compgen -W "branches deps cross clean build flash" -- "$cur" ) ) } && complete -F _uboot uboot