-
Notifications
You must be signed in to change notification settings - Fork 119
ci: add ARM64 Windows runner support to workflows #420
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
wmmc88
merged 40 commits into
microsoft:main
from
krishnakumar4a4:364-ci-workflows-with-arm-based-runners
Aug 15, 2025
Merged
Changes from all commits
Commits
Show all changes
40 commits
Select commit
Hold shift + click to select a range
47793be
ci: add ARM64 Windows runner support to workflows
krishnakumar4a4 d9f9324
ci: adapt for nuget wdk changes
krishnakumar4a4 86f6cb7
ci: replace winget install with powershell script
krishnakumar4a4 a1113a7
ci: remove unnecessary targets from certain workflows
krishnakumar4a4 4922ef9
debug: add PATH env variable printing and include tmate
krishnakumar4a4 631e301
debug: install winget using recommended method
krishnakumar4a4 165ce47
Revert "debug: install winget using recommended method"
krishnakumar4a4 5436c8d
Revert "debug: add PATH env variable printing and include tmate"
krishnakumar4a4 8ead94f
ci: skip certain jobs/steps when WDK is 10.0.22621 and runner is arm6…
krishnakumar4a4 0c2f544
ci: move to older way of installing winget
krishnakumar4a4 9e99c45
debug: modify winget-install to install latest winget using different…
krishnakumar4a4 9eff661
ci: add arm64 support for codeql and doc workflows
krishnakumar4a4 b827dc5
Update crates/cargo-wdk/tests/wdm-driver/src/lib.rs
krishnakumar4a4 f2fe66d
ci: add --all-targets back to cargo clippy and remove old comment
krishnakumar4a4 23b9b41
debug: add target_triple back to test and local-development-makefile …
krishnakumar4a4 119f307
ci: revert arm64 support for codeql
krishnakumar4a4 1ea9662
ci: revert target_triple from test workflow
krishnakumar4a4 6df0f87
ci: revert target_triple from wdk-pre-commit-hook workflow
krishnakumar4a4 5ae1a14
ci: centralized cert tools present check to env var in build workflow
krishnakumar4a4 55d5a5c
ci: make arch names consistent in workflows
krishnakumar4a4 c774633
ci: moved LLVM installation to an action
krishnakumar4a4 9f2480a
Apply suggestion from @gurry
krishnakumar4a4 3648b0a
Apply suggestion from @gurry
krishnakumar4a4 84e0bfd
ci: refactor winget-install action
krishnakumar4a4 e43884d
ci: move to windows-2025 for x64 as winget comes pre installed
krishnakumar4a4 e3b30f1
debug: include tmate to debug windows-2025 has certmgr.exe
krishnakumar4a4 978b2fe
Revert "debug: include tmate to debug windows-2025 has certmgr.exe"
krishnakumar4a4 a3f6119
Revert "ci: move to windows-2025 for x64 as winget comes pre installed"
krishnakumar4a4 ffed717
debug: revert linker fix from wdm-driver
krishnakumar4a4 4c2c3db
debug: remove linker fix from wdm driver template
krishnakumar4a4 db9a000
debug: revert target changes from test workflow to reprod linker issue
krishnakumar4a4 f5d3d9f
debug: coment out job exclusion criteria in test workflow
krishnakumar4a4 613d9d2
ci: revert changes to test workflow post debugging linker issue
krishnakumar4a4 6880f8a
ci: rename winget-install to install-winget for consistency
krishnakumar4a4 cc923ec
ci: refactor install-winget action temp path construction
krishnakumar4a4 c810cf5
ci: update comment for unable to install SDK scenario
krishnakumar4a4 ea30711
copilot: use tag instead of release number for winget installation
krishnakumar4a4 86462bd
ci: add sdk installation step to install-wdk action and also addresse…
krishnakumar4a4 c7cd0a5
ci: change installation method for 10.0.22621 SDK
krishnakumar4a4 def6187
ci: fix wdk and LLVM installation
krishnakumar4a4 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| name: Install LLVM | ||
|
|
||
| inputs: | ||
| version: | ||
| description: "LLVM version to install" | ||
| required: true | ||
|
|
||
| runs: | ||
| using: "composite" | ||
| steps: | ||
| - name: Install LLVM ${{ inputs.version }} | ||
| shell: pwsh | ||
| run: | | ||
| if ((Get-WinGetPackage -Id LLVM -Source winget -MatchOption Equals).InstalledVersion -eq '${{ inputs.version }}') { | ||
| Write-Host "LLVM ${{ inputs.version }} is already installed." | ||
| } else { | ||
| Write-Host "Installing LLVM ${{ inputs.version }}..." | ||
| Install-WinGetPackage -Id LLVM.LLVM -Version ${{ inputs.version }} -Source winget -MatchOption Equals -Mode Silent -Force | ||
|
|
||
| # Check if WinGet installation succeeded | ||
| $installSuccess = $? | ||
| if (-not $installSuccess) { | ||
| Write-Error "LLVM installation failed. Last exit code: $LASTEXITCODE and success status: $installSuccess" | ||
| exit 1 | ||
| } | ||
| } | ||
|
|
||
| clang --version | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
krishnakumar4a4 marked this conversation as resolved.
Show resolved
Hide resolved
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,81 @@ | ||
| name: "Install Winget" | ||
| description: "Install winget on windows runners since its not installed by default: https://github.com/actions/runner-images/issues/6472" | ||
| inputs: | ||
| GITHUB_TOKEN: | ||
| description: "GitHub token to execute authenticated Github API requests (for higher rate limit)" | ||
| required: true | ||
| runs: | ||
| using: "composite" | ||
| steps: | ||
| - name: Get URIs for Winget v1.11.400 assets | ||
wmmc88 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| shell: pwsh | ||
| run: | | ||
| $AuthenticatedHeaders = @{ "Authorization" = "Bearer ${{ inputs.GITHUB_TOKEN }}" } | ||
|
|
||
| # Detect runner architecture | ||
| $Architecture = if ($env:RUNNER_ARCH -eq "ARM64") { "arm64" } else { "x64" } | ||
| Write-Host "Runner architecture: $Architecture" | ||
|
|
||
| # winget-cli release v1.11.400 | ||
| # Define the winget-cli release tag to use | ||
| $WingetReleaseTag = "v1.11.400" | ||
| # Fetch release info by tag instead of magic number release ID | ||
| $ReleaseInfo = Invoke-RestMethod -Headers $AuthenticatedHeaders "https://api.github.com/repos/microsoft/winget-cli/releases/tags/$WingetReleaseTag" | ||
| $WingetDownloadUri = $ReleaseInfo.assets.browser_download_url | Where-Object { $_.EndsWith('.msixbundle') } | ||
| $WingetLicenseDownloadUri = $ReleaseInfo.assets.browser_download_url | Where-Object { $_.EndsWith('License1.xml') } | ||
| $WingetDependenciesZipDownloadUri = $ReleaseInfo.assets.browser_download_url | Where-Object { $_.EndsWith('DesktopAppInstaller_Dependencies.zip') } | ||
|
|
||
| # Print to logs | ||
| Write-Host "WingetDownloadUri=$WingetDownloadUri" | ||
| Write-Host "WingetLicenseDownloadUri=$WingetLicenseDownloadUri" | ||
| Write-Host "WingetDependenciesZipDownloadUri=$WingetDependenciesZipDownloadUri" | ||
|
|
||
| # Save output for next step | ||
| Write-Output "WingetDownloadUri=$WingetDownloadUri" >> $env:GITHUB_ENV | ||
| Write-Output "WingetLicenseDownloadUri=$WingetLicenseDownloadUri" >> $env:GITHUB_ENV | ||
| Write-Output "Architecture=$Architecture" >> $env:GITHUB_ENV | ||
| Write-Output "WingetDependenciesZipDownloadUri=$WingetDependenciesZipDownloadUri" >> $env:GITHUB_ENV | ||
| Write-Output "InstallWingetTempDir=$env:RUNNER_TEMP/install-winget" >> $env:GITHUB_ENV | ||
|
|
||
| - name: Download Winget Assets and Dependencies | ||
| shell: pwsh | ||
| run: | | ||
| New-Item -Type Directory $env:InstallWingetTempDir | ||
krishnakumar4a4 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| # Download winget and license (architecture-agnostic) | ||
| Invoke-WebRequest -Headers $AuthenticatedHeaders -Uri $env:WingetDownloadUri -OutFile $env:InstallWingetTempDir/winget.msixbundle | ||
| Invoke-WebRequest -Headers $AuthenticatedHeaders -Uri $env:WingetLicenseDownloadUri -OutFile $env:InstallWingetTempDir/license.xml | ||
| Invoke-WebRequest -Headers $AuthenticatedHeaders -Uri $env:WingetDependenciesZipDownloadUri -OutFile $env:InstallWingetTempDir/DesktopAppInstaller_Dependencies.zip | ||
|
|
||
| Expand-Archive -Path "$env:InstallWingetTempDir/DesktopAppInstaller_Dependencies.zip" -DestinationPath $env:InstallWingetTempDir/ -Force | ||
|
|
||
| - name: Start Winget Installation for all Users | ||
| shell: pwsh | ||
| run: | | ||
| # Use architecture-specific dependency paths | ||
| [string[]]$DependencyPaths = (Get-ChildItem -Path "$env:InstallWingetTempDir/$env:Architecture" -Filter '*.appx' -File -Force).FullName | ||
|
|
||
| $MicrosoftUIXamlDep = $($DependencyPaths[0]) | ||
| $MicrosoftVCLibsDep = $($DependencyPaths[1]) | ||
|
|
||
| Write-Host "Found Dependency $MicrosoftUIXamlDep" | ||
| Write-Host "Found Dependency $MicrosoftVCLibsDep" | ||
|
|
||
| Add-AppxProvisionedPackage -Online -PackagePath $env:InstallWingetTempDir/winget.msixbundle -LicensePath $env:InstallWingetTempDir/license.xml -DependencyPackagePath "$MicrosoftUIXamlDep", "$MicrosoftVCLibsDep" | ||
|
|
||
| - name: Install Winget for Current User (for better install diagnostics) | ||
| shell: powershell | ||
| run: | | ||
| Add-AppxPackage $env:InstallWingetTempDir/winget.msixbundle | ||
|
|
||
| - name: Wait for Completion of Winget Installation | ||
| shell: pwsh | ||
| run: | | ||
| while ((Get-Command * | Select-String winget)?.ToString() -ne "winget.exe") { | ||
| Start-Sleep -Seconds 1 | ||
| } | ||
| Write-Output "Winget Version: $(winget --version)" | ||
|
|
||
| - name: Install winget Powershell Module | ||
| shell: pwsh | ||
| run: Install-Module -Name Microsoft.WinGet.Client -Repository PSGallery -Force | ||
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.