From 25c434764b82271afe2240523ea8396c64652bba Mon Sep 17 00:00:00 2001 From: jahorta Date: Fri, 5 Jul 2024 17:53:47 -0500 Subject: [PATCH] Added check on windows for Qt6. if not installed, adds external Qt path to cmake and tries again. --- Source/CMakeLists.txt | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Source/CMakeLists.txt b/Source/CMakeLists.txt index 419bba0..fedd8f3 100755 --- a/Source/CMakeLists.txt +++ b/Source/CMakeLists.txt @@ -48,7 +48,17 @@ set(SRCS ${DolphinProcessSrc} set(CMAKE_INCLUDE_CURRENT_DIR ON) -find_package(Qt6Widgets REQUIRED) +if (WIN32) + find_package(Qt6Widgets QUIET) + if (NOT Qt6Widgets_FOUND) + message(STATUS "Qt package not found, using external lib") + list(APPEND CMAKE_PREFIX_PATH "${CMAKE_CURRENT_LIST_DIR}\\..\\Externals\\Qt\\Qt6.5.3\\x64") + find_package(Qt6Widgets REQUIRED) + endif () +else () + find_package(Qt6Widgets REQUIRED) +endif () + find_package(Qt6Core REQUIRED) find_package(Qt6Gui REQUIRED) if (NOT APPLE)