ports/157537: [PATCH] Modify port: chinese/firebird to use USERS and GROUPS
Chris Rees
utisoft at gmail.com
Thu Jun 2 18:20:11 UTC 2011
>Number: 157537
>Category: ports
>Synopsis: [PATCH] Modify port: chinese/firebird to use USERS and GROUPS
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Thu Jun 02 18:20:10 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: Chris Rees
>Release: FreeBSD 8.2-RELEASE-p1 i386
>Organization:
bayofrum
>Environment:
System: FreeBSD zeus.bayofrum.net 8.2-RELEASE-p1 FreeBSD 8.2-RELEASE-p1 #0: Sat Apr 30 15:09:06 BST 2011 root at zeus.bayofrum.net:/usr/obj/usr/src/sys/ZEUS i386
>Description:
This port uses pkg-install to create new users instead of using USERS= and GROUPS=.
Since it's an interactive port, I can't Tinderbox it, and it appears to break compiling on i386.
Edward, can you test its compilation and review the attached patch before approving?
>How-To-Repeat:
>Fix:
- Use USERS and GROUPS
Submitted by: Chris Rees (utisoft at gmail.com)
This depends on ports/157528; that PR contains the bbs user that this port uses.
XXX I've removed the pkg-install script
--- chinese-firebird.patch begins here ---
Index: Makefile
===================================================================
RCS file: /exports/cvsroot-freebsd/ports/chinese/firebird/Makefile,v
retrieving revision 1.11
diff -u -r1.11 Makefile
--- Makefile 15 Nov 2006 08:56:28 -0000 1.11
+++ Makefile 2 Jun 2011 11:22:50 -0000
@@ -18,9 +18,10 @@
USE_BZIP2= yes
IS_INTERACTIVE= yes
NOT_FOR_ARCHS= amd64
+USERS= bbs
+GROUPS= ${USERS}
pre-install:
- ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
${FIND} ${WRKSRC} -name "*.orig" -delete
post-install:
Index: pkg-install
===================================================================
RCS file: pkg-install
diff -N pkg-install
--- pkg-install 16 Feb 2001 13:35:31 -0000 1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,38 +0,0 @@
-#!/bin/sh
-
-PATH=/bin:/usr/sbin
-USER=bbs
-GROUP=bbs
-UID=9999
-GID=99
-
-case $2 in
-PRE-INSTALL)
-
- 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} -g ${GID}; then
- echo "Added group \"${GROUP}\"."
- else
- echo "Adding group \"${GROUP}\" failed..."
- exit 1
- fi
- fi
-
- if pw user show "${USER}" 2>/dev/null; then
- echo "You already have a user \"${USER}\", so I will use it."
- else
- if pw useradd ${USER} -u ${UID} -g ${GROUP} -h - \
- -d /usr/local/bbs -s /sbin/nologin -c "Firebird BBS"
- then
- echo "Added user \"${USER}\"."
- else
- echo "Adding user \"${USER}\" failed..."
- exit 1
- fi
- fi
-
- ;;
-
-esac
--- chinese-firebird.patch ends here ---
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list