Skip to content

Release: an All Runtimes DMG with both MetalSharp Wine apps (#837) - #839

Open
aaf2tbz wants to merge 1 commit into
mainfrom
release/all-runtimes-dmg
Open

aaf2tbz wants to merge 1 commit into
mainfrom
release/all-runtimes-dmg

Conversation

@aaf2tbz

@aaf2tbz aaf2tbz commented Nov 24, 2026

Copy link
Copy Markdown
Collaborator

Closes #837.

This sets up a third release DMG, MetalSharp-<version>-All-Runtimes.dmg, which carries both runtimes. Merging it publishes nothing. The next v* tag builds this DMG next to the regular and FEX DMGs.

What the package is

  • It's the regular MetalSharp.app (MetalSharpVariant=regular, starting on x86_64) carrying both MetalSharp-Wine-x86_64.app and MetalSharp-Wine.app in Resources/. Both are copied unchanged and never re-signed, with the same CDHash checks as the other builds.
  • The backend already prefers a Wine app in Resources (app_source), so the FEX | x86_64 toggle sets up either runtime with nothing to download. An update also refreshes the inactive runtime from the app (ms_wine_refresh_inactive_app).
  • Info.plist has MetalSharpPackage=all, and Sparkle reads appcast-all.xml. An All Runtimes install updates to the next All Runtimes build, so it keeps both runtimes.

Changes

  • Packaging:
    • METALSHARP_PACKAGE=all (package-app.sh → package-local-preview.sh) requires METALSHARP_WINE_X86_64_APP and METALSHARP_WINE_APP, and refuses the FEX variant.
    • package-gpui-dmg.sh checks that the app's MetalSharpPackage matches, verifies both nested apps, names the DMG, and stages it next to the output because two Wine apps are several GB.
    • build-dmg.sh supports it too.
  • tools/dmg/verify-all-runtimes-dmg.sh (new):
    • Checks the identity, variant, package key and the feed.
    • Checks that both rule sets, both Wine apps (verified, Developer ID, same team) and MetalSharp-Wine.app's cross-architecture entitlement and profile are present.
    • Checks that each Wine app's CDHash matches its source, and that no runtime bundles ship.
    • Checks that the DMG name contains neither FEX nor arm64.
  • Sparkle: sparkle_release.py --variant all makes MetalSharp-X-All-Runtimes.zip, its -from<old>.delta files from earlier All Runtimes releases, and appcast-all.xml.
  • Release CI:
    • A new build-all job downloads both zips from the pinned MetalSharp Wine release (each checked against SHA256SUMS and codesign).
    • It then packages, notarizes the app for Sparkle, publishes Sparkle, builds, verifies, signs and notarizes the DMG, and writes DMG-SIGNING-ALL.txt.
    • The release job is optional on it, as with build-fex, so a failure leaves the DMG out instead of blocking the release. It publishes the DMG, zip, deltas and appcast-all.xml.
    • The flatten checks still require exactly one regular arm64 DMG.
  • Updaters can't mix it up:
    • Every in-app DMG updater since 1.0 (updater.c release_assets_find) puts names containing FEX in the FEX slot and prefers an arm64 name for the regular one. A name with neither never displaces the regular DMG, so 1.5.0 and older are safe without a change.
    • The backend now also skips All-Runtimes names explicitly. updater_test.py lists the asset first in the synthetic release.
  • Contract and docs:
    • verify-dmg-workflow.py checks the new job, the feed, the DMG name and the updater skip.
    • Updated AGENTS.md, docs/{development,updates,architecture,user-guide}.md and the CHANGELOG (Unreleased).

Things to know before the next release

  • Runner disk: this job holds both Wine apps, the packaged app, the Sparkle zip and the DMG staging at once. If macos-26 runs short, it fails alone and the release goes out without this DMG. A self-hosted runner or a disk-cleanup step would fix that.
  • DMG fallback: an All Runtimes install that updates through a DMG gets the regular build's DMG, which doesn't carry MetalSharp-Wine.app. That happens on a build switch, or on a release without appcast-all.xml. The FEX runtime stays installed, and is downloaded again only if uninstalled.
  • Merge order: CHANGELOG will conflict with Game Jolt page and art, game settings on every Collection grid, lanes after a runtime switch, launch summaries (#822–#835) #838's Unreleased section; it's a trivial merge.

PR Readiness (MANDATORY)

  • Real-game launch test completed for game/runtime/graphics/compatibility changes: N/A for launches. The DMG itself hasn't been built: that needs macOS and both signed Wine apps, so the first real run is the next tag. A workflow_dispatch run of Release CI would show it beforehand.
  • No hardcoded paths, secrets, or absolute /Users/... paths introduced
  • Config/rules TOML validated if changed (N/A: not changed)
  • Version metadata in sync if version bumped (N/A: no version bump)
  • Bottle/runtime migration and launch behavior preserved. The regular and FEX packaging and DMGs are unchanged when METALSHARP_PACKAGE is unset. Rollback: revert this PR.
  • Docs / compatibility matrix updated (CHANGELOG, AGENTS, development, updates, architecture, user guide)
  • Regression test added (updater_test.py, test_sparkle_release.py, the DMG workflow contract)

Tests (Linux)

  • python3 tools/ci/verify-dmg-workflow.py passes.
  • python3 -m unittest tools.sparkle.tests.test_sparkle_release passes: the "all" names, deltas only from earlier All Runtimes releases, and no FEX or arm64 in its names.
  • python3 -m unittest tools.dmg.tests.test_sign_notarize_dmg passes.
  • tools/ci/shellcheck.sh and shellcheck -S warning are clean on the changed scripts; bash -n passes on all of them; release.yml parses.
  • clang-format-diff is clean on updater.c. updater_test.py and the C build run in the macOS CI here.

Generated by Claude Code

A third release DMG, MetalSharp-<version>-All-Runtimes.dmg: the regular
MetalSharp.app carrying MetalSharp-Wine-x86_64.app and MetalSharp-Wine.app,
both unchanged, so the FEX | x86_64 toggle never downloads a runtime.

- Packaging: METALSHARP_PACKAGE=all (package-app.sh, package-local-preview.sh)
  needs both Wine apps, writes MetalSharpPackage=all and reads Sparkle's
  appcast-all.xml; package-gpui-dmg.sh names and checks the DMG, and
  verify-all-runtimes-dmg.sh verifies both nested apps against their sources.
- Sparkle: an "all" variant (MetalSharp-X-All-Runtimes.zip, its deltas,
  appcast-all.xml).
- Release CI: a build-all job from the pinned MetalSharp Wine release, optional
  in the release like build-fex; the release publishes its DMG, archive,
  deltas and appcast.
- Updaters: the name has neither "FEX" nor "arm64", which every in-app updater
  picks the regular and FEX DMGs by; the backend also skips it by name.

Nothing is released by merging this: the next tag builds it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Combine both systems into one package.

1 participant