Automatically include NativeAOT debug symbols in Android App Bundles for Google Play
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 52/100
- Issue 类型
- 功能
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- android, csharp
- 领域
- build-system, mobile
调研方向
Start by tracing the Android App Bundle metadata packaging target referenced in the workaround, especially _BuildApkEmbed, and how Release NativeAOT output paths vary by ABI. Add automated coverage for symbol paths, inclusion, and matching build IDs, then confirm the resulting bundle is accepted by Play Console without the missing-symbol warning. The payload names no test files or implementation files.
由索引模型根据 Issue 内容生成。
描述
Android framework version
net11.0-android (Preview)
Affected platform version
Reported with .NET SDK 11.0.100-rc.2.26504.105 and Android workload 37.2.0-rc.2.84.
Description
Automatically include the generated NativeAOT debug symbols in Android App Bundles (.aab) so Google Play can use them for native crash reports without a custom MSBuild target.
This is a focused follow-up to the comment by @tipa in #8903. The reporter states that explicitly adding the generated symbols to the bundle removed the Play Console warning about missing native debug symbols.
The SDK should package the generated symbols under BUNDLE-METADATA/com.android.tools.build.debugsymbols/<ABI>/, with the name lib$(TargetName).so.dbg, for each ABI included in a Release NativeAOT bundle. The symbols must match the native library in the bundle. Users should not need to specify ABI paths or add a custom target.
Acceptance criteria:
- Release NativeAOT bundles include the generated app symbols for each packaged ABI.
- Packaged symbols have build IDs that match the corresponding native libraries.
- Add automated coverage for the bundle paths and symbol inclusion.
- Confirm that Play Console accepts the symbols without the missing-symbol warning for the NativeAOT app library.
The reporter checked clean builds, matching build IDs, and local ndk-stack source-line lookup. Production crash symbolication in Google Play and Mono were not tested. This issue covers the generated NativeAOT app library symbols; the broader native crash support request remains in #8903.
Steps to Reproduce
- Build a .NET 11 Android NativeAOT app in Release mode with
PublishAot=trueandAndroidPackageFormat=aab. - Upload the bundle to Google Play Console.
- Observe the warning about missing native debug symbols.
- Add the target below, rebuild, and upload the bundle. The reporter states that this removed the warning.
Did you find any workaround?
@tipa supplied this target for arm64-v8a and x86_64:
<Target Name="IncludePlayNativeSymbols" BeforeTargets="_BuildApkEmbed" Condition="'$(Configuration)' == 'Release' And '$(PublishAot)' == 'true' And '$(AndroidPackageFormat)' == 'aab'">
<ItemGroup>
<AndroidAppBundleMetaDataFile Include="com.android.tools.build.debugsymbols/arm64-v8a/lib$(TargetName).so.dbg:$(OutputPath)android-arm64/native/lib$(TargetName).dbg.so" />
<AndroidAppBundleMetaDataFile Include="com.android.tools.build.debugsymbols/x86_64/lib$(TargetName).so.dbg:$(OutputPath)android-x64/native/lib$(TargetName).dbg.so" />
</ItemGroup>
</Target>
Relevant log output
No build logs were supplied in the source comment. The Play Console warning quoted in #8903 is:
This App Bundle contains native code, and you've not uploaded debug symbols. We recommend you upload a symbol file to make your crashes and ANRs easier to analyze and debug.
- 主要语言
- C#
- 星标
- 2.1k
- 派生
- 581
- 平均合并
- 1 天 17 小时
- 30 天内合并 PR
- 237
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 没有贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
dotnet/android 的其他 Issue
-
Area: App+Library Build
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
Area: Mono.Android
难度 2/5 1-3 小时 新手友好度 65/100
dotnet/android#9192 · 4 条评论 · 1 个 reaction ·
维护者通常 1 天内回复
-
agentic-workflows needs-triage
难度 3/5 1-2 天 新手友好度 38/100
维护者通常 1 天内回复
-
needs-triage
难度 4/5 3-5 天 新手友好度 46/100
dotnet/android#13205 · 1 条评论 ·
维护者通常 1 天内回复
-
needs-triage
难度 4/5 3-5 天 新手友好度 52/100
维护者通常 1 天内回复
相似的 Issue
-
bug priority: P2
难度 1/5 1-3 小时 新手友好度 84/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 77/100
维护者通常 1 天内回复
-
[Docs] README/PRIVACY still name AppCenter although v1.5.6.0+ uses the Microsoft Store Services SDK未关闭
难度 2/5 1-3 小时 新手友好度 78/100
-
needs-triage
难度 2/5 1-3 小时 新手友好度 72/100
Azure/azure-sdk-tools#17317 ·
维护者通常 1 天内回复
-
Test
难度 2/5 1-3 小时 新手友好度 69/100
维护者通常 1 天内回复