[libcamera-devel] meson: options: Disable pycamera by default
diff mbox series

Message ID 20220623121038.598008-1-javierm@redhat.com
State Accepted
Commit 7ec3bfedbe22962600b438a13d9e13d37d55ce25
Headers show
Series
  • [libcamera-devel] meson: options: Disable pycamera by default
Related show

Commit Message

Javier Martinez Canillas June 23, 2022, 12:10 p.m. UTC
The libcamera Python bindings is still experimental and it relies on some
features in pybind11 that are not yet upstreamed, so a special branch has
to be downloaded as a subproject.

This conflicts with the build process used by most Linux distributions,
since there is expected that all the dependencies will be fulfilled by
-devel packages present in the build root.

To allow libcamera to be built by distros, let's disable the pycamera by
default. This can still be enabled with `meson build -Dpycamera=enabled`.

Suggested-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
---

 meson_options.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Laurent Pinchart June 23, 2022, 12:14 p.m. UTC | #1
Hi Javier,

Thank you for the patch.

On Thu, Jun 23, 2022 at 02:10:38PM +0200, Javier Martinez Canillas wrote:
> The libcamera Python bindings is still experimental and it relies on some
> features in pybind11 that are not yet upstreamed, so a special branch has
> to be downloaded as a subproject.
> 
> This conflicts with the build process used by most Linux distributions,
> since there is expected that all the dependencies will be fulfilled by
> -devel packages present in the build root.
> 
> To allow libcamera to be built by distros, let's disable the pycamera by
> default. This can still be enabled with `meson build -Dpycamera=enabled`.
> 
> Suggested-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>

Sounds sensible to me. Any volunteer to engage with upstream pybind11 to
get the features we need in their master branch ? :-)

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

> ---
> 
>  meson_options.txt | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/meson_options.txt b/meson_options.txt
> index ca00c78e8134..7a9aecfc60f5 100644
> --- a/meson_options.txt
> +++ b/meson_options.txt
> @@ -61,5 +61,5 @@ option('v4l2',
>  
>  option('pycamera',
>          type : 'feature',
> -        value : 'auto',
> +        value : 'disabled',
>          description : 'Enable libcamera Python bindings (experimental)')
Tomi Valkeinen June 23, 2022, 12:22 p.m. UTC | #2
On 23/06/2022 15:14, Laurent Pinchart wrote:
> Hi Javier,
> 
> Thank you for the patch.
> 
> On Thu, Jun 23, 2022 at 02:10:38PM +0200, Javier Martinez Canillas wrote:
>> The libcamera Python bindings is still experimental and it relies on some
>> features in pybind11 that are not yet upstreamed, so a special branch has
>> to be downloaded as a subproject.
>>
>> This conflicts with the build process used by most Linux distributions,
>> since there is expected that all the dependencies will be fulfilled by
>> -devel packages present in the build root.
>>
>> To allow libcamera to be built by distros, let's disable the pycamera by
>> default. This can still be enabled with `meson build -Dpycamera=enabled`.
>>
>> Suggested-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
>> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
> 
> Sounds sensible to me. Any volunteer to engage with upstream pybind11 to
> get the features we need in their master branch ? :-)

I know you're talking to me there...

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

Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>

  Tomi
Kieran Bingham June 23, 2022, 12:26 p.m. UTC | #3
Quoting Javier Martinez Canillas (2022-06-23 13:10:38)
> The libcamera Python bindings is still experimental and it relies on some
> features in pybind11 that are not yet upstreamed, so a special branch has
> to be downloaded as a subproject.
> 
> This conflicts with the build process used by most Linux distributions,
> since there is expected that all the dependencies will be fulfilled by
> -devel packages present in the build root.
> 
> To allow libcamera to be built by distros, let's disable the pycamera by
> default. This can still be enabled with `meson build -Dpycamera=enabled`.

Fine with me, but lets highlight this to RPi as the main users so far.

David, Naush - can you bring this to the attention of who ever packages
libcamera, to note that they will have to manually enable pycamera

  -Dpycamera=enabled


Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
 


> 
> Suggested-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
> ---
> 
>  meson_options.txt | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/meson_options.txt b/meson_options.txt
> index ca00c78e8134..7a9aecfc60f5 100644
> --- a/meson_options.txt
> +++ b/meson_options.txt
> @@ -61,5 +61,5 @@ option('v4l2',
>  
>  option('pycamera',
>          type : 'feature',
> -        value : 'auto',
> +        value : 'disabled',
>          description : 'Enable libcamera Python bindings (experimental)')
> -- 
> 2.36.1
>

Patch
diff mbox series

diff --git a/meson_options.txt b/meson_options.txt
index ca00c78e8134..7a9aecfc60f5 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -61,5 +61,5 @@  option('v4l2',
 
 option('pycamera',
         type : 'feature',
-        value : 'auto',
+        value : 'disabled',
         description : 'Enable libcamera Python bindings (experimental)')