From 20045207f40337c57061217214c52870a3993839 Mon Sep 17 00:00:00 2001 From: kamil Date: Sat, 11 Jun 2016 23:00:13 +0000 Subject: [PATCH] Import i3lock-2.7 as x11/i3lock i3lock improves slock by making it fork() and therefore combinable with commands to suspend your computer. Additionally, instead of turning off your screen via DPMS and/or displaying a black screen, i3lock displays a white screen so you can see if your computer failed to resume from suspend or if your screen is just locked. Also, when entering a wrong password, i3lock does not call XBell(). This is important because i3lock/slock think you've entered a password when resuming from suspend, at least sometimes. Originally packaged in pkgsrc-wip by: - myself, - Mateusz Poszwa, - Niclas Rosenvik, - Pierre Allegraud. --- x11/i3lock/DESCR | 8 ++++++++ x11/i3lock/MESSAGE | 12 +++++++++++ x11/i3lock/Makefile | 33 +++++++++++++++++++++++++++++++ x11/i3lock/PLIST | 4 ++++ x11/i3lock/distinfo | 7 +++++++ x11/i3lock/patches/patch-Makefile | 29 +++++++++++++++++++++++++++ 6 files changed, 93 insertions(+) create mode 100644 x11/i3lock/DESCR create mode 100644 x11/i3lock/MESSAGE create mode 100644 x11/i3lock/Makefile create mode 100644 x11/i3lock/PLIST create mode 100644 x11/i3lock/distinfo create mode 100644 x11/i3lock/patches/patch-Makefile diff --git a/x11/i3lock/DESCR b/x11/i3lock/DESCR new file mode 100644 index 000000000000..20c909dbea3e --- /dev/null +++ b/x11/i3lock/DESCR @@ -0,0 +1,8 @@ +i3lock improves slock by making it fork() and therefore combinable with +commands to suspend your computer. Additionally, instead of turning off +your screen via DPMS and/or displaying a black screen, i3lock displays +a white screen so you can see if your computer failed to resume from +suspend or if your screen is just locked. Also, when entering a wrong +password, i3lock does not call XBell(). This is important because +i3lock/slock think you've entered a password when resuming from suspend, +at least sometimes. diff --git a/x11/i3lock/MESSAGE b/x11/i3lock/MESSAGE new file mode 100644 index 000000000000..f900f4951392 --- /dev/null +++ b/x11/i3lock/MESSAGE @@ -0,0 +1,12 @@ +=========================================================================== +$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 --git a/x11/i3lock/Makefile b/x11/i3lock/Makefile new file mode 100644 index 000000000000..fe2c5de342ba --- /dev/null +++ b/x11/i3lock/Makefile @@ -0,0 +1,33 @@ +# $NetBSD: Makefile,v 1.1 2016/06/11 23:00:13 kamil Exp $ +# + +DISTNAME= i3lock-2.7 +CATEGORIES= x11 +MASTER_SITES= http://i3wm.org/i3lock/ +EXTRACT_SUFX= .tar.bz2 + +MAINTAINER= pkgsrc-users@NetBSD.org +HOMEPAGE= http://i3wm.org/i3lock/ +COMMENT= Slightly improved screen locker based on slock +LICENSE= modified-bsd + +USE_TOOLS+= gmake pkg-config +USE_LANGUAGES= c99 + +MAKE_FLAGS+= PREFIX=${PREFIX} +MAKE_FLAGS+= EGDIR=${EGDIR} +MAKE_FLAGS+= MANDIR=${PKGMANDIR} + +EGDIR= ${PREFIX}/share/examples/${PKGBASE} + +MESSAGE_SUBST+= EGDIR=${EGDIR} + +.include "../../devel/libev/buildlink3.mk" +.include "../../graphics/cairo/buildlink3.mk" +.include "../../x11/libxcb/buildlink3.mk" +.include "../../x11/libxkbcommon/buildlink3.mk" +.include "../../x11/xcb-util/buildlink3.mk" +.include "../../x11/xcb-util-image/buildlink3.mk" +.include "../../x11/xcb-util-keysyms/buildlink3.mk" +.include "../../mk/pam.buildlink3.mk" +.include "../../mk/bsd.pkg.mk" diff --git a/x11/i3lock/PLIST b/x11/i3lock/PLIST new file mode 100644 index 000000000000..9ecc2d2bb114 --- /dev/null +++ b/x11/i3lock/PLIST @@ -0,0 +1,4 @@ +@comment $NetBSD: PLIST,v 1.1 2016/06/11 23:00:13 kamil Exp $ +bin/i3lock +man/man1/i3lock.1 +share/examples/i3lock/pam.d/i3lock diff --git a/x11/i3lock/distinfo b/x11/i3lock/distinfo new file mode 100644 index 000000000000..8f039c50af6c --- /dev/null +++ b/x11/i3lock/distinfo @@ -0,0 +1,7 @@ +$NetBSD: distinfo,v 1.1 2016/06/11 23:00:13 kamil Exp $ + +SHA1 (i3lock-2.7.tar.bz2) = d1096b1f67bfcddc447fade8fa4f7bc124607fec +RMD160 (i3lock-2.7.tar.bz2) = b140a1babea730469943641d5d78655d9a5807a8 +SHA512 (i3lock-2.7.tar.bz2) = 7945d142d239fe7f8985c1000e22db0532456939e65ee855f12e364092808d0cc09cc818b1189e32d88c872ce00033c41c8ebefe62349630872815adaf8b3899 +Size (i3lock-2.7.tar.bz2) = 19490 bytes +SHA1 (patch-Makefile) = 20653b964ce099c0b9daba433a07d2b5b0f1bac3 diff --git a/x11/i3lock/patches/patch-Makefile b/x11/i3lock/patches/patch-Makefile new file mode 100644 index 000000000000..36d906657129 --- /dev/null +++ b/x11/i3lock/patches/patch-Makefile @@ -0,0 +1,29 @@ +$NetBSD: patch-Makefile,v 1.1 2016/06/11 23:00:14 kamil Exp $ + +Install example configuration into EGDIR. +Install man-page. + +--- Makefile.orig 2015-05-20 07:17:06.000000000 +0000 ++++ Makefile +@@ -2,6 +2,7 @@ INSTALL=install + PREFIX=/usr + SYSCONFDIR=/etc + PKG_CONFIG=pkg-config ++MANDIR=share/man + + # Check if pkg-config is installed, we need it for building CFLAGS/LIBS + ifeq ($(shell which $(PKG_CONFIG) 2>/dev/null 1>/dev/null || echo 1),1) +@@ -37,9 +38,11 @@ clean: + + install: all + $(INSTALL) -d $(DESTDIR)$(PREFIX)/bin +- $(INSTALL) -d $(DESTDIR)$(SYSCONFDIR)/pam.d ++ $(INSTALL) -d $(DESTDIR)$(EGDIR)/pam.d ++ $(INSTALL) -d $(DESTDIR)$(PREFIX)/$(MANDIR)/man1 + $(INSTALL) -m 755 i3lock $(DESTDIR)$(PREFIX)/bin/i3lock +- $(INSTALL) -m 644 i3lock.pam $(DESTDIR)$(SYSCONFDIR)/pam.d/i3lock ++ $(INSTALL) -m 644 i3lock.pam $(DESTDIR)$(EGDIR)/pam.d/i3lock ++ $(INSTALL) -m 644 i3lock.1 $(DESTDIR)$(PREFIX)/$(MANDIR)/man1/i3lock.1 + + uninstall: + rm -f $(DESTDIR)$(PREFIX)/bin/i3lock