package/opencv3: drop support for protobuf

The protobuf support breaks the build, as protobuf includes
libabseil-cpp headers, which now require C++14. opencv3 doesn't have
any ENABLE_CXX14 option, so for the time being, disable protobuf
support until someone bothers enough to fix this up.

While we suspect a libabseil-cpp version bump to be responsible for
the issue, we are not 100% sure. However, the issue is definitely
present in Buildroot 2025.02.x, as it can be reproduced using the
following defconfig:

BR2_aarch64=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
BR2_PACKAGE_OPENCV3=y
BR2_PACKAGE_OPENCV3_LIB_SHAPE=y
BR2_PACKAGE_OPENCV3_LIB_STITCHING=y
BR2_PACKAGE_OPENCV3_LIB_SUPERRES=y
BR2_PACKAGE_OPENCV3_LIB_TS=y
BR2_PACKAGE_OPENCV3_LIB_VIDEOSTAB=y
BR2_PACKAGE_OPENCV3_WITH_PROTOBUF=y

Fixes:

  https://autobuild.buildroot.net/results/39432e7746e6bc5224592a7d2f744ca992bd529a/

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
This commit is contained in:
Thomas Petazzoni
2025-12-26 18:14:46 +01:00
committed by Julien Olivain
parent a63acfa0a3
commit 0865927da4
3 changed files with 8 additions and 23 deletions

View File

@@ -146,6 +146,13 @@ endif
comment "Legacy options removed in 2026.02"
config BR2_PACKAGE_OPENCV3_WITH_PROTOBUF
bool "opencv3 protobuf support removed"
select BR2_LEGACY
help
Support for OpenCV 3 protobuf support has been removed as it
was no longer compatible with recent versions of protobuf.
config BR2_PACKAGE_RESIPROCATE_APPS
bool "resiprocate apps support option removed"
select BR2_LEGACY

View File

@@ -278,18 +278,6 @@ config BR2_PACKAGE_OPENCV3_WITH_PNG
help
Use shared libpng from the target system.
config BR2_PACKAGE_OPENCV3_WITH_PROTOBUF
bool "protobuf support"
depends on BR2_PACKAGE_PROTOBUF_ARCH_SUPPORTS # protobuf
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_8 # protobuf
select BR2_PACKAGE_PROTOBUF
help
Use shared protobuf from the target system.
comment "protobuf support needs a toolchain w/ gcc >= 8"
depends on BR2_PACKAGE_PROTOBUF_ARCH_SUPPORTS
depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_8
config BR2_PACKAGE_OPENCV3_WITH_TIFF
bool "tiff support"
select BR2_PACKAGE_TIFF

View File

@@ -223,6 +223,7 @@ OPENCV3_CONF_OPTS += \
-DWITH_OPENEXR=OFF \
-DWITH_OPENNI2=OFF \
-DWITH_OPENNI=OFF \
-DWITH_PROTOBUF=OFF \
-DWITH_UNICAP=OFF \
-DWITH_VA=OFF \
-DWITH_VA_INTEL=OFF \
@@ -282,17 +283,6 @@ else
OPENCV3_CONF_OPTS += -DWITH_PNG=OFF
endif
ifeq ($(BR2_PACKAGE_OPENCV3_WITH_PROTOBUF),y)
# protobuf needs c++11 (since 3.6.0)
OPENCV3_CONF_OPTS += \
-DENABLE_CXX11=ON \
-DPROTOBUF_UPDATE_FILES=ON \
-DWITH_PROTOBUF=ON
OPENCV3_DEPENDENCIES += protobuf
else
OPENCV3_CONF_OPTS += -DWITH_PROTOBUF=OFF
endif
ifeq ($(BR2_PACKAGE_OPENCV3_WITH_QT5),y)
OPENCV3_CONF_OPTS += -DWITH_QT=5
OPENCV3_DEPENDENCIES += qt5base