From 2d25f7224f2763e6d0bdc43c4b96b8110957bc27 Mon Sep 17 00:00:00 2001 From: PerchunPak Date: Thu, 26 Dec 2024 12:51:38 +0100 Subject: [PATCH 1/2] libcava: init at 0.10.3 --- pkgs/by-name/li/libcava/package.nix | 38 +++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 pkgs/by-name/li/libcava/package.nix diff --git a/pkgs/by-name/li/libcava/package.nix b/pkgs/by-name/li/libcava/package.nix new file mode 100644 index 000000000000..4bb2d772936c --- /dev/null +++ b/pkgs/by-name/li/libcava/package.nix @@ -0,0 +1,38 @@ +{ + cava, + fetchFromGitHub, + nix-update-script, + meson, + ninja, +}: +cava.overrideAttrs (old: rec { + pname = "libcava"; + # fork may not be updated when we update upstream + version = "0.10.3"; + + src = fetchFromGitHub { + owner = "LukashonakV"; + repo = "cava"; + tag = version; + hash = "sha256-ZDFbI69ECsUTjbhlw2kHRufZbQMu+FQSMmncCJ5pagg="; + }; + + nativeBuildInputs = old.nativeBuildInputs ++ [ + meson + ninja + ]; + + # Automatically enable all optional dependencies + # (instead, Nix sets this option to "enabled" which + # forces all optional dependencies to be required + # or disabled individually) + mesonAutoFeatures = "auto"; + + dontVersionCheck = true; # no `bin/cava` + passthru.updateScript = nix-update-script { }; + + meta = old.meta // { + homepage = "https://github.com/LukashonakV/cava"; + description = "Fork of CAVA to build it as a shared library"; + }; +}) From 2a2e1459520e8067b9edd16dfd3b8fab46570d00 Mon Sep 17 00:00:00 2001 From: PerchunPak Date: Thu, 26 Dec 2024 13:13:04 +0100 Subject: [PATCH 2/2] waybar: libcava moved to a separate package --- pkgs/by-name/wa/waybar/package.nix | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/pkgs/by-name/wa/waybar/package.nix b/pkgs/by-name/wa/waybar/package.nix index e6d004a801bd..73e7a2116b35 100644 --- a/pkgs/by-name/wa/waybar/package.nix +++ b/pkgs/by-name/wa/waybar/package.nix @@ -16,6 +16,7 @@ hyprland, iniparser, jsoncpp, + libcava, libdbusmenu-gtk3, libevdev, libinotify-kqueue, @@ -74,15 +75,6 @@ waybar, }: -let - # Derived from subprojects/cava.wrap - libcava.src = fetchFromGitHub { - owner = "LukashonakV"; - repo = "cava"; - rev = "0.10.3"; - hash = "sha256-ZDFbI69ECsUTjbhlw2kHRufZbQMu+FQSMmncCJ5pagg="; - }; -in stdenv.mkDerivation (finalAttrs: { pname = "waybar"; version = "0.11.0";