diff --git a/src/libs/tracing/CMakeLists.txt b/src/libs/tracing/CMakeLists.txt index 4ebc77b913c..cb46eb21b03 100644 --- a/src/libs/tracing/CMakeLists.txt +++ b/src/libs/tracing/CMakeLists.txt @@ -47,6 +47,10 @@ if(${Qt5_VERSION} VERSION_LESS "6.2.0") qml/tracing.qrc ) else() # < Qt 6.2 + if (NOT TARGET Tracing) + return() + endif() + set(TRACING_QML_FILES qml/ButtonsBar.qml qml/CategoryLabel.qml diff --git a/src/plugins/perfprofiler/CMakeLists.txt b/src/plugins/perfprofiler/CMakeLists.txt index 3c0ce3e434a..f7f6c91aa04 100644 --- a/src/plugins/perfprofiler/CMakeLists.txt +++ b/src/plugins/perfprofiler/CMakeLists.txt @@ -52,6 +52,10 @@ if(${Qt5_VERSION} VERSION_LESS "6.2.0") perfprofiler.qrc ) else() # < Qt 6.2 + if (NOT TARGET PerfProfiler) + return() + endif() + qt_add_resources(PerfProfiler perfprofiler PREFIX "/perfprofiler" tracepoints.sh diff --git a/src/plugins/qmlprofiler/CMakeLists.txt b/src/plugins/qmlprofiler/CMakeLists.txt index 7dc0cecb9dc..295bc3d0bb9 100644 --- a/src/plugins/qmlprofiler/CMakeLists.txt +++ b/src/plugins/qmlprofiler/CMakeLists.txt @@ -83,6 +83,10 @@ if(${Qt5_VERSION} VERSION_LESS "6.2.0") qml/qmlprofiler.qrc ) else() # < Qt 6.2 + if (NOT TARGET QmlProfiler) + return() + endif() + set(QMLPROFILER_QML_FILES qml/QmlProfilerFlameGraphView.qml )