[v5,3/4] build: limit what is built when using MSVC compiler

Message ID 1692222976-2908-4-git-send-email-roretzla@linux.microsoft.com (mailing list archive)
State Accepted, archived
Delegated to: David Marchand
Headers
Series enable use of the MSVC compiler |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Tyler Retzlaff Aug. 16, 2023, 9:56 p.m. UTC
  Build only kvargs and telemetry when is_ms_compiler.

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 app/meson.build       | 4 ++++
 drivers/meson.build   | 4 ++++
 lib/meson.build       | 8 ++++++++
 usertools/meson.build | 4 ++++
 4 files changed, 20 insertions(+)
  

Patch

diff --git a/app/meson.build b/app/meson.build
index 4fc1a83..ccf6f78 100644
--- a/app/meson.build
+++ b/app/meson.build
@@ -1,6 +1,10 @@ 
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017-2019 Intel Corporation
 
+if is_ms_compiler
+    subdir_done()
+endif
+
 disable_apps = ',' + get_option('disable_apps')
 disable_apps = run_command(list_dir_globs, disable_apps, check: true).stdout().split()
 
diff --git a/drivers/meson.build b/drivers/meson.build
index c909070..417b64b 100644
--- a/drivers/meson.build
+++ b/drivers/meson.build
@@ -1,6 +1,10 @@ 
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017-2019 Intel Corporation
 
+if is_ms_compiler
+    subdir_done()
+endif
+
 fs = import('fs')
 
 # Defines the order of dependencies evaluation
diff --git a/lib/meson.build b/lib/meson.build
index 7da3698..77c3e74 100644
--- a/lib/meson.build
+++ b/lib/meson.build
@@ -66,6 +66,14 @@  libraries = [
         'node',
 ]
 
+if is_ms_compiler
+    libraries = [
+            'log',
+            'kvargs',
+            'telemetry',
+    ]
+endif
+
 optional_libs = [
         'bitratestats',
         'cfgfile',
diff --git a/usertools/meson.build b/usertools/meson.build
index 0efa4a8..740b483 100644
--- a/usertools/meson.build
+++ b/usertools/meson.build
@@ -1,6 +1,10 @@ 
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
+if is_ms_compiler
+    subdir_done()
+endif
+
 install_data([
             'dpdk-devbind.py',
             'dpdk-pmdinfo.py',