linux_xanmod: 5.11.14 -> 5.11.15
[NixPkgs.git] / pkgs / development / libraries / gnu-efi / default.nix
blobef8ef7648ebdda8db54bd4def5dc209ba759122c
1 { lib, stdenv, buildPackages, fetchurl, fetchpatch, pciutils }:
3 with lib;
5 stdenv.mkDerivation rec {
6   pname = "gnu-efi";
7   version = "3.0.11";
9   src = fetchurl {
10     url = "mirror://sourceforge/gnu-efi/${pname}-${version}.tar.bz2";
11     sha256 = "1ffnc4xbzfggs37ymrgfx76j56kk2644c081ivhr2bjkla9ag3gj";
12   };
14   patches = [
15     # Fix build on armv6l
16     (fetchpatch {
17       url = "https://sourceforge.net/p/gnu-efi/patches/_discuss/thread/25bb273a18/9c4d/attachment/0001-Fix-ARCH-on-armv6-and-other-32-bit-ARM-platforms.patch";
18       sha256 = "0pj03h20g2bbz6fr753bj1scry6919h57l1h86z3b6q7hqfj0b4r";
19     })
20   ];
22   buildInputs = [ pciutils ];
24   hardeningDisable = [ "stackprotector" ];
26   makeFlags = [
27     "PREFIX=\${out}"
28     "HOSTCC=${buildPackages.stdenv.cc.targetPrefix}cc"
29     "CROSS_COMPILE=${stdenv.cc.targetPrefix}"
30   ];
32   meta = with lib; {
33     description = "GNU EFI development toolchain";
34     homepage = "https://sourceforge.net/projects/gnu-efi/";
35     license = licenses.bsd3;
36     platforms = platforms.linux;
37   };