Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{
2 lib,
3 rustPlatform,
4 fetchFromGitHub,
5 kclvm,
6 rustc,
7}:
8rustPlatform.buildRustPackage rec {
9 pname = "kclvm_cli";
10 version = "0.11.0";
11
12 src = fetchFromGitHub {
13 owner = "kcl-lang";
14 repo = "kcl";
15 rev = "v${version}";
16 hash = "sha256-wRmLXR1r/FtZVfc6jifEj0jS0U0HIgJzBtuuzLQchjo=";
17 };
18
19 sourceRoot = "${src.name}/cli";
20
21 cargoHash = "sha256-ZhrjxHqwWwcVkCVkJJnVm2CZLfRlrI2383ejgI+B2KQ=";
22 cargoPatches = [ ./cargo_lock.patch ];
23
24 buildInputs = [
25 kclvm
26 rustc
27 ];
28
29 meta = with lib; {
30 description = "High-performance implementation of KCL written in Rust that uses LLVM as the compiler backend";
31 homepage = "https://github.com/kcl-lang/kcl";
32 license = licenses.asl20;
33 platforms = platforms.linux ++ platforms.darwin;
34 maintainers = with maintainers; [
35 selfuryon
36 peefy
37 ];
38 mainProgram = "kclvm_cli";
39 };
40}