02bdfa7a45
Signed-off-by: Xaiya Schumin <d.schumin@proton.me>
74 lines
1.3 KiB
Nix
74 lines
1.3 KiB
Nix
{
|
|
lib,
|
|
fetchurl,
|
|
stdenv,
|
|
autoPatchelfHook,
|
|
|
|
wayland,
|
|
libGL,
|
|
|
|
zlib,
|
|
fontconfig,
|
|
freetype,
|
|
|
|
krb5,
|
|
e2fsprogs,
|
|
|
|
libgpg-error,
|
|
|
|
makeWrapper,
|
|
xkeyboard_config
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "musicpresence";
|
|
version = "2.3.5";
|
|
|
|
src = fetchurl {
|
|
url = "https://github.com/ungive/discord-music-presence/releases/download/v${version}/${pname}-${version}-linux-x86_64.tar.gz";
|
|
hash = "sha256-BDgM1SfyEXC0oW+J33mYKwqRrvZX3cy/X9k7Yuk4kS8=";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
autoPatchelfHook
|
|
makeWrapper
|
|
];
|
|
|
|
buildInputs = [
|
|
stdenv.cc.cc
|
|
xkeyboard_config # ARGG
|
|
|
|
wayland
|
|
libGL
|
|
|
|
fontconfig
|
|
freetype
|
|
libgpg-error
|
|
e2fsprogs
|
|
];
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
mkdir -p $out/bin $out/share
|
|
cp -r usr/* $out
|
|
|
|
substituteInPlace $out/share/applications/${pname}.desktop \
|
|
--replace-fail Exec=${pname} Exec=$out/bin/${pname}
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
postFixup = ''
|
|
wrapProgram $out/bin/${pname} \
|
|
--set XKB_CONFIG_ROOT ${xkeyboard_config}/share/X11/xkb
|
|
'';
|
|
|
|
meta = {
|
|
description = "The Discord music status that works with any media player";
|
|
homepage = "https://github.com/ungive/discord-music-presence";
|
|
license = lib.licenses.unfreeRedistributable;
|
|
maintainers = with lib.maintainers; [ ];
|
|
mainProgram = "musicpresence";
|
|
};
|
|
} |