Best way for dealing with RC scripts

Oliver Eikemeier eikemeier at
Wed May 26 04:11:15 PDT 2004

Cyril Guibourg wrote:

> Hello,
> 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.
> 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-install
> in order to check ${OSVERSION} and then install the appropriate script.
> Is this a good way to do it or is there something better to do ?

use USE_RC_SUBR=yes and $SED -s,%%RC_SUBR%%,${RC_SUBR},g for your script.

More information about the freebsd-ports mailing list