commit: 1489fb9dc4df8c340aeacbb95b913965cb9c1816 Author: Aisha Tammy <gentoo <AT> aisha <DOT> cc> AuthorDate: Sun Jan 31 14:17:32 2021 +0000 Commit: Piotr Karbowski <slashbeast <AT> gentoo <DOT> org> CommitDate: Sun Jan 31 21:35:40 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1489fb9d
gui-libs/display-manager-init: add postinst warning Package-Manager: Portage-3.0.14, Repoman-3.0.2 Signed-off-by: Aisha Tammy <gentoo <AT> aisha.cc> Closes: https://github.com/gentoo/gentoo/pull/19272 Signed-off-by: Piotr Karbowski <slashbeast <AT> gentoo.org> .../display-manager-init/display-manager-init-1.0.ebuild | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/gui-libs/display-manager-init/display-manager-init-1.0.ebuild b/gui-libs/display-manager-init/display-manager-init-1.0.ebuild index 576a0a7c887..586c5ddc0f5 100644 --- a/gui-libs/display-manager-init/display-manager-init-1.0.ebuild +++ b/gui-libs/display-manager-init/display-manager-init-1.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -34,4 +34,18 @@ pkg_preinst() { if [[ ${REPLACING_VERSIONS} == "" && -f "${EROOT}"/etc/conf.d/xdm && ! -f "${EROOT}"/etc/conf.d/display-manager ]]; then mv "${EROOT}"/etc/conf.d/{xdm,display-manager} || die fi + local rlevel using_xdm + using_xdm=no + for rlevel in boot default sysinit; do + if [[ -e "${EROOT}"/etc/runlevels/${rlevel}/xdm ]]; then + using_xdm=yes + fi + done + if [[ "${using_xdm}" = "yes" ]]; then + ewarn "The 'xdm' service has been removed as it is" + ewarn "being replaced by the 'display-manager' service." + ewarn "Please migrate to using 'display-manager' and" + ewarn "remember to use dispatch-conf to update the" + ewarn "config protected service files." + fi }
