From owner-freebsd-ports-bugs@FreeBSD.ORG Sat Jun 4 09:30:13 2011 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9430D1065676 for ; Sat, 4 Jun 2011 09:30:13 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 6923D8FC22 for ; Sat, 4 Jun 2011 09:30:13 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p549UDN0032821 for ; Sat, 4 Jun 2011 09:30:13 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p549UDEo032813; Sat, 4 Jun 2011 09:30:13 GMT (envelope-from gnats) Resent-Date: Sat, 4 Jun 2011 09:30:13 GMT Resent-Message-Id: <201106040930.p549UDEo032813@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Chris Rees Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 578D1106566C for ; Sat, 4 Jun 2011 09:20:58 +0000 (UTC) (envelope-from utisoft@hotmail.com) Received: from blu0-omc1-s8.blu0.hotmail.com (blu0-omc1-s8.blu0.hotmail.com [65.55.116.19]) by mx1.freebsd.org (Postfix) with ESMTP id 0F3AB8FC21 for ; Sat, 4 Jun 2011 09:20:57 +0000 (UTC) Received: from BLU0-SMTP109 ([65.55.116.9]) by blu0-omc1-s8.blu0.hotmail.com with Microsoft SMTPSVC(6.0.3790.4675); Sat, 4 Jun 2011 02:20:57 -0700 Received: from zeus.bayofrum.net ([90.221.7.100]) by BLU0-SMTP109.phx.gbl over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Sat, 4 Jun 2011 02:20:55 -0700 Received: from zeus.bayofrum.net (crees@localhost [127.0.0.1]) by zeus.bayofrum.net (8.14.4/8.14.4) with ESMTP id p549FPTB012771 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES256-SHA bits=256 verify=NO) for ; Sat, 4 Jun 2011 10:15:26 +0100 (BST) (envelope-from chris@zeus.bayofrum.net) Received: (from crees@localhost) by zeus.bayofrum.net (8.14.4/8.14.4/Submit) id p549FPZH012770; Sat, 4 Jun 2011 10:15:25 +0100 (BST) (envelope-from chris) Message-Id: Date: Sat, 4 Jun 2011 10:15:25 +0100 From: Chris Rees Sender: To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: ports/157585: Fix port: java/jboss2 should use USERS X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Chris Rees List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 04 Jun 2011 09:30:13 -0000 >Number: 157585 >Category: ports >Synopsis: Fix port: java/jboss2 should use USERS >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: Sat Jun 04 09:30:12 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@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= >How-To-Repeat: >Fix: - Use USERS and GROUPS Submitted by: Chris Rees (utisoft@gmail.com) Please note that pkg-install has been removed --- java-jboss2.patch begins here --- Index: Makefile =================================================================== RCS file: /exports/cvsroot-freebsd/ports/java/jboss2/Makefile,v retrieving revision 1.27 diff -u -r1.27 Makefile --- Makefile 8 Dec 2009 09:23:20 -0000 1.27 +++ Makefile 2 Jun 2011 20:35:44 -0000 @@ -41,7 +41,8 @@ STARTUP_SCRIPT= ${PREFIX}/etc/rc.d/${STARTUP_ORDER}.${STARTUP_SCRIPT_NAME} USER= www GROUP= www -PW?= /usr/sbin/pw +USERS= ${USER} +GROUPS= ${GROUP} STDOUT_LOG= ${LOG_DIR}/stdout.log STDERR_LOG= ${LOG_DIR}/stderr.log AUTO_START?= NO @@ -116,7 +117,6 @@ @${ECHO_CMD} " Logfile stderr: ${STDERR_LOG}" @${ECHO_CMD} " Starting after install: ${AUTO_START}" @${ECHO_CMD} " Stop time-out: ${STOP_TIMEOUT} sec." - @PKG_PREFIX=${PREFIX} ${SH} pkg-install ${PKGNAME} PRE-INSTALL do-install: @${ECHO_CMD} -n ">> Creating destination directory..." Index: pkg-deinstall =================================================================== RCS file: /exports/cvsroot-freebsd/ports/java/jboss2/pkg-deinstall,v retrieving revision 1.1 diff -u -r1.1 pkg-deinstall --- pkg-deinstall 26 Apr 2002 21:54:15 -0000 1.1 +++ pkg-deinstall 2 Jun 2011 20:33:49 -0000 @@ -35,11 +35,4 @@ fi fi -if [ "$2" = "POST-DEINSTALL" ]; then - # If the user exists, then display a message - if pw usershow "www" 2>/dev/null 1>&2; then - echo "To delete the www user permanently, use 'pw userdel www'" - fi -fi - exit 0 Index: pkg-install =================================================================== RCS file: pkg-install diff -N pkg-install --- pkg-install 26 Apr 2002 21:54:15 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,46 +0,0 @@ -#!/bin/sh -# -# Checks if the 'www' user and group exist. If they don't, then -# an attempt is made to create both. -# -# $FreeBSD: ports/java/jboss2/pkg-install,v 1.1 2002/04/26 21:54:15 znerd Exp $ -# - -# Make sure we're called during the 'make install' process -if [ "$2" != "PRE-INSTALL" ]; then - exit 0 -fi - -# Set some constants -USER=www -GROUP=${USER} -UID=80 -GID=${UID} - -# See if the group already exists -if ! pw groupshow "${GROUP}" 2>/dev/null 1>&2; then - - # If not, try to create it - if pw groupadd ${GROUP} -g ${GID}; then - echo "Added group \"${GROUP}\"." - else - echo "Adding group \"${GROUP}\" failed..." - exit 1 - fi -fi - -# See if the user already exists -if ! pw usershow "${USER}" 2>/dev/null 1>&2; then - - # If not, try to create it - if pw useradd ${USER} -u ${UID} -g ${GROUP} -h - \ - -s "/sbin/nologin" -d "/nonexistent" \ - -c "World Wide Web Owner"; \ - then - echo "Added user \"${USER}\"." - else - echo "Adding user \"${USER}\" failed..." - exit 1 - fi -fi -exit 0 --- java-jboss2.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: