From ffb3f0396c238b87bbb798f4d851291a1b0fda15 Mon Sep 17 00:00:00 2001 From: Mikael Brockman Date: Sat, 13 Aug 2016 12:46:43 +0200 Subject: [PATCH] unclutter-xfixes: init at 1.2 --- pkgs/tools/misc/unclutter-xfixes/default.nix | 51 ++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 53 insertions(+) create mode 100644 pkgs/tools/misc/unclutter-xfixes/default.nix diff --git a/pkgs/tools/misc/unclutter-xfixes/default.nix b/pkgs/tools/misc/unclutter-xfixes/default.nix new file mode 100644 index 000000000000..dd13a0d9adce --- /dev/null +++ b/pkgs/tools/misc/unclutter-xfixes/default.nix @@ -0,0 +1,51 @@ +{ stdenv, fetchFromGitHub, + xlibsWrapper, libev, libXi, libXfixes, + pkgconfig, asciidoc, libxslt, docbook_xsl }: + +let version = "1.2"; in + +stdenv.mkDerivation { + name = "unclutter-xfixes-${version}"; + version = version; + + src = fetchFromGitHub { + owner = "Airblader"; + repo = "unclutter-xfixes"; + rev = "v${version}"; + sha256 = "1pw567mj7mq5kr8mqnyrvy7jj62qfg6zgqfyzz21nncslddnjzg8"; + }; + + nativeBuildInputs = [pkgconfig]; + buildInputs = [ + xlibsWrapper libev libXi libXfixes + asciidoc libxslt docbook_xsl + ]; + + postPatch = '' + substituteInPlace Makefile --replace "CC = gcc" "CC = cc" + ''; + + preBuild = '' + # The Makefile calls git only to discover the package version, + # but that doesn't work right in the build environment, + # so we fake it. + git() { echo v${version}; } + export -f git + ''; + + preInstall = '' + export DESTDIR=$out MANDIR=/man/man1 + ''; + + postInstall = '' + mv $out/usr/bin $out/bin + mv $out/usr/share/man $out/man + ''; + + meta = with stdenv.lib; { + description = "Rewrite of unclutter using the X11 Xfixes extension"; + platforms = platforms.unix; + license = stdenv.lib.licenses.mit; + inherit version; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c0c95a56c039..4274c62369f5 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3993,6 +3993,8 @@ in unclutter = callPackage ../tools/misc/unclutter { }; + unclutter-xfixes = callPackage ../tools/misc/unclutter-xfixes { }; + unbound = callPackage ../tools/networking/unbound { }; units = callPackage ../tools/misc/units { };