On 12 June 2015 at 10:25, qlong <qin.l...@intel.com> wrote:
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Long, Qin <qin.l...@intel.com>
> Signed-off-by: qlong <qin.l...@intel.com>

This patch has a whitespace problem so it doesn't apply. See below.

Could you please redo this patch with all trivial whitespace changes
removed, and make sure it is based on a clean working tree?

> ---
>  CryptoPkg/Library/OpensslLib/Install.cmd     | 146 ++++---
>  CryptoPkg/Library/OpensslLib/Install.sh      | 146 ++++---
>  CryptoPkg/Library/OpensslLib/OpensslLib.inf  | 620 
> +++++++++++++++++++--------
>  CryptoPkg/Library/OpensslLib/Patch-HOWTO.txt |  46 +-
>  4 files changed, 608 insertions(+), 350 deletions(-)
>
[...]
> diff --git a/CryptoPkg/Library/OpensslLib/OpensslLib.inf 
> b/CryptoPkg/Library/OpensslLib/OpensslLib.inf
> index f564145..d45922e 100644
> --- a/CryptoPkg/Library/OpensslLib/OpensslLib.inf
> +++ b/CryptoPkg/Library/OpensslLib/OpensslLib.inf
> @@ -631,47 +880,44 @@
>    DebugLib

There are 3 spaces before DebugLib, but there are only 2 in the original file

>
>  [BuildOptions]

There is an additional space before [ but there is none in the original file.

> -   #
> -   # Override MSFT build option to remove /W4 (to silence warning messages 
> when building OpenSSL).
> -   #
> -   MSFT:DEBUG_VS2003_IA32_CC_FLAGS        == /nologo /c /WX /Gs32768 /Gy /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /GX- /Zi /Gm -U_WIN32 
> -U_WIN64 -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:RELEASE_VS2003_IA32_CC_FLAGS      == /nologo /c /WX /Gs32768 /Gy /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /GX- -U_WIN32 -U_WIN64 
> -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w  -DTHIRTY_TWO_BIT
> -   MSFT:DEBUG_VS2003xASL_IA32_CC_FLAGS    == /nologo /c /WX /Gs32768 /Gy /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /GX- /Zi /Gm -U_WIN32 
> -U_WIN64 -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:RELEASE_VS2003xASL_IA32_CC_FLAGS  == /nologo /c /WX /Gs32768 /Gy /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /GX- -U_WIN32 -U_WIN64 
> -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:DEBUG_DDK3790_IA32_CC_FLAGS       == /nologo /c /WX /Gy /Gs32768 /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /Zi /Gm -U_WIN32 -U_WIN64 
> -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:RELEASE_DDK3790_IA32_CC_FLAGS     == /nologo /c /WX /Gy /Gs32768 /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF -U_WIN32 -U_WIN64 -U_MSC_VER 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:DEBUG_DDK3790xASL_IA32_CC_FLAGS   == /nologo /c /WX /Gy /Gs32768 /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /Zi /Gm -U_WIN32 -U_WIN64 
> -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:RELEASE_DDK3790xASL_IA32_CC_FLAGS == /nologo /c /WX /Gy /Gs32768 /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF -U_WIN32 -U_WIN64 -U_MSC_VER 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:DEBUG_*_IA32_CC_FLAGS             == /nologo /c /WX /GS- /Gs32768 /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /Gy /Zi /Gm -U_WIN32 
> -U_WIN64 -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:RELEASE_*_IA32_CC_FLAGS           == /nologo /c /WX /GS- /Gs32768 /D 
> UNICODE /O1ib2 /GL /FIAutoGen.h /EHs-c- /GR- /GF -U_WIN32 -U_WIN64 -U_MSC_VER 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:NOOPT_*_IA32_CC_FLAGS             == /nologo /c /WX /GS- /Gs32768 /D 
> UNICODE /Od /FIAutoGen.h /EHs-c- /GR- /GF /Gy /Zi /Gm -U_WIN32 -U_WIN64 
> -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   MSFT:DEBUG_*_X64_CC_FLAGS              == /nologo /c /WX /GS- /X /Gs32768 
> /D UNICODE /O1ib2s /GL /Gy /FIAutoGen.h /EHs-c- /GR- /GF /Zi /Gm -U_WIN32 
> -U_WIN64 -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> -   MSFT:RELEASE_*_X64_CC_FLAGS            == /nologo /c /WX /GS- /X /Gs32768 
> /D UNICODE /O1ib2s /GL /Gy /FIAutoGen.h /EHs-c- /GR- /GF -U_WIN32 -U_WIN64 
> -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> -   MSFT:NOOPT_*_X64_CC_FLAGS              == /nologo /c /WX /GS- /X /Gs32768 
> /D UNICODE /Od /Gy /FIAutoGen.h /EHs-c- /GR- /GF /Zi /Gm -U_WIN32 -U_WIN64 
> -U_MSC_VER $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> -   MSFT:DEBUG_*_IPF_CC_FLAGS              == /nologo /c /WX /GS- /X /EHs-c- 
> /GR- /Gy /Os /GL /FIAutoGen.h /QIPF_fr32 /Zi -U_WIN32 -U_WIN64 -U_MSC_VER 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> -   MSFT:RELEASE_*_IPF_CC_FLAGS            == /nologo /c /WX /GS- /X /EHs-c- 
> /GR- /Gy /Os /GL /FIAutoGen.h /QIPF_fr32 -U_WIN32 -U_WIN64 -U_MSC_VER 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> -   MSFT:NOOPT_*_IPF_CC_FLAGS              == /nologo /c /WX /GS- /X /EHs-c- 
> /GR- /Gy /Od /FIAutoGen.h /QIPF_fr32 /Zi -U_WIN32 -U_WIN64 -U_MSC_VER 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> -   INTEL:*_*_IA32_CC_FLAGS                = -U_WIN32 -U_WIN64 -U_MSC_VER 
> -U__ICC $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> -   INTEL:*_*_X64_CC_FLAGS                 = -U_WIN32 -U_WIN64 -U_MSC_VER 
> -U__ICC $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> -   INTEL:*_*_IPF_CC_FLAGS                 = -U_WIN32 -U_WIN64 -U_MSC_VER 
> -U__ICC $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> -   GCC:*_*_IA32_CC_FLAGS                  = -U_WIN32 -U_WIN64 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w -DTHIRTY_TWO_BIT
> -   GCC:*_*_X64_CC_FLAGS                   = -U_WIN32 -U_WIN64 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT_LONG
> -   GCC:*_*_IPF_CC_FLAGS                   = -U_WIN32 -U_WIN64 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT_LONG
> -   GCC:*_*_ARM_CC_FLAGS                   = $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -w -DTHIRTY_TWO_BIT
> -   GCC:*_*_AARCH64_CC_FLAGS               = $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT_LONG
> -
> -   # suppress the following warnings in openssl so we don't break the build 
> with warnings-as-errors:
> -   # 1295: Deprecated declaration <entity> - give arg types
> -   #  550: <entity> was set but never used
> -   # 1293: assignment in condition
> -   #  111: statement is unreachable (invariably "break;" after "return X;" 
> in case statement)
> -   #   68: integer conversion resulted in a change of sign ("if (Status == 
> -1)")
> -   #  177: <entity> was declared but never referenced
> -   #  223: function <entity> declared implicitly
> -   #  144: a value of type <type> cannot be used to initialize an entity of 
> type <type>
> -   #  513: a value of type <type> cannot be assigned to an entity of type 
> <type>
> -   #  188: enumerated type mixed with another type (i.e. passing an integer 
> as an enum without a cast)
> -   # 1296: Extended constant initialiser used
> -   RVCT:*_*_ARM_CC_FLAGS                  = $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) --library_interface=aeabi_clib99 --fpu=vfpv3 
> -DTHIRTY_TWO_BIT --diag_suppress=1296,1295,550,1293,111,68,177,223,144,513,188
> -   XCODE:*_*_IA32_CC_FLAGS                = -mmmx -msse -U_WIN32 -U_WIN64 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w -DTHIRTY_TWO_BIT
> -   XCODE:*_*_X64_CC_FLAGS                 = -mmmx -msse -U_WIN32 -U_WIN64 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT_LONG
> \ No newline at end of file
> +  #
> +  # Disables the following Visual Studio compiler warnings brought by 
> openssl source, so we do not break the build with /WX option:
> +  # C4244: conversion from type1 to type2, possible loss of data
> +  # C4702: unreachable code
> +  # C4706: assignment within conditional expression
> +  # C4133: incompatible types - from type1 to type2
> +  # C4245: conversion from type1 to type2, signed/unsigned mismatch
> +  # C4267: conversion from size_t to type, possible loss of data
> +  # C4305: truncation from type1 to type2 of smaller size
> +  # C4306: conversion from type1 to type2 of greater size
> +  # C4702: Potentially uninitialized local variable name used
> +  #
> +  MSFT:*_*_IA32_CC_FLAGS    = -U_WIN32 -U_WIN64 -U_MSC_VER $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -DTHIRTY_TWO_BIT /wd4244 /wd4701 /wd4702 /wd4706
> +  MSFT:*_*_X64_CC_FLAGS     = -U_WIN32 -U_WIN64 -U_MSC_VER $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -DSIXTY_FOUR_BIT /wd4133 /wd4244 /wd4245 /wd4267 /wd4701 
> /wd4305 /wd4306 /wd4702 /wd4706
> +  MSFT:*_*_IPF_CC_FLAGS     = -U_WIN32 -U_WIN64 -U_MSC_VER $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -DSIXTY_FOUR_BIT /wd4133 /wd4244 /wd4245 /wd4267 /wd4701 
> /wd4305 /wd4306 /wd4702 /wd4706
> +
> +  INTEL:*_*_IA32_CC_FLAGS   = -U_WIN32 -U_WIN64 -U_MSC_VER -U__ICC 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DTHIRTY_TWO_BIT
> +  INTEL:*_*_X64_CC_FLAGS    = -U_WIN32 -U_WIN64 -U_MSC_VER -U__ICC 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> +  INTEL:*_*_IPF_CC_FLAGS    = -U_WIN32 -U_WIN64 -U_MSC_VER -U__ICC 
> $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) /w -DSIXTY_FOUR_BIT
> +
> +  GCC:*_*_IA32_CC_FLAGS     = -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -w -DTHIRTY_TWO_BIT
> +  GCC:*_*_X64_CC_FLAGS      = -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT_LONG
> +  GCC:*_*_IPF_CC_FLAGS      = -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT_LONG
> +  GCC:*_*_ARM_CC_FLAGS      = $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w 
> -DTHIRTY_TWO_BIT
> +  GCC:*_*_AARCH64_CC_FLAGS  = $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) -w 
> -DSIXTY_FOUR_BIT_LONG
> +
> +  # suppress the following warnings in openssl so we don't break the build 
> with warnings-as-errors:
> +  # 1295: Deprecated declaration <entity> - give arg types
> +  #  550: <entity> was set but never used
> +  # 1293: assignment in condition
> +  #  111: statement is unreachable (invariably "break;" after "return X;" in 
> case statement)
> +  #   68: integer conversion resulted in a change of sign ("if (Status == 
> -1)")
> +  #  177: <entity> was declared but never referenced
> +  #  223: function <entity> declared implicitly
> +  #  144: a value of type <type> cannot be used to initialize an entity of 
> type <type>
> +  #  513: a value of type <type> cannot be assigned to an entity of type 
> <type>
> +  #  188: enumerated type mixed with another type (i.e. passing an integer 
> as an enum without a cast)
> +  # 1296: Extended constant initialiser used
> +  RVCT:*_*_ARM_CC_FLAGS     = $(OPENSSL_FLAGS) $(OPENSSL_EXFLAGS) 
> --library_interface=aeabi_clib99 --fpu=vfpv3 -DTHIRTY_TWO_BIT 
> --diag_suppress=1296,1295,550,1293,111,68,177,223,144,513,188
> +  XCODE:*_*_IA32_CC_FLAGS   = -mmmx -msse -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -w -DTHIRTY_TWO_BIT
> +  XCODE:*_*_X64_CC_FLAGS    = -mmmx -msse -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) 
> $(OPENSSL_EXFLAGS) -w -DSIXTY_FOUR_BIT_LONG
> diff --git a/CryptoPkg/Library/OpensslLib/Patch-HOWTO.txt 
> b/CryptoPkg/Library/OpensslLib/Patch-HOWTO.txt
> index de60a5f..e5220dc 100644
> --- a/CryptoPkg/Library/OpensslLib/Patch-HOWTO.txt
> +++ b/CryptoPkg/Library/OpensslLib/Patch-HOWTO.txt
> @@ -4,49 +4,49 @@
>  
> ================================================================================
>    OpenSSL is a well-known open source implementation of SSL and TLS 
> protocols.
>  The core library implements the basic cryptographic functions and provides 
> various
> -utility functions. The OpenSSL library is widely used in variety of security
> -products development as base crypto provider. (See http://www.openssl.org 
> for more
> +utility functions. The OpenSSL library is widely used in variety of security
> +products development as base crypto provider. (See http://www.openssl.org 
> for more
>  information for OpenSSL).
> -  UEFI (Unified Extensible Firmware Interface) is a specification detailing 
> the
> -interfaces between OS and platform firmware. Several security features were
> -introduced (e.g. Authenticated Variable Service, Driver Signing, etc) from 
> UEFI
> -2.2 (http://www.uefi.org). These security features highly depends on the
> +  UEFI (Unified Extensible Firmware Interface) is a specification detailing 
> the
> +interfaces between OS and platform firmware. Several security features were
> +introduced (e.g. Authenticated Variable Service, Driver Signing, etc) from 
> UEFI
> +2.2 (http://www.uefi.org). These security features highly depends on the
>  cryptography. This patch will enable openssl building under UEFI environment.
>
>
>  
> ================================================================================
>                                  OpenSSL-Version
>  
> ================================================================================
> -  Current supported OpenSSL version for UEFI Crypto Library is 0.9.8zf.
> -    http://www.openssl.org/source/openssl-0.9.8zf.tar.gz
> +  Current supported OpenSSL version for UEFI Crypto Library is 1.0.2b.
> +    http://www.openssl.org/source/openssl-1.0.2b.tar.gz
>
>
>  
> ================================================================================
>                        HOW to Install Openssl for UEFI Building
>  
> ================================================================================
> -1.  Download OpenSSL 0.9.8zf from official website:
> -       http://www.openssl.org/source/openssl-0.9.8zf.tar.gz
> +1.  Download OpenSSL 1.0.2b from official website:
> +    http://www.openssl.org/source/openssl-1.0.2b.tar.gz
>
> -    NOTE: Some web browsers may rename the downloaded TAR file to 
> openssl-0.9.8zf.tar.tar.
> -          When you do the download, rename the "openssl-0.9.8zf.tar.tar" to
> -          "openssl-0.9.8zf.tar.gz" or rename the local downloaded file with 
> ".tar.tar"
> +    NOTE: Some web browsers may rename the downloaded TAR file to 
> openssl-1.0.2b.tar.tar.
> +          When you do the download, rename the "openssl-1.0.2b.tar.tar" to
> +          "openssl-1.0.2b.tar.gz" or rename the local downloaded file with 
> ".tar.tar"
>            extension to ".tar.gz".
>
> -2.  Extract TAR into CryptoPkg/Library/OpenSslLib/openssl-0.9.8zf
> +2.  Extract TAR into CryptoPkg/Library/OpenSslLib/openssl-1.0.2b
>
> -    NOTE: If you use WinZip to unpack the openssl source in Windows, please
> -          uncheck the WinZip smart CR/LF conversion option (WINZIP: Options 
> -->
> +    NOTE: If you use WinZip to unpack the openssl source in Windows, please
> +          uncheck the WinZip smart CR/LF conversion option (WINZIP: Options 
> -->
>            Configuration --> Miscellaneous --> "TAR file smart CR/LF 
> conversion").
> -
> -3.  Apply this patch: EDKII_openssl-0.9.8zf.patch, and make installation
> +
> +3.  Apply this patch: EDKII_openssl-1.0.2b.patch, and make installation
>
>      For Windows Environment:
>      ------------------------
>      1) Make sure the patch utility has been installed in your machine.
> -       Install Cygwin or get the patch utility binary from
> +       Install Cygwin or get the patch utility binary from
>            http://gnuwin32.sourceforge.net/packages/patch.htm
> -    2) cd $(WORKSPACE)\CryptoPkg\Library\OpensslLib\openssl-0.9.8zf
> -    3) patch -p0 -i ..\EDKII_openssl-0.9.8zf.patch
> +    2) cd $(WORKSPACE)\CryptoPkg\Library\OpensslLib\openssl-1.0.2b
> +    3) patch -p0 -i ..\EDKII_openssl-1.0.2b.patch
>      4) cd ..
>      5) Install.cmd
>
> @@ -54,8 +54,8 @@ cryptography. This patch will enable openssl building under 
> UEFI environment.
>      -----------------------
>      1) Make sure the patch utility has been installed in your machine.
>         Patch utility is available from 
> http://directory.fsf.org/project/patch/
> -    2) cd $(WORKSPACE)/CryptoPkg/Library/OpensslLib/openssl-0.9.8zf
> -    3) patch -p0 -i ../EDKII_openssl-0.9.8zf.patch
> +    2) cd $(WORKSPACE)/CryptoPkg/Library/OpensslLib/openssl-1.0.2b
> +    3) patch -p0 -i ../EDKII_openssl-1.0.2b.patch
>      4) cd ..
>      5) ./Install.sh
>
> --
> 1.9.5.msysgit.1
>

------------------------------------------------------------------------------
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to