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. Debug vs release targets

Debug vs release targets

Scheduled Pinned Locked Moved Qt Creator and other tools
7 Posts 4 Posters 3.6k 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.
  • D Offline
    D Offline
    daviddoria
    wrote on last edited by
    #1

    I'm using QtCreator for the first time. I read here http://doc.qt.nokia.com/qtcreator-2.4/creator-build-settings.html that "By default, Qt Creator creates debug and release build configurations.", but when I go into "Build Settings", I only see an "all" build, and I don't see any option of whether it is debug or release?

    I tried using the Add drop down to create a new build, but I still was not given an option to use Debug or Release.

    In fact, at the top of the "Projects" tab, I do not see a "Targets" tab as there is in that screenshot, I only have "Build Settings", "Run Settings", "Editor Settings", "Code Style Settings", and "Dependencies."

    One last thing - if I click "Details" under Build Steps -> Make, I see a list of the targets, but they are all unchecked. However, when I build the project, some of them build. Can anyone explain that?

    My QtCreator project was created by opening an existing CMakeLists.txt file.

    Thanks in advance!

    David

    1 Reply Last reply
    0
    • sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      So your project is based on CMake. I cannot say much there, as it's not really my area, but the documentation is written for QMake projects. There is a support for CMake, but probably there are some differences, and that is why you might lack some options.

      Try some QMake projects (Qt Examples are a good start, or a new project in Qt Creator - it provides some ready-made templates that make it all easier for beginners).

      (Z(:^

      1 Reply Last reply
      0
      • D Offline
        D Offline
        daviddoria
        wrote on last edited by
        #3

        I found that if (outside of QtCreator) in a normal terminal I run ccmake in the build directory and change the CMAKE_BUILD_TYPE to DEBUG, then configure and generate, then go back to QtCreator and rebuild, that the build mode is switched. Though it works, this seems really awkward. Can anyone confirm that this is the only way to do this?

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mlong
          wrote on last edited by
          #4

          So if you click on the Build Target button (above the green "play arrow" run button in the lower-left corner) do you only have one option?

          Software Engineer
          My views and opinions do not necessarily reflect those of anyone -- living or dead, real or fictional -- in this universe or any other similar multiverse node. Void where prohibited. Your mileage may vary. Caveat emptor.

          1 Reply Last reply
          0
          • D Offline
            D Offline
            daviddoria
            wrote on last edited by
            #5

            mlong - yes, there is only the 'all' target. As I mentioned, I can create a new target, but it also defaults to Release mode and there doesn't seem to be a way to change it (from inside QtCreator).

            1 Reply Last reply
            0
            • T Offline
              T Offline
              tobias.hunger
              wrote on last edited by
              #6

              You should be able to pass extra command line argument to cmake when it is run. This actually allows for every configuration variable in cmake to be set, but it is rather less convenient than using ccmake...

              1 Reply Last reply
              0
              • D Offline
                D Offline
                daviddoria
                wrote on last edited by
                #7

                I have posted a comment here:
                https://bugreports.qt-project.org/browse/QTCREATORBUG-6613

                and a new feature request here:
                https://bugreports.qt-project.org/browse/QTCREATORBUG-7729

                1 Reply Last reply
                0

                • Login

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