2021-10-14 00:43:12 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, bison, flex }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "mceinject";
|
|
|
|
version = "unstable-2013-01-19";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "andikleen";
|
|
|
|
repo = "mce-inject";
|
|
|
|
rev = "4cbe46321b4a81365ff3aafafe63967264dbfec5";
|
|
|
|
sha256 = "0gjapg2hrlxp8ssrnhvc19i3r1xpcnql7xv0zjgbv09zyha08g6z";
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ flex bison ];
|
|
|
|
|
2023-03-04 12:14:45 +00:00
|
|
|
env.NIX_CFLAGS_COMPILE = "-Os -g -Wall";
|
2021-10-14 00:43:12 +00:00
|
|
|
|
|
|
|
NIX_LDFLAGS = [ "-lpthread" ];
|
|
|
|
|
|
|
|
makeFlags = [ "prefix=" ];
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
installFlags = [ "destdir=$(out)" "manprefix=/share" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Tool to inject machine checks into x86 kernel for testing";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "mce-inject";
|
2021-10-14 00:43:12 +00:00
|
|
|
longDescription = ''
|
|
|
|
mce-inject allows to inject machine check errors on the software level
|
|
|
|
into a running Linux kernel. This is intended for validation of the
|
|
|
|
kernel machine check handler.
|
|
|
|
'';
|
|
|
|
homepage = "https://github.com/andikleen/mce-inject/";
|
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = with maintainers; [ arkivm ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|