From 1cc3c2b778a5b582967bb36109c3521008131eff Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 3 Jan 2008 15:14:37 +0000 Subject: [PATCH] * Added Memtest86+. svn path=/nixpkgs/trunk/; revision=10059 --- pkgs/tools/misc/memtest86/default.nix | 26 ++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 4 ++++ 2 files changed, 30 insertions(+) create mode 100644 pkgs/tools/misc/memtest86/default.nix diff --git a/pkgs/tools/misc/memtest86/default.nix b/pkgs/tools/misc/memtest86/default.nix new file mode 100644 index 000000000000..32f2094b44cc --- /dev/null +++ b/pkgs/tools/misc/memtest86/default.nix @@ -0,0 +1,26 @@ +{stdenv, fetchurl}: + +stdenv.mkDerivation { + name = "memtest86+-1.70"; + + src = fetchurl { + url = http://www.memtest.org/download/1.70/memtest86+-1.70.tar.gz; + sha256 = "1swj4hc764qwb3j80kvvb4qg5maq9dp8pxzy9jkk187jf92j8vfw"; + }; + + preBuild = '' + # Really dirty hack to get Memtest to build without needing a Glibc + # with 32-bit libraries and headers. + if test "$system" = x86_64-linux; then + mkdir gnu + touch gnu/stubs-32.h + fi + ''; + + NIX_CFLAGS_COMPILE = "-I."; + + installPhase = '' + ensureDir $out + cp memtest.bin $out/ + ''; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index b40daf8b7d62..ca9db6687727 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -602,6 +602,10 @@ rec { inherit fetchurl stdenv db4 groff; }; + memtest86 = import ../tools/misc/memtest86 { + inherit fetchurl stdenv; + }; + mjpegtools = import ../tools/video/mjpegtools { inherit fetchurl stdenv libjpeg; inherit (xlibs) libX11;