edk2/NetworkPkg/NetworkDynamicPcds.dsc.inc
Mike Beaton b197541f29 OvmfPkg,ArmVirtPkg,NetworkPkg: Fix build with -D NETWORK_ENABLE=0
Previous PR https://github.com/tianocore/edk2/pull/6087 restored the
ability to build OvmfPkg with -D NETWORK_ENABLE=0.

b3b3cfab7e has broken it again, since the
.dsc references to OvmfPkg/VirtioNetDxe/VirtioNet.inf were moved from
outside !if $(NETWORK_ENABLE) == TRUE to inside it, while the .fdf
references remained outside.

In discussion in https://github.com/tianocore/edk2/pull/11719 it was
decided to move the .fdf references inside the conditional, i.e. not to
include VirtioNetDxe unless the rest of the network stack is being built.

Removal of VirtioNetDxe driver on -D NETWORK_ENABLE=0 has only
been applied to those packages which are already using
OvmfPkg/Dsc/Includes/NetworkComponents.dsc.inc.

f9408b7cc1 introduces new PCDs which also
need to be moved inside a NETWORK_ENABLE test in order to allow building
with -D NETWORK_ENABLE=0, which is also done here.

Continuous-integration-options: PatchCheck.ignore-multi-package

Signed-off-by: Mike Beaton <mjsbeaton@gmail.com>
2025-11-21 12:08:00 +01:00

28 lines
883 B
PHP

## @file
# Network DSC include file for [PcdsDynamic*] section of all Architectures.
#
# This file can be included to the [PcdsDynamic*] section(s) of a platform DSC file
# by using "!include NetworkPkg/NetworkDynamicPcds.dsc.inc" to specify PCD settings
# according to the value of flags described in "NetworkDefines.dsc.inc".
#
# Copyright (c) 2024, Aleksandr Goncharov. All rights reserved.<BR>
#
# SPDX-License-Identifier: BSD-2-Clause-Patent
#
##
!if $(NETWORK_ENABLE) == TRUE
#
# IPv4 and IPv6 PXE Boot support.
#
!if $(NETWORK_PXE_BOOT_ENABLE) == TRUE
gEfiNetworkPkgTokenSpaceGuid.PcdIPv4PXESupport|0x01
gEfiNetworkPkgTokenSpaceGuid.PcdIPv6PXESupport|0x01
!endif
#
# IPv4 and IPv6 HTTP Boot support.
#
gEfiNetworkPkgTokenSpaceGuid.PcdIPv4HttpSupport|TRUE
gEfiNetworkPkgTokenSpaceGuid.PcdIPv6HttpSupport|TRUE
!endif