1 # SPDX-License-Identifier: BSD-3-Clause
2 # Copyright(c) 2017 Intel Corporation
4 test_sources = files('commands.c',
5 'packet_burst_generator.c',
14 'test_cmdline_cirbuf.c',
15 'test_cmdline_etheraddr.c',
16 'test_cmdline_ipaddr.c',
19 'test_cmdline_portlist.c',
20 'test_cmdline_string.c',
25 'test_cryptodev_asym.c',
26 'test_cryptodev_blockcipher.c',
30 'test_distributor_perf.c',
36 'test_event_crypto_adapter.c',
37 'test_event_eth_rx_adapter.c',
39 'test_event_eth_tx_adapter.c',
40 'test_event_timer_adapter.c',
42 'test_func_reentrancy.c',
43 'test_flow_classify.c',
45 'test_hash_functions.c',
46 'test_hash_multiwriter.c',
47 'test_hash_readwrite.c',
49 'test_hash_readwrite_lf.c',
53 'test_link_bonding.c',
54 'test_link_bonding_mode4.c',
68 'test_mempool_perf.c',
71 'test_mp_secondary.c',
75 'test_pmd_ring_perf.c',
77 'test_power_acpi_cpufreq.c',
78 'test_power_kvm_vm.c',
80 'test_reciprocal_division.c',
81 'test_reciprocal_division_perf.c',
88 'test_service_cores.c',
93 'test_table_combined.c',
94 'test_table_pipeline.c',
96 'test_table_tables.c',
101 'test_timer_racecond.c',
131 'byteorder_autotest',
136 'cryptodev_qat_autotest',
137 'cryptodev_aesni_mb_autotest',
138 'cryptodev_openssl_autotest',
139 'cryptodev_openssl_asym_autotest',
140 'cryptodev_aesni_gcm_autotest',
141 'cryptodev_null_autotest',
142 'cryptodev_sw_snow3g_autotest',
143 'cryptodev_sw_kasumi_autotest',
144 'cryptodev_sw_zuc_autotest',
145 'cryptodev_sw_armv8_autotest',
146 'cryptodev_sw_mvsam_autotest',
147 'cryptodev_dpaa2_sec_autotest',
148 'cryptodev_dpaa_sec_autotest',
149 'cryptodev_octeontx_autotest',
153 'distributor_autotest',
154 'distributor_perf_autotest',
155 'eal_flags_autotest',
160 'event_crypto_adapter_autotest',
161 'event_eth_rx_adapter_autotest',
162 'event_eth_rx_intr_adapter_autotest',
163 'event_ring_autotest',
164 'event_eth_tx_adapter_autotest',
165 'event_timer_adapter_autotest',
166 'eventdev_common_autotest',
167 'eventdev_octeontx_autotest',
168 'eventdev_sw_autotest',
169 'external_mem_autotest',
170 'func_reentrancy_autotest',
171 'flow_classify_autotest',
173 'hash_functions_autotest',
174 'hash_multiwriter_autotest',
175 'hash_perf_autotest',
176 'hash_readwrite_lf_autotest',
177 'interrupt_autotest',
180 'link_bonding_autotest',
181 'link_bonding_mode4_autotest',
184 'lpm6_perf_autotest',
190 'member_perf_autotest',
192 'memcpy_perf_autotest',
195 'mempool_perf_autotest',
198 'multiprocess_autotest',
199 'per_lcore_autotest',
201 'power_acpi_cpufreq_autotest',
203 'power_kvm_vm_autotest',
205 'reciprocal_division',
206 'reciprocal_division_perf',
212 'ring_perf_autotest',
214 'ring_pmd_perf_autotest',
224 'timer_perf__autotest',
225 'timer_racecond_autotest',
230 if dpdk_conf.has('RTE_LIBRTE_PDUMP')
233 if dpdk_conf.has('RTE_LIBRTE_I40E_PMD')
234 test_deps += 'pmd_i40e'
236 if dpdk_conf.has('RTE_LIBRTE_IXGBE_PMD')
237 test_deps += 'pmd_ixgbe'
239 if dpdk_conf.has('RTE_LIBRTE_BOND_PMD')
240 test_deps += 'pmd_bond'
242 if dpdk_conf.has('RTE_LIBRTE_RING_PMD')
243 test_deps += 'pmd_ring'
245 if dpdk_conf.has('RTE_LIBRTE_POWER')
248 if dpdk_conf.has('RTE_LIBRTE_KNI')
252 cflags = machine_args
253 if cc.has_argument('-Wno-format-truncation')
254 cflags += '-Wno-format-truncation'
257 # specify -D_GNU_SOURCE unconditionally
258 default_cflags += '-D_GNU_SOURCE'
261 compress_test_dep = dependency('zlib', required: false)
262 if compress_test_dep.found()
263 test_dep_objs += compress_test_dep
264 test_sources += 'test_compressdev.c'
265 test_deps += 'compressdev'
266 test_names += 'compressdev_autotest'
270 def_lib = get_option('default_library')
271 test_dep_objs += get_variable(def_lib + '_rte_' + d)
273 test_dep_objs += cc.find_library('execinfo', required: false)
276 if get_option('default_library') == 'static'
277 link_libs = dpdk_drivers
280 if get_option('tests')
281 dpdk_test = executable('dpdk-test',
283 link_whole: link_libs,
284 dependencies: test_dep_objs,
285 c_args: [cflags, '-DALLOW_EXPERIMENTAL_API'],
286 install_rpath: driver_install_path,
289 # some perf tests (eg: memcpy perf autotest)take very long
290 # to complete, so timeout to 10 minutes
291 timeout_seconds = 600
295 env : ['DPDK_TEST='+t],
296 timeout : timeout_seconds,