mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-27 01:13:05 +00:00
tree-sitter: macOS compatibility
This commit is contained in:
parent
aea7f1b540
commit
a63c72212c
@ -5,6 +5,7 @@
|
|||||||
, callPackage
|
, callPackage
|
||||||
, enableShared ? true
|
, enableShared ? true
|
||||||
, enableStatic ? false
|
, enableStatic ? false
|
||||||
|
, Security
|
||||||
}:
|
}:
|
||||||
|
|
||||||
# TODO: move to carnix or https://github.com/kolloch/crate2nix
|
# TODO: move to carnix or https://github.com/kolloch/crate2nix
|
||||||
@ -51,6 +52,8 @@ in rustPlatform.buildRustPackage {
|
|||||||
pname = "tree-sitter";
|
pname = "tree-sitter";
|
||||||
inherit src version cargoSha256;
|
inherit src version cargoSha256;
|
||||||
|
|
||||||
|
buildInputs = lib.optionals stdenv.isDarwin [ Security ];
|
||||||
|
|
||||||
nativeBuildInputs = [ emscripten which ];
|
nativeBuildInputs = [ emscripten which ];
|
||||||
|
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
@ -103,9 +106,8 @@ in rustPlatform.buildRustPackage {
|
|||||||
'';
|
'';
|
||||||
license = lib.licenses.mit;
|
license = lib.licenses.mit;
|
||||||
maintainers = with lib.maintainers; [ Profpatsch ];
|
maintainers = with lib.maintainers; [ Profpatsch ];
|
||||||
# Darwin needs some more work with default libraries
|
|
||||||
# Aarch has test failures with how tree-sitter compiles the generated C files
|
# Aarch has test failures with how tree-sitter compiles the generated C files
|
||||||
broken = stdenv.isDarwin || stdenv.isAarch64;
|
broken = stdenv.isAarch64;
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -11885,7 +11885,9 @@ in
|
|||||||
|
|
||||||
travis = callPackage ../development/tools/misc/travis { };
|
travis = callPackage ../development/tools/misc/travis { };
|
||||||
|
|
||||||
tree-sitter = callPackage ../development/tools/parsing/tree-sitter { };
|
tree-sitter = callPackage ../development/tools/parsing/tree-sitter {
|
||||||
|
inherit (darwin.apple_sdk.frameworks) Security;
|
||||||
|
};
|
||||||
|
|
||||||
trellis = callPackage ../development/tools/trellis { };
|
trellis = callPackage ../development/tools/trellis { };
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user