diff --git a/edalize/tools/vcs.py b/edalize/tools/vcs.py index 1ceb1375..a4091dfe 100644 --- a/edalize/tools/vcs.py +++ b/edalize/tools/vcs.py @@ -157,19 +157,20 @@ def setup(self, edam): self.f_files["vcs.f"] = ["-top", self.toplevel] + self.tool_options.get( "vcs_options", [] ) + binary_name = self.name + ".vsim" self.commands.add( ["vcs"] + full64 - + ["-o", self.name, "-file", "vcs.f", "-parameters", "parameters.txt"], - [self.name], + + ["-o", binary_name, "-file", "vcs.f", "-parameters", "parameters.txt"], + [binary_name], target_files + user_files + ["vcs.f", "parameters.txt"], ) self.commands.add( - ["./" + self.name, "$(EXTRA_OPTIONS)"] + ["./" + binary_name, "$(EXTRA_OPTIONS)"] + self.tool_options.get("run_options", []), ["run"], - [self.name], + [binary_name], ) self.commands.set_default_target(self.name) diff --git a/tests/tools/vcs/basic/Makefile b/tests/tools/vcs/basic/Makefile index 49c1c573..8a4d96e7 100644 --- a/tests/tools/vcs/basic/Makefile +++ b/tests/tools/vcs/basic/Makefile @@ -14,8 +14,8 @@ work_2/64/vhmra.sdb: vhdl_file.vhd vhdl2008_file vlog_incfile work_2.f libx/64/vhmra.sdb: vhdl_lfile libx.f $(EDALIZE_LAUNCHER) vhdlan -full64 -f libx.f -work libx vhdl_lfile -design: work/AN.DB/make.vlogan work_1/AN.DB/make.vlogan work_2/64/vhmra.sdb libx/64/vhmra.sdb user_file vcs.f parameters.txt - $(EDALIZE_LAUNCHER) vcs -full64 -o design -file vcs.f -parameters parameters.txt +design.vsim: work/AN.DB/make.vlogan work_1/AN.DB/make.vlogan work_2/64/vhmra.sdb libx/64/vhmra.sdb user_file vcs.f parameters.txt + $(EDALIZE_LAUNCHER) vcs -full64 -o design.vsim -file vcs.f -parameters parameters.txt -run: design - $(EDALIZE_LAUNCHER) ./design $(EXTRA_OPTIONS) and some run options +run: design.vsim + $(EDALIZE_LAUNCHER) ./design.vsim $(EXTRA_OPTIONS) and some run options diff --git a/tests/tools/vcs/minimal/Makefile b/tests/tools/vcs/minimal/Makefile index f6c67c1a..a82692b8 100644 --- a/tests/tools/vcs/minimal/Makefile +++ b/tests/tools/vcs/minimal/Makefile @@ -14,8 +14,8 @@ work_2/64/vhmra.sdb: vhdl_file.vhd vhdl2008_file vlog_incfile work_2.f libx/64/vhmra.sdb: vhdl_lfile libx.f $(EDALIZE_LAUNCHER) vhdlan -full64 -f libx.f -work libx vhdl_lfile -design: work/AN.DB/make.vlogan work_1/AN.DB/make.vlogan work_2/64/vhmra.sdb libx/64/vhmra.sdb user_file vcs.f parameters.txt - $(EDALIZE_LAUNCHER) vcs -full64 -o design -file vcs.f -parameters parameters.txt +design.vsim: work/AN.DB/make.vlogan work_1/AN.DB/make.vlogan work_2/64/vhmra.sdb libx/64/vhmra.sdb user_file vcs.f parameters.txt + $(EDALIZE_LAUNCHER) vcs -full64 -o design.vsim -file vcs.f -parameters parameters.txt -run: design - $(EDALIZE_LAUNCHER) ./design $(EXTRA_OPTIONS) +run: design.vsim + $(EDALIZE_LAUNCHER) ./design.vsim $(EXTRA_OPTIONS)