blob: b5daa43e98f7c670d4d863a17bfea345ae0dbcc7 [file] [log] [blame]
lh9ed821d2023-04-07 01:36:19 -07001#!/bin/sh
2
3cd ../../..
4SRC_PATH=`pwd`
5KEYS_PATH=$SRC_PATH/../tools/SignImage
6
7cd $SRC_PATH/common/src/loader
8
9make mrproper
10rm -f ./z-load*
11
12is_ok=0
13
14if
15 make "$chip"_zloader_dlon_config;
16then
17 if make platform; then
18 if make together; then
19 is_ok=1
20 fi
21 fi
22fi
23
24if [ $is_ok -eq 1 ];then
25 echo "";
xf.liaa4d92f2023-09-13 00:18:58 -070026 echo "Configuring ["$chip"_"$board"_zloader_dlon_config] for ["$chip" "$board"] board ...";
lh9ed821d2023-04-07 01:36:19 -070027
28 cp z-load.bin $SRC_PATH/common/scripts/tools;
29 cd $SRC_PATH/common/scripts/tools;
30 ./expand z-load.bin;
xf.liaa4d92f2023-09-13 00:18:58 -070031
lh9ed821d2023-04-07 01:36:19 -070032 chmod -R 777 $SRC_PATH/
xf.liaa4d92f2023-09-13 00:18:58 -070033 $SRC_PATH/../tools/SignTool/SignImage -z -i z-load.bin -o $SRC_PATH/prj/$chip/$board/bin/dl_on/zloader.bin -k $SRC_PATH/../tools/SignTool/key/RSA_1024/private.k
34
lh9ed821d2023-04-07 01:36:19 -070035 echo "--Finished build [zloader.bin] ...";
36 echo "................................................OK....";
37 echo "";
38fi