mirror of
https://github.com/QuasarApp/Snake.git
synced 2025-04-29 11:14:40 +00:00
fix build
This commit is contained in:
parent
44e2dd98b0
commit
70256b5cd3
@ -12,11 +12,17 @@ if(TARGET ${PROJECT_NAME})
|
|||||||
return()
|
return()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(QT_VERSION_MAJOR 5)
|
find_package(QT NAMES Qt5 Qt6 COMPONENTS Core REQUIRED)
|
||||||
find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Core Test REQUIRED)
|
|
||||||
|
|
||||||
include(submodules/QuasarAppLib/CMake/QuasarApp.cmake)
|
include(submodules/QuasarAppLib/CMake/QuasarApp.cmake)
|
||||||
|
|
||||||
|
if (NOT ${QT_VERSION_MAJOR} EQUAL 5)
|
||||||
|
message("The ${PROJECT_NAME} support only qt5. please rebuild this project with qt6")
|
||||||
|
initAll()
|
||||||
|
return()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Core Test REQUIRED)
|
||||||
|
|
||||||
if (DEFINED TARGET_PLATFORM_TOOLCHAIN)
|
if (DEFINED TARGET_PLATFORM_TOOLCHAIN)
|
||||||
if (${TARGET_PLATFORM_TOOLCHAIN} STREQUAL "wasm32")
|
if (${TARGET_PLATFORM_TOOLCHAIN} STREQUAL "wasm32")
|
||||||
initAll()
|
initAll()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user