Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Yann E. MORIN" <yann.morin.1998@free.fr>
To: Quentin Schulz <foss+buildroot@0leil.net>
Cc: Quentin Schulz <quentin.schulz@theobroma-systems.com>,
	Kieran Bingham <kieran.bingham@ideasonboard.com>,
	buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH v2] package/libcamera: add explicit dependency on libevent if libevent package to be built
Date: Sun, 17 Jul 2022 14:56:03 +0200	[thread overview]
Message-ID: <20220717125603.GD2107091@scaer> (raw)
In-Reply-To: <20220711131823.116481-1-foss+buildroot@0leil.net>

Quentin, All,

On 2022-07-11 15:18 +0200, Quentin Schulz spake thusly:
> From: Quentin Schulz <quentin.schulz@theobroma-systems.com>
> 
> The cam application requires libevent. Since there's no Kconfig option
> for it, cam building ability is checked by meson build system by default.
> 
> If libevent is present in the sysroot, cam is built.
> 
> The issue is that there's no explicit dependency on libevent in
> libcamera package. This means that it is possible for libevent AND
> libcamera to be built, but have libcamera be built before libevent.
> Meaning that even if all requirements seem to be fulfilled, cam still
> won't be enabled in some cases.
> 
> This fixes the possible race by expliciting the dependency to libevent
> if the libevent package is enabled. Otherwise, explicitly disable cam
> building as it's already known that it isn't going to build.
> 
> Cc: Quentin Schulz <foss+buildroot@0leil.net>
> Signed-off-by: Quentin Schulz <quentin.schulz@theobroma-systems.com>

Applied to master, thanks.

Regards,
Yann E. MORIN.

> ---
> 
> v2:
>  - added -Dcam=enabled when libevent package is enabled, to catch
>  possible additional dependencies to cam in later upgrades,
> 
>  package/libcamera/libcamera.mk | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/package/libcamera/libcamera.mk b/package/libcamera/libcamera.mk
> index 41d6a5abef..3f336cb797 100644
> --- a/package/libcamera/libcamera.mk
> +++ b/package/libcamera/libcamera.mk
> @@ -84,6 +84,13 @@ else
>  LIBCAMERA_CONF_OPTS += -Dqcam=disabled
>  endif
>  
> +ifeq ($(BR2_PACKAGE_LIBEVENT),y)
> +LIBCAMERA_CONF_OPTS += -Dcam=enabled
> +LIBCAMERA_DEPENDENCIES += libevent
> +else
> +LIBCAMERA_CONF_OPTS += -Dcam=disabled
> +endif
> +
>  ifeq ($(BR2_PACKAGE_TIFF),y)
>  LIBCAMERA_DEPENDENCIES += tiff
>  endif
> -- 
> 2.36.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

  parent reply	other threads:[~2022-07-17 12:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-11 13:18 [Buildroot] [PATCH v2] package/libcamera: add explicit dependency on libevent if libevent package to be built Quentin Schulz
2022-07-11 19:53 ` Kieran Bingham
2022-07-12  8:00   ` Quentin Schulz
2022-07-13  9:02     ` Kieran Bingham
2022-07-17 12:59       ` Yann E. MORIN
2022-07-17 12:56 ` Yann E. MORIN [this message]
2022-08-10 10:22 ` Peter Korsgaard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220717125603.GD2107091@scaer \
    --to=yann.morin.1998@free.fr \
    --cc=buildroot@buildroot.org \
    --cc=foss+buildroot@0leil.net \
    --cc=kieran.bingham@ideasonboard.com \
    --cc=quentin.schulz@theobroma-systems.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox