Add materialdecoration as a module
This commit is contained in:
parent
e0e4d943e2
commit
6aa291f2e3
4 changed files with 78 additions and 5 deletions
3
external/CMakeLists.txt
vendored
3
external/CMakeLists.txt
vendored
|
|
@ -24,6 +24,9 @@ if (add_hunspell_library)
|
||||||
endif()
|
endif()
|
||||||
add_checked_subdirectory(iconv)
|
add_checked_subdirectory(iconv)
|
||||||
add_checked_subdirectory(lz4)
|
add_checked_subdirectory(lz4)
|
||||||
|
if (LINUX)
|
||||||
|
add_checked_subdirectory(materialdecoration)
|
||||||
|
endif()
|
||||||
add_checked_subdirectory(minizip)
|
add_checked_subdirectory(minizip)
|
||||||
add_checked_subdirectory(openal)
|
add_checked_subdirectory(openal)
|
||||||
add_checked_subdirectory(openssl)
|
add_checked_subdirectory(openssl)
|
||||||
|
|
|
||||||
56
external/materialdecoration/CMakeLists.txt
vendored
Normal file
56
external/materialdecoration/CMakeLists.txt
vendored
Normal file
|
|
@ -0,0 +1,56 @@
|
||||||
|
# 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()
|
||||||
22
external/qt/CMakeLists.txt
vendored
22
external/qt/CMakeLists.txt
vendored
|
|
@ -24,15 +24,24 @@ if (DESKTOP_APP_USE_PACKAGED)
|
||||||
Qt5::Network
|
Qt5::Network
|
||||||
)
|
)
|
||||||
|
|
||||||
if (Qt5DBus_FOUND)
|
|
||||||
target_link_libraries(external_qt INTERFACE Qt5::DBus)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
target_include_directories(external_qt
|
target_include_directories(external_qt
|
||||||
INTERFACE
|
INTERFACE
|
||||||
${Qt5Core_PRIVATE_INCLUDE_DIRS}
|
${Qt5Core_PRIVATE_INCLUDE_DIRS}
|
||||||
${Qt5Gui_PRIVATE_INCLUDE_DIRS}
|
${Qt5Gui_PRIVATE_INCLUDE_DIRS}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if (Qt5WaylandClient_FOUND)
|
||||||
|
target_link_libraries(external_qt INTERFACE Qt5::WaylandClient)
|
||||||
|
|
||||||
|
target_include_directories(external_qt
|
||||||
|
INTERFACE
|
||||||
|
${Qt5WaylandClient_PRIVATE_INCLUDE_DIRS}
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (Qt5DBus_FOUND)
|
||||||
|
target_link_libraries(external_qt INTERFACE Qt5::DBus)
|
||||||
|
endif()
|
||||||
else()
|
else()
|
||||||
target_include_directories(external_qt SYSTEM
|
target_include_directories(external_qt SYSTEM
|
||||||
INTERFACE
|
INTERFACE
|
||||||
|
|
@ -40,10 +49,13 @@ else()
|
||||||
${qt_loc}/include/QtCore
|
${qt_loc}/include/QtCore
|
||||||
${qt_loc}/include/QtGui
|
${qt_loc}/include/QtGui
|
||||||
${qt_loc}/include/QtWidgets
|
${qt_loc}/include/QtWidgets
|
||||||
|
${qt_loc}/include/QtWaylandClient
|
||||||
${qt_loc}/include/QtCore/${qt_version}
|
${qt_loc}/include/QtCore/${qt_version}
|
||||||
${qt_loc}/include/QtGui/${qt_version}
|
${qt_loc}/include/QtGui/${qt_version}
|
||||||
|
${qt_loc}/include/QtWaylandClient/${qt_version}
|
||||||
${qt_loc}/include/QtCore/${qt_version}/QtCore
|
${qt_loc}/include/QtCore/${qt_version}/QtCore
|
||||||
${qt_loc}/include/QtGui/${qt_version}/QtGui
|
${qt_loc}/include/QtGui/${qt_version}/QtGui
|
||||||
|
${qt_loc}/include/QtWaylandClient/${qt_version}/QtWaylandClient
|
||||||
)
|
)
|
||||||
|
|
||||||
if (Qt5DBus_FOUND)
|
if (Qt5DBus_FOUND)
|
||||||
|
|
@ -58,6 +70,7 @@ else()
|
||||||
_REENTRANT
|
_REENTRANT
|
||||||
QT_STATICPLUGIN
|
QT_STATICPLUGIN
|
||||||
QT_PLUGIN
|
QT_PLUGIN
|
||||||
|
QT_WAYLANDCLIENT_LIB
|
||||||
QT_WIDGETS_LIB
|
QT_WIDGETS_LIB
|
||||||
QT_NETWORK_LIB
|
QT_NETWORK_LIB
|
||||||
QT_GUI_LIB
|
QT_GUI_LIB
|
||||||
|
|
@ -166,7 +179,6 @@ else()
|
||||||
plugins/platforminputcontexts/${qt_lib_prefix}composeplatforminputcontextplugin
|
plugins/platforminputcontexts/${qt_lib_prefix}composeplatforminputcontextplugin
|
||||||
${qt_libs_dbus_plugins}
|
${qt_libs_dbus_plugins}
|
||||||
plugins/wayland-decoration-client/${qt_lib_prefix}bradient
|
plugins/wayland-decoration-client/${qt_lib_prefix}bradient
|
||||||
plugins/wayland-decoration-client/${qt_lib_prefix}material
|
|
||||||
plugins/wayland-shell-integration/${qt_lib_prefix}ivi-shell
|
plugins/wayland-shell-integration/${qt_lib_prefix}ivi-shell
|
||||||
plugins/wayland-shell-integration/${qt_lib_prefix}wl-shell
|
plugins/wayland-shell-integration/${qt_lib_prefix}wl-shell
|
||||||
plugins/wayland-shell-integration/${qt_lib_prefix}xdg-shell-v5
|
plugins/wayland-shell-integration/${qt_lib_prefix}xdg-shell-v5
|
||||||
|
|
|
||||||
2
external/qt/package.cmake
vendored
2
external/qt/package.cmake
vendored
|
|
@ -26,6 +26,8 @@ find_package(Qt5Gui COMPONENTS QWebpPlugin REQUIRED)
|
||||||
if (LINUX)
|
if (LINUX)
|
||||||
if (NOT DESKTOP_APP_USE_PACKAGED)
|
if (NOT DESKTOP_APP_USE_PACKAGED)
|
||||||
find_package(Qt5 COMPONENTS WaylandClient Svg REQUIRED)
|
find_package(Qt5 COMPONENTS WaylandClient Svg REQUIRED)
|
||||||
|
elseif (DESKTOP_APP_USE_PACKAGED_LAZY)
|
||||||
|
find_package(Qt5 COMPONENTS WaylandClient REQUIRED)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (DESKTOP_APP_DISABLE_DBUS_INTEGRATION)
|
if (DESKTOP_APP_DISABLE_DBUS_INTEGRATION)
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue