Skip to content

Commit f352e6b

Browse files
committed
Use dedicated json file and custom profile to build bootloader
1 parent c55b688 commit f352e6b

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

generate_rel.sh

+5-5
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ rm -rf release
33
rm -rf BUILD
44

55
if [[ $1 == "library" ]] || [[ $1 == "all" ]]; then
6-
mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_bootutil.json -DBOOTUTIL_LIBARY_BUILD=1
6+
mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --app=mbed_app_bootutil.json
77
echo
88
echo Generating bootutil library
99
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
@@ -14,7 +14,7 @@ fi
1414
if [[ $1 == "portenta" ]] || [[ $1 == "all" ]]; then
1515
echo
1616
echo Generating binaries for PORTENTA H7
17-
mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --profile=release --profile mbed-os/tools/profiles/extensions/lto.json -N mcuboot_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
1818
mkdir -p release/PORTENTA_H7
1919
cp ./libbootutil.a ./release/PORTENTA_H7
2020
cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-RELEASE/mcuboot_portenta_h7.bin ./release/PORTENTA_H7/mcuboot_portenta_h7.bin
@@ -28,7 +28,7 @@ fi
2828
if [[ $1 == "lite" ]] || [[ $1 == "all" ]]; then
2929
echo
3030
echo Generating binaries for PORTENTA H7 Lite
31-
mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --profile=release --profile mbed-os/tools/profiles/extensions/lto.json -DBOARD_HAS_VIDEO=0 -DBOARD_HAS_WIFI=0 -N mcuboot_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
3232
mkdir -p release/PORTENTA_H7_Lite
3333
cp ./libbootutil.a ./release/PORTENTA_H7_Lite
3434
cp ./BUILD/PORTENTA_H7_M7/GCC_ARM-RELEASE/mcuboot_portenta_h7_lite.bin ./release/PORTENTA_H7_Lite/mcuboot_portenta_h7_lite.bin
@@ -42,7 +42,7 @@ fi
4242
if [[ $1 == "connected" ]] || [[ $1 == "all" ]]; then
4343
echo
4444
echo Generating binaries for PORTENTA H7 Lite Connected
45-
mbed compile -c -m PORTENTA_H7_M7 -t GCC_ARM --profile=release --profile mbed-os/tools/profiles/extensions/lto.json -DBOARD_HAS_VIDEO=0 -N mcuboot_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
4646
mkdir -p release/PORTENTA_H7_Lite_Connected
4747
cp ./libbootutil.a ./release/PORTENTA_H7_Lite_Connected
4848
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
@@ -56,7 +56,7 @@ fi
5656
if [[ $1 == "nicla" ]] || [[ $1 == "all" ]]; then
5757
echo
5858
echo Generating binaries for NICLA VISION
59-
mbed compile -c -m NICLA_VISION -t GCC_ARM --profile=release --profile mbed-os/tools/profiles/extensions/lto.json -DBOARD_RAM_SIZE=0 -N mcuboot_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
6060
mkdir -p release/NICLA_VISION
6161
mv ./libbootutil.a ./release/NICLA_VISION
6262
cp ./BUILD/NICLA_VISION/GCC_ARM-RELEASE/mcuboot_nicla_vision.bin ./release/NICLA_VISION/mcuboot_nicla_vision.bin

0 commit comments

Comments
 (0)