nixpkgs/pkgs/applications/display-managers/lightdm/gtk-greeter.nix
R. RyanTM 712da92800 lightdm_gtk_greeter: 2.0.5 -> 2.0.6 (#47021)
Semi-automatic update generated by
https://github.com/ryantm/nixpkgs-update tools. This update was made
based on information from
https://repology.org/metapackage/lightdm-gtk-greeter/versions
2018-09-28 22:36:18 +02:00

51 lines
1.5 KiB
Nix

{ stdenv, fetchurl, lightdm, pkgconfig, intltool
, hicolor-icon-theme, makeWrapper
, useGTK2 ? false, gtk2, gtk3 # gtk3 seems better supported
, exo
}:
#ToDo: bad icons with gtk2;
# avatar icon is missing in standard hicolor theme, I don't know where gtk3 takes it from
let
ver_branch = "2.0";
version = "2.0.6";
in
stdenv.mkDerivation rec {
name = "lightdm-gtk-greeter-${version}";
src = fetchurl {
url = "${meta.homepage}/${ver_branch}/${version}/+download/${name}.tar.gz";
sha256 = "1pis5qyg95pg31dvnfqq34bzgj00hg4vs547r8h60lxjk81z8p15";
};
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ lightdm exo intltool makeWrapper hicolor-icon-theme ]
++ (if useGTK2 then [ gtk2 ] else [ gtk3 ]);
configureFlags = [
"--localstatedir=/var"
"--sysconfdir=/etc"
] ++ stdenv.lib.optional useGTK2 "--with-gtk2";
NIX_CFLAGS_COMPILE = [ "-Wno-error=deprecated-declarations" ];
installFlags = [
"localstatedir=\${TMPDIR}"
"sysconfdir=\${out}/etc"
];
postInstall = ''
substituteInPlace "$out/share/xgreeters/lightdm-gtk-greeter.desktop" \
--replace "Exec=lightdm-gtk-greeter" "Exec=$out/sbin/lightdm-gtk-greeter"
wrapProgram "$out/sbin/lightdm-gtk-greeter" \
--prefix XDG_DATA_DIRS ":" "${hicolor-icon-theme}/share"
'';
meta = with stdenv.lib; {
homepage = https://launchpad.net/lightdm-gtk-greeter;
platforms = platforms.linux;
license = licenses.gpl3;
maintainers = with maintainers; [ ocharles wkennington ];
};
}