This commit is contained in:
joey0320
2023-02-13 02:14:23 -08:00
parent 4d31ccf218
commit 6cd46d3c73
5 changed files with 16 additions and 13 deletions

View File

@@ -102,7 +102,6 @@ $(BOOTROM_TARGETS): $(build_dir)/bootrom.%.img: $(TESTCHIP_RSRCS_DIR)/testchipip
#########################################################################################
# AG: must re-elaborate if cva6 sources have changed... otherwise just run firrtl compile
$(FIRRTL_FILE) $(ANNO_FILE) &: $(SCALA_SOURCES) $(sim_files) $(SCALA_BUILDTOOL_DEPS) $(EXTRA_GENERATOR_REQS)
if [ -d $(OUT_DIR) ]; then rm -rf $(OUT_DIR); fi
mkdir -p $(build_dir)
$(call run_scala_main,$(SBT_PROJECT),$(GENERATOR_PACKAGE).Generator,\
--target-dir $(build_dir) \

View File

@@ -94,10 +94,11 @@ SIM_FILE_REQS += \
$(ROCKETCHIP_RSRCS_DIR)/vsrc/EICG_wrapper.v
# copy files but ignore *.h files in *.f (match vcs)
$(sim_files): $(SIM_FILE_REQS) | $(OUT_DIR)
cp -f $^ $(OUT_DIR)
$(sim_files): $(SIM_FILE_REQS) $(OUT_DIR)
rm -rf $(OUT_DIR)/*
cp -f $(SIM_FILE_REQS) $(OUT_DIR)
$(foreach file,\
$^,\
$(SIM_FILE_REQS),\
$(if $(filter %.h,$(file)),\
,\
echo "$(addprefix $(OUT_DIR)/, $(notdir $(file)))" >> $@;))

View File

@@ -38,10 +38,11 @@ SIM_FILE_REQS += \
$(ROCKETCHIP_RSRCS_DIR)/vsrc/TestDriver.v
# copy files but ignore *.h files in *.f since vcs has +incdir+$(build_dir)
$(sim_files): $(SIM_FILE_REQS) | $(OUT_DIR)
cp -f $^ $(OUT_DIR)
$(sim_files): $(SIM_FILE_REQS) $(OUT_DIR)
rm -rf $(OUT_DIR)/*
cp -f $(SIM_FILE_REQS) $(OUT_DIR)
$(foreach file,\
$^,\
$(SIM_FILE_REQS),\
$(if $(filter %.h,$(file)),\
,\
echo "$(addprefix $(OUT_DIR)/, $(notdir $(file)))" >> $@;))

View File

@@ -66,10 +66,11 @@ SIM_FILE_REQS += \
$(ROCKETCHIP_RSRCS_DIR)/csrc/remote_bitbang.cc
# copy files and add -FI for *.h files in *.f
$(sim_files): $(SIM_FILE_REQS) | $(OUT_DIR)
cp -f $^ $(OUT_DIR)
$(sim_files): $(SIM_FILE_REQS) $(OUT_DIR)
rm -rf $(OUT_DIR)/*
cp -f $(SIM_FILE_REQS) $(OUT_DIR)
$(foreach file,\
$^,\
$(SIM_FILE_REQS),\
$(if $(filter %.h,$(file)),\
echo "-FI $(addprefix $(OUT_DIR)/, $(notdir $(file)))" >> $@;,\
echo "$(addprefix $(OUT_DIR)/, $(notdir $(file)))" >> $@;))

View File

@@ -108,10 +108,11 @@ SIM_FILE_REQS += \
$(ROCKETCHIP_RSRCS_DIR)/vsrc/TestDriver.v
# copy files but ignore *.h files in *.f since vcs has +incdir+$(build_dir)
$(sim_files): $(SIM_FILE_REQS) | $(build_dir)
cp -f $^ $(build_dir)
$(sim_files): $(SIM_FILE_REQS) $(build_dir)
rm -rf $(build_dir)/*
cp -f $(SIM_FILE_REQS) $(build_dir)
$(foreach file,\
$^,\
$(SIM_FILE_REQS),\
$(if $(filter %.h,$(file)),\
,\
echo "$(addprefix $(build_dir)/, $(notdir $(file)))" >> $@;))