2021-01-11 08:54:33 +01:00
|
|
|
{ lib, stdenv, fetchFromGitHub, libX11, imlib2
|
2016-01-06 09:12:04 +01:00
|
|
|
, enableXinerama ? true, libXinerama ? null
|
|
|
|
}:
|
|
|
|
|
|
|
|
assert enableXinerama -> libXinerama != null;
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-05-25 20:39:51 +02:00
|
|
|
version = "2.0.2";
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "setroot";
|
2016-01-06 09:12:04 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ttzhou";
|
|
|
|
repo = "setroot";
|
|
|
|
rev = "v${version}";
|
2019-05-25 20:39:51 +02:00
|
|
|
sha256 = "0w95828v0splk7bj5kfacp4pq6wxpyamvyjmahyvn5hc3ycq21mq";
|
2016-01-06 09:12:04 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ libX11 imlib2 ]
|
|
|
|
++ stdenv.lib.optional enableXinerama libXinerama;
|
|
|
|
|
2019-10-27 14:03:25 +01:00
|
|
|
buildFlags = [ "CC=cc" (if enableXinerama then "xinerama=1" else "xinerama=0") ] ;
|
2016-01-06 09:12:04 +01:00
|
|
|
|
2019-10-27 14:03:25 +01:00
|
|
|
installFlags = [ "DESTDIR=$(out)" "PREFIX=" ];
|
2016-01-06 09:12:04 +01:00
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2016-01-06 09:12:04 +01:00
|
|
|
description = "Simple X background setter inspired by imlibsetroot and feh";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://github.com/ttzhou/setroot";
|
2016-01-06 09:12:04 +01:00
|
|
|
license = licenses.gpl3Plus;
|
2017-12-05 23:20:11 +01:00
|
|
|
maintainers = [ maintainers.vyp ];
|
2016-01-06 09:12:04 +01:00
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|