Hi All,
I've found that after updating past r8564, the keybinder plugin is not compiling anymore. The error is
..\..\..\.objs\plugins\contrib\keybinder\cbkeybinder.o: In function `ZN11cbKeyBinder21MergeAcceleratorTableEb':
C:/Work/codeblocks_trunk/src/plugins/contrib/keybinder/cbkeybinder.cpp:856: undefined reference to `GetFullMenuPath(int)'
..\..\..\.objs\plugins\contrib\keybinder\keybinder.o: In function `ZNK5wxCmd4SaveEP12wxConfigBaseRK8wxStringb':
C:/Work/codeblocks_trunk/src/plugins/contrib/keybinder/keybinder.cpp:696: undefined reference to `GetFullMenuPath(int)'
I've track the problem to the anonymous namespace introduced in menuutils.cpp, line 137, which causes the function GetFullMenuPath() (and FindMenuIdUsingFullMenuPath()) to be "local" to menuutils.cpp
namespace
{
// ----------------------------------------------------------------------------
wxString GetFullMenuPath(int id)
// ----------------------------------------------------------------------------
{ ...
...
The change was made in 8563 (Killerbot).
It indeed will not compile.
What's up Killer?
Also, in commit 8561 a bug slipped in projectconfigurationpanel.cpp:
for ( size_t i=0; i<Categories.Count(); i++ )
became
for ( size_t cat = 0; cat < Categories.Count(); cat )
The ++ operator was missed, so the loop never ends.
Great fun ;D
Quote from: mgimenez on November 15, 2012, 05:09:05 PM
Also, in commit 8561 a bug slipped in projectconfigurationpanel.cpp:
for ( size_t i=0; i<Categories.Count(); i++ )
became
for ( size_t cat = 0; cat < Categories.Count(); cat )
The ++ operator was missed, so the loop never ends.
fixed
Quote from: daniloz on November 15, 2012, 09:41:27 AM
Hi All,
I've found that after updating past r8564, the keybinder plugin is not compiling anymore. The error is
..\..\..\.objs\plugins\contrib\keybinder\cbkeybinder.o: In function `ZN11cbKeyBinder21MergeAcceleratorTableEb':
C:/Work/codeblocks_trunk/src/plugins/contrib/keybinder/cbkeybinder.cpp:856: undefined reference to `GetFullMenuPath(int)'
..\..\..\.objs\plugins\contrib\keybinder\keybinder.o: In function `ZNK5wxCmd4SaveEP12wxConfigBaseRK8wxStringb':
C:/Work/codeblocks_trunk/src/plugins/contrib/keybinder/keybinder.cpp:696: undefined reference to `GetFullMenuPath(int)'
I've track the problem to the anonymous namespace introduced in menuutils.cpp, line 137, which causes the function GetFullMenuPath() (and FindMenuIdUsingFullMenuPath()) to be "local" to menuutils.cpp
namespace
{
// ----------------------------------------------------------------------------
wxString GetFullMenuPath(int id)
// ----------------------------------------------------------------------------
{ ...
...
OK found the cause, man this was very hacky code, good it became apparent now, however for me everything builded fine (and it still does, even after make clean).
But indeed in :
cbKeybinder.cpp
keybinder.cpp
magically they are aware of some method living somewhere dirty dirty) :
extern wxString GetFullMenuPath(int);
Now this is nicely exported in the header.
EDIT : now idea why it builds for me (CB build and makefiles, could it be those pch's again ?)