Author Topic: possible bug in compiler/linker options  (Read 3422 times)

Offline spedgenius

  • Single posting newcomer
  • *
  • Posts: 8
possible bug in compiler/linker options
« on: March 05, 2012, 10:37:42 pm »
I have noticed an odd behavior in codeblocks.  I am using v 10.05-1  from the Ubuntu repositories.

I have a configuration bash script that I use to supply -I and -L compiler and linker directives. I call this script in the "build options->compiler settings->other options"  using the name of the bash file `wx-extras`.  while I was writing the script, I had to make numerous changes.   What I noticed was that whenever I made a change to the script that should change the resulting include directory, that change did not appear until I exited and restarted codeblocks.  It is almost as if codeblock caches the expanded form of whatever is used in the settings.  It took me a while to figure out what was going on.  I am wondering if this is intentional behavior.  It is rather annoying to have to restart the IDE every I make a change to a cofiguration script for my source code. Obviously, once I have the script working the way I want, It is a non issue.  Although I occasionally run into the same issue when I have need to switch between versions of wxWidgets.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: possible bug in compiler/linker options
« Reply #1 on: March 05, 2012, 10:42:55 pm »
Hm, why do you need a script for wx widgets, they provide their own config script?

And yes, this caching is by design. I don't like it, too.
I think that it should be cleared if the project is cleaned, but I'm too lazy to track it down and fix it.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline spedgenius

  • Single posting newcomer
  • *
  • Posts: 8
Re: possible bug in compiler/linker options
« Reply #2 on: March 05, 2012, 11:22:58 pm »
it's actually for a group of my own custom widgets and add on classes for wxwidgets.  I use it along side wx-config. 

any thoughts on where to look for the code responsible for the cache?  I might try to track it down if I have the time.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: possible bug in compiler/linker options
« Reply #3 on: March 05, 2012, 11:27:36 pm »
src/plugins/compiler
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline spedgenius

  • Single posting newcomer
  • *
  • Posts: 8
Re: possible bug in compiler/linker options
« Reply #4 on: March 05, 2012, 11:29:11 pm »
thanks

Online Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: possible bug in compiler/linker options
« Reply #5 on: March 05, 2012, 11:56:41 pm »
The caching is done in wxString CompilerCommandGenerator::ExpandBackticks(wxString& str) in src/sdk/compilercommandgenerator.cpp and not in the compiler-plugin.