mirror of
https://github.com/ggml-org/llama.cpp.git
synced 2026-07-23 11:10:55 -05:00
nix: support unified apple-sdk
This commit is contained in:
@@ -13,6 +13,7 @@
|
||||
cudaPackages,
|
||||
autoAddDriverRunpath,
|
||||
darwin,
|
||||
apple-sdk ? null,
|
||||
rocmPackages,
|
||||
vulkan-headers,
|
||||
vulkan-loader,
|
||||
@@ -76,15 +77,17 @@ let
|
||||
'';
|
||||
|
||||
# apple_sdk is supposed to choose sane defaults, no need to handle isAarch64
|
||||
# separately
|
||||
# separately.
|
||||
# Modern Nixpkgs (25.05+) provides a unified 'apple-sdk' derivation.
|
||||
# Legacy Nixpkgs (24.05/24.11) uses 'darwin.apple_sdk.frameworks'.
|
||||
darwinBuildInputs =
|
||||
with darwin.apple_sdk.frameworks;
|
||||
[
|
||||
Accelerate
|
||||
CoreVideo
|
||||
CoreGraphics
|
||||
]
|
||||
++ optionals useMetalKit [ MetalKit ];
|
||||
if apple-sdk != null then
|
||||
# Unified SDK: single package provides all frameworks
|
||||
[ apple-sdk ]
|
||||
else
|
||||
with darwin.apple_sdk.frameworks;
|
||||
[ Accelerate CoreVideo CoreGraphics ]
|
||||
++ lib.optional useMetalKit MetalKit;
|
||||
|
||||
cudaBuildInputs = with cudaPackages; [
|
||||
cuda_cudart
|
||||
|
||||
Reference in New Issue
Block a user