mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-05 04:53:54 -07:00
QTDIRxx
This commit is contained in:
parent
73626c98a6
commit
8715a403b3
1 changed files with 7 additions and 16 deletions
|
|
@ -51,21 +51,16 @@ if(WIN32 OR USE_VCPKG)
|
|||
# Use vcpkg toolchain on Windows (and on macOS in CI)
|
||||
set(CMAKE_TOOLCHAIN_FILE
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/vcpkg/scripts/buildsystems/vcpkg.cmake
|
||||
CACHE STRING "Vcpkg toolchain file"
|
||||
CACHE FILEPATH "Vcpkg toolchain file"
|
||||
)
|
||||
# Qt path set by user or env var
|
||||
if(QTDIR
|
||||
OR DEFINED ENV{QTDIR}
|
||||
OR DEFINED ENV{QTDIR64}
|
||||
)
|
||||
|
||||
else()
|
||||
# Check if Qt path is set by user or env var
|
||||
if(NOT QTDIR AND NOT DEFINED ENV{QTDIR})
|
||||
set(QTDIR
|
||||
""
|
||||
CACHE PATH "Path to Qt (e.g. C:/Qt/5.7/msvc2015_64)"
|
||||
)
|
||||
message(
|
||||
WARNING "QTDIR variable is missing. Please set this variable to specify path to Qt (e.g. C:/Qt/5.7/msvc2015_64)"
|
||||
WARNING "QTDIR variable is missing. Please set this variable to specify path to Qt (e.g. C:/Qt/5.7/msvc2015_64)"
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
|
@ -196,20 +191,16 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang")
|
|||
add_definitions("-DSFMT_MEXP=19937")
|
||||
endif()
|
||||
|
||||
find_package(Qt6 6.4 REQUIRED)
|
||||
|
||||
find_package(Threads REQUIRED)
|
||||
|
||||
if(DEFINED QTDIR${_lib_suffix})
|
||||
list(APPEND CMAKE_PREFIX_PATH "${QTDIR${_lib_suffix}}")
|
||||
elseif(DEFINED QTDIR)
|
||||
if(DEFINED QTDIR)
|
||||
list(APPEND CMAKE_PREFIX_PATH "${QTDIR}")
|
||||
elseif(DEFINED ENV{QTDIR${_lib_suffix}})
|
||||
list(APPEND CMAKE_PREFIX_PATH "$ENV{QTDIR${_lib_suffix}}")
|
||||
elseif(DEFINED ENV{QTDIR})
|
||||
list(APPEND CMAKE_PREFIX_PATH "$ENV{QTDIR}")
|
||||
endif()
|
||||
|
||||
find_package(Qt6 6.4 REQUIRED)
|
||||
|
||||
message(STATUS "Update Translations: ${UPDATE_TRANSLATIONS}")
|
||||
|
||||
include(FindQtRuntime)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue