1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-21 19:33:03 +04:00

protobuf build documenting: move the WITH_PROTOBUF option to the top level

This commit is contained in:
Alexander Enaldiev
2018-04-23 15:15:34 +03:00
committed by Alexander Alekhin
parent 331af82e6d
commit 677dc802ae
2 changed files with 4 additions and 4 deletions
+3 -4
View File
@@ -1,15 +1,14 @@
# If protobuf is found - libprotobuf target is available
ocv_option(WITH_PROTOBUF "Enable libprotobuf" ON)
ocv_option(BUILD_PROTOBUF "Force to build libprotobuf from sources" ON)
ocv_option(PROTOBUF_UPDATE_FILES "Force rebuilding .proto files (protoc should be available)" OFF)
set(HAVE_PROTOBUF FALSE)
if(NOT WITH_PROTOBUF)
return()
endif()
ocv_option(BUILD_PROTOBUF "Force to build libprotobuf from sources" ON)
ocv_option(PROTOBUF_UPDATE_FILES "Force rebuilding .proto files (protoc should be available)" OFF)
function(get_protobuf_version version include)
file(STRINGS "${include}/google/protobuf/stubs/common.h" ver REGEX "#define GOOGLE_PROTOBUF_VERSION [0-9]+")
string(REGEX MATCHALL "[0-9]+" ver ${ver})