How to use with Google Protocol Buffers?

Sysprogs forums Forums VisualGDB How to use with Google Protocol Buffers?

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #12805
    LakeWorthB
    Participant

    So for protobuf, you start with a *.proto file, which you have to first call protoc to generate the c and header files, then you have to compile with g++.  How can I automate this with VisualGDB to a remote Linux server?

    protoc -I=. –cpp_out=. Example.proto

    g++ -c Example.pb.cc
    … repeat for each proto file.
    g++ -o Messages.a Example1.pb.o Example2.pb.o …

    • This topic was modified 7 years, 8 months ago by LakeWorthB.
    #12819
    support
    Keymaster

    Hi,

    If you are using a Custom edition or higher, you can simply add a custom pre-build action.

    Another option would be to add a custom Makefile target or a cutsom MSBuild target. We don’t have an example specific to protobuf, however you can try following our tutorial for building Qt projects with MSBuild for a detailed example on creating custom MSBuild rules and targets.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.