Code::Blocks Forums

User forums => Help => Topic started by: Bazin on January 01, 2014, 10:16:42 am

Title: How i can chose between wxWidgets version ?
Post by: Bazin on January 01, 2014, 10:16:42 am
Hello ,  i am trying to learn with codeblocks and wxWidgets . I have running on archlinux and using codeblocks 13.12  with wxgtk 2.8. 
But i wana try wxWidgets 3.0  i compiled it successfull and i have in system 3 version of wxWidgets :
Code
wx-config --list

    Default config is gtk2-unicode-release-2.8

  Default config will be used for output

  Also available in /usr:
    gtk2-unicode-2.9
    gtk3-unicode-3.1
When i try to chose wx 3.0 in project wizard and try to compile , then codeblocks still using wx 2.8 instead of 3.0 .. is there any way how i can change wx libary path ?

Thanks much for help . 
Title: Re: How i can chose between wxWidgets version ?
Post by: stahta01 on January 01, 2014, 12:53:50 pm
This is really more of an wxWidgets or OS question.

The answer used to be in the CB Wiki; no idea if it still is.

http://wiki.codeblocks.org/index.php?title=Installing_Code::Blocks (http://wiki.codeblocks.org/index.php?title=Installing_Code::Blocks)

Tim S.
Title: Re: How i can chose between wxWidgets version ?
Post by: cacb on January 01, 2014, 11:06:18 pm

When i try to chose wx 3.0 in project wizard and try to compile , then codeblocks still using wx 2.8 instead of 3.0 .. is there any way how i can change wx libary path ?

Thanks much for help . 

Hi,
One way to achieve this is using wx-config for compiler and linker settings in  `backticks` mode (note the special quotes!!)

For example, from my settings:
Compiler options:   `wx-config  --version=3.0  --toolkit=gtk2  --cxxflags`
Linker options: `wx-config  --version=3.0  --toolkit=gtk2  --libs std,aui --static`

It is possible to combine this with global variables so you can build against wx2.8 or wx3.0 with exacly the same projects nand sources. All you have to do is switch to another another set of global variables in Code::Blocks. I have done this so I can build my projects against both (some source code fixing required). It is nice to have this as a possibility as you try to determine whether wx3.0 is mature enough for production use (mostly it is IMHO, but some things do cause issues).

More details here
http://forums.codeblocks.org/index.php/topic,18650.0.html
Title: Re: How i can chose between wxWidgets version ?
Post by: Bazin on January 02, 2014, 10:53:41 pm

When i try to chose wx 3.0 in project wizard and try to compile , then codeblocks still using wx 2.8 instead of 3.0 .. is there any way how i can change wx libary path ?

Thanks much for help . 

Hi,
One way to achieve this is using wx-config for compiler and linker settings in  `backticks` mode (note the special quotes!!)

For example, from my settings:
Compiler options:   `wx-config  --version=3.0  --toolkit=gtk2  --cxxflags`
Linker options: `wx-config  --version=3.0  --toolkit=gtk2  --libs std,aui --static`

It is possible to combine this with global variables so you can build against wx2.8 or wx3.0 with exacly the same projects nand sources. All you have to do is switch to another another set of global variables in Code::Blocks. I have done this so I can build my projects against both (some source code fixing required). It is nice to have this as a possibility as you try to determine whether wx3.0 is mature enough for production use (mostly it is IMHO, but some things do cause issues).

More details here
http://forums.codeblocks.org/index.php/topic,18650.0.html

Hello  ,
thx for this , it working for me :-) .

Btw this options u put into "Default config " or only in build targets options ?

I tried to make it via global war,but doe not work it :( ,cuz idk how i can assing global variables to project :( .

And last question . For start learning in wxWidgets and C:B is beter to use 2.8 or 3.0 version of wx   ? :-)

Thanks :-) .