Bug 157545 - [PATCH] comms/gnokii should use GROUPS=
Summary: [PATCH] comms/gnokii should use GROUPS=
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Rene Ladan
Depends on:
Reported: 2011-06-02 22:10 UTC by Chris Rees
Modified: 2011-06-06 22:13 UTC (History)
0 users

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Chris Rees 2011-06-02 22:10:09 UTC

	This port uses pkg-install to create new groups instead of using GROUPS=. It also removes the group on deinstall, which could break other installed ports.

Fix: - Use GROUPS
	- Stop removing GROUPS on deinstall

	Submitted by: Chris Rees (utisoft@gmail.com)

	This PR depends on ports/157528 -- the gnokii group isn't in GIDs as of yet

This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.--TfvdqtPvAK9hl3nwyHBJTEfxduBAywXoghooAMdEx42xrhNk
Content-Type: text/plain; name="comms-gnokii.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="comms-gnokii.patch"

Index: Makefile
RCS file: /exports/cvsroot-freebsd/ports/comms/gnokii/Makefile,v
retrieving revision 1.88
diff -u -r1.88 Makefile
--- Makefile	26 Jan 2011 13:47:03 -0000	1.88
+++ Makefile	2 Jun 2011 11:42:06 -0000
@@ -21,6 +21,7 @@
 BUILD_DEPENDS=	${SITE_PERL}/${PERL_ARCH}/XML/Parser.pm:${PORTSDIR}/textproc/p5-XML-Parser
 USE_BZIP2=	yes
@@ -38,7 +39,6 @@
 		LIBS="-L${WRKSRC}/common -L${LOCALBASE}/lib" \
 SUB_FILES+=	pkg-message
 MAN1=		gnokii.1 sendsms.1 xgnokii.1
@@ -126,9 +126,6 @@
 	@${MV} ${WRKSRC}/Docs/man/xgnokii.1x ${WRKSRC}/Docs/man/xgnokii.1
 	${INSTALL_DATA} ${WRKSRC}/xgnokii/xgnokii.pc ${PREFIX}/libdata/pkgconfig
Index: pkg-install
RCS file: /exports/cvsroot-freebsd/ports/comms/gnokii/pkg-install,v
retrieving revision 1.2
diff -u -r1.2 pkg-install
--- pkg-install	13 Nov 2005 18:28:39 -0000	1.2
+++ pkg-install	2 Jun 2011 11:41:19 -0000
@@ -2,8 +2,6 @@
 SUIDBINS="${PKG_PREFIX}/sbin/gnokiid ${PKG_PREFIX}/sbin/mgnokiidev"
 BINS="${PKG_PREFIX}/bin/gnokii ${SUIDBINS}"
@@ -12,30 +10,10 @@
 case "$2" in
-	if pw group show "${GROUP}" 2>/dev/null; then
-		echo "You already have a group \"${GROUP}\", so I will use it."
-	else
-		if pw groupadd ${GROUP}; then
-			echo "Added group \"${GROUP}\"."
-		else
-			echo "Adding group \"${GROUP}\" failed..."
-			exit 1
-		fi
-	fi
-	;;
 	chgrp $GROUP $BINS
 	chmod 750 ${BINS}
 	chmod u+s ${SUIDBINS}
-	if [ -z "`pw groupshow $GROUP 2>&1 | sed -E -e 's/^([^:]+:){3}(.*)$/\2/'`" ]; then
-		echo "Removing empty group \"$GROUP\"."
-		pw groupdel $GROUP
-	fi
-	;;
Comment 1 Edwin Groothuis freebsd_committer 2011-06-02 22:10:23 UTC
Maintainer of comms/gnokii,

Please note that PR ports/157545 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:

Edwin Groothuis via the GNATS Auto Assign Tool
Comment 2 Edwin Groothuis freebsd_committer 2011-06-02 22:10:25 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 3 Guido Falsi freebsd_committer 2011-06-03 13:04:47 UTC
I 've looked at the patch and see no problem with this, so I approve, 
obviously once also ports/157528 has been committed.

Thank you!

Guido Falsi <mad@madpilot.net>
Comment 4 Rene Ladan freebsd_committer 2011-06-03 15:04:34 UTC
Responsible Changed
From-To: freebsd-ports-bugs->rene

Comment 5 dfilter service freebsd_committer 2011-06-06 20:27:13 UTC
rene        2011-06-06 19:27:00 UTC

  FreeBSD ports repository

  Modified files:
    comms/gnokii         Makefile pkg-install 
  Change this port to use the GROUPS variable
  PR:             ports/157545
  Submitted by:   Chris Rees [utisoft gmail com]
  Approved by:    maintainer
  Revision  Changes    Path
  1.89      +1 -4      ports/comms/gnokii/Makefile
  1.3       +0 -22     ports/comms/gnokii/pkg-install
cvs-all@freebsd.org mailing list
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 6 Rene Ladan freebsd_committer 2011-06-06 22:11:59 UTC
State Changed
From-To: feedback->closed

Committed, thanks