@@ -556,6 +556,16 @@ jobs:
556556 with :
557557 workspaces : host -> target
558558
559+ - name : Ensure surrogate build consistency
560+ shell : pwsh
561+ run : |
562+ $hlsExe = "host\target\release\build\hyperlight-host-*\out\..\..\hls\x86_64-pc-windows-msvc\release\hyperlight_surrogate.exe"
563+ if (-not (Resolve-Path $hlsExe -ErrorAction SilentlyContinue)) {
564+ Write-Host "Surrogate missing — clearing hyperlight-host fingerprints to force rebuild"
565+ Get-ChildItem "host\target\release\.fingerprint" -Filter "hyperlight-host-*" -Directory -ErrorAction SilentlyContinue |
566+ Remove-Item -Recurse -Force
567+ }
568+
559569 - name : Build host binaries
560570 shell : pwsh
561571 run : |
@@ -662,6 +672,17 @@ jobs:
662672 with :
663673 workspaces : host -> target
664674
675+ - name : Ensure surrogate build consistency (Windows only)
676+ if : runner.os == 'Windows'
677+ shell : pwsh
678+ run : |
679+ $hlsExe = "host\target\release\build\hyperlight-host-*\out\..\..\hls\x86_64-pc-windows-msvc\release\hyperlight_surrogate.exe"
680+ if (-not (Resolve-Path $hlsExe -ErrorAction SilentlyContinue)) {
681+ Write-Host "Surrogate missing — clearing hyperlight-host fingerprints to force rebuild"
682+ Get-ChildItem "host\target\release\.fingerprint" -Filter "hyperlight-host-*" -Directory -ErrorAction SilentlyContinue |
683+ Remove-Item -Recurse -Force
684+ }
685+
665686 # Linux needs /dev/kvm access to run the guest.
666687 - name : Enable KVM permissions (Linux only)
667688 if : runner.os == 'Linux'
@@ -683,12 +704,20 @@ jobs:
683704 echo "::warning::/dev/kvm is not available; pyhl test skipped"
684705 fi
685706
686- - name : Install pyhl
707+ - name : Install pyhl (Linux)
708+ if : runner.os == 'Linux'
709+ run : |
710+ cd host
711+ cargo build --release --bin pyhl
712+ sudo cp target/release/pyhl /usr/local/bin/
713+
714+ - name : Install pyhl (Windows)
715+ if : runner.os == 'Windows'
687716 shell : pwsh
688717 run : |
689718 cd host
690719 cargo build --release --bin pyhl
691- Copy-Item target/ release/ pyhl* $env:USERPROFILE/ .cargo/ bin/ -Force
720+ Copy-Item target\ release\ pyhl.exe $env:USERPROFILE\ .cargo\ bin\ -Force
692721
693722 - name : Download prebuilt python-agent-driver image
694723 uses : actions/download-artifact@v4
@@ -768,7 +797,7 @@ jobs:
768797 exit 1
769798 }
770799
771- all-checks -passed :
800+ test-examples -passed :
772801 if : always()
773802 needs : [build-example, runtime-test, package-images-for-windows, runtime-test-windows, pyhl-snapshot-test]
774803 runs-on : ubuntu-latest
0 commit comments