diff options
author | Alyssa Ross <hi@alyssa.is> | 2020-01-11 23:37:02 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2020-01-11 23:41:30 +0000 |
commit | 6c557e3f1c28cf87e9fba232811d6875dd1399c1 (patch) | |
tree | 035a071d5d8980df6de0fa42e2ef8fc0cce7055e /nixpkgs/pkgs/tools/misc/memtest86-efi/default.nix | |
parent | da7500bc026e937ac7fce7b50f67a0e1765737a7 (diff) | |
parent | e4134747f5666bcab8680aff67fa3b63384f9a0f (diff) | |
download | nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.gz nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.bz2 nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.lz nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.xz nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.tar.zst nixlib-6c557e3f1c28cf87e9fba232811d6875dd1399c1.zip |
Merge commit 'e4134747f5666bcab8680aff67fa3b63384f9a0f'
Diffstat (limited to 'nixpkgs/pkgs/tools/misc/memtest86-efi/default.nix')
-rw-r--r-- | nixpkgs/pkgs/tools/misc/memtest86-efi/default.nix | 44 |
1 files changed, 23 insertions, 21 deletions
diff --git a/nixpkgs/pkgs/tools/misc/memtest86-efi/default.nix b/nixpkgs/pkgs/tools/misc/memtest86-efi/default.nix index 10135d66408b..71409b1c3a8b 100644 --- a/nixpkgs/pkgs/tools/misc/memtest86-efi/default.nix +++ b/nixpkgs/pkgs/tools/misc/memtest86-efi/default.nix @@ -1,25 +1,28 @@ -{ lib, stdenv, fetchurl, unzip, libguestfs-with-appliance }: +{ fetchzip, lib, p7zip, stdenv }: stdenv.mkDerivation rec { pname = "memtest86-efi"; - version = "8.0"; + version = "8.2"; - src = fetchurl { - # TODO: The latest version of memtest86 is actually 8.1, but apparently the - # company has stopped distributing versioned binaries of memtest86: + src = fetchzip { + # TODO: The latest version of memtest86 is actually 8.2, but the + # company developing memtest86 has stopped providing a versioned download + # link for the latest version: + # # https://www.passmark.com/forum/memtest86/44494-version-8-1-distribution-file-is-not-versioned?p=44505#post44505 - # However, it does look like redistribution is okay, so if we had - # somewhere to host binaries that we make sure to version, then we could - # probably keep up with the latest versions released by the company. + # + # However, versioned links for the previous version are available, so that + # is what is being used. + # + # It does look like redistribution is okay, so if we had somewhere to host + # binaries that we make sure to version, then we could probably keep up + # with the latest versions released by the company. url = "https://www.memtest86.com/downloads/memtest86-${version}-usb.zip"; - sha256 = "147mnd7fnx2wvbzscw7pkg9ljiczhz05nb0cjpmww49a0ms4yknw"; + sha256 = "1x1wjssr4nnbnfan0pi7ni2dfwnm3288kq584hkfqcyza8xdx03i"; + stripRoot = false; }; - nativeBuildInputs = [ libguestfs-with-appliance unzip ]; - - unpackPhase = '' - unzip -q $src -d . - ''; + nativeBuildInputs = [ p7zip ]; installPhase = '' mkdir -p $out @@ -27,16 +30,15 @@ stdenv.mkDerivation rec { # memtest86 is distributed as a bootable USB image. It contains the actual # memtest86 EFI app. # - # The following command uses libguestfs to extract the actual EFI app from the - # usb image so that it can be installed directly on the hard drive. This creates - # the ./BOOT/ directory with the memtest86 EFI app. - guestfish --ro --add ./memtest86-usb.img --mount /dev/sda1:/ copy-out /EFI/BOOT . - - cp -r BOOT/* $out/ + # The following command uses p7zip to extract the actual EFI app from the + # usb image so that it can be installed directly on the hard drive. + 7z x -o$TEMP/temp-efi-dirs $src/memtest86-usb.img + 7z x -o$TEMP/memtest86-files $TEMP/temp-efi-dirs/EFI\ System\ Partition.img + cp -r $TEMP/memtest86-files/EFI/BOOT/* $out/ ''; meta = with lib; { - homepage = http://memtest86.com/; + homepage = "http://memtest86.com/"; downloadPage = "https://www.memtest86.com/download.htm"; description = "A tool to detect memory errors, to be run from a bootloader"; longDescription = '' |