From c4f4cfe68e55b8defc77b0f1cc293ca9f5d58ca8 Mon Sep 17 00:00:00 2001 From: Markus Koch Date: Fri, 29 Apr 2022 20:52:31 +0200 Subject: [PATCH] bench: Allow for different bench top levels in Makefile --- cocotb/Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cocotb/Makefile b/cocotb/Makefile index 8c88e68..cee0c6b 100644 --- a/cocotb/Makefile +++ b/cocotb/Makefile @@ -1,7 +1,9 @@ # defaults + SIM ?= ghdl TOPLEVEL_LANG ?= vhdl BASE = $(PWD)/.. +BENCHTOP ?= cocotb_top_mac_test COMPILE_ARGS=--std=08 SIM_ARGS ?= --wave=wave.ghw @@ -11,7 +13,7 @@ VHDL_SOURCES_design += $(BASE)/design/*.vhd VHDL_SOURCES_design += $(BASE)/bench/pll0.vhd VHDL_SOURCES += $(BASE)/cocotb/*.vhd -TOPLEVEL = cocotb_top_mac_test -MODULE = cocotb_top_mac_test +TOPLEVEL ?= $(BENCHTOP) +MODULE ?= $(BENCHTOP) include $(shell cocotb-config --makefiles)/Makefile.sim