Answer the question
In order to leave comments, you need to log in
Qt application is not dynamically linked to windows. What to do?
There is the following cmake file:
cmake_minimum_required(VERSION 3.1)
project(Flamingo)
set (CMAKE_CXX_STANDARD 14)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_CXX_FLAGS_RELEASE "-O3")
find_package(Qt5Q) find_package(Qt5Q)
find_package(Qt5Q)
find_package(Qt5Multimedia)
find_package(Qt5MultimediaWidgets)
include_directories(".")
file(GLOB_RECURSE Flamingo_SRC
"*.h"
"*.cpp"
"*.hpp"
)
add_executable(${PROJECT_NAME} ${Flamingo_SRC} "res/main.qrc ")
target_link_libraries(${PROJECT_NAME} -lpthread)
target_link_libraries(${PROJECT_NAME} Qt5::Widgets)
target_link_libraries(${PROJECT_NAME} Qt5::Sql)
target_link_libraries(${PROJECT_NAME} Qt5::Multimedia)
target_link_libraries(${PROJECT_NAME} Qt5::MultimediaWidgets)
Answer the question
In order to leave comments, you need to log in
I don’t know if it will help or not, but when I built OpenCV with Qt, I used CMake UI which just highlighted in red that I couldn’t find Qt components. In the same place, I clearly indicated the correct paths and it all worked.
Maybe it makes sense to run CMake UI and see what it swears at?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question