Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: adapt to qt6 #152

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,15 @@
#
# SPDX-License-Identifier: CC0-1.0

cmake_minimum_required(VERSION 3.11)
cmake_minimum_required(VERSION 3.16)

project(dde-appearance)

cmake_policy(SET CMP0160 OLD)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--no-undefined")

if (CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
set(CMAKE_INSTALL_PREFIX /usr)
Expand All @@ -18,6 +21,12 @@ if (CMAKE_BUILD_TYPE STREQUAL "Debug")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -Wall -Werror=return-type -fno-omit-frame-pointer -Wextra")
endif()

set(QT_VERSION_MAJOR 6)
set(DTK_VERSION_MAJOR 6)

set(TRANS_FILE_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}src/service/impl/appearancemanager.cpp)
set(PLUGIN_NAME "plugin-dde-appearance")

add_subdirectory(src)
add_subdirectory(misc)
add_subdirectory(fakewm)
17 changes: 8 additions & 9 deletions debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,23 @@ Maintainer: Deepin Packages Builder <[email protected]>
Build-Depends: debhelper (>= 9),
cmake,
pkg-config,
qtbase5-dev,
libdtkcore-dev,
libdtkgui-dev,
libpolkit-qt5-1-dev,
qt6-base-dev,
qt6-tools-dev-tools,
libdtk6core-dev,
libdtk6gui-dev,
libpolkit-qt6-1-dev,
libgdk-pixbuf2.0-0,
libgsettings-qt-dev,
libglib2.0-dev,
libxcursor-dev,
libgtk-3-dev,
libxcb1-dev,
libxcb-cursor-dev,
libxcb-randr0-dev,
libxcb-render0-dev,
qttools5-dev-tools,
libssl-dev,
libkf5globalaccel-dev,
libkf5windowsystem-dev,
libkf5config-dev,
libkf6globalaccel-dev,
libkf6windowsystem-dev,
libkf6config-dev,
Standards-Version: 3.9.8
Homepage: http://www.deepin.org

Expand Down
40 changes: 17 additions & 23 deletions fakewm/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,19 @@ set(CMAKE_AUTOMOC ON)
include(FindPkgConfig)
find_package(PkgConfig REQUIRED)

find_package(Qt5 REQUIRED COMPONENTS Core DBus Concurrent Gui)
find_package(DtkCore REQUIRED)
find_package(DtkGui REQUIRED)
find_package(PkgConfig REQUIRED)
find_package(KF5Config REQUIRED)
find_package(KF5WindowSystem REQUIRED)
find_package(KF5GlobalAccel REQUIRED)
find_package(Dtk REQUIRED COMPONENTS Core)

pkg_check_modules(QGSettings REQUIRED IMPORTED_TARGET gsettings-qt)
find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Core DBus Concurrent Gui)
find_package(Dtk${DTK_VERSION_MAJOR} REQUIRED COMPONENTS Core Gui)
find_package(KF6Config REQUIRED)
find_package(KF6WindowSystem REQUIRED)
find_package(KF6GlobalAccel REQUIRED)

set(SRCS
./dbus/deepinwmfaker.h
./dbus/deepinwmfaker.cpp
main.cpp
./dbus/deepinwmfaker.h
./dbus/deepinwmfaker.cpp
main.cpp
)

qt5_add_dbus_adaptor(
qt_add_dbus_adaptor(
wm_SRCS
../dbus/com.deepin.wm.xml
./dbus/deepinwmfaker.h
Expand All @@ -38,15 +33,14 @@ add_executable(dde-fakewm
)

target_link_libraries(dde-fakewm
Qt5::Core
Qt5::DBus
Qt5::Concurrent
Qt5::Gui
KF5::ConfigCore
KF5::WindowSystem
KF5::GlobalAccel
PkgConfig::QGSettings
Dtk::Core
Qt${QT_VERSION_MAJOR}::Core
Qt${QT_VERSION_MAJOR}::DBus
Qt${QT_VERSION_MAJOR}::Concurrent
Qt${QT_VERSION_MAJOR}::Gui
Dtk${DTK_VERSION_MAJOR}::Core
KF6::ConfigCore
KF6::WindowSystem
KF6::GlobalAccel
)

install(TARGETS dde-fakewm DESTINATION ${CMAKE_INSTALL_BINDIR})
Loading
Loading