]> git.proxmox.com Git - mirror_edk2.git/commitdiff
CryptoPkg: fix build support under RVCT
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Thu, 17 Dec 2015 17:02:06 +0000 (17:02 +0000)
committerabiesheuvel <abiesheuvel@Edk2>
Thu, 17 Dec 2015 17:02:06 +0000 (17:02 +0000)
The RVCT compiler chokes on a couple of issues in upstream OpenSSL that
can be confirmed to be non-issues by inspection. So just ignore these
warnings entirely.

Also, move the dummy -J system include from CryptoPkg.dsc to the various
.INF files, since it will not be picked up when building the CryptoPkg
libraries from a platform .DSC

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Qin Long <qin.long@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19328 6f19259b-4bc3-4df7-8a09-765794883524

CryptoPkg/CryptoPkg.dsc
CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf
CryptoPkg/Library/BaseCryptLib/PeiCryptLib.inf
CryptoPkg/Library/BaseCryptLib/RuntimeCryptLib.inf
CryptoPkg/Library/OpensslLib/OpensslLib.inf

index 043704067a221b4804c452e1eecd6bc22195c605..fdd0431fd1db691b9884b364dc769eefdf6a3c66 100644 (file)
 [LibraryClasses.common.UEFI_APPLICATION]\r
   BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf\r
 \r
-###############################################################################\r
-#\r
-# BuildOptions Section - Define the module specific tool chain flags that\r
-#                        should be used as the default flags for a module.\r
-#                        These flags are appended to any standard flags that\r
-#                        are defined by the build process.\r
-#\r
-# -JCryptoPkg/Include : To disable the use of the system includes provided by\r
-#                       the RVCT toolchain.\r
-# --diag_remark=1     : To make the warning "#1-D: last line of file ends\r
-#                       without a newline" just a remark such that the\r
-#                       build doesn't stop as warnings are considered as\r
-#                       errors.\r
-#\r
-################################################################################\r
-[BuildOptions]\r
-RVCT:*_*_ARM_CC_FLAGS = -JCryptoPkg/Include --diag_remark=1\r
-\r
 ################################################################################\r
 #\r
 # Pcd Section - list of all EDK II PCD Entries defined by this Platform\r
index 05cfe11b2cc4c87a877be2545bc6015c37d789df..a66faf1c04c0d659ed5deeeb39f2b371798d3b88 100644 (file)
@@ -95,3 +95,7 @@
   #   C4305: truncation from type1 to type2 (Introduced by RFC3161 Timestamp ASN.1 declarations)\r
   MSFT:*_*_*_CC_FLAGS = /wd4305\r
   GCC:*_GCC44_IA32_CC_FLAGS = "-D__cdecl=__attribute__((cdecl))" "-D__declspec(t)=__attribute__((t))"\r
+\r
+  # -JCryptoPkg/Include : To disable the use of the system includes provided by RVCT\r
+  # --diag_remark=1     : Reduce severity of "#1-D: last line of file ends without a newline"\r
+  RVCT:*_*_ARM_CC_FLAGS = -JCryptoPkg/Include --diag_remark=1\r
index b522a3628badca8a16911b0cb91225f7284de062..75f8e6e5f06dbb37683d80ba579bf62f9efe86f5 100644 (file)
@@ -85,3 +85,7 @@
 #\r
 [BuildOptions]\r
   GCC:*_GCC44_IA32_CC_FLAGS = "-D__cdecl=__attribute__((cdecl))" "-D__declspec(t)=__attribute__((t))"\r
+\r
+  # -JCryptoPkg/Include : To disable the use of the system includes provided by RVCT\r
+  # --diag_remark=1     : Reduce severity of "#1-D: last line of file ends without a newline"\r
+  RVCT:*_*_ARM_CC_FLAGS = -JCryptoPkg/Include --diag_remark=1\r
index cf38b51ff20df743e382c27c52e69e4d5b396203..446f0ae47605fd4b874cf073fcfd87bcb6e6972e 100644 (file)
@@ -98,3 +98,7 @@
 #\r
 [BuildOptions]\r
   GCC:*_GCC44_IA32_CC_FLAGS = "-D__cdecl=__attribute__((cdecl))" "-D__declspec(t)=__attribute__((t))"\r
+\r
+  # -JCryptoPkg/Include : To disable the use of the system includes provided by RVCT\r
+  # --diag_remark=1     : Reduce severity of "#1-D: last line of file ends without a newline"\r
+  RVCT:*_*_ARM_CC_FLAGS = -JCryptoPkg/Include --diag_remark=1\r
index 216c1bb764eb142e874e321e40fcf523bb7d819b..54ac055a43ca605c00385acedae0f6a95da2a0ad 100644 (file)
   #  513: a value of type <type> cannot be assigned to an entity of type <type>\r
   #  188: enumerated type mixed with another type (i.e. passing an integer as an enum without a cast)\r
   # 1296: Extended constant initialiser used\r
-  RVCT:*_*_ARM_CC_FLAGS     = $(OPENSSL_FLAGS) --library_interface=aeabi_clib99 --diag_suppress=1296,1295,550,1293,111,68,177,223,144,513,188\r
+  #  128: loop is not reachable - may be emitted inappropriately if code follows a conditional return\r
+  #       from the function that evaluates to true at compile time\r
+  #  546: transfer of control bypasses initialization - may be emitted inappropriately if the uninitialized\r
+  #       variable is never referenced after the jump\r
+  #    1: ignore "#1-D: last line of file ends without a newline"\r
+  RVCT:*_*_ARM_CC_FLAGS     = $(OPENSSL_FLAGS) --library_interface=aeabi_clib99 --diag_suppress=1296,1295,550,1293,111,68,177,223,144,513,188,128,546,1 -JCryptoPkg/Include\r
   XCODE:*_*_IA32_CC_FLAGS   = -mmmx -msse -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) -w\r
   XCODE:*_*_X64_CC_FLAGS    = -mmmx -msse -U_WIN32 -U_WIN64 $(OPENSSL_FLAGS) -w\r