@@ -233,6 +233,11 @@ function Write-ColoredGHDLLine
233233 Write-Host " ${Indent} ERROR: " - NoNewline - ForegroundColor Red
234234 Write-Host $InputObject
235235 }
236+ elseif ($InputObject -match " :error:\s" )
237+ { $ErrorRecordFound = $true
238+ Write-Host " ${Indent} ERROR: " - NoNewline - ForegroundColor Red
239+ Write-Host $InputObject
240+ }
236241 else
237242 { Write-Host " ${Indent}$InputObject " }
238243 }
@@ -266,13 +271,13 @@ function Start-Analyze
266271 [Parameter (Mandatory = $true )][string []]$SourceFiles ,
267272 [Parameter (Mandatory = $true )][bool ]$HaltOnError
268273 )
269- Write-Host " Compiling library '$Library ' ..." - ForegroundColor Yellow
274+ # Write-Host "Compiling library '$Library' ..." -ForegroundColor Yellow
270275 $ErrorCount = 0
271276 foreach ($File in $SourceFiles )
272277 { # Write-Host "Analyzing file '$File'" -ForegroundColor DarkCyan
273278 $InvokeExpr = " $GHDLBinary " + ($GHDLOptions -join " " ) + " --work=$Library " + $File + " 2>&1"
274279 # Write-Host " $InvokeExpr" -ForegroundColor DarkGray
275- $ErrorRecordFound = Invoke-Expression $InvokeExpr | Restore-NativeCommandStream | Write-ColoredGHDLLine $SuppressWarnings
280+ $ErrorRecordFound = Invoke-Expression $InvokeExpr | Restore-NativeCommandStream | Write-ColoredGHDLLine $SuppressWarnings " "
276281 if ($LastExitCode -ne 0 )
277282 { $ErrorCount += 1
278283 if ($HaltOnError )
@@ -308,7 +313,7 @@ function Start-Execution
308313 # Write-Host "Executing '$TopLevel'" -ForegroundColor DarkCyan
309314 $InvokeExpr = " $GHDLBinary " + ($GHDLOptions -join " " ) + " --work=$Library " + $TopLevel + " 2>&1"
310315 # Write-Host " $InvokeExpr" -ForegroundColor DarkGray
311- $ErrorRecordFound = Invoke-Expression $InvokeExpr | Restore-NativeCommandStream | Write-ColoredGHDLLine $SuppressWarnings
316+ $ErrorRecordFound = Invoke-Expression $InvokeExpr | Restore-NativeCommandStream | Write-ColoredGHDLLine $SuppressWarnings " "
312317 if ($LastExitCode -ne 0 )
313318 { $ErrorCount += 1
314319 if ($HaltOnError )
@@ -352,14 +357,15 @@ if ($GHDL)
352357 $FileNames = dir - Path ./ test_parsing * .json | Sort-Object - Property Name
353358 $TestCase = 0
354359 foreach ($File in $FileNames )
355- { $TestName = $File.Name.TrimEnd (" .json" )
356- $SourceFile = " $SourceDirectory \$File "
360+ { $TestCase += 1
361+ $TestName = $File.Name.TrimEnd (" .json" )
362+ $SourceFile = " $SourceDirectory \$File "
363+ $Library = " test_$TestCase "
357364
365+ Write-Host (" Test: {0,-50} VHDL library: {1}" -f $TestName , $Library ) - ForegroundColor DarkCyan
358366 $ConfigPackageContent = " package config is`n`t constant C_JSON_FILE : STRING := `" $SourceFile `" ;`n end package;"
359367 $ConfigPackageContent | Out-File $ConfigPackageFile - Encoding Ascii
360368
361- $TestCase += 1
362- $Library = " test_$TestCase "
363369 $SourceFiles = (
364370 $ConfigPackageFile ,
365371 " TopLevel.vhdl"
0 commit comments