#icarus verilog
#iverilog
TOP = test_counter
SRC = counter.v
TEST_SRC= test_counter.v
BIN = $(TOP).vvp
$(BIN): $(SRC) $(TEST_SRC)
iverilog -o $(BIN) -s $(TOP) $(SRC) $(TEST_SRC)
.PHONY: all clean test
all: $(BIN)
test: $(BIN)
vvp $(BIN)
clean:
rm -f *.vvp *.vcd
https://brng.dev/blog/technical/tutorial/2019/05/11/icarus_gtkwave/