mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-30 22:11:59 -09:00
package/libcamera: Enable python bindings
Since libcamera commit f513fd70ba1a ("subprojects: Drop leftovers of
pybind11"), merged before libcamera v0.1.0, libcamera has no longer
relied on an external subproject branch of pybind to build the python
bindings.
Provide a new package option to allow enabling the python bindings on
libcamera when python3 is available in the buildroot configuration.
Enabling the python bindings will select and bring in pybind as a
dependency.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Marcus Folkesson <marcus.folkesson@gmail.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
This commit is contained in:
committed by
Julien Olivain
parent
4a9a4c3cd5
commit
81ae3116e4
@@ -24,6 +24,13 @@ menuconfig BR2_PACKAGE_LIBCAMERA
|
|||||||
|
|
||||||
if BR2_PACKAGE_LIBCAMERA
|
if BR2_PACKAGE_LIBCAMERA
|
||||||
|
|
||||||
|
config BR2_PACKAGE_LIBCAMERA_PYTHON
|
||||||
|
bool "python bindings"
|
||||||
|
depends on BR2_PACKAGE_PYTHON3
|
||||||
|
select BR2_PACKAGE_PYTHON_PYBIND
|
||||||
|
help
|
||||||
|
Enable libcamera python bindings
|
||||||
|
|
||||||
config BR2_PACKAGE_LIBCAMERA_V4L2
|
config BR2_PACKAGE_LIBCAMERA_V4L2
|
||||||
bool "libcamera v4l2 compatibility layer"
|
bool "libcamera v4l2 compatibility layer"
|
||||||
help
|
help
|
||||||
|
|||||||
@@ -19,7 +19,6 @@ LIBCAMERA_CONF_OPTS = \
|
|||||||
-Dandroid=disabled \
|
-Dandroid=disabled \
|
||||||
-Ddocumentation=disabled \
|
-Ddocumentation=disabled \
|
||||||
-Dtest=false \
|
-Dtest=false \
|
||||||
-Dpycamera=disabled \
|
|
||||||
-Dwerror=false
|
-Dwerror=false
|
||||||
LIBCAMERA_INSTALL_STAGING = YES
|
LIBCAMERA_INSTALL_STAGING = YES
|
||||||
LIBCAMERA_LICENSE = \
|
LIBCAMERA_LICENSE = \
|
||||||
@@ -45,6 +44,13 @@ ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_7),y)
|
|||||||
LIBCAMERA_CXXFLAGS = -faligned-new
|
LIBCAMERA_CXXFLAGS = -faligned-new
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifeq ($(BR2_PACKAGE_LIBCAMERA_PYTHON),y)
|
||||||
|
LIBCAMERA_DEPENDENCIES += python3 python-pybind
|
||||||
|
LIBCAMERA_CONF_OPTS += -Dpycamera=enabled
|
||||||
|
else
|
||||||
|
LIBCAMERA_CONF_OPTS += -Dpycamera=disabled
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(BR2_PACKAGE_LIBCAMERA_V4L2),y)
|
ifeq ($(BR2_PACKAGE_LIBCAMERA_V4L2),y)
|
||||||
LIBCAMERA_CONF_OPTS += -Dv4l2=true
|
LIBCAMERA_CONF_OPTS += -Dv4l2=true
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user