From d4e4bf4e1e03eb5685474d240929d3e3b50581f8 Mon Sep 17 00:00:00 2001 From: Gary Ching-Pang Lin Date: Thu, 25 Sep 2014 18:12:42 +0800 Subject: [PATCH] Adapt the change in gnu-efi-3.0w --- Cryptlib/Include/OpenSslSupport.h | 13 +++++++------ Cryptlib/Makefile | 1 + Cryptlib/OpenSSL/Makefile | 3 +++ Makefile | 2 ++ 4 files changed, 13 insertions(+), 6 deletions(-) diff --git a/Cryptlib/Include/OpenSslSupport.h b/Cryptlib/Include/OpenSslSupport.h index 9e56ced..6b3bfbd 100644 --- a/Cryptlib/Include/OpenSslSupport.h +++ b/Cryptlib/Include/OpenSslSupport.h @@ -16,12 +16,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #define __OPEN_SSL_SUPPORT_H__ #include -#include -#include -#include -#include -#include -#include #define CONST const @@ -63,6 +57,13 @@ typedef __builtin_va_list VA_LIST; #define va_end(Marker) ((void)0) #endif +#include +#include +#include +#include +#include +#include + // // #defines from EFI Application Toolkit required to buiild Open SSL // diff --git a/Cryptlib/Makefile b/Cryptlib/Makefile index 9719a27..dbd79fb 100644 --- a/Cryptlib/Makefile +++ b/Cryptlib/Makefile @@ -3,6 +3,7 @@ EFI_INCLUDES = -IInclude -I$(EFI_INCLUDE) -I$(EFI_INCLUDE)/$(ARCH) -I$(EFI_INCLU CFLAGS = -ggdb -O0 -I. -fno-stack-protector -fno-strict-aliasing -fpic -fshort-wchar \ -Wall $(EFI_INCLUDES) +CFLAGS += -DGNU_EFI_USE_EXTERNAL_STDARG ifeq ($(ARCH),x86_64) CFLAGS += -mno-mmx -mno-sse -mno-red-zone -nostdinc -maccumulate-outgoing-args \ diff --git a/Cryptlib/OpenSSL/Makefile b/Cryptlib/OpenSSL/Makefile index 7990b3c..967e55e 100644 --- a/Cryptlib/OpenSSL/Makefile +++ b/Cryptlib/OpenSSL/Makefile @@ -18,6 +18,9 @@ endif ifeq ($(ARCH),arm) CFLAGS += -O2 -DTHIRTY_TWO_BIT -ffreestanding -I$(shell $(CC) -print-file-name=include) endif + +CFLAGS += -DGNU_EFI_USE_EXTERNAL_STDARG + LDFLAGS = -nostdlib -znocombreloc TARGET = libopenssl.a diff --git a/Makefile b/Makefile index 332a29b..52fd5b3 100644 --- a/Makefile +++ b/Makefile @@ -26,6 +26,8 @@ CFLAGS = -ggdb -O0 -fno-stack-protector -fno-strict-aliasing -fpic \ "-DDEFAULT_LOADER_CHAR=\"$(DEFAULT_LOADER)\"" \ $(EFI_INCLUDES) +CFLAGS += -DGNU_EFI_USE_EXTERNAL_STDARG + ifneq ($(origin OVERRIDE_SECURITY_POLICY), undefined) CFLAGS += -DOVERRIDE_SECURITY_POLICY endif -- 1.8.4.5