nixpkgs/pkgs/by-name/op/openzwave/package.nix
aleksana 571c71e6f7 treewide: migrate packages to pkgs/by-name, take 1
We are migrating packages that meet below requirements:

1. using `callPackage`
2. called path is a directory
3. overriding set is empty (`{ }`)
4. not containing path expressions other than relative path (to
makenixpkgs-vet happy)
5. not referenced by nix files outside of the directory, other
than`pkgs/top-level/all-packages.nix`
6. not referencing nix files outside of the directory
7. not referencing `default.nix` (since it's changed to `package.nix`)
8. `outPath` doesn't change after migration

The tool is here: https://github.com/Aleksanaa/by-name-migrate.
2024-11-09 20:04:51 +08:00

48 lines
1.2 KiB
Nix

{ lib, stdenv, fetchFromGitHub
, doxygen, fontconfig, graphviz-nox, libxml2, pkg-config, which
, systemd }:
stdenv.mkDerivation rec {
pname = "openzwave";
version = "1.6-unstable-2022-11-17";
src = fetchFromGitHub {
owner = "OpenZWave";
repo = "open-zwave";
rev = "3fff11d246a0d558d26110e1db6bd634a1b347c0";
hash = "sha256-CLK2MeoTmZ8GMKb1OAZFNLyc4C+k+REK2w+WQxZv0/E=";
};
outputs = [ "out" "doc" ];
nativeBuildInputs = [ doxygen fontconfig graphviz-nox libxml2 pkg-config which ];
buildInputs = [ systemd ];
hardeningDisable = [ "format" ];
enableParallelBuilding = true;
makeFlags = [
"PREFIX=${placeholder "out"}"
];
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
substituteInPlace cpp/build/Makefile \
--replace "-Werror" "-Werror -Wno-format"
'';
meta = with lib; {
description = "C++ library to control Z-Wave Networks via a USB Z-Wave Controller";
homepage = "http://www.openzwave.net/";
license = licenses.gpl3;
maintainers = [ ];
platforms = platforms.linux;
};
}