summaryrefslogtreecommitdiff
path: root/testsuite/gna/bug17309/makefile
blob: 6914cb7177f41cca5063ffdbbb3858fef7dc40ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
# Builds the library file "polyamplib", and a lot of testbenches.

.SUFFIXES :
.SUFFIXES : .o .vhdl

AN_OPTS = --workdir=work
ANTB_OPTS = --workdir=work --ieee=synopsys
EL_OPTS = --workdir=work --ieee=synopsys

OPTIONS=--ieee=synopsys

#TB3REQ = command_decoder.o 

# General rule that don't recognize the working directory
#.vhdl.o : 
#       ghdl -a ${AN_OPTS} $<


# Add testbenches to run here
tests: prio_resolv2_tb.vcd active_input_tb.vcd one_of_n_encoder_tb.vcd master_state_machine_tb.vcd

.PHONY: tests

.PHONY: clean
clean:
	ghdl --clean ${AN_OPTS}

work/polyamplib.o : polyamplib.vhdl
	ghdl -a ${AN_OPTS} polyamplib.vhdl

ad_interface_tb.vcd: ad_interface_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} ad_interface_tb.vhdl
	ghdl -e ${EL_OPTS} ad_interface_tb
	ghdl -r ${EL_OPTS} ad_interface_tb --vcd=ad_interface_tb.vcd

prio_resolv2_tb.vcd: prio_resolv2_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} prio_resolv2_tb.vhdl
	ghdl -e ${EL_OPTS} prio_resolv2_tb
	ghdl -r ${EL_OPTS} prio_resolv2_tb --vcd=prio_resolv2_tb.vcd

active_input_tb.vcd: active_input_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} active_input_tb.vhdl
	ghdl -e ${EL_OPTS} active_input_tb
	ghdl -r ${EL_OPTS} active_input_tb --vcd=active_input_tb.vcd

one_of_n_encoder_tb.vcd: one_of_n_encoder_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} one_of_n_encoder_tb.vhdl
	ghdl -e ${EL_OPTS} one_of_n_encoder_tb
	ghdl -r ${EL_OPTS} one_of_n_encoder_tb --vcd=one_of_n_encoder_tb.vcd

master_state_machine_tb.vcd: master_state_machine_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} master_state_machine_tb.vhdl
	ghdl -e ${EL_OPTS} master_state_machine_tb
	ghdl -r ${EL_OPTS} master_state_machine_tb --vcd=master_state_machine_tb.vcd

fifo_memory_tb.vcd: fifo_memory_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} fifo_memory_tb.vhdl
	ghdl -e ${EL_OPTS} fifo_memory_tb
	ghdl -r ${EL_OPTS} fifo_memory_tb --vcd=fifo_memory_tb.vcd

fifo_ft_memory_tb.vcd: fifo_ft_memory_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} fifo_ft_memory_tb.vhdl
	ghdl -e ${EL_OPTS} fifo_ft_memory_tb
	ghdl -r ${EL_OPTS} fifo_ft_memory_tb --vcd=fifo_ft_memory_tb.vcd

#ads1271_model.o: ads1271_model.vhdl
#	ghdl -a ${ANTB_OPTS} ads1271_model.vhdl
#
#command_decoder.o : command_decoder.vhdl
#	ghdl -a ${AN_OPTS} command_decoder.vhdl

ad_interface2_tb.vcd: ad_interface2_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} ad_interface2_tb.vhdl
	ghdl -e ${EL_OPTS} ad_interface2_tb
	ghdl -r ${EL_OPTS} ad_interface2_tb --vcd=ad_interface2_tb.vcd

testguarded.vcd: testguarded.vhdl
	ghdl -a ${ANTB_OPTS} testguarded.vhdl
	ghdl -e ${EL_OPTS} testguarded
	ghdl -r ${EL_OPTS} testguarded --vcd=testguarded.vcd

sr_piso_tb.vcd: sr_piso_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} sr_piso_tb.vhdl
	ghdl -e ${EL_OPTS} sr_piso_tb
	ghdl -r ${EL_OPTS} sr_piso_tb --vcd=sr_piso_tb.vcd

spi_slave_tb1.vcd: spi_slave_tb1.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} spi_slave_tb1.vhdl
	ghdl -e ${EL_OPTS} spi_slave_tb1
	ghdl -r ${EL_OPTS} spi_slave_tb1 --vcd=spi_slave_tb1.vcd

spi_slave_burst_tb.vcd: spi_slave_burst_tb.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} spi_slave_burst_tb.vhdl
	ghdl -e ${EL_OPTS} spi_slave_burst_tb
	ghdl -r ${EL_OPTS} spi_slave_burst_tb --vcd=spi_slave_burst_tb.vcd

master_testbench.vcd: master_testbench.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} master_testbench.vhdl
	ghdl -e ${EL_OPTS} master_testbench
	ghdl -r ${EL_OPTS} master_testbench --vcd=master_testbench.vcd

master_testbench2.vcd: master_testbench2.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} master_testbench2.vhdl
	ghdl -e ${EL_OPTS} master_testbench2
	ghdl -r ${EL_OPTS} master_testbench2 --vcd=master_testbench2.vcd

master_testbench3.vcd: master_testbench3.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} master_testbench3.vhdl
	ghdl -e ${EL_OPTS} master_testbench3
	ghdl -r ${EL_OPTS} master_testbench3 --vcd=master_testbench3.vcd

fast_edge_detect.vcd: fast_edge_detect.vhdl work/polyamplib.o
	ghdl -a ${ANTB_OPTS} fast_edge_detect.vhdl
	ghdl -e ${EL_OPTS} fast_edge_detect
	ghdl -r ${EL_OPTS} fast_edge_detect --vcd=fast_edge_detect.vcd
srff_tb.vcd: srff.vhdl
	ghdl -a ${ANTB_OPTS} srff.vhdl
	ghdl -e ${EL_OPTS} srff_tb
	ghdl -r ${EL_OPTS} srff_tb --vcd=srff_tb.vcd