[Qt-creator] Breakpoints not working in QC1.1.0
Eike Ziller
eike.ziller at nokia.com
Tue May 5 11:56:42 CEST 2009
On May 4, 2009, at 11:32 PM, ext Leo Spalteholz wrote:
> On Fri, May 1, 2009 at 4:04 PM, Andre Poenitz
> <andre.poenitz at mathematik.tu-chemnitz.de> wrote:
>> On Fri, May 01, 2009 at 03:25:14PM -0700, Leo Spalteholz wrote:
>>> I have a similar problem (QtCreator ignoring breakpoints completely)
>>> but it is happening on Windows.
>>
>> By now this has been reported several times, and in all cases we
>> manage to examine close enough the problem was a release-only build.
>>
>> I guess in the long run we would need to have to discover whether
>> the binary that's actually running is indeed a debug build, but
>> for the short term, please double-check not only that it is a debug
>> build (Project settings) but alose whether the "Compile output" pane
>> mentions '-g' during compilation). Also, for starters, try to set
>> a breakpoint on 'main' using Debug -> Set breakpoint on function
>> "main".
>
> That's it. Even when the build configuration is set to debug, it was
> still compiling in release mode.
>
> Turns out in my .pro file (which came from pre-QtCreator days), I had
> put in a CONFIG += release, so that's what was causing the problem.
> Removing that line solves everything.
>
> So the problem was a change in behaviour between QtCreator versions.
> In 1.0, specifying Debug mode in the build configuration overrides
> whatever is in the CONFIG in the pro file, in QtCreator 1.1, the pro
> file overrides the build configuration setting. I don't know what is
> more correct, but it is certainly confusing to set Debug and end up
> with a release build.
There might be no "right" way to do it :)
But explicitly setting CONFIG+=release in a profile often indicates
that whoever put it there wanted to force this code/library to be
compiled in release mode, independent from other parts of the
application. (Or the other way round for CONFIG+=debug. E.g. we do a
forced debug build for the debugging helper, and a forced release
build for the process stub for QtCreator.)
--
Eike Ziller
Software Engineer
Nokia, Qt Software
Phone +49 (0)30 6392 3255
Fax +49 (0)30 6392 3256
E-mail eike.ziller at nokia.com
More information about the Qt-creator-old
mailing list