nixpkgs/pkgs/tools/security/efitools/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

40 lines
1.1 KiB
Nix
Raw Normal View History

{ lib, stdenv, gnu-efi, openssl, sbsigntool, perl, perlPackages,
help2man, fetchzip }:
2019-01-22 15:55:38 +01:00
stdenv.mkDerivation rec {
pname = "efitools";
2019-01-22 15:55:38 +01:00
version = "1.9.2";
buildInputs = [
gnu-efi
openssl
sbsigntool
];
nativeBuildInputs = [
perl
perlPackages.FileSlurp
help2man
];
src = fetchzip {
url = "https://git.kernel.org/pub/scm/linux/kernel/git/jejb/efitools.git/snapshot/efitools-v${version}.tar.gz";
2019-01-22 15:55:38 +01:00
sha256 = "0jabgl2pxvfl780yvghq131ylpf82k7banjz0ksjhlm66ik8gb1i";
};
postPatch = ''
sed -i -e 's#/usr/include/efi#${gnu-efi}/include/efi/#g' Make.rules
sed -i -e 's#/usr/lib64/gnuefi#${gnu-efi}/lib/#g' Make.rules
sed -i -e 's#$(DESTDIR)/usr#$(out)#g' Make.rules
substituteInPlace lib/console.c --replace "EFI_WARN_UNKOWN_GLYPH" "EFI_WARN_UNKNOWN_GLYPH"
2019-01-22 15:55:38 +01:00
patchShebangs .
'';
meta = with lib; {
2019-01-22 15:55:38 +01:00
description = "Tools for manipulating UEFI secure boot platforms";
homepage = "https://git.kernel.org/pub/scm/linux/kernel/git/jejb/efitools.git";
2024-04-26 13:35:31 +02:00
license = licenses.gpl2Only;
2019-01-22 15:55:38 +01:00
maintainers = [ maintainers.grahamc ];
platforms = platforms.linux;
};
}