summaryrefslogtreecommitdiff
path: root/Cryptlib/Include/OpenSslSupport.h
diff options
context:
space:
mode:
authorMathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com>2015-05-12 21:51:24 -0400
committerMathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com>2015-05-12 21:51:24 -0400
commitc2f285a93f50edc40d6f2b8114e4f9af812398d0 (patch)
tree6940e340eae98afd92b17d71589fdd0e9e6ba9ac /Cryptlib/Include/OpenSslSupport.h
parentd6f876b8504896cd20e3e6455a6baf7eabaf49f9 (diff)
downloadefi-boot-shim-c2f285a93f50edc40d6f2b8114e4f9af812398d0.tar.gz
efi-boot-shim-c2f285a93f50edc40d6f2b8114e4f9af812398d0.zip
More GCC 5 fixes: stdarg.h and other include tweaks, cherry-pick from
d51739a4.
Diffstat (limited to 'Cryptlib/Include/OpenSslSupport.h')
-rw-r--r--Cryptlib/Include/OpenSslSupport.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/Cryptlib/Include/OpenSslSupport.h b/Cryptlib/Include/OpenSslSupport.h
index 9e56ced7..b77838db 100644
--- a/Cryptlib/Include/OpenSslSupport.h
+++ b/Cryptlib/Include/OpenSslSupport.h
@@ -34,7 +34,7 @@ typedef VOID *FILE;
//
// Map all va_xxxx elements to VA_xxx defined in MdePkg/Include/Base.h
//
-#if !defined(__CC_ARM) // if va_list is not already defined
+#if !defined(__CC_ARM) || defined(_STDARG_H) // if va_list is not already defined
/*
* These are now unconditionally #defined by GNU_EFI's efistdarg.h,
* so we should #undef them here before providing a new definition.
@@ -94,7 +94,9 @@ typedef __builtin_va_list VA_LIST;
portably, hence it is provided by a Standard C header file.
For pre-Standard C compilers, here is a version that usually works
(but watch out!): */
+#ifndef offsetof
#define offsetof(type, member) ( (int) & ((type*)0) -> member )
+#endif
//
// Basic types from EFI Application Toolkit required to buiild Open SSL