New upstream version 18.02
[deb_dpdk.git] / drivers / net / i40e / meson.build
1 # SPDX-License-Identifier: BSD-3-Clause
2 # Copyright(c) 2017 Intel Corporation
3
4 cflags += ['-DPF_DRIVER',
5         '-DVF_DRIVER',
6         '-DINTEGRATED_VF',
7         '-DX722_A0_SUPPORT']
8
9 subdir('base')
10 objs = [base_objs]
11
12 sources = files(
13         'i40e_ethdev.c',
14         'i40e_rxtx.c',
15         'i40e_ethdev_vf.c',
16         'i40e_pf.c',
17         'i40e_fdir.c',
18         'i40e_flow.c',
19         'i40e_tm.c',
20         'rte_pmd_i40e.c'
21         )
22
23 deps += ['hash']
24
25 if arch_subdir == 'x86'
26         dpdk_conf.set('RTE_LIBRTE_I40E_INC_VECTOR', 1)
27         sources += files('i40e_rxtx_vec_sse.c')
28
29         # compile AVX2 version if either:
30         # a. we have AVX supported in minimum instruction set baseline
31         # b. it's not minimum instruction set, but supported by compiler
32         if dpdk_conf.has('RTE_MACHINE_CPUFLAG_AVX2')
33                 sources += files('i40e_rxtx_vec_avx2.c')
34         elif cc.has_argument('-mavx2')
35                 i40e_avx2_lib = static_library('i40e_avx2_lib',
36                                 'i40e_rxtx_vec_avx2.c',
37                                 dependencies: [static_rte_ethdev,
38                                         static_rte_kvargs, static_rte_hash],
39                                 c_args: '-mavx2')
40                 objs += i40e_avx2_lib.extract_objects('i40e_rxtx_vec_avx2.c')
41         endif
42 endif
43
44 includes += include_directories('base')
45
46 install_headers('rte_pmd_i40e.h')