[libcamera-devel] [PATCH] build: Add project arguments
Laurent Pinchart
laurent.pinchart at ideasonboard.com
Tue Nov 27 00:21:13 CET 2018
Hi Kieran,
Thank you for the patch.
On Monday, 26 November 2018 16:26:35 EET Kieran Bingham wrote:
> Add language specific project arguments and ensure that -Werror is
> enabled, enforcing code to be as clean as possible.
>
> Signed-off-by: Kieran Bingham <kieran.bingham at ideasonboard.com>
>
> ---
>
> This should be kept for development as much as possible, but we may want
> to have an automatic relaxation for package builds rather than developer
> builds so that external compiler changes do not block users.
>
> meson.build | 12 ++++++++++++
> 1 file changed, 12 insertions(+)
>
> diff --git a/meson.build b/meson.build
> index 494193483079..f1fcb8e20e00 100644
> --- a/meson.build
> +++ b/meson.build
> @@ -7,6 +7,18 @@ project('libcamera - supporting complex camera pipelines',
> 'c', 'cpp', # generated from this too.
> api_version = '0.1'
>
> +common_arguments = [
> + '-Wall',
> + '-Wextra',
> + '-Werror',
I would already add -Wno-unused-parameter. This could also be done in a
subsequent patch.
Reviewed-by: Laurent Pinchart <laurent.pinchart at ideasonboard.com>
> +]
> +
> +c_arguments = common_arguments
> +cpp_arguments = common_arguments
> +
> +add_project_arguments(c_arguments, language: 'c')
> +add_project_arguments(cpp_arguments, language: 'cpp')
> +
> inc = include_directories('include')
>
> subdir('Documentation')
--
Regards,
Laurent Pinchart
More information about the libcamera-devel
mailing list