Skip to content

Commit

Permalink
修改插件proto_to_struct的生成目录
Browse files Browse the repository at this point in the history
  • Loading branch information
171930433 committed Mar 27, 2024
1 parent 844e1b2 commit 31e2b9e
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions src/protoc_plugin/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,23 +1,20 @@
cmake_minimum_required(VERSION 3.10)
# set(CMAKE_C_COMPILER gcc-9)
# set(CMAKE_CXX_COMPILER g++-9)
# set(CMAKE_CXX_STANDARD 17)

project(protoc-gen-struct_pb)

set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/output/bin)

find_package(Protobuf REQUIRED)
# find_package(Protobuf REQUIRED)
file(GLOB SRCS "*.cpp" "*.cc" "*.h")
# protobuf_generate_cpp(PROTO_SRCS PROTO_HDRS proto_to_struct.proto)

include(cmake/struct_pb.cmake)
protobuf_generate_modified(
PROTO_PATH_FROM_CMAKE_SOURCE
LANGUAGE cpp
OUT_VAR PROTO_CLASS_SRCS
IMPORT_DIRS ${CMAKE_SOURCE_DIR}
# IMPORT_DIRS ${CMAKE_SOURCE_DIR}
PROTOS proto_to_struct.proto
PROTOC_OUT_DIR ${CMAKE_BINARY_DIR}
# PROTOC_OUT_DIR ${CMAKE_BINARY_DIR}
)


Expand Down

0 comments on commit 31e2b9e

Please sign in to comment.