- iOS/Objective-C 元类和类别
- objective-c - -1001 错误,当 NSURLSession 通过 httpproxy 和/etc/hosts
- java - 使用网络类获取 url 地址
- ios - 推送通知中不播放声音
我已尽我所能按照说明进行操作。下载的 GPBuffers 5.0rc1 将 src/google 文件夹放入我的项目目录。添加了设置> C/C++ >“其他包含目录”的路径。
但我想我需要在某处放置一个 -lprotobuf 编译器选项。我尝试将其添加到设置 > xxx > 附加命令行参数中的 C/C++ 和链接器。
但运气不好。
似乎缺少 libprotobuf.lib、libprotobuf-lite.lib 和 libprotoc.lib。也许它没有正确构建..
我有我的 serverThread.cpp,它看起来像:
#include "serverThread.h"
#include "sendStruct.h"
#include <fstream>
#include <string>
#include "messages.pb.h"
日志转载如下。
它似乎缺少对某个库的引用。因为大多数依赖项都在那里。
Error 62 error LNK1120: 60 unresolved externals C:\work\freetimeC+\ServerUpdater\Debug\ServerUpdater.exe
Error 37 error LNK2001: unresolved external symbol "class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const google::protobuf::internal::kEmptyString" (?kEmptyString@internal@protobuf@google@@3V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@B) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 34 error LNK2001: unresolved external symbol "private: virtual void __thiscall google::protobuf::Message::SetCachedSize(int)const " (?SetCachedSize@Message@protobuf@google@@EBEXH@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 27 error LNK2001: unresolved external symbol "public: virtual bool __thiscall google::protobuf::Message::IsInitialized(void)const " (?IsInitialized@Message@protobuf@google@@UBE_NXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 28 error LNK2001: unresolved external symbol "public: virtual bool __thiscall google::protobuf::Message::MergePartialFromCodedStream(class google::protobuf::io::CodedInputStream *)" (?MergePartialFromCodedStream@Message@protobuf@google@@UAE_NPAVCodedInputStream@io@23@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 21 error LNK2001: unresolved external symbol "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall google::protobuf::Message::GetTypeName(void)const " (?GetTypeName@Message@protobuf@google@@UBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 22 error LNK2001: unresolved external symbol "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall google::protobuf::Message::InitializationErrorString(void)const " (?InitializationErrorString@Message@protobuf@google@@UBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 35 error LNK2001: unresolved external symbol "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall google::protobuf::MessageLite::InitializationErrorString(void)const " (?InitializationErrorString@MessageLite@protobuf@google@@UBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 29 error LNK2001: unresolved external symbol "public: virtual int __thiscall google::protobuf::Message::ByteSize(void)const " (?ByteSize@Message@protobuf@google@@UBEHXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 25 error LNK2001: unresolved external symbol "public: virtual int __thiscall google::protobuf::Message::SpaceUsed(void)const " (?SpaceUsed@Message@protobuf@google@@UBEHXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 31 error LNK2001: unresolved external symbol "public: virtual unsigned char * __thiscall google::protobuf::MessageLite::SerializeWithCachedSizesToArray(unsigned char *)const " (?SerializeWithCachedSizesToArray@MessageLite@protobuf@google@@UBEPAEPAE@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 23 error LNK2001: unresolved external symbol "public: virtual void __thiscall google::protobuf::Message::CheckTypeAndMergeFrom(class google::protobuf::MessageLite const &)" (?CheckTypeAndMergeFrom@Message@protobuf@google@@UAEXABVMessageLite@23@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 26 error LNK2001: unresolved external symbol "public: virtual void __thiscall google::protobuf::Message::Clear(void)" (?Clear@Message@protobuf@google@@UAEXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 32 error LNK2001: unresolved external symbol "public: virtual void __thiscall google::protobuf::Message::CopyFrom(class google::protobuf::Message const &)" (?CopyFrom@Message@protobuf@google@@UAEXABV123@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 24 error LNK2001: unresolved external symbol "public: virtual void __thiscall google::protobuf::Message::DiscardUnknownFields(void)" (?DiscardUnknownFields@Message@protobuf@google@@UAEXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 33 error LNK2001: unresolved external symbol "public: virtual void __thiscall google::protobuf::Message::MergeFrom(class google::protobuf::Message const &)" (?MergeFrom@Message@protobuf@google@@UAEXABV123@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 30 error LNK2001: unresolved external symbol "public: virtual void __thiscall google::protobuf::Message::SerializeWithCachedSizes(class google::protobuf::io::CodedOutputStream *)const " (?SerializeWithCachedSizes@Message@protobuf@google@@UBEXPAVCodedOutputStream@io@23@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 43 error LNK2019: unresolved external symbol "private: bool __thiscall google::protobuf::io::CodedInputStream::ReadVarint32Fallback(unsigned int *)" (?ReadVarint32Fallback@CodedInputStream@io@protobuf@google@@AAE_NPAI@Z) referenced in function "public: bool __thiscall google::protobuf::io::CodedInputStream::ReadVarint32(unsigned int *)" (?ReadVarint32@CodedInputStream@io@protobuf@google@@QAE_NPAI@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 53 error LNK2019: unresolved external symbol "private: static int __cdecl google::protobuf::io::CodedOutputStream::VarintSize32Fallback(unsigned int)" (?VarintSize32Fallback@CodedOutputStream@io@protobuf@google@@CAHI@Z) referenced in function "public: static int __cdecl google::protobuf::io::CodedOutputStream::VarintSize32(unsigned int)" (?VarintSize32@CodedOutputStream@io@protobuf@google@@SAHI@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 49 error LNK2019: unresolved external symbol "private: static unsigned char * __cdecl google::protobuf::io::CodedOutputStream::WriteVarint32FallbackToArray(unsigned int,unsigned char *)" (?WriteVarint32FallbackToArray@CodedOutputStream@io@protobuf@google@@CAPAEIPAE@Z) referenced in function "public: static unsigned char * __cdecl google::protobuf::io::CodedOutputStream::WriteTagToArray(unsigned int,unsigned char *)" (?WriteTagToArray@CodedOutputStream@io@protobuf@google@@SAPAEIPAE@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 44 error LNK2019: unresolved external symbol "private: static void __cdecl google::protobuf::internal::WireFormat::VerifyUTF8StringFallback(char const *,int,enum google::protobuf::internal::WireFormat::Operation)" (?VerifyUTF8StringFallback@WireFormat@internal@protobuf@google@@CAXPBDHW4Operation@1234@@Z) referenced in function "public: static void __cdecl google::protobuf::internal::WireFormat::VerifyUTF8String(char const *,int,enum google::protobuf::internal::WireFormat::Operation)" (?VerifyUTF8String@WireFormat@internal@protobuf@google@@SAXPBDHW4Operation@1234@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 42 error LNK2019: unresolved external symbol "private: unsigned int __thiscall google::protobuf::io::CodedInputStream::ReadTagFallback(void)" (?ReadTagFallback@CodedInputStream@io@protobuf@google@@AAEIXZ) referenced in function "public: unsigned int __thiscall google::protobuf::io::CodedInputStream::ReadTag(void)" (?ReadTag@CodedInputStream@io@protobuf@google@@QAEIXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 38 error LNK2019: unresolved external symbol "private: void __thiscall google::protobuf::UnknownFieldSet::ClearFallback(void)" (?ClearFallback@UnknownFieldSet@protobuf@google@@AAEXXZ) referenced in function "public: void __thiscall google::protobuf::UnknownFieldSet::Clear(void)" (?Clear@UnknownFieldSet@protobuf@google@@QAEXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 61 error LNK2019: unresolved external symbol "protected: void __thiscall google::protobuf::internal::RepeatedPtrFieldBase::Reserve(int)" (?Reserve@RepeatedPtrFieldBase@internal@protobuf@google@@IAEXH@Z) referenced in function "protected: class ArchProtocol::Person_PhoneNumber * __thiscall google::protobuf::internal::RepeatedPtrFieldBase::Add<class google::protobuf::RepeatedPtrField<class ArchProtocol::Person_PhoneNumber>::TypeHandler>(void)" (??$Add@VTypeHandler@?$RepeatedPtrField@VPerson_PhoneNumber@ArchProtocol@@@protobuf@google@@@RepeatedPtrFieldBase@internal@protobuf@google@@IAEPAVPerson_PhoneNumber@ArchProtocol@@XZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 58 error LNK2019: unresolved external symbol "protected: void __thiscall google::protobuf::internal::RepeatedPtrFieldBase::Swap(class google::protobuf::internal::RepeatedPtrFieldBase *)" (?Swap@RepeatedPtrFieldBase@internal@protobuf@google@@IAEXPAV1234@@Z) referenced in function "public: void __thiscall google::protobuf::RepeatedPtrField<class ArchProtocol::Person_PhoneNumber>::Swap(class google::protobuf::RepeatedPtrField<class ArchProtocol::Person_PhoneNumber> *)" (?Swap@?$RepeatedPtrField@VPerson_PhoneNumber@ArchProtocol@@@protobuf@google@@QAEXPAV123@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 2 error LNK2019: unresolved external symbol "public: __thiscall google::protobuf::internal::GeneratedMessageReflection::GeneratedMessageReflection(class google::protobuf::Descriptor const *,class google::protobuf::Message const *,int const * const,int,int,int,class google::protobuf::DescriptorPool const *,class google::protobuf::MessageFactory *,int)" (??0GeneratedMessageReflection@internal@protobuf@google@@QAE@PBVDescriptor@23@PBVMessage@23@QBHHHHPBVDescriptorPool@23@PAVMessageFactory@23@H@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AssignDesc_messages_2eproto(void)" (?protobuf_AssignDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 4 error LNK2019: unresolved external symbol "public: __thiscall google::protobuf::internal::LogMessage::~LogMessage(void)" (??1LogMessage@internal@protobuf@google@@QAE@XZ) referenced in function "void __cdecl ArchProtocol::protobuf_AssignDesc_messages_2eproto(void)" (?protobuf_AssignDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 7 error LNK2019: unresolved external symbol "public: __thiscall google::protobuf::internal::LogMessage::LogMessage(enum google::protobuf::LogLevel,char const *,int)" (??0LogMessage@internal@protobuf@google@@QAE@W4LogLevel@23@PBDH@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AssignDesc_messages_2eproto(void)" (?protobuf_AssignDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 18 error LNK2019: unresolved external symbol "public: __thiscall google::protobuf::UnknownFieldSet::~UnknownFieldSet(void)" (??1UnknownFieldSet@protobuf@google@@QAE@XZ) referenced in function __unwindfunclet$??0Person_PhoneNumber@ArchProtocol@@QAE@XZ$0 C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 20 error LNK2019: unresolved external symbol "public: __thiscall google::protobuf::UnknownFieldSet::UnknownFieldSet(void)" (??0UnknownFieldSet@protobuf@google@@QAE@XZ) referenced in function "public: __thiscall ArchProtocol::Person_PhoneNumber::Person_PhoneNumber(void)" (??0Person_PhoneNumber@ArchProtocol@@QAE@XZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 8 error LNK2019: unresolved external symbol "public: class google::protobuf::FileDescriptor const * __thiscall google::protobuf::DescriptorPool::FindFileByName(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)const " (?FindFileByName@DescriptorPool@protobuf@google@@QBEPBVFileDescriptor@23@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AssignDesc_messages_2eproto(void)" (?protobuf_AssignDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 6 error LNK2019: unresolved external symbol "public: class google::protobuf::internal::LogMessage & __thiscall google::protobuf::internal::LogMessage::operator<<(char const *)" (??6LogMessage@internal@protobuf@google@@QAEAAV0123@PBD@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AssignDesc_messages_2eproto(void)" (?protobuf_AssignDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 60 error LNK2019: unresolved external symbol "public: int __thiscall google::protobuf::io::CodedInputStream::PushLimit(int)" (?PushLimit@CodedInputStream@io@protobuf@google@@QAEHH@Z) referenced in function "public: static bool __cdecl google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual<class ArchProtocol::Person_PhoneNumber>(class google::protobuf::io::CodedInputStream*,class ArchProtocol::Person_PhoneNumber *)" (??$ReadMessageNoVirtual@VPerson_PhoneNumber@ArchProtocol@@@WireFormatLite@internal@protobuf@google@@SA_NPAVCodedInputStream@io@23@PAVPerson_PhoneNumber@ArchProtocol@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 39 error LNK2019: unresolved external symbol "public: static bool __cdecl google::protobuf::internal::WireFormat::SkipField(class google::protobuf::io::CodedInputStream *,unsigned int,class google::protobuf::UnknownFieldSet *)" (?SkipField@WireFormat@internal@protobuf@google@@SA_NPAVCodedInputStream@io@34@IPAVUnknownFieldSet@34@@Z) referenced in function "public: virtual bool __thiscall ArchProtocol::Person_PhoneNumber::MergePartialFromCodedStream(class google::protobuf::io::CodedInputStream *)" (?MergePartialFromCodedStream@Person_PhoneNumber@ArchProtocol@@UAE_NPAVCodedInputStream@io@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 41 error LNK2019: unresolved external symbol "public: static bool __cdecl google::protobuf::internal::WireFormatLite::ReadString(class google::protobuf::io::CodedInputStream *,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > *)" (?ReadString@WireFormatLite@internal@protobuf@google@@SA_NPAVCodedInputStream@io@34@PAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in function "public: virtual bool __thiscall ArchProtocol::Person_PhoneNumber::MergePartialFromCodedStream(class google::protobuf::io::CodedInputStream *)" (?MergePartialFromCodedStream@Person_PhoneNumber@ArchProtocol@@UAE_NPAVCodedInputStream@io@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 9 error LNK2019: unresolved external symbol "public: static class google::protobuf::DescriptorPool const * __cdecl google::protobuf::DescriptorPool::generated_pool(void)" (?generated_pool@DescriptorPool@protobuf@google@@SAPBV123@XZ) referenced in function "void __cdecl ArchProtocol::protobuf_AssignDesc_messages_2eproto(void)" (?protobuf_AssignDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 3 error LNK2019: unresolved external symbol "public: static class google::protobuf::MessageFactory * __cdecl google::protobuf::MessageFactory::generated_factory(void)" (?generated_factory@MessageFactory@protobuf@google@@SAPAV123@XZ) referenced in function "void __cdecl ArchProtocol::protobuf_AssignDesc_messages_2eproto(void)" (?protobuf_AssignDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 52 error LNK2019: unresolved external symbol "public: static int __cdecl google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(class google::protobuf::UnknownFieldSet const &)" (?ComputeUnknownFieldsSize@WireFormat@internal@protobuf@google@@SAHABVUnknownFieldSet@34@@Z) referenced in function "public: virtual int __thiscall ArchProtocol::Person_PhoneNumber::ByteSize(void)const " (?ByteSize@Person_PhoneNumber@ArchProtocol@@UBEHXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 48 error LNK2019: unresolved external symbol "public: static unsigned char * __cdecl google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(class google::protobuf::UnknownFieldSet const &,unsigned char *)" (?SerializeUnknownFieldsToArray@WireFormat@internal@protobuf@google@@SAPAEABVUnknownFieldSet@34@PAE@Z) referenced in function "public: virtual unsigned char * __thiscall ArchProtocol::Person_PhoneNumber::SerializeWithCachedSizesToArray(unsigned char *)const " (?SerializeWithCachedSizesToArray@Person_PhoneNumber@ArchProtocol@@UBEPAEPAE@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 51 error LNK2019: unresolved external symbol "public: static unsigned char * __cdecl google::protobuf::io::CodedOutputStream::WriteRawToArray(void const *,int,unsigned char *)" (?WriteRawToArray@CodedOutputStream@io@protobuf@google@@SAPAEPBXHPAE@Z) referenced in function "public: static unsigned char * __cdecl google::protobuf::io::CodedOutputStream::WriteStringToArray(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,unsigned char *)" (?WriteStringToArray@CodedOutputStream@io@protobuf@google@@SAPAEABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@PAE@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 50 error LNK2019: unresolved external symbol "public: static unsigned char * __cdecl google::protobuf::io::CodedOutputStream::WriteVarint64ToArray(unsigned __int64,unsigned char *)" (?WriteVarint64ToArray@CodedOutputStream@io@protobuf@google@@SAPAE_KPAE@Z) referenced in function "public: static unsigned char * __cdecl google::protobuf::io::CodedOutputStream::WriteVarint32SignExtendedToArray(int,unsigned char *)" (?WriteVarint32SignExtendedToArray@CodedOutputStream@io@protobuf@google@@SAPAEHPAE@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 16 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::DescriptorPool::InternalAddGeneratedFile(void const *,int)" (?InternalAddGeneratedFile@DescriptorPool@protobuf@google@@SAXPBXH@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AddDesc_messages_2eproto(void)" (?protobuf_AddDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 54 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::internal::ReflectionOps::Merge(class google::protobuf::Message const &,class google::protobuf::Message *)" (?Merge@ReflectionOps@internal@protobuf@google@@SAXABVMessage@34@PAV534@@Z) referenced in function "public: virtual void __thiscall ArchProtocol::Person_PhoneNumber::MergeFrom(class google::protobuf::Message const &)" (?MergeFrom@Person_PhoneNumber@ArchProtocol@@UAEXABVMessage@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 45 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::internal::WireFormat::SerializeUnknownFields(class google::protobuf::UnknownFieldSet const &,class google::protobuf::io::CodedOutputStream *)" (?SerializeUnknownFields@WireFormat@internal@protobuf@google@@SAXABVUnknownFieldSet@34@PAVCodedOutputStream@io@34@@Z) referenced in function "public:virtual void __thiscall ArchProtocol::Person_PhoneNumber::SerializeWithCachedSizes(class google::protobuf::io::CodedOutputStream *)const " (?SerializeWithCachedSizes@Person_PhoneNumber@ArchProtocol@@UBEXPAVCodedOutputStream@io@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 46 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::internal::WireFormatLite::WriteEnum(int,int,class google::protobuf::io::CodedOutputStream *)" (?WriteEnum@WireFormatLite@internal@protobuf@google@@SAXHHPAVCodedOutputStream@io@34@@Z) referenced in function "public: virtual void __thiscall ArchProtocol::Person_PhoneNumber::SerializeWithCachedSizes(class google::protobuf::io::CodedOutputStream *)const " (?SerializeWithCachedSizes@Person_PhoneNumber@ArchProtocol@@UBEXPAVCodedOutputStream@io@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 57 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::internal::WireFormatLite::WriteInt32(int,int,class google::protobuf::io::CodedOutputStream *)" (?WriteInt32@WireFormatLite@internal@protobuf@google@@SAXHHPAVCodedOutputStream@io@34@@Z) referenced in function "public: virtual void __thiscall ArchProtocol::Person::SerializeWithCachedSizes(class google::protobuf::io::CodedOutputStream *)const " (?SerializeWithCachedSizes@Person@ArchProtocol@@UBEXPAVCodedOutputStream@io@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 56 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(int,class google::protobuf::MessageLite const &,class google::protobuf::io::CodedOutputStream *)" (?WriteMessageMaybeToArray@WireFormatLite@internal@protobuf@google@@SAXHABVMessageLite@34@PAVCodedOutputStream@io@34@@Z) referenced in function"public: virtual void __thiscall ArchProtocol::Person::SerializeWithCachedSizes(class google::protobuf::io::CodedOutputStream *)const " (?SerializeWithCachedSizes@Person@ArchProtocol@@UBEXPAVCodedOutputStream@io@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 47 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::internal::WireFormatLite::WriteString(int,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class google::protobuf::io::CodedOutputStream *)" (?WriteString@WireFormatLite@internal@protobuf@google@@SAXHABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@PAVCodedOutputStream@io@34@@Z) referenced in function "public: virtual void __thiscall ArchProtocol::Person_PhoneNumber::SerializeWithCachedSizes(class google::protobuf::io::CodedOutputStream *)const " (?SerializeWithCachedSizes@Person_PhoneNumber@ArchProtocol@@UBEXPAVCodedOutputStream@io@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 15 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::MessageFactory::InternalRegisterGeneratedFile(char const *,void (__cdecl*)(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &))" (?InternalRegisterGeneratedFile@MessageFactory@protobuf@google@@SAXPBDP6AXABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AddDesc_messages_2eproto(void)" (?protobuf_AddDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 10 error LNK2019: unresolved external symbol "public: static void __cdecl google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(class google::protobuf::Descriptor const *,class google::protobuf::Message const *)" (?InternalRegisterGeneratedMessage@MessageFactory@protobuf@google@@SAXPBVDescriptor@23@PBVMessage@23@@Z) referenced in function "void __cdecl ArchProtocol::`anonymous namespace'::protobuf_RegisterTypes(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (?protobuf_RegisterTypes@?A0x2751caee@ArchProtocol@@YAXABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 13 error LNK2019: unresolved external symbol "public: virtual __thiscall google::protobuf::Closure::~Closure(void)" (??1Closure@protobuf@google@@UAE@XZ) referenced in function "public: virtual void * __thiscall google::protobuf::Closure::`scalar deleting destructor'(unsigned int)" (??_GClosure@protobuf@google@@UAEPAXI@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 11 error LNK2019: unresolved external symbol "public: virtual __thiscall google::protobuf::internal::FunctionClosure0::~FunctionClosure0(void)" (??1FunctionClosure0@internal@protobuf@google@@UAE@XZ) referenced in function "void __cdecl google::protobuf::GoogleOnceInit(int *,void (__cdecl*)(void))" (?GoogleOnceInit@protobuf@google@@YAXPAHP6AXXZ@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 19 error LNK2019: unresolved external symbol "public: virtual __thiscall google::protobuf::Message::~Message(void)" (??1Message@protobuf@google@@UAE@XZ) referenced in function __unwindfunclet$??0Person_PhoneNumber@ArchProtocol@@QAE@XZ$0 C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 36 error LNK2019: unresolved external symbol "public: virtual __thiscall google::protobuf::MessageLite::~MessageLite(void)" (??1MessageLite@protobuf@google@@UAE@XZ) referenced in function "public: virtual void * __thiscall google::protobuf::MessageLite::`scalar deleting destructor'(unsigned int)" (??_GMessageLite@protobuf@google@@UAEPAXI@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 5 error LNK2019: unresolved external symbol "public: void __thiscall google::protobuf::internal::LogFinisher::operator=(class google::protobuf::internal::LogMessage &)" (??4LogFinisher@internal@protobuf@google@@QAEXAAVLogMessage@123@@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AssignDesc_messages_2eproto(void)" (?protobuf_AssignDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 59 error LNK2019: unresolved external symbol "public: void __thiscall google::protobuf::io::CodedInputStream::PopLimit(int)" (?PopLimit@CodedInputStream@io@protobuf@google@@QAEXH@Z) referenced in function "public: static bool __cdecl google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual<class ArchProtocol::Person_PhoneNumber>(class google::protobuf::io::CodedInputStream *,class ArchProtocol::Person_PhoneNumber *)" (??$ReadMessageNoVirtual@VPerson_PhoneNumber@ArchProtocol@@@WireFormatLite@internal@protobuf@google@@SA_NPAVCodedInputStream@io@23@PAVPerson_PhoneNumber@ArchProtocol@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 40 error LNK2019: unresolved external symbol "public: void __thiscall google::protobuf::UnknownFieldSet::AddVarint(int,unsigned __int64)" (?AddVarint@UnknownFieldSet@protobuf@google@@QAEXH_K@Z) referenced in function "public: virtual bool __thiscall ArchProtocol::Person_PhoneNumber::MergePartialFromCodedStream(class google::protobuf::io::CodedInputStream *)" (?MergePartialFromCodedStream@Person_PhoneNumber@ArchProtocol@@UAE_NPAVCodedInputStream@io@protobuf@google@@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 55 error LNK2019: unresolved external symbol "public: void __thiscall google::protobuf::UnknownFieldSet::MergeFrom(class google::protobuf::UnknownFieldSet const &)" (?MergeFrom@UnknownFieldSet@protobuf@google@@QAEXABV123@@Z) referenced in function "public: void __thiscall ArchProtocol::Person_PhoneNumber::MergeFrom(class ArchProtocol::Person_PhoneNumber const &)" (?MergeFrom@Person_PhoneNumber@ArchProtocol@@QAEXABV12@@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 12 error LNK2019: unresolved external symbol "void __cdecl google::protobuf::GoogleOnceInitImpl(int *,class google::protobuf::Closure *)" (?GoogleOnceInitImpl@protobuf@google@@YAXPAHPAVClosure@12@@Z) referenced in function "void __cdecl google::protobuf::GoogleOnceInit(int *,void (__cdecl*)(void))" (?GoogleOnceInit@protobuf@google@@YAXPAHP6AXXZ@Z) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 14 error LNK2019: unresolved external symbol "void __cdecl google::protobuf::internal::OnShutdown(void (__cdecl*)(void))" (?OnShutdown@internal@protobuf@google@@YAXP6AXXZ@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AddDesc_messages_2eproto(void)" (?protobuf_AddDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
Error 17 error LNK2019: unresolved external symbol "void __cdecl google::protobuf::internal::VerifyVersion(int,int,char const *)" (?VerifyVersion@internal@protobuf@google@@YAXHHPBD@Z) referenced in function "void __cdecl ArchProtocol::protobuf_AddDesc_messages_2eproto(void)" (?protobuf_AddDesc_messages_2eproto@ArchProtocol@@YAXXZ) C:\work\freetimeC+\ServerUpdater\ServerUpdater\messages.pb.obj
最佳答案
需要正确编译 Protobuf。有一个 vsprojects 文件夹。只需构建 libprotobuf 并将 libprotobuf.lib 添加为对项目的引用,方法是:
属性 > 链接器 > 输入:附加依赖项 > 编辑...
如果你把它复制到你的项目文件夹/google 放在 google/libprotobuf.lib
现在一切都应该顺利编译。
关于c++ - Visual Studio 2010 C++/w Google Protocol Buffer 。找不到 60 个外部对象。无法编译,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13733604/
我的一位教授给了我们一些考试练习题,其中一个问题类似于下面(伪代码): a.setColor(blue); b.setColor(red); a = b; b.setColor(purple); b
我似乎经常使用这个测试 if( object && object !== "null" && object !== "undefined" ){ doSomething(); } 在对象上,我
C# Object/object 是值类型还是引用类型? 我检查过它们可以保留引用,但是这个引用不能用于更改对象。 using System; class MyClass { public s
我在通过 AJAX 发送 json 时遇到问题。 var data = [{"name": "Will", "surname": "Smith", "age": "40"},{"name": "Wil
当我尝试访问我的 View 中的对象 {{result}} 时(我从 Express js 服务器发送该对象),它只显示 [object][object]有谁知道如何获取 JSON 格式的值吗? 这是
我有不同类型的数据(可能是字符串、整数......)。这是一个简单的例子: public static void main(String[] args) { before("one"); }
嗨,我是 json 和 javascript 的新手。 我在这个网站找到了使用json数据作为表格的方法。 我很好奇为什么当我尝试使用 json 数据作为表时,我得到 [Object,Object]
已关闭。此问题需要 debugging details 。目前不接受答案。 编辑问题以包含 desired behavior, a specific problem or error, and the
我听别人说 null == object 比 object == null check 例如: void m1(Object obj ) { if(null == obj) // Is thi
Match 对象 提供了对正则表达式匹配的只读属性的访问。 说明 Match 对象只能通过 RegExp 对象的 Execute 方法来创建,该方法实际上返回了 Match 对象的集合。所有的
Class 对象 使用 Class 语句创建的对象。提供了对类的各种事件的访问。 说明 不允许显式地将一个变量声明为 Class 类型。在 VBScript 的上下文中,“类对象”一词指的是用
Folder 对象 提供对文件夹所有属性的访问。 说明 以下代码举例说明如何获得 Folder 对象并查看它的属性: Function ShowDateCreated(f
File 对象 提供对文件的所有属性的访问。 说明 以下代码举例说明如何获得一个 File 对象并查看它的属性: Function ShowDateCreated(fil
Drive 对象 提供对磁盘驱动器或网络共享的属性的访问。 说明 以下代码举例说明如何使用 Drive 对象访问驱动器的属性: Function ShowFreeSpac
FileSystemObject 对象 提供对计算机文件系统的访问。 说明 以下代码举例说明如何使用 FileSystemObject 对象返回一个 TextStream 对象,此对象可以被读
我是 javascript OOP 的新手,我认为这是一个相对基本的问题,但我无法通过搜索网络找到任何帮助。我是否遗漏了什么,或者我只是以错误的方式解决了这个问题? 这是我的示例代码: functio
我可以很容易地创造出很多不同的对象。例如像这样: var myObject = { myFunction: function () { return ""; } };
function Person(fname, lname) { this.fname = fname, this.lname = lname, this.getName = function()
任何人都可以向我解释为什么下面的代码给出 (object, Object) 吗? (console.log(dope) 给出了它应该的内容,但在 JSON.stringify 和 JSON.parse
我正在尝试完成散点图 exercise来自免费代码营。然而,我现在只自己学习了 d3 几个小时,在遵循 lynda.com 的教程后,我一直在尝试确定如何在工具提示中显示特定数据。 This code
我是一名优秀的程序员,十分优秀!