Merge pull request #1542 from haukepetersen/add_make_moretargets

make: added targets 'debug-server' and 'reset'
dev/timer
Hauke Petersen 9 years ago
commit 0a7a2c088d

@ -193,4 +193,11 @@ buildinfo:
@echo 'DEBUGGER: $(DEBUGGER)'
@echo 'DEBUGGER_FLAGS: $(DEBUGGER_FLAGS)'
@echo ''
@echo 'DEBUGSERVER: $(DEBUGSERVER)'
@echo 'DEBUGSERVER_FLAGS: $(DEBUGSERVER_FLAGS)'
@echo ''
@echo 'RESET: $(RESET)'
@echo 'RESET_FLAGS: $(RESET_FLAGS)'
@echo ''
@echo -e 'MAKEFILE_LIST:$(patsubst %, \n\t%, $(abspath $(MAKEFILE_LIST)))'

@ -157,6 +157,12 @@ doc:
debug:
$(DEBUGGER) $(DEBUGGER_FLAGS)
debug-server:
$(DEBUGSERVER) $(DEBUGSERVER_FLAGS)
reset:
$(RESET) $(RESET_FLAGS)
# Extra make goals for testing and comparing changes.
include $(RIOTBASE)/Makefile.buildtests

@ -40,3 +40,9 @@ export TERMPROG # The command to call on "make term".
export PORT # The parameters to supply to TERMPROG.
export ELFFILE # The unstripped result of the compilation.
export HEXFILE # The stripped result of the compilation.
export DEBUGGER # The command to call on "make debug", usually a script starting the GDB front-end
export DEBUGGER_FLAGS # The parameters to supply to DEBUGGER
export DEBUGSERVER # The command to call on "make debug-server", usually a script starting the GDB server
export DEBUGSERVER_FLAGS # The parameters to supply to DEBUGSERVER
export RESET # The command to call on "make reset", this command resets/reboots the target
export RESET_FLAGS # The parameters to supply to RESET

@ -18,13 +18,17 @@ TERMPROG = $(RIOTBASE)/dist/tools/pyterm/pyterm
export FLASHER ?= mspdebug
export PORT ?= /dev/ttyUSB0
export PROGRAMMER ?= olimex
export FFLAGS += -j $(PROGRAMMER)
export MSPDEBUGFLAGS += -j $(PROGRAMMER)
ifeq ($(strip $(PROGRAMMER)),uif)
export FFLAGS += -d $(PORT)
export MSPDEBUGFLAGS += -d $(PORT)
endif
export DEBUGSERVER = $(FLASHER)
export DEBUGSERVER_FLAGS = $(MSPDEBUGFLAGS) gdb
export DEBUGGER = $(PREFIX)gdb
export DEBUGGER_FLAGS = --tui --ex="target remote localhost:2000" --ex "monitor reset halt" --ex load -ex "monitor reset halt" $(ELFFILE)
export TERMFLAGS += -p
export FFLAGS += "prog $(HEXFILE)"
export FFLAGS = $(MSPDEBUGFLAGS) "prog $(HEXFILE)"
export USEMODULE += msp430_common
export INCLUDES += -I$(RIOTCPU)/msp430-common/include/ -I$(RIOTBOARD)/msb-430-common/include -I$(RIOTBOARD)/msb-430-common/drivers/include

@ -25,6 +25,7 @@ export OBJCOPY = $(PREFIX)objcopy
export TERMPROG = $(RIOTBASE)/dist/tools/pyterm/pyterm
export FLASHER = st-flash
export DEBUGGER = $(RIOTBOARD)/$(BOARD)/dist/debug.sh
export DEBUGSERVER = st-util
# define build specific options
CPU_USAGE = -mcpu=cortex-m0

@ -25,6 +25,7 @@ export OBJCOPY = $(PREFIX)objcopy
export TERMPROG = $(RIOTBASE)/dist/tools/pyterm/pyterm
export FLASHER = st-flash
export DEBUGGER = $(RIOTBOARD)/$(BOARD)/dist/debug.sh
export DEBUGSERVER = st-util
# define build specific options
CPU_USAGE = -mcpu=cortex-m4

@ -25,6 +25,7 @@ export OBJCOPY = $(PREFIX)objcopy
export TERMPROG = $(RIOTBASE)/dist/tools/pyterm/pyterm
export FLASHER = st-flash
export DEBUGGER = $(RIOTBOARD)/$(BOARD)/dist/debug.sh
export DEBUGSERVER = st-util
# define build specific options
CPU_USAGE = -mcpu=cortex-m4

Loading…
Cancel
Save