From e40293b26b42cf2e600e21d4efbf5b88d8e47d72 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Wed, 15 Jan 2020 21:21:09 -0300 Subject: [PATCH] cmake: Add DEBUG_QML option MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Patrick José Pereira --- CMakeLists.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 975a259eb7..4b934063ae 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -75,6 +75,18 @@ if(COMPILE_QML) ) endif() +#============================================================================= +# Debug QML +# +option(DEBUG_QML "Build QGroundControl with QML debugging/profiling support." FALSE) +add_feature_info(DEBUG_QML DEBUG_QML "Build QGroundControl with QML debugging/profiling support.") +if(DEBUG_QML) + message(STATUS "To enable the QML debugger/profiler, run with: '-qmljsdebugger=port:1234'") + add_definitions(-DQMLJSDEBUGGER) + add_definitions(-DQT_DECLARATIVE_DEBUG) + add_definitions(-DQT_QML_DEBUG) +endif() + #============================================================================= # GStreamer # -- GitLab