From 2ec6d7d09e2cd6c08686aae9427b46a217972675 Mon Sep 17 00:00:00 2001 From: Nathan Ringo Date: Sun, 5 May 2024 10:26:50 -0500 Subject: Initial commit --- Makefile | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..80b04e5 --- /dev/null +++ b/Makefile @@ -0,0 +1,19 @@ +BSC_COMP_FLAGS = -aggressive-conditions -check-assert -keep-fires +BSC_LINK_FLAGS = -keep-fires +TOPFILE = Top +TOPMODULE = mkTop + +all: tmp/$(TOPMODULE).exe tmp/$(TOPMODULE).v +clean: clean.sh + @./clean.sh +.PHONY: all clean + +tmp/$(TOPMODULE).exe: tmp/$(TOPMODULE).ba + @mkdir -p $(dir $@) + bsc -e $(TOPMODULE) -o $@ -p $(dir $<) -sim -simdir tmp -u $(BSC_LINK_FLAGS) +tmp/$(TOPMODULE).ba: src/$(TOPFILE).bs + @mkdir -p $(dir $@) + bsc -bdir $(dir $@) -g $(TOPMODULE) -sim -u $(BSC_COMP_FLAGS) $< +tmp/$(TOPMODULE).v: src/$(TOPFILE).bs + @mkdir -p $(dir $@) + bsc -bdir tmp -g $(TOPMODULE) -u -verilog -vdir tmp $(BSC_COMP_FLAGS) $< -- cgit v1.2.3