2020-04-19 15:40:30 +01:00
|
|
|
{ lib, buildPythonPackage, fetchPypi, libpulseaudio, glibc, substituteAll, stdenv, pulseaudio, python }:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pulsectl";
|
2020-06-06 07:47:23 +01:00
|
|
|
version = "20.5.1";
|
2020-04-19 15:40:30 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-06-06 07:47:23 +01:00
|
|
|
sha256 = "39b0a0e7974a7d6468d826a838822f78b00ac9c3803f0d7bfa9b1cad08ee22db";
|
2020-04-19 15:40:30 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./library-paths.patch;
|
|
|
|
libpulse = "${libpulseaudio.out}/lib/libpulse${stdenv.hostPlatform.extensions.sharedLibrary}";
|
|
|
|
librt = "${glibc.out}/lib/librt${stdenv.hostPlatform.extensions.sharedLibrary}";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [ pulseaudio ];
|
|
|
|
checkPhase = ''
|
|
|
|
${python.interpreter} -m unittest pulsectl.tests.all
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python high-level interface and ctypes-based bindings for PulseAudio (libpulse)";
|
|
|
|
homepage = "https://pypi.python.org/pypi/pulsectl/";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ hexa ];
|
|
|
|
};
|
|
|
|
}
|