Yes. I have this problem too, as I have reported before at
http://forums.codeblocks.org/index.php/topic,13639.msg92113.html#msg92113
Accidentally I found that I have this problem (thanks to svn , too.
- <Add directory="$(#unittest_pp.include)" />
+ <Add directory="/home/obfuscated/projects/unittest-cpp/UnitTest++/src" />
I'm running dbg branch r6864 on gentoo linux 64bit.
I'm not sure what is causing it... But I think, that I've not edited the changed project.
Edit: I remembered that I've added some files with 'Ctrl + Shift + N', then clicking on the add to project button
OK, I have the steps to reproduce:
1. Close C::B if it is open
2. Double click on a project in explorer/total commander
3. Open a .cpp file and type #include "|<- press ctrl + space
4. Open the build options and you have your global vars broken....
Here is the patch to fix it (extremely annoying... arghhhhhh):
Index: src/plugins/codecompletion/codecompletion.cpp
===================================================================
--- src/plugins/codecompletion/codecompletion.cpp (revision 6942)
+++ src/plugins/codecompletion/codecompletion.cpp (working copy)
@@ -1183,8 +1183,9 @@
{
for (size_t i = 0; i < targets.GetCount(); ++i)
{
- Manager::Get()->GetMacrosManager()->ReplaceMacros(targets[i]);
- wxFileName fn(targets[i], wxEmptyString);
+ wxString includePath = targets[i];
+ Manager::Get()->GetMacrosManager()->ReplaceMacros(includePath);
+ wxFileName fn(includePath, wxEmptyString);
if (fn.IsRelative())
{
const wxArrayString oldDirs = fn.GetDirs();
Index: src/sdk/uservarmanager.cpp
===================================================================
--- src/sdk/uservarmanager.cpp (revision 6942)
+++ src/sdk/uservarmanager.cpp (working copy)
@@ -611,6 +611,9 @@
wxArrayString sets = cfg->EnumerateSubPaths(cSets);
wxArrayString vars = cfg->EnumerateSubPaths(cSets + currentSet + _T("/"));
+ sets.Sort();
+ vars.Sort();
+
selSet->Clear();
selSet->Append(sets);
selVar->Clear();
The reason this breaks is because wxArrayString::operator[] is declared like this:
wxString& operator[](size_t nIndex) const { return Item(nIndex); }
What were they thinking
p.s. I've added sorting to the choice controls in the dialog, because it is annoying, too. Feel free to commit them separately
p.p.s. I'm talking to the wx guys about this... and until this problem is fixed I advise anyone to not use wxArrayString and to check all the code using it, because there is a chance you have hidden bugs in your code...