3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/servers/gpm/default.nix

48 lines
1.2 KiB
Nix
Raw Normal View History

2015-04-30 23:31:11 +01:00
{ stdenv, fetchurl, automake, autoconf, libtool, flex, bison, texinfo
# Optional Dependencies
, ncurses ? null
}:
stdenv.mkDerivation rec {
2015-04-05 04:31:55 +01:00
name = "gpm-1.20.7";
src = fetchurl {
url = "http://www.nico.schottelius.org/software/gpm/archives/${name}.tar.bz2";
2015-04-05 04:31:55 +01:00
sha256 = "13d426a8h403ckpc8zyf7s2p5rql0lqbg2bv0454x0pvgbfbf4gh";
};
2017-11-07 07:33:48 +00:00
postPatch = ''
sed '1i#include <sys/types.h>' -i src/daemon/open_console.c
substituteInPlace src/prog/gpm-root.y --replace __sigemptyset sigemptyset
'';
2015-04-30 23:31:11 +01:00
nativeBuildInputs = [ automake autoconf libtool flex bison texinfo ];
buildInputs = [ ncurses ];
hardeningDisable = [ "format" ];
2015-12-23 01:59:47 +00:00
2015-04-05 04:31:55 +01:00
preConfigure = ''
./autogen.sh
'';
configureFlags = [
"--sysconfdir=/etc"
"--localstatedir=/var"
2015-04-30 23:31:11 +01:00
(if ncurses == null then "--without-curses" else "--with-curses")
2015-04-05 04:31:55 +01:00
];
2015-04-30 23:31:11 +01:00
# Provide libgpm.so for compatability
postInstall = ''
2015-04-30 23:31:11 +01:00
ln -sv $out/lib/libgpm.so.2 $out/lib/libgpm.so
'';
2015-04-30 23:31:11 +01:00
meta = with stdenv.lib; {
homepage = http://www.nico.schottelius.org/software/gpm/;
description = "A daemon that provides mouse support on the Linux console";
2015-04-30 23:31:11 +01:00
license = licenses.gpl2;
2017-05-23 14:36:32 +01:00
platforms = platforms.linux ++ platforms.cygwin;
2015-04-30 23:31:11 +01:00
maintainers = with maintainers; [ eelco wkennington ];
};
}