46 lines
928 B
Nix
46 lines
928 B
Nix
|
{
|
||
|
stdenv,
|
||
|
lib,
|
||
|
fetchFromGitLab,
|
||
|
rustPlatform,
|
||
|
pkg-config,
|
||
|
rocksdb,
|
||
|
}: let
|
||
|
meta = builtins.fromJSON (builtins.readFile ./meta.json);
|
||
|
|
||
|
rev = meta.rev;
|
||
|
sha256 = meta.sha256;
|
||
|
in
|
||
|
rustPlatform.buildRustPackage rec {
|
||
|
pname = "matrix-conduit";
|
||
|
version = "latest-${rev}";
|
||
|
|
||
|
src = fetchFromGitLab {
|
||
|
owner = "famedly";
|
||
|
repo = "conduit";
|
||
|
rev = "${rev}";
|
||
|
sha256 = "${sha256}";
|
||
|
};
|
||
|
|
||
|
cargoSha256 = "sha256-E9f7yJR2GksUHjWE4EP+iBRlhn4JG/JUVw7/L+41Nfc=";
|
||
|
|
||
|
nativeBuildInputs = [
|
||
|
rustPlatform.bindgenHook
|
||
|
pkg-config
|
||
|
];
|
||
|
|
||
|
buildInputs = [
|
||
|
rocksdb
|
||
|
];
|
||
|
|
||
|
cargoBuildFlags = ["--bin" "conduit"];
|
||
|
|
||
|
meta = with lib; {
|
||
|
broken = stdenv.isDarwin;
|
||
|
description = "A Matrix homeserver written in Rust";
|
||
|
homepage = "https://conduit.rs/";
|
||
|
license = licenses.asl20;
|
||
|
maintainers = with maintainers; [pstn piegames pimeys];
|
||
|
};
|
||
|
}
|