Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. How to configure debug and release builds?
QtWS25 Last Chance

How to configure debug and release builds?

Scheduled Pinned Locked Moved Solved Qt Creator and other tools
vs 2013compilerparametersdebugrelease
4 Posts 2 Posters 4.4k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • W Offline
    W Offline
    Wodzu
    wrote on 11 Sept 2016, 14:01 last edited by Wodzu 9 Nov 2016, 18:22
    #1

    Hi,

    currently I am using Visual Studio 2013 as a compiler and Qt Creator 4.1 as an IDE. I've spotted differences in my math project depending whether I am using debug build or release build. So now I am trying to find an option in Qt Creator which is responsible for passing parameters to VS compiler.

    In Projects / Build Settings I see the configurations for debug and release but I don't see the exact parameters that are passed to MSVC2013. Could someone explain me how can I see what are the exact parameters passed to compiler and how can I change them? For example how to turn on or off the optimization or how to change floating point model?

    Just for your information, I've tried to find this information in Qt's manual, for example here: http://doc.qt.io/qtcreator/creator-build-settings.html

    Thank you for your time.

    As above so below...

    1 Reply Last reply
    0
    • N Offline
      N Offline
      Naahmi
      wrote on 11 Sept 2016, 18:43 last edited by
      #2

      Hi, you can wrote in your .pro file

      Qt Creator passed CONFIG+=debug to qmake and in the Makefile you can see the /DEBUG flag.

      For turning off optimization add in your .pro file:

      QMAKE_CXXFLAGS_RELEASE -= -O2
      QMAKE_CXXFLAGS_RELEASE += -Os
      
      W 1 Reply Last reply 11 Sept 2016, 18:52
      0
      • N Naahmi
        11 Sept 2016, 18:43

        Hi, you can wrote in your .pro file

        Qt Creator passed CONFIG+=debug to qmake and in the Makefile you can see the /DEBUG flag.

        For turning off optimization add in your .pro file:

        QMAKE_CXXFLAGS_RELEASE -= -O2
        QMAKE_CXXFLAGS_RELEASE += -Os
        
        W Offline
        W Offline
        Wodzu
        wrote on 11 Sept 2016, 18:52 last edited by
        #3

        Thank you,

        so analogically, if I would want to add another parameter I would do:

        QMAKE_CXXFLAGS_RELEASE += fp:precise
        

        Is that correct?

        As above so below...

        1 Reply Last reply
        0
        • W Offline
          W Offline
          Wodzu
          wrote on 14 Sept 2016, 10:31 last edited by
          #4

          Ok, I've found that the results are stored in files Makefile.Release, Makefile.Debug and everything is explained here.

          As above so below...

          1 Reply Last reply
          0

          2/4

          11 Sept 2016, 18:43

          • Login

          • Login or register to search.
          2 out of 4
          • First post
            2/4
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved