This does not seem to be a "Debug" build
-
wrote on 18 Oct 2013, 22:21 last edited by SGaist
I'm trying to use a debugger with an android device and get the window with such warning message:
@
This does not seem to be a "Debug" build.
Setting breakpoints by file name and line number may fail.Section .debug_info: Not found.
Section .debug_abbrev: Not found.
Section .debug_line: Not found.
Section .debug_str: Not found.
Section .debug_loc: Not found.
Section .debug_range: Not found.
Section .gdb_index: Not found.
Section .note.gnu.build-id: Not found.
Section .gnu.hash: Not found.
Section .gnu_debuglink: Not found.
@I'm using the Qt Creator 2.8.1 based on Qt 5.1.1 (GCC 4.6.1, 64 bit).
The Qt libraries, the application and all the depends was built with the GCC 4.8.The most strange in this situation that I can use a debugger for the main Application, but all libraries are not able for debugging.
-
wrote on 19 Oct 2013, 18:12 last edited by
The problem was solved by changing the library type from dynamic to static.
Maybe someone knows why the dynamic libraries are not able for debugging? -
wrote on 25 Aug 2014, 03:15 last edited by
I'm still seeing this with Qt5.3.
How did you set to use static? did you rebuild Qt yourself?
-
wrote on 28 Aug 2014, 16:30 last edited by
I didn't mean Qt. I told about my libraries. When they were static I could use the debugger.
But right now (at version Qt 5.3.1 and Creator 3.2.1) I can use debugger in my libraries even when they are shared.
I rebuilt Qt several times, but only for changing qreal type to double precision and never used it as static.
-
wrote on 28 Aug 2014, 22:07 last edited by
I'm still seeing this issue on mac with all the latest Qt and creator. might be a bug?
I don't have any libraries, just the main program.
-
wrote on 15 Nov 2015, 05:45 last edited by
A solution that worked for me was to got to project>Build settings.
Click Run Cmake and in the cmake wizard that appears add -DCMAKE_BUILD_TYPE=Debug to the command line arguments and click Run Cmake. This sets up the build to be a debug build type -
Your Qt libraries are built in Release mode. You need libraries built in Debug mode if you want to debug them.
-
Your Qt libraries are built in Release mode. You need libraries built in Debug mode if you want to debug them.
-
wrote on 15 Dec 2016, 08:48 last edited by
But what if I can not choose debug mode cause it does not have "debug " to select ?
-
But what if I can not choose debug mode cause it does not have "debug " to select ?
@ElsonAmber Then you should add Debug configuration to your project configuration: go to "Projects/Build&Run/Build Settings", then click Add combobox and select Debug.
-
wrote on 22 Feb 2023, 01:40 last edited by DungeonLords
-
wrote on 2 Mar 2023, 10:57 last edited by
I am getting the exact same error.
@jsulm How do I "build libraries in Debug mode"?
My project is using qmake, and everything is set to "Debug" mode everywhere that it possibly can be. The effective qmake call is "/home/dane/buildroot/output/host/usr/bin/qmake /home/dane/dev/qt/test_qt_quick_qmake/test_qt_quick_qmake.pro -spec devices/linux-buildroot-g++ CONFIG+=debug CONFIG+=qml_debug && /usr/bin/make qmake_all".
I can debug (set breakpoints in) the QML side of the project on the target but not the C++ side. -
I am getting the exact same error.
@jsulm How do I "build libraries in Debug mode"?
My project is using qmake, and everything is set to "Debug" mode everywhere that it possibly can be. The effective qmake call is "/home/dane/buildroot/output/host/usr/bin/qmake /home/dane/dev/qt/test_qt_quick_qmake/test_qt_quick_qmake.pro -spec devices/linux-buildroot-g++ CONFIG+=debug CONFIG+=qml_debug && /usr/bin/make qmake_all".
I can debug (set breakpoints in) the QML side of the project on the target but not the C++ side.wrote on 2 Mar 2023, 12:03 last edited by JonB 3 Feb 2023, 12:17@Dane-0
Have you set both as per https://doc.qt.io/qtcreator/creator-debugging-qml.html#mixed-c-qml-debugging ? Other people seem to have had the reverse trouble: C++ debugging works but not QML. -
@Dane-0
Have you set both as per https://doc.qt.io/qtcreator/creator-debugging-qml.html#mixed-c-qml-debugging ? Other people seem to have had the reverse trouble: C++ debugging works but not QML.wrote on 2 Mar 2023, 12:08 last edited by@JonB Both "Enable C++" and "Enable QML" are ticked under "Debugger settings" (Projects->Build & Run->Run).
I get the exact same error message as the OP:This does not seem to be a "Debug" build.
Setting breakpoints by file name and line number may fail.
Section .debug_info: Not found.
Section .debug_abbrev: Not found.
Section .debug_line: Not found.
Section .debug_str: Not found.
Section .debug_loc: Not found.
Section .debug_range: Not found.
Section .gdb_index: Not found.
Section .note.gnu.build-id: Not found.
Section .gnu.hash: Not found.
Section .gnu_debuglink: Not found. -
-
wrote on 3 Mar 2023, 12:36 last edited by
Inspecting the compiled executable with objdump reveals that there are no debug sections, and looking at the Makefile generated by QMake I can see that the CFLAGS and CXXFLAGS for the embedded target do not include the -g option.
Why would QMake not be including the -g option when it is being called with CONFIG+=debug? How can I fix or workaround this? -
Inspecting the compiled executable with objdump reveals that there are no debug sections, and looking at the Makefile generated by QMake I can see that the CFLAGS and CXXFLAGS for the embedded target do not include the -g option.
Why would QMake not be including the -g option when it is being called with CONFIG+=debug? How can I fix or workaround this?@Dane-0 Did you try from a clean state: delete everything in build folder, run qmake and then build. Maybe you already built in release mode in same folder, so qmake does not update makefiles.
-
wrote on 3 Mar 2023, 12:52 last edited by
I just found this:
https://bootlin.com/blog/building-a-linux-system-for-the-stm32mp1-setting-up-a-qt5-application-development-environment/#comment-2267741
which seems probably like the correct explanation for what is happening.
I have now set BR2_ENABLE_DEBUG=y in BuildRoot and am busy with a BuildRoot clean / rebuild. Will revert once done (will take some time). -
wrote on 4 Mar 2023, 20:36 last edited by
Yip that solved it. BR2_ENABLE_DEBUG=y in BuildRoot. Easy once you know! ;-)