pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/x11/i3lock i3lock: make this work out of the box on Ne...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/3dabbc9ac246
branches:  trunk
changeset: 769161:3dabbc9ac246
user:      nia <nia%pkgsrc.org@localhost>
date:      Tue Nov 09 09:01:08 2021 +0000

description:
i3lock: make this work out of the box on NetBSD, per netbsd-users@

diffstat:

 x11/i3lock/MESSAGE  |  12 ------------
 x11/i3lock/Makefile |  26 ++++++++++++++++++++++++--
 2 files changed, 24 insertions(+), 14 deletions(-)

diffs (59 lines):

diff -r 66cd4ebecb72 -r 3dabbc9ac246 x11/i3lock/MESSAGE
--- a/x11/i3lock/MESSAGE        Tue Nov 09 08:51:22 2021 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,12 +0,0 @@
-===========================================================================
-$NetBSD: MESSAGE,v 1.1 2016/06/11 23:00:13 kamil Exp $
-
-You need to copy the i3lock PAM configuration file to your PAM
-configuration directory (typically /etc/pam.d).  You can find a sample
-file in:
-
-       ${EGDIR}/pam.d/i3lock
-
-It may need to be manually adjusted.
-
-===========================================================================
diff -r 66cd4ebecb72 -r 3dabbc9ac246 x11/i3lock/Makefile
--- a/x11/i3lock/Makefile       Tue Nov 09 08:51:22 2021 +0000
+++ b/x11/i3lock/Makefile       Tue Nov 09 09:01:08 2021 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.7 2020/08/17 20:20:27 leot Exp $
+# $NetBSD: Makefile,v 1.8 2021/11/09 09:01:08 nia Exp $
 #
 
 DISTNAME=      i3lock-2.8
-PKGREVISION=   3
+PKGREVISION=   4
 CATEGORIES=    x11
 MASTER_SITES=  https://i3wm.org/i3lock/
 EXTRACT_SUFX=  .tar.bz2
@@ -25,6 +25,28 @@
 
 MESSAGE_SUBST+=        EGDIR=${EGDIR}
 
+BUILD_DEFS+=   SYSCONFBASE
+
+.include "../../mk/bsd.prefs.mk"
+
+.if ${OPSYS} == "NetBSD"
+SUBST_CLASSES+=                pam
+SUBST_STAGE.pam=       pre-configure
+SUBST_FILES.pam+=      i3lock.pam
+SUBST_SED.pam+=                -e "s,login,system,g"
+.elif ${OPSYS} == "Linux"
+SUBST_CLASSES+=                pam
+SUBST_STAGE.pam=       pre-configure
+SUBST_FILES.pam+=      i3lock.pam
+SUBST_SED.pam+=                -e "s,login,system-auth,g"
+.endif
+
+.if ${UNPRIVILEGED:tl} != "yes"
+CONF_FILES+=           ${PREFIX}/share/examples/${PKGBASE}/pam.d/i3lock \
+                       ${SYSCONFBASE}/pam.d/i3lock
+SPECIAL_PERMS+=                bin/i3lock ${SETUID_ROOT_PERMS}
+.endif
+
 .include "../../devel/libev/buildlink3.mk"
 .include "../../graphics/cairo/buildlink3.mk"
 .include "../../x11/libxcb/buildlink3.mk"



Home | Main Index | Thread Index | Old Index