Honor caller-provided macOS deployment targets - #278
Draft
johnrichardrinehart wants to merge 1 commit into
Draft
Conversation
Keep a nonempty CMAKE_OSX_DEPLOYMENT_TARGET supplied by a caller or toolchain. Otherwise use MACOSX_DEPLOYMENT_TARGET from the environment, falling back to the existing 10.15.4 default when neither supplies a value. Mirror the selected target into the ordinary MACOSX_DEPLOYMENT_TARGET variable so bundle metadata agrees with the compiler deployment target.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The macOS setup unconditionally resets
CMAKE_OSX_DEPLOYMENT_TARGETandMACOSX_DEPLOYMENT_TARGETto10.15.4. This overrides the deployment target chosen by a consuming application, toolchain, or package builder.Change
CMAKE_OSX_DEPLOYMENT_TARGETsupplied by the caller/toolchain.MACOSX_DEPLOYMENT_TARGETenvironment value.10.15.4default.MACOSX_DEPLOYMENT_TARGETvariable to the selected CMake value so theLSMinimumSystemVersionsubstitution inbuildscripts/packaging/macOS/Info.plist.inremains consistent.A supplied CMake target takes precedence over a conflicting environment value. No cache value is forced, and the existing user override include is unchanged.
Verification and status
Draft: native macOS verification and human review are outstanding. No build, test, lint, or formatter commands were run for this submission. The downstream integrator will apply the immutable patch to the Audacity 4 release sources and perform validation separately. Current main, related build scripts, packaging metadata, and PR search results were inspected; no equivalent fix was found.
AI disclosure
This patch and PR text were prepared and submitted by an AI coding assistant at the repository owner's explicit request. The assistant cannot attest to the owner's CLA status or claim human understanding/sign-off.
Checklist
Validation update
Subsequent validation: the fetched patch applies to the Muse snapshot bundled with Audacity 4.0.0. Executing its CMake block preserves the 10.15.4 default, honors an environment-only target, and gives an explicit CMake target precedence. Package-level smoke checks preserve minimum 14.0 or overridden 15.0 across both Muse and Audacity setup blocks. The final Linux Audacity build passed; native Darwin review is now running.