cannot use typeid with -fno-rtti

3 views
Skip to first unread message

Nerijus Baliunas

unread,
Nov 21, 2009, 1:37:20 PM11/21/09
to wx-...@googlegroups.com
Hello,

When I compile Mahogany with latest wx trunk, I get:

wxWidgets/include/wx/event.h: In member function
'virtual bool wxObjectEventFunctor::IsMatching(const wxEventFunctor&) const':
wxWidgets/include/wx/event.h:239: error: cannot use typeid with -fno-rtti

Rev 62690 is still bad, 62689 good.

Regards,
Nerijus

Jaakko Salli

unread,
Nov 21, 2009, 1:55:28 PM11/21/09
to wx-...@googlegroups.com

Hi,

The code on that line should not actually use typeid()
if C++ RTTI is disabled. However, for this to work
wxNO_RTTI has to be properly defined by wxWidgets
(as documentation suggest would be the case).

I just made a quick search through the headers and
unfortunately found no place where wxNO_RTTI was
actually defined.

Regards,
Jaakko

Vadim Zeitlin

unread,
Nov 22, 2009, 6:24:53 AM11/22/09
to wx-...@googlegroups.com
On Sat, 21 Nov 2009 20:55:28 +0200 Jaakko Salli <jaakko...@dnainternet.net> wrote:

JS> I just made a quick search through the headers and
JS> unfortunately found no place where wxNO_RTTI was
JS> actually defined.

It's defined in build/msw/makefile.* but this obviously doesn't help when
using configure. I've just checked in r62698 which should fix this by
adding detection of RTTI for g++ and MSVC to wx/platform.h itself.

Regards,
VZ

Reply all
Reply to author
Forward
0 new messages