| 1234567891011121314151617181920212223242526272829303132333435363738 |
- # Activate the local PID verification toolchain for the current PowerShell session only.
- # This script does not modify the system PATH, registry, user profile, or repository.
- $ToolchainBase = Join-Path $HOME "CodexToolchains\CPLD"
- $ToolchainRoot = Join-Path $ToolchainBase "oss-cad-suite\latest"
- $CocotbPython = Join-Path $ToolchainBase "venvs\pid-study-cocotb-venv\Scripts\python.exe"
- $ToolchainBin = Join-Path $ToolchainRoot "bin"
- $ToolchainLib = Join-Path $ToolchainRoot "lib"
- $VerilatorRoot = Join-Path $ToolchainRoot "share\verilator"
- $Smtbmc = Join-Path $ToolchainRoot "bin\yosys-smtbmc.exe.exe"
- $env:PID_STUDY_TOOLCHAIN_ROOT = $ToolchainRoot
- $env:OSS_CAD_SUITE_ROOT = $ToolchainRoot
- $env:PID_STUDY_COCOTB_PYTHON = $CocotbPython
- if (Test-Path -LiteralPath $VerilatorRoot) {
- $env:VERILATOR_ROOT = $VerilatorRoot
- }
- if (Test-Path -LiteralPath $Smtbmc) {
- $env:SMTBMC = $Smtbmc
- }
- if (Test-Path -LiteralPath $ToolchainBin) {
- $pathParts = $env:PATH -split ";"
- if ($pathParts -notcontains $ToolchainBin) {
- $env:PATH = "$ToolchainBin;$env:PATH"
- }
- }
- if (Test-Path -LiteralPath $ToolchainLib) {
- $pathParts = $env:PATH -split ";"
- if ($pathParts -notcontains $ToolchainLib) {
- $env:PATH = "$ToolchainLib;$env:PATH"
- }
- }
- Write-Host "PID verification toolchain variables set for current PowerShell session."
- Write-Host "PID_STUDY_TOOLCHAIN_ROOT=$env:PID_STUDY_TOOLCHAIN_ROOT"
- Write-Host "PID_STUDY_COCOTB_PYTHON=$env:PID_STUDY_COCOTB_PYTHON"
|