diff --git a/common.mk b/common.mk index 43097731..7dee4727 100644 --- a/common.mk +++ b/common.mk @@ -61,7 +61,7 @@ CHISEL_ARGS ?= $(FIRRTL_FILE) $(ANNO_FILE): $(SCALA_SOURCES) $(sim_dotf) mkdir -p $(build_dir) - cd $(base_dir) && $(SBT) "runMain $(PROJECT).Generator $(CHISEL_ARGS) $(build_dir) $(PROJECT) $(MODEL) $(CFG_PROJECT) $(CONFIG)" + cd $(base_dir) && $(SBT) "project $(SBT_PROJECT)" "runMain $(PROJECT).Generator $(CHISEL_ARGS) $(build_dir) $(PROJECT) $(MODEL) $(CFG_PROJECT) $(CONFIG)" ######################################################################################### # create verilog files rules and variables diff --git a/variables.mk b/variables.mk index f44286c5..c944af1c 100644 --- a/variables.mk +++ b/variables.mk @@ -9,6 +9,7 @@ # MODEL = the top level module of the project (normally the harness) # CONFIG = the configuration class to give the parameters for the project # CFG_PROJECT = the scala package to find the CONFIG class +# SBT_PROJECT = the SBT project that you should find the Generator class in # TB = wrapper over the TestHarness needed to simulate in VCS # TOP = top level module of the project (normally the module instantiated by the harness) ######################################################################################### @@ -16,6 +17,7 @@ PROJECT ?= example MODEL ?= TestHarness CONFIG ?= DefaultExampleConfig CFG_PROJECT ?= $(PROJECT) +SBT_PROJECT ?= $(PROJECT) TB ?= TestDriver TOP ?= ExampleTop