-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathMakefile
More file actions
35 lines (28 loc) · 772 Bytes
/
Makefile
File metadata and controls
35 lines (28 loc) · 772 Bytes
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
# Copyright 2023 ETH Zurich and University of Bologna.
# Solderpad Hardware License, Version 0.51, see LICENSE for details.
# SPDX-License-Identifier: SHL-0.51
BENDER ?= bender
VSIM ?= vsim
AVAILABLE_TESTBENCHES = tb_obi_xbar tb_obi_atop_resolver
scripts/compile.tcl:
mkdir -p scripts
$(BENDER) script vsim -t test --vlog-arg="-svinputport=compat" > $@
.PHONY: build
build: scripts/compile.tcl
$(VSIM) -c -do 'exit -code [source scripts/compile.tcl]'
.PHONY: $(AVAILABLE_TESTBENCHES)
$(AVAILABLE_TESTBENCHES): build
ifdef gui
$(VSIM) $@ -voptargs="+acc"
else
$(VSIM) -c $@ -do "run -all; quit -f"
endif
.PHONY: all
all: $(AVAILABLE_TESTBENCHES)
.PHONY: clean
clean:
rm -f scripts/compile.tcl
rm -rf work
rm -f modelsim.ini
rm -f transcript
rm -f vsim.wlf