Merge pull request #252983 from RaitoBezarius/update/edk2

authored by Ryan Lahfa and committed by GitHub fc8f7c74 bc88e90b

+16 -5
+16 -5
pkgs/development/compilers/edk2/default.nix
··· 2 2 , clangStdenv 3 3 , fetchFromGitHub 4 4 , fetchpatch 5 + , runCommand 5 6 , libuuid 6 7 , python3 7 8 , bc ··· 28 29 else 29 30 "GCC5"; 30 31 31 - edk2 = stdenv.mkDerivation { 32 + edk2 = stdenv.mkDerivation rec { 32 33 pname = "edk2"; 33 - version = "202305"; 34 + version = "202308"; 34 35 35 36 patches = [ 36 37 # pass targetPrefix as an env var ··· 40 41 }) 41 42 ]; 42 43 43 - # submodules 44 - src = fetchFromGitHub { 44 + srcWithVendoring = fetchFromGitHub { 45 45 owner = "tianocore"; 46 46 repo = "edk2"; 47 47 rev = "edk2-stable${edk2.version}"; 48 48 fetchSubmodules = true; 49 - hash = "sha256-htOvV43Hw5K05g0SF3po69HncLyma3BtgpqYSdzRG4s="; 49 + hash = "sha256-Eoi1xf/hw/Knr7n0f0rgVof7wTgrHkmvV4eJjJV1NhM="; 50 50 }; 51 51 52 + # We don't want EDK2 to keep track of OpenSSL, 53 + # they're frankly bad at it. 54 + src = runCommand "edk2-unvendored-src" { } '' 55 + cp --no-preserve=mode -r ${srcWithVendoring} $out 56 + rm -rf $out/CryptoPkg/Library/OpensslLib/openssl 57 + mkdir -p $out/CryptoPkg/Library/OpensslLib/openssl 58 + tar --strip-components=1 -xf ${buildPackages.openssl.src} -C $out/CryptoPkg/Library/OpensslLib/openssl 59 + chmod -R +w $out/ 60 + ''; 61 + 52 62 nativeBuildInputs = [ pythonEnv ]; 53 63 depsBuildBuild = [ buildPackages.stdenv.cc buildPackages.util-linux buildPackages.bash ]; 54 64 strictDeps = true; ··· 69 79 # patchShebangs fails to see these when cross compiling 70 80 for i in $out/BaseTools/BinWrappers/PosixLike/*; do 71 81 substituteInPlace $i --replace '/usr/bin/env bash' ${buildPackages.bash}/bin/bash 82 + chmod +x "$i" 72 83 done 73 84 ''; 74 85