nixpkgs-suyu/nixos/modules/services/x11/desktop-managers/kodi.nix
Christian Kögler 8f12a72488 kodi: fix lirc support
* adapted to the way kodi finds the lircd socket
* added lirc package to build support for lirc
2020-03-22 12:47:25 +01:00

30 lines
582 B
Nix

{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.services.xserver.desktopManager.kodi;
in
{
options = {
services.xserver.desktopManager.kodi = {
enable = mkOption {
default = false;
description = "Enable the kodi multimedia center.";
};
};
};
config = mkIf cfg.enable {
services.xserver.desktopManager.session = [{
name = "kodi";
start = ''
LIRC_SOCKET_PATH=/run/lirc/lircd ${pkgs.kodi}/bin/kodi --standalone &
waitPID=$!
'';
}];
environment.systemPackages = [ pkgs.kodi ];
};
}