forked from mirrors/nixpkgs
OVMF: fix buils against openssl-3.0.13
Without the change the build fails on `staging-next` as https://hydra.nixos.org/build/248863953/nixlog/2/tail: /build/edk2-unvendored-src/CryptoPkg/Library/OpensslLib/openssl/crypto/property/property_parse.c:107:19: error: ‘INT64_MAX’ undeclared (first use in this function) 107 | if (v > ((INT64_MAX - (*s - '0')) / 10)) { | ^~~~~~~~~ The unbundled version of `openssl` `nixpkgs` injects into `edk2` started using `INT64_MAX` that `edk2`'s `<stdint.h>` does not provide and relies on `openssl` to define as a fallback. Let's pull in `openssl`'s own definition of those.
This commit is contained in:
parent
6556cc0f76
commit
7b01dd0370
|
@ -59,6 +59,11 @@ edk2 = stdenv.mkDerivation rec {
|
|||
mkdir -p $out/CryptoPkg/Library/OpensslLib/openssl
|
||||
tar --strip-components=1 -xf ${buildPackages.openssl.src} -C $out/CryptoPkg/Library/OpensslLib/openssl
|
||||
chmod -R +w $out/
|
||||
|
||||
# Fix missing INT64_MAX include that edk2 explicitly does not provide
|
||||
# via it's own <stdint.h>. Let's pull in openssl's definition instead:
|
||||
sed -i $out/CryptoPkg/Library/OpensslLib/openssl/crypto/property/property_parse.c \
|
||||
-e '1i #include "internal/numbers.h"'
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ pythonEnv ];
|
||||
|
|
Loading…
Reference in a new issue