Results 1 to 17 of 17

Thread: qt creator - breakpoints don't work

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Location
    Belgium
    Posts
    1,938
    Thanked 268 Times in 268 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Wiki edits
    20

    Default Re: qt creator - breakpoints don't work

    Did you recently change /etc/make.conf ?
    On my system it contains the CXX_FLAGS (or something like that) environment variable.

    Edit: note that optimisation isn't always wanted, so you should set the level yourself.

  2. #2
    Join Date
    May 2010
    Posts
    15
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: qt creator - breakpoints don't work

    No, I didn't change /etc/make.conf C(XX)FLAGS lately. It's set to:
    Qt Code:
    1. CFLAGS="-O2 -march=core2 -msse3 -mssse3 -msse4.1 -pipe -g"
    2. CXXFLAGS="${CFLAGS}"
    To copy to clipboard, switch view to plain text mode 

    I also remember, that in the past the release mode used some or all of these flags.

  3. #3
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: qt creator - breakpoints don't work

    I don't think qmake takes /etc/make.conf into consideration when generating the Makefile. It should work solely based upon $QTDIR/mkspecs/*.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  4. #4
    Join Date
    May 2010
    Posts
    15
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: qt creator - breakpoints don't work

    Well then, should the QMAKE_CFLAGS_RELEASE variable be empty?

  5. #5
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: qt creator - breakpoints don't work

    I think you should care more about QMAKE_CXXFLAGS and family.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  6. #6
    Join Date
    May 2010
    Posts
    15
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: qt creator - breakpoints don't work

    Quote Originally Posted by wysota View Post
    I think you should care more about QMAKE_CXXFLAGS and family.
    This one's set to just "-pipe".

  7. #7
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: qt creator - breakpoints don't work

    What about QMAKE_CXXFLAGS_DEBUG and others like it?
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  8. #8
    Join Date
    May 2010
    Posts
    15
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: qt creator - breakpoints don't work

    Here are all the defaults:
    Qt Code:
    1. QMAKE_CC = gcc
    2. QMAKE_CFLAGS += -pipe
    3. QMAKE_CFLAGS_DEPS += -M
    4. QMAKE_CFLAGS_WARN_ON += -Wall -W
    5. QMAKE_CFLAGS_WARN_OFF += -w
    6. QMAKE_CFLAGS_RELEASE +=
    7. QMAKE_CFLAGS_DEBUG += -g
    8. QMAKE_CFLAGS_SHLIB += -fPIC
    9. QMAKE_CFLAGS_STATIC_LIB += -fPIC
    10. QMAKE_CFLAGS_YACC += -Wno-unused -Wno-parentheses
    11. QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
    12. QMAKE_CFLAGS_PRECOMPILE += -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
    13. QMAKE_CFLAGS_USE_PRECOMPILE += -include ${QMAKE_PCH_OUTPUT_BASE}
    14.  
    15. QMAKE_CXX = g++
    16. QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
    17. QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
    18. QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
    19. QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
    20. QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
    21. QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
    22. QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
    23. QMAKE_CXXFLAGS_STATIC_LIB += $$QMAKE_CFLAGS_STATIC_LIB
    24. QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
    25. QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden
    26. QMAKE_CXXFLAGS_PRECOMPILE += -x c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
    27. QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
    To copy to clipboard, switch view to plain text mode 

  9. #9
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: qt creator - breakpoints don't work

    Looks fine to me. According to this -g should be in debug mode and not in release mode. My qmake gives me -g in release mode as well (it might be platform dependent, I'm using 'linux-g++' platform) but it's more important that it's there for debug. If -g is missing from your debug makefile, then obviously something had to remove it - maybe you are using some 3rd party addition that introduces such effect.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  10. #10
    Join Date
    May 2010
    Posts
    15
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: qt creator - breakpoints don't work

    I'm not saying -g should be in the release mode. I'm saying that at least -O2 should be in the release mode. Am I not right?

    I just want to know if some optimization flags are SUPPOSED to be there or is it up to the distribution's maintainers. Or maybe it's supposed to be empty after all?

    -g was missing from debug, but then I rebuilt qt-core and it popped back. Weird, but it happens, this problem is solved now. I just want to know about the release thing and I'll be gone
    Last edited by pmitas; 8th September 2010 at 10:33.

  11. #11
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: qt creator - breakpoints don't work

    Quote Originally Posted by pmitas View Post
    I'm saying that at least -O2 should be in the release mode. Am I not right?
    I wouldn't say that was relevant to breakpoints working (or not) in debug mode.

    I just want to know if some optimization flags are SUPPOSED to be there or is it up to the distribution's maintainers. Or maybe it's supposed to be empty after all?
    It depends on where do you have Qt from. If you installed it from the verbatim package downloaded from Nokia then you should have the defaults. But if you installed it through a package manager for your distro, the maintainer of the package might have changed some of the specs (I don't say that is the case). Take a look at the mkspecs directory of your installation and compare it to the Makefile generated by qmake. See if the variable values are consistent.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  12. #12
    Join Date
    May 2010
    Posts
    15
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: qt creator - breakpoints don't work

    That's all then. Thanks for your time.

Similar Threads

  1. Breakpoints set at a slot will not stop?
    By MorrisLiang in forum Newbie
    Replies: 7
    Last Post: 19th May 2010, 16:18
  2. Replies: 2
    Last Post: 13th December 2009, 20:27
  3. Qt Creator doesn't stop at breakpoints
    By TheSaw in forum Qt Tools
    Replies: 3
    Last Post: 12th May 2009, 15:53
  4. Replies: 0
    Last Post: 18th March 2009, 11:56
  5. Replies: 3
    Last Post: 15th January 2008, 12:11

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.