[1/2] build: temporarily disable MSVC warnings

Message ID 1697548427-10153-2-git-send-email-roretzla@linux.microsoft.com (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series make dpdk buildable with latest msvc |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Tyler Retzlaff Oct. 17, 2023, 1:13 p.m. UTC
  Temporarily disable integer truncation and conversion warnings for MSVC
to allow CI pipeline to be established.

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 config/meson.build | 3 +++
 1 file changed, 3 insertions(+)
  

Comments

Bruce Richardson Oct. 17, 2023, 1:31 p.m. UTC | #1
On Tue, Oct 17, 2023 at 06:13:46AM -0700, Tyler Retzlaff wrote:
> Temporarily disable integer truncation and conversion warnings for MSVC
> to allow CI pipeline to be established.
> 
> Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
> ---
>  config/meson.build | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/config/meson.build b/config/meson.build
> index d56b0f9..6e8320e 100644
> --- a/config/meson.build
> +++ b/config/meson.build
> @@ -36,6 +36,9 @@ if is_ms_compiler
>      # the MSVC compiler regards as unsafe but are used by DPDK
>      dpdk_conf.set('_CRT_SECURE_NO_WARNINGS', 1)
>  
> +    # temporarily disable msvc specific warnings
> +    add_project_arguments('/wd4244', '/wd4267', language: 'c')
> +

Please add a comment line above indicating what the warning is being
disabled, e.g. unsigned compare warning etc.

Acked-by: Bruce Richardson <bruce.richardson@intel.com>
  

Patch

diff --git a/config/meson.build b/config/meson.build
index d56b0f9..6e8320e 100644
--- a/config/meson.build
+++ b/config/meson.build
@@ -36,6 +36,9 @@  if is_ms_compiler
     # the MSVC compiler regards as unsafe but are used by DPDK
     dpdk_conf.set('_CRT_SECURE_NO_WARNINGS', 1)
 
+    # temporarily disable msvc specific warnings
+    add_project_arguments('/wd4244', '/wd4267', language: 'c')
+
     # enable non-locking atomic operations
     add_project_arguments('/experimental:c11atomics', language: 'c')