Skip to content

Commit

Permalink
Fix quoting and make libdirs
Browse files Browse the repository at this point in the history
  • Loading branch information
olofk committed Nov 4, 2024
1 parent 237fed3 commit 5047f40
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions edalize/tools/vcs.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,11 @@ def setup(self, edam):

_args = []
for k, v in vlog_defines.items():
_args.append("+define+{}={}".format(k, self._param_value_str(v)))
_args.append(
"+define+{}={}".format(
k, self._param_value_str(v, str_quote_style='\\"')
)
)
defines = " ".join(_args)
cmd = "vlogan"
elif file_type.startswith("vhdlSource"):
Expand Down Expand Up @@ -118,7 +122,7 @@ def setup(self, edam):
depfiles.append(fname)
if cmd == "vlogan":
has_vlog = True
commands = []
commands = [["mkdir", lib]]
for (cmd, defines), fnames in cmds.items():
if cmd == "vlogan":
options = vlogan_options.copy()
Expand Down Expand Up @@ -152,6 +156,14 @@ def setup(self, edam):
[self.name],
)
self.commands.set_default_target(self.name)
self.libs = libs.keys()

def write_config_files(self):
s = "WORK > DEFAULT\nDEFAULT : ./work\n"
for lib in self.libs:
if lib != "work":
s += f"{lib} : ./{lib}\n"
self.update_config_file("synopsys_sim.setup", s)

def run(self):
args = ["run"]
Expand Down

0 comments on commit 5047f40

Please sign in to comment.