-
QT debug confusion
I recently compiled QT 4.4.2 on Linux. The configure --help command says that the debug mode is off by default. Indeed, configure said "Debug No". I looked to the lib directory and to my surprise it contained every file in 2 versions - a normal and .debug one. For example libQtCore.so.4.4.2 was 2.2 MB and libQtCore.so.4.4.2.debug was 17 MB.
Then I tried recompiling QT with debug on. I installed it to a different location and checked sizes:
libQtCore.so.4.4.2 - 3 MB
libQtCore.so.4.4.2.debug - 24 MB
So, it seems that compiling with debug gives some extra information to the libs, but now I'm completely confused. Can anyone explain what additional stuff is included in the debug version and why those .debug file were created in both cases.
-
Re: QT debug confusion
debug only means that it's compiled with '-O0 -g' whereas release means '-O2 -g' when I'm correct.
-
Re: QT debug confusion
Well, it's seems to be true. I checked Makefiles. Release version has "-g -O2" whereas the debug one "-g" which really means "-g -O0" as "-O0" is default.
Additionally release binaries are compiled with -DQT_NO_DEBUG.
What about the difference between .so and .so.debug files? Why both of them are created by default?
UPDATE:
Anyway, a binary compiled with "CONFIG += debug" doesn't seem to use these .so.debug files. At least ldd claims so.