Date: Fri, 6 Dec 2013 12:25:48 +0000 (UTC) From: Ganael LAPLANCHE <martymac@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r335740 - in head/security/vlock: . files Message-ID: <201312061225.rB6CPm2B049023@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: martymac Date: Fri Dec 6 12:25:48 2013 New Revision: 335740 URL: http://svnweb.freebsd.org/changeset/ports/335740 Log: - Enable staging - Update USES - Use new options framework - Always stage documentation - Strip installed binaries Added: head/security/vlock/files/patch-Makefile (contents, props changed) head/security/vlock/files/patch-modules-Makefile (contents, props changed) Modified: head/security/vlock/Makefile (contents, props changed) head/security/vlock/pkg-plist (contents, props changed) Modified: head/security/vlock/Makefile ============================================================================== --- head/security/vlock/Makefile Fri Dec 6 12:19:21 2013 (r335739) +++ head/security/vlock/Makefile Fri Dec 6 12:25:48 2013 (r335740) @@ -3,6 +3,7 @@ PORTNAME= vlock PORTVERSION= 2.2.3 +PORTREVISION= 1 CATEGORIES= security MASTER_SITES= http://cthulhu.c3d2.de/~toidinamai/vlock/archive/ @@ -11,76 +12,52 @@ COMMENT= Locks a terminal LICENSE= GPLv2 -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" \ + VLOCK_GROUP="nobody" \ EXTRA_CFLAGS="-I${LOCALBASE}/include" \ EXTRA_LDFLAGS="-L${LOCALBASE}/lib" +USES= gmake USE_CSTD= gnu99 OPTIONS_DEFINE= ROOTPWD VLOCKSCRIPTS CACASAVER OPTIONS_DEFAULT= ROOTPWD +OPTIONS_SUB= yes ROOTPWD_DESC= Enable unlock using root password +ROOTPWD_CONFIGURE_ENABLE= root-password VLOCKSCRIPTS_DESC= Install sample hook scripts CACASAVER_DESC= Enable libcaca screensaver - -MANLANG= "" -MAN1= vlock.1 -MAN5= vlock-plugins.5 -MAN8= vlock-main.8 +CACASAVER_BUILD_DEPENDS= ${LOCALBASE}/lib/libcaca.a:${PORTSDIR}/graphics/libcaca # Default scripts/modules VLOCKSCRIPTS= VLOCKMODULES= all.so new.so -NO_STAGE= yes -# Vlock group = vlock:*:129: -VLOCKGRP= vlock -VLOCKGID= 129 +# Vlock special group +VLOCK_GRP= vlock +GROUPS= ${VLOCK_GRP} +PLIST_SUB+= VLOCK_GRP=${VLOCK_GRP} \ + SHAREMODE=${SHAREMODE} \ + SHAREGRP=${SHAREGRP} PORTDOCS= ChangeLog PLUGINS README README.X11 SECURITY TODO -.include <bsd.port.pre.mk> - -.if ${PORT_OPTIONS:MROOTPWD} -CONFIGURE_ARGS+= --enable-root-password -.else -CONFIGURE_ARGS+= --disable-root-password -.endif +.include <bsd.port.options.mk> .if ${PORT_OPTIONS:MVLOCKSCRIPTS} VLOCKSCRIPTS+= amarok.sh example_script.sh mplayer.sh -PLIST_SUB+= PL_VLOCKSCRIPTS="" -.else -PLIST_SUB+= PL_VLOCKSCRIPTS="@comment " .endif .if ${PORT_OPTIONS:MCACASAVER} -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 ${PORT_OPTIONS:MDOCS} - @${MKDIR} ${DOCSDIR} -.for doc in ${PORTDOCS} - ${INSTALL_DATA} ${WRKSRC}/${doc} ${DOCSDIR} -.endfor -.endif + ${MKDIR} ${STAGEDIR}${DOCSDIR} + ${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR} -.include <bsd.port.post.mk> +.include <bsd.port.mk> Added: head/security/vlock/files/patch-Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/security/vlock/files/patch-Makefile Fri Dec 6 12:25:48 2013 (r335740) @@ -0,0 +1,11 @@ +--- Makefile.orig 2013-11-20 17:41:38.000000000 +0100 ++++ Makefile 2013-11-20 17:43:12.000000000 +0100 +@@ -59,7 +59,7 @@ + $(MKDIR_P) -m 755 $(DESTDIR)$(PREFIX)/bin + $(INSTALL) -m 755 -o root -g $(ROOT_GROUP) vlock $(DESTDIR)$(BINDIR)/vlock + $(MKDIR_P) -m 755 $(DESTDIR)$(PREFIX)/sbin +- $(INSTALL) -m 4711 -o root -g $(ROOT_GROUP) vlock-main $(DESTDIR)$(SBINDIR)/vlock-main ++ $(INSTALL) -s -m 4711 -o root -g $(ROOT_GROUP) vlock-main $(DESTDIR)$(SBINDIR)/vlock-main + + .PHONY: install-plugins + install-plugins: install-modules install-scripts Added: head/security/vlock/files/patch-modules-Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/security/vlock/files/patch-modules-Makefile Fri Dec 6 12:25:48 2013 (r335740) @@ -0,0 +1,20 @@ +--- modules/Makefile.orig 2013-11-20 17:39:23.000000000 +0100 ++++ modules/Makefile 2013-11-20 17:40:03.000000000 +0100 +@@ -15,7 +15,7 @@ + + #special build rules + +-caca.so : override LDLIBS += -lcaca -lncurses ++caca.so : override LDLIBS += -lcaca -lm + + all.o: all.c ../src/console_switch.h + +@@ -37,7 +37,7 @@ + .PHONY: install-%.so + install-%.so: %.so + $(MKDIR_P) -m 755 $(DESTDIR)$(MODULEDIR) +- $(INSTALL) -m $(MODULE_MODE) -o root -g $(MODULE_GROUP) $< $(DESTDIR)$(MODULEDIR)/$< ++ $(INSTALL) -s -m $(MODULE_MODE) -o root -g $(MODULE_GROUP) $< $(DESTDIR)$(MODULEDIR)/$< + + .PHONY: clean + clean: Modified: head/security/vlock/pkg-plist ============================================================================== --- head/security/vlock/pkg-plist Fri Dec 6 12:19:21 2013 (r335739) +++ head/security/vlock/pkg-plist Fri Dec 6 12:25:48 2013 (r335740) @@ -1,12 +1,19 @@ bin/vlock -sbin/vlock-main +man/man1/vlock.1.gz +man/man5/vlock-plugins.5.gz +man/man8/vlock-main.8.gz +%%VLOCKSCRIPTS%%lib/vlock/scripts/amarok +%%VLOCKSCRIPTS%%lib/vlock/scripts/example_script +%%VLOCKSCRIPTS%%lib/vlock/scripts/mplayer +%%VLOCKSCRIPTS%%@dirrm lib/vlock/scripts lib/vlock/modules/all.so +%%CACASAVER%%lib/vlock/modules/caca.so +@mode 4711 +sbin/vlock-main +@mode 0750 +@group %%VLOCK_GRP%% lib/vlock/modules/new.so -%%PL_CACASAVER%%lib/vlock/modules/caca.so +@mode %%SHAREMODE%% +@group %%SHAREGRP%% @dirrm lib/vlock/modules -%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/amarok -%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/example_script -%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/mplayer -%%PL_VLOCKSCRIPTS%%@dirrm lib/vlock/scripts @dirrm lib/vlock -@exec if ! pw groupshow vlock 2>/dev/null; then pw groupadd vlock -g 129; fi
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201312061225.rB6CPm2B049023>