2021-01-25 08:26:54 +00:00
|
|
|
{ lib, rustPlatform, fetchFromGitHub
|
2019-04-07 13:29:30 +01:00
|
|
|
, libsodium, openssl
|
2021-01-17 03:51:22 +00:00
|
|
|
, pkg-config
|
2021-11-04 17:07:13 +00:00
|
|
|
, fetchpatch
|
2019-04-07 13:29:30 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
with rustPlatform;
|
|
|
|
|
|
|
|
buildRustPackage rec {
|
2019-08-31 12:41:23 +01:00
|
|
|
pname = "tox-node";
|
2021-02-06 22:35:57 +00:00
|
|
|
version = "0.1.1";
|
2019-04-07 13:29:30 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "tox-rs";
|
|
|
|
repo = "tox-node";
|
|
|
|
rev = "v${version}";
|
2021-02-06 22:35:57 +00:00
|
|
|
sha256 = "sha256-tB6v2NEBdTNHf89USdQOr/pV0mbxxb8ftOYPPJMvz5Y=";
|
2019-04-07 13:29:30 +01:00
|
|
|
};
|
|
|
|
|
2021-11-04 17:07:13 +00:00
|
|
|
cargoPatches = [
|
|
|
|
# update cargo lock
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/tox-rs/tox-node/commit/63712d49d84e55df7bba9710e129780bbc636de3.patch";
|
|
|
|
sha256 = "sha256-jI6b5IHsAuGuM+7sPCdFnOOuV6K9rBmc5QqU5x72Fl0=";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2019-04-07 13:29:30 +01:00
|
|
|
buildInputs = [ libsodium openssl ];
|
2021-01-17 03:51:22 +00:00
|
|
|
nativeBuildInputs = [ pkg-config ];
|
2019-04-07 13:29:30 +01:00
|
|
|
|
|
|
|
SODIUM_USE_PKG_CONFIG = "yes";
|
|
|
|
|
|
|
|
doCheck = false;
|
|
|
|
|
2021-11-04 17:07:13 +00:00
|
|
|
cargoSha256 = "sha256-yHsYjKJJNjepvcNszj4XQ0DbOY3AEJMZOnz0cAiwO1A=";
|
2019-04-07 13:29:30 +01:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2019-04-07 13:29:30 +01:00
|
|
|
description = "A server application to run tox node written in pure Rust";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/tox-rs/tox-node";
|
2020-10-07 21:37:19 +01:00
|
|
|
license = [ licenses.gpl3Plus ];
|
2019-04-07 13:29:30 +01:00
|
|
|
platforms = platforms.linux;
|
2021-11-04 17:59:18 +00:00
|
|
|
maintainers = with maintainers; [ suhr kurnevsky ];
|
2019-04-07 13:29:30 +01:00
|
|
|
};
|
|
|
|
}
|