Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QT_NO_DEBUG_OUTPUT - why do I need to compile from scratch when switching between debug and release?
Qt 6.11 is out! See what's new in the release blog

QT_NO_DEBUG_OUTPUT - why do I need to compile from scratch when switching between debug and release?

Scheduled Pinned Locked Moved Solved General and Desktop
2 Posts 2 Posters 861 Views 1 Watching
  • 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.
  • K Offline
    K Offline
    Kuczmil
    wrote on last edited by
    #1

    Hello,

    I would like to ask somebody for explanation of the following issue:
    I switched off "shadow copy". Both debug and release versions are created in the same directory. My pro file contains line:

    CONFIG(release, debug|release):DEFINES += QT_NO_DEBUG_OUTPUT
    

    so it is expected to hide all debug information when compiled in release mode.

    And now the important thing - when compiling from scratch, the behavior is correct, i.e. there is no messages when release mode, and debug is present when debug mode is on. But when it is once compiled as debug and then as release - debug information is present. And reversely - having release compiled first, debug second, there is no any debug information on console.

    Could somebody explain why is that? Is qmake making some optimizations and since header are intact, the assumption is made that there were no change in code (despite some extra flag?).

    Thank you in advance.

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi
      i would suspect .qmake.stash left over or similar file.
      However i have not tested this assumption.

      1 Reply Last reply
      1

      • Login

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