I am building a project with CMake but I am new to it, so is really hard to understand how to do that.
cmake_minimum_required(VERSION 3.5)
project(my_project)
find_package(Qt5Core)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_BUILD_TYPE Debug)
file(GLOB includeFiles
"include/*.h"
"include/*.hpp"
"external_dependencies/*.h"
"external_dependencies/*.hpp"
)
file(GLOB sourceFiles
"src/*.cpp"
"external_dependencies/*.cpp"
)
.................................
add_executable(
${PROJECT_NAME}
"qml/qml.qrc"
"src/my_project.cpp"
${includeFiles}
${sourceFiles}
)
add_executable(...)
add_dependencies(...)
target_link_libraries(...)
I need to get the qml files as well in the building folder of the application, more precise where the executable is created.
I need the whole directory to be copied by once with qml files.