fix(tvix): fix build on darwin
on macOS additional framework was needed to build tvix build Change-Id: I0e327378d1bd4837f62496c4c6e66bc489ddedb4 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10747 Tested-by: BuildkiteCI Reviewed-by: tazjin <tazjin@tvl.su>
This commit is contained in:
parent
40d81d0c74
commit
70c068df51
1 changed files with 7 additions and 3 deletions
|
@ -7,7 +7,10 @@ let
|
|||
iconvDarwinDep = lib.optional pkgs.stdenv.isDarwin pkgs.libiconv;
|
||||
|
||||
# On Darwin, some crates producing binaries need to be able to link against security.
|
||||
securityDarwinDep = lib.optional pkgs.stdenv.isDarwin pkgs.buildPackages.darwin.apple_sdk.frameworks.Security;
|
||||
darwinDeps = lib.optionals pkgs.stdenv.isDarwin (with pkgs.buildPackages.darwin.apple_sdk.frameworks; [
|
||||
Security
|
||||
SystemConfiguration
|
||||
]);
|
||||
|
||||
# Load the crate2nix crate tree.
|
||||
crates = import ./Cargo.nix {
|
||||
|
@ -47,6 +50,7 @@ let
|
|||
tvix-build = prev: {
|
||||
PROTO_ROOT = depot.tvix.build.protos.protos;
|
||||
nativeBuildInputs = protobufDep prev;
|
||||
buildInputs = darwinDeps;
|
||||
};
|
||||
|
||||
tvix-castore = prev: {
|
||||
|
@ -55,7 +59,7 @@ let
|
|||
};
|
||||
|
||||
tvix-cli = prev: {
|
||||
buildInputs = prev.buildInputs or [ ] ++ securityDarwinDep;
|
||||
buildInputs = prev.buildInputs or [ ] ++ darwinDeps;
|
||||
};
|
||||
|
||||
tvix-store = prev: {
|
||||
|
@ -63,7 +67,7 @@ let
|
|||
nativeBuildInputs = protobufDep prev;
|
||||
# fuse-backend-rs uses DiskArbitration framework to handle mount/unmount on Darwin
|
||||
buildInputs = prev.buildInputs or [ ]
|
||||
++ securityDarwinDep
|
||||
++ darwinDeps
|
||||
++ lib.optional pkgs.stdenv.isDarwin pkgs.buildPackages.darwin.apple_sdk.frameworks.DiskArbitration;
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue