nixpkgs/pkgs/tools/X11/runningx/default.nix
volth 46420bbaa3 treewide: name -> pname (easy cases) (#66585)
treewide replacement of

stdenv.mkDerivation rec {
  name = "*-${version}";
  version = "*";

to pname
2019-08-15 13:41:18 +01:00

34 lines
838 B
Nix

{ stdenv, fetchurl, pkgconfig, libX11 }:
stdenv.mkDerivation rec {
pname = "runningx";
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 = ''
cc -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 ];
};
}