Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 fetchurl, 5 automake, 6 autoconf, 7 libX11, 8}: 9 10stdenv.mkDerivation rec { 11 pname = "libstroke"; 12 version = "0.5.1"; 13 14 src = fetchurl { 15 url = "https://web.archive.org/web/20161204100704/http://etla.net/libstroke/${pname}-${version}.tar.gz"; 16 sha256 = "0bbpqzsqh9zrc6cg62f6vp1p4dzvv37blsd0gdlzdskgwvyzba8d"; 17 }; 18 19 postPatch = '' 20 sed -i 1i'#include <string.h>' libstroke/stroke.c 21 ''; 22 23 nativeBuildInputs = [ 24 automake 25 autoconf 26 ]; 27 buildInputs = [ libX11 ]; 28 29 # libstroke ships with an ancient config.sub that doesn't know about x86_64, so regenerate it. 30 # Also, modern automake doesn't like things and returns error code 63. But it generates the file. 31 preConfigure = '' 32 rm config.sub 33 autoconf 34 automake -a || true 35 ''; 36 37 meta = { 38 description = "Library for simple gesture recognition"; 39 homepage = "https://web.archive.org/web/20161204100704/http://etla.net/libstroke/"; 40 license = lib.licenses.gpl2; 41 42 longDescription = '' 43 libstroke, last updated in 2001, still successfully provides a basic 44 gesture recognition engine based around a 3x3 grid. It's simple and 45 easy to work with, and notably used by FVWM. 46 ''; 47 48 platforms = lib.platforms.linux; 49 }; 50}