Skip to content

Commit

Permalink
feat: run yowasp-yosys from output dir
Browse files Browse the repository at this point in the history
  • Loading branch information
qarlosalberto committed Oct 3, 2024
1 parent f1314cf commit 7b7f607
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion auto_package/templates/info.nj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"displayName": "TerosHDL",
"publisher": "teros-technology",
"description": "Powerful toolbox for ASIC/FPGA: state machine viewer, linter, documentation, snippets... and more! ",
"version": "6.0.9",
"version": "6.0.10",
"engines": {
"vscode": "^1.74.0"
},
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"displayName": "TerosHDL",
"publisher": "teros-technology",
"description": "Powerful toolbox for ASIC/FPGA: state machine viewer, linter, documentation, snippets... and more! ",
"version": "6.0.9",
"version": "6.0.10",
"engines": {
"vscode": "^1.74.0"
},
Expand Down
8 changes: 5 additions & 3 deletions src/colibri/yosys/yosys.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,15 @@ export function runYosysRaw(config: e_config, topTevel: string, sources: t_file[

const outputPathFilename = config.schematic.general.backend === e_schematic_general_backend.yowasp ?
process_utils.createTempFileInHome("") : process_utils.create_temp_file("");

const outputPathName = file_utils.get_filename(outputPathFilename, true);

let cmd =
// eslint-disable-next-line max-len
`${preArguments} ${yosysPath} -p "${cmdFiles}; ${topLevelCmd}; proc; ${customArguments}; write_json ${outputPathFilename}; stat"`;
`${preArguments} ${yosysPath} -p "${cmdFiles}; ${topLevelCmd}; proc; ${customArguments}; write_json ${outputPathName}; stat"`;
cmd = removeEmptyCommands(cmd);

const opt_exec = { cwd: get_directory(topTevel) };
const opt_exec = { cwd: get_directory(outputPathFilename) };

const p = new Process();
const exec_i = p.exec(cmd, opt_exec, (result: p_result) => {
Expand Down Expand Up @@ -276,4 +278,4 @@ function normalizePathForLinux(filepath: string): string {
}
const normalizedPath = path_lib.normalize(filepath);
return normalizedPath.replace(/\\/g, '/');
}
}

0 comments on commit 7b7f607

Please sign in to comment.