[Midnightbsd-cvs] mports: security/vlock: update to 2.2.2

laffer1 at midnightbsd.org laffer1 at midnightbsd.org
Thu Jan 1 20:19:16 EST 2009


Log Message:
-----------
update to 2.2.2

Modified Files:
--------------
    mports/security/vlock:
        Makefile (r1.2 -> r1.3)
        distinfo (r1.1 -> r1.2)
        pkg-descr (r1.1 -> r1.2)

Added Files:
-----------
    mports/security/vlock/files:
        patch-configure (r1.1)

Removed Files:
-------------
    mports/security/vlock/files:
        patch-aa
        patch-ab
        patch-ac
        patch-ad
        patch-ae

-------------- next part --------------
Index: pkg-descr
===================================================================
RCS file: /home/cvs/mports/security/vlock/pkg-descr,v
retrieving revision 1.1
retrieving revision 1.2
diff -L security/vlock/pkg-descr -L security/vlock/pkg-descr -u -r1.1 -r1.2
--- security/vlock/pkg-descr
+++ security/vlock/pkg-descr
@@ -1,5 +1,4 @@
 This is a utility which locks a terminal so it can only be unlocked with the
 user's password (or the root password).  It uses PAM authentication by default.
 
-- George Reid
-services at nevernet.net
+WWW: http://freshmeat.net/projects/vlock
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/security/vlock/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L security/vlock/Makefile -L security/vlock/Makefile -u -r1.2 -r1.3
--- security/vlock/Makefile
+++ security/vlock/Makefile
@@ -2,22 +2,86 @@
 # Date created:		08 Oct 2000
 # Whom:			George Reid <services at nevernet.net>
 #
-# $FreeBSD: ports/security/vlock/Makefile,v 1.5 2004/02/05 20:37:48 trevor Exp $
 # $MidnightBSD$
-#
+# $FreeBSD: ports/security/vlock/Makefile,v 1.9 2008/06/19 19:35:54 pav Exp $
 
 PORTNAME=	vlock
-PORTVERSION=	1.3
-PORTREVISION=	1
+PORTVERSION=	2.2.2
 CATEGORIES=	security
-MASTER_SITES=	${MASTER_SITE_SUNSITE}
-MASTER_SITE_SUBDIR=	utils/console
+MASTER_SITES=	http://cthulhu.c3d2.de/~toidinamai/vlock/archive/
 
 MAINTAINER=	ports at MidnightBSD.org
 COMMENT=	Locks a terminal
 LICENSE=	gpl2
 
+USE_GMAKE=	yes
+HAS_CONFIGURE=	yes
+CONFIGURE_ARGS=	--enable-plugins --enable-pam \
+		--prefix=${PREFIX} \
+		--mandir=${MANPREFIX}/man \
+		--with-modules="${VLOCKMODULES}" \
+		--with-scripts="${VLOCKSCRIPTS}" \
+		VLOCK_GROUP="${VLOCKGRP}" \
+		VLOCK_MODE="0750" \
+		EXTRA_CFLAGS="-I${LOCALBASE}/include" \
+		EXTRA_LDFLAGS="-L${LOCALBASE}/lib"
+
+OPTIONS=	ROOTPWD "Enable unlock using root password" on \
+		VLOCKSCRIPTS "Install sample hook scripts" off \
+		CACASAVER "Enable libcaca screensaver" off
+
+MANLANG=	""
 MAN1=		vlock.1
-PLIST_FILES=	bin/vlock
+MAN5=		vlock-plugins.5
+MAN8=		vlock-main.8
+
+# Default scripts/modules
+VLOCKSCRIPTS=
+VLOCKMODULES=	all.so new.so
+
+# Vlock group = vlock:*:129:
+VLOCKGRP=	vlock
+VLOCKGID=	129
+
+.include <bsd.port.pre.mk>
+
+.if !defined(WITHOUT_ROOTPWD)
+CONFIGURE_ARGS+=	--enable-root-password
+.else
+CONFIGURE_ARGS+=	--disable-root-password
+.endif
+
+.if !defined(WITHOUT_VLOCKSCRIPTS)
+VLOCKSCRIPTS+=	amarok.sh example_script.sh mplayer.sh
+PLIST_SUB+=	PL_VLOCKSCRIPTS=""
+.else
+PLIST_SUB+=	PL_VLOCKSCRIPTS="@comment "
+.endif
+
+.if !defined(WITHOUT_CACASAVER)
+BUILD_DEPENDS+=	${LOCALBASE}/lib/libcaca.a:${PORTSDIR}/graphics/libcaca
+VLOCKMODULES+=	caca.so
+PLIST_SUB+=	PL_CACASAVER=""
+.else
+PLIST_SUB+=	PL_CACASAVER="@comment "
+.endif
+
+post-patch:
+	@${REINPLACE_CMD} -e 's|-lncurses|-lm|' ${WRKSRC}/modules/Makefile
+
+pre-install:
+	if ! pw groupshow ${VLOCKGRP}; then pw groupadd ${VLOCKGRP} -g ${VLOCKGID}; fi
+
+post-install:
+.if !defined(NOPORTDOCS)
+	@${MKDIR} ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/COPYING ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/ChangeLog ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/PLUGINS ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README.X11 ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/SECURITY ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/TODO ${DOCSDIR}
+.endif
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
Index: distinfo
===================================================================
RCS file: /home/cvs/mports/security/vlock/distinfo,v
retrieving revision 1.1
retrieving revision 1.2
diff -L security/vlock/distinfo -L security/vlock/distinfo -u -r1.1 -r1.2
--- security/vlock/distinfo
+++ security/vlock/distinfo
@@ -1,3 +1,3 @@
-MD5 (vlock-1.3.tar.gz) = d04076f9c5f12aadc4d5fbbabf8a0c12
-SHA256 (vlock-1.3.tar.gz) = 700b8f45b6b7cdaac2185a4796870ac378015db18a7414eebee5e5b6a4131daf
-SIZE (vlock-1.3.tar.gz) = 17188
+MD5 (vlock-2.2.2.tar.gz) = 51c389ee4ef814bf59063bc367437eb8
+SHA256 (vlock-2.2.2.tar.gz) = ea875250cad150872583b6ed2436470bc5e9c3a580d85554e31a2d5ae1d92fad
+SIZE (vlock-2.2.2.tar.gz) = 54732
--- security/vlock/files/patch-ac
+++ /dev/null
@@ -1,11 +0,0 @@
---- terminal.c.orig	Sun Oct  8 18:03:19 2000
-+++ terminal.c		Sun Oct  8 18:03:24 2000
-@@ -15,7 +15,7 @@
- #include <unistd.h>
- #include <termios.h>
- #include <sys/ioctl.h>
--#include <sys/vt.h>
-+#include <sys/consio.h>
- #include "vlock.h"
- 
- 
--- /dev/null
+++ security/vlock/files/patch-configure
@@ -0,0 +1,25 @@
+--- configure.orig	2008-05-18 05:10:54 -0400
++++ configure	2009-01-01 20:16:02 -0500
+@@ -220,7 +220,8 @@
+   MODULEDIR="\$(LIBDIR)/vlock/modules"
+ 
+   CC=gcc
+-  DEFAULT_CFLAGS="-O2 -Wall -W -pedantic -std=gnu99"
++  #DEFAULT_CFLAGS="-O2 -Wall -W -pedantic -std=gnu99"
++  DEFAULT_CFLAGS="-pedantic -std=gnu99"
+   DEBUG_CFLAGS="-O0 -g -Wall -W -pedantic -std=gnu99"
+   CFLAGS="${DEFAULT_CFLAGS}"
+   LD=ld
+@@ -266,6 +267,12 @@
+       CRYPT_LIB=''
+       MODULES="all.so new.so"
+     ;;
++    MidnightBSD)
++      PAM_LIBS='-lpam'
++      DL_LIB=''
++      CRYPT_LIB=''
++      MODULES="all.so new.so"
++    ;;
+   esac
+ }
+ 
--- security/vlock/files/patch-ab
+++ /dev/null
@@ -1,11 +0,0 @@
---- signals.c.orig	Sun Oct  8 18:03:19 2000
-+++ signals.c		Sun Oct  8 18:03:24 2000
-@@ -16,7 +16,7 @@
- #include <signal.h>
- #include <sys/wait.h>
- #include <sys/ioctl.h>
--#include <sys/vt.h>
-+#include <sys/consio.h>
- #include "vlock.h"
- 
- 
--- security/vlock/files/patch-ae
+++ /dev/null
@@ -1,39 +0,0 @@
---- input.c.orig	Thu Jan 14 03:19:14 1999
-+++ input.c	Fri Feb 28 13:48:38 2003
-@@ -60,11 +60,27 @@
- #error "Shadow and PAM don't mix!"
- #endif
- 
-+#if (__FreeBSD__ == 0)            /* 1.0 did not define __FreeBSD__ */
-+#define __FreeBSD_version 199401
-+#elsif __FreeBSD__ == 1          /* 1.1 defined it to be 1 */
-+#define __FreeBSD_version 199405
-+#else                           /* 2.0 and higher define it to be 2 */
-+#include <osreldate.h>          /* and this works */
-+#endif
-+
- #include <security/pam_appl.h>
-+#if defined (__FreeBSD_version) && (__FreeBSD_version > 500030)
-+#include <security/openpam.h>
-+#else
- #include <security/pam_misc.h>
-+#endif
- 
- static struct pam_conv PAM_conversation = {
-+#if defined (__FreeBSD_version) && (__FreeBSD_version > 500030)
-+    openpam_ttyconv,
-+#else
-     &misc_conv,
-+#endif
-     NULL
- };
- 
-@@ -291,7 +307,7 @@
-   setuid(getuid());
-   setgid(getgid());
- 
--  sprintf(prompt, "%s's password: ", username);
-+  snprintf(prompt, 99, "%s's password: ", username);
- #endif /* !USE_PAM */
- }
- 
--- security/vlock/files/patch-ad
+++ /dev/null
@@ -1,46 +0,0 @@
---- vlock.c.orig	Sun Oct  8 18:03:19 2000
-+++ vlock.c		Sun Oct  8 18:03:24 2000
-@@ -14,12 +14,10 @@
- #include <stdio.h>
- #include <unistd.h>
- #include <fcntl.h>
--#include <getopt.h>
- #include <termios.h>
- #include <signal.h>
--#include <sys/vt.h>
--#include <sys/kd.h>
- #include <sys/ioctl.h>
-+#include <sys/consio.h>
- #include "vlock.h"
- #include "version.h"
- 
-@@ -37,20 +35,12 @@
- 
- int main(int argc, char **argv) {
- 
--  static struct option long_options[] = { /* For parsing long arguments */
--    {"current", 0, &o_lock_all, 0},
--    {"all", 0, &o_lock_all, 1},
--    {"version", no_argument, 0, O_VERSION},
--    {"help", no_argument, 0, O_HELP},
--    {0, 0, 0, 0},
--  };
-   int option_index; /* Unused */
-   int c;
-   struct vt_mode vtm;
- 
-   /* First we parse all the command line arguments */
--  while ((c = getopt_long(argc, argv, "acvh",
--			  long_options, &option_index)) != -1) {
-+  while ((c = getopt(argc, argv, "acvh")) != -1) {
-     switch(c) {
-     case 'c':
-       o_lock_all = 0;
-@@ -107,6 +97,7 @@
-     vtm.mode = VT_PROCESS;
-     vtm.relsig = SIGUSR1; /* handled by release_vt() */
-     vtm.acqsig = SIGUSR2; /* handled by acquire_vt() */
-+    vtm.frsig = SIGUSR1;  /* needed by FreeBSD */
-     ioctl(vfd, VT_SETMODE, &vtm);
-   }
- 
--- security/vlock/files/patch-aa
+++ /dev/null
@@ -1,36 +0,0 @@
---- Makefile.orig	Thu Jan 14 01:19:14 1999
-+++ Makefile	Wed Jun 16 17:23:34 2004
-@@ -1,24 +1,19 @@
- # vlock makefile
- 
--CC = gcc
--# remove the -DUSE_PAM, -ldl, and -lpam if you aren't using PAM
--RPM_OPT_FLAGS=-O2
--CFLAGS = $(RPM_OPT_FLAGS) -DUSE_PAM
--LDFLAGS = -ldl -lpam -lpam_misc
-+CFLAGS += -DUSE_PAM
-+LDFLAGS = -lpam
- 
- OBJS = vlock.o signals.o help.o terminal.o input.o
- 
--vlock: $(OBJS)
-+all:	vlock
- 
--vlock.man: vlock.1
--	groff -man -Tascii vlock.1 > vlock.man
-+vlock:	$(OBJS)
-+	cc $(OBJS) $(LDFLAGS) -o vlock
- 
--vlock.o: vlock.h version.h
--signals.o: vlock.h
--help.o: vlock.h
--terminal.o: vlock.h
--input.o: vlock.h
-+install:
-+	/usr/bin/install -c -s -o root -g wheel -m 4555 vlock ${PREFIX}/bin
-+	/usr/bin/install -c -o root -g wheel -m 444 vlock.1 ${MANPREFIX}/man/man1
- 
- clean:
--	rm -f $(OBJS) vlock core core.vlock
-+	rm -f $(OBJS) vlock vlock.core
- 


More information about the Midnightbsd-cvs mailing list