From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 6B0F7A0530; Wed, 12 Feb 2020 10:27:55 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 4E8B02BF4; Wed, 12 Feb 2020 10:27:55 +0100 (CET) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 4FF031F28 for ; Wed, 12 Feb 2020 10:27:53 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 12 Feb 2020 01:27:52 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,428,1574150400"; d="scan'208";a="237659084" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by orsmga006.jf.intel.com with ESMTP; 12 Feb 2020 01:27:50 -0800 Received: from fmsmsx155.amr.corp.intel.com (10.18.116.71) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 12 Feb 2020 01:26:55 -0800 Received: from shsmsx153.ccr.corp.intel.com (10.239.6.53) by FMSMSX155.amr.corp.intel.com (10.18.116.71) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 12 Feb 2020 01:26:55 -0800 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.5]) by SHSMSX153.ccr.corp.intel.com ([169.254.12.97]) with mapi id 14.03.0439.000; Wed, 12 Feb 2020 17:26:53 +0800 From: "Xu, Rosen" To: Thomas Monjalon , "dev@dpdk.org" CC: "Richardson, Bruce" , Matan Azrad , Shahaf Shuler , "Viacheslav Ovsiienko" , "Zhang, Tianfei" Thread-Topic: [PATCH v4 1/6] drivers: cleanup meson build variable Thread-Index: AQHV4Ug4Y3x9mF63xEKNyQ0HS1kYy6gXScAA Date: Wed, 12 Feb 2020 09:26:53 +0000 Message-ID: <0E78D399C70DA940A335608C6ED296D73AD4FC66@SHSMSX104.ccr.corp.intel.com> References: <20200116071656.1663967-1-thomas@monjalon.net> <20200212015944.3037000-1-thomas@monjalon.net> <20200212015944.3037000-2-thomas@monjalon.net> In-Reply-To: <20200212015944.3037000-2-thomas@monjalon.net> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiMjRmOWIzNjItZGYxOS00MDVhLWFhNmItY2U1ZGZlYTVjNDA3IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiUXd3NTFEVnpUbW1laHZDbUtYeVwvQ1hHUHZNeUcrdFFtYVI1aWVCZk5WSVRCeFFSc0tUcGFzbDNcLzNDYU5xXC9hSSJ9 x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v4 1/6] drivers: cleanup meson build variable X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Hi, I find some build error in patchwork. > -----Original Message----- > From: Thomas Monjalon > Sent: Wednesday, February 12, 2020 10:00 > To: dev@dpdk.org > Cc: Richardson, Bruce ; Matan Azrad > ; Shahaf Shuler ; > Viacheslav Ovsiienko ; Xu, Rosen > ; Zhang, Tianfei > Subject: [PATCH v4 1/6] drivers: cleanup meson build variable >=20 > The variable build is already initialized as true in drivers/meson.build. > Duplicate initializations can be removed from mlx. >=20 > When the variable build is set to false, it is easier to call > subdir_done() than branch the rest of the code on build condition. >=20 > Suggested-by: Bruce Richardson > Signed-off-by: Thomas Monjalon > --- > drivers/common/mlx5/meson.build | 293 ++++++++++++++++---------------- > drivers/net/ipn3ke/meson.build | 17 +- > drivers/net/mlx4/meson.build | 131 +++++++------- > drivers/raw/ifpga/meson.build | 23 ++- > 4 files changed, 230 insertions(+), 234 deletions(-) >=20 > diff --git a/drivers/common/mlx5/meson.build > b/drivers/common/mlx5/meson.build index 2b704107cd..be57558267 100644 > --- a/drivers/common/mlx5/meson.build > +++ b/drivers/common/mlx5/meson.build > @@ -6,7 +6,6 @@ if not is_linux > reason =3D 'only supported on Linux' > subdir_done() > endif > -build =3D true >=20 > pmd_dlopen =3D (get_option('ibverbs_link') =3D=3D 'dlopen') LIB_GLUE_BA= SE =3D > 'librte_pmd_mlx5_glue.so' > @@ -32,158 +31,158 @@ foreach libname:libnames > else > build =3D false > reason =3D 'missing dependency, "' + libname + '"' > + subdir_done() > endif > endforeach >=20 > -if build > - allow_experimental_apis =3D true > - deps +=3D ['hash', 'pci', 'net', 'eal', 'kvargs'] > - ext_deps +=3D libs > - sources =3D files( > - 'mlx5_devx_cmds.c', > - 'mlx5_common.c', > - 'mlx5_nl.c', > - ) > - if not pmd_dlopen > - sources +=3D files('mlx5_glue.c') > - endif > - cflags_options =3D [ > - '-std=3Dc11', > - '-Wno-strict-prototypes', > - '-D_BSD_SOURCE', > - '-D_DEFAULT_SOURCE', > - '-D_XOPEN_SOURCE=3D600' > - ] > - foreach option:cflags_options > - if cc.has_argument(option) > - cflags +=3D option > - endif > - endforeach > - if get_option('buildtype').contains('debug') > - cflags +=3D [ '-pedantic', '-DPEDANTIC' ] > - else > - cflags +=3D [ '-UPEDANTIC' ] > +allow_experimental_apis =3D true > +deps +=3D ['hash', 'pci', 'net', 'eal', 'kvargs'] ext_deps +=3D libs > +sources =3D files( > + 'mlx5_devx_cmds.c', > + 'mlx5_common.c', > + 'mlx5_nl.c', > +) > +if not pmd_dlopen > + sources +=3D files('mlx5_glue.c') > +endif > +cflags_options =3D [ > + '-std=3Dc11', > + '-Wno-strict-prototypes', > + '-D_BSD_SOURCE', > + '-D_DEFAULT_SOURCE', > + '-D_XOPEN_SOURCE=3D600' > +] > +foreach option:cflags_options > + if cc.has_argument(option) > + cflags +=3D option > endif > - # To maintain the compatibility with the make build system > - # mlx5_autoconf.h file is still generated. > - # input array for meson member search: > - # [ "MACRO to define if found", "header for the search", > - # "symbol to search", "struct member to search" ] > - has_member_args =3D [ > - [ 'HAVE_IBV_MLX5_MOD_SWP', 'infiniband/mlx5dv.h', > - 'struct mlx5dv_sw_parsing_caps', 'sw_parsing_offloads' ], > - [ 'HAVE_IBV_DEVICE_COUNTERS_SET_V42', > 'infiniband/verbs.h', > - 'struct ibv_counter_set_init_attr', 'counter_set_id' ], > - [ 'HAVE_IBV_DEVICE_COUNTERS_SET_V45', > 'infiniband/verbs.h', > - 'struct ibv_counters_init_attr', 'comp_mask' ], > - ] > - # input array for meson symbol search: > - # [ "MACRO to define if found", "header for the search", > - # "symbol to search" ] > - has_sym_args =3D [ > - [ 'HAVE_IBV_DEVICE_STRIDING_RQ_SUPPORT', > 'infiniband/mlx5dv.h', > - 'MLX5DV_CQE_RES_FORMAT_CSUM_STRIDX' ], > - [ 'HAVE_IBV_DEVICE_TUNNEL_SUPPORT', > 'infiniband/mlx5dv.h', > - 'MLX5DV_CONTEXT_MASK_TUNNEL_OFFLOADS' ], > - [ 'HAVE_IBV_MLX5_MOD_MPW', 'infiniband/mlx5dv.h', > - 'MLX5DV_CONTEXT_FLAGS_MPW_ALLOWED' ], > - [ 'HAVE_IBV_MLX5_MOD_CQE_128B_COMP', > 'infiniband/mlx5dv.h', > - 'MLX5DV_CONTEXT_FLAGS_CQE_128B_COMP' ], > - [ 'HAVE_IBV_MLX5_MOD_CQE_128B_PAD', > 'infiniband/mlx5dv.h', > - 'MLX5DV_CQ_INIT_ATTR_FLAGS_CQE_PAD' ], > - [ 'HAVE_IBV_FLOW_DV_SUPPORT', 'infiniband/mlx5dv.h', > - 'mlx5dv_create_flow_action_packet_reformat' ], > - [ 'HAVE_IBV_DEVICE_MPLS_SUPPORT', 'infiniband/verbs.h', > - 'IBV_FLOW_SPEC_MPLS' ], > - [ 'HAVE_IBV_WQ_FLAGS_PCI_WRITE_END_PADDING', > 'infiniband/verbs.h', > - 'IBV_WQ_FLAGS_PCI_WRITE_END_PADDING' ], > - [ 'HAVE_IBV_WQ_FLAG_RX_END_PADDING', > 'infiniband/verbs.h', > - 'IBV_WQ_FLAG_RX_END_PADDING' ], > - [ 'HAVE_MLX5DV_DR_DEVX_PORT', 'infiniband/mlx5dv.h', > - 'mlx5dv_query_devx_port' ], > - [ 'HAVE_IBV_DEVX_OBJ', 'infiniband/mlx5dv.h', > - 'mlx5dv_devx_obj_create' ], > - [ 'HAVE_IBV_FLOW_DEVX_COUNTERS', 'infiniband/mlx5dv.h', > - 'MLX5DV_FLOW_ACTION_COUNTERS_DEVX' ], > - [ 'HAVE_IBV_DEVX_ASYNC', 'infiniband/mlx5dv.h', > - 'mlx5dv_devx_obj_query_async' ], > - [ 'HAVE_MLX5DV_DR_ACTION_DEST_DEVX_TIR', > 'infiniband/mlx5dv.h', > - 'mlx5dv_dr_action_create_dest_devx_tir' ], > - [ 'HAVE_IBV_DEVX_EVENT', 'infiniband/mlx5dv.h', > - 'mlx5dv_devx_get_event' ], > - [ 'HAVE_MLX5_DR_CREATE_ACTION_FLOW_METER', > 'infiniband/mlx5dv.h', > - 'mlx5dv_dr_action_create_flow_meter' ], > - [ 'HAVE_MLX5DV_MMAP_GET_NC_PAGES_CMD', > 'infiniband/mlx5dv.h', > - 'MLX5_MMAP_GET_NC_PAGES_CMD' ], > - [ 'HAVE_MLX5DV_DR', 'infiniband/mlx5dv.h', > - 'MLX5DV_DR_DOMAIN_TYPE_NIC_RX' ], > - [ 'HAVE_MLX5DV_DR_ESWITCH', 'infiniband/mlx5dv.h', > - 'MLX5DV_DR_DOMAIN_TYPE_FDB' ], > - [ 'HAVE_MLX5DV_DR_VLAN', 'infiniband/mlx5dv.h', > - 'mlx5dv_dr_action_create_push_vlan' ], > - [ 'HAVE_IBV_VAR', 'infiniband/mlx5dv.h', 'mlx5dv_alloc_var' ], > - [ 'HAVE_SUPPORTED_40000baseKR4_Full', 'linux/ethtool.h', > - 'SUPPORTED_40000baseKR4_Full' ], > - [ 'HAVE_SUPPORTED_40000baseCR4_Full', 'linux/ethtool.h', > - 'SUPPORTED_40000baseCR4_Full' ], > - [ 'HAVE_SUPPORTED_40000baseSR4_Full', 'linux/ethtool.h', > - 'SUPPORTED_40000baseSR4_Full' ], > - [ 'HAVE_SUPPORTED_40000baseLR4_Full', 'linux/ethtool.h', > - 'SUPPORTED_40000baseLR4_Full' ], > - [ 'HAVE_SUPPORTED_56000baseKR4_Full', 'linux/ethtool.h', > - 'SUPPORTED_56000baseKR4_Full' ], > - [ 'HAVE_SUPPORTED_56000baseCR4_Full', 'linux/ethtool.h', > - 'SUPPORTED_56000baseCR4_Full' ], > - [ 'HAVE_SUPPORTED_56000baseSR4_Full', 'linux/ethtool.h', > - 'SUPPORTED_56000baseSR4_Full' ], > - [ 'HAVE_SUPPORTED_56000baseLR4_Full', 'linux/ethtool.h', > - 'SUPPORTED_56000baseLR4_Full' ], > - [ 'HAVE_ETHTOOL_LINK_MODE_25G', 'linux/ethtool.h', > - 'ETHTOOL_LINK_MODE_25000baseCR_Full_BIT' ], > - [ 'HAVE_ETHTOOL_LINK_MODE_50G', 'linux/ethtool.h', > - 'ETHTOOL_LINK_MODE_50000baseCR2_Full_BIT' ], > - [ 'HAVE_ETHTOOL_LINK_MODE_100G', 'linux/ethtool.h', > - 'ETHTOOL_LINK_MODE_100000baseKR4_Full_BIT' ], > - [ 'HAVE_IFLA_NUM_VF', 'linux/if_link.h', > - 'IFLA_NUM_VF' ], > - [ 'HAVE_IFLA_EXT_MASK', 'linux/if_link.h', > - 'IFLA_EXT_MASK' ], > - [ 'HAVE_IFLA_PHYS_SWITCH_ID', 'linux/if_link.h', > - 'IFLA_PHYS_SWITCH_ID' ], > - [ 'HAVE_IFLA_PHYS_PORT_NAME', 'linux/if_link.h', > - 'IFLA_PHYS_PORT_NAME' ], > - [ 'HAVE_RDMA_NL_NLDEV', 'rdma/rdma_netlink.h', > - 'RDMA_NL_NLDEV' ], > - [ 'HAVE_RDMA_NLDEV_CMD_GET', 'rdma/rdma_netlink.h', > - 'RDMA_NLDEV_CMD_GET' ], > - [ 'HAVE_RDMA_NLDEV_CMD_PORT_GET', > 'rdma/rdma_netlink.h', > - 'RDMA_NLDEV_CMD_PORT_GET' ], > - [ 'HAVE_RDMA_NLDEV_ATTR_DEV_INDEX', > 'rdma/rdma_netlink.h', > - 'RDMA_NLDEV_ATTR_DEV_INDEX' ], > - [ 'HAVE_RDMA_NLDEV_ATTR_DEV_NAME', > 'rdma/rdma_netlink.h', > - 'RDMA_NLDEV_ATTR_DEV_NAME' ], > - [ 'HAVE_RDMA_NLDEV_ATTR_PORT_INDEX', > 'rdma/rdma_netlink.h', > - 'RDMA_NLDEV_ATTR_PORT_INDEX' ], > - [ 'HAVE_RDMA_NLDEV_ATTR_NDEV_INDEX', > 'rdma/rdma_netlink.h', > - 'RDMA_NLDEV_ATTR_NDEV_INDEX' ], > - [ 'HAVE_MLX5_DR_FLOW_DUMP', 'infiniband/mlx5dv.h', > - 'mlx5dv_dump_dr_domain'], > - [ 'HAVE_DEVLINK', 'linux/devlink.h', > 'DEVLINK_GENL_NAME' ], > - ] > - config =3D configuration_data() > - foreach arg:has_sym_args > - config.set(arg[0], cc.has_header_symbol(arg[1], arg[2], > - dependencies: libs)) > - endforeach > - foreach arg:has_member_args > - file_prefix =3D '#include <' + arg[1] + '>' > - config.set(arg[0], cc.has_member(arg[2], arg[3], > - prefix : file_prefix, dependencies: libs)) > - endforeach > - configure_file(output : 'mlx5_autoconf.h', configuration : config) > +endforeach > +if get_option('buildtype').contains('debug') > + cflags +=3D [ '-pedantic', '-DPEDANTIC' ] else > + cflags +=3D [ '-UPEDANTIC' ] > endif > +# To maintain the compatibility with the make build system # > +mlx5_autoconf.h file is still generated. > +# input array for meson member search: > +# [ "MACRO to define if found", "header for the search", > +# "symbol to search", "struct member to search" ] > +has_member_args =3D [ > + [ 'HAVE_IBV_MLX5_MOD_SWP', 'infiniband/mlx5dv.h', > + 'struct mlx5dv_sw_parsing_caps', 'sw_parsing_offloads' ], > + [ 'HAVE_IBV_DEVICE_COUNTERS_SET_V42', 'infiniband/verbs.h', > + 'struct ibv_counter_set_init_attr', 'counter_set_id' ], > + [ 'HAVE_IBV_DEVICE_COUNTERS_SET_V45', 'infiniband/verbs.h', > + 'struct ibv_counters_init_attr', 'comp_mask' ], ] # input array for > +meson symbol search: > +# [ "MACRO to define if found", "header for the search", > +# "symbol to search" ] > +has_sym_args =3D [ > + [ 'HAVE_IBV_DEVICE_STRIDING_RQ_SUPPORT', > 'infiniband/mlx5dv.h', > + 'MLX5DV_CQE_RES_FORMAT_CSUM_STRIDX' ], > + [ 'HAVE_IBV_DEVICE_TUNNEL_SUPPORT', 'infiniband/mlx5dv.h', > + 'MLX5DV_CONTEXT_MASK_TUNNEL_OFFLOADS' ], > + [ 'HAVE_IBV_MLX5_MOD_MPW', 'infiniband/mlx5dv.h', > + 'MLX5DV_CONTEXT_FLAGS_MPW_ALLOWED' ], > + [ 'HAVE_IBV_MLX5_MOD_CQE_128B_COMP', 'infiniband/mlx5dv.h', > + 'MLX5DV_CONTEXT_FLAGS_CQE_128B_COMP' ], > + [ 'HAVE_IBV_MLX5_MOD_CQE_128B_PAD', 'infiniband/mlx5dv.h', > + 'MLX5DV_CQ_INIT_ATTR_FLAGS_CQE_PAD' ], > + [ 'HAVE_IBV_FLOW_DV_SUPPORT', 'infiniband/mlx5dv.h', > + 'mlx5dv_create_flow_action_packet_reformat' ], > + [ 'HAVE_IBV_DEVICE_MPLS_SUPPORT', 'infiniband/verbs.h', > + 'IBV_FLOW_SPEC_MPLS' ], > + [ 'HAVE_IBV_WQ_FLAGS_PCI_WRITE_END_PADDING', > 'infiniband/verbs.h', > + 'IBV_WQ_FLAGS_PCI_WRITE_END_PADDING' ], > + [ 'HAVE_IBV_WQ_FLAG_RX_END_PADDING', 'infiniband/verbs.h', > + 'IBV_WQ_FLAG_RX_END_PADDING' ], > + [ 'HAVE_MLX5DV_DR_DEVX_PORT', 'infiniband/mlx5dv.h', > + 'mlx5dv_query_devx_port' ], > + [ 'HAVE_IBV_DEVX_OBJ', 'infiniband/mlx5dv.h', > + 'mlx5dv_devx_obj_create' ], > + [ 'HAVE_IBV_FLOW_DEVX_COUNTERS', 'infiniband/mlx5dv.h', > + 'MLX5DV_FLOW_ACTION_COUNTERS_DEVX' ], > + [ 'HAVE_IBV_DEVX_ASYNC', 'infiniband/mlx5dv.h', > + 'mlx5dv_devx_obj_query_async' ], > + [ 'HAVE_MLX5DV_DR_ACTION_DEST_DEVX_TIR', > 'infiniband/mlx5dv.h', > + 'mlx5dv_dr_action_create_dest_devx_tir' ], > + [ 'HAVE_IBV_DEVX_EVENT', 'infiniband/mlx5dv.h', > + 'mlx5dv_devx_get_event' ], > + [ 'HAVE_MLX5_DR_CREATE_ACTION_FLOW_METER', > 'infiniband/mlx5dv.h', > + 'mlx5dv_dr_action_create_flow_meter' ], > + [ 'HAVE_MLX5DV_MMAP_GET_NC_PAGES_CMD', > 'infiniband/mlx5dv.h', > + 'MLX5_MMAP_GET_NC_PAGES_CMD' ], > + [ 'HAVE_MLX5DV_DR', 'infiniband/mlx5dv.h', > + 'MLX5DV_DR_DOMAIN_TYPE_NIC_RX' ], > + [ 'HAVE_MLX5DV_DR_ESWITCH', 'infiniband/mlx5dv.h', > + 'MLX5DV_DR_DOMAIN_TYPE_FDB' ], > + [ 'HAVE_MLX5DV_DR_VLAN', 'infiniband/mlx5dv.h', > + 'mlx5dv_dr_action_create_push_vlan' ], > + [ 'HAVE_IBV_VAR', 'infiniband/mlx5dv.h', 'mlx5dv_alloc_var' ], > + [ 'HAVE_SUPPORTED_40000baseKR4_Full', 'linux/ethtool.h', > + 'SUPPORTED_40000baseKR4_Full' ], > + [ 'HAVE_SUPPORTED_40000baseCR4_Full', 'linux/ethtool.h', > + 'SUPPORTED_40000baseCR4_Full' ], > + [ 'HAVE_SUPPORTED_40000baseSR4_Full', 'linux/ethtool.h', > + 'SUPPORTED_40000baseSR4_Full' ], > + [ 'HAVE_SUPPORTED_40000baseLR4_Full', 'linux/ethtool.h', > + 'SUPPORTED_40000baseLR4_Full' ], > + [ 'HAVE_SUPPORTED_56000baseKR4_Full', 'linux/ethtool.h', > + 'SUPPORTED_56000baseKR4_Full' ], > + [ 'HAVE_SUPPORTED_56000baseCR4_Full', 'linux/ethtool.h', > + 'SUPPORTED_56000baseCR4_Full' ], > + [ 'HAVE_SUPPORTED_56000baseSR4_Full', 'linux/ethtool.h', > + 'SUPPORTED_56000baseSR4_Full' ], > + [ 'HAVE_SUPPORTED_56000baseLR4_Full', 'linux/ethtool.h', > + 'SUPPORTED_56000baseLR4_Full' ], > + [ 'HAVE_ETHTOOL_LINK_MODE_25G', 'linux/ethtool.h', > + 'ETHTOOL_LINK_MODE_25000baseCR_Full_BIT' ], > + [ 'HAVE_ETHTOOL_LINK_MODE_50G', 'linux/ethtool.h', > + 'ETHTOOL_LINK_MODE_50000baseCR2_Full_BIT' ], > + [ 'HAVE_ETHTOOL_LINK_MODE_100G', 'linux/ethtool.h', > + 'ETHTOOL_LINK_MODE_100000baseKR4_Full_BIT' ], > + [ 'HAVE_IFLA_NUM_VF', 'linux/if_link.h', > + 'IFLA_NUM_VF' ], > + [ 'HAVE_IFLA_EXT_MASK', 'linux/if_link.h', > + 'IFLA_EXT_MASK' ], > + [ 'HAVE_IFLA_PHYS_SWITCH_ID', 'linux/if_link.h', > + 'IFLA_PHYS_SWITCH_ID' ], > + [ 'HAVE_IFLA_PHYS_PORT_NAME', 'linux/if_link.h', > + 'IFLA_PHYS_PORT_NAME' ], > + [ 'HAVE_RDMA_NL_NLDEV', 'rdma/rdma_netlink.h', > + 'RDMA_NL_NLDEV' ], > + [ 'HAVE_RDMA_NLDEV_CMD_GET', 'rdma/rdma_netlink.h', > + 'RDMA_NLDEV_CMD_GET' ], > + [ 'HAVE_RDMA_NLDEV_CMD_PORT_GET', 'rdma/rdma_netlink.h', > + 'RDMA_NLDEV_CMD_PORT_GET' ], > + [ 'HAVE_RDMA_NLDEV_ATTR_DEV_INDEX', 'rdma/rdma_netlink.h', > + 'RDMA_NLDEV_ATTR_DEV_INDEX' ], > + [ 'HAVE_RDMA_NLDEV_ATTR_DEV_NAME', 'rdma/rdma_netlink.h', > + 'RDMA_NLDEV_ATTR_DEV_NAME' ], > + [ 'HAVE_RDMA_NLDEV_ATTR_PORT_INDEX', 'rdma/rdma_netlink.h', > + 'RDMA_NLDEV_ATTR_PORT_INDEX' ], > + [ 'HAVE_RDMA_NLDEV_ATTR_NDEV_INDEX', 'rdma/rdma_netlink.h', > + 'RDMA_NLDEV_ATTR_NDEV_INDEX' ], > + [ 'HAVE_MLX5_DR_FLOW_DUMP', 'infiniband/mlx5dv.h', > + 'mlx5dv_dump_dr_domain'], > + [ 'HAVE_DEVLINK', 'linux/devlink.h', 'DEVLINK_GENL_NAME' ], ] > config =3D > +configuration_data() foreach arg:has_sym_args > + config.set(arg[0], cc.has_header_symbol(arg[1], arg[2], > + dependencies: libs)) > +endforeach > +foreach arg:has_member_args > + file_prefix =3D '#include <' + arg[1] + '>' > + config.set(arg[0], cc.has_member(arg[2], arg[3], > + prefix : file_prefix, dependencies: libs)) endforeach > +configure_file(output : 'mlx5_autoconf.h', configuration : config) > + > # Build Glue Library > -if pmd_dlopen and build > +if pmd_dlopen > dlopen_name =3D 'mlx5_glue' > dlopen_lib_name =3D driver_name_fmt.format(dlopen_name) > dlopen_so_version =3D LIB_GLUE_VERSION > diff --git a/drivers/net/ipn3ke/meson.build > b/drivers/net/ipn3ke/meson.build index bfec592aba..f19083af15 100644 > --- a/drivers/net/ipn3ke/meson.build > +++ b/drivers/net/ipn3ke/meson.build > @@ -16,16 +16,15 @@ endif > if not dep.found() > build =3D false > reason =3D 'missing dependency, "libfdt"' > + subdir_done() > endif >=20 > -if build > - allow_experimental_apis =3D true > +allow_experimental_apis =3D true >=20 > - includes +=3D include_directories('../../raw/ifpga') > +includes +=3D include_directories('../../raw/ifpga') >=20 > - sources +=3D files('ipn3ke_ethdev.c', > - 'ipn3ke_representor.c', > - 'ipn3ke_tm.c', > - 'ipn3ke_flow.c') > - deps +=3D ['bus_ifpga', 'ethdev', 'sched'] > -endif > +sources +=3D files('ipn3ke_ethdev.c', > + 'ipn3ke_representor.c', > + 'ipn3ke_tm.c', > + 'ipn3ke_flow.c') > +deps +=3D ['bus_ifpga', 'ethdev', 'sched'] > diff --git a/drivers/net/mlx4/meson.build b/drivers/net/mlx4/meson.build > index 0260c5dc59..6d2397b3cc 100644 > --- a/drivers/net/mlx4/meson.build > +++ b/drivers/net/mlx4/meson.build > @@ -7,7 +7,6 @@ if not is_linux > reason =3D 'only supported on Linux' > subdir_done() > endif > -build =3D true >=20 > pmd_dlopen =3D (get_option('ibverbs_link') =3D=3D 'dlopen') LIB_GLUE_BA= SE =3D > 'librte_pmd_mlx4_glue.so' > @@ -33,77 +32,77 @@ foreach libname:libnames > else > build =3D false > reason =3D 'missing dependency, "' + libname + '"' > + subdir_done() > endif > endforeach >=20 > -if build > - allow_experimental_apis =3D true > - ext_deps +=3D libs > - sources =3D files( > - 'mlx4.c', > - 'mlx4_ethdev.c', > - 'mlx4_flow.c', > - 'mlx4_intr.c', > - 'mlx4_mp.c', > - 'mlx4_mr.c', > - 'mlx4_rxq.c', > - 'mlx4_rxtx.c', > - 'mlx4_txq.c', > - 'mlx4_utils.c', > - ) > - if not pmd_dlopen > - sources +=3D files('mlx4_glue.c') > - endif > - cflags_options =3D [ > - '-std=3Dc11', > - '-Wno-strict-prototypes', > - '-D_BSD_SOURCE', > - '-D_DEFAULT_SOURCE', > - '-D_XOPEN_SOURCE=3D600' > - ] > - foreach option:cflags_options > - if cc.has_argument(option) > - cflags +=3D option > - endif > - endforeach > - if get_option('buildtype').contains('debug') > - cflags +=3D [ '-pedantic', '-DPEDANTIC' ] > - else > - cflags +=3D [ '-UPEDANTIC' ] > +allow_experimental_apis =3D true > +ext_deps +=3D libs > +sources =3D files( > + 'mlx4.c', > + 'mlx4_ethdev.c', > + 'mlx4_flow.c', > + 'mlx4_intr.c', > + 'mlx4_mp.c', > + 'mlx4_mr.c', > + 'mlx4_rxq.c', > + 'mlx4_rxtx.c', > + 'mlx4_txq.c', > + 'mlx4_utils.c', > +) > +if not pmd_dlopen > + sources +=3D files('mlx4_glue.c') > +endif > +cflags_options =3D [ > + '-std=3Dc11', > + '-Wno-strict-prototypes', > + '-D_BSD_SOURCE', > + '-D_DEFAULT_SOURCE', > + '-D_XOPEN_SOURCE=3D600' > +] > +foreach option:cflags_options > + if cc.has_argument(option) > + cflags +=3D option > endif > - # To maintain the compatibility with the make build system > - # mlx4_autoconf.h file is still generated. > - # input array for meson member search: > - # [ "MACRO to define if found", "header for the search", > - # "symbol to search", "struct member to search" ] > - # > - has_member_args =3D [ > - [ 'HAVE_IBV_MLX4_WQE_LSO_SEG', 'infiniband/mlx4dv.h', > - 'struct mlx4_wqe_lso_seg', 'mss_hdr_size' ], > - ] > - # input array for meson symbol search: > - # [ "MACRO to define if found", "header for the search", > - # "symbol to search" ] > - has_sym_args =3D [ > - [ 'HAVE_IBV_MLX4_BUF_ALLOCATORS', > 'infiniband/mlx4dv.h', > - 'MLX4DV_SET_CTX_ATTR_BUF_ALLOCATORS' ], > - [ 'HAVE_IBV_MLX4_UAR_MMAP_OFFSET', > 'infiniband/mlx4dv.h', > - 'MLX4DV_QP_MASK_UAR_MMAP_OFFSET' ], > - ] > - config =3D configuration_data() > - foreach arg:has_sym_args > - config.set(arg[0], cc.has_header_symbol(arg[1], arg[2], > - dependencies: libs)) > - endforeach > - foreach arg:has_member_args > - file_prefix =3D '#include <' + arg[1] + '>' > - config.set(arg[0], cc.has_member(arg[2], arg[3], > - prefix: file_prefix, dependencies: libs)) > - endforeach > - configure_file(output : 'mlx4_autoconf.h', configuration : config) > +endforeach > +if get_option('buildtype').contains('debug') > + cflags +=3D [ '-pedantic', '-DPEDANTIC' ] else > + cflags +=3D [ '-UPEDANTIC' ] > endif > +# To maintain the compatibility with the make build system # > +mlx4_autoconf.h file is still generated. > +# input array for meson member search: > +# [ "MACRO to define if found", "header for the search", > +# "symbol to search", "struct member to search" ] > +# > +has_member_args =3D [ > + [ 'HAVE_IBV_MLX4_WQE_LSO_SEG', 'infiniband/mlx4dv.h', > + 'struct mlx4_wqe_lso_seg', 'mss_hdr_size' ], ] # input array for > meson > +symbol search: > +# [ "MACRO to define if found", "header for the search", > +# "symbol to search" ] > +has_sym_args =3D [ > + [ 'HAVE_IBV_MLX4_BUF_ALLOCATORS', 'infiniband/mlx4dv.h', > + 'MLX4DV_SET_CTX_ATTR_BUF_ALLOCATORS' ], > + [ 'HAVE_IBV_MLX4_UAR_MMAP_OFFSET', 'infiniband/mlx4dv.h', > + 'MLX4DV_QP_MASK_UAR_MMAP_OFFSET' ], > +] > +config =3D configuration_data() > +foreach arg:has_sym_args > + config.set(arg[0], cc.has_header_symbol(arg[1], arg[2], > + dependencies: libs)) > +endforeach > +foreach arg:has_member_args > + file_prefix =3D '#include <' + arg[1] + '>' > + config.set(arg[0], cc.has_member(arg[2], arg[3], > + prefix: file_prefix, dependencies: libs)) endforeach > +configure_file(output : 'mlx4_autoconf.h', configuration : config) > + > # Build Glue Library > -if pmd_dlopen and build > +if pmd_dlopen > dlopen_name =3D 'mlx4_glue' > dlopen_lib_name =3D driver_name_fmt.format(dlopen_name) > dlopen_so_version =3D LIB_GLUE_VERSION > diff --git a/drivers/raw/ifpga/meson.build b/drivers/raw/ifpga/meson.buil= d > index d4027068d6..e2a4b8cccb 100644 > --- a/drivers/raw/ifpga/meson.build > +++ b/drivers/raw/ifpga/meson.build > @@ -8,21 +8,20 @@ endif > if not dep.found() > build =3D false > reason =3D 'missing dependency, "libfdt"' > + subdir_done() > endif >=20 > -if build > - subdir('base') > - objs =3D [base_objs] > +subdir('base') > +objs =3D [base_objs] >=20 > - deps +=3D ['ethdev', 'rawdev', 'pci', 'bus_pci', 'kvargs', > - 'bus_vdev', 'bus_ifpga', 'net', 'pmd_i40e', 'pmd_ipn3ke'] > - ext_deps +=3D dep > +deps +=3D ['ethdev', 'rawdev', 'pci', 'bus_pci', 'kvargs', > + 'bus_vdev', 'bus_ifpga', 'net', 'pmd_i40e', 'pmd_ipn3ke'] ext_deps +=3D > +dep >=20 > - sources =3D files('ifpga_rawdev.c') > +sources =3D files('ifpga_rawdev.c') >=20 > - includes +=3D include_directories('base') > - includes +=3D include_directories('../../net/ipn3ke') > - includes +=3D include_directories('../../net/i40e') > +includes +=3D include_directories('base') includes +=3D > +include_directories('../../net/ipn3ke') > +includes +=3D include_directories('../../net/i40e') >=20 > - allow_experimental_apis =3D true > -endif > +allow_experimental_apis =3D true > -- > 2.25.0