From owner-freebsd-ports-bugs@FreeBSD.ORG Fri Jan 20 12:10:21 2006 Return-Path: X-Original-To: freebsd-ports-bugs@hub.freebsd.org Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B86A616A41F for ; Fri, 20 Jan 2006 12:10:21 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 262D143D5E for ; Fri, 20 Jan 2006 12:10:15 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id k0KCAE8o004121 for ; Fri, 20 Jan 2006 12:10:14 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id k0KCAEVu004120; Fri, 20 Jan 2006 12:10:14 GMT (envelope-from gnats) Resent-Date: Fri, 20 Jan 2006 12:10:14 GMT Resent-Message-Id: <200601201210.k0KCAEVu004120@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, Lapo Luchini Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A71D416A420 for ; Fri, 20 Jan 2006 12:03:11 +0000 (GMT) (envelope-from lapo@mail.lapo.it) Received: from mail.lapo.it (static.88-198-0-105.clients.your-server.de [88.198.0.105]) by mx1.FreeBSD.org (Postfix) with SMTP id 19C7C43D8E for ; Fri, 20 Jan 2006 12:02:57 +0000 (GMT) (envelope-from lapo@mail.lapo.it) Received: (qmail 45266 invoked by uid 1001); 20 Jan 2006 12:02:56 -0000 Message-Id: <20060120120256.45265.qmail@mail.lapo.it> Date: 20 Jan 2006 12:02:56 -0000 From: Lapo Luchini To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: ale@FreeBSD.org, garga@FreeBSD.org Subject: ports/92054: ports/net-im/jabber-py(icq|msn) rc.d files misbehave X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Lapo Luchini List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jan 2006 12:10:21 -0000 >Number: 92054 >Category: ports >Synopsis: ports/net-im/jabber-py(icq|msn) rc.d files misbehave >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Jan 20 12:10:14 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Lapo Luchini >Release: FreeBSD 6.0-RELEASE amd64 >Organization: >Environment: System: FreeBSD motoko.lapo.it 6.0-RELEASE FreeBSD 6.0-RELEASE #0: Wed Nov 2 19:07:38 UTC 2005 root@rat.samsco.home:/usr/obj/usr/src/sys/GENERIC amd64 >Description: The rc.d scripts distributed with ports/net-im/jabber-pyicq and ports/net-im/jabber-pymsn don't honor the variables put in rc.conf. >How-To-Repeat: Change some vars in rc.conf and "start" the service. >Fix: I did the following mods the rc.d files and found some probable errors: Changed jabber_pyicq_dir=${jabberd_pyicq_dir-"/usr/local/lib/jabber/pyicq"} to jabber_pyicq_dir=${jabber_pyicq_dir:-"/usr/local/lib/jabber/pyicq"} Moved load_rc_config $name higher in the file, else the command_ lines do not "see" the rc.conf settings. Added the missing -o option to command_args="-o pid=${pidfile} &" Follows my full working pyicq script. pymsn needed the same mods but also seems that xml file configuration about the PID file overrides the one passed as -o, differently from pyicq. --- jabber-pyicq-transport.sh begins here --- #!/bin/sh # Start or stop jabber-pyicq # $FreeBSD: ports/net-im/jabber-pyicq/files/jabber-pyicq-transport.sh.in,v 1.1 2005/06/07 15:18:15 pav Exp $ # PROVIDE: jabber_pyicq # REQUIRE: DAEMON # BEFORE: LOGIN # KEYWORD: FreeBSD shutdown # # Define these jabber_pyicq_* variables in one of these files: # /etc/rc.conf # /etc/rc.conf.local # # DO NOT CHANGE THESE DEFAULT VALUES HERE # jabber_pyicq_dir=${jabber_pyicq_dir:-"/usr/local/lib/jabber/pyicq"} jabber_pyicq_piddir=${jabber_pyicq_piddir:-"/var/jabberd/pid"} jabber_pyicq_enable=${jabber_pyicq_enable:-"NO"} . /etc/rc.subr name="jabber_pyicq" rcvar=`set_rcvar` load_rc_config $name pidfile="${jabber_pyicq_piddir}/pyicq.pid" command_interpreter="/usr/local/bin/python" command="${jabber_pyicq_dir}/main.py" command_args="-o pid=${pidfile} &" run_rc_command "$1" --- jabber-pyicq-transport.sh ends here --- >Release-Note: >Audit-Trail: >Unformatted: