2024-02-19 20:40:03 +00:00
|
|
|
{
|
|
|
|
description = "Integration of RGB protocol on core lightning";
|
|
|
|
|
|
|
|
inputs = {
|
|
|
|
nixpkgs.url = "github:nixos/nixpkgs";
|
|
|
|
flake-utils.url = "github:numtide/flake-utils";
|
|
|
|
rust-overlay.url = "github:oxalica/rust-overlay";
|
|
|
|
};
|
|
|
|
|
|
|
|
outputs = { self, nixpkgs, flake-utils, rust-overlay, ... }:
|
|
|
|
flake-utils.lib.eachDefaultSystem (system:
|
|
|
|
let
|
|
|
|
pkgs = import nixpkgs {
|
|
|
|
inherit system;
|
|
|
|
overlays = [ rust-overlay.overlay ];
|
|
|
|
};
|
|
|
|
|
|
|
|
clightning = pkgs.clightning.overrideAttrs (oldAttrs: {
|
|
|
|
version = "rgb-hooks";
|
|
|
|
src = pkgs.fetchgit {
|
|
|
|
url = "https://github.com/vincenzopalazzo/lightning";
|
2024-03-04 22:08:00 +00:00
|
|
|
rev = "e1da6c799f302ea0346e352a07fbc083e4b7d0df";
|
|
|
|
sha256 = "sha256-zaTNd0KnokiQdeMG9cE6Yx5FbQBA4F3Lm2vvWiWWjR8=";
|
2024-02-19 20:40:03 +00:00
|
|
|
fetchSubmodules = true;
|
|
|
|
};
|
|
|
|
configureFlags = [ "--disable-rust" "--disable-valgrind" ];
|
|
|
|
});
|
|
|
|
in
|
|
|
|
{
|
|
|
|
packages = {
|
|
|
|
default = pkgs.gnumake;
|
|
|
|
};
|
|
|
|
formatter = pkgs.nixpkgs-fmt;
|
|
|
|
|
|
|
|
devShell = pkgs.mkShell {
|
|
|
|
buildInputs = with pkgs; [
|
|
|
|
# build dependencies
|
|
|
|
libcap
|
|
|
|
gcc
|
|
|
|
pkg-config
|
2024-02-20 10:56:30 +00:00
|
|
|
openssl
|
2024-02-19 20:40:03 +00:00
|
|
|
git
|
|
|
|
|
|
|
|
gnumake
|
|
|
|
|
|
|
|
rustc
|
|
|
|
cargo
|
|
|
|
|
|
|
|
# integration test dependencies
|
|
|
|
clightning
|
|
|
|
bitcoind
|
|
|
|
];
|
|
|
|
|
|
|
|
shellHook = ''
|
|
|
|
export HOST_CC=gcc
|
|
|
|
export PWD="$(pwd)"
|
2024-02-28 11:14:56 +00:00
|
|
|
export RUST_LOG=info
|
|
|
|
|
|
|
|
export PLUGIN_NAME=rgb-cln
|
2024-02-21 17:40:04 +00:00
|
|
|
|
|
|
|
make
|
2024-02-19 20:40:03 +00:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
}
|
|
|
|
);
|
|
|
|
}
|