> sim RTL
ysyx_22040000 李心杨 Linux calcite 6.1.69 #1-NixOS SMP PREEMPT_DYNAMIC Wed Dec 20 16:00:29 UTC 2023 x86_64 GNU/Linux 14:05:24 up 22:44, 2 users, load average: 0.93, 0.77, 0.80
This commit is contained in:
parent
23766bd467
commit
1a6f02c20a
1 changed files with 6 additions and 8 deletions
14
npc/Makefile
14
npc/Makefile
|
@ -4,7 +4,7 @@ OBJDIR := $(PREFIX)/obj
|
|||
TARGET := $(OBJDIR)/Vexample
|
||||
|
||||
VSRC := $(wildcard vsrc/*.v)
|
||||
SRC_AUTO_BIND := $(PREFIX)/auto_bind.cpp
|
||||
SRC_AUTO_BIND := $(abspath $(PREFIX)/auto_bind.cpp)
|
||||
CPPSRCS := $(addprefix $(PWD)/,$(wildcard csrc/*.cpp))
|
||||
NXDC_FILES = $(abspath constr/top.nxdc)
|
||||
SUBMAKE := $(OBJDIR)/Vexample.mk
|
||||
|
@ -26,13 +26,11 @@ $(OBJDIR)/Vexample: $(SUBMAKE)
|
|||
$(PREFIX)/nvobj/Vexample: $(SUBMAKE)
|
||||
$(MAKE) -C $(OBJDIR) -f $(notdir $(SUBMAKE)) Vexample
|
||||
|
||||
$(SUBMAKE): $(VSRC) $(CPPSRCS) $(OBJDIR)
|
||||
$(SUBMAKE): $(VSRC) $(CPPSRCS)
|
||||
mkdir -p $(OBJDIR)
|
||||
verilator $(VERILATOR_FLAGS) $(addprefix -CFLAGS , $(CXXFLAGS)) $(addprefix -LDFLAGS , $(LDFLAGS)) --Mdir $(abspath $(OBJDIR)) $(VSRC) $(CPPSRCS)
|
||||
|
||||
$(OBJDIR):
|
||||
mkdir -p $(OBJDIR)
|
||||
|
||||
$(SRC_AUTO_BIND): $(NXDC_FILES) $(OBJDIR)
|
||||
$(SRC_AUTO_BIND): $(NXDC_FILES)
|
||||
NVBOARD_HOME=$(NVBOARD_HOME) python3 $(NVBOARD_HOME)/scripts/auto_pin_bind.py $< $@
|
||||
|
||||
ifneq (,$(wildcard ../Makefile))
|
||||
|
@ -49,10 +47,10 @@ git_trace:
|
|||
.PHONY: clean nvboard
|
||||
|
||||
# TODO: fix this awkward way to find nvboard.a
|
||||
nvboard: OBJDIR := $(PREFIX)/nvobj
|
||||
nvboard: CPPSRCS := $(addprefix $(PWD)/,$(wildcard csrc_nvboard/*.cpp)) $(SRC_AUTO_BIND) $(NVBOARD_HOME)/build/nvboard.a
|
||||
nvboard: CXXFLAGS += -I$(NVBOARD_HOME)/include $(shell sdl2-config --cflags) -g
|
||||
nvboard: OBJDIR := $(PREFIX)/nvobj
|
||||
nvboard: $(VSRC) $(CPPSRCS) $(PREFIX)/nvobj/Vexample $(SUBMAKE) $(SRC_AUTO_BIND)
|
||||
nvboard: $(VSRC) $(CPPSRCS) $(PREFIX)/nvobj/Vexample $(SUBMAKE) $(SRC_AUTO_BIND)
|
||||
@NVBOARD_HOME=$(NVBOARD_HOME) $(OBJDIR)/Vexample
|
||||
|
||||
clean:
|
||||
|
|
Loading…
Add table
Reference in a new issue