From 5cb7783a167c359f8f4becb50c54a2bf1e67ea38 Mon Sep 17 00:00:00 2001 From: Jakob Lechner Date: Wed, 29 Oct 2025 14:07:06 +0100 Subject: [PATCH] Use avahi-daemon release candidate Let's see if this fixes the high CPU load issues. --- modules/avahi.nix | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/modules/avahi.nix b/modules/avahi.nix index d0653bf..c12bd75 100644 --- a/modules/avahi.nix +++ b/modules/avahi.nix @@ -1,8 +1,35 @@ -{ config, lib, ... }: +{ config, lib, pkgs, ... }: lib.mkIf config.jalr.gui.enable { services.avahi = { enable = true; + package = + let + xmltoman = pkgs.xmltoman.overrideAttrs (_: { + nativeBuildInputs = [ + pkgs.installShellFiles + ]; + buildInputs = [ + (pkgs.perl.withPackages (pl: [ + pl.XMLParser + ])) + ]; + }); + in + pkgs.avahi.overrideAttrs (o: rec { + version = "0.9-rc2"; + src = pkgs.fetchurl { + url = "https://github.com/avahi/avahi/archive/refs/tags/v${version}.tar.gz"; + sha256 = "sha256-9k7+1qlyz5LLLfs1q/aqkXPWK4Q7FYUML0CvdqQjj4o="; + }; + patches = [ ]; + buildInputs = o.buildInputs ++ [ pkgs.systemdLibs ]; + nativeBuildInputs = o.nativeBuildInputs ++ [ xmltoman ]; + installFlags = [ + "runstatedir=${placeholder "out"}/run" + "sysconfdir=${placeholder "out"}/etc" + ]; + }); nssmdns4 = true; extraConfig = '' [server]