diff options
author | Gao, Zhichao <zhichao.gao@intel.com> | 2020-11-12 13:55:49 +0800 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2020-11-17 19:26:50 +0000 |
commit | 1aa2cf0521aa0b1ef332ae435f7b3f7aa7e68f65 (patch) | |
tree | db5571d0226a2afd41acbd4fbfef8e6d1e4c4a59 | |
parent | d3d560e0f04e43868fc2f9e420a4897d66b14718 (diff) | |
download | edk2-1aa2cf0521aa0b1ef332ae435f7b3f7aa7e68f65.tar.gz edk2-1aa2cf0521aa0b1ef332ae435f7b3f7aa7e68f65.tar.bz2 edk2-1aa2cf0521aa0b1ef332ae435f7b3f7aa7e68f65.zip |
NetworkPkg: Enable MD5 while enable iSCSI
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3003
There is a plan to make MD5 disable as default.
The new MACRO ENABLE_MD5_DEPRECATED_INTERFACES
would be introduced to enable MD5. Make the
definition ahead of the change to avoid build
error after the MACRO changed.
1. Add the NetworkBuildOptions.dsc.inc to define
the MACRO for build (support: GCC, INTEL, MSFT and
RVCT)
2. Add the BuildOption file to Network.dsc.inc
Cc: Maciej Rabeda <maciej.rabeda@linux.intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Siyuan Fu <siyuan.fu@intel.com>
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com>
Message-Id: <20201112055558.2348-5-zhichao.gao@intel.com>
[lersek@redhat.com: clean up comments in "NetworkBuildOptions.dsc.inc"]
[lersek@redhat.com: hoist "BuildOptions" above "Components" in
"Network.dsc.inc" for bug compat with edk2-platforms]
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Siyuan Fu <siyuan.fu@intel.com>
-rw-r--r-- | NetworkPkg/Network.dsc.inc | 5 | ||||
-rw-r--r-- | NetworkPkg/NetworkBuildOptions.dsc.inc | 22 |
2 files changed, 26 insertions, 1 deletions
diff --git a/NetworkPkg/Network.dsc.inc b/NetworkPkg/Network.dsc.inc index 16f090a187..99fad885bf 100644 --- a/NetworkPkg/Network.dsc.inc +++ b/NetworkPkg/Network.dsc.inc @@ -7,7 +7,7 @@ # This file defines one build flag PLATFORMX64_ENABLE to support
# IA32 PEI and X64 DXE platform. Its default value is FALSE.
#
-# Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2019 - 2020, Intel Corporation. All rights reserved.<BR>
# Copyright (c) 2020, Hewlett Packard Enterprise Development LP. All rights reserved.<BR>
#
# SPDX-License-Identifier: BSD-2-Clause-Patent
@@ -30,6 +30,9 @@ [LibraryClasses]
!include NetworkPkg/NetworkLibs.dsc.inc
+[BuildOptions]
+!include NetworkPkg/NetworkBuildOptions.dsc.inc
+
!if $(PLATFORMX64_ENABLE) == TRUE
[Components.X64]
!include NetworkPkg/NetworkComponents.dsc.inc
diff --git a/NetworkPkg/NetworkBuildOptions.dsc.inc b/NetworkPkg/NetworkBuildOptions.dsc.inc new file mode 100644 index 0000000000..42d980d954 --- /dev/null +++ b/NetworkPkg/NetworkBuildOptions.dsc.inc @@ -0,0 +1,22 @@ +## @file
+# Network DSC include file for [BuildOptions] sections of all Architectures.
+#
+# This file can be included in the [BuildOptions*] section(s) of a platform DSC file
+# by using "!include NetworkPkg/NetworkBuildOptions.dsc.inc", to specify the C language
+# feature test macros (eg., API deprecation macros) according to the flags described
+# in "NetworkDefines.dsc.inc".
+#
+# Supported tool chain families: "GCC", "INTEL", "MSFT", "RVCT".
+#
+# Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>
+#
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+!if $(NETWORK_ISCSI_ENABLE) == TRUE
+ MSFT:*_*_*_CC_FLAGS = /D ENABLE_MD5_DEPRECATED_INTERFACES
+ INTEL:*_*_*_CC_FLAGS = /D ENABLE_MD5_DEPRECATED_INTERFACES
+ GCC:*_*_*_CC_FLAGS = -D ENABLE_MD5_DEPRECATED_INTERFACES
+ RVCT:*_*_*_CC_FLAGS = -DENABLE_MD5_DEPRECATED_INTERFACES
+!endif
|