default.nix file

Signed-off-by: Christine Dodrill <me@christine.website>
This commit is contained in:
Cadey Ratio 2021-04-25 12:30:00 -04:00
parent 9c172287ac
commit abd6ae4348
2 changed files with 19 additions and 0 deletions

1
.gitignore vendored
View File

@ -1 +1,2 @@
/target
result

18
default.nix Normal file
View File

@ -0,0 +1,18 @@
{ pkgs ? import <nixpkgs> { }, rustPlatform ? pkgs.rustPlatform
, pkg-config ? pkgs.pkg-config, dbus ? pkgs.dbus }:
let
src = builtins.filterSource
(path: type: type != "directory" || builtins.baseNameOf path != "target")
./.;
in rustPlatform.buildRustPackage rec {
pname = "nanpa";
version = "0.1.0";
inherit src;
buildInputs = [ dbus ];
nativeBuildInputs = [ pkg-config ];
cargoSha256 = "1brlq4ilzhbz25sblcqxl2hkd8g7i79g6xijrzmk5fbb4qlq1fz7";
}