Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib, stdenv, fetchzip, autoreconfHook, pkg-config, gnumake42, glib, pcre 2, json_c, flex, bison, dtc, pciutils, dmidecode, acpica-tools, libbsd }: 3 4stdenv.mkDerivation rec { 5 pname = "fwts"; 6 version = "23.03.00"; 7 8 src = fetchzip { 9 url = "https://fwts.ubuntu.com/release/${pname}-V${version}.tar.gz"; 10 sha256 = "sha256-loBlNQwsgv3n5qqvcT6w22Z/AshwIS7vQrBjLCL4z/Q="; 11 stripRoot = false; 12 }; 13 14 # fails with make 4.4 15 nativeBuildInputs = [ autoreconfHook pkg-config gnumake42 ]; 16 buildInputs = [ glib pcre json_c flex bison dtc pciutils dmidecode acpica-tools libbsd ]; 17 18 postPatch = '' 19 substituteInPlace src/lib/include/fwts_binpaths.h \ 20 --replace "/usr/bin/lspci" "${pciutils}/bin/lspci" \ 21 --replace "/usr/sbin/dmidecode" "${dmidecode}/bin/dmidecode" \ 22 --replace "/usr/bin/iasl" "${acpica-tools}/bin/iasl" 23 ''; 24 25 enableParallelBuilding = true; 26 27 meta = with lib; { 28 homepage = "https://wiki.ubuntu.com/FirmwareTestSuite"; 29 description = "Firmware Test Suite"; 30 platforms = platforms.linux; 31 license = licenses.gpl2; 32 maintainers = with maintainers; [ tadfisher ]; 33 }; 34}