Author Topic: Trunk broken somewhen since r5680  (Read 9706 times)

Offline Mephistopheles

  • Multiple posting newcomer
  • *
  • Posts: 16
Trunk broken somewhen since r5680
« on: July 18, 2009, 10:42:41 pm »
Hello.

I've been providing builds for Fedora, Mandriva and openSUSE for some while which worked like a charm but due to some change since revision 5680 trunk no longer builds for me.

The last log lines are:

Code
/bin/sh ../../../../libtool --tag=CXX   --mode=compile g++ -DHAVE_CONFIG_H -I. -I../../../../src/include -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -pthread -I../../../../src/include -I../../../../src/include/wxscintilla/include -I../../../../src/plugins/contrib/wxSmith -I../../../../src/plugins/contrib/wxSmith/propgrid/contrib/include -I./wxAuiManager -I./wxAuiNotebook -I./wxAuiToolBar -DWXMAKINGLIB_PROPGRID -Ulinux -Uunix  -O2 -ffast-math -DCB_AUTOCONF -march=i586 -mtune=i686 -fmessage-length=0 -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -fexceptions -MT wxsAuiNotebook.lo -MD -MP -MF .deps/wxsAuiNotebook.Tpo -c -o wxsAuiNotebook.lo `test -f './wxAuiNotebook/wxsAuiNotebook.cpp' || echo './'`./wxAuiNotebook/wxsAuiNotebook.cpp
libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I../../../../src/include -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -pthread -I../../../../src/include -I../../../../src/include/wxscintilla/include -I../../../../src/plugins/contrib/wxSmith -I../../../../src/plugins/contrib/wxSmith/propgrid/contrib/include -I./wxAuiManager -I./wxAuiNotebook -I./wxAuiToolBar -DWXMAKINGLIB_PROPGRID -Ulinux -Uunix -O2 -ffast-math -DCB_AUTOCONF -march=i586 -mtune=i686 -fmessage-length=0 -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -fexceptions -MT wxsAuiNotebook.lo -MD -MP -MF .deps/wxsAuiNotebook.Tpo -c ./wxAuiNotebook/wxsAuiNotebook.cpp  -fPIC -DPIC -o .libs/wxsAuiNotebook.o
In file included from ./wxAuiManager/wxsAuiManager.cpp:19:
./wxAuiManager/wxsAuiManager.h: In constructor 'wxsAuiPaneInfoExtra::wxsAuiPaneInfoExtra()':
./wxAuiManager/wxsAuiManager.h:110: warning: 'wxsAuiPaneInfoExtra::m_LastDockDirection' will be initialized after
./wxAuiManager/wxsAuiManager.h:66: warning:   'bool wxsAuiPaneInfoExtra::m_FirstAdd'
./wxAuiManager/wxsAuiManager.h:69: warning:   when initialized here
./wxAuiManager/wxsAuiManager.cpp: In member function 'virtual wxObject* wxsAuiManager::OnBuildPreview(wxWindow*, long int)':
./wxAuiManager/wxsAuiManager.cpp:564: error: 'wxAuiToolBar' was not declared in this scope
./wxAuiManager/wxsAuiManager.cpp:564: error: 'ChildAsToolBar' was not declared in this scope
./wxAuiManager/wxsAuiManager.cpp:564: error: expected primary-expression before ')' token
./wxAuiManager/wxsAuiManager.cpp:564: error: expected `)' before 'wxCheckDynamicCast'
./wxAuiManager/wxsAuiManager.cpp: In member function 'virtual void wxsAuiManager::OnAddChildQPP(wxsItem*, wxsAdvQPP*)':
./wxAuiManager/wxsAuiManager.cpp:669: error: 'wxAuiToolBar' was not declared in this scope
./wxAuiManager/wxsAuiManager.cpp:669: error: expected primary-expression before ')' token
./wxAuiManager/wxsAuiManager.cpp:669: error: expected `)' before 'wxCheckDynamicCast'
./wxAuiManager/wxsAuiManager.cpp:684: error: expected `)' before '}' token
./wxAuiManager/wxsAuiManager.cpp:684: error: expected primary-expression before '}' token
./wxAuiManager/wxsAuiManager.cpp:684: error: expected `;' before '}' token
make[4]: *** [wxsAuiManager.lo] Error 1
make[4]: *** Waiting for unfinished jobs....
In file included from ./wxAuiManager/wxsAuiManagerParentQP.h:34,
                 from ./wxAuiManager/wxsAuiManagerParentQP.cpp:19:
./wxAuiManager/wxsAuiManager.h: In constructor 'wxsAuiPaneInfoExtra::wxsAuiPaneInfoExtra()':
./wxAuiManager/wxsAuiManager.h:110: warning: 'wxsAuiPaneInfoExtra::m_LastDockDirection' will be initialized after
./wxAuiManager/wxsAuiManager.h:66: warning:   'bool wxsAuiPaneInfoExtra::m_FirstAdd'
./wxAuiManager/wxsAuiManager.h:69: warning:   when initialized here
mv -f .deps/wxsAuiNotebook.Tpo .deps/wxsAuiNotebook.Plo
mv -f .deps/wxsAuiManagerParentQP.Tpo .deps/wxsAuiManagerParentQP.Plo
make[4]: Leaving directory `/usr/src/packages/BUILD/codeblocks/src/plugins/contrib/wxSmithAui'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/usr/src/packages/BUILD/codeblocks/src/plugins/contrib'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/src/packages/BUILD/codeblocks/src/plugins'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/packages/BUILD/codeblocks/src'
make: *** [all-recursive] Error 1

Partial build log is attached (trying to build current trunk - r5695. Same problem with r5692, so it must be some change after r5680 and before r5692). If you want the full log please let me know how to provide it since I'm not allowed to upload zipped files and the raw one is too big.

Please be so kind to have a look at it because I'm kinda lost with it.

[attachment deleted by admin]

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: Trunk broken somewhen since r5680
« Reply #1 on: July 19, 2009, 12:21:52 am »
The warning is no problem and can be easily fixed.

Which version of wxWidgets do you use (or is used by the build-system) ?

If I see it correctly wxAuiToolbar was added in wx2.8.9 and can (of course) not be used before.

So we have to put into version-guards or whatever.

It's a little late for a quick fix no.

For the moment I suggest to build without wxSmithAui:

Code
configure --with-contrib-plugins=all,-wxsmithaui

should do it.

Sorry for the inconvenience.

Offline Mephistopheles

  • Multiple posting newcomer
  • *
  • Posts: 16
Re: Trunk broken somewhen since r5680
« Reply #2 on: July 19, 2009, 10:46:24 pm »
Thanks a lot for the fast response, even more since I was missing the obvious :D

I fixed it for the moment with some if else in the .spec, nevertheless some version checks & bitching during configure would be great and probably would spare you some questions.

JFYI, we build against the original distro versions which are:
Code
Fedora_9  wxGTK-2.8.7-2.fc9
Fedora_10 wxGTK-2.8.9-1.fc10
Fedora_11 wxGTK-2.8.10-1.fc11

Mandriva_2008 wxgtk2.8-2.8.4-3mdv2008.0
Mandriva_2009 wxgtk2.8-2.8.8-1mdv2009.0

SLE_11 wxGTK-2.8.8.1-1.36

openSUSE_10.3 wxGTK-2.8.4.0-53
openSUSE_11.0 wxGTK-2.8.7.1-23.1
openSUSE_11.1 wxGTK-2.8.8.1-1.48
openSUSE_Factory wxGTK-2.8.9.1-3.1
So this will only work on Fedora 10 & 11 without updated wxGTK / wxWidgets.

One more thing since I'm posting anyways: The automated code checks warned about the following:
Code
I: Program is likely to break with new gcc. Try -fno-strict-aliasing.
W: codeblocks strict-aliasing-punning ../../../../src/include/scripting/sqplus/sqplus.h:420, 1801
W: codeblocks strict-aliasing-punning sqcompiler.cpp:652
W: codeblocks strict-aliasing-punning sqstdblob.cpp:160, 168
W: codeblocks strict-aliasing-punning sqstdsystem.cpp:55
W: codeblocks strict-aliasing-punning sqvm.cpp:712
Dunno if those are false positives or not but perhaps you might want to have a look at them.

Thanks once again for your help :)

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: Trunk broken somewhen since r5680
« Reply #3 on: July 20, 2009, 12:20:23 am »
I think version-guards in the code might be better, because they would only hide the wxAuiToolbar-related code.

But I'm not sure if it can be easily done (it's not "my" plugin), nevertheless, I will have a look into it.

The strict-aliasing-warnings can (hopefully) be ignored at the moment, but they should of course not be here.

I hope I find the time next week to remove some (all) of them.

Offline Mephistopheles

  • Multiple posting newcomer
  • *
  • Posts: 16
Re: Trunk broken somewhen since r5680
« Reply #4 on: July 20, 2009, 04:29:34 am »
I think version-guards in the code might be better, because they would only hide the wxAuiToolbar-related code.

But I'm not sure if it can be easily done (it's not "my" plugin), nevertheless, I will have a look into it.

That sounds great, could you please be so kind to write me a PM or poke me somehow when you managed to do this so I can reenable the plugin for those builds?

Regarding the general stuff I probably was too optimistic cause builds for Mandriva 2008, 2009 and openSUSE 10.3 are still failing with stuff like

Code
 i586-mandriva-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I../../src/include -I/usr/lib/wx/include/ -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -pthread -I../../src/include -I../../src/include/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 -O2 -pipe -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fexceptions -fomit-frame-pointer -march=i586 -mtune=generic -fasynchronous-unwind-tables -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -fexceptions -MT editormanager.lo -MD -MP -MF .deps/editormanager.Tpo -c editormanager.cpp -fPIC -DPIC -o .libs/editormanager.o
editormanager.cpp:137: error: 'EVT_AUINOTEBOOK_TAB_RIGHT_UP' was not declared in this scope
editormanager.cpp:138: error: expected `}' before 'wxEventTableEntry'
editormanager.cpp:138: error: expected ',' or ';' before 'wxEventTableEntry'
editormanager.cpp:151: error: expected declaration before '}' token
make[3]: *** [editormanager.lo] Error 1

Full build logs are available at:

Probably unrelated to that builds for openSUSE Factory (currently coming 11.2) fail with http://pastebin.be/19858.

Please be so kind to have a look at them as well. I'll be happy to try any patches against current trunk :)

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: Trunk broken somewhen since r5680
« Reply #5 on: July 20, 2009, 10:47:27 am »
Regarding the general stuff I probably was too optimistic cause builds for Mandriva 2008, 2009 and openSUSE 10.3 are still failing with stuff like

Code
 i586-mandriva-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I../../src/include -I/usr/lib/wx/include/ -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -pthread -I../../src/include -I../../src/include/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 -O2 -pipe -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fexceptions -fomit-frame-pointer -march=i586 -mtune=generic -fasynchronous-unwind-tables -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -fexceptions -MT editormanager.lo -MD -MP -MF .deps/editormanager.Tpo -c editormanager.cpp -fPIC -DPIC -o .libs/editormanager.o
editormanager.cpp:137: error: 'EVT_AUINOTEBOOK_TAB_RIGHT_UP' was not declared in this scope
editormanager.cpp:138: error: expected `}' before 'wxEventTableEntry'
editormanager.cpp:138: error: expected ',' or ';' before 'wxEventTableEntry'
editormanager.cpp:151: error: expected declaration before '}' token
make[3]: *** [editormanager.lo] Error 1

This might be because of many changes/improvements to wxAuiNotebook in wx2.8.5. As you wrote openSUSE 10.3 and Mandriva 2008 use 2.8.4 .
The problem is, that C::B uses wxAuiNotebook instead of wxFlatNotebook for almost all notebooks now (except from notebooks in config-dialogs).
I think a backport is not possible with a reasonable amount of work:
Quote from: wxWidgets-changes for 2.8.5
- Added tab mouse click events to wxAuiNotebook (Ben Williams).
- Option for middle-click tab close in wxAuiNotebook (Ben Williams).
- Added wxAuiNotebook::SetFont, GetTabCtrlHeight, GetHeightForPageHeight.
[...]
- Added AdvanceSelection, ShowWindowMenu functions and keyboard handling to
  wxAuiNotebook.
- Added wxAUI_NB_SUPPORT for standard wxAuiNotebook art (Langhammer).
- Added event for double clicks on wxAuiNotebook tab background.
- Added events for wxAuiNotebook tab dragging and closing notification.
[...]
- Fixed a wxTabFrame leak by deleting all wxAuiNotebook pages in the destructor.

If I find a solution for the other issues I will post them here.

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: Trunk broken somewhen since r5680
« Reply #6 on: July 21, 2009, 08:16:03 pm »
Hi,

It would be nice, if you can test the attached patch.

It should fix the undefined references in wxSmithContribItems and the wxAuiToolbar problem.

If it works, I will commit it.

As I wrote before, there's no fix for OS10.3 and Mandriva 2008, because reverting to wxFlatNotebook is not an option.
For these two, the last revision that should work is svn r5681.

[attachment deleted by admin]

Offline Mephistopheles

  • Multiple posting newcomer
  • *
  • Posts: 16
Re: Trunk broken somewhen since r5680
« Reply #7 on: July 23, 2009, 05:23:04 pm »
It would be nice, if you can test the attached patch.

It should fix the undefined references in wxSmithContribItems and the wxAuiToolbar problem.

If it works, I will commit it.

Sorry, I'm not sure if I got you right. As far as I understood you that patch is supposed to solve the issue from the very first post so I don't need some if else stuff in my .spec to compile some versions with "--with-contrib-plugins=all,-wxsmithaui", right?

If so it sadly doesn't work. The error still is the exact same and the full build log for openSUSE 11.1 can be seen here (applied cleanly against r5695).

As I wrote before, there's no fix for OS10.3 and Mandriva 2008, because reverting to wxFlatNotebook is not an option.
For these two, the last revision that should work is svn r5681.

That's fine, I just wanted to ensure that it isn't me who's screwing it up.

If you find the time to come up with another patch I'll happily play the guinea pig but, as you saw, it can take a few days due to a lack of time atm.

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: Trunk broken somewhen since r5680
« Reply #8 on: July 23, 2009, 06:17:05 pm »
Sorry, I'm not sure if I got you right. As far as I understood you that patch is supposed to solve the issue from the very first post so I don't need some if else stuff in my .spec to compile some versions with "--with-contrib-plugins=all,-wxsmithaui", right?

Yes.

Here comes another patch.

[attachment deleted by admin]

Offline Mephistopheles

  • Multiple posting newcomer
  • *
  • Posts: 16
Re: Trunk broken somewhen since r5680
« Reply #9 on: July 23, 2009, 08:49:06 pm »
Great one! That patch fixed all builds except Mandriva 2008 & openSUSE 10.3 which wont work anyways as stated. Thanks for that :)

Now we are down to the strict-aliasing warnings:
Code
I: Program is likely to break with new gcc. Try -fno-strict-aliasing.
W: codeblocks strict-aliasing-punning ../../../../src/include/scripting/sqplus/sqplus.h:420, 1801
W: codeblocks strict-aliasing-punning sqcompiler.cpp:652
W: codeblocks strict-aliasing-punning sqstdblob.cpp:160, 168
W: codeblocks strict-aliasing-punning sqstdsystem.cpp:55
W: codeblocks strict-aliasing-punning sqvm.cpp:712

and openSUSE Factory / 11.2 failing with http://pastebin.be/19858