1config BR2_PACKAGE_LIBCAMERA_ARCH_SUPPORTS
2	bool
3	default y
4	# Invalid packing size of ControlValue struct on m68k
5	depends on !BR2_m68k
6
7menuconfig BR2_PACKAGE_LIBCAMERA
8	bool "libcamera"
9	depends on BR2_PACKAGE_LIBCAMERA_ARCH_SUPPORTS
10	depends on BR2_INSTALL_LIBSTDCPP
11	depends on BR2_TOOLCHAIN_HAS_THREADS
12	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_8 # C++17
13	depends on !BR2_STATIC_LIBS # gnutls
14	depends on BR2_USE_WCHAR # gnutls
15	select BR2_PACKAGE_GNUTLS
16	select BR2_PACKAGE_LIBYAML
17	select BR2_PACKAGE_LIBCAMERA_PIPELINE_UVCVIDEO if !BR2_PACKAGE_LIBCAMERA_HAS_PIPELINE
18	help
19	  libcamera provides a software stack to support
20	  complex devices that need heavy hardware image
21	  processing operations.
22
23	  http://www.libcamera.org/
24
25if BR2_PACKAGE_LIBCAMERA
26
27config BR2_PACKAGE_LIBCAMERA_V4L2
28	bool "libcamera v4l2 compatibility layer"
29	help
30	  libcamera v4l2 compatibility layer
31
32config BR2_PACKAGE_LIBCAMERA_HAS_PIPELINE
33	bool
34
35config BR2_PACKAGE_LIBCAMERA_PIPELINE_IMX8_ISI
36	bool "imx8-isi pipeline"
37	depends on BR2_arm || BR2_aarch64
38	select BR2_PACKAGE_LIBCAMERA_HAS_PIPELINE
39	help
40	  Pipeline for i.MX8 SoC ISI capture interface.
41
42config BR2_PACKAGE_LIBCAMERA_PIPELINE_IPU3
43	bool "ipu3 pipeline"
44	depends on BR2_i386 || BR2_x86_64
45	select BR2_PACKAGE_LIBCAMERA_HAS_PIPELINE
46	help
47	  Pipeline for Intel IPU3.
48
49config BR2_PACKAGE_LIBCAMERA_PIPELINE_RKISP1
50	bool "rkisp1 pipeline"
51	depends on BR2_arm || BR2_aarch64
52	select BR2_PACKAGE_LIBCAMERA_HAS_PIPELINE
53	help
54	  Pipeline for Rockchip ISP1.
55
56config BR2_PACKAGE_LIBCAMERA_PIPELINE_RPI_VC4
57	bool "rpi/vc4 pipeline"
58	depends on BR2_arm || BR2_aarch64
59	depends on BR2_USE_WCHAR # boost (already enforced for gnutls)
60	select BR2_PACKAGE_BOOST
61	select BR2_PACKAGE_LIBCAMERA_HAS_PIPELINE
62	help
63	  Pipeline for Raspberry Pi devices.
64
65config BR2_PACKAGE_LIBCAMERA_PIPELINE_SIMPLE
66	bool "simple pipeline"
67	select BR2_PACKAGE_LIBCAMERA_HAS_PIPELINE
68	help
69	  Pipeline for simple pipelines.
70
71config BR2_PACKAGE_LIBCAMERA_PIPELINE_UVCVIDEO
72	bool "uvcvideo pipeline"
73	help
74	  Pipeline for uvcvideo devices.
75
76config BR2_PACKAGE_LIBCAMERA_PIPELINE_VIMC
77	bool "vimc pipeline"
78	select BR2_PACKAGE_LIBCAMERA_HAS_PIPELINE
79	help
80	  Pipeline for the vimc device.
81
82config BR2_PACKAGE_LIBCAMERA_COMPLIANCE
83	bool "lc-compliance test application"
84	depends on BR2_USE_WCHAR # gtest
85	depends on BR2_TOOLCHAIN_HAS_THREADS # gtest
86	depends on BR2_INSTALL_LIBSTDCPP # gtest
87	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_5 # gtest
88	depends on BR2_USE_MMU # gtest
89	select BR2_PACKAGE_GTEST
90	select BR2_PACKAGE_LIBEVENT
91	help
92	  lc-compliance test application
93
94comment "lc-compliance test application needs a toolchain w/ C++, wchar, threads, gcc >= 5"
95	depends on BR2_USE_MMU
96	depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS || \
97		!BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_GCC_AT_LEAST_5
98
99endif # BR2_PACKAGE_LIBCAMERA
100
101comment "libcamera needs a toolchain w/ C++, threads, wchar, dynamic library, gcc >= 8"
102	depends on BR2_PACKAGE_LIBCAMERA_ARCH_SUPPORTS
103	depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS || \
104		!BR2_TOOLCHAIN_GCC_AT_LEAST_8 || BR2_STATIC_LIBS || !BR2_USE_WCHAR
105