[2/2] lib: make graph optional
Checks
Commit Message
Allow disabling of the graph library in builds.
Signed-off-by: David Marchand <david.marchand@redhat.com>
---
app/test/meson.build | 12 +++++++-----
lib/meson.build | 1 +
2 files changed, 8 insertions(+), 5 deletions(-)
Comments
On Tue, Jun 20, 2023 at 2:17 AM David Marchand
<david.marchand@redhat.com> wrote:
>
> Allow disabling of the graph library in builds.
Good to make graph as optional.
I did not check the build, will examples/l3fwd-graph/ skip automatically ?
>
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---
> +if dpdk_conf.has('RTE_LIB_GRAPH')
Can devtools/test-meson-builds.sh updated to check build with
disabling all optional libs?
> + test_sources += 'test_graph.c'
> + fast_tests += [['graph_autotest', true, true]]
> + fast_tests += [['node_list_dump', true, true]]
> + test_sources += 'test_graph_perf.c'
> + perf_test_names += 'graph_perf_autotest'
On Tue, Jun 20, 2023 at 8:56 AM Jerin Jacob <jerinjacobk@gmail.com> wrote:
>
> On Tue, Jun 20, 2023 at 2:17 AM David Marchand
> <david.marchand@redhat.com> wrote:
> >
> > Allow disabling of the graph library in builds.
>
> Good to make graph as optional.
> I did not check the build, will examples/l3fwd-graph/ skip automatically ?
Yes.
Each example exposes its required dependencies.
examples/meson.build will skip any example with unmet requirements
unless the example was explicitly set in the -Dexamples= list of
examples to build.
See:
https://git.dpdk.org/dpdk/tree/examples/meson.build#n105
https://git.dpdk.org/dpdk/tree/examples/meson.build#n79
https://git.dpdk.org/dpdk/tree/examples/meson.build#n117
>
> >
> > Signed-off-by: David Marchand <david.marchand@redhat.com>
> > ---
> > +if dpdk_conf.has('RTE_LIB_GRAPH')
>
> Can devtools/test-meson-builds.sh updated to check build with
> disabling all optional libs?
I already tested this series with our script: we already have a "mini" target.
build build-mini cc skipABI $use_shared -Ddisable_libs=* \
-Denable_drivers=net/null
...
Message: Skipping example "l2fwd-jobstats"
Library rt found: YES
Message: Missing dependency "graph" for example "l3fwd-graph"
Message: Skipping example "l3fwd-graph"
Message: Missing dependency "power" for example "l3fwd-power"
Message: Skipping example "l3fwd-power"
...
On Mon, Jun 19, 2023 at 10:46:50PM +0200, David Marchand wrote:
> Allow disabling of the graph library in builds.
>
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---
> app/test/meson.build | 12 +++++++-----
> lib/meson.build | 1 +
> 2 files changed, 8 insertions(+), 5 deletions(-)
>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
On Tue, Jun 20, 2023 at 1:40 PM Bruce Richardson
<bruce.richardson@intel.com> wrote:
>
> On Mon, Jun 19, 2023 at 10:46:50PM +0200, David Marchand wrote:
> > Allow disabling of the graph library in builds.
> >
> > Signed-off-by: David Marchand <david.marchand@redhat.com>
> > ---
> > app/test/meson.build | 12 +++++++-----
> > lib/meson.build | 1 +
> > 2 files changed, 8 insertions(+), 5 deletions(-)
> >
> Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
20/06/2023 10:20, Jerin Jacob:
> On Tue, Jun 20, 2023 at 1:40 PM Bruce Richardson
> <bruce.richardson@intel.com> wrote:
> >
> > On Mon, Jun 19, 2023 at 10:46:50PM +0200, David Marchand wrote:
> > > Allow disabling of the graph library in builds.
> > >
> > > Signed-off-by: David Marchand <david.marchand@redhat.com>
> > > ---
> > > app/test/meson.build | 12 +++++++-----
> > > lib/meson.build | 1 +
> > > 2 files changed, 8 insertions(+), 5 deletions(-)
> > >
> > Acked-by: Bruce Richardson <bruce.richardson@intel.com>
>
> Acked-by: Jerin Jacob <jerinj@marvell.com>
Series applied, thanks.
@@ -61,8 +61,6 @@ test_sources = files(
'test_fib6.c',
'test_fib6_perf.c',
'test_func_reentrancy.c',
- 'test_graph.c',
- 'test_graph_perf.c',
'test_hash.c',
'test_hash_functions.c',
'test_hash_multiwriter.c',
@@ -250,8 +248,6 @@ fast_tests = [
['thash_autotest', true, true],
['threads_autotest', true, true],
['trace_autotest', true, true],
- ['graph_autotest', true, true],
- ['node_list_dump', true, true],
]
# Tests known to have issues or which don't belong in other tests lists.
@@ -300,7 +296,6 @@ perf_test_names = [
'trace_perf_autotest',
'ipsec_perf_autotest',
'thash_perf_autotest',
- 'graph_perf_autotest',
]
driver_test_names = [
@@ -366,6 +361,13 @@ if dpdk_conf.has('RTE_LIB_FLOW_CLASSIFY')
test_sources += 'test_flow_classify.c'
fast_tests += [['flow_classify_autotest', false, true]]
endif
+if dpdk_conf.has('RTE_LIB_GRAPH')
+ test_sources += 'test_graph.c'
+ fast_tests += [['graph_autotest', true, true]]
+ fast_tests += [['node_list_dump', true, true]]
+ test_sources += 'test_graph_perf.c'
+ perf_test_names += 'graph_perf_autotest'
+endif
if dpdk_conf.has('RTE_LIB_METRICS')
test_sources += ['test_metrics.c']
fast_tests += [['metrics_autotest', true, true]]
@@ -72,6 +72,7 @@ optional_libs = [
'cfgfile',
'flow_classify',
'gpudev',
+ 'graph',
'gro',
'gso',
'kni',