diff --git a/x11/sddm/Makefile b/x11/sddm/Makefile index b13d0c4c0940..d3afc62e8501 100644 --- a/x11/sddm/Makefile +++ b/x11/sddm/Makefile @@ -1,57 +1,60 @@ PORTNAME= sddm PORTVERSION= 0.19.0 DISTVERSIONPREFIX= v -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= x11 MAINTAINER= kde@FreeBSD.org COMMENT= QML based login manager # The source code is GPLv2+, but the provided themes are: # - CC-BY 3.0 (default greeter theme, maldives) # - CC-BY 4.0 (maya) # - Apache20 (font included with maya) LICENSE= GPLv2+ CC-BY-3.0 CC-BY-4.0 APACHE20 LICENSE_COMB= multi LICENSE_FILE_GPLv2+ = ${WRKSRC}/LICENSE LICENSE_FILE_CC-BY-3.0= ${WRKSRC}/LICENSE.CC-BY-3.0 BUILD_DEPENDS= rst2man.py-${PYTHON_VER}:textproc/py-docutils@${PY_FLAVOR} RUN_DEPENDS= dbus-run-session:devel/dbus \ - xauth:x11/xauth + xauth:x11/xauth \ + xmessage:x11/xmessage USES= cmake compiler:c++11-lang kde:5 pkgconfig python:build qt:5 xorg USE_GITHUB= yes USE_KDE= ecm_build USE_QT= core declarative dbus gui network \ buildtools_build linguisttools_build qmake_build testlib_build USE_XORG= xcb CONFLICTS_INSTALL= lightdm CMAKE_ON= BUILD_MAN_PAGES CMAKE_ARGS= -DUID_MIN=1000 \ -DUID_MAX=65000 \ -DCMAKE_INSTALL_SYSCONFDIR:PATH=${LOCALBASE}/etc \ -DRST2MAN_EXECUTABLE=${LOCALBASE}/bin/rst2man.py-${PYTHON_VER} USE_RC_SUBR= sddm SUB_FILES= xinitrc.desktop USERS= sddm GROUPS= sddm post-patch: @${REINPLACE_CMD} -e 's#/etc/X11#${LOCALBASE}/etc/X11#' \ -e 's#/usr/bin/#${LOCALBASE}/bin/#g' \ -e 's#/usr/share/#${LOCALBASE}/share/#' \ ${WRKSRC}/data/scripts/Xsession \ ${WRKSRC}/src/common/Configuration.h post-install: # Install xsession.desktop to launch .xinitrc via sddm. ${MKDIR} ${STAGEDIR}${PREFIX}/share/xsessions ${INSTALL_DATA} ${WRKDIR}/xinitrc.desktop ${STAGEDIR}${PREFIX}/share/xsessions ${INSTALL_SCRIPT} ${FILESDIR}/xinit-session ${STAGEDIR}${PREFIX}/share/sddm/scripts + ${REINPLACE_CMD} -e 's#@@LOCALBASE@@#${LOCALBASE}#' ${STAGEDIR}${PREFIX}/share/sddm/scripts/xinit-session + .include diff --git a/x11/sddm/files/xinit-session b/x11/sddm/files/xinit-session index 804728c9ca53..d10125d73770 100644 --- a/x11/sddm/files/xinit-session +++ b/x11/sddm/files/xinit-session @@ -1,12 +1,22 @@ #!/bin/sh # # Runs the user's .xinitrc (at this point, .xsession has already -# been sourced). +# been sourced). If there is no .xinitrc, but xinit is installed, +# then there is a default script. If neither is installed, +# display a message. RC="$HOME/.xinitrc" +if [ ! -f "$RC" ] ; then + RC="@@LOCALBASE@@/etc/X11/xinit/xinitrc" + # But that one needs at least xterm to do something useful + if [ ! -x @@LOCALBASE@@/bin/xterm ] ; then + RC="" + fi +fi -test -f "$RC" || exit 1 - -test -x "$RC" && exec "$RC" -test -f "$RC" && exec /bin/sh "$RC" - +if [ -n "$RC" -a -f "$RC" ] ; then + test -x "$RC" && exec "$RC" + test -f "$RC" && exec /bin/sh "$RC" +else + exec @@LOCALBASE@@/bin/xmessage -geometry +0+0 "There is no user-session or usable default with xterm" +fi diff --git a/x11/sddm/pkg-message b/x11/sddm/pkg-message index bd1e209ceecf..2f3a3614efe5 100644 --- a/x11/sddm/pkg-message +++ b/x11/sddm/pkg-message @@ -1,13 +1,20 @@ [ { type: upgrade maximum_version: 0.18.1_4 message: <