Skip to content

fix: remove darwin.apple_sdk.frameworks.AppKit reference - #97

Merged
hanebox merged 1 commit into
nostacks:mainfrom
willcforte:deprecate-appkit-ref
Oct 3, 2026
Merged

hanebox merged 1 commit into
nostacks:mainfrom
willcforte:deprecate-appkit-ref

Conversation

@willcforte

@willcforte willcforte commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

Problem

Building packages.default (or devShells.default) for MacOS (Darwin) fails during evaluation:

error: darwin.apple_sdk_11_0 has been removed as it was a legacy compatibility stub; see <https://nixos.org/manual/nixpkgs/stable/#sec-darwin-legacy-frameworks> for migration instructions

Cause

flake.nix references the legacy darwin.apple_sdk.frameworks.AppKit attribute in both packages.default.buildInputs and devShells.default.buildInputs.

nixpkgs removed darwin.apple_sdk{ , _11_0, _12_3} in NixOS/nixpkgs#429387. As per nixpkgs migration notes:

You may see references to darwin.apple_sdk.frameworks. This is the legacy SDK pattern, and it is being phased out. All packages in darwin.apple_sdk, darwin.apple_sdk_11_0, and darwin.apple_sdk_12_3 have been removed. If your derivation references them, you should delete those references, as the default SDK should be enough to build your package.

So any nixpkgs version after this (e.g. nixos-unstable) will trigger this evaluation error.

This deprecation only breaks compatibility for nixpkgs versions before NixOS/nixpkgs#346043 merged on October 10th, 2024.

Changes made

This PR removes apple_sdk.frameworks.AppKit buildInput from packages.default and devShells.default.

Testing

Verified on aarch64-darwin:

$ nix build .#default --no-link --print-out-paths
/nix/store/ch8l9jlgg7jsyd3by68ihkn7a4a8g32d-ekphos-0.60.0

Build completes cleanly on my machine.
Yay! This is my first OSS PR :)

nixpkgs removed the legacy darwin.apple_sdk attribute set (and
apple_sdk_11_0/apple_sdk_12_3) in NixOS/nixpkgs#429387, replacing it
with a throwing stub. Any nixpkgs revision after that PR (merged
2025-08-16) fails to evaluate this flake on *-darwin systems:

    error: darwin.apple_sdk_11_0 has been removed as it was a legacy
    compatibility stub; see
    <https://nixos.org/manual/nixpkgs/stable/#sec-darwin-legacy-frameworks>
    for migration instructions

Per the migration notes, the default SDK now provides AppKit without
an explicit buildInput, so the reference can simply be dropped.

Verified: nix build .#default succeeds on aarch64-darwin with this change.
@willcforte willcforte changed the title fix(flake): drop removed darwin.apple_sdk.frameworks.AppKit buildInput fix: remove darwin.apple_sdk.frameworks.AppKit Oct 3, 2026
@willcforte willcforte changed the title fix: remove darwin.apple_sdk.frameworks.AppKit fix: remove darwin.apple_sdk.frameworks.AppKit reference Oct 3, 2026
@willcforte
willcforte marked this pull request as ready for review October 3, 2026 00:18
@hanebox

hanebox commented Oct 3, 2026

Copy link
Copy Markdown
Member

Congrats on your first PR!! 🙌

Thanks! will merge this asap

@hanebox
hanebox merged commit fe50783 into nostacks:main Oct 3, 2026
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.

2 participants