[Buildroot] [git commit] package/opencv3: drop support for protobuf
Julien Olivain
ju.o at free.fr
Sat Dec 27 14:38:26 UTC 2025
commit: https://git.buildroot.net/buildroot/commit/?id=0865927da4dc74c884d86c0b381f7fef0317d7da
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/master
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 at bootlin.com>
Signed-off-by: Julien Olivain <ju.o at free.fr>
---
Config.in.legacy | 7 +++++++
package/opencv3/Config.in | 12 ------------
package/opencv3/opencv3.mk | 12 +-----------
3 files changed, 8 insertions(+), 23 deletions(-)
diff --git a/Config.in.legacy b/Config.in.legacy
index 1a756dcd3c..fea7f79ec5 100644
--- a/Config.in.legacy
+++ b/Config.in.legacy
@@ -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
diff --git a/package/opencv3/Config.in b/package/opencv3/Config.in
index c4c5d22a54..6c4d4e9c8a 100644
--- a/package/opencv3/Config.in
+++ b/package/opencv3/Config.in
@@ -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
diff --git a/package/opencv3/opencv3.mk b/package/opencv3/opencv3.mk
index 8a862a47b1..3fcf2543a7 100644
--- a/package/opencv3/opencv3.mk
+++ b/package/opencv3/opencv3.mk
@@ -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
More information about the buildroot
mailing list