[v4,5/9] build: make bpf library optional

Message ID 20230623150708.2203918-6-bruce.richardson@intel.com (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series expand list of optional libraries |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Bruce Richardson June 23, 2023, 3:07 p.m. UTC
  This library is not essential for most DPDK uses, so mark it as optional
in the build config.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
---
 app/test/meson.build | 10 +++++++---
 lib/meson.build      |  1 +
 2 files changed, 8 insertions(+), 3 deletions(-)
  

Comments

Konstantin Ananyev June 27, 2023, 9:26 a.m. UTC | #1
23/06/2023 16:07, Bruce Richardson пишет:
> This library is not essential for most DPDK uses, so mark it as optional
> in the build config.
> 
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> Acked-by: Morten Brørup <mb@smartsharesystems.com>
> ---
>   app/test/meson.build | 10 +++++++---
>   lib/meson.build      |  1 +
>   2 files changed, 8 insertions(+), 3 deletions(-)
> 
> diff --git a/app/test/meson.build b/app/test/meson.build
> index 0f9992c0b2..0ef0bf690f 100644
> --- a/app/test/meson.build
> +++ b/app/test/meson.build
> @@ -15,7 +15,6 @@ test_sources = files(
>           'test_barrier.c',
>           'test_bitops.c',
>           'test_bitmap.c',
> -        'test_bpf.c',
>           'test_byteorder.c',
>           'test_cksum.c',
>           'test_cksum_perf.c',
> @@ -150,8 +149,6 @@ fast_tests = [
>           ['acl_autotest', true, true],
>           ['atomic_autotest', false, true],
>           ['bitmap_autotest', true, true],
> -        ['bpf_autotest', true, true],
> -        ['bpf_convert_autotest', true, true],
>           ['bitops_autotest', true, true],
>           ['byteorder_autotest', true, true],
>           ['cksum_autotest', true, true],
> @@ -341,6 +338,13 @@ if dpdk_conf.has('RTE_EVENT_SKELETON')
>       test_deps += 'event_skeleton'
>   endif
>   
> +if dpdk_conf.has('RTE_LIB_BPF')
> +    test_sources += 'test_bpf.c'
> +    fast_tests += [
> +        ['bpf_autotest', true, true],
> +        ['bpf_convert_autotest', true, true],
> +    ]
> +endif
>   if dpdk_conf.has('RTE_LIB_DMADEV')
>       test_sources += ['test_dmadev.c', 'test_dmadev_api.c']
>       driver_test_names += 'dmadev_autotest'
> diff --git a/lib/meson.build b/lib/meson.build
> index de7069a078..47c18ca3b0 100644
> --- a/lib/meson.build
> +++ b/lib/meson.build
> @@ -70,6 +70,7 @@ libraries = [
>   optional_libs = [
>           'bbdev',
>           'bitratestats',
> +        'bpf',
>           'cfgfile',
>           'compressdev',
>           'dmadev',

Acked-by: Konstantin Ananyev <konstantin.v.ananyev@yandex.ru>
  

Patch

diff --git a/app/test/meson.build b/app/test/meson.build
index 0f9992c0b2..0ef0bf690f 100644
--- a/app/test/meson.build
+++ b/app/test/meson.build
@@ -15,7 +15,6 @@  test_sources = files(
         'test_barrier.c',
         'test_bitops.c',
         'test_bitmap.c',
-        'test_bpf.c',
         'test_byteorder.c',
         'test_cksum.c',
         'test_cksum_perf.c',
@@ -150,8 +149,6 @@  fast_tests = [
         ['acl_autotest', true, true],
         ['atomic_autotest', false, true],
         ['bitmap_autotest', true, true],
-        ['bpf_autotest', true, true],
-        ['bpf_convert_autotest', true, true],
         ['bitops_autotest', true, true],
         ['byteorder_autotest', true, true],
         ['cksum_autotest', true, true],
@@ -341,6 +338,13 @@  if dpdk_conf.has('RTE_EVENT_SKELETON')
     test_deps += 'event_skeleton'
 endif
 
+if dpdk_conf.has('RTE_LIB_BPF')
+    test_sources += 'test_bpf.c'
+    fast_tests += [
+        ['bpf_autotest', true, true],
+        ['bpf_convert_autotest', true, true],
+    ]
+endif
 if dpdk_conf.has('RTE_LIB_DMADEV')
     test_sources += ['test_dmadev.c', 'test_dmadev_api.c']
     driver_test_names += 'dmadev_autotest'
diff --git a/lib/meson.build b/lib/meson.build
index de7069a078..47c18ca3b0 100644
--- a/lib/meson.build
+++ b/lib/meson.build
@@ -70,6 +70,7 @@  libraries = [
 optional_libs = [
         'bbdev',
         'bitratestats',
+        'bpf',
         'cfgfile',
         'compressdev',
         'dmadev',