Page 1 of 1

Adding Custom wx-config script at Project Creation

Posted: Sat Sep 03, 2011 3:55 am
by evstevemd
I use multiple wxWidgets (2.8 for running applications and 2.9 for developing my apps). Now I want to be able to use custom described here during creating projects.
C::B have a way of defining WX global and you can use that at project creation. Is there a plan/workaround in CL than editing manually?
Thanks!

Re: Adding Custom wx-config script at Project Creation

Posted: Sat Sep 03, 2011 9:50 am
by eranif
evstevemd wrote:Now I want to be able to use custom described here
Described where?
evstevemd wrote:C::B have a way of defining WX global and you can use that at project creation
How is that relevant?
evstevemd wrote:Is there a plan/workaround in CL than editing manually?
Assuming that I understood what you want correctly:

* create a wxWidgets project
* In "project settings | compiler" and the "project settings | pages" pages replace the 'wx-config' line from:
$(shell wx-config ...) into something like $(shell $(WXTOOL) ....)
* define the build configurations you want (wx_29_debug, wx_28_debug) or as many as you need
* For each build configuration (wx_29_debug, wx_28_debug etc), go to "Project Settings | Environment | Additional Environment variables" set the following variables
1) WXTOOL
2) WXWIN (needed for Windows)
3) WXCFG (needed for Windows)
to point to the one you want for that build configuration (in the format of: WXTOOL=/path/to/my/wxconfig)
* save this project as template

Create a new project using the template you have just created and from now on, use this template instead of the default wx one.

Note: there is a minor bug under Windows that the user templates are saved into the installation directory.. (if you are running under Windows with Admin privileges, it won't be a problem)

Eran

Re: Adding Custom wx-config script at Project Creation

Posted: Sun Sep 04, 2011 9:45 am
by evstevemd
Thanks and forgive me for forgetting posting a link.
Everything in that link is already beautifully put in your post.
Again thanks and enjoy!
:D