Commit b93a0639 authored by Neal Gompa's avatar Neal Gompa
Browse files

login-sessions: Set the correct filename depending on default session type

For distributions aiming to ship the Wayland session by default, allow
the Wayland session file to be installed as "plasma.desktop". Otherwise,
revert to status quo where the X11 session is installed as "plasma.desktop".
parent 71dfc770
......@@ -193,6 +193,7 @@ add_definitions(-DQT_NO_URL_CAST_FROM_STRING)
query_qmake(QtBinariesDir QT_INSTALL_BINS)
option(PLASMA_SYSTEMD_BOOT "Use systemd units for startup of plasma (WIP)" FALSE)
option(PLASMA_WAYLAND_DEFAULT_SESSION "Use Wayland session by default for Plasma" FALSE)
add_subdirectory(doc)
add_subdirectory(libkworkspace)
......
## For Plasma end users
configure_file(plasmax11.desktop.cmake ${CMAKE_CURRENT_BINARY_DIR}/plasmax11.desktop)
if(PLASMA_WAYLAND_DEFAULT_SESSION)
set(PLASMA_X11_DESKTOP_FILENAME plasmax11.desktop CACHE INTERNAL)
set(PLASMA_WAYLAND_DESKTOP_FILENAME plasma.desktop CACHE INTERNAL)
else()
set(PLASMA_X11_DESKTOP_FILENAME plasma.desktop CACHE INTERNAL)
set(PLASMA_WAYLAND_DESKTOP_FILENAME plasmawayland.desktop CACHE INTERNAL)
endif()
configure_file(plasmax11.desktop.cmake ${CMAKE_CURRENT_BINARY_DIR}/${PLASMA_X11_DESKTOP_FILENAME})
install(FILES
${CMAKE_CURRENT_BINARY_DIR}/plasmax11.desktop
${CMAKE_CURRENT_BINARY_DIR}/${PLASMA_X11_DESKTOP_FILENAME}
DESTINATION ${KDE_INSTALL_DATADIR}/xsessions
)
configure_file(plasmawayland.desktop.cmake ${CMAKE_CURRENT_BINARY_DIR}/plasmawayland.desktop)
configure_file(plasmawayland.desktop.cmake ${CMAKE_CURRENT_BINARY_DIR}/${PLASMA_WAYLAND_DESKTOP_FILENAME})
install(FILES
${CMAKE_CURRENT_BINARY_DIR}/plasmawayland.desktop
${CMAKE_CURRENT_BINARY_DIR}/${PLASMA_WAYLAND_DESKTOP_FILENAME}
DESTINATION ${KDE_INSTALL_DATADIR}/wayland-sessions
)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment