[v2] app/test-pmd: fix meson build failed when used latency stats lib
Checks
Commit Message
meson build cannot find the header rte_latencystats.h when build DPDK
first time or never installed DPDK lib after build via meson/ninja.
Because the corresponding header directory isn't included after enabled
RTE_LIBRTE_LATENCY_STATS flag.
Add the lib 'latencystats' to deps of meson.build of test-pmd, the
corresponding header files will be included automatically.
Fixes: 62d3216d6194 ("app/testpmd: add latency statistics calculation")
Signed-off-by: SteveX Yang <stevex.yang@intel.com>
---
v2:
removed long cflags and added 'latencystats' as a dependency of testpmd
---
app/test-pmd/meson.build | 3 +++
1 file changed, 3 insertions(+)
Comments
On 9/15/2020 3:08 AM, SteveX Yang wrote:
> meson build cannot find the header rte_latencystats.h when build DPDK
> first time or never installed DPDK lib after build via meson/ninja.
>
> Because the corresponding header directory isn't included after enabled
> RTE_LIBRTE_LATENCY_STATS flag.
>
> Add the lib 'latencystats' to deps of meson.build of test-pmd, the
> corresponding header files will be included automatically.
>
> Fixes: 62d3216d6194 ("app/testpmd: add latency statistics calculation")
>
> Signed-off-by: SteveX Yang <stevex.yang@intel.com>
> ---
> v2:
> removed long cflags and added 'latencystats' as a dependency of testpmd
The code has 'RTE_LIBRTE_LATENCY_STATS' which needs to be updated.
But I see Bruce is working on a more generic solution:
https://patches.dpdk.org/project/dpdk/list/?series=12283
I will mark this one as superseded and will wait the Bruce's set for fix.
@@ -25,6 +25,9 @@ sources = files('5tswap.c',
'util.c')
deps += ['ethdev', 'gro', 'gso', 'cmdline', 'metrics', 'meter', 'bus_pci']
+if dpdk_conf.has('RTE_LIBRTE_LATENCYSTATS')
+ deps += 'latencystats'
+endif
if dpdk_conf.has('RTE_LIBRTE_PDUMP')
deps += 'pdump'
endif