REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4880

Facing the below issue after openssl is upgraded

Edk2\CryptoPkg\Library\OpensslLib\openssl\include\internal/safe_math.h(19):
warning C4668: '__GNUC__' is not defined as a preprocessor macro, replacing
with '0' for '#if/#elif'

Cc: Gerd Hoffmann <kra...@redhat.com>

Signed-off-by: Kalavakolanu Hema Anmisha <hema.anmisha.kalavakol...@intel.com>
---
 include/internal/safe_math.h | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/include/internal/safe_math.h b/include/internal/safe_math.h
index be37e6ab88..ba0b18082f 100644
--- a/include/internal/safe_math.h
+++ b/include/internal/safe_math.h
@@ -15,9 +15,11 @@
 
 # ifndef OPENSSL_NO_BUILTIN_OVERFLOW_CHECKING
 #  ifdef __has_builtin
-#   define has(func) __has_builtin(func)
-#  elif __GNUC__ > 5
-#   define has(func) 1
+#    define has(func) __has_builtin(func)
+#  elif defined(__GNUC__)
+#    if __GNUC__ > 5
+#      define has(func) 1
+#    endif
 #  endif
 # endif /* OPENSSL_NO_BUILTIN_OVERFLOW_CHECKING */
 
-- 
2.26.2.windows.1



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


Reply via email to