mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-12 16:53:21 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
45 lines
1.2 KiB
Nix
45 lines
1.2 KiB
Nix
{ lib, stdenv, gnu-efi, openssl, sbsigntool, perl, perlPackages,
|
|
help2man, fetchzip }:
|
|
stdenv.mkDerivation rec {
|
|
pname = "efitools";
|
|
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";
|
|
sha256 = "0jabgl2pxvfl780yvghq131ylpf82k7banjz0ksjhlm66ik8gb1i";
|
|
};
|
|
|
|
# https://github.com/ncroxon/gnu-efi/issues/7#issuecomment-2122741592
|
|
patches = [
|
|
./aarch64.patch
|
|
];
|
|
|
|
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"
|
|
patchShebangs .
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Tools for manipulating UEFI secure boot platforms";
|
|
homepage = "https://git.kernel.org/pub/scm/linux/kernel/git/jejb/efitools.git";
|
|
license = licenses.gpl2Only;
|
|
maintainers = [ maintainers.grahamc ];
|
|
platforms = platforms.linux;
|
|
};
|
|
}
|