summaryrefslogtreecommitdiffstats
path: root/OvmfPkg/Microvm
diff options
context:
space:
mode:
authorMike Beaton <mjsbeaton@gmail.com>2024-08-24 09:18:10 +0100
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2024-09-12 21:34:33 +0000
commit14d7ae94bc1d3367703a674b862748cb117b71c8 (patch)
treeec127125853b6cb5ee95f256e22e062a7f39b236 /OvmfPkg/Microvm
parentaf60615f0ef5f5d5ab3f9cea3215e07b8c73b600 (diff)
downloadedk2-14d7ae94bc1d3367703a674b862748cb117b71c8.tar.gz
edk2-14d7ae94bc1d3367703a674b862748cb117b71c8.tar.bz2
edk2-14d7ae94bc1d3367703a674b862748cb117b71c8.zip
OvmfPkg: Fix unable to build OVMF with -D NETWORK_ENABLE=0
https://bugzilla.tianocore.org/show_bug.cgi?id=4829 7f17a15 (2024/02/22) "OvmfPkg: Shell*.inc: allow building without network support" breaks building OVMF with `-D NETWORK_ENABLE=0`. Before this commit we could build OVMF e.g. with the following command in the OvmfPkg directory: ./build.sh -D NETWORK_ENABLE=0 After the commit the same command fails early with: /home/user/OpenSource/edk2/OvmfPkg/OvmfPkgX64.dsc(15): error F001: Pcd (gEfiNetworkPkgTokenSpaceGuid.PcdAllowHttpConnections) defined in DSC is not declared in DEC files referenced in INF files in FDF. Arch: ['X64'] The problem applies in Intel OvmfPkg platforms. Additionally, it applies in various other OvmfPkg platforms, but is masked buy another issue; namely that these platforms incorrectly still include some network packages when most are disabled. (A fix for that issue has previously been made, in OvmfPkg Intel platforms only, by d933ec1 followed by 7f17a15 .) This commit conditionally removes the undefined Pcd references in all OvmfPkg platforms which are now affected by this issue, and in all those which would be affected as and when the other issue mentioned above is fixed. Signed-off-by: Mike Beaton <mjsbeaton@gmail.com>
Diffstat (limited to 'OvmfPkg/Microvm')
-rw-r--r--OvmfPkg/Microvm/MicrovmX64.dsc2
1 files changed, 2 insertions, 0 deletions
diff --git a/OvmfPkg/Microvm/MicrovmX64.dsc b/OvmfPkg/Microvm/MicrovmX64.dsc
index 3b2312ddbc..1196ba98c9 100644
--- a/OvmfPkg/Microvm/MicrovmX64.dsc
+++ b/OvmfPkg/Microvm/MicrovmX64.dsc
@@ -647,9 +647,11 @@
gEfiSecurityPkgTokenSpaceGuid.PcdOptionRomImageVerificationPolicy|0x00
+!if $(NETWORK_ENABLE) == TRUE
# IPv4 and IPv6 PXE Boot support.
gEfiNetworkPkgTokenSpaceGuid.PcdIPv4PXESupport|0x01
gEfiNetworkPkgTokenSpaceGuid.PcdIPv6PXESupport|0x01
+!endif
# Set ConfidentialComputing defaults
gEfiMdePkgTokenSpaceGuid.PcdConfidentialComputingGuestAttr|0