From owner-freebsd-ports@FreeBSD.ORG Wed May 26 04:22:56 2004 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6D11216A4CE for ; Wed, 26 May 2004 04:22:56 -0700 (PDT) Received: from smtp.infracaninophile.co.uk (happy-idiot-talk.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id EF70843D39 for ; Wed, 26 May 2004 04:22:54 -0700 (PDT) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost.infracaninophile.co.uk [IPv6:::1])i4QBMTcF026942 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 26 May 2004 12:22:29 +0100 (BST) (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost)id i4QBMTrF026941; Wed, 26 May 2004 12:22:29 +0100 (BST) (envelope-from matthew) Date: Wed, 26 May 2004 12:22:29 +0100 From: Matthew Seaman To: Cyril Guibourg Message-ID: <20040526112229.GD26430@happy-idiot-talk.infracaninophile.co.uk> References: <871xl7cx9p.fsf@blackbox.babasse.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="/3yNEOqWowh/8j+e" Content-Disposition: inline In-Reply-To: <871xl7cx9p.fsf@blackbox.babasse.net> User-Agent: Mutt/1.5.6i X-Virus-Scanned: clamd / ClamAV version devel-20040525, clamav-milter version 0.71 X-Virus-Status: Clean X-Spam-Status: No, hits=-4.8 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=2.63 X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on happy-idiot-talk.infracaninophile.co.uk cc: ports@freebsd.org Subject: Re: Best way for dealing with RC scripts X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 May 2004 11:22:56 -0000 --/3yNEOqWowh/8j+e Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, May 26, 2004 at 12:12:34PM +0200, Cyril Guibourg wrote: > I am in the final stage of creating a new port and I would like to get > some advice about the best way to handle differences between 4.X and 5.X > for the startup script. >=20 > The source of the port already comes from NetBSD pkgsrc with a RCNG style > script. I plan tocreate a 4.X script and add special targets in post-ins= tall > in order to check ${OSVERSION} and then install the appropriate script. >=20 > Is this a good way to do it or is there something better to do ? Just provide the rcNG startup script, and add: USE_RC_SUBR=3D yes to the Makefile. That will cause system versions 4.x or lower (actually it's ${OSVERSION} < 500037 to be pedantic) to install and add a RUN_DEPENDS on the sysutils/rc_subr port automatically. Cheers, Matthew=09 --=20 Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way PGP: http://www.infracaninophile.co.uk/pgpkey Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK --/3yNEOqWowh/8j+e Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFAtH31iD657aJF7eIRAkxJAJ0fJwAwrq7UfM3lY21YidR+z7HR6wCgtA+0 wPXYEHRNWjOkgSHbAF5zac8= =vyza -----END PGP SIGNATURE----- --/3yNEOqWowh/8j+e--