X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=debug%2FMakefile;h=48be07c45ae7663ffa4733cedca7393dedce9ac4;hb=fc3d7e8196dfb567a9b6c34dd97c1b43260b4cd5;hp=1916bdaa964012ae4a7bcfca2abddfe8aeef9ad3;hpb=2091a5bfc777c2d3edc167148802f2e928960d5f;p=riscv-tests.git diff --git a/debug/Makefile b/debug/Makefile index 1916bda..48be07c 100644 --- a/debug/Makefile +++ b/debug/Makefile @@ -1,36 +1,25 @@ RISCV_SIM ?= spike XLEN ?= 64 -OPENOCD_INSTALL ?= $(abspath .)/openocd-install -OPENOCD_VERSION = 860b42a3c4f6aa37d8d4fe50a71000b7cff66b85 - -OPENOCD_DIR = $(OPENOCD_INSTALL)_$(OPENOCD_VERSION)/ - -$(OPENOCD_DIR)/bin/openocd: - rm -rf riscv-openocd - git clone http://github.com/riscv/riscv-openocd.git - cd riscv-openocd ; \ - git checkout $(OPENOCD_VERSION) ; \ - ./bootstrap ; \ - ./configure --enable-remote_bitbang --prefix=$(OPENOCD_INSTALL)_$(OPENOCD_VERSION) --disable-werror; \ - make ; \ - make install - -install_openocd: $(OPENOCD_DIR)/bin/openocd - src_dir ?= . GDBSERVER_PY = $(src_dir)/gdbserver.py -default: spike$(XLEN).log +default: spike$(XLEN) spike$(XLEN)-2 + +all-tests: spike32 spike32-2 spike32-2-rtos spike64 spike64-2 spike64-2-rtos -all: pylint spike32.log spike64.log +all: pylint all-tests pylint: - pylint --rcfile=pylint.rc *.py + pylint --rcfile=pylint.rc `git ls-files '*.py'` -%.log: - $(GDBSERVER_PY) --isolate --$(subst .log,,$@) --server_cmd $(OPENOCD_DIR)/bin/openocd \ - > $@ 2>&1 || (sed s/^/$@:\ / $@ && false) +spike%: + $(GDBSERVER_PY) \ + --isolate \ + --print-failures \ + $(src_dir)/targets/RISC-V/$@.py \ + --sim_cmd $(RISCV)/bin/$(RISCV_SIM) \ + --server_cmd $(RISCV)/bin/openocd clean: - rm -f *.log *.pyc + rm -f *.pyc