diff options
Diffstat (limited to 'pkgs/os-specific/linux/mcelog/default.nix')
-rw-r--r-- | pkgs/os-specific/linux/mcelog/default.nix | 47 |
1 files changed, 20 insertions, 27 deletions
diff --git a/pkgs/os-specific/linux/mcelog/default.nix b/pkgs/os-specific/linux/mcelog/default.nix index 463722d2c96..55ab8eda9b5 100644 --- a/pkgs/os-specific/linux/mcelog/default.nix +++ b/pkgs/os-specific/linux/mcelog/default.nix @@ -1,37 +1,30 @@ -{ stdenv, fetchgit }: - -# Shows the machine check exceptions logged by the kernel. -# E.g. a log is generated when intel processors cpu-throttle. - -# The releases of this package are no longer on kernel.org -# hence we fetch them from github. Apparently, these -# are also more recent. - -let - - rev = "7fa99818367a6d17014b36d6f918ad848cbe7ce2"; - version = "1.0pre-${stdenv.lib.strings.substring 0 7 rev}"; - sha256 = "15eea3acd76190c7922c71028b31963221a2eefd8afa713879e191a26bc22ae7"; - -in stdenv.mkDerivation { +{ stdenv, fetchFromGitHub }: +let version = "115"; in +stdenv.mkDerivation { name = "mcelog-${version}"; - src = fetchgit { - url = "https://github.com/andikleen/mcelog"; - inherit sha256; - inherit rev; + src = fetchFromGitHub { + sha256 = "13m9y4xfd3klzj2xrwwwwg31pnjfwd0rbrr2845sf557iyqrshki"; + rev = "v${version}"; + repo = "mcelog"; + owner = "andikleen"; }; - makeFlags = "prefix=$(out) etcprefix=$(out) DOCDIR=$(out)/share/doc"; - - preInstall = '' - mkdir -p $out/share/doc + postPatch = '' + for i in mcelog.conf paths.h; do + substituteInPlace $i --replace /etc $out/etc + done + touch mcelog.conf.5 # avoid regeneration requiring Python ''; - meta = { - description = "Tool to display logged machine check exceptions"; + installFlags = "DESTDIR=$(out) prefix= DOCDIR=/share/doc"; + + meta = with stdenv.lib; { + inherit version; + description = "Log machine checks (memory, IO, and CPU hardware errors)"; homepage = http://mcelog.org/; - license = stdenv.lib.licenses.gpl2; + license = with licenses; gpl2; + maintainers = with maintainers; [ nckx ]; }; } |