@@ -3,22 +3,23 @@ rm -rf release
3
3
rm -rf BUILD
4
4
5
5
mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_bootutil.json
6
+
7
+ set -e
8
+
6
9
echo
7
10
echo Generating bootutil library
8
11
find ./BUILD/PORTENTA_H7_M7/GCC_ARM/ \( -name " FileBlockDevice.o" -o -name " BSP.o" -o -name " SDMMCBlockDevice.o" -o -name " rtc.o" -o -name " default_bd.o" -o -name " bootutil_extra.o" -o -name " flash_map_backend.o" -o -name " bootutil_public.o" \) | xargs arm-none-eabi-ar -csr libbootutil.a
9
12
echo -n " Library: "
10
13
find ./ -name " libbootutil.a"
11
14
12
- set -e
13
-
14
15
if [[ $1 == " portenta" ]] || [[ $1 == " all" ]]; then
15
16
echo
16
17
echo Generating binaries for PORTENTA H7
17
- mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_portenta.json --profile=release --profile custom.json -N mcuboot_portenta_h7
18
+ mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_portenta.json --profile=custom.json -N mcuboot_portenta_h7
18
19
mkdir -p release/PORTENTA_H7
19
20
cp ./libbootutil.a ./release/PORTENTA_H7
20
- cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-RELEASE /mcuboot_portenta_h7.bin ./release/PORTENTA_H7/mcuboot_portenta_h7.bin
21
- cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-RELEASE /mcuboot_portenta_h7_application.elf ./release/PORTENTA_H7/mcuboot_portenta_h7.elf
21
+ cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-CUSTOM /mcuboot_portenta_h7.bin ./release/PORTENTA_H7/mcuboot_portenta_h7.bin
22
+ cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-CUSTOM /mcuboot_portenta_h7_application.elf ./release/PORTENTA_H7/mcuboot_portenta_h7.elf
22
23
xxd -i ./release/PORTENTA_H7/mcuboot_portenta_h7.bin > ./release/PORTENTA_H7/mcuboot_portenta_h7.h
23
24
sed -i " s/unsigned char __release_PORTENTA_H7_mcuboot_portenta_h7_bin/const unsigned char mcuboot_portenta_h7_bin/" ./release/PORTENTA_H7/mcuboot_portenta_h7.h
24
25
sed -i " s/__release_PORTENTA_H7_mcuboot_portenta_h7_bin_len/mcuboot_portenta_h7_bin_len/" ./release/PORTENTA_H7/mcuboot_portenta_h7.h
28
29
if [[ $1 == " lite" ]] || [[ $1 == " all" ]]; then
29
30
echo
30
31
echo Generating binaries for PORTENTA H7 Lite
31
- mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_portenta_lite.json --profile=release --profile custom.json -N mcuboot_portenta_h7_lite
32
+ mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_portenta_lite.json --profile=custom.json -N mcuboot_portenta_h7_lite
32
33
mkdir -p release/PORTENTA_H7_Lite
33
34
cp ./libbootutil.a ./release/PORTENTA_H7_Lite
34
- cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-RELEASE /mcuboot_portenta_h7_lite.bin ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.bin
35
- cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-RELEASE /mcuboot_portenta_h7_lite_application.elf ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.elf
35
+ cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-CUSTOM /mcuboot_portenta_h7_lite.bin ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.bin
36
+ cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-CUSTOM /mcuboot_portenta_h7_lite_application.elf ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.elf
36
37
xxd -i ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.bin > ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.h
37
38
sed -i " s/unsigned char __release_PORTENTA_H7_mcuboot_portenta_h7_lite_bin/const unsigned char mcuboot_portenta_h7_lite_bin/" ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.h
38
39
sed -i " s/__release_PORTENTA_H7_mcuboot_portenta_h7_lite_bin_len/mcuboot_portenta_h7_lite_bin_len/" ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.h
42
43
if [[ $1 == " connected" ]] || [[ $1 == " all" ]]; then
43
44
echo
44
45
echo Generating binaries for PORTENTA H7 Lite Connected
45
- mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_portenta_lite_connected.json --profile=release --profile custom.json -N mcuboot_portenta_h7_lite_connected
46
+ mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_portenta_lite_connected.json --profile=custom.json -N mcuboot_portenta_h7_lite_connected
46
47
mkdir -p release/PORTENTA_H7_Lite_Connected
47
48
cp ./libbootutil.a ./release/PORTENTA_H7_Lite_Connected
48
- cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-RELEASE /mcuboot_portenta_h7_lite_connected.bin ./release/PORTENTA_H7_Lite_Connected/mcuboot_portenta_h7_lite_connected.bin
49
- cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-RELEASE /mcuboot_portenta_h7_lite_connected_application.elf ./release/PORTENTA_H7_Lite_Connected/mcuboot_portenta_h7_lite_connected.elf
49
+ cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-CUSTOM /mcuboot_portenta_h7_lite_connected.bin ./release/PORTENTA_H7_Lite_Connected/mcuboot_portenta_h7_lite_connected.bin
50
+ cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-CUSTOM /mcuboot_portenta_h7_lite_connected_application.elf ./release/PORTENTA_H7_Lite_Connected/mcuboot_portenta_h7_lite_connected.elf
50
51
xxd -i ./release/PORTENTA_H7_Lite_Connected/mcuboot_portenta_h7_lite_connected.bin > ./release/PORTENTA_H7_Lite_Connected/mcuboot_portenta_h7_lite_connected.h
51
52
sed -i " s/unsigned char __release_PORTENTA_H7_mcuboot_portenta_h7_lite_connected_bin/const unsigned char mcuboot_portenta_h7_lite_connected_bin/" ./release/PORTENTA_H7_Lite_Connected/mcuboot_portenta_h7_lite_connected.h
52
53
sed -i " s/__release_PORTENTA_H7_mcuboot_portenta_h7_lite_connected_bin_len/mcuboot_portenta_h7_lite_connected_bin_len/" ./release/PORTENTA_H7_Lite_Connected/mcuboot_portenta_h7_lite_connected.h
56
57
if [[ $1 == " nicla" ]] || [[ $1 == " all" ]]; then
57
58
echo
58
59
echo Generating binaries for NICLA VISION
59
- mbed compile -c -m NICLA_VISION -t GCC_ARM --app=mbed_app_nicla_vision.json --profile=release --profile custom.json -N mcuboot_nicla_vision
60
+ mbed compile -c -m NICLA_VISION -t GCC_ARM --app=mbed_app_nicla_vision.json --profile=custom.json -N mcuboot_nicla_vision
60
61
mkdir -p release/NICLA_VISION
61
62
mv ./libbootutil.a ./release/NICLA_VISION
62
- cp ./BUILD/NICLA_VISION/GCC_ARM-RELEASE /mcuboot_nicla_vision.bin ./release/NICLA_VISION/mcuboot_nicla_vision.bin
63
- cp ./BUILD/NICLA_VISION/GCC_ARM-RELEASE /mcuboot_nicla_vision_application.elf ./release/NICLA_VISION/mcuboot_nicla_vision.elf
63
+ cp ./BUILD/NICLA_VISION/GCC_ARM-CUSTOM /mcuboot_nicla_vision.bin ./release/NICLA_VISION/mcuboot_nicla_vision.bin
64
+ cp ./BUILD/NICLA_VISION/GCC_ARM-CUSTOM /mcuboot_nicla_vision_application.elf ./release/NICLA_VISION/mcuboot_nicla_vision.elf
64
65
xxd -i ./release/NICLA_VISION/mcuboot_nicla_vision.bin > ./release/NICLA_VISION/mcuboot_nicla_vision.h
65
66
sed -i " s/unsigned char __release_NICLA_VISION_mcuboot_nicla_vision_bin/const unsigned char mcuboot_nicla_vision_bin/" ./release/NICLA_VISION/mcuboot_nicla_vision.h
66
67
sed -i " s/__release_NICLA_VISION_mcuboot_nicla_vision_bin_len/mcuboot_nicla_vision_bin_len/" ./release/NICLA_VISION/mcuboot_nicla_vision.h
0 commit comments