Thursday, December 29, 2005

wxWidgets resources compile again every time you hit "Run" (F5)

Another wxWidgets related answer...

Symptoms:
You include the wxWidgets resources in your project (wxrc.rc). Now everytime you hit 'Run' (F5) Visual Studio (7) thinks it has to rebuild some of the sources and the resources.

Solution:
Create a file 'inc_wxrc.rc' with the following contents:
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by mikadoApp.rc
//
#include
Do not add wx.rc to your project directly. Either add 'inc_wxrc.rc' to the project or, if you have a .rc file that includes wx.rc, include 'inc_wxrc.rc' instead.

Advertisment (for my own product):
The wxVisualSetup Project Wizard does this automatically and even add a version resource to your binary. It is available for €39.95 for Visual Studio 2002, 2003 and 2005, all versions.

Best regards

Hajo

No comments: