Skip to content

[skia-sync] Update skia to milestone 150#4146

Merged
mattleibow merged 10 commits into
mainfrom
skia-sync/m150
Jun 12, 2026
Merged

[skia-sync] Update skia to milestone 150#4146
mattleibow merged 10 commits into
mainfrom
skia-sync/m150

Conversation

@mattleibow

@mattleibow mattleibow commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

Automated Skia milestone bump from m148 to m150.

Companion skia PR: mono/skia#253

mono/SkiaSharp PR Summary: Skia m148 → m150 Binding Update

Overview

Updated SkiaSharp parent repository to use the newly merged Skia m150 submodule. This is a version bump with no breaking C API or C# changes.

Version Changes

File Change
scripts/VERSIONS.txt Milestone 148 → 150; NuGet version 4.148.0 → 4.150.0
cgmanifest.json commitHash updated to 94451aa283, chrome_milestone = 150, upstream_merge_commit = c92514572e
scripts/azure-templates-variables.yml SKIASHARP_VERSION = 4.150.0
externals/skia Submodule pointer updated to 94451aa283 (mono/skia PR #253 merge commit on skiasharp; m150 merge 0a248d1b82 + portability fixes — see below)

SK_C_INCREMENT

SK_C_INCREMENT was reset to 0 by the update-versions script on milestone change (was already 0). No new C API functions were added in this update.

C API Changes

None. The binding generator (regenerate-bindings.ps1) confirmed no changes to SkiaApi.generated.cs between m148 and m150.

C# Wrapper Changes

None. No new generated functions were detected requiring hand-written C# wrapper code.

Breaking Change Analysis

Upstream Change C# Impact Action
SkRegion::setRects signature None (not in C API)
SkShader::isOpaque() pure virtual None (no subclassing in C# layer)
SkStrikeRef new type None exposed
Graphite API changes None (Ganesh only)

Post-Merge CI / Portability Fixes

After the initial merge, the Azure DevOps native source build (SkiaSharp (Public)) surfaced toolchain-specific compile failures on Windows, WASM, and Tizen. These were fixed in the companion skia fork PR #253 (commits on top of the m150 merge) and the submodule was re-pinned forward to 94451aa283 (the PR #253 merge commit on the skiasharp branch). Summary of the fork fixes now included:

Area Fix Why
WASM (emscripten 3.1.34 / libc++ 15) std::views::reverse → reverse-iterator loop in SkPDFTag.cpp std::ranges/std::views gated behind incomplete-features in libc++ 15
Tizen (clang 10 / gcc 9.2 libstdc++) PDF backend C++20 three-way comparisons backported to explicit C++17 operators (SkPDFTypes.h, SkPDFTag.cpp); optional::emplace on aggregate → aggregate-init Tizen toolchain predates C++20 <compare>/ranges. Resolves #4155; PDF stays enabled on Tizen (no regression)
Tizen SkOpts SIMD opts("ml3")/opts("ml4") use clang-10 -march=haswell / skylake-avx512 (keeping m150's new -mprefer-vector-width=512) m150 switched to -march=x86-64-v3/v4, which clang 10 doesn't know (clang ≥ 12)
Windows min_win_sdk_version = "10.0.22621.0" floor in skia gn/BUILDCONFIG.gn m150's SkFontMgr_win_dw.cpp uses IDWriteFontSet4, which needs the Win11 SDK (acquired via QueryInterface with null-check fallback — runtime-safe on older Windows)
Windows D3D GrD3DBackendSurface.cpp: GrBackendFormatData::equal made unconditional, GrBackendTextureData::equal fully guarded under GPU_TEST_UTILS Completes upstream 20c304440c, which left the D3D backend abstract in non-test builds. Only SkiaSharp compiles the D3D backend, so upstream CI never caught it
All platforms Reverted a SK_SUPPORT_PDF guard in src/c/sk_document.cpp The C-API shim compiles into skia's :core target, which never receives :pdf's SK_SUPPORT_PDF public define → guard was always false → PDF factories returned null everywhere (caught by SKDocumentTest)

Build Results

  • Native library: Built successfully from source (externals-linux x64)
    • libSkiaSharp.so.150.0.0
    • libHarfBuzzSharp.so
  • C# bindings: dotnet build binding/SkiaSharp/SkiaSharp.csproj ✅ (0 errors, 0 warnings)
  • CI: Azure DevOps SkiaSharp (Public) build 158224 — all stages green (Native Windows/macOS/Linux/WASM, Native, Package NuGets, API Diff, Build Managed, Tests, Samples).

Test Results

Passed!  - Failed: 0, Passed: 5507, Skipped: 172, Total: 5679
Duration: 2 m 44 s - SkiaSharp.Tests.dll (net10.0)

All 172 skipped tests are expected platform/hardware skips (GPU tests without GPU drivers, platform-specific features). Zero failures.

Full test output: test-output.txt (workflow artifact)

Items Needing Human Attention

  1. No C# API additions for SkStrikeRef: Upstream added SkFont::makeStrikeRef() returning the new SkStrikeRef type. This is not yet exposed in the C API or C# bindings. Could be tracked as a future API addition issue if users request it.

  2. DEPS pinning carries forward: Fork maintains custom-pinned native library versions (expat 2.8.1, freetype 2.14.3, harfbuzz 14.2.0, etc.) which are security/bug-fix upgrades vs upstream. These remain correct.

Created by skia-upstream-sync.

- Bumped milestone from m148 to m150
- Updated NuGet version from 4.148.0 to 4.150.0
- Updated cgmanifest.json with new commit hash and chrome_milestone=150
- Updated submodule to merged m150 branch

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions

github-actions Bot commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

📦 Try the packages from this PR

Warning

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 -- 4146

PowerShell / Windows:

iex "& { $(irm https://raw.githubusercontent.com/mono/SkiaSharp/main/scripts/get-skiasharp-pr.ps1) } 4146"

Step 2 — Add the local NuGet source

dotnet nuget add source ~/.skiasharp/hives/pr-4146/packages --name skiasharp-pr-4146
More options
Option Description
--successful-only / -SuccessfulOnly Only use successful builds
--force / -Force Overwrite previously downloaded packages
--list / -List List available artifacts without downloading
--build-id ID / -BuildId ID Download from a specific build

Or download manually from Azure Pipelines — look for the nuget artifact on the build for this PR.

Remove the source when you're done:

dotnet nuget remove source skiasharp-pr-4146

@github-actions

github-actions Bot commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

📖 Documentation Preview

The documentation for this PR has been deployed and is available at:

🔗 View Staging Site
🔗 View Staging Docs
🔗 View Staging Gallery (Blazor)
🔗 View Staging Gallery (Uno Platform)
🔗 View Staging SkiaFiddle

This preview will be updated automatically when you push new commits to this PR.


This comment is automatically updated by the documentation staging workflow.

Advances externals/skia to 047210c1bf which removes the fork-only
// TODO(kjlubick) comment in tests/RegionTest.cpp so the file matches
upstream chrome/m150 exactly. Updates cgmanifest.json commit hash to match.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Three platform-specific native build failures on Azure DevOps build 158198:

- Windows: m150's SkFontMgr_win_dw.cpp onMatch() uses IDWriteFontSet4,
  which requires Windows 11 SDK 10.0.22621. Skia's GN picks the lowest
  installed SDK >= 10.0.16299, so it resolved to an older SDK and failed
  with 'use of undeclared identifier IDWriteFontSet4'. Pin
  win_sdk_version='10.0.22621.0' (preinstalled on the windows-2022 image).
  Runtime-safe: IDWriteFontSet4 is acquired via QueryInterface with a
  null-check fallback, and a newer SDK adds no new DLL import.

- WASM/Tizen: bump skia submodule to replace std::views::reverse in
  SkPDFTag.cpp with a reverse-iterator loop (emscripten 3.1.34 / libc++ 15
  disables ranges) and guard the PDF C API with SK_SUPPORT_PDF.

- Tizen: clang 10 + gcc 9.2 libstdc++ predate C++20 (<compare>/ranges
  required by m150's PDF backend), so disable PDF with skia_enable_pdf=false
  as an agreed stopgap. Regresses SKDocument PDF on Tizen, tracked by #4155.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
mattleibow and others added 6 commits June 12, 2026 03:04
Rather than pinning win_sdk_version='10.0.22621.0' exactly, raise
min_win_sdk_version to 10.0.22621.0. Skia's gn/BUILDCONFIG.gn selects
the lowest installed SDK >= min_win_sdk_version via lowest_version_dir.py,
so this picks 22621 when present and tolerates a newer SDK if the exact
version isn't installed on the agent.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Bump skia submodule to d2fe11b410:
- mono/skia #255: C++17 backport of the PDF backend's three-way
  comparisons (SkPDFTypes.h, SkPDFTag.cpp), so PDF compiles on the Tizen
  clang-10/gcc-9.2 toolchain. Removes the skia_enable_pdf=false stopgap
  from native/tizen/build.cake, restoring SKDocument PDF on Tizen. Fixes #4155.
- Raise min_win_sdk_version to 10.0.22621.0 in skia's gn/BUILDCONFIG.gn
  (for IDWriteFontSet4) instead of threading a gn arg through build.cake,
  so the requirement lives with the source that needs it. Reverts the
  earlier cake-level win_sdk arg.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Roll skia to 144ebf96d5 which fixes the C++17 PDF backport's use of
std::optional<Data>::emplace on an aggregate type, which failed to
compile on the Tizen gcc-9.2 libstdc++ toolchain.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Roll skia to a8ea924948 so the m150 ml3/ml4 SkOpts use clang-10-compatible
-march names (haswell / skylake-avx512) on Tizen x86_64, which clang 10
rejects under the new x86-64-v3 / x86-64-v4 CPU names.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Re-pin externals/skia to 159b1ec9e5 which fixes the m150 D3D backend
abstract-class / override errors in GrD3DBackendSurface.cpp on the
Windows native build.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Re-pin externals/skia to bceb12ad2c which reverts the SK_SUPPORT_PDF
guard that broke PDF document creation on all platforms (the define
never reaches the C API translation unit compiled into :core). Fixes
SKDocumentTest PDF failures. PDF is enabled on every platform now (#4155).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
mattleibow added a commit to mono/skia that referenced this pull request Jun 12, 2026
[skia-sync] Merge upstream chrome/m150 (#253)

Context: https://skia.googlesource.com/skia/+log/chrome/m150
Changes: skiasharp...skia-sync/m150
Companion: mono/SkiaSharp#4146
Fixes: mono/SkiaSharp#4155

Advance the SkiaSharp fork's Skia engine from Chrome milestone 148 to 150 by
merging upstream chrome/m150 (tip c925145) into skia-sync/m150 on top of the
fork's skiasharp branch (1a155ba). Merge commit 0a248d1 resolved 19
conflicts; the fork's intentional deltas were preserved while taking upstream's
behavior everywhere the fork had no opinion.

Notable conflict resolutions:

  * DEPS: kept the fork's pinned native deps (expat 2.8.1, freetype 2.14.3,
    harfbuzz 14.2.0, libjpeg-turbo, libpng, libwebp, zlib) — upstream would
    have downgraded these security/bug-fix bumps.
  * include/core/SkFont.h: kept the fork's breakText() overloads and added
    upstream's new SkStrikeRef makeStrikeRef().
  * src/gpu/ganesh/ops/AtlasTextOp.cpp: combined the fork's glyphSrcPadding()>0
    guard with upstream's supportsBilerp() condition, taking upstream's graceful
    log+return on stride mismatch instead of the prior hard assert.

~~ Post-merge portability fixes ~~

The raw merge compiles on the primary toolchains, but SkiaSharp's CI builds the
native libraries on toolchains upstream Skia CI does not exercise: WASM
(emscripten 3.1.34 / libc++ 15), Tizen (clang 10 + gcc 9.2 libstdc++), and the
Direct3D Ganesh backend on Windows. Those legs failed until the following fixes
landed on top of the merge:

  * 8912293 — WASM/Tizen: rewrite std::views::reverse in SkPDFTag.cpp as a
    reverse-iterator loop; ranges/std::views are gated off in libc++ 15 and
    unavailable in clang 10.
  * d0b422e (PR #255) — Tizen: backport the PDF backend's C++20 three-way
    comparisons (<=>/==) to explicit C++17 operators in SkPDFTypes.h and
    SkPDFTag.cpp; the Tizen libstdc++ predates <compare>. This keeps PDF enabled
    on Tizen with no regression and resolves SkiaSharp #4155.
  * 144ebf9 — Tizen: replace optional::emplace on an aggregate with
    aggregate-init for libstdc++ 9.2.
  * a8ea924 — Tizen: opts("ml3")/opts("ml4") use clang-10-spellable
    -march=haswell / skylake-avx512 (keeping m150's new
    -mprefer-vector-width=512). m150 switched to -march=x86-64-v3/v4, which
    clang only understands from version 12.
  * d2fe11b — Windows: raise min_win_sdk_version to 10.0.22621.0 in
    gn/BUILDCONFIG.gn (a floor, not a pin) so the MSVC toolchain selects the
    Win11 SDK that defines IDWriteFontSet4, used by m150's SkFontMgr_win_dw.cpp.
    The interface is acquired via QueryInterface with a null-check fallback, so
    older Windows at runtime is unaffected.
  * 159b1ec — Windows D3D: declare GrD3DBackendFormatData::equal
    unconditionally and fully guard GrD3DBackendTextureData::equal under
    GPU_TEST_UTILS. Completes upstream 20c3044, which left the D3D backend
    abstract in non-test builds; only SkiaSharp compiles the D3D backend, so
    upstream CI never caught it.
  * bceb12a — All platforms: revert a SK_SUPPORT_PDF guard added to
    src/c/sk_document.cpp. The SkiaSharp C-API shim compiles into Skia's :core
    target, which never receives :pdf's SK_SUPPORT_PDF public define, so the
    guard was always false and the PDF factories returned null everywhere
    (caught by SKDocumentTest).

These are toolchain/portability changes only — no change to Skia rendering
behavior on any platform. The companion SkiaSharp PR #4146 re-pins the submodule
to bceb12a, and Azure DevOps "SkiaSharp (Public)" build 158224 is green across
all stages (native Windows/macOS/Linux/WASM, package, API diff, managed build,
tests, samples).

Co-authored-by: Matthew Leibowitz <mattleibow@live.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
mono/skia PR #253 merged the chrome/m150 update into the stable `skiasharp`
branch as merge commit 94451aa283 (parents 1a155bae3a + bceb12ad2c). Point the
submodule at that merge commit instead of the now-merged integration-branch tip
bceb12ad2c; the tree content is identical, but this tracks the stable branch.

Also fix the stale "Main Skia repository reference" commitHash in
cgmanifest.json, which still pointed at the first fork commit (047210c1bf),
to the same merge commit. chrome_milestone (150) and upstream_merge_commit
(c92514572e, the chrome/m150 tip) are unchanged and correct.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@mattleibow mattleibow requested a review from Copilot June 12, 2026 20:00
@mattleibow mattleibow marked this pull request as ready for review June 12, 2026 20:01

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Bumps SkiaSharp’s pinned Skia dependency from Chrome milestone m148 to m150 and updates the repo’s version metadata to align (NuGet/package versions, build pipeline variables, and component governance tracking).

Changes:

  • Updated scripts/VERSIONS.txt to milestone 150 and bumped SkiaSharp NuGet/package versions to 4.150.0 (plus soname/version fields).
  • Updated Azure pipeline template variables to use SKIASHARP_VERSION: 4.150.0.
  • Updated cgmanifest.json to reflect the new mono/skia commit hash and milestone tracking metadata (chrome_milestone, upstream_merge_commit).

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
scripts/VERSIONS.txt Updates milestone/soname/assembly/file/NuGet version metadata to m150 / 4.150.0.
scripts/azure-templates-variables.yml Bumps SKIASHARP_VERSION used by Azure pipeline build numbering to 4.150.0.
cgmanifest.json Updates component governance entries for the Skia git commit and chrome milestone tracking to m150.

@mattleibow mattleibow merged commit 4e08384 into main Jun 12, 2026
7 checks passed
@mattleibow mattleibow deleted the skia-sync/m150 branch June 12, 2026 22:28
@mattleibow mattleibow added this to the 4.150.0-preview.1 milestone Jun 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Tizen: re-enable PDF backend disabled for Skia m150 (C++20 toolchain limitation)

2 participants