Skip to content

Commit

Permalink
Add cardano-http-bridge to environment of stack --nix
Browse files Browse the repository at this point in the history
Relates to #5
  • Loading branch information
rvl committed Mar 15, 2019
1 parent 840869f commit ba85795
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 0 deletions.
2 changes: 2 additions & 0 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,6 @@

{
inherit pkgs;

cardano-http-bridge = import ./nix/cardano-http-bridge.nix { inherit pkgs; };
}
23 changes: 23 additions & 0 deletions nix/cardano-http-bridge.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{ nixpkgs ? fetchTarball channel:nixos-19.03
, pkgs ? import nixpkgs {}
}:

with pkgs;

rustPlatform.buildRustPackage {
name = "cardano-http-bridge";

src = fetchFromGitHub {
owner = "input-output-hk";
repo = "cardano-http-bridge";
fetchSubmodules = true;
rev = "b81c805e0fe62e6b8eacdc11fee573fa5668cbc8";
sha256 = "0vkg1hgcg9xqwzi9a1rap12sgyvc7ppnf89rqlf8pgsz3akzr4qd";
};

buildInputs = [ sqlite protobuf rustfmt ];

PROTOC = "${protobuf}/bin/protoc";

cargoSha256 = "19g5fy8af65vd9rl66058c67nlrz7r6mjd0cy83865d7q81hdl8r";
}
1 change: 1 addition & 0 deletions nix/stack-shell.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ haskell.lib.buildStackProject {

buildInputs = [
zlib gmp ncurses lzma openssl git
walletPackages.cardano-http-bridge
] ++ (lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [ Cocoa CoreServices libcxx libiconv ]));

phases = ["nobuildPhase"];
Expand Down

0 comments on commit ba85795

Please sign in to comment.