From 643e77da59b09d2233a92ff4e83da26465b3ac90 Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Thu, 6 Nov 2025 21:49:22 +0100 Subject: [PATCH 1/9] Get libigc version from Windows driver --- scripts/capture-hw-details.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index c0e8f00678..2790121393 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -20,7 +20,7 @@ done function libigc_version { if [[ $OSTYPE = msys ]]; then - powershell -Command "(Get-ChildItem c:/Windows/System32/DriverStore/FileRepository/*/igc64.dll).VersionInfo.ProductVersion" + powershell -Command "(Get-WmiObject Win32_VideoController | where {$_.VideoProcessor -like "*Intel*" }).DriverVersion" return fi if dpkg-query --show libigc2 &> /dev/null; then From 579e781bc20d74be06597ea13f7c8f226323a246 Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Thu, 6 Nov 2025 21:54:47 +0100 Subject: [PATCH 2/9] Show highest libigc version from the driver store --- scripts/capture-hw-details.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index 2790121393..cd259ad0c3 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -20,7 +20,7 @@ done function libigc_version { if [[ $OSTYPE = msys ]]; then - powershell -Command "(Get-WmiObject Win32_VideoController | where {$_.VideoProcessor -like "*Intel*" }).DriverVersion" + powershell -Command "(Get-ChildItem c:/Windows/System32/DriverStore/FileRepository/*/igc64.dll | Sort-Object LastWriteTime -Descending | Select-Object -First 1).VersionInfo.ProductVersion" return fi if dpkg-query --show libigc2 &> /dev/null; then From 44ee766a507957d06e2e1cc2e6721a53db714a66 Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Thu, 6 Nov 2025 22:31:41 +0100 Subject: [PATCH 3/9] Get igc64.dll version from the currently loaded driver --- scripts/capture-hw-details.sh | 36 ++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index cd259ad0c3..e38dc98909 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -20,7 +20,41 @@ done function libigc_version { if [[ $OSTYPE = msys ]]; then - powershell -Command "(Get-ChildItem c:/Windows/System32/DriverStore/FileRepository/*/igc64.dll | Sort-Object LastWriteTime -Descending | Select-Object -First 1).VersionInfo.ProductVersion" + powershell -Command " + try { + \$intel = Get-PnpDevice -Class Display -PresentOnly | Where-Object { \$_.FriendlyName -like '*Intel*' } | Select-Object -First 1 + if (-not \$intel) { throw 'No Intel display adapter' } + + # Get the bound signed driver (gives us oemXX.inf) + \$drv = Get-CimInstance Win32_PnPSignedDriver | Where-Object { \$_.DeviceID -eq \$intel.InstanceId } | Select-Object -First 1 + if (-not \$drv) { throw 'No signed driver record' } + \$oemInf = \$drv.InfName # e.g. oem42.inf + + # Extract the Original Name from the oem*.inf (DCH packages keep it) + \$origLine = Select-String -Path (Join-Path \$env:windir 'INF' \$oemInf) -Pattern 'Original Name' -ErrorAction SilentlyContinue | Select-Object -First 1 + if (\$origLine) { + \$originalInf = (\$origLine.Line -replace '.*Original Name\\s*-\\s*','').Trim() + } else { + # Fallback: if missing, guess by scanning for iigd_dch.inf style directories containing igc64.dll + \$originalInf = 'iigd_dch.inf' + } + + # Locate matching driver store directory + \$dir = Get-ChildItem (Join-Path \$env:windir 'System32\\DriverStore\\FileRepository') -Directory -Filter \"\$originalInf*amd64*\" 2>\$null | + Where-Object { Test-Path (Join-Path \$_.FullName 'igc64.dll') } | + Sort-Object LastWriteTime -Descending | + Select-Object -First 1 + + if (-not \$dir) { throw 'No driver store directory with igc64.dll' } + + \$dll = Join-Path \$dir.FullName 'igc64.dll' + if (-not (Test-Path \$dll)) { throw 'igc64.dll missing in chosen directory' } + + (Get-Item \$dll).VersionInfo.ProductVersion + } catch { + 'Not Found' + } + " return fi if dpkg-query --show libigc2 &> /dev/null; then From 111995cf06f3e64514ce12a22e4bbd3f4316d0b6 Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Thu, 6 Nov 2025 23:16:04 +0100 Subject: [PATCH 4/9] Use pwsh for libigc_version --- scripts/capture-hw-details.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index e38dc98909..a58e992394 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -20,7 +20,7 @@ done function libigc_version { if [[ $OSTYPE = msys ]]; then - powershell -Command " + pwsh -Command " try { \$intel = Get-PnpDevice -Class Display -PresentOnly | Where-Object { \$_.FriendlyName -like '*Intel*' } | Select-Object -First 1 if (-not \$intel) { throw 'No Intel display adapter' } From f5a539b2e4e1221852d283bfbc672b29df3315da Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Mon, 10 Nov 2025 19:22:26 +0100 Subject: [PATCH 5/9] Get igc version from dwm.exe --- scripts/capture-hw-details.sh | 44 ++++++++--------------------------- 1 file changed, 10 insertions(+), 34 deletions(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index a58e992394..8f075de818 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -20,41 +20,17 @@ done function libigc_version { if [[ $OSTYPE = msys ]]; then - pwsh -Command " - try { - \$intel = Get-PnpDevice -Class Display -PresentOnly | Where-Object { \$_.FriendlyName -like '*Intel*' } | Select-Object -First 1 - if (-not \$intel) { throw 'No Intel display adapter' } - - # Get the bound signed driver (gives us oemXX.inf) - \$drv = Get-CimInstance Win32_PnPSignedDriver | Where-Object { \$_.DeviceID -eq \$intel.InstanceId } | Select-Object -First 1 - if (-not \$drv) { throw 'No signed driver record' } - \$oemInf = \$drv.InfName # e.g. oem42.inf - - # Extract the Original Name from the oem*.inf (DCH packages keep it) - \$origLine = Select-String -Path (Join-Path \$env:windir 'INF' \$oemInf) -Pattern 'Original Name' -ErrorAction SilentlyContinue | Select-Object -First 1 - if (\$origLine) { - \$originalInf = (\$origLine.Line -replace '.*Original Name\\s*-\\s*','').Trim() - } else { - # Fallback: if missing, guess by scanning for iigd_dch.inf style directories containing igc64.dll - \$originalInf = 'iigd_dch.inf' + pwsh -Command " + $igc = @(Get-Process -Name dwm -Module | Where-Object ModuleName -eq 'igc64.dll') + if ($igc.Count -gt 1) { + Write-Host "MULTIPLE" } - - # Locate matching driver store directory - \$dir = Get-ChildItem (Join-Path \$env:windir 'System32\\DriverStore\\FileRepository') -Directory -Filter \"\$originalInf*amd64*\" 2>\$null | - Where-Object { Test-Path (Join-Path \$_.FullName 'igc64.dll') } | - Sort-Object LastWriteTime -Descending | - Select-Object -First 1 - - if (-not \$dir) { throw 'No driver store directory with igc64.dll' } - - \$dll = Join-Path \$dir.FullName 'igc64.dll' - if (-not (Test-Path \$dll)) { throw 'igc64.dll missing in chosen directory' } - - (Get-Item \$dll).VersionInfo.ProductVersion - } catch { - 'Not Found' - } - " + elseif ($igc.Count -eq 1) { + $igc[0].FileVersionInfo.FileVersion + } + else { + Write-Host "Not Found" + }" return fi if dpkg-query --show libigc2 &> /dev/null; then From 79ebfbdd01021a5acba5b10a4dae54cca1573fff Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Mon, 10 Nov 2025 19:55:03 +0100 Subject: [PATCH 6/9] Fix powershell --- scripts/capture-hw-details.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index 8f075de818..4dbc6fa0dd 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -26,7 +26,7 @@ function libigc_version { Write-Host "MULTIPLE" } elseif ($igc.Count -eq 1) { - $igc[0].FileVersionInfo.FileVersion + Write-Host $igc[0].FileVersionInfo.FileVersion } else { Write-Host "Not Found" From af755b263a2703d0c49253eac45de40c7db1f407 Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Mon, 10 Nov 2025 20:14:14 +0100 Subject: [PATCH 7/9] Fix quoting --- scripts/capture-hw-details.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index 4dbc6fa0dd..ff3c605f2d 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -20,7 +20,7 @@ done function libigc_version { if [[ $OSTYPE = msys ]]; then - pwsh -Command " + pwsh -Command ' $igc = @(Get-Process -Name dwm -Module | Where-Object ModuleName -eq 'igc64.dll') if ($igc.Count -gt 1) { Write-Host "MULTIPLE" @@ -30,7 +30,7 @@ function libigc_version { } else { Write-Host "Not Found" - }" + }' return fi if dpkg-query --show libigc2 &> /dev/null; then From 87223d59a395c4d4dd8288128b73fa9ad0d2133b Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Wed, 12 Nov 2025 18:55:58 +0100 Subject: [PATCH 8/9] Handle multiple dwms --- scripts/capture-hw-details.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index ff3c605f2d..e2eb515f9e 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -21,12 +21,12 @@ done function libigc_version { if [[ $OSTYPE = msys ]]; then pwsh -Command ' - $igc = @(Get-Process -Name dwm -Module | Where-Object ModuleName -eq 'igc64.dll') + $igc = @(Get-Process -Name dwm -Module | Where-Object ModuleName -eq 'igc64.dll').FileVersionInfo.FileVersion | Sort-Object -Unique if ($igc.Count -gt 1) { Write-Host "MULTIPLE" } elseif ($igc.Count -eq 1) { - Write-Host $igc[0].FileVersionInfo.FileVersion + Write-Host $igc[0] } else { Write-Host "Not Found" From 72dae64f5af2eca1668f7c2f44df928876cd3d2f Mon Sep 17 00:00:00 2001 From: Vadim Musin Date: Wed, 12 Nov 2025 22:57:27 +0100 Subject: [PATCH 9/9] Handle multiple dwms --- scripts/capture-hw-details.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/capture-hw-details.sh b/scripts/capture-hw-details.sh index e2eb515f9e..8e9d425012 100755 --- a/scripts/capture-hw-details.sh +++ b/scripts/capture-hw-details.sh @@ -26,7 +26,7 @@ function libigc_version { Write-Host "MULTIPLE" } elseif ($igc.Count -eq 1) { - Write-Host $igc[0] + Write-Host $igc } else { Write-Host "Not Found"