Skip to content

fix(macos): build without updater for --disable-auto-updater - #11465

Draft
i2h3 wants to merge 1 commit into
masterfrom
i2h3/mac-crafter-build-updater-off
Draft

i2h3 wants to merge 1 commit into
masterfrom
i2h3/mac-crafter-build-updater-off

Conversation

@i2h3

@i2h3 i2h3 commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

Resolves #9932.

Summary

A Mac App Store build must not contain a self-updater (#9932, part of #9941). Building with BUILD_UPDATER=OFF already leaves out Sparkle, the update check, the update settings and Sparkle's -spks/-spki temporary-exception entitlement. This needs no new BUILD_FOR_APP_STORE switch (#9935). Two gaps were left, and this PR closes them:

  • mac-crafter could not make such a build. --disable-auto-updater only skipped downloading Sparkle. BUILD_UPDATER stayed on, so the client still checked updates.nextcloud.org, offered a manual download link and kept the temporary exception. mac-crafter now passes -DBUILD_UPDATER=OFF with --disable-auto-updater and -DBUILD_UPDATER=ON without it, using Craft's nextcloud-client.args option. It passes the value in both cases because an incremental build reuses the previous CMake cache.
  • The Sparkle keys stayed in Info.plist. SUShowReleaseNotes, SUPublicDSAKeyFile, SUPublicEDKey and SUEnableInstallerLauncherService are now only written when BUILD_UPDATER is on. With the updater, the generated Info.plist is byte-identical to the one built from master.

Side effects for reviewers:

  • The NextcloudDev Xcode build (Craft.sh) uses --disable-auto-updater, so dev builds no longer contain any updater. The macOS CI build still compiles the updater, because it keeps the default BUILD_UPDATER=ON.
  • Craft's args option replaces, rather than extends, any nextcloud-client.args set in BlueprintSettings.ini. None is set in this repository. A dedicated buildUpdater option in desktop-client-blueprints would avoid that, but it has to land there before mac-crafter can use it.

Not changed: mac-crafter still tries to sign the Sparkle helpers and still writes a .tbz when Sparkle is absent. The signing attempts only log errors.

Tests

  • UpdaterCraftOptionsTests (swift test in admin/osx/mac-crafter): 13 of 13 tests pass.
  • SparkleInfoPlistKeysTest (new ctest) checks that the four keys are present when BUILD_UPDATER is on and absent when it is off. SparklePublicKeyTest now only runs when it is on. Run against a CMake configure on macOS with the Craft dependencies:
    • Against the Info.plist built from master with BUILD_UPDATER=OFF, the check fails with Unexpected SUShowReleaseNotes …. With this change, it passes.
    • With BUILD_UPDATER=ON, SparkleInfoPlistKeysTest and SparklePublicKeyTest both pass.
  • macOS CI only builds with the updater on, so CI runs only the "on" half of the new test.

TODO

  • Run mac-crafter build --disable-auto-updater --build-tests and check four things: the log says Compiling without updater; ctest -R Sparkle passes; codesign -d --entitlements :- <app> has no temporary-exception.mach-lookup.global-name; and the settings show no update section.
  • Run an incremental build without the flag in the same build path and check that the log says Compiling with updater and that Sparkle is bundled again.

No full Craft or mac-crafter build has been run for this change. The Craft side was checked by reading Craft's option handling, not by running it.

Checklist

AI (if applicable)

@i2h3 i2h3 self-assigned this Nov 30, 2026
@i2h3 i2h3 added this to the 36.0.0 milestone Nov 30, 2026
@github-project-automation github-project-automation Bot moved this to 🧭 Planning evaluation (don't pick) in 💻 Desktop Clients team Nov 30, 2026
@i2h3 i2h3 added os: 🍎 macOS Apple macOS, formerly also known as OS X feature: 📥 install and update labels Nov 30, 2026
@i2h3 i2h3 moved this from 🧭 Planning evaluation (don't pick) to 🏗️ In progress in 💻 Desktop Clients team Nov 30, 2026
@i2h3
i2h3 marked this pull request as draft November 30, 2026 15:08
The Mac App Store does not allow an app to update itself. Building with
BUILD_UPDATER=OFF already leaves out Sparkle, the update check and the
Sparkle temporary-exception entitlement, but mac-crafter could not make
such a build: --disable-auto-updater only skipped downloading Sparkle.
BUILD_UPDATER stayed on, so the client still polled the update server,
offered a manual download and kept the temporary exception.

BUILD_UPDATER is passed in both directions because an incremental build
keeps the value from the previous configure.

The Sparkle keys in Info.plist are only read by Sparkle, so they are
left out as well when the updater is not built.

Closes #9932.

Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: Iva Horn <iva.horn@nextcloud.com>
@i2h3
i2h3 force-pushed the i2h3/mac-crafter-build-updater-off branch from ba65fb1 to 780def5 Compare November 30, 2026 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature: 📥 install and update os: 🍎 macOS Apple macOS, formerly also known as OS X

Projects

Status: 🏗️ In progress

Development

Successfully merging this pull request may close these issues.

Remove Sparkle auto-updater (Mac App Store)

1 participant