From: NickP on 10 Feb 2006 10:03 Hi there, I have a VC Win32 application compiling under VS.NET 2003 no problems, but when attempting to compile under VS.NET 2005 I am recieving linker problems. The only main difference between the 2 systems is that I am using the latest platform SDK on the 2005 system in order to utilize the latest DirectX (DirectShow) SDK. Anyway, the linker error I'm recieving is Error 79 error LNK2019: unresolved external symbol "wchar_t * __stdcall _com_util::ConvertStringToBSTR(char const *)" (?ConvertStringToBSTR@_com_util@@YGPA_WPBD@Z) referenced in function "public: __thiscall _bstr_t::Data_t::Data_t(char const *)" (??0Data_t@_bstr_t@@QAE(a)PBD@Z) MTDetector.obj Error 80 error LNK2019: unresolved external symbol "char * __stdcall _com_util::ConvertBSTRToString(wchar_t *)" (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) referenced in function "public: char const * __thiscall _bstr_t::Data_t::GetString(void)const " (?GetString(a)Data_t@_bstr_t@@QBEPBDXZ) MTDetector.obj Error 81 error LNK2001: unresolved external symbol "char * __stdcall _com_util::ConvertBSTRToString(wchar_t *)" (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) SrcFilter.obj Error 82 error LNK2001: unresolved external symbol "char * __stdcall _com_util::ConvertBSTRToString(wchar_t *)" (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) TCSource.obj Error 83 fatal error LNK1120: 2 unresolved externals Raptor - <filename> I can't find any references to this call in any of my source code so I can only presume that something else I am linking in is requiring this reference? The libraries I am including and also include in VS.NET 2003 which compiles perfectly are... comctl32.lib ws2_32.lib gdiplus.lib winmm.lib strmbase.lib kernel32.lib user32.lib gdi32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib msimg32.lib imagehlp.lib msxml2.lib wmvcore.lib wininet.lib rpcrt4.lib What confuses me most is why this would work in 2003 and not 2005? Had anyone else experienced this problem and have any kind of a resolve? Thanks I'm eagerly awaiting some answer, cheers in advance! Nick.
From: Bruno van Dooren on 10 Feb 2006 11:00 > I have a VC Win32 application compiling under VS.NET 2003 no problems, > but when attempting to compile under VS.NET 2005 I am recieving linker > problems. The only main difference between the 2 systems is that I am > using the latest platform SDK on the 2005 system in order to utilize the > latest DirectX (DirectShow) SDK. > > Anyway, the linker error I'm recieving is > > Error 79 error LNK2019: unresolved external symbol "wchar_t * __stdcall > _com_util::ConvertStringToBSTR(char const *)" > (?ConvertStringToBSTR@_com_util@@YGPA_WPBD@Z) referenced in function > "public: __thiscall _bstr_t::Data_t::Data_t(char const *)" > (??0Data_t@_bstr_t@@QAE(a)PBD@Z) MTDetector.obj > Error 80 error LNK2019: unresolved external symbol "char * __stdcall > _com_util::ConvertBSTRToString(wchar_t *)" > (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) referenced in function > "public: char const * __thiscall _bstr_t::Data_t::GetString(void)const " > (?GetString(a)Data_t@_bstr_t@@QBEPBDXZ) MTDetector.obj > Error 81 error LNK2001: unresolved external symbol "char * __stdcall > _com_util::ConvertBSTRToString(wchar_t *)" > (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) SrcFilter.obj > Error 82 error LNK2001: unresolved external symbol "char * __stdcall > _com_util::ConvertBSTRToString(wchar_t *)" > (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) TCSource.obj > Error 83 fatal error LNK1120: 2 unresolved externals Raptor - <filename> > > I can't find any references to this call in any of my source code so I > can only presume that something else I am linking in is requiring this > reference? > > The libraries I am including and also include in VS.NET 2003 which > compiles perfectly are... > > comctl32.lib > ws2_32.lib > gdiplus.lib > winmm.lib > strmbase.lib > kernel32.lib > user32.lib > gdi32.lib > advapi32.lib > shell32.lib > ole32.lib > oleaut32.lib > uuid.lib > msimg32.lib > imagehlp.lib > msxml2.lib > wmvcore.lib > wininet.lib > rpcrt4.lib > > What confuses me most is why this would work in 2003 and not 2005? Had > anyone else experienced this problem and have any kind of a resolve? > Thanks I'm eagerly awaiting some answer, cheers in advance! from the ConvertStringToBSTR documentation in MSDN 2005, Header: comutil.h Lib: comsuppw.lib or comsuppwd.lib (see /Zc:wchar_t (wchar_t Is Native Type) for more information) in MSDN2003, it specifies commsupp.lib, not comsuppw.lib you lib list does not include comsuppw.lib. Try to add it. I seem to remember someone mentioning on this list that this problem is caused by the fact that the default for wchar_t changed from VC2003 to VC2005. -- Kind regards, Bruno. bruno_nos_pam_van_dooren(a)hotmail.com Remove only "_nos_pam"
From: NickP on 10 Feb 2006 12:26 Hi Bruno, I managed to get rid of the error finally by recompiling another library that I hadnt mentioned I was linking in the list. It now doesnt look for said function. Cheers for your help and sorry for my delay getting back to you. And cheers for telling me the reason why this happens, very informative! Nick. "Bruno van Dooren" <bruno_nos_pam_van_dooren(a)hotmail.com> wrote in message news:%238mVYslLGHA.2624(a)TK2MSFTNGP12.phx.gbl... >> I have a VC Win32 application compiling under VS.NET 2003 no problems, >> but when attempting to compile under VS.NET 2005 I am recieving linker >> problems. The only main difference between the 2 systems is that I am >> using the latest platform SDK on the 2005 system in order to utilize the >> latest DirectX (DirectShow) SDK. >> >> Anyway, the linker error I'm recieving is >> >> Error 79 error LNK2019: unresolved external symbol "wchar_t * __stdcall >> _com_util::ConvertStringToBSTR(char const *)" >> (?ConvertStringToBSTR@_com_util@@YGPA_WPBD@Z) referenced in function >> "public: __thiscall _bstr_t::Data_t::Data_t(char const *)" >> (??0Data_t@_bstr_t@@QAE(a)PBD@Z) MTDetector.obj >> Error 80 error LNK2019: unresolved external symbol "char * __stdcall >> _com_util::ConvertBSTRToString(wchar_t *)" >> (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) referenced in function >> "public: char const * __thiscall _bstr_t::Data_t::GetString(void)const " >> (?GetString(a)Data_t@_bstr_t@@QBEPBDXZ) MTDetector.obj >> Error 81 error LNK2001: unresolved external symbol "char * __stdcall >> _com_util::ConvertBSTRToString(wchar_t *)" >> (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) SrcFilter.obj >> Error 82 error LNK2001: unresolved external symbol "char * __stdcall >> _com_util::ConvertBSTRToString(wchar_t *)" >> (?ConvertBSTRToString@_com_util@@YGPADPA_W@Z) TCSource.obj >> Error 83 fatal error LNK1120: 2 unresolved externals Raptor - <filename> >> >> I can't find any references to this call in any of my source code so I >> can only presume that something else I am linking in is requiring this >> reference? >> >> The libraries I am including and also include in VS.NET 2003 which >> compiles perfectly are... >> >> comctl32.lib >> ws2_32.lib >> gdiplus.lib >> winmm.lib >> strmbase.lib >> kernel32.lib >> user32.lib >> gdi32.lib >> advapi32.lib >> shell32.lib >> ole32.lib >> oleaut32.lib >> uuid.lib >> msimg32.lib >> imagehlp.lib >> msxml2.lib >> wmvcore.lib >> wininet.lib >> rpcrt4.lib >> >> What confuses me most is why this would work in 2003 and not 2005? >> Had anyone else experienced this problem and have any kind of a resolve? >> Thanks I'm eagerly awaiting some answer, cheers in advance! > > from the ConvertStringToBSTR documentation in MSDN 2005, > Header: comutil.h > Lib: comsuppw.lib or comsuppwd.lib (see /Zc:wchar_t (wchar_t Is Native > Type) for more information) > > in MSDN2003, it specifies commsupp.lib, not comsuppw.lib > > you lib list does not include comsuppw.lib. Try to add it. > I seem to remember someone mentioning on this list that this problem is > caused > by the fact that the default for wchar_t changed from VC2003 to VC2005. > > > -- > > Kind regards, > Bruno. > bruno_nos_pam_van_dooren(a)hotmail.com > Remove only "_nos_pam" > >
|
Pages: 1 Prev: Visual Studio 2005 and ISO C++ Names (Repost) Next: Problem using AWE |