-
Notifications
You must be signed in to change notification settings - Fork 19
/
default.nix
32 lines (32 loc) · 1.15 KB
/
default.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{ system ? builtins.currentSystem, nixpkgs ? import ./nix { inherit system; } }:
with nixpkgs;
let
subpath = import ./nix/gitSource.nix { inherit system nixpkgs; } ;
noNixFile = name: type:
let baseName = builtins.baseNameOf (builtins.toString name);
in !(lib.hasSuffix ".nix" name);
vessel = rustPlatform.buildRustPackage rec {
pname = "vessel";
version = "0.7.0";
buildInputs = [
openssl_3_0 openssl_3_0.dev
] ++ pkgs.lib.optional pkgs.stdenv.isDarwin
pkgs.darwin.apple_sdk.frameworks.Security;
nativeBuildInputs = [ pkg-config ];
src = lib.sources.cleanSourceWith {
filter = noNixFile;
src = subpath ./.;
};
cargoSha256 = "sha256-7lokhaImoo7Z89YSiS+v1OosI+hlLkpwvv0AkYn1FvE=";
verifyCargoDeps = true;
};
in rec {
inherit vessel;
# include shell in default.nix so that the nix cache will have pre-built versions
# of all the dependencies that are only depended on by nix-shell.
shell =
let extra-pkgs = [ easy-dhall.dhall-simple easy-dhall.dhall-lsp-simple ];
in vessel.overrideAttrs (old: {
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ extra-pkgs;
});
}