Skip to content

Auto-generate VHDL LS .toml library configuration from OSVVM .pro files #72

@BekdoucheAmine

Description

@BekdoucheAmine

Description
To my knowledge, integrating OSVVM libraries with the VS Code VHDL Language Server currently requires manually defining libraries and file paths in the .vhdl_ls.toml file.

Therefore, I propose a TCL-based solution (this could also be implemented in Python, but maintaining TCL preserves consistency with the existing OSVVM scripting workflow). The feature would parse OSVVM build.pro files recursively, starting from the main OsvvmLibraries.pro, and automatically generate the corresponding .toml library configuration for VS Code.

Motivation

  • Reduce manual configuration for VHDL LS
  • Ensure .toml always matches OSVVM build structure
  • Improve developer onboarding and reproducibility
  • Enable scalable integration as new OSVVM libraries are added

Proposed Behavior

  • Parse the root OsvvmLibraries.pro file
  • Recursively follow include directives
  • Collect all analyzed VHDL source files
  • Group files by library
  • Generate or update .vhdl_ls.toml automatically

Example Workflow

  1. Run the TCL setup script, which invokes the procedure responsible for generating or updating .vhdl_ls.toml.
  2. The script parses the OSVVM .pro hierarchy recursively, resolving include, use, and analyze directives.
  3. All discovered VHDL source files are grouped by library and written into .vhdl_ls.toml, keeping the VS Code VHDL LS configuration synchronized with the OSVVM build structure.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions