mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-05 21:13:55 -07:00
CMake: support fir linking against qt5
This commit is contained in:
parent
05f46011eb
commit
d7a962c055
5 changed files with 199 additions and 30 deletions
|
|
@ -71,8 +71,18 @@ IF(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang")
|
|||
ADD_DEFINITIONS("-DSFMT_MEXP=19937")
|
||||
ENDIF()
|
||||
|
||||
#Find Qt4 and enable the needed features
|
||||
FIND_PACKAGE(Qt4 REQUIRED)
|
||||
#Find Qt and enable the needed features
|
||||
FIND_PACKAGE(Qt5Widgets)
|
||||
IF(Qt5Widgets_FOUND)
|
||||
MESSAGE(STATUS "Found Qt ${Qt5Widgets_VERSION_STRING}")
|
||||
ELSE()
|
||||
FIND_PACKAGE(Qt4 REQUIRED)
|
||||
IF(Qt4_FOUND)
|
||||
MESSAGE(STATUS "Found Qt ${QT_VERSION_MAJOR}.${QT_VERSION_MINOR}.${QT_VERSION_PATCH}")
|
||||
ELSE()
|
||||
MESSAGE(FATAL_ERROR "No Qt4 or Qt5 found!")
|
||||
ENDIF()
|
||||
ENDIF()
|
||||
|
||||
set(CMAKE_AUTOMOC TRUE)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue