Makefile.ref 1.29 KB
Newer Older
1 2 3 4 5 6 7
########################################
#  This file was generated by hdlmake  #
#  http://ohwr.org/projects/hdl-make/  #
########################################

TOP_MODULE := gate

8
MODELSIM_INI_PATH := $(HDLMAKE_MODELSIM_PATH)/..
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27

VCOM_FLAGS := -quiet -modelsimini modelsim.ini 
VSIM_FLAGS := 
VLOG_FLAGS := -quiet -modelsimini modelsim.ini 
VMAP_FLAGS := -modelsimini modelsim.ini 
#target for performing local simulation
local: sim_pre_cmd simulation sim_post_cmd

VERILOG_SRC := 
VERILOG_OBJ := 
VHDL_SRC := ../files/gate.vhdl \

VHDL_OBJ := work/gate/.gate_vhdl \

INCLUDE_DIRS :=
LIBS := work
LIB_IND := work\.work

simulation: modelsim.ini $(LIB_IND) $(VERILOG_OBJ) $(VHDL_OBJ)
28
$(VERILOG_OBJ): modelsim.ini
29 30 31 32 33
$(VHDL_OBJ): $(LIB_IND) modelsim.ini

modelsim.ini: $(MODELSIM_INI_PATH)/modelsim.ini
		copy $< . 2>&1
work\.work:
34
	(vlib work && vmap $(VMAP_FLAGS) work && type nul >> work\.work) || del /s /q /f work
35 36 37

work/gate/.gate_vhdl: ../files/gate.vhdl
		vcom $(VCOM_FLAGS) -work work $< 
38
		@mkdir $(dir $@) && type nul >> $@
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55


# USER SIM COMMANDS
sim_pre_cmd:
		
sim_post_cmd:
		

CLEAN_TARGETS := $(LIBS) modelsim.ini transcript

clean:
		del /s /q /f $(CLEAN_TARGETS)
		@-rmdir /s /q $(CLEAN_TARGETS) >nul 2>&1
mrproper: clean
		del /s /q /f *.vcd *.wlf

.PHONY: mrproper clean sim_pre_cmd sim_post_cmd simulation