CC: Michael D Kinney <michael.d.kin...@intel.com>
CC: Liming Gao <gaolim...@byosoft.com.cn>
CC: Zhiguang Liu <zhiguang....@intel.com>
Signed-off-by: JoeX Lu <pen-chunx...@intel.com>
---
 MdePkg/Include/Base.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/MdePkg/Include/Base.h b/MdePkg/Include/Base.h
index 6597e441a6..951fce43ee 100644
--- a/MdePkg/Include/Base.h
+++ b/MdePkg/Include/Base.h
@@ -45,8 +45,12 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
 ///  to it after all compiler and linker optimizations have been performed.
 ///
 ///
+#if defined (__GNUC__)
+#define GLOBAL_REMOVE_IF_UNREFERENCED __attribute__((unused))
+#else
 #define GLOBAL_REMOVE_IF_UNREFERENCED
 #endif
+#endif
 
 //
 // Should be used in combination with NORETURN to avoid 'noreturn' returns
-- 
2.31.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#103732): https://edk2.groups.io/g/devel/message/103732
Mute This Topic: https://groups.io/mt/98551348/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to