[libcamera-devel,4/4] meson: test: Simplify top level meson
diff mbox series

Message ID 20201207150737.307692-5-kieran.bingham@ideasonboard.com
State Accepted
Delegated to: Kieran Bingham
Headers show
Series
  • libcamera: Small meson-fixes
Related show

Commit Message

Kieran Bingham Dec. 7, 2020, 3:07 p.m. UTC
Utilise the subdir_done() functionality as is used with other optional components
to simplify the top level meson file.

Suggested-by: Jacopo Mondi <jacopo@jmondi.org>
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
---
 meson.build      | 5 +----
 test/meson.build | 4 ++++
 2 files changed, 5 insertions(+), 4 deletions(-)

Comments

Laurent Pinchart Dec. 7, 2020, 7:15 p.m. UTC | #1
Hi Kieran,

Thank you for the patch.

On Mon, Dec 07, 2020 at 03:07:37PM +0000, Kieran Bingham wrote:
> Utilise the subdir_done() functionality as is used with other optional components
> to simplify the top level meson file.
> 
> Suggested-by: Jacopo Mondi <jacopo@jmondi.org>
> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> ---
>  meson.build      | 5 +----
>  test/meson.build | 4 ++++
>  2 files changed, 5 insertions(+), 4 deletions(-)
> 
> diff --git a/meson.build b/meson.build
> index 55cf36e15f57..c47eb420f4db 100644
> --- a/meson.build
> +++ b/meson.build
> @@ -121,10 +121,7 @@ subdir('src')
>  # through configuration values. They are enabled by default.
>  
>  subdir('Documentation')
> -
> -if get_option('test')
> -    subdir('test')
> -endif
> +subdir('test')
>  
>  if not meson.is_cross_build()
>      kernel_version_req = '>= 5.0.0'
> diff --git a/test/meson.build b/test/meson.build
> index 0a1d434e3996..7f0682ad9efe 100644
> --- a/test/meson.build
> +++ b/test/meson.build
> @@ -1,5 +1,9 @@
>  # SPDX-License-Identifier: CC0-1.0
>  
> +if not get_option('test')
> +    subdir_done()
> +endif
> +
>  subdir('libtest')
>  
>  subdir('camera')

Patch
diff mbox series

diff --git a/meson.build b/meson.build
index 55cf36e15f57..c47eb420f4db 100644
--- a/meson.build
+++ b/meson.build
@@ -121,10 +121,7 @@  subdir('src')
 # through configuration values. They are enabled by default.
 
 subdir('Documentation')
-
-if get_option('test')
-    subdir('test')
-endif
+subdir('test')
 
 if not meson.is_cross_build()
     kernel_version_req = '>= 5.0.0'
diff --git a/test/meson.build b/test/meson.build
index 0a1d434e3996..7f0682ad9efe 100644
--- a/test/meson.build
+++ b/test/meson.build
@@ -1,5 +1,9 @@ 
 # SPDX-License-Identifier: CC0-1.0
 
+if not get_option('test')
+    subdir_done()
+endif
+
 subdir('libtest')
 
 subdir('camera')