Hey,
I've run into the same problem. According to what I found on the internet,
Qt ships protobuf < 3.2, and there was no straightforward way to disable it.
Eventually they will conflict, so I needed to downgrade protobuf to 3.1
again to make it work.
I hope the next Qt release will upgrade protobuf and/or allow to configure it.
Cheers,
Mario
On 03.03.2017 12:19, Mastic Cover wrote:
> EDIT:
>
> Tested this:
>
> *# Google Protocol Buffers library
> INCLUDEPATH += "C:\\protobuf\\install\\include"
> LIBS += -L"C:\\protobuf\\install\\lib" -llibprotobuf*
>
> And this one:
>
> *# Google Protocol Buffers library
> INCLUDEPATH += "C:\\protobuf\\install\\include"
> LIBS += -L"C:\\protobuf\\install\\lib" -lprotobuf*
>
>
> Same result over and over again.
>
>
>
>
> El viernes, 3 de marzo de 2017, 12:16:14 (UTC+1), Mastic Cover escribió:
>
> Hi everyone,
>
> I'm trying to build Protobuf with Minwg from MSYS2 as specified in documentation (C++ Installation - Windows). Everything goes perfect and all libraries are
> created.
>
> The problem comes trying to compile and test the "addressbook" sample in Qt/C++. After generating the .pb.cc and .pb.h, I add this to my .pro file inside my
> Qt project:
>
>
> *# Google Protocol Buffers library
> INCLUDEPATH += "C:\\protobuf\\install\\include"
> LIBS += -L"C:\\protobuf\\install\\lib" -llibprotobuf*
>
>
> A lot of "undefined reference" errors (almost 200 errors) are shown and I am not able to make it work:
>
> /C:\Qt Developments\MyProject\protoFolder\
addressbook.pb.cc:86 <
http://addressbook.pb.cc:86>: error: undefined reference to
> `google::protobuf::internal::AssignDescriptors(std::string const&, google::protobuf::internal::MigrationSchema const*, google::protobuf::Message const*
> const*, unsigned int const*, google::protobuf::MessageFactory*, google::protobuf::Metadata*, google::protobuf::EnumDescriptor const**,
> google::protobuf::ServiceDescriptor const**)'
>
> C:\Qt Developments\MyProject\protoFolder\
addressbook.pb.cc:97 <
http://addressbook.pb.cc:97>: error: undefined reference to
> `google::protobuf::internal::RegisterAllTypes(google::protobuf::Metadata const*, int)'
>
> C:\Qt Developments\MyProject\protoFolder\
addressbook.pb.cc:112 <
http://addressbook.pb.cc:112>: error: undefined reference to
> `google::protobuf::internal::VerifyVersion(int, int, char const*)'
>
> And so on.../
>
> Has anyone ever come across this error? Same proccess, same project, tested in a Fedora machine... it works like a charm! But I have to make it work on
> Windows :(
>
> Thanks in advance for your help.
Viele Gruesse,
Mario Emmenlauer
--
BioDataAnalysis GmbH, Mario Emmenlauer Tel. Buero:
+49-89-74677203
Balanstr. 43 mailto: memmenlauer *
biodataanalysis.de
D-81669 München
http://www.biodataanalysis.de/