I have a Qt Quick project that uses CMake as its build system. I mostly went with the Qt Creator-generated CMake project, so I have
set(CMAKE_AUTORCC ON)
in my root CMakeLists.txt.
I recently learned about ahead-of-time compiling for QML resources which is supposed to yield quite a bit of startup time improvement. The documentation that describes how to use this with CMake says that I need to do the following:
find_package(Qt5 COMPONENTS Quick Core Network)
find_package(Qt5QuickCompiler)
qtquick_compiler_add_resources(RESOURCES example.qrc)
add_executable(myapp ${SRC_LIST} ${RESOURCES})
qt5_use_modules(myapp Quick Core Network)
but as far as I see, qtquick_compiler_add_resources does nothing but produce a list of C++ files which don't exist. I assume those would be produced by the QtQuick compiler, but as it is, CMake doesn't run because it can't find those sources. What is the missing bit?