diff options
Diffstat (limited to 'tizen/build-kvim3.sh')
-rwxr-xr-x | tizen/build-kvim3.sh | 46 |
1 files changed, 17 insertions, 29 deletions
diff --git a/tizen/build-kvim3.sh b/tizen/build-kvim3.sh index 4aa17aa30f..29a08f590c 100755 --- a/tizen/build-kvim3.sh +++ b/tizen/build-kvim3.sh @@ -14,39 +14,27 @@ check_ccache() build_uboot() { - echo "Build $1" - if [ "$1" = "vim3" ]; then - if [ -d output ]; then - rm output/vim3/* - rm output/* - fi - - [ -d output/vim3 ] || mkdir -p output/vim3 - - if ! [ -e .config ] ; then - make ARCH=arm64 khadas-vim3_defconfig - fi - make CROSS_COMPILE="$CCACHE $CROSS_COMPILE" $JOBS - ./tools/mkimage -A arm64 -T script -C none -n "Tizen KVIM3 u-boot helper" -d ./tizen/bootscript/tizen-boot-khadas-vim3-64b.scr ./output/vim3/boot.scr.uimg - elif [ "$1" = "vim3l" ]; then - if [ -d output ]; then - rm output/vim3l/* - rm output/* - fi - - [ -d output/vim3l ] || mkdir -p output/vim3l - - if ! [ -e .config ] ; then - make ARCH=arm64 khadas-vim3l_defconfig - fi - make CROSS_COMPILE="$CCACHE $CROSS_COMPILE" $JOBS - ./tools/mkimage -A arm64 -T script -C none -n "Tizen KVIM3L u-boot helper" -d ./tizen/bootscript/tizen-boot-khadas-vim3l-64b.scr ./output/vim3l/boot.scr.uimg - else - echo "Usage ./build_vim3.sh [TARGET]" + BOARD=$1 + echo "Build $BOARD" + if [ "$BOARD" != "vim3" ] && [ "$BOARD" != "vim3l" ]; then + echo "Usage ./build_kvim3.sh [TARGET]" echo " - TARGET : vim3 or vim3l" echo " - e.g) ./build_vim3.sh vim3 or ./build_vim3.sh vim3l" exit 1; fi + if [ -d output ]; then + rm output/$BOARD/* + rm output/* + fi + + [ -d output/$BOARD ] || mkdir -p output/$BOARD + + if ! [ -e .config ] ; then + make ARCH=arm64 khadas-${BOARD}_defconfig + fi + + make CROSS_COMPILE="$CCACHE $CROSS_COMPILE" $JOBS + ./tools/mkimage -A arm64 -T script -C none -n "Tizen Khadas $BOARD u-boot helper" -d ./tizen/bootscript/tizen-boot-khadas-vim3-64b.scr ./output/$BOARD/boot.scr.uimg } |