2021-04-03 10:01:27 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, fetchpatch
|
2021-01-19 06:50:56 +00:00
|
|
|
, doxygen, fontconfig, graphviz-nox, libxml2, pkg-config, which
|
2018-04-07 18:11:56 +00:00
|
|
|
, systemd }:
|
|
|
|
|
2021-04-03 10:01:27 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2019-08-13 21:52:01 +00:00
|
|
|
pname = "openzwave";
|
2021-04-03 10:01:27 +00:00
|
|
|
version = "1.6";
|
2018-04-07 18:11:56 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2021-04-03 10:01:27 +00:00
|
|
|
owner = "OpenZWave";
|
2018-04-07 18:11:56 +00:00
|
|
|
repo = "open-zwave";
|
2021-04-03 10:01:27 +00:00
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "0xgs4mmr0480c269wx9xkk67ikjzxkh8xcssrdx0f5xcl1lyd333";
|
2018-04-07 18:11:56 +00:00
|
|
|
};
|
|
|
|
|
2021-04-03 10:01:27 +00:00
|
|
|
patches = [
|
|
|
|
(fetchpatch {
|
|
|
|
name = "fix-strncat-build-failure.patch";
|
|
|
|
url = "https://github.com/OpenZWave/open-zwave/commit/601e5fb16232a7984885e67fdddaf5b9c9dd8105.patch";
|
|
|
|
sha256 = "1n1k5arwk1dyc12xz6xl4n8yw28vghzhv27j65z1nca4zqsxgza1";
|
|
|
|
})
|
|
|
|
(fetchpatch {
|
|
|
|
name = "fix-text-uninitialized.patch";
|
|
|
|
url = "https://github.com/OpenZWave/open-zwave/commit/3b029a467e83bc7f0054e4dbba1e77e6eac7bc7f.patch";
|
|
|
|
sha256 = "183mrzjh1zx2b2wzkj4jisiw8br7g7bbs167afls4li0fm01d638";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
outputs = [ "out" "doc" ];
|
|
|
|
|
2021-01-19 06:50:56 +00:00
|
|
|
nativeBuildInputs = [ doxygen fontconfig graphviz-nox libxml2 pkg-config which ];
|
2018-04-07 18:11:56 +00:00
|
|
|
|
|
|
|
buildInputs = [ systemd ];
|
|
|
|
|
2018-06-11 22:55:44 +00:00
|
|
|
hardeningDisable = [ "format" ];
|
|
|
|
|
2018-04-07 18:11:56 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2021-04-03 10:01:27 +00:00
|
|
|
makeFlags = [
|
|
|
|
"PREFIX=${placeholder "out"}"
|
|
|
|
];
|
2018-04-07 18:11:56 +00:00
|
|
|
|
|
|
|
FONTCONFIG_FILE="${fontconfig.out}/etc/fonts/fonts.conf";
|
|
|
|
FONTCONFIG_PATH="${fontconfig.out}/etc/fonts/";
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace cpp/src/Options.cpp \
|
|
|
|
--replace /etc/openzwave $out/etc/openzwave
|
|
|
|
'';
|
|
|
|
|
2021-01-21 17:00:13 +00:00
|
|
|
meta = with lib; {
|
2018-04-07 18:11:56 +00:00
|
|
|
description = "C++ library to control Z-Wave Networks via a USB Z-Wave Controller";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "http://www.openzwave.net/";
|
2018-04-07 18:11:56 +00:00
|
|
|
license = licenses.gpl3;
|
2022-07-14 12:39:58 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2018-04-07 18:11:56 +00:00
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|