diff options
author | Jörg Thalheim <Mic92@users.noreply.github.com> | 2021-02-12 12:59:37 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-12 12:59:37 +0000 |
commit | d5f20799fa3f45fc5bde1d17f40bb7ebccd7c7c4 (patch) | |
tree | 4c69f74110007980d6906ec48d3f3485183f47ce /pkgs/applications/misc | |
parent | e2b08e2f7e30411360c638d69aabab4223512ab6 (diff) | |
parent | def34bb17051f4cc39baca207012d719fab4b759 (diff) | |
download | nixpkgs-d5f20799fa3f45fc5bde1d17f40bb7ebccd7c7c4.tar nixpkgs-d5f20799fa3f45fc5bde1d17f40bb7ebccd7c7c4.tar.gz nixpkgs-d5f20799fa3f45fc5bde1d17f40bb7ebccd7c7c4.tar.bz2 nixpkgs-d5f20799fa3f45fc5bde1d17f40bb7ebccd7c7c4.tar.lz nixpkgs-d5f20799fa3f45fc5bde1d17f40bb7ebccd7c7c4.tar.xz nixpkgs-d5f20799fa3f45fc5bde1d17f40bb7ebccd7c7c4.tar.zst nixpkgs-d5f20799fa3f45fc5bde1d17f40bb7ebccd7c7c4.zip |
Merge pull request #112774 from AndersonTorres/updates
treewide: mpd_clientlib -> libmpdclient
Diffstat (limited to 'pkgs/applications/misc')
-rw-r--r-- | pkgs/applications/misc/polybar/default.nix | 86 | ||||
-rw-r--r-- | pkgs/applications/misc/waybar/default.nix | 121 |
2 files changed, 128 insertions, 79 deletions
diff --git a/pkgs/applications/misc/polybar/default.nix b/pkgs/applications/misc/polybar/default.nix index c79da21ad63..b01b5af7ded 100644 --- a/pkgs/applications/misc/polybar/default.nix +++ b/pkgs/applications/misc/polybar/default.nix @@ -1,13 +1,29 @@ -{ cairo, cmake, fetchFromGitHub, libXdmcp, libpthreadstubs, libxcb, pcre, pkg-config -, python3, lib, stdenv, xcbproto, xcbutil, xcbutilcursor, xcbutilimage -, xcbutilrenderutil, xcbutilwm, xcbutilxrm, makeWrapper +{ cairo +, cmake +, fetchFromGitHub +, libXdmcp +, libpthreadstubs +, libxcb +, pcre +, pkg-config +, python3 +, lib +, stdenv +, xcbproto +, xcbutil +, xcbutilcursor +, xcbutilimage +, xcbutilrenderutil +, xcbutilwm +, xcbutilxrm +, makeWrapper , removeReferencesTo # optional packages-- override the variables ending in 'Support' to enable or # disable modules , alsaSupport ? true, alsaLib ? null , githubSupport ? false, curl ? null -, mpdSupport ? false, mpd_clientlib ? null +, mpdSupport ? false, libmpdclient ? null , pulseSupport ? false, libpulseaudio ? null , iwSupport ? false, wirelesstools ? null , nlSupport ? true, libnl ? null @@ -16,7 +32,7 @@ assert alsaSupport -> alsaLib != null; assert githubSupport -> curl != null; -assert mpdSupport -> mpd_clientlib != null; +assert mpdSupport -> libmpdclient != null; assert pulseSupport -> libpulseaudio != null; assert iwSupport -> ! nlSupport && wirelesstools != null; @@ -37,26 +53,24 @@ stdenv.mkDerivation rec { fetchSubmodules = true; }; - meta = with lib; { - homepage = "https://polybar.github.io/"; - description = "A fast and easy-to-use tool for creating status bars"; - longDescription = '' - Polybar aims to help users build beautiful and highly customizable - status bars for their desktop environment, without the need of - having a black belt in shell scripting. - ''; - license = licenses.mit; - maintainers = with maintainers; [ afldcr Br1ght0ne ]; - platforms = platforms.linux; - }; - buildInputs = [ - cairo libXdmcp libpthreadstubs libxcb pcre python3 xcbproto xcbutil - xcbutilcursor xcbutilimage xcbutilrenderutil xcbutilwm xcbutilxrm + cairo + libXdmcp + libpthreadstubs + libxcb + pcre + python3 + xcbproto + xcbutil + xcbutilcursor + xcbutilimage + xcbutilrenderutil + xcbutilwm + xcbutilxrm (if alsaSupport then alsaLib else null) (if githubSupport then curl else null) - (if mpdSupport then mpd_clientlib else null) + (if mpdSupport then libmpdclient else null) (if pulseSupport then libpulseaudio else null) (if iwSupport then wirelesstools else null) @@ -69,16 +83,36 @@ stdenv.mkDerivation rec { (if i3Support || i3GapsSupport then makeWrapper else null) ]; - postInstall = if (i3Support || i3GapsSupport) then '' - wrapProgram $out/bin/polybar \ - --prefix PATH : "${if i3Support then i3 else i3-gaps}/bin" - '' else ""; + postInstall = if i3Support + then ''wrapProgram $out/bin/polybar \ + --prefix PATH : "${i3}/bin" + '' + else if i3GapsSupport + then ''wrapProgram $out/bin/polybar \ + --prefix PATH : "${i3-gaps}/bin" + '' + else ''''; nativeBuildInputs = [ - cmake pkg-config removeReferencesTo + cmake + pkg-config + removeReferencesTo ]; postFixup = '' remove-references-to -t ${stdenv.cc} $out/bin/polybar ''; + + meta = with lib; { + homepage = "https://polybar.github.io/"; + description = "A fast and easy-to-use tool for creating status bars"; + longDescription = '' + Polybar aims to help users build beautiful and highly customizable + status bars for their desktop environment, without the need of + having a black belt in shell scripting. + ''; + license = licenses.mit; + maintainers = with maintainers; [ afldcr Br1ght0ne ]; + platforms = platforms.linux; + }; } diff --git a/pkgs/applications/misc/waybar/default.nix b/pkgs/applications/misc/waybar/default.nix index 8dd18de5d89..0cbe325f62a 100644 --- a/pkgs/applications/misc/waybar/default.nix +++ b/pkgs/applications/misc/waybar/default.nix @@ -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"; + }; +} |