Skip to content

Fix Linux SkiaSharp native asset version mismatch - #555

Merged
wieslawsoltes merged 2 commits into
masterfrom
agent/issue-554-linux-native-assets
Aug 12, 2026
Merged

wieslawsoltes merged 2 commits into
masterfrom
agent/issue-554-linux-native-assets

Conversation

@wieslawsoltes

@wieslawsoltes wieslawsoltes commented Aug 11, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • add SkiaSharp.NativeAssets.Linux 4.148.0 to Svg.Controls.Skia.Avalonia
  • keep the standalone Svg.Skia package native-neutral, preserving the application choice between SkiaSharp.NativeAssets.Linux and SkiaSharp.NativeAssets.Linux.NoDependencies
  • verify packed NuGet dependency metadata and a clean linux-x64 consumer publish in build and release workflows

Root cause

Svg.Controls.Skia.Avalonia 12.0.0.14 upgraded Svg.Skia to 5.2.0 and managed SkiaSharp to 4.148.0. The SkiaSharp meta-package supplies Windows and macOS native assets, but not Linux. Avalonia.Skia therefore remained the only source of SkiaSharp.NativeAssets.Linux, at 3.119.4. On Linux, managed 4.148.0 rejected native 3.119.4 during SkiaApi initialization.

The Linux native dependency was deliberately removed from the core package in #408 after #406 so standalone consumers could choose the standard native package or the NoDependencies variant. This change retains that policy and scopes the matching standard native asset to the Avalonia controls package, whose Avalonia dependency already selects the standard variant.

Regression coverage

The new package verifier:

  • rejects a direct Linux SkiaSharp native dependency in Svg.Skia
  • requires Svg.Controls.Skia.Avalonia to declare the same native version as the core managed SkiaSharp dependency
  • restores and publishes a clean linux-x64 consumer from the packed controls package
  • verifies the resolved 4.148.0 package graph and published libSkiaSharp.so

Validation

  • dotnet format Svg.Skia.slnx --no-restore
  • dotnet build Svg.Skia.slnx -c Release --no-restore
  • dotnet test Svg.Skia.slnx -c Release --no-build --no-restore — 3,115 passed, 40 skipped
  • packed consumer verification — SkiaSharp 4.148.0 managed/native match

Fixes #554

@wieslawsoltes wieslawsoltes changed the title Fix Linux SkiaSharp native asset dependency Fix Linux SkiaSharp native asset version mismatch Aug 11, 2026
@wieslawsoltes
wieslawsoltes marked this pull request as ready for review August 12, 2026 09:54
@wieslawsoltes
wieslawsoltes merged commit 8b4cb7c into master Aug 12, 2026
11 checks passed
@wieslawsoltes
wieslawsoltes deleted the agent/issue-554-linux-native-assets branch August 12, 2026 09:54
kubaflo pushed a commit to dotnet/maui that referenced this pull request Sep 10, 2026
Updated [ShimSkiaSharp](https://github.com/wieslawsoltes/Svg.Skia) from
5.1.1 to 5.2.3.

<details>
<summary>Release notes</summary>

_Sourced from [ShimSkiaSharp's
releases](https://github.com/wieslawsoltes/Svg.Skia/releases)._

## 5.2.3

## What's Changed
* Update SVG upstream and prepare v5.2.3 by @​wieslawsoltes in
wieslawsoltes/Svg.Skia#562


**Full Changelog**:
wieslawsoltes/Svg.Skia@v5.2.2...v5.2.3

## 5.2.2

## What's Changed
* Add styled Avalonia SVG source resources by @​wieslawsoltes in
wieslawsoltes/Svg.Skia#560
* Keep run typeface when character fallback finds nothing by
@​donaldsteele in wieslawsoltes/Svg.Skia#559
* Add net10.0 target to MAUI controls by @​wieslawsoltes in
wieslawsoltes/Svg.Skia#561

## New Contributors
* @​donaldsteele made their first contribution in
wieslawsoltes/Svg.Skia#559

**Full Changelog**:
wieslawsoltes/Svg.Skia@v5.2.1...v5.2.2

## 5.2.1

## What's Changed
* Fix Linux SkiaSharp native asset version mismatch by @​wieslawsoltes
in wieslawsoltes/Svg.Skia#555
* Fix Avalonia SVG opacity layers by @​wieslawsoltes in
wieslawsoltes/Svg.Skia#556


**Full Changelog**:
wieslawsoltes/Svg.Skia@v5.2.0...v5.2.1

## 5.2.0

## What's Changed
* Update SkiaSharp to 4.148.0 and HarfBuzzSharp to 14.2.0 by
@​mattleibow in wieslawsoltes/Svg.Skia#544
* Restore Avalonia CurrentColor and CSS overrides by @​wieslawsoltes in
wieslawsoltes/Svg.Skia#549
* Strong-name sign all packaged assemblies by @​wieslawsoltes in
wieslawsoltes/Svg.Skia#547
* Honor variable font weights during text shaping by @​wieslawsoltes in
wieslawsoltes/Svg.Skia#548
* Ensure svg model has no trimmer warnings by @​OleRoss in
wieslawsoltes/Svg.Skia#551

## New Contributors
* @​OleRoss made their first contribution in
wieslawsoltes/Svg.Skia#551

**Full Changelog**:
wieslawsoltes/Svg.Skia@v5.1.1...v5.2.0

Commits viewable in [compare
view](wieslawsoltes/Svg.Skia@v5.1.1...v5.2.3).
</details>

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=ShimSkiaSharp&package-manager=nuget&previous-version=5.1.1&new-version=5.2.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Svg.Controls.Skia.Avalonia 12.0.0.14 crashes in Linux when the application starts:

1 participant