After tests, this linking error is generated by this code :

     std::wstring test;
     WString str(test);


In fact in WString.C file the implementation is like this :

#ifndef WT_NO_STD_WSTRING
WString::WString(const std::wstring& value)
   : impl_(0)
{
   utf8_ = Wt::toUTF8(value);
}
#endif

So I think i compiled Wt with this flag so the constructor is not 
implemented in my Wt lib.

Why this flag woke up is set to ON when I compile on windows ?
How can I solve my problem in a proper way ?



Le 20/09/2011 17:57, Bastien Amiel a écrit :
> Hi,
>
> I have linking problem on every widget using WString on Windows with
> Visual 9.0 (compile fine on linux) :
>
> web.lib(WidgetTasks.obj) : error LNK2001: unresolved external symbol
> "public: __thiscall Wt::WString::WString(class
> std::basic_string<unsigned short,struct std::char_traits<unsigned
> short>,class std::allocator<unsigned short>  >  const&)"
> (??0WString@Wt@@QAE@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@@Z)
>
> I tryed to add this flag "/Zc:wchar_t-" to CMake but it does'nt solve my
> problem.
>
> Any idea ?
>
> Thx
>
>
>
>
>
> ------------------------------------------------------------------------------
> All the data continuously generated in your IT infrastructure contains a
> definitive record of customers, application performance, security
> threats, fraudulent activity and more. Splunk takes this data and makes
> sense of it. Business sense. IT sense. Common sense.
> http://p.sf.net/sfu/splunk-d2dcopy1
> _______________________________________________
> witty-interest mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/witty-interest
>
>


------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2dcopy1
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest

Reply via email to