Problem linking release version of C++ project

B

Barry

Hi,

I have a C++ project which I maintain with CMake. The Debug version of
the program works fine but I can't link the release version which uses
the same CMake file. Can anyone offer me some advice on how I might
resolve this issue?

Here is an example of one of my linker erros -

Application.obj : error LNK2001: unresolved external symbol "__declspec
(dllimport) public: static class QString __cdecl QString::fromStdString
(class std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &)" (__imp_?fromStdString@QString@@SA?
AV1@ABV?$basic_string@DU?$char_traits@D@std@@V?
$allocator@D@2@@std@@@Z)

Thanks for your help,

Magnus
 
J

joseph cook

Hi,

I have a C++ project which I maintain with CMake. The Debug version of
the program works fine but I can't link the release version which uses
the same CMake file. Can anyone offer me some advice on how I might
resolve this issue?

Here is an example of one of my linker erros -

Application.obj : error LNK2001: unresolved external symbol "__declspec
(dllimport) public: static class QString __cdecl QString::fromStdString
(class std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &)" (__imp_?fromStdString@QString@@SA?
AV1@ABV?$basic_string@DU?$char_traits@D@std@@V?
$allocator@D@2@@std@@@Z)

Thanks for your help,

Magnus

Try posting in the trolltech Qt forums. It's possible you have come
across a compiler bug that others have seen before you.

Joe C
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,065
Latest member
OrderGreenAcreCBD

Latest Threads

Top