From 1e6f7a495318addcbb6bc5ae7465a2eb1d889acd Mon Sep 17 00:00:00 2001 From: Julian T Date: Mon, 15 Feb 2021 14:31:49 +0100 Subject: Add assignments for digital design --- sem6/dig/common.mk | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 sem6/dig/common.mk (limited to 'sem6/dig/common.mk') diff --git a/sem6/dig/common.mk b/sem6/dig/common.mk new file mode 100644 index 0000000..266511b --- /dev/null +++ b/sem6/dig/common.mk @@ -0,0 +1,29 @@ + + +all: $(INPUTFILES) + +.PHONY: all clean + +%.o: %.vhdl + ghdl -a $^ + +$(INPUTFILES): %: %.o + ghdl -e $@ + +test_%.vhdl: %.vhdl ../generate_test_file.py + ../generate_test_file.py $< $@ + +test_%: test_%.o + ghdl -e $@ + +run_%: % + ghdl -r $^ + +sim_%: test_% % + -./$< --vcd=out.vcd + +clean: + ghdl --clean + rm -f work*.cf + rm -f test_*.vhdl + -- cgit v1.2.3