Updated cmake sources to TDesktop version 2.6
This commit is contained in:
commit
7f4e983cc2
10 changed files with 81 additions and 82 deletions
12
external/CMakeLists.txt
vendored
12
external/CMakeLists.txt
vendored
|
|
@ -19,7 +19,9 @@ endif()
|
|||
add_checked_subdirectory(expected)
|
||||
if (LINUX AND NOT DESKTOP_APP_DISABLE_DBUS_INTEGRATION)
|
||||
add_checked_subdirectory(fcitx_qt5)
|
||||
if (NOT DESKTOP_APP_DISABLE_X11_INTEGRATION)
|
||||
add_checked_subdirectory(fcitx5_qt5)
|
||||
endif()
|
||||
endif()
|
||||
add_checked_subdirectory(ffmpeg)
|
||||
if (LINUX)
|
||||
|
|
@ -34,10 +36,10 @@ if (add_hunspell_library)
|
|||
endif()
|
||||
add_checked_subdirectory(iconv)
|
||||
add_checked_subdirectory(jpeg)
|
||||
add_checked_subdirectory(lz4)
|
||||
if (LINUX AND NOT DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION)
|
||||
add_checked_subdirectory(materialdecoration)
|
||||
add_checked_subdirectory(kwayland)
|
||||
endif()
|
||||
add_checked_subdirectory(lz4)
|
||||
add_checked_subdirectory(minizip)
|
||||
if (LINUX)
|
||||
add_checked_subdirectory(nimf_qt5)
|
||||
|
|
@ -60,10 +62,8 @@ if (LINUX AND NOT DESKTOP_APP_DISABLE_DBUS_INTEGRATION)
|
|||
endif()
|
||||
add_checked_subdirectory(ton)
|
||||
add_checked_subdirectory(variant)
|
||||
if (NOT DESKTOP_APP_DISABLE_WEBRTC_INTEGRATION)
|
||||
add_checked_subdirectory(webrtc)
|
||||
endif()
|
||||
if (LINUX)
|
||||
add_checked_subdirectory(webrtc)
|
||||
if (LINUX AND NOT DESKTOP_APP_DISABLE_X11_INTEGRATION)
|
||||
add_checked_subdirectory(xcb)
|
||||
endif()
|
||||
add_checked_subdirectory(xxhash)
|
||||
|
|
|
|||
39
external/kwayland/CMakeLists.txt
vendored
Normal file
39
external/kwayland/CMakeLists.txt
vendored
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
# This file is part of Desktop App Toolkit,
|
||||
# a set of libraries for developing nice desktop applications.
|
||||
#
|
||||
# For license and copyright information please follow this link:
|
||||
# https://github.com/desktop-app/legal/blob/master/LEGAL
|
||||
|
||||
if (DESKTOP_APP_USE_PACKAGED)
|
||||
add_library(external_kwayland INTERFACE IMPORTED GLOBAL)
|
||||
add_library(desktop-app::external_kwayland ALIAS external_kwayland)
|
||||
|
||||
find_package(KF5Wayland REQUIRED)
|
||||
target_link_libraries(external_kwayland INTERFACE KF5::WaylandClient)
|
||||
else()
|
||||
add_library(external_kwayland STATIC IMPORTED GLOBAL)
|
||||
add_library(desktop-app::external_kwayland ALIAS external_kwayland)
|
||||
|
||||
find_library(KWAYLAND_LIBRARY libKF5WaylandClient.a)
|
||||
set_target_properties(external_kwayland PROPERTIES
|
||||
IMPORTED_LOCATION "${KWAYLAND_LIBRARY}"
|
||||
)
|
||||
|
||||
target_include_directories(external_kwayland
|
||||
INTERFACE
|
||||
/usr/local/include/KF5
|
||||
/usr/local/include/KF5/KWayland/Client
|
||||
)
|
||||
|
||||
target_link_static_libraries(external_kwayland
|
||||
INTERFACE
|
||||
wayland-client
|
||||
ffi
|
||||
)
|
||||
|
||||
target_link_libraries(external_kwayland
|
||||
INTERFACE
|
||||
${qt_loc}/lib/libQt5Concurrent.a
|
||||
desktop-app::external_qt
|
||||
)
|
||||
endif()
|
||||
56
external/materialdecoration/CMakeLists.txt
vendored
56
external/materialdecoration/CMakeLists.txt
vendored
|
|
@ -1,56 +0,0 @@
|
|||
# This file is part of Desktop App Toolkit,
|
||||
# a set of libraries for developing nice desktop applications.
|
||||
#
|
||||
# For license and copyright information please follow this link:
|
||||
# https://github.com/desktop-app/legal/blob/master/LEGAL
|
||||
|
||||
if (DESKTOP_APP_USE_PACKAGED AND NOT DESKTOP_APP_USE_PACKAGED_LAZY)
|
||||
add_library(external_materialdecoration INTERFACE IMPORTED GLOBAL)
|
||||
add_library(desktop-app::external_materialdecoration ALIAS external_materialdecoration)
|
||||
else()
|
||||
add_library(external_materialdecoration STATIC)
|
||||
add_library(desktop-app::external_materialdecoration ALIAS external_materialdecoration)
|
||||
init_target(external_materialdecoration "(external)")
|
||||
|
||||
set(materialdecoration_loc ${third_party_loc}/materialdecoration)
|
||||
set(materialdecoration_src ${materialdecoration_loc}/src/plugins/decorations/material)
|
||||
|
||||
set_target_properties(external_materialdecoration PROPERTIES AUTOMOC ON)
|
||||
|
||||
nice_target_sources(external_materialdecoration ${materialdecoration_src}
|
||||
PRIVATE
|
||||
materialdecoration.cpp
|
||||
materialdecoration.h
|
||||
plugin.cpp
|
||||
)
|
||||
|
||||
target_include_directories(external_materialdecoration
|
||||
PRIVATE
|
||||
${materialdecoration_src}
|
||||
)
|
||||
|
||||
target_compile_definitions(external_materialdecoration
|
||||
PRIVATE
|
||||
QT_STATICPLUGIN
|
||||
)
|
||||
|
||||
target_link_libraries(external_materialdecoration
|
||||
PRIVATE
|
||||
desktop-app::external_qt
|
||||
)
|
||||
|
||||
if (DESKTOP_APP_USE_PACKAGED)
|
||||
find_package(PkgConfig REQUIRED)
|
||||
pkg_check_modules(WAYLAND_CLIENT REQUIRED IMPORTED_TARGET wayland-client)
|
||||
|
||||
target_link_libraries(external_materialdecoration
|
||||
PRIVATE
|
||||
PkgConfig::WAYLAND_CLIENT
|
||||
)
|
||||
else()
|
||||
target_link_static_libraries(external_materialdecoration
|
||||
PRIVATE
|
||||
wayland-client
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
4
external/qt/CMakeLists.txt
vendored
4
external/qt/CMakeLists.txt
vendored
|
|
@ -280,9 +280,12 @@ else()
|
|||
${qt_libs_dbus_plugins}
|
||||
${qt_libs_waylandclient_plugins}
|
||||
plugins/platforms/${qt_lib_prefix}qxcb
|
||||
plugins/xcbglintegrations/${qt_lib_prefix}qxcb-egl-integration
|
||||
plugins/xcbglintegrations/${qt_lib_prefix}qxcb-glx-integration
|
||||
plugins/iconengines/${qt_lib_prefix}qsvgicon
|
||||
lib/${qt_lib_prefix}Qt5XcbQpa
|
||||
lib/${qt_lib_prefix}Qt5EglSupport
|
||||
lib/${qt_lib_prefix}Qt5GlxSupport
|
||||
lib/${qt_lib_prefix}Qt5ServiceSupport
|
||||
lib/${qt_lib_prefix}Qt5EdidSupport
|
||||
lib/${qt_lib_prefix}Qt5XkbCommonSupport
|
||||
|
|
@ -349,6 +352,7 @@ else()
|
|||
wayland-client
|
||||
xkbcommon
|
||||
xkbcommon-x11
|
||||
xcb-glx
|
||||
xcb-xkb
|
||||
xcb-randr
|
||||
xcb-icccm
|
||||
|
|
|
|||
7
external/qt/qt_static_plugins/CMakeLists.txt
vendored
7
external/qt/qt_static_plugins/CMakeLists.txt
vendored
|
|
@ -29,15 +29,14 @@ if (LINUX)
|
|||
target_link_libraries(external_qt_static_plugins
|
||||
PUBLIC
|
||||
desktop-app::external_fcitx_qt5
|
||||
desktop-app::external_fcitx5_qt5
|
||||
desktop-app::external_hime_qt
|
||||
)
|
||||
endif()
|
||||
|
||||
if (NOT DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION)
|
||||
if (NOT DESKTOP_APP_DISABLE_X11_INTEGRATION)
|
||||
target_link_libraries(external_qt_static_plugins
|
||||
PUBLIC
|
||||
desktop-app::external_materialdecoration
|
||||
desktop-app::external_fcitx5_qt5
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
|
|
|||
|
|
@ -22,6 +22,8 @@ Q_IMPORT_PLUGIN(QCocoaIntegrationPlugin)
|
|||
Q_IMPORT_PLUGIN(QGenericEnginePlugin)
|
||||
#elif defined Q_OS_UNIX // Q_OS_WIN | Q_OS_MAC
|
||||
Q_IMPORT_PLUGIN(QXcbIntegrationPlugin)
|
||||
Q_IMPORT_PLUGIN(QXcbEglIntegrationPlugin)
|
||||
Q_IMPORT_PLUGIN(QXcbGlxIntegrationPlugin)
|
||||
Q_IMPORT_PLUGIN(QGenericEnginePlugin)
|
||||
Q_IMPORT_PLUGIN(QComposePlatformInputContextPlugin)
|
||||
Q_IMPORT_PLUGIN(QSvgIconPlugin)
|
||||
|
|
@ -47,12 +49,11 @@ Q_IMPORT_PLUGIN(QWaylandEglPlatformIntegrationPlugin)
|
|||
Q_IMPORT_PLUGIN(NimfInputContextPlugin)
|
||||
#ifndef DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
||||
Q_IMPORT_PLUGIN(QFcitxPlatformInputContextPlugin)
|
||||
#ifndef DESKTOP_APP_DISABLE_X11_INTEGRATION
|
||||
Q_IMPORT_PLUGIN(QFcitx5PlatformInputContextPlugin)
|
||||
#endif // !DESKTOP_APP_DISABLE_X11_INTEGRATION
|
||||
Q_IMPORT_PLUGIN(QHimePlatformInputContextPlugin)
|
||||
#endif // !DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
||||
#ifndef DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION
|
||||
Q_IMPORT_PLUGIN(QWaylandMaterialDecorationPlugin)
|
||||
#endif // !DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION
|
||||
#endif // !DESKTOP_APP_USE_PACKAGED || DESKTOP_APP_USE_PACKAGED_LAZY
|
||||
|
||||
#if !defined DESKTOP_APP_USE_PACKAGED || defined DESKTOP_APP_USE_PACKAGED_LAZY_PLATFORMTHEMES
|
||||
|
|
|
|||
8
external/ton/CMakeLists.txt
vendored
8
external/ton/CMakeLists.txt
vendored
|
|
@ -55,3 +55,11 @@ target_link_libraries(external_ton
|
|||
INTERFACE
|
||||
${ton_libs_list}
|
||||
)
|
||||
|
||||
if (WIN32)
|
||||
target_link_libraries(external_ton
|
||||
INTERFACE
|
||||
Psapi
|
||||
Normaliz
|
||||
)
|
||||
endif()
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ add_library(desktop-app::common_options ALIAS common_options)
|
|||
target_compile_definitions(common_options
|
||||
INTERFACE
|
||||
$<IF:$<CONFIG:Debug>,_DEBUG,NDEBUG>
|
||||
QT_NO_CAST_FROM_BYTEARRAY
|
||||
)
|
||||
|
||||
if (DESKTOP_APP_DISABLE_CRASH_REPORTS)
|
||||
|
|
@ -26,6 +27,13 @@ if (DESKTOP_APP_DISABLE_DBUS_INTEGRATION)
|
|||
)
|
||||
endif()
|
||||
|
||||
if (DESKTOP_APP_DISABLE_X11_INTEGRATION)
|
||||
target_compile_definitions(common_options
|
||||
INTERFACE
|
||||
DESKTOP_APP_DISABLE_X11_INTEGRATION
|
||||
)
|
||||
endif()
|
||||
|
||||
if (DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION)
|
||||
target_compile_definitions(common_options
|
||||
INTERFACE
|
||||
|
|
@ -33,10 +41,10 @@ if (DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION)
|
|||
)
|
||||
endif()
|
||||
|
||||
if (DESKTOP_APP_DISABLE_WEBRTC_INTEGRATION)
|
||||
if (DESKTOP_APP_DISABLE_GTK_INTEGRATION)
|
||||
target_compile_definitions(common_options
|
||||
INTERFACE
|
||||
DESKTOP_APP_DISABLE_WEBRTC_INTEGRATION
|
||||
DESKTOP_APP_DISABLE_GTK_INTEGRATION
|
||||
)
|
||||
endif()
|
||||
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@ INTERFACE
|
|||
if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
|
||||
target_compile_options(common_options
|
||||
INTERFACE
|
||||
/bigobj # scheme.cpp and history_widget.cpp has too many sections.
|
||||
/permissive-
|
||||
# /Qspectre
|
||||
/W1
|
||||
|
|
@ -37,12 +38,6 @@ if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
|
|||
$<IF:$<CONFIG:Debug>,/NODEFAULTLIB:LIBCMT,/DEBUG;/OPT:REF>
|
||||
)
|
||||
|
||||
if (build_win64)
|
||||
target_compile_options(common_options
|
||||
INTERFACE
|
||||
/bigobj # scheme.cpp has too many sections.
|
||||
)
|
||||
endif()
|
||||
elseif (CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
|
||||
target_compile_definitions(common_options
|
||||
INTERFACE
|
||||
|
|
|
|||
|
|
@ -29,8 +29,9 @@ endif()
|
|||
|
||||
option(DESKTOP_APP_LOTTIE_USE_CACHE "Use caching in lottie animations." ON)
|
||||
option(DESKTOP_APP_DISABLE_DBUS_INTEGRATION "Disable all code for D-Bus integration (Linux only)." OFF)
|
||||
option(DESKTOP_APP_DISABLE_X11_INTEGRATION "Disable all code for X11 integration (Linux only)." OFF)
|
||||
option(DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION "Disable all code for Wayland integration (Linux only)." OFF)
|
||||
option(DESKTOP_APP_DISABLE_WEBRTC_INTEGRATION "Disable all code for WebRTC integration." OFF)
|
||||
option(DESKTOP_APP_DISABLE_GTK_INTEGRATION "Disable all code for GTK integration (Linux only)." OFF)
|
||||
option(DESKTOP_APP_USE_GLIBC_WRAPS "Use wraps for new GLIBC features." OFF)
|
||||
option(DESKTOP_APP_USE_PACKAGED "Find libraries using CMake instead of exact paths." ${no_special_target})
|
||||
option(DESKTOP_APP_USE_PACKAGED_LAZY "Bundle recommended Qt plugins for self-contained packages. (Linux only)" OFF)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue