compiling wxWidgets, MS VC 2003 .Net versus MS VS 2005
Carsten A. Arnholm
arnholm at offline.no
Sun Jul 15 11:29:39 PDT 2007
Vadim Zeitlin wrote:
> On Sun, 15 Jul 2007 14:05:21 +0200 "Carsten A. Arnholm"
> <arnholm at offline.no> wrote:
>
>> For C++ compiler settings (Release) I use: multithreaded DLL Runtime
>> [/MD]
>>
>> For linker (excerpt from Code::Blocks project file)
>> <Add option="/NODEFAULTLIB:libcmt.lib" />
>> <Add option="/NODEFAULTLIB:msvcrtd.lib" />
>
> FWIW, if you must use /NODEFAULTLIB switch chances are you're doing
> something wrong. It shouldn't be necessary to exclude the default
> libraries
> if the correct /MD[d] option is used for all the code in the project.
Maybe you are right, but I have had such problems also in earlier versions
of VS, so at least it is easy to end up in such a situation. I am clearly
using the proper /MD[d] option but still this can ce an issue sometimes. The
/NODEFAULTLIB:msvcrtd.lib excludes the debug runtime from release mode.
I agree this should not be necessary, but in real life sometimes its is.
>>> Are there known problems with wxWidgets and MS VS 2005?
>>
>> Only that it can be a pain to set up correctly, I think.
>
> Importing the project files in build/msw directory and building is
> all you need to do.
For building wxWidgets, that is true, it is easy. The only confusing thing
is that there are so many build configurations.
For building an application that uses wxWidgets, it can still be a problem
to set things up properly, especially if you are distributing binary code. I
had it wrong for a while, and the program would only run on the developer
machine. The problem was that debug dependencies sneaked into release build.
Best regards
Carsten A. Arnholm
http://arnholm.org/
N59.776 E10.457
More information about the wx-users
mailing list