Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Building C::B with GCC 4.1.0

(1/6) > >>

Michael:
Hello,

I have tried to compile C::B + contrib. plugins with GCC 4.1.0 (from Ceniza) and it worked quite well :D. I got a lot of warnings regarding wxWidgets (I think that Ceniza said already something about this). Especially of this type:


--- Quote ---wx/include/wx/string.h:58: warning: type attributes are honored only at type definition

--- End quote ---

C::B had some of these too.

Several warnings of this type too:


--- Quote ---sdk/propgrid/include/wx/propgrid/propgrid.h:2352: warning: 'class wxPropertyContainerMethods' has virtual functions but non-virtual destructor

--- End quote ---

Some of this type:


--- Quote ---sdk\propgrid\src\propgrid\propgrid.cpp:6804: warning: comparison is always false due to limited range of data type

--- End quote ---

and others, but less frequent.

But I also got errors, e.g.,:


--- Quote ---sdk/manager.h:81: error: extra qualification 'Manager::' on member 'GetConfigManager'
sdk/configmanager.h:195: error: extra qualification 'ConfigManager::' on member 'Write'
sdk/editormanager.h:127: error: extra qualification 'EditorManager::' on member 'GetTree'
sdk/managedthread.h:14: error: extra qualification 'ManagedThread::' on member 'ManagedThread'
sdk/managedthread.h:15: error: extra qualification 'ManagedThread::' on member 'ManagedThread'
sdk/xtra_classes.h:22: error: extra qualification 'wxSplitPanel::' on member 'wxSplitPanel'
sdk/xtra_classes.h:25: error: extra qualification 'wxSplitPanel::' on member 'wxSplitPanel'
sdk/xtra_classes.h:37: error: extra qualification 'wxSplitPanel::' on member 'RefreshSplitter'
sdk/xtra_classes.h:39: error: extra qualification 'wxSplitPanel::' on member 'wxSplitPanel'

--- End quote ---

I have provided a patch to solve them, but I am not sure regarding the following:

Original:


--- Quote ---wxPG_IMPLEMENT_PGMAN_METHOD_NORET1 (SetPropertyValue, const wxPoint&);
wxPG_IMPLEMENT_PGMAN_METHOD_NORET1 (SetPropertyValue, const wxSize&);
wxPG_IMPLEMENT_PGMAN_METHOD_NORET1 (SetPropertyValue, const wxArrayInt&);

--- End quote ---

Solution:


--- Quote ---/*wxPG_IMPLEMENT_PGMAN_METHOD_NORET1*/void SetPropertyValue(const wxPoint&);
/*wxPG_IMPLEMENT_PGMAN_METHOD_NORET1*/void SetPropertyValue(const wxSize&);
/*wxPG_IMPLEMENT_PGMAN_METHOD_NORET1*/void SetPropertyValue(const wxArrayInt&);

--- End quote ---

Anyway, the patch is attached to this post (I prefer to know the opinions of the devs, before posting it to SF (if the devs think it is worth).

Could not be worthy to use GCC 4.1.0 for build C::B instead of the previous versions, e.g., 3.4.5, 3.4.4 and 3.4.2? Or it is too early and could have compatibility problems?

Best wishes,
Michael


[attachment deleted by admin]

killerbot:
propgrid also has this warning with the actual GCC (3.4.4)

I hope your patch get accepted, die warnings die ;-)

Michael:

--- Quote from: killerbot on February 01, 2006, 08:10:41 pm ---I hope your patch get accepted, die warnings die ;-)

--- End quote ---

Unfortunately, the patch just remove the errors :(. I hope anyway. Errors that I find a bit strange. Anyway, I think that some of the warnings could be relatively easy solved (at least the ones in C::B + contrib. plugins). I will work at it :).

Michael

Ceniza:
The "extra qualification" errors are really evil, even more those introduced by the use of macros. I created a post about this issue in the developers forum when I uploaded that version of GCC but it got no attention (at least no about that specific issue).

I'm still waiting for the release of GCC 4.1.0 final, which seems to be pretty close, to provide binaries for it.

Michael:

--- Quote from: Ceniza on February 02, 2006, 01:57:08 am ---The "extra qualification" errors are really evil, even more those introduced by the use of macros. I created a post about this issue in the developers forum when I uploaded that version of GCC but it got no attention (at least no about that specific issue).

--- End quote ---

I will check your post. Yes, those introduced with the macros are probably the worst. I will try if the "solution" that worked for me, still work with a previous GCC version. If yes, I will post a Patch to SF.


--- Quote from: Ceniza on February 02, 2006, 01:57:08 am ---I'm still waiting for the release of GCC 4.1.0 final, which seems to be pretty close, to provide binaries for it.

--- End quote ---

That would be good :D. I think it is possible to use GCC 4.1.0 to clean/improve the code (especially from warnings).

Michael

Navigation

[0] Message Index

[#] Next page

Go to full version