2024-10-24 02:23:41 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
stdenv,
|
|
|
|
fetchFromGitHub,
|
|
|
|
autoreconfHook,
|
|
|
|
autoconf-archive,
|
|
|
|
alsa-lib,
|
|
|
|
fftw,
|
|
|
|
iniparser,
|
2024-10-24 02:43:08 +00:00
|
|
|
libGL,
|
2024-10-24 02:23:41 +00:00
|
|
|
libpulseaudio,
|
2024-10-24 02:43:08 +00:00
|
|
|
libtool,
|
2024-10-24 02:23:41 +00:00
|
|
|
ncurses,
|
2024-10-24 02:43:08 +00:00
|
|
|
pipewire,
|
2024-10-24 02:23:41 +00:00
|
|
|
pkgconf,
|
2024-10-24 02:43:08 +00:00
|
|
|
portaudio,
|
2024-10-24 02:23:41 +00:00
|
|
|
SDL2,
|
2024-10-24 02:59:18 +00:00
|
|
|
versionCheckHook,
|
2024-10-24 02:23:41 +00:00
|
|
|
withSDL2 ? false,
|
2024-10-24 02:43:08 +00:00
|
|
|
withPipewire ? stdenv.hostPlatform.isLinux,
|
2023-08-16 18:54:35 +00:00
|
|
|
}:
|
2014-12-11 23:09:24 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "cava";
|
2024-05-15 01:25:56 +00:00
|
|
|
version = "0.10.2";
|
2023-08-16 18:54:35 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "karlstav";
|
|
|
|
repo = "cava";
|
|
|
|
rev = version;
|
2024-05-15 01:25:56 +00:00
|
|
|
hash = "sha256-y6RslsU/zmr0Ai/rnr73N3OtjuBcWa3JCwh9P5GkNss=";
|
2023-08-16 18:54:35 +00:00
|
|
|
};
|
2014-12-11 23:09:24 +00:00
|
|
|
|
2024-10-24 02:23:41 +00:00
|
|
|
buildInputs =
|
|
|
|
[
|
|
|
|
fftw
|
2024-10-24 02:43:08 +00:00
|
|
|
iniparser
|
2024-10-24 02:23:41 +00:00
|
|
|
libpulseaudio
|
2024-10-24 02:43:08 +00:00
|
|
|
libtool
|
2024-10-24 02:23:41 +00:00
|
|
|
ncurses
|
2024-10-24 02:43:08 +00:00
|
|
|
]
|
|
|
|
++ lib.optionals stdenv.hostPlatform.isLinux [
|
|
|
|
alsa-lib
|
|
|
|
]
|
|
|
|
++ lib.optionals stdenv.hostPlatform.isDarwin [
|
|
|
|
portaudio
|
2024-10-24 02:23:41 +00:00
|
|
|
]
|
|
|
|
++ lib.optionals withSDL2 [
|
|
|
|
libGL
|
2024-10-24 02:43:08 +00:00
|
|
|
SDL2
|
2024-10-24 02:23:41 +00:00
|
|
|
]
|
|
|
|
++ lib.optionals withPipewire [
|
|
|
|
pipewire
|
|
|
|
];
|
2014-12-11 23:09:24 +00:00
|
|
|
|
2023-08-16 18:54:35 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
autoreconfHook
|
2023-09-03 16:36:06 +00:00
|
|
|
autoconf-archive
|
2023-08-16 18:54:35 +00:00
|
|
|
pkgconf
|
2024-10-24 02:59:18 +00:00
|
|
|
versionCheckHook
|
2023-08-16 18:54:35 +00:00
|
|
|
];
|
2024-10-24 02:59:18 +00:00
|
|
|
doInstallCheck = true;
|
|
|
|
versionCheckProgramArg = "-v";
|
2014-12-11 23:09:24 +00:00
|
|
|
|
2023-08-16 18:54:35 +00:00
|
|
|
preAutoreconf = ''
|
|
|
|
echo ${version} > version
|
|
|
|
'';
|
2016-05-10 09:48:38 +00:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2014-12-11 23:09:24 +00:00
|
|
|
description = "Console-based Audio Visualizer for Alsa";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/karlstav/cava";
|
2016-05-10 09:48:38 +00:00
|
|
|
license = licenses.mit;
|
2024-10-24 02:23:41 +00:00
|
|
|
maintainers = with maintainers; [
|
|
|
|
offline
|
|
|
|
mirrexagon
|
|
|
|
];
|
2024-10-24 02:43:08 +00:00
|
|
|
platforms = platforms.unix;
|
2023-08-04 15:54:47 +00:00
|
|
|
mainProgram = "cava";
|
2014-12-11 23:09:24 +00:00
|
|
|
};
|
|
|
|
}
|