From e3a348908b5b7a729103d3d3b29186ff3cdca459 Mon Sep 17 00:00:00 2001 From: Hamish Mackenzie Date: Tue, 4 Mar 2025 14:16:49 +1300 Subject: [PATCH 1/2] Fix for older versions of nixpkgs Older versions of nixpkgs have `pkgs.darwin.apple_sdk.sdk` instead of `pkgs.apple-sdk`. --- modules/configuration-nix.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/configuration-nix.nix b/modules/configuration-nix.nix index c7195f1703..a3fe077ab9 100644 --- a/modules/configuration-nix.nix +++ b/modules/configuration-nix.nix @@ -199,7 +199,7 @@ in addPackageKeys { # for whatever reason nixpkgs 24.11 defines x86_64-darwin # to be sdk-10.12.2, and aarch64-darwin to be sdk-11. # nixpkgs 25.05 will drop sdk-10.12, and unify aarch64 and x86 at last. - packages.network.components.library.libs = lib.mkIf (pkgs.stdenv.hostPlatform.isDarwin && lib.versionOlder pkgs.apple-sdk.version "11") [ + packages.network.components.library.libs = lib.mkIf (pkgs.stdenv.hostPlatform.isDarwin && lib.versionOlder (pkgs.apple-sdk or pkgs.darwin.apple_sdk.sdk).version "11") [ pkgs.apple-sdk_11 (pkgs.darwinMinVersionHook "11.0") ]; From d01c98f7d24278a17d337a8b44ee379c1763d072 Mon Sep 17 00:00:00 2001 From: Hamish Mackenzie Date: Tue, 4 Mar 2025 15:01:03 +1300 Subject: [PATCH 2/2] Not sure where `pkgs.apple-sdk_11` is for older nixpkgs. --- modules/configuration-nix.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/configuration-nix.nix b/modules/configuration-nix.nix index a3fe077ab9..81f416eda7 100644 --- a/modules/configuration-nix.nix +++ b/modules/configuration-nix.nix @@ -199,7 +199,7 @@ in addPackageKeys { # for whatever reason nixpkgs 24.11 defines x86_64-darwin # to be sdk-10.12.2, and aarch64-darwin to be sdk-11. # nixpkgs 25.05 will drop sdk-10.12, and unify aarch64 and x86 at last. - packages.network.components.library.libs = lib.mkIf (pkgs.stdenv.hostPlatform.isDarwin && lib.versionOlder (pkgs.apple-sdk or pkgs.darwin.apple_sdk.sdk).version "11") [ + packages.network.components.library.libs = lib.mkIf (pkgs.stdenv.hostPlatform.isDarwin && pkgs ? apple-sdk && lib.versionOlder pkgs.apple-sdk.version "11") [ pkgs.apple-sdk_11 (pkgs.darwinMinVersionHook "11.0") ];