xfce.xfce4-power-manager: add withGtk3 version 1.6.0
test passed: nix-build '<nixos/release.nix>' -A tests.xfce.x86_64-linux Closes: #8595
This commit is contained in:
parent
0060a0f3df
commit
ecd3617d7a
|
@ -1,22 +1,38 @@
|
||||||
{ stdenv, fetchurl, pkgconfig, intltool, gtk, dbus_glib, upower, xfconf
|
{ stdenv, lib, fetchurl, pkgconfig, intltool, glib, gtk, dbus_glib, upower, xfconf
|
||||||
, libxfce4ui, libxfce4util, libnotify, xfce4panel, hicolor_icon_theme }:
|
, libxfce4ui, libxfce4util, libnotify, xfce4panel, hicolor_icon_theme
|
||||||
|
, withGtk3 ? false, gtk3, libxfce4ui_gtk3, xfce4panel_gtk3 }:
|
||||||
let
|
let
|
||||||
p_name = "xfce4-power-manager";
|
p_name = "xfce4-power-manager";
|
||||||
ver_maj = "1.4";
|
ver_maj = if withGtk3 then "1.6" else "1.4";
|
||||||
ver_min = "4";
|
ver_min = if withGtk3 then "0" else "4";
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "${p_name}-${ver_maj}.${ver_min}";
|
name = "${p_name}-${ver_maj}.${ver_min}";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "mirror://xfce/src/xfce/${p_name}/${ver_maj}/${name}.tar.bz2";
|
url = "mirror://xfce/src/xfce/${p_name}/${ver_maj}/${name}.tar.bz2";
|
||||||
sha256 = "01rvqy1cif4s8lkidb7hhmsz7d9f2fwcwvc51xycaj3qgsmch3n5";
|
sha256 =
|
||||||
|
if withGtk3
|
||||||
|
then "0avzhllpimcn7a6z9aa4jn0zg5ahxr9ks5ldchizycdb0rz1bqxx"
|
||||||
|
else "01rvqy1cif4s8lkidb7hhmsz7d9f2fwcwvc51xycaj3qgsmch3n5";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs =
|
buildInputs =
|
||||||
[ pkgconfig intltool gtk dbus_glib upower xfconf libxfce4ui libxfce4util
|
[ pkgconfig intltool glib dbus_glib upower xfconf libxfce4util
|
||||||
libnotify xfce4panel hicolor_icon_theme
|
libnotify hicolor_icon_theme
|
||||||
];
|
] ++
|
||||||
|
(if withGtk3
|
||||||
|
then [ gtk3 libxfce4ui_gtk3 xfce4panel_gtk3 ]
|
||||||
|
else [ gtk libxfce4ui xfce4panel ]);
|
||||||
|
|
||||||
|
postPatch = lib.optionalString withGtk3 ''
|
||||||
|
substituteInPlace configure --replace gio-2.0 gio-unix-2.0
|
||||||
|
'';
|
||||||
|
|
||||||
|
postConfigure = lib.optionalString withGtk3 ''
|
||||||
|
substituteInPlace src/Makefile --replace "xfce4_power_manager_CFLAGS = " "xfce4_power_manager_CFLAGS = \$(GIO_CFLAGS) "
|
||||||
|
substituteInPlace settings/Makefile --replace "xfce4_power_manager_settings_CFLAGS = " "xfce4_power_manager_settings_CFLAGS = \$(GIO_CFLAGS) "
|
||||||
|
'';
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
homepage = http://goodies.xfce.org/projects/applications/xfce4-power-manager;
|
homepage = http://goodies.xfce.org/projects/applications/xfce4-power-manager;
|
||||||
|
|
|
@ -40,6 +40,7 @@ xfce_self = rec { # the lines are very long but it seems better than the even-od
|
||||||
xfce4session = callPackage ./core/xfce4-session.nix { };
|
xfce4session = callPackage ./core/xfce4-session.nix { };
|
||||||
xfce4settings = callPackage ./core/xfce4-settings.nix { };
|
xfce4settings = callPackage ./core/xfce4-settings.nix { };
|
||||||
xfce4_power_manager = callPackage ./core/xfce4-power-manager.nix { };
|
xfce4_power_manager = callPackage ./core/xfce4-power-manager.nix { };
|
||||||
|
xfce4_power_manager_gtk3 = callPackage ./core/xfce4-power-manager.nix { withGtk3 = true; };
|
||||||
xfconf = callPackage ./core/xfconf.nix { };
|
xfconf = callPackage ./core/xfconf.nix { };
|
||||||
xfdesktop = callPackage ./core/xfdesktop.nix { };
|
xfdesktop = callPackage ./core/xfdesktop.nix { };
|
||||||
xfwm4 = callPackage ./core/xfwm4.nix { };
|
xfwm4 = callPackage ./core/xfwm4.nix { };
|
||||||
|
|
Loading…
Reference in New Issue