Protocol Buffers - Google's data interchange format (grpc依赖)
https://developers.google.com/protocol-buffers/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
394 B
17 lines
394 B
5 years ago
|
set(protoc_files
|
||
|
${protobuf_source_dir}/src/google/protobuf/compiler/main.cc
|
||
|
)
|
||
|
|
||
|
if (MSVC)
|
||
|
set(protoc_rc_files
|
||
|
${CMAKE_CURRENT_BINARY_DIR}/version.rc
|
||
|
)
|
||
|
endif()
|
||
|
|
||
|
add_executable(protoc ${protoc_files} ${protoc_rc_files})
|
||
|
target_link_libraries(protoc libprotoc libprotobuf)
|
||
|
add_executable(protobuf::protoc ALIAS protoc)
|
||
|
|
||
|
set_target_properties(protoc PROPERTIES
|
||
|
VERSION ${protobuf_VERSION})
|