Use the base code build handling logic in the drivers/meson.build file, rather than re-implementing it in the driver itself.
Signed-off-by: Bruce Richardson <bruce.richard...@intel.com> --- drivers/net/hinic/base/meson.build | 16 +++++----------- drivers/net/hinic/meson.build | 1 - 2 files changed, 5 insertions(+), 12 deletions(-) diff --git a/drivers/net/hinic/base/meson.build b/drivers/net/hinic/base/meson.build index 3aa53df881..9028acdf4d 100644 --- a/drivers/net/hinic/base/meson.build +++ b/drivers/net/hinic/base/meson.build @@ -1,7 +1,7 @@ # SPDX-License-Identifier: BSD-3-Clause # Copyright(c) 2017 Huawei Technologies Co., Ltd -sources = [ +base_sources = files( 'hinic_pmd_api_cmd.c', 'hinic_pmd_cfg.c', 'hinic_pmd_cmdq.c', @@ -13,7 +13,7 @@ sources = [ 'hinic_pmd_nicio.c', 'hinic_pmd_wq.c', 'hinic_pmd_mbox.c', -] +) extra_flags = [] # The driver runs only on arch64 machine, remove 32bit warnings @@ -22,16 +22,10 @@ if not dpdk_conf.get('RTE_ARCH_64') endif foreach flag: extra_flags - if cc.has_argument(flag) - cflags += flag - endif + if cc.has_argument(flag) + cflags += flag + endif endforeach deps += ['hash'] -c_args = cflags - -base_lib = static_library('hinic_base', sources, - dependencies: [static_rte_eal, static_rte_ethdev, static_rte_bus_pci, static_rte_hash], - c_args: c_args) -base_objs = base_lib.extract_all_objects(recursive: true) diff --git a/drivers/net/hinic/meson.build b/drivers/net/hinic/meson.build index 8242e0052e..36cc9431a6 100644 --- a/drivers/net/hinic/meson.build +++ b/drivers/net/hinic/meson.build @@ -8,7 +8,6 @@ if is_windows endif subdir('base') -objs = [base_objs] sources = files( 'hinic_pmd_ethdev.c', -- 2.45.2