depot/third_party/nixpkgs/pkgs/desktops/gnome-3/extensions/sound-output-device-chooser/default.nix
Default email 48af15f7a5 Project import generated by Copybara.
GitOrigin-RevId: 04a2b269d8921505a2969fc9ec25c1f517f2b307
2021-03-20 04:20:00 +00:00

44 lines
1.1 KiB
Nix

{ lib, stdenv
, substituteAll
, fetchFromGitHub
, libpulseaudio
, python3
}:
stdenv.mkDerivation rec {
pname = "gnome-shell-extension-sound-output-device-chooser";
version = "35";
src = fetchFromGitHub {
owner = "kgshank";
repo = "gse-sound-output-device-chooser";
rev = version;
sha256 = "sha256-Yl5ut6kJAkAAdCBiNFpwDgshXCLMmFH3/zhnFGpyKqs=";
};
patches = [
# Fix paths to libpulse and python
(substituteAll {
src = ./fix-paths.patch;
libpulse = "${libpulseaudio}/lib/libpulse.so";
python = python3.interpreter;
})
];
dontBuild = true;
uuid = "sound-output-device-chooser@kgshank.net";
installPhase = ''
runHook preInstall
mkdir -p $out/share/gnome-shell/extensions
cp -r ${uuid} $out/share/gnome-shell/extensions
runHook postInstall
'';
meta = with lib; {
description = "GNOME Shell extension adding audio device chooser to panel";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ jtojnar ];
homepage = "https://github.com/kgshank/gse-sound-output-device-chooser";
};
}