Author Topic: errors compiling with wxgtk 2.7.1  (Read 7658 times)

xhrit

  • Guest
errors compiling with wxgtk 2.7.1
« on: September 07, 2006, 03:01:11 am »
Using Slackware Linux 10.2, here are the steps I take:

compile wxgtk 2.7.1 in 2.4 compatibility mode

download code::blocks from svn as described in wiki.

export ACLOCAL_FLAGS="-I /home/xhrit/Documents/Code/cpp/wxWidgets-2.7.0-1"

./bootstrap

./configure

./make

compiles fine for a wile, then pops errors in wxscintilla (duplicate case values) - fixed by commenting out 4 lines in ScintillaWX.cpp

./make

compiles fine for a while, then pops a slew ov errors I have no idea how to fix :

In file included from src/propgrid/odcombo.cpp:48:
../../../src/sdk/propgrid/include/wx/propgrid/odcombo.h:478: error: conflicting
   return type specified for `virtual int wxPGOwnerDrawnComboBox::GetCount()
   const'
/usr/local/include/wx-2.7/wx/ctrlsub.h:41: error:   overriding `virtual
   unsigned int wxItemContainerImmutable::GetCount() const'
src/propgrid/odcombo.cpp: In static member function `static wxObject*
   wxPGOwnerDrawnComboBox::wxCreateObject()':
src/propgrid/odcombo.cpp:2240: error: cannot allocate an object of type `
   wxPGOwnerDrawnComboBox'
src/propgrid/odcombo.cpp:2240: error:   because the following virtual functions
   are abstract:
/usr/local/include/wx-2.7/wx/ctrlsub.h:44: error:       virtual wxString
   wxItemContainerImmutable::GetString(unsigned int) const
/usr/local/include/wx-2.7/wx/ctrlsub.h:46: error:       virtual void
   wxItemContainerImmutable::SetString(unsigned int, const wxString&)
/usr/local/include/wx-2.7/wx/ctrlsub.h:121: error:      virtual void
   wxItemContainer::Delete(unsigned int)
/usr/local/include/wx-2.7/wx/ctrlsub.h:140: error:      virtual int
   wxItemContainer::DoInsert(const wxString&, unsigned int)
/usr/local/include/wx-2.7/wx/ctrlsub.h:142: error:      virtual void
   wxItemContainer::DoSetItemClientData(unsigned int, void*)
/usr/local/include/wx-2.7/wx/ctrlsub.h:143: error:      virtual void*
   wxItemContainer::DoGetItemClientData(unsigned int) const
/usr/local/include/wx-2.7/wx/ctrlsub.h:144: error:      virtual void
   wxItemContainer::DoSetItemClientObject(unsigned int, wxClientData*)
/usr/local/include/wx-2.7/wx/ctrlsub.h:145: error:      virtual wxClientData*
   wxItemContainer::DoGetItemClientObject(unsigned int) const



Offline Ceniza

  • Developer
  • Lives here!
  • *****
  • Posts: 1441
    • CenizaSOFT
Re: errors compiling with wxgtk 2.7.1
« Reply #1 on: September 07, 2006, 04:20:36 am »
wxWidgets 2.7.x has some changes that break Code::Blocks' compilation, and you can see that from the errors you got.

We are NOT supporting wxWidgets 2.7 yet, only 2.6, and it seems there's NOT any plans to support it by now.

If you want to compile Code::Blocks, please downgrade to wxWidgets 2.6.

xhrit

  • Guest
Re: errors compiling with wxgtk 2.7.1
« Reply #2 on: September 07, 2006, 04:30:59 am »
hmm. So i take it i can compile codeblocks with 2.6, and then use it to build apps with 2.7?

I ask because the app I am building codeblocks to build uses 2.7.

Offline Game_Ender

  • Lives here!
  • ****
  • Posts: 551
Re: errors compiling with wxgtk 2.7.1
« Reply #3 on: September 07, 2006, 07:15:32 am »
Yes you can build Code::Blocks with 2.6 and then make an App that uses 2.7.  wxWidgets 2.7 is a developer release, and its moves too quickly and is to buggy for a project like Code::Blocks.

xhrit

  • Guest
Re: errors compiling with wxgtk 2.7.1
« Reply #4 on: September 08, 2006, 06:16:55 am »
ok, so i removed wxwidgets 2.7 and installed 2.6 + patch as described in the wiki. (someone should really change the wiki - it said i could use 2.6 *or later*.) Anyway, everything compiles fine for a while... then it pops an error.

In file included from debuggerstate.cpp:2: debuggerstate.h:28: error: `cbProject' was not declared in this scope

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5490
Re: errors compiling with wxgtk 2.7.1
« Reply #5 on: September 08, 2006, 08:14:35 am »
ok, so i removed wxwidgets 2.7 and installed 2.6 + patch as described in the wiki. (someone should really change the wiki - it said i could use 2.6 *or later*.) Anyway, everything compiles fine for a while... then it pops an error.

In file included from debuggerstate.cpp:2: debuggerstate.h:28: error: `cbProject' was not declared in this scope

try again with rev 2959

xhrit

  • Guest
Re: errors compiling with wxgtk 2.7.1
« Reply #6 on: September 08, 2006, 12:16:31 pm »
how do I get rev 2959?

I changed this :

#ifndef CB_PRECOMP
    #include "cbproject.h"
#endif

...to this :

#ifndef CB_PRECOMP
    #include "../sdk/cbproject.h"
#endif

...and then moved it in front the block ov #includes. Then i make again, and it compiled fine for a while. Then it gives me another error.

I ignore it, and just run su make install codeblocks. It works, sorta. On start it displays a notice that some plugins failed to load (every plugin after and including debugger.) And it wont allow a new project or file to be created, only a blank file. It does however compile and run a hello world program if i type one out in a blank file and save as .cpp - then i can press teh compile/run buttons.



Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5490
Re: errors compiling with wxgtk 2.7.1
« Reply #7 on: September 08, 2006, 01:48:45 pm »
well since you got the souces from CB, I guess you are using svn --> svn update

xhrit

  • Guest
Re: errors compiling with wxgtk 2.7.1
« Reply #8 on: September 08, 2006, 11:08:14 pm »
ok, so i did that, and compile again.

gdb_tipwindow.cpp: In member function `wxSize
   GDBTipWindowView::GetTextSize(wxArrayString&, const wxString&, int, int)':
gdb_tipwindow.cpp:365: error: `DBGLOG' undeclared (first use this function)

same error as before. so.. I ignore it again, and just run su make install codeblocks. It works, better then before, but not much. On start it still displays a notice that some plugins failed to load (but lists less plugins, only 3 this time) However, it still will not allow a new project or file to be created.

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5490
Re: errors compiling with wxgtk 2.7.1
« Reply #9 on: September 09, 2006, 01:27:23 am »
ok, so i did that, and compile again.

gdb_tipwindow.cpp: In member function `wxSize
   GDBTipWindowView::GetTextSize(wxArrayString&, const wxString&, int, int)':
gdb_tipwindow.cpp:365: error: `DBGLOG' undeclared (first use this function)

same error as before. so.. I ignore it again, and just run su make install codeblocks. It works, better then before, but not much. On start it still displays a notice that some plugins failed to load (but lists less plugins, only 3 this time) However, it still will not allow a new project or file to be created.


ok, we will fix the dependency tomorrow, for now you can safely comment out that line or you leave the line but then you need to #include "messagemanager.h" and #include "manager.h"

My suggestion : comment it out ;-)


[edit] : committed : rev 2964 (commented out the line)
« Last Edit: September 09, 2006, 01:33:47 am by killerbot »

xhrit

  • Guest
Re: errors compiling with wxgtk 2.7.1
« Reply #10 on: September 10, 2006, 03:14:42 pm »
yeah, that worked.

thanks.