File: run-ppc-elf

package info (click to toggle)
libaunit 18-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,100 kB
  • sloc: ada: 5,325; makefile: 152; sh: 94; xml: 13
file content (23 lines) | stat: -rwxr-xr-x 292 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/sh

if [ $# -ne 1 ]; then
  echo "Usage: $0 obj"
  exit 2
fi

obj=$1

# Generate the simple script
cat > gdb.run << EOF
# Load binary
target sim -e bug -r 0x400000
load $obj
set confirm off
run
quit
EOF

# Run gdb on it
powerpc-elf-gdb -n --batch --command=gdb.run $obj
rm -f gdb.run