dynamic_casts fail on OSX



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 01/06/2010 at 05:53, xxxxxxxx wrote:

    User Information:
    Cinema 4D Version:   11.5 
    Platform:      Mac OSX  ; 
    Language(s) :     C++  ;

    ---------
    Hi,

    we recently tried to compile our plugin using the C4D 11 SDK. On windows this worked without problems, on OSX though there are strange things happening now:

    I was able to compile and link everything without problems, when opening the plugin in C4D though, the program crashed. C4D crash report told me that a dynamic_cast failed. I checked the XCODE project settings and found out that "Enable C++ runtime type information" was disabled. I enabled this and recompiled - now linking fails, giving error messages like:

    "typeinfo fo GeModalDialog", referenced from:
    typeinfo for AboutDialog MainDialog.o
    .
    .
    .
    symbol(s) not found

    Am I doing something completely wrong here? The code used to compile using 10.5 SDK without problems before...

    Any ideas?

    Many thanks

    Markus



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 01/06/2010 at 06:06, xxxxxxxx wrote:

    you really need to give more information about the classes involved and a little bit of code. Is the base class virtual? So is it really polymorphic?



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 01/06/2010 at 14:53, xxxxxxxx wrote:

    Just a guess: This error looks as if the API library has not been recompiled with rtti enabled. (only the actual plugin library, so it fails to link with the non-rtti api lib)



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 02/06/2010 at 01:46, xxxxxxxx wrote:

    Hi,

    many thanks for your answers :)

    Actually that was exactly what was happening (found that out yesterday but forgot to post an update here) :

    I was under the assumption that the build options for my project propagated to the embedded _api project - they didn't. I enabled rtti in the api project, recompiled, all is well now ;)

    Thanks

    Markus


Log in to reply