Skip to content

Commit

Permalink
OvmfPkg: fix building without network support for X64 QEMU
Browse files Browse the repository at this point in the history
When NETWORK_ENABLE is set to FALSE, the compiler blames PCDs from
gEfiNetworkPkgTokenSpaceGuid. To overcome this error, we need to
add an extra conditional.

NETWORK_IP4_ENABLE and NETWORK_IP6_ENABLE are not used because
PXEv4 / PXEv6 boot support can be controlled from the QEMU command
line.

Tested on QEMU 9.0.2 with NETWORK_ENABLE=FALSE and
NETWORK_ENABLE=TRUE builds.

Cc: Ard Biesheuvel <[email protected]>
Cc: Jiewen Yao <[email protected]>
Cc: Gerd Hoffmann <[email protected]>
Cc: Saloni Kasbekar <[email protected]>
Cc: Zachary Clark-williams <[email protected]>
Signed-off-by: Alexander Goncharov <[email protected]>
  • Loading branch information
Joursoir committed Aug 7, 2024
1 parent 3134b11 commit e50f656
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions OvmfPkg/OvmfPkgX64.dsc
Original file line number Diff line number Diff line change
Expand Up @@ -691,8 +691,10 @@
!include OvmfPkg/Include/Dsc/OvmfTpmPcds.dsc.inc

# IPv4 and IPv6 PXE Boot support.
!if $(NETWORK_ENABLE) == TRUE
gEfiNetworkPkgTokenSpaceGuid.PcdIPv4PXESupport|0x01
gEfiNetworkPkgTokenSpaceGuid.PcdIPv6PXESupport|0x01
!endif

# Set ConfidentialComputing defaults
gEfiMdePkgTokenSpaceGuid.PcdConfidentialComputingGuestAttr|0
Expand Down

0 comments on commit e50f656

Please sign in to comment.