Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, stdenv 3, fetchurl 4, bison 5}: 6 7stdenv.mkDerivation rec { 8 pname = "as31"; 9 version = "2.3.1"; 10 11 src = fetchurl { 12 url = "http://wiki.erazor-zone.de/_media/wiki:projects:linux:as31:${pname}-${version}.tar.gz"; 13 name = "${pname}-${version}.tar.gz"; 14 hash = "sha256-zSEyWHFon5nyq717Mpmdv1XZ5Hz0e8ZABqsP8M83c1U="; 15 }; 16 17 patches = [ 18 # Check return value of getline in run.c 19 ./0000-getline-break.patch 20 ]; 21 22 postPatch = '' 23 # parser.c is generated from parser.y; it is better to generate it via bison 24 # instead of using the prebuilt one, especially in x86_64 25 rm -f as31/parser.c 26 ''; 27 28 preConfigure = '' 29 chmod +x configure 30 ''; 31 32 nativeBuildInputs = [ 33 bison 34 ]; 35 36 meta = with lib; { 37 homepage = "http://wiki.erazor-zone.de/wiki:projects:linux:as31"; 38 description = "An 8031/8051 assembler"; 39 license = licenses.gpl2Plus; 40 maintainers = with maintainers; [ AndersonTorres ]; 41 platforms = platforms.unix; 42 }; 43}