[build] Replace TPN generation with checked-in file + skill#11284
Conversation
Delete ~31 files of xaprepare TPN generation infrastructure: - ThirdPartyNotice/ThirdPartyNoticeGroup base classes, TPNAttribute, ThirdPartyLicenseType, CommonLicenses, Step_ThirdPartyNotices, Scenario_ThirdPartyNotices - All 19 TPN definition files in ThirdPartyNotices/ - Dead CreateThirdPartyNotices MSBuild task - license-data/ template files (Apache-2.0, GPLv2, GPLv3, Mono-MIT) Merge both TPN sets (build-deps + shipped-deps) into a single THIRD-PARTY-NOTICES.TXT at the repo root (26 entries). Update packaging (License.targets, create-installers.targets) to reference the checked-in file instead of the generated one. Add .github/skills/update-tpn/SKILL.md with full dependency catalog and audit workflow for maintaining the TPN file going forward. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Use upstream URL (Tessil/robin-map) instead of fork (xamarin/robin-map) to match the TPN entry. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR removes the xaprepare-based third-party notices (TPN) generation pipeline and replaces it with a single checked-in THIRD-PARTY-NOTICES.TXT at the repo root, plus a new update-tpn skill to guide future audits/updates.
Changes:
- Check in a merged
THIRD-PARTY-NOTICES.TXT(build + shipped dependencies) using the Microsoft OSS header format. - Update NuGet/installer packaging targets to ship the checked-in TPN file instead of a generated
$(XAInstallPrefix)file. - Delete the xaprepare TPN generation infrastructure (scenario/step/types/data) and the unused prep task + license-data templates; add a new
.github/skills/update-tpnskill doc.
Reviewed changes
Copilot reviewed 37 out of 37 changed files in this pull request and generated 1 comment.
Show a summary per file
Show actual fork URLs from .gitmodules for lz4 (dotnet/lz4) and robin-map (xamarin/robin-map), with upstream URLs noted. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
/review |
|
✅ Android PR Reviewer completed successfully! |
|
Compared the checked-in
All 22 entries from the shipped version are preserved exactly as-is. |
There was a problem hiding this comment.
✅ LGTM
Clean, well-structured removal of ~2,550 lines of TPN generation infrastructure, replaced by a checked-in THIRD-PARTY-NOTICES.TXT and a Copilot skill for future maintenance.
What I verified
- No dangling references — all 31 deleted files (7 infra classes, 19 TPN definitions, 4 license templates, 1 dead MSBuild task) have zero remaining references in
.cs,.csproj,.targets, or.propsfiles - TPN completeness — 26 TOC entries match 26
%%license sections; entries match the skill's dependency inventory (submodules, vendored source, NuGet packages, vendored linker, SDK tools, libzip) - MSBuild path change is sound —
$(XamarinAndroidSourcePath)is already defined inConfiguration.propsand used extensively inLicense.targetsitself (lines 9–10); switching from$(XAInstallPrefix)eliminates the dependency onxapreparegenerating the file before packaging - Old checked-in TPN entries preserved — all 7 original entries (android/platform/tools/base, bazel, constexpr-xxh3, xxHash, crc32.net, nunitlite, robin-map) are present in the merged file alongside the 19 former "shipped" entries
Step_CopyExtraResultFilesForCIstill works — it searchesXamarinAndroidSourceRootforTHIRD-PARTY-NOTICES.TXT, which now resolves to the checked-in file- CI — both public checks passing (license/cla ✅, dotnet-android ✅)
Issue summary
| Severity | Count |
|---|---|
| 💡 Suggestion | 1 |
One minor suggestion on the skill's verification step using a PowerShell-only cmdlet.
Generated by Android PR Reviewer for issue #11284 · ● 10M
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
No longer needed since the file is checked into the repo instead of generated at build time. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Verified the Extracted from |
The GPLv3 license text (gnu/binutils) uses "countries" and "country" which are flagged by PoliCheck geopolitical rules. These are verbatim license terms that cannot be modified. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Summary
Phase 2: Replace the xaprepare TPN generation infrastructure with a checked-in
THIRD-PARTY-NOTICES.TXTfile and a Copilot skill for future maintenance.Changes
Merged TPN file
THIRD-PARTY-NOTICES.TXTat the repo root (26 entries)Updated packaging
License.targetsandcreate-installers.targetsnow reference$(XamarinAndroidSourcePath)THIRD-PARTY-NOTICES.TXT(the checked-in file) instead of$(XAInstallPrefix)THIRD-PARTY-NOTICES.TXT(the generated one)Deleted ~31 files of TPN generation code (-2551 lines)
ThirdPartyNotice,ThirdPartyNoticeGroup,TPNAttribute,ThirdPartyLicenseType,CommonLicenses,Step_ThirdPartyNotices,Scenario_ThirdPartyNotices)ThirdPartyNotices/CreateThirdPartyNoticesMSBuild task (never invoked from any .targets)Apache-2.0.txt,GPLv2.txt,GPLv3.txt,Mono-MIT.txt)Step_ThirdPartyNoticesfromScenario_Standard.csAdded
update-tpnskill.github/skills/update-tpn/SKILL.mdwith full dependency catalog (all URLs, license file paths) and audit workflow for maintaining the TPN file going forward