build: add 'qemugdb' target
This new target works much like 'make qemu' but fires up a local GDB server on port 1234 and pauses execution Change-Id: I87fd174c66dcc9f2f43b5b1204cc5c34f741622d Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
parent
54b58827b0
commit
be13e26586
2 changed files with 7 additions and 0 deletions
4
Makefile
4
Makefile
|
@ -1050,6 +1050,7 @@ help:
|
||||||
@echo ' all - Build all targets marked with [*]'
|
@echo ' all - Build all targets marked with [*]'
|
||||||
@echo '* zephyr - Build a zephyr application'
|
@echo '* zephyr - Build a zephyr application'
|
||||||
@echo ' qemu - Build a zephyr application and run it in qemu'
|
@echo ' qemu - Build a zephyr application and run it in qemu'
|
||||||
|
@echo ' qemugdb - Same as 'qemu' but start a GDB server on port 1234'
|
||||||
@echo ' flash - Build and flash an application'
|
@echo ' flash - Build and flash an application'
|
||||||
@echo ' debug - Build and debug an application using GDB'
|
@echo ' debug - Build and debug an application using GDB'
|
||||||
@echo ''
|
@echo ''
|
||||||
|
@ -1168,6 +1169,9 @@ qemu: zephyr
|
||||||
$(if $(CONFIG_X86_IAMCU),python $(ZEPHYR_BASE)/scripts/qemu-machine-hack.py $(KERNEL_ELF_NAME))
|
$(if $(CONFIG_X86_IAMCU),python $(ZEPHYR_BASE)/scripts/qemu-machine-hack.py $(KERNEL_ELF_NAME))
|
||||||
$(Q)$(QEMU) $(QEMU_FLAGS) $(QEMU_EXTRA_FLAGS) -kernel $(KERNEL_ELF_NAME)
|
$(Q)$(QEMU) $(QEMU_FLAGS) $(QEMU_EXTRA_FLAGS) -kernel $(KERNEL_ELF_NAME)
|
||||||
|
|
||||||
|
qemugdb: QEMU_EXTRA_FLAGS += -s -S
|
||||||
|
qemugdb: qemu
|
||||||
|
|
||||||
-include $(srctree)/boards/$(BOARD_NAME)/Makefile.board
|
-include $(srctree)/boards/$(BOARD_NAME)/Makefile.board
|
||||||
ifneq ($(FLASH_SCRIPT),)
|
ifneq ($(FLASH_SCRIPT),)
|
||||||
flash: zephyr
|
flash: zephyr
|
||||||
|
|
|
@ -75,9 +75,12 @@ all: $(DOTCONFIG)
|
||||||
ifeq ($(findstring qemu_,$(BOARD)),)
|
ifeq ($(findstring qemu_,$(BOARD)),)
|
||||||
qemu:
|
qemu:
|
||||||
@echo "Emulation not available for this platform"
|
@echo "Emulation not available for this platform"
|
||||||
|
qemugdb: qemu
|
||||||
else
|
else
|
||||||
qemu: $(DOTCONFIG)
|
qemu: $(DOTCONFIG)
|
||||||
$(Q)$(call zephyrmake,$(O),$@)
|
$(Q)$(call zephyrmake,$(O),$@)
|
||||||
|
qemugdb: $(DOTCONFIG)
|
||||||
|
$(Q)$(call zephyrmake,$(O),$@)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
debug: $(DOTCONFIG)
|
debug: $(DOTCONFIG)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue