Add CI Native AOT gate and document AOT compatibility - #17
Merged
Conversation
The library is already Native-AOT and trim compatible: AOT-publishing the demo consumer produces a single native binary with zero IL2xxx/IL3xxx warnings, and the binary runs. Lock that in and advertise it: - test.yml: new `aot` job AOT-publishes the demo and fails on any IL#### trim/AOT warning. A library's AOT warnings only surface when a consuming app is AOT-published, so this is the authoritative regression guard. - README: add a "Trimming & Native AOT" section. - csproj: note trim/AOT compatibility in the package description and tags. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
What
The library is already Native-AOT & trim compatible — this PR verifies that, guards it against regressions, and advertises it. No production code changes were required.
Verification (already compliant)
PublishAot=true,win-x64): the entire trimmed graph (library + compiled XAML + Avalonia) produced a single self-contained native.exewith zeroIL2xxx/IL3xxx/AVLNtrim/AOT warnings and no managed runtime DLLs in the publish folder.staticctor's enum-keyed theme lookup, compiled XAML bindings, and animations all work after trimming.EnumAPIs, every{Binding}typed via$parent[c:LoadingIndicator](compiled, never reflection), no runtime reflection.Changes
.github/workflows/test.yml— newaotjob installs the Linux native toolchain (clang,zlib1g-dev) and AOT-publishes the demo, failing on anyIL####trim/AOT warning. A library's AOT warnings only surface when a consuming app is AOT-published, so this is the authoritative regression guard.README.md— new "Trimming & Native AOT" section.LoadingIndicators.Avalonia.csproj— note trim/AOT compatibility in the package<Description>and addAOT, trimmingto<PackageTags>.🤖 Generated with Claude Code