User forums > Help

r9741 compile error with wx3.0 on Windows

(1/2) > >>

gd_on:
When trying to compile C::B svn 9741 with wxwidgets 3.0, using CodeBlocks_wx30.workspace (full rebuild), I obtain a compile error in cbplugin.cpp, more precisely in ccmanager.h line 94 (no problems with wxwidgets 2.8.12 in 32 or 64 bits) :

--- Code: ----------------- Générer : sdk dans Code::Blocks wx3.0.x (compilateur : GNU GCC Compiler)---------------

mingw32-g++.exe -Wall -O -pipe -mthreads -fmessage-length=0 -fexceptions -DHAVE_W32API_H -D__WXMSW__ -DWXUSINGDLL -DcbDEBUG -DNOPCH -DwxUSE_UNICODE -Woverloaded-virtual -DEXPORT_LIB -DEXPORT_EVENTS -DWXMAKINGDLL_SCI -IC:\wxWidgets-3.0.0\include -IC:\wxWidgets-3.0.0\lib\gcc_dll\mswu -Isdk\wxscintilla\include -Iinclude\tinyxml -Iinclude -Iinclude\tinyxml -Iinclude\scripting\bindings -Iinclude\scripting\include -Iinclude\scripting\sqplus -Iinclude\mozilla_chardet -Iinclude\mozilla_chardet\mfbt -Iinclude\mozilla_chardet\nsprpub\pr\include -Iinclude\mozilla_chardet\xpcom -Iinclude\mozilla_chardet\xpcom\base -Iinclude\mozilla_chardet\xpcom\glue -c D:\gdurand.ONL\Documents\00_svn_CodeBlocks\CodeBlocks_src\trunk\src\sdk\configmanager-revision.cpp -o .objs30\sdk\configmanager-revision.o
...

mingw32-g++.exe -Wall -O -pipe -mthreads -fmessage-length=0 -fexceptions -DHAVE_W32API_H -D__WXMSW__ -DWXUSINGDLL -DcbDEBUG -DNOPCH -DwxUSE_UNICODE -Woverloaded-virtual -DEXPORT_LIB -DEXPORT_EVENTS -DWXMAKINGDLL_SCI -IC:\wxWidgets-3.0.0\include -IC:\wxWidgets-3.0.0\lib\gcc_dll\mswu -Isdk\wxscintilla\include -Iinclude\tinyxml -Iinclude -Iinclude\tinyxml -Iinclude\scripting\bindings -Iinclude\scripting\include -Iinclude\scripting\sqplus -Iinclude\mozilla_chardet -Iinclude\mozilla_chardet\mfbt -Iinclude\mozilla_chardet\nsprpub\pr\include -Iinclude\mozilla_chardet\xpcom -Iinclude\mozilla_chardet\xpcom\base -Iinclude\mozilla_chardet\xpcom\glue -c D:\gdurand.ONL\Documents\00_svn_CodeBlocks\CodeBlocks_src\trunk\src\sdk\cbstatusbar.cpp -o .objs30\sdk\cbstatusbar.o
In file included from D:\gdurand.ONL\Documents\00_svn_CodeBlocks\CodeBlocks_src\trunk\src\sdk\cbplugin.cpp:39:0:
include/ccmanager.h:94:9: error: 'wxListView' does not name a type
         wxListView* m_pAutocompPopup;
         ^
Le processus s'est terminé avec le code d'état 1 (0 minute(s), 47 seconde(s))
 
Le processus s'est terminé avec le code d'état 0 (0 minute(s), 51 seconde(s))
1 erreur(s), 8 avertissement(s) (0 minute(s), 51 seconde(s))


--- End code ---

Here are the lines in ccmanager.h:

--- Code: ---92         wxPoint m_DocPos;
93 #ifdef __WXMSW__
94         wxListView* m_pAutocompPopup;
95 #endif // __WXMSW__
96         cbEditor* m_pLastEditor;

--- End code ---

as far as I know, I have generated wxWidgets 3.0 as indicated in the wiki, with tdm 4.8.1 mingw 32 version.

gd_on

joinAero:
Not forward declaration for class wxListView.

ccmanager.h:


--- Code: ---16 class UnfocusablePopupWindow;
17 class wxHtmlLinkEvent;
18 class wxHtmlWindow;
19 class wxListEvent;
20 class wxListView;  // Added
21 class wxScintillaEvent;

--- End code ---

gd_on:
adding this line n° 20, solve this specific problem apparently, but there is an other one when linking codeblocks.dll some time after in the compilation process.
So, this patch is not sufficient (at least for me !). sorry.

gd_on

stahta01:

--- Quote from: joinAero on March 17, 2014, 02:22:04 pm ---Not forward declaration for class wxListView.

--- End quote ---

A patch doing your fix; still compiling CB core project using wxWidgets 3.0 on windows 32 bit (CodeBlocks_wx30.cbp).


--- Code: ---Index: src/include/ccmanager.h
===================================================================
--- src/include/ccmanager.h (revision 9741)
+++ src/include/ccmanager.h (working copy)
@@ -17,6 +17,7 @@
 class wxHtmlLinkEvent;
 class wxHtmlWindow;
 class wxListEvent;
+class wxListView;
 class wxScintillaEvent;
 
 class DLLIMPORT CCManager : public Mgr<CCManager>, wxEvtHandler

--- End code ---

Edit: The CB SDK compiled without error.
Edit2: Finished building CodeBlocks_wx30.cbp without error.

Tim S.

Alpha:

--- Quote from: gd_on on March 17, 2014, 07:10:27 pm ---adding this line n° 20, solve this specific problem apparently, but there is an other one when linking codeblocks.dll some time after in the compilation process.
So, this patch is not sufficient (at least for me !). sorry.

--- End quote ---
Could you post the error message please?


--- Quote from: stahta01 on March 17, 2014, 08:01:34 pm ---Edit2: Finished building CodeBlocks_wx30.cbp without error.

--- End quote ---
Adding this forward declare, CodeBlocks_wx30_64.cbp builds for me.

Navigation

[0] Message Index

[#] Next page

Go to full version