[v3,1/2] build: change NUMA flag variable type to boolean
Checks
Commit Message
The has_libnuma flag was using 0 and 1 integer values, instead of the
more appropriate boolean type. Change to use true/false instead.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>
---
config/arm/meson.build | 2 +-
config/meson.build | 4 ++--
lib/eal/linux/meson.build | 2 +-
lib/vhost/meson.build | 2 +-
4 files changed, 5 insertions(+), 5 deletions(-)
@@ -592,7 +592,7 @@ if update_flags
part_number = soc_config['part_number']
soc_flags = soc_config.get('flags', [])
if not soc_config.get('numa', true)
- has_libnuma = 0
+ has_libnuma = false
endif
disable_drivers += ',' + soc_config.get('disable_drivers', '')
@@ -174,7 +174,7 @@ if link_lib != ''
endif
# check for libraries used in multiple places in DPDK
-has_libnuma = 0
+has_libnuma = false
find_libnuma = true
if meson.is_cross_build() and not meson.get_cross_property('numa', true)
# don't look for libnuma if explicitly disabled in cross build
@@ -184,7 +184,7 @@ if find_libnuma
numa_dep = cc.find_library('numa', required: false)
if numa_dep.found() and cc.has_header('numaif.h')
dpdk_conf.set10('RTE_HAS_LIBNUMA', true)
- has_libnuma = 1
+ has_libnuma = true
add_project_link_arguments('-lnuma', language: 'c')
dpdk_extra_ldflags += '-lnuma'
endif
@@ -20,6 +20,6 @@ sources += files(
)
deps += ['kvargs', 'telemetry']
-if has_libnuma == 1
+if has_libnuma
dpdk_conf.set10('RTE_EAL_NUMA_AWARE_HUGEPAGES', true)
endif
@@ -5,7 +5,7 @@ if not is_linux
build = false
reason = 'only supported on Linux'
endif
-if has_libnuma == 1
+if has_libnuma
dpdk_conf.set10('RTE_LIBRTE_VHOST_NUMA', true)
endif
if (toolchain == 'gcc' and cc.version().version_compare('>=8.3.0'))