a9cca82fb8
windows-drivers-provision / provision (push) Successful in 13s
windows-drivers / probe-and-proto (push) Successful in 17s
android / android (push) Failing after 40s
apple / swift (push) Successful in 1m0s
ci / web (push) Successful in 58s
windows-drivers / driver-build (push) Successful in 1m9s
ci / docs-site (push) Successful in 1m18s
ci / rust (push) Successful in 4m25s
apple / screenshots (push) Successful in 5m24s
deb / build-publish (push) Successful in 2m29s
decky / build-publish (push) Successful in 11s
docker / build-push (--build-arg FEDORA_VERSION=44, ci, ci/fedora-rpm.Dockerfile, punktfunk-fedora44-rpm) (push) Successful in 6s
docker / build-push (., web/Dockerfile, punktfunk-web) (push) Successful in 29s
ci / bench (push) Successful in 4m48s
docker / build-push (ci, ci/fedora-rpm.Dockerfile, punktfunk-fedora-rpm) (push) Successful in 4s
docker / build-push (docs-site, docs-site/Dockerfile, punktfunk-docs) (push) Successful in 5s
docker / build-push (ci, ci/rust-ci.Dockerfile, punktfunk-rust-ci) (push) Successful in 5s
windows-host / package (push) Successful in 6m38s
rpm / build-publish (bazzite, punktfunk-fedora-rpm) (push) Successful in 9m24s
rpm / build-publish (fedora-44, punktfunk-fedora44-rpm) (push) Successful in 9m31s
docker / deploy-docs (push) Successful in 18s
Now that the drivers build from source in CI, remove the dead checked-in binaries and
the toolchain cruft they left behind:
- Delete packaging/windows/{pf-vdisplay,gamepad-drivers}/ (the prebuilt .dll/.inf/.cat/.cer).
pack-host-installer.ps1 builds + signs all three drivers from the drivers/ workspace and
nothing reads the vendored dirs anymore; stage-pf-vdisplay.ps1's -VendorDir is now a
mandatory build-output path, not a vendored default.
- Drop the LLVM-21 pin. The vendored bindgen 0.71->0.72 bump (the shipping pack already
builds green on the runner-default clang 22) retired the bindgen-0.71 layout-test overflow
that needed LLVM 21.1.2, so windows-drivers.yml + provision-windows-wdk.ps1 no longer
install/point at C:\llvm-21 (~898 MB off a fresh provision) - both driver builds now use one
toolchain (clang 22 + bindgen 0.72).
- pack -SkipBuild on the gamepad build (build-pf-vdisplay.ps1 already builds the whole
workspace), build-web.ps1 reaps a stale node too, deploy-dev.ps1 nefconc path + comments.
- Reword the vendored-driver references (build scripts, .iss, READMEs, the vite web-bundle
comment) to the build-from-source reality.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
81 lines
4.0 KiB
PowerShell
81 lines
4.0 KiB
PowerShell
#requires -Version 5.1
|
|
<#
|
|
.SYNOPSIS
|
|
Build-stage-sign-install the NEW-tree pf-vdisplay UMDF IddCx driver (packaging/windows/drivers/) for
|
|
local dev/test on the RTX box. The wdk-sys / windows-drivers-rs analogue of the superseded
|
|
vdisplay-driver/deploy-dev.ps1.
|
|
|
|
.DESCRIPTION
|
|
Stages the freshly built pf_vdisplay.dll, CLEARS its FORCE_INTEGRITY PE bit (this tree's wdk-build links
|
|
/INTEGRITYCHECK, which a self-signed cert can't satisfy — the old wdf-umdf tree didn't), signs it with
|
|
the self-signed test cert, stamps a STRICTLY-INCREASING DriverVer into the INF, generates + signs the
|
|
catalog, and (with -Install) pnputil-installs it.
|
|
|
|
Build first: from packaging/windows/drivers/, in an MSVC dev shell with LIBCLANG_PATH +
|
|
Version_Number=10.0.26100.0, run `cargo build`.
|
|
|
|
Re-deploying needs a HIGHER DriverVer than the installed one or pnputil silently keeps the old binary —
|
|
hence the 9.9.MMdd.HHmm scheme (also what the installer build uses; a later-minute dev redeploy wins).
|
|
If the host service is running it holds the driver: `punktfunk-host service stop`, deploy, then start it.
|
|
.PARAMETER Install
|
|
Also add the driver package to the store + (if absent) create the Root\pf_vdisplay devnode via nefconc.
|
|
Needs an ELEVATED shell.
|
|
#>
|
|
[CmdletBinding()]
|
|
param(
|
|
[string]$Stage = 'C:\Users\Public\pfvd-stage-deploy',
|
|
[string]$Thumbprint = '6A52984E54376C45A1C236B1A2C8A746C5AB6131',
|
|
[string]$Nefconc = 'C:\Users\Public\nefcon\x64\nefconc.exe', # pinned nefcon (stage-pf-vdisplay.ps1 fetches it)
|
|
[switch]$Install
|
|
)
|
|
$ErrorActionPreference = 'Stop'
|
|
|
|
$root = Split-Path -Parent $MyInvocation.MyCommand.Path
|
|
$dll = Join-Path $root 'target\x86_64-pc-windows-msvc\debug\pf_vdisplay.dll'
|
|
$inx = Join-Path $root 'pf-vdisplay\pf_vdisplay.inx'
|
|
$clear = Join-Path $root '..\clear-force-integrity.ps1'
|
|
if (-not (Test-Path $dll)) { throw "driver not built: $dll (cargo build in packaging/windows/drivers first)" }
|
|
|
|
$kits = 'C:\Program Files (x86)\Windows Kits\10\bin'
|
|
function Find-Tool([string]$name, [string]$arch) {
|
|
(Get-ChildItem "$kits\*\$arch\$name" -EA SilentlyContinue | Sort-Object FullName | Select-Object -Last 1).FullName
|
|
}
|
|
$signtool = Find-Tool 'signtool.exe' 'x64'
|
|
$stampinf = Find-Tool 'stampinf.exe' 'x64'
|
|
$inf2cat = Find-Tool 'Inf2Cat.exe' 'x86'
|
|
foreach ($t in @($signtool, $stampinf, $inf2cat)) { if (-not $t) { throw 'a WDK tool (signtool/stampinf/Inf2Cat) was not found' } }
|
|
|
|
if (Test-Path $Stage) { Remove-Item $Stage -Recurse -Force }
|
|
New-Item -ItemType Directory -Force -Path $Stage | Out-Null
|
|
$stagedDll = Join-Path $Stage 'pf_vdisplay.dll'
|
|
$stagedInf = Join-Path $Stage 'pf_vdisplay.inf'
|
|
$stagedCat = Join-Path $Stage 'pf_vdisplay.cat'
|
|
Copy-Item $dll $stagedDll -Force
|
|
Copy-Item $inx $stagedInf -Force # stampinf rewrites this copy in place
|
|
|
|
# Clear FORCE_INTEGRITY BEFORE signing (the clear edits the PE, which invalidates any signature).
|
|
& $clear -Path $stagedDll | Out-Null
|
|
|
|
# DriverVer must strictly increase past whatever is installed; 9.9.MMdd.HHmm bumps every minute.
|
|
$now = Get-Date
|
|
$ver = '9.9.{0}.{1}' -f $now.ToString('MMdd'), $now.ToString('HHmm')
|
|
|
|
& $signtool sign /fd SHA256 /sha1 $Thumbprint $stagedDll | Out-Null
|
|
& $stampinf -f $stagedInf -d '*' -a 'amd64' -u '2.15.0' -v $ver | Out-Null
|
|
& $inf2cat /driver:$Stage /os:10_X64 /uselocaltime | Out-Null
|
|
& $signtool sign /fd SHA256 /sha1 $Thumbprint $stagedCat | Out-Null
|
|
Write-Host "staged + signed pf-vdisplay (new tree) DriverVer=$ver -> $Stage"
|
|
|
|
if ($Install) {
|
|
& pnputil /add-driver $stagedInf /install
|
|
$present = Get-PnpDevice -EA SilentlyContinue |
|
|
Where-Object { $_.InstanceId -match 'PF_VDISPLAY' -or $_.FriendlyName -match 'punktfunk Virtual Display' }
|
|
if (-not $present) {
|
|
if (-not (Test-Path $Nefconc)) { throw "nefconc not found: $Nefconc" }
|
|
& $Nefconc --create-device-node --hardware-id 'root\pf_vdisplay' --class-name Display --class-guid '{4d36e968-e325-11ce-bfc1-08002be10318}' | Out-Null
|
|
Start-Sleep 2
|
|
& pnputil /add-driver $stagedInf /install
|
|
}
|
|
Write-Host "installed pf-vdisplay DriverVer=$ver"
|
|
}
|