summary refs log tree commit diff
path: root/pkgs/tools/misc/unclutter-xfixes/default.nix
blob: 93e0d750a2acbb79c3b6b51cc8ce448e759120fa (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{ lib, stdenv, fetchFromGitHub,
  libev, libX11, libXext, libXi, libXfixes,
  pkg-config, asciidoc, libxslt, docbook_xsl }:

stdenv.mkDerivation rec {
  pname = "unclutter-xfixes";
  version = "1.6";

  src = fetchFromGitHub {
    owner = "Airblader";
    repo = "unclutter-xfixes";
    rev = "v${version}";
    sha256 = "sha256-suKmaoJq0PBHZc7NzBQ60JGwJkAtWmvzPtTHWOPJEdc=";
  };

  nativeBuildInputs = [ pkg-config asciidoc libxslt docbook_xsl ];
  buildInputs = [ libev libX11 libXext libXi libXfixes ];

  prePatch = ''
    substituteInPlace Makefile --replace 'PKG_CONFIG =' 'PKG_CONFIG ?='
  '';
  makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];

  installFlags = [ "PREFIX=$(out)" ];

  meta = with lib; {
    description = "Rewrite of unclutter using the X11 Xfixes extension";
    platforms = platforms.unix;
    license = lib.licenses.mit;
    maintainers = [ maintainers.globin ];
    mainProgram = "unclutter";
  };
}