From bf0bd795c9ffffb7c35009e7fa3539d18ce1ef90 Mon Sep 17 00:00:00 2001 From: radami2006 Date: Wed, 18 Mar 2026 08:14:42 +0000 Subject: [PATCH] fix(vivado): detect xvhdl/xvlog in linter configuration check on Windows Issue #821 reported that Vivado 2025.1 on Windows was not detected when users configured the unwrapped bin folder. Updated Vivado linter configuration validation to try multiple candidate binaries: xvhdl, xvlog, and vivado. This allows TerosHDL to validate more Vivado installation layouts, including paths where vivado.exe is not the executable used for linting. Closes #821 --- src/colibri/linter/vivado.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/colibri/linter/vivado.ts b/src/colibri/linter/vivado.ts index 14073955..accb9590 100644 --- a/src/colibri/linter/vivado.ts +++ b/src/colibri/linter/vivado.ts @@ -25,6 +25,7 @@ import { LANGUAGE } from "../common/general"; import { Base_linter } from "./base_linter"; import * as common from "./common"; import * as path_lib from "path"; +import { BinaryCheck, checkBinary } from "colibri/toolChecker/utils"; export class Vivado extends Base_linter { binary = "vivado"; @@ -35,6 +36,13 @@ export class Vivado extends Base_linter { super(); } + public async checkLinterConfiguration(installationPath: string): Promise { + // Vivado installations can expose either wrapper binaries (vivado) or + // direct lint binaries (xvhdl/xvlog), depending on the configured folder. + const binaryCandidates = ["xvhdl", "xvlog", "vivado"]; + return await checkBinary(this.constructor.name, installationPath, binaryCandidates, this.argumentToCheck); + } + public set_binary(file: string) { const file_lang = get_language_from_filepath(file); let binary = "";