summarylogtreecommitdiffstats
path: root/fix-x11.patch
blob: d7fbf3a6f9597ceae42e1a5b389005d93424bf54 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
Description: Fix for Cmake unable to find X11::X11.
Author: Arun Kumar Pariyar <openarungeek@gmail.com>
Last-Update: 2021-09-28
---

Index: dde-kwin/deepin-wm-dbus/CMakeLists.txt
===================================================================
--- dde-kwin.orig/deepin-wm-dbus/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
+++ dde-kwin/deepin-wm-dbus/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
@@ -8,6 +8,7 @@
 find_package(KF5GlobalAccel REQUIRED)
 find_package(DtkCore REQUIRED)
 find_package(PkgConfig REQUIRED)
+find_package(X11 REQUIRED)

 option(DISABLE_DEEPIN_WM "disable compatibility with deepin-wm" OFF)

@@ -64,6 +65,7 @@
     Qt5::DBus
     KF5::ConfigCore
     KF5::WindowSystem
+    X11::X11
     KF5::GlobalAccel
     dtkcore
     ${GSETTINGS_LDFLAGS}
Index: dde-kwin/plugins/kdecoration/CMakeLists.txt
===================================================================
--- dde-kwin.orig/plugins/kdecoration/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
+++ dde-kwin/plugins/kdecoration/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
@@ -7,7 +7,7 @@
 find_package(KF5Config REQUIRED)
 find_package(KF5WindowSystem REQUIRED)
 find_package(KDecoration2 REQUIRED)
-
+find_package(X11 REQUIRED)
 include_directories(${Qt5Core_PRIVATE_INCLUDE_DIRS})
 include_directories(${Qt5Gui_PRIVATE_INCLUDE_DIRS})

@@ -32,6 +32,7 @@
     ${TARGET_NAME}
     PUBLIC
     Qt5::Core
+    X11::X11
     PRIVATE
     KDecoration2::KDecoration
     KF5::CoreAddons
Index: dde-kwin/plugins/kwineffects/CMakeLists.txt
===================================================================
--- dde-kwin.orig/plugins/kwineffects/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
+++ dde-kwin/plugins/kwineffects/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
@@ -1,7 +1,7 @@
 find_package(Qt5 CONFIG REQUIRED COMPONENTS Core Gui)
 find_package(KF5CoreAddons REQUIRED)
 find_package(KF5WindowSystem REQUIRED)
-
+find_package(X11 REQUIRED)
 set(INSTALL_PATH "${QT_INSTALL_PLUGINS}/kwin/effects/plugins")

 add_subdirectory(scissor-window)
Index: dde-kwin/plugins/kwineffects/blur/CMakeLists.txt
===================================================================
--- dde-kwin.orig/plugins/kwineffects/blur/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
+++ dde-kwin/plugins/kwineffects/blur/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
@@ -1,6 +1,7 @@
 set(TARGET_NAME "blur")

 find_package(KF5Config REQUIRED)
+find_package(X11 REQUIRED)

 add_library(
     ${TARGET_NAME} MODULE
@@ -16,6 +17,7 @@
     PUBLIC
     Qt5::Core
     Qt5::Gui
+    X11::X11
     PRIVATE
     KF5::CoreAddons
     KF5::WindowSystem
Index: dde-kwin/plugins/kwineffects/multitasking/CMakeLists.txt
===================================================================
--- dde-kwin.orig/plugins/kwineffects/multitasking/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
+++ dde-kwin/plugins/kwineffects/multitasking/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
@@ -6,6 +6,7 @@
 set(KF5_DEP_VERSION "5.54.0") # handled by release scripts

 find_package(ECM 5.54.0  NO_MODULE)
+find_package(X11 REQUIRED)

 set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR})

@@ -22,7 +23,9 @@
 endif()

 #optional features
-find_package(X11 MODULE)
+message(STATUS "X11_FOUND = ${X11_FOUND}")
+message(STATUS "X11_INCLUDE_DIR = ${X11_INCLUDE_DIR}")
+message(STATUS "X11_LIBRARIES = ${X11_LIBRARIES}")
 set_package_properties(X11 PROPERTIES DESCRIPTION "X11 libraries"
                        URL "http://www.x.org"
                        TYPE OPTIONAL
@@ -32,6 +35,10 @@
                        URL "http://xcb.freedesktop.org"
                        TYPE OPTIONAL
                       )
+
+message(STATUS "XCB_XCB_FOUND = ${XCB_XCB_FOUND}")
+message(STATUS "XCB_LIBRARIES = ${XCB_LIBRARIES}")
+
 if(X11_FOUND AND XCB_XCB_FOUND)
   set(HAVE_X11 1)
   find_package(Qt5 REQUIRED NO_MODULE COMPONENTS X11Extras)
@@ -104,6 +111,7 @@
     Qt5::Widgets
     Qt5::Quick
     Qt5::QuickWidgets
+    X11::X11
     PRIVATE
     KF5::ConfigCore
     KF5::CoreAddons
Index: dde-kwin/plugins/kwineffects/scissor-window/CMakeLists.txt
===================================================================
--- dde-kwin.orig/plugins/kwineffects/scissor-window/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
+++ dde-kwin/plugins/kwineffects/scissor-window/CMakeLists.txt	2021-09-29 03:36:49.000000000 +0545
@@ -1,4 +1,5 @@
 set(TARGET_NAME "scissor-window")
+find_package(X11 REQUIRED)

 add_library(
     ${TARGET_NAME} MODULE
@@ -9,12 +10,13 @@

 target_link_libraries(
     ${TARGET_NAME}
-    PUBLIC
-    Qt5::Core
-    Qt5::Gui
     PRIVATE
     KF5::CoreAddons
     KF5::WindowSystem
+    PUBLIC
+    Qt5::Core
+    Qt5::Gui
+    X11::X11
 )

 option(DISABLE_LIB_KWIN_XCB "Don't use libkwin-xcb" OFF)
Index: dde-kwin/plugins/platforms/lib/CMakeLists.txt
===================================================================
--- dde-kwin.orig/plugins/platforms/lib/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
+++ dde-kwin/plugins/platforms/lib/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
@@ -6,13 +6,15 @@
 find_package(KF5Config REQUIRED)
 find_package(KF5WindowSystem REQUIRED)
 find_package(KF5CoreAddons REQUIRED)
-
+find_package(X11)
 if (${KF5WindowSystem_VERSION_MINOR} GREATER 45)
     add_definitions(-DKWINDOWSYSTEM_NO_QWIDGET)
 else()
     find_package(Qt5Widgets REQUIRED)
 endif()

+link_libraries(${X11_LIBRARIES})
+
 add_library(
     ${TARGET_NAME} SHARED
     kwinutils.cpp
@@ -33,6 +35,7 @@
     KF5::ConfigCore
     KF5::WindowSystem
     KF5::CoreAddons
+    X11::X11
 )

 if (KWIN_LIBRARY_PATH)
Index: dde-kwin/plugins/platforms/plugin/CMakeLists.txt
===================================================================
--- dde-kwin.orig/plugins/platforms/plugin/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
+++ dde-kwin/plugins/platforms/plugin/CMakeLists.txt	2021-09-29 03:36:35.000000000 +0545
@@ -10,6 +10,7 @@
 find_package(Qt5DBus REQUIRED)
 find_package(Qt5Widgets REQUIRED)
 find_package(DtkGui REQUIRED)
+find_package(X11)

 include_directories(${Qt5Core_PRIVATE_INCLUDE_DIRS})
 include_directories(${Qt5Gui_PRIVATE_INCLUDE_DIRS})
@@ -40,6 +41,7 @@
     org.kde.kwin.KWinUtils.xml
 )

+link_libraries(${X11_LIBRARIES})
 # for xcb platform
 add_library(
     ${TARGET_NAME} MODULE
@@ -63,6 +65,7 @@
     Qt5::Widgets
     ${DtkGui_LIBRARIES}
     kwin-xcb
+    X11::X11
 )

 # for wayland platform