36 lines
1.1 KiB
Makefile
36 lines
1.1 KiB
Makefile
TESTBENCH = vgasquare_tb.v
|
|
SRC = vgasquare.v vga640x480.v
|
|
|
|
#Tools
|
|
COMPILER = "C:\System\iverilog\bin\iverilog.exe"
|
|
SIMULATOR = "C:\System\iverilog\bin\vvp.exe"
|
|
VIEWER = "C:\System\iverilog\gtkwave\bin\gtkwave.exe"
|
|
|
|
TBOUTPUT = vgasquare_tb.vcd #THIS NEEDS TO MATCH THE OUTPUT FILE
|
|
#FROM YOUR TESTBENCH
|
|
###############################################################################
|
|
# BE CAREFUL WHEN CHANGING ITEMS BELOW THIS LINE
|
|
###############################################################################
|
|
#TOOL OPTIONS
|
|
COFLAGS = -o
|
|
SFLAGS =
|
|
SOUTPUT = -lxt #SIMULATOR OUTPUT TYPE
|
|
#TOOL OUTPUT
|
|
COUTPUT = vgasquare_tb.vpp #COMPILER OUTPUT
|
|
###############################################################################
|
|
#MAKE DIRECTIVES
|
|
check : $(TESTBENCH) $(SRC)
|
|
$(COMPILER) -v $(SRC)
|
|
|
|
simulate: $(COUTPUT)
|
|
$(SIMULATOR) $(SFLAGS) $(COUTPUT) $(SOUTPUT)
|
|
|
|
display: $(TBOUTPUT)
|
|
$(VIEWER) $(TBOUTPUT)
|
|
|
|
#MAKE DEPENDANCIES
|
|
$(TBOUTPUT): $(COUTPUT)
|
|
$(SIMULATOR) $(SOPTIONS) $(COUTPUT) $(SOUTPUT)
|
|
|
|
$(COUTPUT): $(TESTBENCH) $(SRC)
|
|
$(COMPILER) $(COFLAGS) $(COUTPUT) $(TESTBENCH) $(SRC)
|