2021-12-19 01:06:50 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, fetchpatch
|
2021-02-05 17:12:51 +00:00
|
|
|
, pkg-config, cmake
|
2020-04-24 23:36:52 +00:00
|
|
|
, libpulseaudio, ncurses }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "pamix";
|
|
|
|
version = "1.6";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "patroclos";
|
|
|
|
repo = "pamix";
|
|
|
|
rev = version;
|
|
|
|
sha256 = "1d44ggnwkf2gff62959pj45v3a2k091q8v154wc5pmzamam458wp";
|
|
|
|
};
|
|
|
|
|
2021-12-19 01:06:50 +00:00
|
|
|
patches = [
|
|
|
|
# ncurses-6.3 support, included in next release
|
|
|
|
(fetchpatch {
|
|
|
|
name = "ncurses-6.3-p1.patch";
|
|
|
|
url = "https://github.com/patroclos/PAmix/commit/3400b9c048706c572373e4617b4d5fcdb8dd2505.patch";
|
|
|
|
sha256 = "0rw56a844pz876ad9p8hfvn2fkd5rh29gpp47h55g08spf0vwb2z";
|
|
|
|
})
|
|
|
|
(fetchpatch {
|
|
|
|
name = "ncurses-6.3-p2.patch";
|
|
|
|
url = "https://github.com/patroclos/PAmix/commit/5ef67fc5ef6fc0dc0b48ff07ba48093881561d9c.patch";
|
|
|
|
sha256 = "0f8shpdv2swxdz04bkqgmkvl6c17r5mn4slzr7xd6pvw8hh51p4h";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
preConfigure = ''
|
|
|
|
substituteInPlace CMakeLists.txt --replace "/etc" "$out/etc/xdg"
|
|
|
|
'';
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
2020-04-24 23:36:52 +00:00
|
|
|
buildInputs = [ libpulseaudio ncurses ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Pulseaudio terminal mixer";
|
|
|
|
homepage = "https://github.com/patroclos/PAmix";
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ ericsagnes ];
|
|
|
|
};
|
|
|
|
}
|