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. How to make a define that works only in Release build in Qt Creator?

How to make a define that works only in Release build in Qt Creator?

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 790 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.
  • B Offline
    B Offline
    Bremenpl
    wrote on last edited by
    #1

    Hello there,
    In my .pro file I have added:

    CONFIG(release)
    {
    DEFINES += QT_NO_DEBUG_OUTPUT
    }

    But even though, I am not seing qDebug() prints anymore in both Debug and Release build. What is the proper way of defininf this only for one build? I would apreciate all help.

    lprzenioslo.zut.edu.pl

    1 Reply Last reply
    0
    • hskoglundH Offline
      hskoglundH Offline
      hskoglund
      wrote on last edited by
      #2

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

      1 Reply Last reply
      0
      • B Offline
        B Offline
        Bremenpl
        wrote on last edited by
        #3

        This helped thank you,

        lprzenioslo.zut.edu.pl

        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