From 969c4c8d03cbf20df85194c1be145929642d648e Mon Sep 17 00:00:00 2001 From: Savva Mitrofanov Date: Fri, 3 Feb 2023 17:44:30 +0600 Subject: [PATCH] MdeModulePkg/BrotliCustomDecompressLib: Disable C4559 MSVC warning Disables redefinition warning due to win 10 sdk to fix build using MSVC toolchain Signed-off-by: Savva Mitrofanov --- .../BrotliCustomDecompressLib.inf | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/MdeModulePkg/Library/BrotliCustomDecompressLib/BrotliCustomDecompressLib.inf b/MdeModulePkg/Library/BrotliCustomDecompressLib/BrotliCustomDecompressLib.inf index 525e92408d..6d9ce87b0b 100644 --- a/MdeModulePkg/Library/BrotliCustomDecompressLib/BrotliCustomDecompressLib.inf +++ b/MdeModulePkg/Library/BrotliCustomDecompressLib/BrotliCustomDecompressLib.inf @@ -71,3 +71,12 @@ DebugLib BaseMemoryLib ExtractGuidedSectionLib + +[BuildOptions] + # + # Disables the following Visual Studio compiler warnings brought by brotli source, + # so we do not break the build with /WX option: + # C4559: 'function' : redefinition; the function gains __declspec(restrict) + # + MSFT:*_*_IA32_CC_FLAGS = /wd4559 + MSFT:*_*_X64_CC_FLAGS = /wd4559