diff options
author | Andreas Sturmlechner <asturm@gentoo.org> | 2024-03-07 19:09:33 +0100 |
---|---|---|
committer | Andreas Sturmlechner <asturm@gentoo.org> | 2024-03-08 23:59:26 +0100 |
commit | 73163d56cdd1a916e9f6d3a06e97e97acf3b3087 (patch) | |
tree | 3b88fdbc27afeba070344553d81bfea20c90b42e /x11-misc/sddm | |
parent | media-gfx/imageworsener: Respect tests exit code (diff) | |
download | gentoo-73163d56cdd1a916e9f6d3a06e97e97acf3b3087.tar.gz gentoo-73163d56cdd1a916e9f6d3a06e97e97acf3b3087.tar.bz2 gentoo-73163d56cdd1a916e9f6d3a06e97e97acf3b3087.zip |
x11-misc/sddm: Ship our own pam files
Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
Diffstat (limited to 'x11-misc/sddm')
-rw-r--r-- | x11-misc/sddm/Manifest | 1 | ||||
-rw-r--r-- | x11-misc/sddm/files/sddm-0.21.0-disable-etc-debian-check.patch | 26 | ||||
-rw-r--r-- | x11-misc/sddm/files/sddm-0.21.0-no-default-pam_systemd-module.patch | 44 | ||||
-rw-r--r-- | x11-misc/sddm/sddm-0.21.0.ebuild | 24 |
4 files changed, 20 insertions, 75 deletions
diff --git a/x11-misc/sddm/Manifest b/x11-misc/sddm/Manifest index c5a2b8780fb4..57ed50b91404 100644 --- a/x11-misc/sddm/Manifest +++ b/x11-misc/sddm/Manifest @@ -1,3 +1,4 @@ DIST sddm-0.18.1.tar.xz 3402972 BLAKE2B 99ab43d374e9a3d318f692a6d496d8a6d68927af3c8e8fc2208d7355ec90649a14758b39f5733dd32f942ed569de88085576d4f5f8666f4f97079e0fb6dcb99e SHA512 ff0637600cda2f4da1f643f047f8ee822bd9651ae4ccbb614b9804175c97360ada7af93e07a7b63832f014ef6e7d1b5380ab2b8959f8024ea520fa5ff17efd60 DIST sddm-0.20.0.tar.gz 3552722 BLAKE2B 8086c9555d5ce1598db3279353de077d51adbcc5222a929750e8558a1bcdad395a411f90608bffdc6e1ca7e7ac2b8325e25cf04cbf8476698d787ce7e60c2105 SHA512 0f64b405f1451873a01a2210530feb6f4cbbdea17be9d039c105088963a48322968db7b60c0d20ac5d97c8ec2a19e5130f0a74c0f9de58c61453d8ce8bb6272a DIST sddm-0.21.0.tar.gz 3557266 BLAKE2B 849cb8b06b9510e5366ea28ef322c242db7d5a77d94c0a5a727f468209880a717055ad8b0c2f5a857852202a4d6bc1f68281fe0e0ab3c6a32327b5a4219af3a0 SHA512 2e8e460e7f318f20a406dcbb1a9fa1dc78b6a5b8d888bfbbaae22b9c642dbc49cf2ac682b4ea9ed847bbafa9bdc361ba08795e59cad970088b370caaaa70f458 +DIST sddm-0.21.0-pam.tar.xz 676 BLAKE2B 06a79f74a5833eca9877df4be8639311382d13061b21aa3627e6c4b07725878ded62221fca943440bacc143f6be2a23b2e0a2124012ff2c9fac82e1eded11144 SHA512 6d91eef2434346f7707122454522cf19f104994ac95d562417f6060a92b4e6c9792bebcccabac8290479200b4ba02fc4d92c6098c435c7ceda796d619d8913c2 diff --git a/x11-misc/sddm/files/sddm-0.21.0-disable-etc-debian-check.patch b/x11-misc/sddm/files/sddm-0.21.0-disable-etc-debian-check.patch deleted file mode 100644 index b0a13259991b..000000000000 --- a/x11-misc/sddm/files/sddm-0.21.0-disable-etc-debian-check.patch +++ /dev/null @@ -1,26 +0,0 @@ -From cef0ad9776d9349e85020b529d20dcc88113015a Mon Sep 17 00:00:00 2001 -From: Andreas Sturmlechner <asturm@gentoo.org> -Date: Tue, 13 Oct 2020 01:04:44 +0200 -Subject: [PATCH 4/5] Disable /etc/debian_version check - -Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org> ---- - services/CMakeLists.txt | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/services/CMakeLists.txt b/services/CMakeLists.txt -index 5158e87..441e46a 100644 ---- a/services/CMakeLists.txt -+++ b/services/CMakeLists.txt -@@ -20,7 +20,7 @@ endif() - configure_file("${CMAKE_CURRENT_SOURCE_DIR}/sddm-greeter.pam.in" "${CMAKE_CURRENT_BINARY_DIR}/sddm-greeter.pam") - - if(INSTALL_PAM_CONFIGURATION) -- if(EXISTS "/etc/debian_version") -+ if(0) - install(FILES debian.sddm-autologin.pam DESTINATION ${CMAKE_INSTALL_FULL_SYSCONFDIR}/pam.d RENAME sddm-autologin) - install(FILES debian.sddm-greeter.pam DESTINATION ${CMAKE_INSTALL_FULL_SYSCONFDIR}/pam.d RENAME sddm-greeter) - install(FILES debian.sddm.pam DESTINATION ${CMAKE_INSTALL_FULL_SYSCONFDIR}/pam.d RENAME sddm) --- -2.43.0 - diff --git a/x11-misc/sddm/files/sddm-0.21.0-no-default-pam_systemd-module.patch b/x11-misc/sddm/files/sddm-0.21.0-no-default-pam_systemd-module.patch deleted file mode 100644 index 4a213d853d16..000000000000 --- a/x11-misc/sddm/files/sddm-0.21.0-no-default-pam_systemd-module.patch +++ /dev/null @@ -1,44 +0,0 @@ -From 6f618b6862d625796c13677ff265bae21b44e029 Mon Sep 17 00:00:00 2001 -From: Andreas Sturmlechner <asturm@gentoo.org> -Date: Tue, 13 Oct 2020 01:10:00 +0200 -Subject: [PATCH 5/5] Don't add pam_systemd.so to pam.d/sddm-greeter in case of - NO_SYSTEMD - ---- - services/CMakeLists.txt | 7 +++++-- - services/sddm-greeter.pam.in | 2 +- - 2 files changed, 6 insertions(+), 3 deletions(-) - -diff --git a/services/CMakeLists.txt b/services/CMakeLists.txt -index 441e46a..8e70fb1 100644 ---- a/services/CMakeLists.txt -+++ b/services/CMakeLists.txt -@@ -12,10 +12,13 @@ if(DEFINED SYSTEMD_TMPFILES_DIR) - install(FILES "${CMAKE_CURRENT_BINARY_DIR}/sddm-tmpfiles.conf" DESTINATION "${SYSTEMD_TMPFILES_DIR}" RENAME sddm.conf) - endif() - -+set(LOGIND_PAM_MODULE "session optional") - if(USE_ELOGIND) -- set(LOGIND_PAM_MODULE "pam_elogind.so") -+ set(LOGIND_PAM_MODULE "${LOGIND_PAM_MODULE} pam_elogind.so") -+elseif(NOT NO_SYSTEMD) -+ set(LOGIND_PAM_MODULE "${LOGIND_PAM_MODULE} pam_systemd.so") - else() -- set(LOGIND_PAM_MODULE "pam_systemd.so") -+ set(LOGIND_PAM_MODULE "") - endif() - configure_file("${CMAKE_CURRENT_SOURCE_DIR}/sddm-greeter.pam.in" "${CMAKE_CURRENT_BINARY_DIR}/sddm-greeter.pam") - -diff --git a/services/sddm-greeter.pam.in b/services/sddm-greeter.pam.in -index d41792d..35dcfd5 100644 ---- a/services/sddm-greeter.pam.in -+++ b/services/sddm-greeter.pam.in -@@ -14,4 +14,4 @@ password required pam_deny.so - - # Setup session - session required pam_unix.so --session optional @LOGIND_PAM_MODULE@ -+@LOGIND_PAM_MODULE@ --- -2.43.0 - diff --git a/x11-misc/sddm/sddm-0.21.0.ebuild b/x11-misc/sddm/sddm-0.21.0.ebuild index a81703972d7f..6aeaf469501a 100644 --- a/x11-misc/sddm/sddm-0.21.0.ebuild +++ b/x11-misc/sddm/sddm-0.21.0.ebuild @@ -3,6 +3,7 @@ EAPI=8 +PAM_TAR="${PN}-0.21.0-pam" if [[ ${PV} == *9999* ]]; then inherit git-r3 EGIT_REPO_URI="https://github.com/${PN}/${PN}.git" @@ -12,10 +13,11 @@ else fi QTMIN=5.15.12 -inherit cmake linux-info optfeature systemd tmpfiles +inherit cmake linux-info optfeature pam systemd tmpfiles DESCRIPTION="Simple Desktop Display Manager" HOMEPAGE="https://github.com/sddm/sddm" +SRC_URI+=" https://dev.gentoo.org/~asturm/distfiles/${PAM_TAR}.tar.xz" LICENSE="GPL-2+ MIT CC-BY-3.0 CC-BY-SA-3.0 public-domain" SLOT="0" @@ -57,9 +59,6 @@ PATCHES=( # Downstream patches "${FILESDIR}/${PN}-0.20.0-respect-user-flags.patch" "${FILESDIR}/${P}-Xsession.patch" # bug 611210 - "${FILESDIR}/${PN}-0.20.0-sddm.pam-use-substack.patch" # bug 728550 - "${FILESDIR}/${P}-disable-etc-debian-check.patch" - "${FILESDIR}/${P}-no-default-pam_systemd-module.patch" # bug 669980 ) pkg_setup() { @@ -67,6 +66,11 @@ pkg_setup() { use kernel_linux && linux-info_pkg_setup } +src_unpack() { + [[ ${PV} == *9999* ]] && git-r3_src_unpack + default +} + src_prepare() { touch 01gentoo.conf || die @@ -82,13 +86,19 @@ EOF sed -e "/^find_package/s/ Test//" -i CMakeLists.txt || die cmake_comment_add_subdirectory test fi + + if use systemd; then + sed -e "/pam_elogind.so/s/elogind/systemd/" \ + -i "${WORKDIR}"/${PAM_TAR}/${PN}-greeter.pam || die + fi } src_configure() { local mycmakeargs=( -DBUILD_MAN_PAGES=ON - -DBUILD_WITH_QT6=OFF # default theme (and others) not yet compatible + -DBUILD_WITH_QT6=OFF # default theme (and others) not yet compatible -DDBUS_CONFIG_FILENAME="org.freedesktop.sddm.conf" + -DINSTALL_PAM_CONFIGURATION=OFF -DRUNTIME_DIR=/run/sddm -DSYSTEMD_TMPFILES_DIR="/usr/lib/tmpfiles.d" -DNO_SYSTEMD=$(usex !systemd) @@ -108,6 +118,10 @@ src_install() { insinto /etc/logrotate.d newins "${FILESDIR}/sddm.logrotate" sddm fi + + newpamd "${WORKDIR}"/${PAM_TAR}/${PN}.pam ${PN} + newpamd "${WORKDIR}"/${PAM_TAR}/${PN}-autologin.pam ${PN}-autologin + newpamd "${WORKDIR}"/${PAM_TAR}/${PN}-greeter.pam ${PN}-greeter } pkg_postinst() { |