Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Plasma
Plasma Workspace
Commits
7f13eea3
Commit
7f13eea3
authored
Jan 29, 2021
by
Nicolas Fella
Browse files
Use imported targets for X11 libs
They are more robust and nicer than variables
parent
d291b2c9
Changes
19
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
7f13eea3
cmake_minimum_required
(
VERSION 3.
6
)
cmake_minimum_required
(
VERSION 3.
14
)
project
(
plasma-workspace
)
set
(
PROJECT_VERSION
"5.21.80"
)
...
...
appmenu/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -21,7 +21,6 @@ target_link_libraries(appmenu
KF5::DBusAddons
KF5::KIOCore
KF5::WindowSystem
${
X11_LIBRARIES
}
dbusmenuqt
)
...
...
dataengines/mouse/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -14,11 +14,11 @@ target_link_libraries(plasma_engine_mouse
Qt::X11Extras
KF5::Plasma
KF5::WindowSystem
${
X11
_LIBRARIES
}
X11
::X11
)
if
(
X11_Xfixes_FOUND
)
target_link_libraries
(
plasma_engine_mouse
${
X11
_
Xfixes
_LIB
}
)
target_link_libraries
(
plasma_engine_mouse X11
::
Xfixes
)
endif
()
kcoreaddons_desktop_to_json
(
plasma_engine_mouse plasma-dataengine-mouse.desktop
)
...
...
kcms/colors/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -36,7 +36,7 @@ target_link_libraries(kcm_colors
)
if
(
X11_FOUND
)
target_link_libraries
(
kcm_colors
${
X11
_LIBRARIES
}
Qt::X11Extras
)
target_link_libraries
(
kcm_colors X11
::X11
Qt::X11Extras
)
endif
()
kcoreaddons_desktop_to_json
(
kcm_colors
"kcm_colors.desktop"
)
...
...
kcms/cursortheme/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -44,16 +44,16 @@ target_link_libraries(kcm_cursortheme
KF5::KDELibs4Support
KF5::NewStuffCore
KF5::QuickAddons
${
X11
_LIBRARIES
}
X11
::X11
XCB::XCB
PW::KWorkspace
)
if
(
X11_Xcursor_FOUND
)
target_link_libraries
(
kcm_cursortheme
${
X11
_
Xcursor
_LIB
}
)
target_link_libraries
(
kcm_cursortheme X11
::
Xcursor
)
endif
()
if
(
X11_Xfixes_FOUND
)
target_link_libraries
(
kcm_cursortheme
${
X11
_
Xfixes
_LIB
}
)
target_link_libraries
(
kcm_cursortheme X11
::
Xfixes
)
endif
()
install
(
TARGETS kcm_cursortheme DESTINATION
${
KDE_INSTALL_PLUGINDIR
}
/kcms
)
...
...
kcms/fonts/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -44,7 +44,7 @@ if(X11_FOUND)
target_link_libraries
(
kcm_fonts
${
FONTCONFIG_LIBRARIES
}
)
endif
()
target_link_libraries
(
kcm_fonts
${
X11
_LIBRARIES
}
${
X11
_
Xft
_LIB
}
)
target_link_libraries
(
kcm_fonts X11
::X11
X11
::
Xft
)
endif
()
kcoreaddons_desktop_to_json
(
kcm_fonts
"kcm_fonts.desktop"
)
...
...
kcms/kfontinst/apps/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -19,13 +19,12 @@ target_link_libraries(kfontinst_bin
KF5::KIOCore
KF5::KIOWidgets
KF5::XmlGui
${
X11
_
X11
_LIB
}
X11
::
X11
kfontinst
)
target_link_libraries
(
kfontprint_bin
Qt::PrintSupport
KF5::IconThemes
${
X11_X11_LIB
}
${
FREETYPE_LIBRARIES
}
kfontinstui
kfontinst
...
...
kcms/kfontinst/kcmfontinst/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -15,7 +15,7 @@ target_link_libraries(kcm_fontinst
KF5::NewStuff
kfontinstui
kfontinst
${
X11
_LIBRARIES
}
X11
::X11
)
install
(
TARGETS kcm_fontinst DESTINATION
${
KDE_INSTALL_PLUGINDIR
}
)
...
...
kcms/kfontinst/lib/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -18,6 +18,6 @@ target_link_libraries(kfontinst
set_target_properties
(
kfontinst PROPERTIES VERSION
${
PROJECT_VERSION
}
SOVERSION
${
PROJECT_VERSION_MAJOR
}
)
add_library
(
kfontinstui SHARED
${
kfontinstui_LIB_SRCS
}
)
target_link_libraries
(
kfontinstui Qt::X11Extras KF5::KIOCore KF5::KIOWidgets
${
FREETYPE_LIBRARIES
}
${
FONTCONFIG_LIBRARIES
}
${
X11
_
X11
_LIB
}
${
X11
_
Xft
_LIB
}
kfontinst
)
target_link_libraries
(
kfontinstui Qt::X11Extras KF5::KIOCore KF5::KIOWidgets
${
FREETYPE_LIBRARIES
}
${
FONTCONFIG_LIBRARIES
}
X11
::
X11
X11
::
Xft kfontinst
)
set_target_properties
(
kfontinstui PROPERTIES VERSION
${
PROJECT_VERSION
}
SOVERSION
${
PROJECT_VERSION_MAJOR
}
)
install
(
TARGETS kfontinst kfontinstui
${
KDE_INSTALL_TARGETS_DEFAULT_ARGS
}
)
kcms/lookandfeel/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -59,17 +59,17 @@ target_link_libraries(kcm_lookandfeel
Qt::DBus
Qt::Widgets
Qt::QuickWidgets
${
X11
_LIBRARIES
}
X11
::X11
)
if
(
X11_FOUND
)
target_link_libraries
(
kcm_lookandfeel Qt::X11Extras
)
endif
()
if
(
X11_Xcursor_FOUND
)
target_link_libraries
(
kcm_lookandfeel
${
X11
_
Xcursor
_LIB
}
)
target_link_libraries
(
kcm_lookandfeel X11
::
Xcursor
)
endif
()
if
(
X11_Xfixes_FOUND
)
target_link_libraries
(
kcm_lookandfeel
${
X11
_
Xfixes
_LIB
}
)
target_link_libraries
(
kcm_lookandfeel X11
::
Xfixes
)
endif
()
kcoreaddons_desktop_to_json
(
kcm_lookandfeel
"kcm_lookandfeel.desktop"
SERVICE_TYPES kcmodule.desktop
)
...
...
@@ -126,17 +126,16 @@ target_link_libraries(lookandfeeltool
Qt::DBus
Qt::Widgets
Qt::QuickWidgets
${
X11_LIBRARIES
}
)
if
(
X11_FOUND
)
target_link_libraries
(
lookandfeeltool Qt::X11Extras
)
target_link_libraries
(
lookandfeeltool
X11::X11
Qt::X11Extras
)
endif
()
if
(
X11_Xcursor_FOUND
)
target_link_libraries
(
lookandfeeltool
${
X11
_
Xcursor
_LIB
}
)
target_link_libraries
(
lookandfeeltool X11
::
Xcursor
)
endif
()
if
(
X11_Xfixes_FOUND
)
target_link_libraries
(
lookandfeeltool
${
X11
_
Xfixes
_LIB
}
)
target_link_libraries
(
lookandfeeltool X11
::
Xfixes
)
endif
()
install
(
TARGETS lookandfeeltool
${
KDE_INSTALL_TARGETS_DEFAULT_ARGS
}
)
...
...
kcms/lookandfeel/autotests/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -40,17 +40,17 @@ target_link_libraries(kcmTest
Qt::DBus
Qt::Widgets
Qt::QuickWidgets
${
X11
_LIBRARIES
}
X11
::X11
)
if
(
X11_FOUND
)
target_link_libraries
(
kcmTest Qt::X11Extras
)
endif
()
if
(
X11_Xcursor_FOUND
)
target_link_libraries
(
kcmTest
${
X11
_
Xcursor
_LIB
}
)
target_link_libraries
(
kcmTest X11
::
Xcursor
)
endif
()
if
(
X11_Xfixes_FOUND
)
target_link_libraries
(
kcmTest
${
X11
_
Xfixes
_LIB
}
)
target_link_libraries
(
kcmTest X11
::
Xfixes
)
endif
()
add_test
(
NAME lookandfeel-kcmTest COMMAND kcmTest
)
...
...
kcms/style/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -38,7 +38,7 @@ target_link_libraries(kcm_style
KF5::I18n
KF5::Notifications
KF5::Plasma
${
X11
_LIBRARIES
}
X11
::X11
KF5::KDELibs4Support
KF5::GuiAddons
KF5::QuickAddons
...
...
ksmserver/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -49,8 +49,6 @@ target_link_libraries(ksmserver
KF5::I18n
KF5::KIOCore
KF5::KIOGui
${
X11_LIBRARIES
}
${
X11_Xrender_LIB
}
Qt::X11Extras
KF5::Solid
Qt::Quick
...
...
@@ -60,6 +58,10 @@ target_link_libraries(ksmserver
KF5::Package
KF5::WindowSystem
Qt::Concurrent
X11::X11
X11::SM
X11::ICE
X11::Xrender
)
install
(
TARGETS ksmserver
${
KDE_INSTALL_TARGETS_DEFAULT_ARGS
}
)
...
...
libkworkspace/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -66,7 +66,7 @@ if(X11_FOUND)
if
(
NOT X11_Xau_FOUND
)
message
(
FATAL_ERROR
"Found X11, but not libXau which is required for building kworkspace"
)
endif
()
target_link_libraries
(
kworkspace PRIVATE Qt::X11Extras
${
X11
_LIBRARIES
}
${
X11_Xau_LIB
}
)
target_link_libraries
(
kworkspace PRIVATE Qt::X11Extras X11
::Xau
)
endif
()
write_basic_config_version_file
(
${
CMAKE_CURRENT_BINARY_DIR
}
/LibKWorkspaceConfigVersion.cmake VERSION
...
...
logout-greeter/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -21,7 +21,7 @@ target_link_libraries(ksmserver-logout-greeter
KF5::QuickAddons
KF5::WaylandClient
KF5::WindowSystem
${
X11
_LIBRARIES
}
X11
::X11
)
install
(
TARGETS ksmserver-logout-greeter DESTINATION
${
KDE_INSTALL_LIBEXECDIR
}
)
kdbusaddons_generate_dbus_service_file
(
ksmserver-logout-greeter org.kde.LogoutPrompt
${
KDE_INSTALL_FULL_LIBEXECDIR
}
)
...
...
shell/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -89,7 +89,7 @@ target_include_directories(plasmashell PRIVATE "${CMAKE_BINARY_DIR}")
target_compile_definitions
(
plasmashell PRIVATE -DPROJECT_VERSION=
"
${
PROJECT_VERSION
}
"
)
if
(
HAVE_X11
)
target_link_libraries
(
plasmashell
${
X11_LIBRARIES
}
${
XCB_LIBRARIES
}
)
target_link_libraries
(
plasmashell
XCB::XCB XCB::RANDR
)
target_link_libraries
(
plasmashell Qt::X11Extras
)
endif
()
...
...
shell/autotests/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -12,7 +12,7 @@ MACRO(PLASMASHELL_UNIT_TESTS)
KF5::WindowSystem
)
if
(
HAVE_X11
)
target_link_libraries
(
${
_testname
}
${
X11_LIBRARIES
}
${
XCB_LIBRARIES
}
)
target_link_libraries
(
${
_testname
}
XCB::XCB XCB::RANDR
)
target_link_libraries
(
${
_testname
}
Qt::X11Extras
)
endif
()
if
(
QT_QTOPENGL_FOUND
)
...
...
startkde/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -24,9 +24,8 @@ add_executable(startplasma-x11 ${START_PLASMA_COMMON_SRCS} startplasma-x11.cpp k
add_executable
(
startplasma-wayland
${
START_PLASMA_COMMON_SRCS
}
startplasma-wayland.cpp
${
startplasma_SRCS
}
)
add_executable
(
startplasma-waylandsession
${
START_PLASMA_COMMON_SRCS
}
startplasma-waylandsession.cpp
${
startplasma_SRCS
}
)
target_include_directories
(
startplasma-x11 PRIVATE
${
X11_X11_INCLUDE_PATH
}
)
target_link_libraries
(
startplasma-x11 PRIVATE Qt::Core Qt::DBus KF5::ConfigCore PW::KWorkspace
${
X11
_
X11
_LIB
}
# for kcheckrunning
X11
::
X11
# for kcheckrunning
)
target_link_libraries
(
startplasma-wayland PRIVATE Qt::Core Qt::DBus KF5::ConfigCore PW::KWorkspace
)
...
...
xembed-sni-proxy/CMakeLists.txt
View file @
7f13eea3
...
...
@@ -58,7 +58,7 @@ target_link_libraries(xembedsniproxy
Qt::DBus
KF5::WindowSystem
${
XCB_LIBS
}
${
X11
_XTest_LIB
}
X11
::Xtst
)
install
(
TARGETS xembedsniproxy
${
KDE_INSTALL_TARGETS_DEFAULT_ARGS
}
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment