[libcamera-devel,v4,1/6] py: meson: Use libcamera_private dependency
diff mbox series

Message ID 20220819111615.39814-2-tomi.valkeinen@ideasonboard.com
State Accepted
Commit 418cbde04b8b21a7b9392808a0144dadcd56d268
Headers show
Series
  • Python bindings: PyCameraManager and non-blocking eventfd
Related show

Commit Message

Tomi Valkeinen Aug. 19, 2022, 11:16 a.m. UTC
We define -DLIBCAMERA_BASE_PRIVATE to get access to libcamera private
headers, but the correct way to do this is to have a meson dependency to
libcamera_private.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
---
 src/py/libcamera/meson.build | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

Comments

Laurent Pinchart Aug. 19, 2022, 11:23 a.m. UTC | #1
Hi Tomi,

Thank you for the patch.

On Fri, Aug 19, 2022 at 02:16:10PM +0300, Tomi Valkeinen wrote:
> We define -DLIBCAMERA_BASE_PRIVATE to get access to libcamera private
> headers, but the correct way to do this is to have a meson dependency to
> libcamera_private.
> 
> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>

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

> ---
>  src/py/libcamera/meson.build | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/src/py/libcamera/meson.build b/src/py/libcamera/meson.build
> index 04578bac..99c2a8c0 100644
> --- a/src/py/libcamera/meson.build
> +++ b/src/py/libcamera/meson.build
> @@ -60,7 +60,7 @@ pycamera_sources += custom_target('py_gen_formats',
>                                    command : [gen_py_formats, '-o', '@OUTPUT@', '@INPUT@'])
>  
>  pycamera_deps = [
> -    libcamera_public,
> +    libcamera_private,
>      py3_dep,
>      pybind11_dep,
>  ]
> @@ -69,7 +69,6 @@ pycamera_args = [
>      '-fvisibility=hidden',
>      '-Wno-shadow',
>      '-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT',
> -    '-DLIBCAMERA_BASE_PRIVATE',
>  ]
>  
>  destdir = get_option('libdir') / ('python' + py3_dep.version()) / 'site-packages' / 'libcamera'

Patch
diff mbox series

diff --git a/src/py/libcamera/meson.build b/src/py/libcamera/meson.build
index 04578bac..99c2a8c0 100644
--- a/src/py/libcamera/meson.build
+++ b/src/py/libcamera/meson.build
@@ -60,7 +60,7 @@  pycamera_sources += custom_target('py_gen_formats',
                                   command : [gen_py_formats, '-o', '@OUTPUT@', '@INPUT@'])
 
 pycamera_deps = [
-    libcamera_public,
+    libcamera_private,
     py3_dep,
     pybind11_dep,
 ]
@@ -69,7 +69,6 @@  pycamera_args = [
     '-fvisibility=hidden',
     '-Wno-shadow',
     '-DPYBIND11_USE_SMART_HOLDER_AS_DEFAULT',
-    '-DLIBCAMERA_BASE_PRIVATE',
 ]
 
 destdir = get_option('libdir') / ('python' + py3_dep.version()) / 'site-packages' / 'libcamera'