User forums > Help
Trouble Complining CB with CB under Linux
Miguel Gimenez:
Probably it is time to create the CodeBlocks_wx32-unix.workspace :)
tigerbeard:
--- Quote from: Miguel Gimenez on December 11, 2023, 01:19:19 pm ---Probably it is time to create the CodeBlocks_wx32-unix.workspace :)
--- End quote ---
Maybe there is a wx-config that could be handled at the same time...(?)
Because I still can't get it compiled from CB. At least I know why: CB is still using the GKT2 system version in "/usr/bin/wx-config". I just did not yet find out how to make CB using the other one.
My PATH has "/usr/local/bin" with the correct wx-config to use. When I open any terminal I get the correct version. I also tried to start CB from a terminal, but it keeps resolving it to "/usr/bin/wx-config".
Obviously I could re-edit each project and put the full full path the CustomVar page, but that can't be the standard approach, is it? Also changing the system default symlink each time I want to compile C::B seems wrong as well. There must be sth I am not seeing..
stahta01:
--- Quote from: tigerbeard on December 09, 2023, 11:07:46 pm ---
I changed the the custom variables to this
--- Code: --- WX_VERSION = 32
WX_CONFIG =/usr/local/bin/wx-config --version=3.2
--- End code ---
--- End quote ---
You told it to do what it is doing!!!
tigerbeard:
--- Quote from: stahta01 on December 12, 2023, 04:47:56 am ---
--- Quote from: tigerbeard on December 09, 2023, 11:07:46 pm ---
--- Code: --- WX_VERSION = 32
WX_CONFIG =/usr/local/bin/wx-config --version=3.2
--- End code ---
--- End quote ---
You told it to do what it is doing!!!
--- End quote ---
well, not quite.
I had been reverting the values to default and use a gtk3 compiled version of wx3.0. I think that should fix the compile errors. But its still using the gtk2 version and not the gtk3 version.
Currently the build options are this:
--- Code: ---
// custom vars
WX_VERSION = 30
WX_CONFIG =wx-config --version=3.0
//compiler
`$(WX_CONFIG) --cflags` # thats the default that resolves the compile options for wx
--- End code ---
With the setting above its not clear to me how to use multiple wx-config on the system? I thought its using the same wx-config that I is default with my user by setting $PATH. This version that any terminal would use. Currently I have those two wx-configs on the system and the path is such that it should find the local one first which works fine in a terminal window.
--- Code: ---
/usr/bin/wx-config # CB is using that
/usr/local/bin/wx-config # all terminal windows use this
echo $PATH
.../usr/local/bin;/usr/bin...
--- End code ---
From the terminal I can see what the two versions do. In the C::B build log I can see C::B is using the gkt2 version.
--- Code: ---
/usr/bin/wx-config --cflags resolves to -I/usr/lib/x86_64-linux-gnu/wx/include/gtk2-unicode-3.0 ....
/usr/local/bin/wx-config --cflags resolves to -I/usr/local/lib/wx/include/gtk3-unicode-3.0 ....
--- End code ---
I'd like to understand why C:B is using the first one.
tigerbeard:
Update:
I finally got it compiled with wx3.0 GTK3.
I discoverd the tool Project options manipulator which allows to replace a variable in all projects of a workspace
So I replaced
--- Code: --- WX_CONFIG wx-config --version=$(WX_VERSION)
WX_CONFIG /usr/local/bin/wx-config --version=$(WX_VERSION)
--- End code ---
After that the whole workspace compiled fine and codeblocks starts from within codeblocks, now using the custom compiled wx3.0 GKT3 version.
I still do not understand why C::B ignores my $PATH setting. OF if there are other ways to solve that issue
Navigation
[0] Message Index
[*] Previous page
Go to full version