Results 1 to 2 of 2

Thread: Necessitas: dynamic_cast_will_always_fail / How to set QMAKE_CXXFLAGS

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2012
    Location
    Dortmund, Germany
    Posts
    159
    Thanks
    69
    Thanked 10 Times in 8 Posts
    Qt products
    Qt4
    Platforms
    Windows Android

    Default Necessitas: dynamic_cast_will_always_fail / How to set QMAKE_CXXFLAGS

    Hi, I have set up Necessitas Qt Creator (2.3.1) for Android and I am able to create some little programs.
    With my project I get this error message:

    C:\qtOnAndroid\Kombiversuch-build--Necessitas_Qt_4_8_0_for_Android_armv5_Release\..\. .\necessitas\Android\Qt\480\armeabi\include\QtCore \qglobal.h:2481: error: 'dynamic_cast_will_always_fail_because_rtti_is_dis abled' is not a member of 'QPushButton*'
    I've googled heavily: BogDan himself states, that exceptions and rtti are disabled by default - but they can be switched on with
    Qt Code:
    1. QMAKE_CXXFLAGS += -fexceptions -frtti
    To copy to clipboard, switch view to plain text mode 
    He points to a website for further reading, but I can't see how and where to set the CXXFLAGS, they are not mentioned on that page.

    I've tried adding this line at the beginning of my .pro-file (nothing changes, same error message).

    Then I've tried giving it as a parameter to qmake in Projects|BuildSteps|qmake|Details in the "additional arguments" line.
    This threw the error message:
    ***Unknown option -fexceptions
    The process "c:\necessitas\android\qt\480\armeabi\bin\qmake.ex e" exited with code 1.
    I am aware that I am obviously lacking very basic knowledge about the build process in QtCreator. So please excuse my questions:
    1. How can I set these two flags
    2. Where can I read more to understand the build process better?

    I'd gratefully appreciate any help on this!
    Last edited by sedi; 13th May 2012 at 19:04.

Similar Threads

  1. Necessitas Android Help
    By RENOLD in forum Qt Programming
    Replies: 0
    Last Post: 6th March 2012, 04:51
  2. Qt Necessitas - setFullScreen ?
    By leviribeiro in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 2nd November 2011, 22:56
  3. Necessitas: How to deploy shared library
    By Al_ in forum Qt for Embedded and Mobile
    Replies: 0
    Last Post: 28th August 2011, 15:20
  4. Necessitas Qt for Android issue
    By rickrvo in forum Qt for Embedded and Mobile
    Replies: 3
    Last Post: 8th June 2011, 10:30
  5. Qt for Android. Necessitas
    By freely in forum Newbie
    Replies: 3
    Last Post: 27th May 2011, 18:12

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.