Skip to content

feat(linux): make a wry build - #1852

Open
eleboucher wants to merge 4 commits into
devfrom
feat/wry-embedded-webkit
Open

feat(linux): make a wry build#1852
eleboucher wants to merge 4 commits into
devfrom
feat/wry-embedded-webkit

Conversation

@eleboucher

Copy link
Copy Markdown
Member

Description

Fixes #

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings

AI disclosure:

  • Partially AI assisted (clarify which code was AI assisted and briefly explain what it does).
  • Fully AI generated (explain what all the generated code does in moderate detail).

Stock WebKitGTK ships without ENABLE_WEB_RTC on most distros, so wry Linux
builds cannot place calls. Bundle the portable runtime built by the
webkitgtk-webrtc pipeline next to the binary instead of relying on the host.

scripts/webkit mirrors scripts/cef: fetch the pinned artifact, stage it into
webkit/ beside the binary, and package deb/rpm/AppImage from there. build.rs
adds the matching rpath and main.rs points the helper processes and GStreamer
at the bundle, all inert when it is absent.

copy-libs.sh refuses a runtime built without relocatable-exec-path.patch or
with a glibc floor above the host's, since both fail silently at runtime.

The CI job builds and uploads wry bundles as artifacts only; CEF stays the
shipped Linux path.
Points at run 13100, the first portable build carrying the relocation patch.

fetch.sh could never have worked: node wrote the manifest fields without a
trailing newline, so read returned 1 at EOF and set -e killed the script
before it printed anything. Every earlier test had bypassed fetch.sh via
SABLE_WEBKIT_RUNTIME_DIR.
Comment thread .github/workflows/tauri-build.yml Fixed
…time

Setting only GST_PLUGIN_SYSTEM_PATH_1_0 left GST_PLUGIN_PATH_1_0 unset, so
the host-probing block below filled it with /usr/lib/gstreamer-1.0. Those
plugins then loaded against the bundle's older GStreamer core and failed on
missing symbols, and one pulled in libsoup2 alongside WebKit's libsoup3,
aborting the web process and leaving the window blank.

Also drops the WebKit runtime cache step. CodeQL flagged it as cache
poisoning reachable from workflow_dispatch, and caching a binary runtime we
then ship is exactly the wrong thing to key on a file hash. The artifact is
a 131 MB download that takes seconds.
Derived by auditing the bundled runtime inside Ubuntu, Debian and Fedora
containers with a desktop package set, rather than assuming. The engine
needs libXtst, libXScrnSaver, libatomic, harfbuzz-icu, nghttp2, rsvg, psl,
tasn1, wayland-client/egl and xcb from the host, and none of them were
declared.

Also re-pins the runtime at run 13112.
@lunar-seal

Copy link
Copy Markdown
Contributor

Per https://blogs.igalia.com/webkit/blog/2026/wip-71/
Webkit dropped GstWebRTC WebKit/WebKit@6ae9a39 and thus webkitgtk uses libwebrtc instead.

This should then also use webkitgtk compiled with a libwebrtc backend going forward.

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.

3 participants