diff --git a/CMakeLists.txt b/CMakeLists.txt index c99576f..86e0d6c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,43 +1,49 @@ cmake_minimum_required (VERSION 3.5 FATAL_ERROR) project(kdiamond) set (QT_MIN_VERSION "5.10.0") set (KF5_MIN_VERSION "5.46.0") find_package(ECM ${KF5_MIN_VERSION} REQUIRED CONFIG) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR}) find_package(Qt5 ${QT_MIN_VERSION} REQUIRED NO_MODULE COMPONENTS Widgets ) find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS CoreAddons Config Crash DBusAddons DocTools WidgetsAddons Config I18n ConfigWidgets XmlGui Notifications NotifyConfig ) find_package(KF5KDEGames 4.9.0 REQUIRED) include(FeatureSummary) include(ECMInstallIcons) include(KDEInstallDirs) include(KDEFrameworkCompilerSettings NO_POLICY_SCOPE) include(KDECMakeSettings) include(ECMAddAppIcon) if (${KF5Config_VERSION} STRGREATER "5.56.0") add_definitions(-DQT_NO_FOREACH) MESSAGE(STATUS "compile without foreach") endif() +# workaround for https://bugreports.qt.io/browse/QTBUG-74665 (bug in qt5.13 reevaluate it) +if (${Qt5Widgets_VERSION} STREQUAL "5.13.0") + MESSAGE(STATUS "Qt version: ${Qt5Widgets_VERSION} DISABLE compile without deprecated methods. bug QTBUG-74665") +else() + add_definitions(-DQT_DISABLE_DEPRECATED_BEFORE=0x060000) +endif() add_subdirectory(src) add_subdirectory(sounds) add_subdirectory(themes) add_subdirectory(doc) feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES FATAL_ON_MISSING_REQUIRED_PACKAGES)