From owner-cvs-all@FreeBSD.ORG Mon Aug 21 02:02:19 2006 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0503116A4DA; Mon, 21 Aug 2006 02:02:19 +0000 (UTC) (envelope-from yar@comp.chem.msu.su) Received: from comp.chem.msu.su (comp.chem.msu.su [158.250.32.97]) by mx1.FreeBSD.org (Postfix) with ESMTP id 979B043D4C; Mon, 21 Aug 2006 02:02:17 +0000 (GMT) (envelope-from yar@comp.chem.msu.su) Received: from comp.chem.msu.su (localhost [127.0.0.1]) by comp.chem.msu.su (8.13.4/8.13.3) with ESMTP id k7L22DSR042425; Mon, 21 Aug 2006 06:02:13 +0400 (MSD) (envelope-from yar@comp.chem.msu.su) Received: (from yar@localhost) by comp.chem.msu.su (8.13.4/8.13.3/Submit) id k7L228cS042422; Mon, 21 Aug 2006 06:02:08 +0400 (MSD) (envelope-from yar) Date: Mon, 21 Aug 2006 06:02:08 +0400 From: Yar Tikhiy To: Giorgos Keramidas Message-ID: <20060821020208.GD36875@comp.chem.msu.su> References: <200608181210.k7ICAIme084410@repoman.freebsd.org> <86ejvet9m6.fsf@xps.des.no> <20060818143310.GA14203@comp.chem.msu.su> <20060818143508.GA2545@lor.one-eyed-alien.net> <20060818153744.GA14726@comp.chem.msu.su> <20060820185525.GA12000@gothmog.pc> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20060820185525.GA12000@gothmog.pc> User-Agent: Mutt/1.5.9i Cc: Brooks Davis , Dag-Erling Sm?rgrav , src-committers@FreeBSD.org, cvs-all@FreeBSD.org, cvs-src@FreeBSD.org Subject: Re: cvs commit: src/etc rc.subr X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Aug 2006 02:02:19 -0000 On Sun, Aug 20, 2006 at 09:55:25PM +0300, Giorgos Keramidas wrote: > On 2006-08-18 19:37, Yar Tikhiy wrote: > > On Fri, Aug 18, 2006 at 09:35:08AM -0500, Brooks Davis wrote: > > > On Fri, Aug 18, 2006 at 06:33:11PM +0400, Yar Tikhiy wrote: > > > > On Fri, Aug 18, 2006 at 04:13:37PM +0200, Dag-Erling Sm?rgrav wrote: > > > > > Yar Tikhiy writes: > > > > > > Log: > > > > > > The ps(1) command is unfriendly to scripts by default because > > > > > > it limits the width of its output to the value of $COLUMNS, or > > > > > > what TIOCGWINSZ reports, or 79 columns. We should specify -ww > > > > > > to ps(1) so that it removes the limit and prints lines in full. > > > > > > Otherwise very long command pathnames could be mishandled, e.g., > > > > > > by _find_processes(). > > > > > > > > > > or perhaps _find_processes() should use pgrep(1) instead of ps(1). > > > > > > > > I considered that but had to stick to ps(1) because pgrep was in > > > > /usr/bin while ps was in /bin. The use of /usr/bin tools should > > > > be very limited in rc.subr(8). OTOH, pgrep uses /lib libs only, > > > > which makes it possible to transfer pgrep+pkill to /bin if we can > > > > stand the growth of / by some 50 kbytes. > > > > > > I think that's appropriate since pgrep is such an obvious fit for this > > > sort of thing. I think we'll want to consider compatability symlinks > > > due to existing hardcoded paths in scripts. > > > > Creating the compat symlinks should be as easy as adding the following > > lines to the Makefile: > > > > SYMLINKS= ${BINDIR}/pgrep /usr/bin/pgrep > > SYMLINKS+= ${BINDIR}/pkill /usr/bin/pkill > > Hmmm. Shouldn't this be using ${DESTDIR} in the right-hand paths? I thought the same, peeked in /usr/share/mk/bsd.links.mk, and found that it would take care of ${DESTDIR} internally. I had to scratch my head a couple of times before I got why ${DESTDIR} was prepended to both paths in LINKS, but only to the right-hand path in SYMLINKS. :-) -- Yar