nixpkgs/pkgs/development/python-modules/rns/default.nix
2026-06-03 06:19:56 +02:00

61 lines
1.2 KiB
Nix

{
lib,
bleak,
buildPythonPackage,
cryptography,
esptool,
fetchFromGitHub,
netifaces,
pyserial,
replaceVars,
setuptools,
versionCheckHook,
}:
buildPythonPackage (finalAttrs: {
pname = "rns";
version = "1.3.4";
pyproject = true;
__structuredAttrs = true;
src = fetchFromGitHub {
owner = "markqvist";
repo = "Reticulum";
tag = finalAttrs.version;
hash = "sha256-rhZfkSV2OtCVPbUyTrYry2lwIeSfz3JnX+mVTkZt+Rc=";
};
patches = [
(replaceVars ./unvendor-esptool.patch {
esptool = lib.getExe esptool;
})
];
build-system = [ setuptools ];
dependencies = [
bleak
cryptography
netifaces
pyserial
];
pythonImportsCheck = [ "RNS" ];
nativeCheckInputs = [ versionCheckHook ];
versionCheckProgram = "${placeholder "out"}/bin/rncp";
meta = {
description = "Cryptography-based networking stack for wide-area networks";
homepage = "https://reticulum.network";
changelog = "https://github.com/markqvist/Reticulum/blob/${finalAttrs.src.tag}/Changelog.md";
# Reticulum License
# https://github.com/markqvist/Reticulum/blob/master/LICENSE
license = lib.licenses.unfree;
maintainers = with lib.maintainers; [
fab
qbit
];
};
})