Click here to Skip to main content
15,746,202 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
I need to use protobuf libarary in my visual studio 2013,which I probably suppose supports c++03 ,so without the correct protobuf version I am getting error when I try to run the c++ code which has imported the generated header.

.proto file compiled with version :protoc 3.21

error :ProtoBuf requires atleast C++11

What I have tried:

I tried installing the protobuf pacakage using vcpkg ,but it is installing the version 3.21 which is failing to run in visual studio 2013.
Kindly Provide a suitable version as well as link of the site to download.
Updated 6-Jun-23 22:50pm
Shao Voon Wong 7-Jun-23 6:22am    
Visual Studio 2013 supports C++11. You have to enable it in the project properties dialog.

1 solution

As per this GitHub issue[^], all versions since 3.6.0 require C++ 11, and will not work in such an ancient version of Visual Studio.

If you can't update to a recent version of Visual Studio (why not? The community edition of VS2022[^] is free!) then you'll need to use protobuf v3.5.x or earlier.
Share this answer
CPallini 7-Jun-23 8:01am    

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900