Repository navigation
Publish Android symbols through Arcade - #4838
Conversation
Remove duplicate preview pipeline artifacts now that each build emits one package family. Collapse preview transfer wrappers into _NuGets and _Symbols, migrate PR/docs consumers, and stop the special-package job from republishing raw native inputs. Preserve Arcade publishing artifacts and the distinct native symbol payload used by API Scan. Co-authored-by: Copilot App <[email protected]>
Unify normal and symbol NuGets in one pipeline artifact so Arcade can classify real symbol packages and generate fallback copies only where appropriate. Add deterministic Android ELF build IDs and enforce matching split-debug identities for dotnet-symbol retrieval. Co-authored-by: Copilot App <[email protected]> Copilot-Session: 906c4f99-e164-4f92-b614-70c924dc9d47
📦 Try the packages from this PRWarning Do not run these scripts without first reviewing the code in this PR. Step 1 — Download the packages bash / macOS / Linux: curl -fsSL https://raw.githubusercontent.com/mono/SkiaSharp/main/scripts/get-skiasharp-pr.sh | bash -s -- 4838PowerShell / Windows: iex "& { $(irm https://raw.githubusercontent.com/mono/SkiaSharp/main/scripts/get-skiasharp-pr.ps1) } 4838"Step 2 — Add the local NuGet source dotnet nuget add source ~/.skiasharp/hives/pr-4838/packages --name skiasharp-pr-4838More options
Or download manually from Azure Pipelines — look for the Remove the source when you're done: dotnet nuget remove source skiasharp-pr-4838 |
📊 SkiaSharp benchmarks — PR #4838⭐ this PR (full source build) vs 🌙 nightly · Linux · Windows · macOS
Highlights⏱️ Time — 🔴 26 slower · 🟢 15 faster
Full per-OS benchmark deltasLinux⏱️ Time (vs 🌙 nightly
Windows⏱️ Time (vs 🌙 nightly
macOS⏱️ Time (vs 🌙 nightly
|
📦 Artifact size reportPackages from this PR (build Total Packages
+37 package(s) unchanged (< 50.0 KB). Per-file changes
|
| File | Size |
|---|---|
🧬 android-x86 (runtimes/android-x86/native/libSkiaSharp.so) |
11.8 MB → 11.0 MB (🟢 −802.1 KB) |
README.md |
219 B → 1.9 KB (🔴 +1.7 KB) |
SkiaSharp.NativeAssets.WebAssembly
| File | Size |
|---|---|
README.md |
219 B → 1.9 KB (🔴 +1.7 KB) |
SkiaSharp.NativeAssets.WinUI
| File | Size |
|---|---|
runtimes/win-arm64/native/libGLESv2.pdb |
64.5 MB → 64.4 MB (🟢 −96.0 KB) |
runtimes/win-x64/native/libGLESv2.pdb |
66.6 MB → 66.5 MB (🟢 −80.0 KB) |
runtimes/win-x86/native/libGLESv2.pdb |
67.2 MB → 67.2 MB (🟢 −48.0 KB) |
README.md |
219 B → 1.9 KB (🔴 +1.7 KB) |
runtimes/win-arm64/lib/net10.0-windows10.0.19041.0/SkiaSharp.Views.WinUI.Native.Projection.dll |
24.5 KB → 25.5 KB (🔴 +1.0 KB) |
runtimes/win-arm64/lib/net9.0-windows10.0.19041.0/SkiaSharp.Views.WinUI.Native.Projection.dll |
24.5 KB → 25.5 KB (🔴 +1.0 KB) |
runtimes/win-x64/lib/net10.0-windows10.0.19041.0/SkiaSharp.Views.WinUI.Native.Projection.dll |
24.5 KB → 25.5 KB (🔴 +1.0 KB) |
runtimes/win-x64/lib/net9.0-windows10.0.19041.0/SkiaSharp.Views.WinUI.Native.Projection.dll |
24.5 KB → 25.5 KB (🔴 +1.0 KB) |
runtimes/win-x86/lib/net10.0-windows10.0.19041.0/SkiaSharp.Views.WinUI.Native.Projection.dll |
24.5 KB → 25.5 KB (🔴 +1.0 KB) |
runtimes/win-x86/lib/net9.0-windows10.0.19041.0/SkiaSharp.Views.WinUI.Native.Projection.dll |
24.5 KB → 25.5 KB (🔴 +1.0 KB) |
Informational only — this never blocks the PR. Native binaries are labelled by os/arch.
Stop repackaging standard Arcade symbol packages into the _Symbols transfer package family. Genuine symbols.nupkg files remain in the unified nuget artifact for BAR and symbol-server publishing. Co-authored-by: Copilot App <[email protected]> Copilot-Session: 906c4f99-e164-4f92-b614-70c924dc9d47
Migrate CI to dnceng with Arcade shipping and transport (#4803) Context: #4775 Context: #4800 Context: #4801 Context: #4802 Context: #4838 Context: #4842 Context: #4846 Context: #4859 Context: https://dev.azure.com/dnceng/internal/_git/dotnet-SkiaSharp/pullrequest/63954 Context: https://dev.azure.com/dnceng/internal/_build/results?buildId=3057398 Replace the legacy DevDiv Native -> Managed -> Tests chain with repository-owned dnceng pipelines and a standard Arcade V3 package flow. Keep public validation unsigned, reserve protected identities for internal signing, scanning, BAR registration, and promotion, and leave the binding, native, and runtime product surface unchanged. ~~ Connected dnceng topology ~~ The split Native and Package definitions handed artifacts across independently numbered runs, which made source, package, and test provenance harder to keep connected. Make internal definition 1642 own Prepare, Native, and Package in one Build run, and make Tests 1630 consume the folder-qualified `\dotnet\skiasharp\skiasharp-package` resource. Trigger 1642 directly for `main` and `release/*` path changes, plus a daily main schedule, instead of waiting for completion of a separate Native pipeline. Remove the obsolete native-only and internal-complete YAML roots, and derive managed, test, and sample dependencies from the shared build/test pipeline role. Public definition 345 and downstream Tests 1630 keep those shared stages through the local output adapter; for public CI this avoids the inaccessible private 1ES template repository. Expansion guards require the internal project, a non-PR reason, and a non-PR ref before signing, compliance, or publishing stages can exist. ~~ dnceng execution policy ~~ Move the internal root from the DevDiv MicroBuild 1ES template to the released v1 1ES Official template, and move its Windows and Linux agents to NetCore1ESPool-Internal. Apple jobs remain on Microsoft-hosted macOS images. Armory, BinSkim, CredScan, ESLint, PoliCheck, and PSScriptAnalyzer are configured to break; CodeQL also runs on non-default branches. Network isolation remains in Audit while permanent mirrors and allowlisting are completed. The combined root carries forward the managed Apple macOS 15/Xcode 26.3 and native Apple macOS 14/Xcode 16.2 split. The repository remains on SDK 10.0.203 and workload set 10.0.202, but Visual Studio MSBuild 17.x cannot load .NET 10.0.2xx. Install `DOTNET_VERSION_WINUI` (10.0.108) side by side on the three WinUI C++/WinRT jobs. Build and merge the MSVC Win32 artifacts unconditionally, dropping the former `System.TeamProject == 'devdiv'` gate. ~~ Provider-neutral build identity ~~ Replace feature-name and loosely parsed downstream counters with Arcade's `yyyyMMdd.revision` OfficialBuildId, converted to the existing `short-date.revision` package suffix. Normalize GitHub and Azure Repos PR numbers, source commits, source branches, and repository URLs before packing; fail when required identity is absent or an inherited Build run name is malformed. PR builds use `pr.<number>`, scheduled builds use `nightly`, and ordinary builds retain their source-controlled label. A producing pipeline may select the `stable` sentinel only on an internal `release/*` branch; it clears the suffix to produce exact `X.Y.Z` packages. Downstream Tests inherit the selected Build run name, including an exact-release identity, rather than generating a second identity. Each run creates one transport alias family as well: PR aliases for PR validation and branch aliases otherwise. Remove commit aliases so one BAR cannot receive multiple versions of the same transport package ID. Package outputs are not cached because their versions and transport family depend on run identity, not only repository inputs. ~~ Deterministic Arcade package inputs ~~ Replace the separate normal and special packaging jobs, and the stable, preview, and symbol transport variants they produced, with one Cake graph in a single `package_windows` job. It publishes raw `nuget` and `nuget_special` artifacts plus prepared `arcade_shipping`, `arcade_nonshipping`, and `PdbArtifacts` inputs. Shipping contains product and explicit symbol packages; NonShipping contains the run's single `_NuGets`/`_NativeAssets*` transport family. `_NuGets` uses numbered dependency packages to keep each payload chunk near 200 MB. Arcade V3 expects `PdbArtifacts`, so provide real loose symbols rather than a permanent placeholder or manufactured fallback packages. For product packages without an explicit symbol package, extract implementation and runtime PDBs under package/version/TFM/RID paths. Exclude `ref/**`, reject ZIP paths that escape the package root, avoid loose-PDB duplication for packages with explicit symbols, and emit `.empty` only when no eligible PDB exists. Consume the Apple symbol packages introduced by #4846 instead of manufacturing fallback copies. The public PR downloaders now query definition 345 by exact PR merge ref, consume the canonical `nuget` artifact, exclude `.symbols.nupkg`, and use isolated temp directories. Documentation and sample generation select the single package family instead of assuming stable and preview packages coexist. The exact 3057398 artifact audit matched raw and prepared package payloads, contained 209 path-safe loose PDBs, and confirmed that the Package stage emitted only the five contract artifacts, with no `package_windows` artifact. ~~ Self-verifying build logic ~~ Build identity, API Scan input preparation, and Arcade asset assembly encode release constraints that would otherwise fail only in later or protected stages. Add dedicated suites for each and run them as pipeline gates rather than relying on YAML string checks or post-release inspection. Prepare runs `SetBuildVariables.Tests.ps1` and `PrepareApiScanInputs.Tests.ps1` before product stages, so identity failures and API Scan input drift are caught even when API Scan does not expand. Package runs `AssembleArcadeAssets.Tests.ps1` after packing against real ZIP fixtures, proving PDB extraction, `ref/**` exclusion, traversal rejection, explicit-symbol ownership, PR/branch transport selection, and `.empty` fallback on each run. ~~ Shipping-only signing ~~ Replace the legacy SignList and Arcade defaults with the explicit policy in `eng/Signing.props`. Any new signable payload must be added to one of its first-party, Mac developer, third-party, or skipped classifications for signing validation to succeed. First-party binaries use the repository's certificate mappings and skip the third-party copyright check because they intentionally lack Microsoft copyright metadata. Only prepared Shipping NuGets enter Arcade signing; product and explicit symbol packages are signed together. `eng/SignCheckExclusionsFile.txt` marks NonShipping transport `DO-NOT-SIGN, DO-NOT-UNPACK` and marks JavaScript and generated WebGPU payloads `DO-NOT-SIGN`; those payloads use `CertificateName=None` and remain authenticated by their signed NuGet container. `DO-NOT-SIGN` is fail-closed, so SignCheck fails if a listed file is ever signed. Main and release branches select real signing automatically. Other trusted internal branches test-sign unless `forceRealSigning` is requested, and forced BAR side effects additionally require `registerInBar`. Use standard Arcade SignTool and SignCheck validation rather than retaining the migration prototype's duplicate recursive verifier. ~~ API Scan input coverage ~~ Move API Scan into a repository-owned internal stage that downloads the current `nuget` and `native_msvc` artifacts, authenticates through the dedicated WIF connection, and runs in release mode. Package extraction preserves symbols and builds checked surrogates for Win32, NanoServer, and WinUI, including shipped ARM64 binaries that require API-compatible x64 MSVC inputs. Use the same HTTPS SymWeb symbol path in the scan task and generated surrogate configuration. Input preparation fails when packages, binaries, PDBs, surrogate files, or configured target matches are absent. Reporting, TSA upload, and PostAnalysis use Note-level API Scan policy; raw logs are published for audit. The stage runs when explicitly requested and on scheduled main builds, independently of BAR registration. ~~ BAR registration and promotion ~~ Generate one Arcade V3 manifest from signed Shipping and prepared NonShipping artifacts, with explicit symbol blobs and the standard PDB artifact alongside it. Protected registration is structurally limited to non-PR internal builds. Main and release branches register automatically; a forced feature-branch run must opt into both real signing and BAR registration. Use standard post-build validation with `publishAssetsImmediately: false` and `requireDefaultChannels: true`, so a missing Maestro mapping fails closed and Darc performs configured channel promotion only after asset publication finishes. NuGet.org publication remains a separate protected operation; #4859 carries the release-tooling adaptation to this BAR model. Exact Build 3057398 completed real signing, Note-level API Scan, BAR registration, asset validation, and Darc promotion. BAR 328638 reached General Testing with 41 shipping package assets, 22 non-shipping transport assets, 14 symbol blobs, and one manifest, with no recorded incoherencies or staleness. Co-authored-by: Matthew Leibowitz <[email protected]> Co-authored-by: Matthew Leibowitz <[email protected]> Co-authored-by: Copilot App <[email protected]>
Description
This PR is stacked on #4803 and includes that CI migration so the complete pipeline plus the symbol changes can run through public PR validation against
main.It replaces SkiaSharp's split normal/symbol pipeline artifacts with one flat
nugetartifact containing normal packages and genuine*.symbols.nupkgpackages. This follows Arcade's standard discovery behavior: existing symbol packages becomeBlobassets withCategory="Symbols", while packages without a matching symbol package receive Arcade's generated-copy fallback.The legacy
_Symbols/_Symbols.Dependencies.*transfer packages are removed. Genuine*.symbols.nupkgfiles remain standard Arcade inputs and are no longer repackaged into repository-specific wrappers.Android native builds now emit deterministic SHA-1 GNU build IDs and validate that each stripped
.soand.so.dbgpair shares the same identity and is connected through.gnu_debuglink. This allowsdotnet-symbolto resolve Android symbols by ELF build ID after Arcade indexes the real symbol packages.Related issues
Related to #4803.
Required skia PR
None.
Areas affected
binding/)externals/skia/src/c,include/c)Changes
Behavior
Official Android native packages can be indexed by Arcade and resolved by
dotnet-symbol; no public managed API or native ABI changes.Testing
.so/.so.dbgpair and validated.gnu_debuglink.Publish.projover packages containing the source-built binaries and verified two shippingPackagerecords plus two unchangedBlob Category="Symbols"records.nuget-specialemits_NuGetsand_NativeAssetscompatibility packages but no_Symbolspackage, and_NuGetsexcludes genuine*.symbols.nupkgfiles.1561694succeeded on exact commit5c5ad1b509a791e4df2ffc6c6bd1db50a9a67fc5.nugetartifact contains 36 normal packages and 4 genuine symbol packages; both Android symbol packages contain all four.so/.so.dbgRID pairs.3053467completed native builds, packaging, real signing, API Scan, BAR registration, and validation successfully. Its only failed stage was automatic default-channel promotion because feature branches intentionally have no default mapping.327990was manually promoted toGeneral Testingvia promotion build3053632.dotnet-symbolretrieved both.so.dbgfiles from MSDL and internal SymWeb using fresh caches. Both servers returned identical bytes:libSkiaSharp.so.dbg:6a705a42e531e294bf5977ef96707fb6f27a4f5891a183f88041ea7e09f0c5c6libHarfBuzzSharp.so.dbg:bd15f239e64c23487bd13544e36004f55e7478a55e9365a9a3dc5b55951d03f6Checklist
Changesabove lists all public API and behavioral changes (or "None.")mono/skiaPR linked above and bindings regenerated — N/A, linker/package configuration only; nomono/skiaor C API changes.