diff options
Diffstat (limited to 'dynamic-layers/openembedded-layer/recipes-support/opencv/files/0003-protobuf-allow-target-protoc-to-be-built.patch')
-rw-r--r-- | dynamic-layers/openembedded-layer/recipes-support/opencv/files/0003-protobuf-allow-target-protoc-to-be-built.patch | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0003-protobuf-allow-target-protoc-to-be-built.patch b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0003-protobuf-allow-target-protoc-to-be-built.patch new file mode 100644 index 00000000..bbdeaa2a --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0003-protobuf-allow-target-protoc-to-be-built.patch @@ -0,0 +1,45 @@ +From 450d94b475460d1af32b207d0ced495794863f0d Mon Sep 17 00:00:00 2001 +From: Anuj Mittal <anuj.mittal@intel.com> +Date: Wed, 29 Nov 2023 12:55:19 +0530 +Subject: [PATCH 3/3] protobuf: allow target protoc to be built + +We can run target binaries using a qemu wrapper so allow these to be +built and run. + +Upstream-Status: Inappropriate + +Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> +--- + cmake/developer_package/frontends/frontends.cmake | 2 +- + thirdparty/protobuf/CMakeLists.txt | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/cmake/developer_package/frontends/frontends.cmake b/cmake/developer_package/frontends/frontends.cmake +index f3b5520d6d2..7579f638c5a 100644 +--- a/cmake/developer_package/frontends/frontends.cmake ++++ b/cmake/developer_package/frontends/frontends.cmake +@@ -163,7 +163,7 @@ macro(ov_add_frontend) + set(OUTPUT_PB_HEADER ${CMAKE_CURRENT_BINARY_DIR}/${relative_path}/${FILE_WE}.pb.h) + add_custom_command( + OUTPUT "${OUTPUT_PB_SRC}" "${OUTPUT_PB_HEADER}" +- COMMAND ${PROTOC_EXECUTABLE} ARGS --cpp_out ${CMAKE_CURRENT_BINARY_DIR} -I ${protofiles_root_dir} ${proto_file} ++ COMMAND protoc ARGS --cpp_out ${CMAKE_CURRENT_BINARY_DIR} -I ${protofiles_root_dir} ${proto_file} + DEPENDS ${PROTOC_DEPENDENCY} ${proto_file} + COMMENT "Running C++ protocol buffer compiler (${PROTOC_EXECUTABLE}) on ${proto_file_relative}" + VERBATIM +diff --git a/thirdparty/protobuf/CMakeLists.txt b/thirdparty/protobuf/CMakeLists.txt +index 15f32601f23..36853caf7dc 100644 +--- a/thirdparty/protobuf/CMakeLists.txt ++++ b/thirdparty/protobuf/CMakeLists.txt +@@ -31,7 +31,7 @@ unset(HAVE_ZLIB CACHE) + if(CMAKE_CROSSCOMPILING OR + (APPLE AND (HOST_X86_64 AND AARCH64)) OR + (MSVC AND (HOST_X86_64 AND (AARCH64 OR ARM)))) +- set(protobuf_BUILD_PROTOC_BINARIES OFF CACHE BOOL "Build protoc binaries" FORCE) ++ set(protobuf_BUILD_PROTOC_BINARIES ON CACHE BOOL "Build protoc binaries" FORCE) + else() + set(protobuf_BUILD_PROTOC_BINARIES ON CACHE BOOL "Build protoc binaries" FORCE) + endif() +-- +2.34.1 + |