Make NativeAOT the default for UniGetUI release packages on all targets#5062
Merged
Conversation
…orms - Enable PublishAot=true for Release builds in Avalonia csproj and disable conflicting PublishReadyToRun when NativeAOT is active. - Add NativeAOT publish profiles for win-arm64, osx-x64, osx-arm64, linux-x64 and linux-arm64. - Update build-release.yml to publish every platform with NativeAOT profiles. - Harden dotnet-test.yml NativeAOT publish report (no longer ignored). - Capture per-platform uncompressed and compressed artifact sizes in CI. - Add NativeAOT variants to CLI headless E2E workflow. - Support avalonia-native daemon kind in E2E runner for NativeAOT Linux. - Update publish-nativeaot.ps1 to support arm64 and README documentation. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The default ubuntu-latest runner does not include the aarch64 cross- compilation toolchain required for linux-arm64 NativeAOT. Keep NativeAOT for linux-x64 and fall back to the existing ReadyToRun/full-trim path for linux-arm64 until cross-compilation is available. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The publish step now uses PowerShell syntax for profile selection and NativeAOT fallback handling, so it must run under pwsh on macOS/Linux. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The per-platform size JSONs are already captured during packaging. Add a standalone size-report job that downloads all artifacts, consolidates the sizes into a markdown table, and uploads it. This runs even in dry-run mode so size comparisons are available before a real release. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The fallback disables NativeAOT because the hosted x64 runner cannot cross-compile NativeAOT for linux-arm64. The resulting build is the previous non-NativeAOT self-contained path; update the comment so it is not misread as a guaranteed ReadyToRun fallback. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Install the Linux arm64 cross toolchain on the x64 Ubuntu release runner and use the linux-arm64 NativeAOT publish profile instead of falling back to the non-AOT self-contained path. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Remove large .dbg/.pdb files from Linux release payloads before packaging, matching the existing Windows behavior of not shipping oversized debug symbols in release artifacts. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Use the actual UniGetUI app host as the default Linux package executable and validate that the staged package payload contains it before creating launcher integration files. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Pass UseSharedCompilation=false directly to the Windows NativeAOT publish command so referenced project compiles do not use VBCSCompiler and intermittently lock intermediate outputs. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Disable MSBuild project parallelism for the Windows NativeAOT release publish to avoid intermittent intermediate output races in referenced projects. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Gabriel Dufresne (GabrielDuf)
approved these changes
Jul 8, 2026
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This change promotes the opt-in NativeAOT path added in #5057 to the default release packaging path for every UniGetUI target: Windows, macOS, and Linux on x64 and arm64.
What changed
PublishAot=trueis now enabled forReleasepublishes inUniGetUI.Avalonia.csproj, while Debug/local development builds remain non-AOT by default.PublishReadyToRunis disabled whenever NativeAOT is active.build-release.ymlnow publishes NativeAOT packages for all release targets.clang/LLVM,gcc-aarch64-linux-gnu,binutils-aarch64-linux-gnu,zlib1g-dev:arm64) before publishinglinux-arm64-NativeAot..dbg/.pdbfiles are removed from Linux release payloads before packaging, matching the existing Windows oversized-PDB pruning behavior./opt/unigetui/UniGetUI, and package staging validates that the executable exists.dotnet-test.ymlno longer usescontinue-on-error, so publish failures block CI.UniGetUI-size-reportartifact.avalonia-nativedaemon kind for Linux NativeAOT executables.publish-nativeaot.ps1supports arm64 and the README documents NativeAOT as the release default.Validation
.NET Testspassed.CLI Headless E2Epassed for:build-release.ymldry-run passed for all release targets:.deblauncher points to/opt/unigetui/UniGetUI, matching the packaged app host.Latest successful release dry run: https://github.com/Devolutions/UniGetUI/actions/runs/28967170760
Final dry-run package sizes
Same-branch Linux comparison
The initial Linux size increase came from shipping the NativeAOT debug-symbol file (
UniGetUI.dbg, about 105.8 MiB). After pruning oversized symbols, NativeAOT is smaller than the same-branch non-AOT/R2R Linux publish:PublishAot=false,PublishReadyToRun=true)Notes
DataGridstill produces known third-party trim/AOT warnings; no new UniGetUI-specific warnings were introduced.Collection was modifiedpackage-download error; the rerun passed.