[libcamera-devel] [RFC PATCH] lc-compliance: Disable clang builds
Laurent Pinchart
laurent.pinchart at ideasonboard.com
Thu Sep 9 17:06:46 CEST 2021
Hi Kieran,
Thank you for the patch.
On Thu, Sep 09, 2021 at 04:02:38PM +0100, Kieran Bingham wrote:
> On distributions with clang and gcc, the gtest library is usually
> expected to be compiled with gcc. This causes a build failure due
> to the abi incompatibility.
>
> Ideally this would be solved, or detected to be incompatible, but it may
> not be simple to identify the ABI used for an installed library with
> meson to check if it is compatible.
>
> Restrict lc-compliance to gcc builds only, knowing that if a fully
> clang-built OS or environment later wants to enable this, a new solution
> will need to be found.
This makes it impossible to compile lc-compliance on CrOS, which isn't
nice :-(
> Signed-off-by: Kieran Bingham <kieran.bingham at ideasonboard.com>
> ---
> src/lc-compliance/meson.build | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/src/lc-compliance/meson.build b/src/lc-compliance/meson.build
> index aa5852f6cb87..416405b4e67b 100644
> --- a/src/lc-compliance/meson.build
> +++ b/src/lc-compliance/meson.build
> @@ -8,6 +8,12 @@ if not (libevent.found() and libgtest.found())
> subdir_done()
> endif
>
> +if cc.get_id() == 'clang'
> + lc_compliance_enabled = false
> + warning('Disabling lc-compliance on clang due to gtest package incompatibility')
> + subdir_done()
> +endif
> +
> lc_compliance_enabled = true
>
> lc_compliance_sources = files([
--
Regards,
Laurent Pinchart
More information about the libcamera-devel
mailing list