waybar: mpd_clientlib -> libmpdclient
This commit is contained in:
parent
9ac26e0f9c
commit
a6b8246c91
1 changed files with 68 additions and 53 deletions
|
@ -1,5 +1,19 @@
|
|||
{ lib, stdenv, fetchFromGitHub, meson, pkg-config, ninja, wrapGAppsHook
|
||||
, wayland, wlroots, gtkmm3, libsigcxx, jsoncpp, fmt, scdoc, spdlog, gtk-layer-shell
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, meson
|
||||
, pkg-config
|
||||
, ninja
|
||||
, wrapGAppsHook
|
||||
, wayland
|
||||
, wlroots
|
||||
, gtkmm3
|
||||
, libsigcxx
|
||||
, jsoncpp
|
||||
, fmt
|
||||
, scdoc
|
||||
, spdlog
|
||||
, gtk-layer-shell
|
||||
, howard-hinnant-date, cmake
|
||||
, traySupport ? true, libdbusmenu-gtk3
|
||||
, pulseSupport ? true, libpulseaudio
|
||||
|
@ -7,68 +21,69 @@
|
|||
, nlSupport ? true, libnl
|
||||
, udevSupport ? true, udev
|
||||
, swaySupport ? true, sway
|
||||
, mpdSupport ? true, mpd_clientlib
|
||||
, mpdSupport ? true, libmpdclient
|
||||
, withMediaPlayer ? false, glib, gobject-introspection, python3, python38Packages, playerctl
|
||||
}:
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "waybar";
|
||||
version = "0.9.5";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Alexays";
|
||||
repo = "Waybar";
|
||||
rev = version;
|
||||
sha256 = "1kzrgqaclfk6gcwhknxn28xl74gm5swipgn8kk8avacb4nsw1l9q";
|
||||
};
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "waybar";
|
||||
version = "0.9.5";
|
||||
|
||||
nativeBuildInputs = [
|
||||
meson ninja pkg-config scdoc wrapGAppsHook cmake
|
||||
] ++ lib.optional withMediaPlayer gobject-introspection;
|
||||
src = fetchFromGitHub {
|
||||
owner = "Alexays";
|
||||
repo = "Waybar";
|
||||
rev = version;
|
||||
sha256 = "1kzrgqaclfk6gcwhknxn28xl74gm5swipgn8kk8avacb4nsw1l9q";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = lib.optionals withMediaPlayer [
|
||||
glib
|
||||
playerctl
|
||||
python38Packages.pygobject3
|
||||
];
|
||||
strictDeps = false;
|
||||
nativeBuildInputs = [
|
||||
meson ninja pkg-config scdoc wrapGAppsHook cmake
|
||||
] ++ lib.optional withMediaPlayer gobject-introspection;
|
||||
|
||||
buildInputs = with lib;
|
||||
[ wayland wlroots gtkmm3 libsigcxx jsoncpp fmt spdlog gtk-layer-shell howard-hinnant-date ]
|
||||
++ optional traySupport libdbusmenu-gtk3
|
||||
++ optional pulseSupport libpulseaudio
|
||||
++ optional sndioSupport sndio
|
||||
++ optional nlSupport libnl
|
||||
++ optional udevSupport udev
|
||||
++ optional swaySupport sway
|
||||
++ optional mpdSupport mpd_clientlib;
|
||||
propagatedBuildInputs = lib.optionals withMediaPlayer [
|
||||
glib
|
||||
playerctl
|
||||
python38Packages.pygobject3
|
||||
];
|
||||
strictDeps = false;
|
||||
|
||||
mesonFlags = (lib.mapAttrsToList
|
||||
(option: enable: "-D${option}=${if enable then "enabled" else "disabled"}")
|
||||
{
|
||||
dbusmenu-gtk = traySupport;
|
||||
pulseaudio = pulseSupport;
|
||||
sndio = sndioSupport;
|
||||
libnl = nlSupport;
|
||||
libudev = udevSupport;
|
||||
mpd = mpdSupport;
|
||||
}
|
||||
) ++ [
|
||||
"-Dout=${placeholder "out"}"
|
||||
"-Dsystemd=disabled"
|
||||
];
|
||||
buildInputs = with lib;
|
||||
[ wayland wlroots gtkmm3 libsigcxx jsoncpp fmt spdlog gtk-layer-shell howard-hinnant-date ]
|
||||
++ optional traySupport libdbusmenu-gtk3
|
||||
++ optional pulseSupport libpulseaudio
|
||||
++ optional sndioSupport sndio
|
||||
++ optional nlSupport libnl
|
||||
++ optional udevSupport udev
|
||||
++ optional swaySupport sway
|
||||
++ optional mpdSupport libmpdclient;
|
||||
|
||||
preFixup = lib.optional withMediaPlayer ''
|
||||
mesonFlags = (lib.mapAttrsToList
|
||||
(option: enable: "-D${option}=${if enable then "enabled" else "disabled"}")
|
||||
{
|
||||
dbusmenu-gtk = traySupport;
|
||||
pulseaudio = pulseSupport;
|
||||
sndio = sndioSupport;
|
||||
libnl = nlSupport;
|
||||
libudev = udevSupport;
|
||||
mpd = mpdSupport;
|
||||
}
|
||||
) ++ [
|
||||
"-Dout=${placeholder "out"}"
|
||||
"-Dsystemd=disabled"
|
||||
];
|
||||
|
||||
preFixup = lib.optional withMediaPlayer ''
|
||||
cp $src/resources/custom_modules/mediaplayer.py $out/bin/waybar-mediaplayer.py
|
||||
|
||||
wrapProgram $out/bin/waybar-mediaplayer.py \
|
||||
--prefix PYTHONPATH : "$PYTHONPATH:$out/${python3.sitePackages}"
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Highly customizable Wayland bar for Sway and Wlroots based compositors";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ FlorianFranzen minijackson synthetica ];
|
||||
platforms = platforms.unix;
|
||||
homepage = "https://github.com/alexays/waybar";
|
||||
};
|
||||
}
|
||||
meta = with lib; {
|
||||
description = "Highly customizable Wayland bar for Sway and Wlroots based compositors";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ FlorianFranzen minijackson synthetica ];
|
||||
platforms = platforms.unix;
|
||||
homepage = "https://github.com/alexays/waybar";
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue