ive been getting the following error trying to build any recent (as in any build from the last couple of months) build.
../../src/include/toolsmanager.h:41: error: 'class ToolsList::Node' has not been declared
Its using wxGTK 2.8 built with X gif gnome joystick opengl sdl stl unicode support using GCC x86_64-pc-linux-gnu-4.2.0
Theres one mention of it in the forums http://forums.codeblocks.org/index.php/topic,5928.msg45367.html#msg45367 but no one ever helped the person so im guessing it was never resolved.
Submitted patch "wxList related patch to help compile with STL wxWidgets"
http://developer.berlios.de/patch/?func=detailpatch&patch_id=2161&group_id=5358
https://developer.berlios.de/patch/download.php?id=2161
Note: I gave up patching the STL related errors when I got to the SDK Scripting (Squirrel SqPlus) section of code. I really have problems understanding that code.
Tim S
Misc patches that are not ready for submitting to Code::Blocks; no plan to make them ready.
Index: src/sdk/cbproject.cpp
===================================================================
--- src/sdk/cbproject.cpp (revision 4413)
+++ src/sdk/cbproject.cpp (working copy)
@@ -702,9 +702,9 @@
return RemoveFile(f);
}
-int filesSort(const ProjectFile** arg1, const ProjectFile** arg2)
+int filesSort(const void* arg1, const void* arg2)
{
- return (*arg1)->file.GetFullPath().CompareTo((*arg2)->file.GetFullPath());
+ return ((ProjectFile*)arg1)->file.GetFullPath().CompareTo(((ProjectFile*)arg2)->file.GetFullPath());
}
void cbProject::BuildTree(wxTreeCtrl* tree, const wxTreeItemId& root, bool categorize, bool useFolders, FilesGroupsAndMasks* fgam)
Index: src/sdk/compilercommandgenerator.cpp
===================================================================
--- src/sdk/compilercommandgenerator.cpp (revision 4413)
+++ src/sdk/compilercommandgenerator.cpp (working copy)
@@ -905,7 +905,7 @@
DBGLOG(_T("Cached"));
}
ret << bt << _T(' ');
- str = str.substr(0, start) + bt + str.substr(end + 1, wxString::npos);
+ str = str.substr(0, start).append(bt.append(str.substr(end + 1, wxString::npos)));
// find next occurrence
start = str.find(_T('`'));
Index: src/sdk/scripting/bindings/sc_util_dialogs.cpp
===================================================================
--- src/sdk/scripting/bindings/sc_util_dialogs.cpp (revision 4413)
+++ src/sdk/scripting/bindings/sc_util_dialogs.cpp (working copy)
@@ -69,7 +69,7 @@
EditArrayOrderDlg* dlg = 0;
if (sa.GetParamCount() == 1)
- dlg = new EditArrayOrderDlg(0);
+ dlg = new EditArrayOrderDlg((wxWindow*)0, wxArrayString());
else if (sa.GetParamCount() == 2)
dlg = new EditArrayOrderDlg(0, *SqPlus::GetInstance<wxArrayString>(v, 2));
else
Index: src/sdk/toolsmanager.cpp
===================================================================
--- src/sdk/toolsmanager.cpp (revision 4413)
+++ src/sdk/toolsmanager.cpp (working copy)
Index: src/sdk/configmanager.cpp
===================================================================
--- src/sdk/configmanager.cpp (revision 4413)
+++ src/sdk/configmanager.cpp (working copy)
@@ -286,9 +286,10 @@
{
size_t size = is->GetSize();
wxString str;
- wxChar* c = str.GetWriteBuf(size);
+ // wxChar* c = str.GetWriteBuf(size);
+ wxChar* c = (wxChar*)wxStringBuffer(str, size);
is->Read(c, size);
- str.UngetWriteBuf(size);
+ // str.UngetWriteBuf(size);
doc = new TiXmlDocument();
I hope I will not annoy you with a resolved problem, but I also have this error, on Debian (testing with some sid and experimental)
Here the full log:
$ make -j 5
Making all in src
make[1]: entrant dans le répertoire « /home/berenger/prj/codeblocks/src »
Making all in include
make[2]: entrant dans le répertoire « /home/berenger/prj/codeblocks/src/include »
rm -f ../../src/include/sdk_precomp.h.gch
g++ -DHAVE_CONFIG_H -I/usr/local/lib/wx/include/gtk2-unicode-2.9 -I/usr/local/include/wx-2.9 -D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -pthread -I../../src/include -I../../src/sdk/wxscintilla/include -I../../src/include/tinyxml -I../../src/include/scripting/include -I../../src/include/scripting/sqplus -I../../src/include/mozilla_chardet -Ulinux -Uunix -O2 -ffast-math -DCB_AUTOCONF -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -fexceptions -o ../../src/include/sdk_precomp.h.gch -xc++-header ./sdk_precomp.h
In file included from ./sdk_common.h:43:0,
from ./sdk_precomp.h:13:
./prep.h: In member function ‘ID::operator void*() const’:
./prep.h:333:45: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
In file included from ./sdk_common.h:136:0,
from ./sdk_precomp.h:13:
./toolsmanager.h: At global scope:
./toolsmanager.h:46:32: error: ‘ToolsList::Node’ has not been declared
make[2]: *** [../../src/include/sdk_precomp.h.gch] Erreur 1
make[2]: quittant le répertoire « /home/berenger/prj/codeblocks/src/include »
make[1]: *** [all-recursive] Erreur 1
make[1]: quittant le répertoire « /home/berenger/prj/codeblocks/src »
make: *** [all-recursive] Erreur 1
I followed the instructions in BUILD file, and http://wiki.codeblocks.org/index.php?title=Category:Installing_Code::Blocks_from_source (which are basically the same) for compilation.
To install dependencies, I simply have jens' repo in my sources.list, and used "aptitude build-dep codeblocks".
On debian, there is only one wxWidgets package for dev, and I do not know which compilation options were used. And I do not really want to play again with all the flags they use for compiling (had enough problems with a personal project, before trying to use jens' version of 1.9.4. Thanks a lot for your work jens.)
I also have to admit I did not investigate more than that, I only wanted to compile myself to confirm the closure of the crash issue on wxSmith as Danselmi asked me to do.
If there is a known solution, I suggest to update the BUILD instructions.