From 93a371ede780fa18f4e767f882d78d0de1eff9af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo=20Malaquias?= Date: Tue, 31 May 2016 09:55:55 -0300 Subject: [PATCH] runningx: init at 1.0 --- pkgs/tools/X11/runningx/default.nix | 34 +++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 36 insertions(+) create mode 100644 pkgs/tools/X11/runningx/default.nix diff --git a/pkgs/tools/X11/runningx/default.nix b/pkgs/tools/X11/runningx/default.nix new file mode 100644 index 000000000000..a4b3f05c94c1 --- /dev/null +++ b/pkgs/tools/X11/runningx/default.nix @@ -0,0 +1,34 @@ +{ stdenv, fetchurl, pkgconfig, libX11 }: + +stdenv.mkDerivation rec { + name = "runningx-${version}"; + version = "1.0"; + + src = fetchurl { + url = "http://www.fiction.net/blong/programs/mutt/autoview/RunningX.c"; + sha256 = "1mikkhrx6jsx716041qdy3nwjac08pxxvxyq2yablm8zg9hrip0d"; + }; + + nativeBuildInputs = [ pkgconfig ]; + + buildInputs = [ libX11 ]; + + phases = [ "buildPhase" "installPhase" ]; + + buildPhase = '' + gcc -O2 -o RunningX $(pkg-config --cflags --libs x11) $src + ''; + + installPhase = '' + mkdir -p "$out"/bin + cp -vai RunningX "$out/bin" + ''; + + meta = { + homepage = http://www.fiction.net/blong/programs/mutt/; + description = "A program for testing if X is running"; + license = stdenv.lib.licenses.free; + platforms = stdenv.lib.platforms.unix; + maintainers = [ stdenv.lib.maintainers.romildo ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index dbc671c985e7..d59798b64857 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3206,6 +3206,8 @@ in rubber = callPackage ../tools/typesetting/rubber { }; + runningx = callPackage ../tools/X11/runningx { }; + runzip = callPackage ../tools/archivers/runzip { }; rxp = callPackage ../tools/text/xml/rxp { };