2021-10-17 16:05:17 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, rustPlatform
|
|
|
|
, pkg-config
|
|
|
|
, Security
|
|
|
|
, openssl
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "hiksink";
|
2022-02-12 10:10:18 +00:00
|
|
|
version = "1.2.1";
|
2021-10-17 16:05:17 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "CornerBit";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2022-02-12 10:10:18 +00:00
|
|
|
sha256 = "sha256-k/cBCc7DywyBbAzCRCHdrOVmo+QVCsSgDn8hcyTIUI8=";
|
2021-10-17 16:05:17 +00:00
|
|
|
};
|
|
|
|
|
2022-02-12 10:10:18 +00:00
|
|
|
cargoSha256 = "sha256-vqzXpSPBwY7m/Fdob0mHH0OXnzyQwFk7x2kk9Tgez3M=";
|
2021-10-17 16:05:17 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkg-config
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
openssl
|
2022-10-06 16:38:53 +00:00
|
|
|
] ++ lib.optionals stdenv.isDarwin [
|
2021-10-17 16:05:17 +00:00
|
|
|
Security
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Tool to convert Hikvision camera events to MQTT";
|
|
|
|
homepage = "https://github.com/CornerBit/HikSink";
|
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
2022-04-01 19:34:55 +00:00
|
|
|
mainProgram = "hik_sink";
|
2021-10-17 16:05:17 +00:00
|
|
|
};
|
|
|
|
}
|