Repository navigation
chore: iOS support for Native AOT - #1725
Merged
Merged
Conversation
Context: unoplatform/uno#21066 Context: unoplatform/uno@92676ea Context: https://learn.microsoft.com/en-us/dotnet/maui/deployment/nativeaot?view=net-maui-10.0#publish-using-native-aot MAUI documentation suggests that the `.csproj` should be modified to contain `$(PublishAot)` instead of specifying it on the command-line. In the case of `Chefs`, this doesn't appear to be necessary, but it can be necessary if the project has `@(ProjectReference)`s which can't be built in a trimming environment (e.g. .NET Standard projects). As we *don't* want `$(PublishAot)` to be set by default, introduce a `$(SkiaPublishAot)` "override", a'la unoplatform/uno@92676ea7. `$(PublishAot)` will be true *only if* `$(SkiaPublishAot)`=true. Additionally, it would be useful to install multiple different builds side-by-side. In order for this to work on iOS (and Android), the different builds must have different `$(ApplicationId)`s. Introduce support for the following new MSBuild properties: * `$(ApplicationIdVendorSuffix)`: Value to append to `$(ApplicationId)`, so that separate builds have separate names. * `$(ApplicationTitleVendorSuffix)`: Value to append to `$(ApplicationTitle)`, so that the different builds are distinguishable on the Home Screen. This allows [^0] [^1]: git clean -xdf Chefs{,.Api} dotnet publish -c Release -r ios-arm64 -f net10.0-ios -p:TargetFrameworkOverride=net10.0-ios \ -bl Chefs/Chefs.csproj -p:UseSkiaRendering=true \ -p:ApplicationIdVendorSuffix=.mono "-p:ApplicationTitleVendorSuffix= (Mono)" \ -p:_DeviceName=$UDID "-p:CodesignKey=$CODESIGN_KEY" && cp Chefs/bin/Release/net10.0-ios/ios-arm64/publish/Chefs.ipa ../Chefs-monovm.ipa git clean -xdf Chefs{,.Api} dotnet publish -c Release -r ios-arm64 -f net10.0-ios -p:TargetFrameworkOverride=net10.0-ios \ -bl Chefs/Chefs.csproj -p:UseSkiaRendering=true -p:SkiaPublishAot=true \ -p:ApplicationIdVendorSuffix=.naot "-p:ApplicationTitleVendorSuffix= (NAOT)" \ -p:_DeviceName=$UDID "-p:CodesignKey=$CODESIGN_KEY" && \cp Chefs/bin/Release/net10.0-ios/ios-arm64/publish/Chefs.ipa ../Chefs-naot.ipa Then *both* `Chefs-monovm.ipa` *and* `Chefs-naot.ipa` can be installed *at the same time*, making it easier to do side-by-side comparisons. Finally, add a `Chefs App Finished Launching` message to the end of `App.OnLaunched()` to provide a primitive way to determine app startup times: 1. Launch **Console.app** 2. Select your target device in the Sources panel on the left 3. In the **Search** panel, enter: `Process:Chefs` 4. Click the **▶️ Start** button in the toolbar On the target device, launch the app. Back in Console, look for: * The *first* message from Chefs, and * The *first* message containing `Chefs App Finished Launching`. Then subtract the timestamps. [^0]: `$UDID` from: https://learn.microsoft.com/en-us/dotnet/maui/ios/cli?view=net-maui-10.0#launch-the-app-on-a-device [^1]: `$CODESIGN_KEY` from: https://learn.microsoft.com/en-us/dotnet/maui/ios/deployment/publish-cli?view=net-maui-10.0
kazo0
approved these changes
Jan 21, 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.
Context: unoplatform/uno#21066
Context: unoplatform/uno@92676ea
Context: https://learn.microsoft.com/en-us/dotnet/maui/deployment/nativeaot?view=net-maui-10.0#publish-using-native-aot
MAUI documentation suggests that the
.csprojshould be modified to contain$(PublishAot)instead of specifying it on the command-line. In the case ofChefs, this doesn't appear to be necessary, but it can be necessary if the project has@(ProjectReference)s which can't be built in a trimming environment (e.g. .NET Standard projects).As we don't want
$(PublishAot)to be set by default, introduce a$(SkiaPublishAot)"override", a'la unoplatform/uno@92676ea7.$(PublishAot)will be true only if$(SkiaPublishAot)=true.Additionally, it would be useful to install multiple different builds side-by-side. In order for this to work on iOS (and Android), the different builds must have different
$(ApplicationId)s.Introduce support for the following new MSBuild properties:
$(ApplicationIdVendorSuffix): Value to append to$(ApplicationId), so that separate builds have separate names.$(ApplicationTitleVendorSuffix): Value to append to$(ApplicationTitle), so that the different builds are distinguishable on the Home Screen.This allows 1 2:
Then both
Chefs-monovm.ipaandChefs-naot.ipacan be installed at the same time, making it easier to do side-by-side comparisons.Finally, add a
Chefs App Finished Launchingmessage to the end ofApp.OnLaunched()to provide a primitive way to determine app startup times:Process:ChefsOn the target device, launch the app.
Back in Console, look for:
Chefs App Finished Launching.Then subtract the timestamps.
GitHub Issue (If applicable): #
PR Type
What kind of change does this PR introduce?
What is the current behavior?
What is the new behavior?
PR Checklist
Please check if your PR fulfills the following requirements:
Screenshots Compare Test Runresults.Other information
Internal Issue (If applicable):
Footnotes
$UDIDfrom: https://learn.microsoft.com/en-us/dotnet/maui/ios/cli?view=net-maui-10.0#launch-the-app-on-a-device ↩$CODESIGN_KEYfrom: https://learn.microsoft.com/en-us/dotnet/maui/ios/deployment/publish-cli?view=net-maui-10.0 ↩