Skip to content

Commit

Permalink
albyhub: init at 1.12.0
Browse files Browse the repository at this point in the history
  • Loading branch information
bleetube committed Dec 29, 2024
1 parent 308f45a commit e3e4277
Show file tree
Hide file tree
Showing 6 changed files with 3,788 additions and 0 deletions.
47 changes: 47 additions & 0 deletions pkgs/by-name/al/albyhub/breez-sdk-go/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
{
lib,
buildGoModule,
fetchFromGitHub,
stdenv,
go,
}:

buildGoModule rec {
pname = "breez-sdk-go";
version = "0.5.2";

src = fetchFromGitHub {
owner = "breez";
repo = "breez-sdk-go";
rev = "v${version}";
hash = "sha256-zE8GIMi/YopprNVT3rAGqykosCtuKKnVHBSObdp/ONo=";
};

vendorHash = null;
doCheck = false;

ldflags = [
"-s"
"-w"
];

installPhase = ''
mkdir -p $out/lib
case ${go.GOARCH} in
amd64|aarch64)
cp -v "${src}/breez_sdk/lib/linux-${go.GOARCH}/libbreez_sdk_bindings.so" $out/lib/
;;
*)
echo "Unsupported architecture: ${go.GOARCH}"
exit 1
;;
esac
'';

meta = {
description = "Embeds the BreezSDK runtime compiled as shared library objects";
homepage = "https://github.com/breez/breez-sdk-go/";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ bleetube ];
};
}
47 changes: 47 additions & 0 deletions pkgs/by-name/al/albyhub/glalby-go/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
{
lib,
buildGoModule,
fetchFromGitHub,
stdenv,
}:

buildGoModule rec {
pname = "glalby-go";
version = "unstable-2024-06-21";

src = fetchFromGitHub {
owner = "getAlby";
repo = "glalby-go";
rev = "95673c864d5954a6f78a24600876784b81af799f";
hash = "sha256-DwYOJkk0VzCMzHMUM+C31Kq8e6jIsBZNBQLgpylOe4E=";
};

vendorHash = null;

ldflags = [
"-s"
"-w"
];

CGO_ENABLED = 1;

installPhase = ''
mkdir -p $out/lib
case ${stdenv.hostPlatform.parsed.cpu.name} in
x86_64|aarch64)
cp -v "${src}/glalby/${stdenv.hostPlatform.parsed.cpu.name}-unknown-linux-gnu/libglalby_bindings.so" $out/lib/
;;
*)
echo "Unsupported architecture: ${stdenv.hostPlatform.parsed.cpu.name}"
exit 1
;;
esac
'';

meta = {
description = "Go bindings for https://github.com/getalby/glalby";
homepage = "https://github.com/getAlby/glalby-go";
license = lib.licenses.asl20; # https://github.com/getAlby/ldk-node-go/issues/27
maintainers = with lib.maintainers; [ bleetube ];
};
}
46 changes: 46 additions & 0 deletions pkgs/by-name/al/albyhub/ldk-node-go/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{
lib,
buildGoModule,
fetchFromGitHub,
stdenv,
}:

buildGoModule rec {
pname = "ldk-node-go";
version = "unstable-2024-12-11";

src = fetchFromGitHub {
owner = "getAlby";
repo = "ldk-node-go";
rev = "8911834564db720e9b22950441df706d69622d81";
hash = "sha256-vjXpvjPZlxOiTrcEbQW8YTnpQx7XbmPqYda+8UYyUvE=";
};

vendorHash = null;

ldflags = [
"-s"
"-w"
];

installPhase = ''
mkdir -p $out/lib
case ${stdenv.hostPlatform.parsed.cpu.name} in
x86_64|aarch64)
cp -v "${src}/ldk_node/${stdenv.hostPlatform.parsed.cpu.name}-unknown-linux-gnu/libldk_node.so" $out/lib/
;;
*)
echo "Unsupported architecture: ${stdenv.hostPlatform.parsed.cpu.name}"
exit 1
;;
esac
'';

meta = {
description = "Experimental Go bindings for LDK-node";
homepage = "https://github.com/getAlby/ldk-node-go";
license = lib.licenses.asl20; # https://github.com/getAlby/ldk-node-go/issues/27
maintainers = with lib.maintainers; [ ];
mainProgram = "ldk-node-go";
};
}
Loading

0 comments on commit e3e4277

Please sign in to comment.