QMK/lib/chibios-contrib/os/various/gdb.mk

14 lines
369 B
Makefile
Raw Normal View History

2020-03-23 10:48:11 +01:00
GDB ?= arm-none-eabi-gdb
GDB_PROGRAM ?= $(BUILDDIR)/$(PROJECT).elf
GDB_PORT ?= 2331
GDB_START_ADDRESS ?= 0
GDB_BREAK ?= main
gdb-debug:
printf "target remote localhost:$(GDB_PORT)\nmem $(GDB_START_ADDRESS) 0\nbreak $(GDB_BREAK)\nload\nmon reset\ncontinue" > .gdbinit
$(GDB) --command=.gdbinit $(GDB_PROGRAM)
.PHONY: gdb-debug