nixpkgs/pkgs/servers/domoticz/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

92 lines
2.0 KiB
Nix
Raw Normal View History

{ lib, stdenv,
fetchFromGitHub,
2020-04-30 11:49:28 +00:00
makeWrapper,
cmake,
python3,
openssl,
pkg-config,
mosquitto,
lua5_3,
sqlite,
jsoncpp,
zlib,
boost,
curl,
git,
libusb-compat-0_1,
cereal
}:
stdenv.mkDerivation rec {
pname = "domoticz";
2024-02-01 01:44:46 +00:00
version = "2024.4";
src = fetchFromGitHub {
owner = "domoticz";
repo = pname;
rev = version;
2024-02-01 01:44:46 +00:00
sha256 = "sha256-bIA7Dx8XV2zT2Cdm4CwKX6xfedBREhevE/bN76o4r78=";
fetchSubmodules = true;
};
2020-04-30 11:49:28 +00:00
buildInputs = [
openssl
python3
mosquitto
lua5_3
sqlite
jsoncpp
boost
zlib
curl
git
libusb-compat-0_1
cereal
];
nativeBuildInputs = [
cmake
pkg-config
makeWrapper
];
cmakeFlags = [
"-DUSE_BUILTIN_MQTT=false"
"-DUSE_BUILTIN_LUA=false"
"-DUSE_BUILTIN_SQLITE=false"
"-DUSE_BUILTIN_JSONCPP=false"
"-DUSE_BUILTIN_ZLIB=false"
"-DUSE_OPENSSL_STATIC=false"
"-DUSE_STATIC_BOOST=false"
"-DUSE_BUILTIN_MINIZIP=true"
];
installPhase = ''
mkdir -p $out/share/domoticz
cp -r $src/www $out/share/domoticz/
cp -r $src/Config $out/share/domoticz
cp -r $src/scripts $out/share/domoticz
cp -r $src/plugins $out/share/domoticz
mkdir -p $out/bin
cp domoticz $out/bin
wrapProgram $out/bin/domoticz --set LD_LIBRARY_PATH ${python3}/lib;
'';
meta = with lib; {
2020-04-30 11:49:28 +00:00
description = "Home automation system";
longDescription = ''
Domoticz is a home automation system that lets you monitor and configure
various devices like: lights, switches, various sensors/meters like
temperature, rain, wind, UV, electra, gas, water and much more
'';
maintainers = with maintainers; [ edcragg ];
homepage = "https://www.domoticz.com/";
2023-02-20 11:26:04 +00:00
changelog = "https://github.com/domoticz/domoticz/blob/${version}/History.txt";
license = licenses.gpl3Plus;
2020-04-30 11:49:28 +00:00
platforms = platforms.all;
2021-12-26 18:50:25 +00:00
broken = stdenv.isDarwin; # never built on Hydra https://hydra.nixos.org/job/nixpkgs/staging-next/domoticz.x86_64-darwin
2023-11-27 01:17:53 +00:00
mainProgram = "domoticz";
2020-04-30 11:49:28 +00:00
};
}