David Brown | 22a6fe3 | 2017-01-10 10:40:43 -0700 | [diff] [blame] | 1 | #! /bin/bash |
David Brown | 79c4fcf | 2021-01-26 15:04:05 -0700 | [diff] [blame] | 2 | # |
| 3 | # SPDX-License-Identifier: Apache-2.0 |
David Brown | 22a6fe3 | 2017-01-10 10:40:43 -0700 | [diff] [blame] | 4 | |
| 5 | source $(dirname $0)/../target.sh |
| 6 | |
| 7 | gscript=/tmp/init$$.gdb |
| 8 | |
| 9 | cat > $gscript <<EOF |
| 10 | target remote localhost:2331 |
| 11 | symbol-file outdir/$BOARD/zephyr.elf |
| 12 | # symbol-file ../zephyr/samples/shell/outdir/$BOARD/zephyr.elf |
| 13 | # dir apps/boot/src |
| 14 | # dir libs/bootutil/src |
| 15 | # dir hw/mcu/stm/stm32f4xx/src |
| 16 | b main |
| 17 | # b __reset |
| 18 | # b bootutil_img_validate |
| 19 | # b cmp_rsasig |
| 20 | # b bootutil_verify_sig |
| 21 | # b mbedtls_rsa_public |
| 22 | # b boot_calloc |
| 23 | mon reset 2 |
| 24 | layout src |
| 25 | focus cmd |
| 26 | EOF |
| 27 | |
| 28 | $gdbexe -x $gscript |
| 29 | rm $gscript |