Files
nixpkgs/pkgs/by-name/vo/volctl/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

75 lines
1.6 KiB
Nix

{
lib,
python3Packages,
fetchFromGitHub,
wrapGAppsHook3,
gobject-introspection,
libpulseaudio,
glib,
gtk3,
pango,
xorg,
}:
python3Packages.buildPythonApplication rec {
pname = "volctl";
version = "0.9.5";
format = "setuptools";
src = fetchFromGitHub {
owner = "buzz";
repo = "volctl";
rev = "v${version}";
sha256 = "sha256-zL1m/DeSOrNkjt9B+8pdy2jUgjSp7tt81UpAueGsIwQ=";
};
postPatch = ''
substituteInPlace volctl/xwrappers.py \
--replace 'libXfixes.so' "${xorg.libXfixes}/lib/libXfixes.so" \
--replace 'libXfixes.so.3' "${xorg.libXfixes}/lib/libXfixes.so.3"
'';
preBuild = ''
export LD_LIBRARY_PATH=${libpulseaudio}/lib
'';
nativeBuildInputs = [
gobject-introspection
wrapGAppsHook3
];
propagatedBuildInputs = [
pango
gtk3
]
++ (with python3Packages; [
pulsectl
click
pycairo
pygobject3
pyyaml
]);
# with strictDeps importing "gi.repository.Gtk" fails with "gi.RepositoryError: Typelib file for namespace 'Pango', version '1.0' not found"
strictDeps = false;
# no tests included
doCheck = false;
pythonImportsCheck = [ "volctl" ];
preFixup = ''
glib-compile-schemas ${glib.makeSchemaPath "$out" "${pname}-${version}"}
gappsWrapperArgs+=(--prefix LD_LIBRARY_PATH : "${libpulseaudio}/lib")
'';
meta = with lib; {
description = "PulseAudio enabled volume control featuring per-app sliders";
homepage = "https://buzz.github.io/volctl/";
license = licenses.gpl2Only;
platforms = platforms.linux;
maintainers = [ maintainers.romildo ];
mainProgram = "volctl";
};
}