Subject: Re: rc.subr on Linux
To: Louis Guillaume <lguillaume@berklee.edu>
From: reed <reed@reedmedia.net>
List: tech-pkg
Date: 07/03/2007 16:31:20
> I'm running into an issue on RedHat: rc.subr has _RCCMD_su="/usr/bin/su"
> but su on Linux is in /bin/su. Same issue appears to be there on
> Debian/Ubuntu, but I don't have a Slackware machine or other Linuxes to
> look at.
> 
> I looked for any other issues with rc.subr in general and found none.
> Here's a patch...
> 
> --- files/rc.subr.orig  2007-07-03 18:49:06.000000000 -0400
> +++ files/rc.subr       2007-07-03 18:49:28.000000000 -0400
> @@ -99,6 +99,7 @@
>                 _RCCMD_nice=$(which nice)
>  #              _RCCMD_rcs="/usr/bin/rcs"               # not in
> Slackware 8.1
>  #              _RCCMD_systrace="/bin/systrace"         # not in
> Slackware 8.1
> +               _RCCMD_su="/bin/su"
>                 _RCARG_ps="ax"
>                 ;;
>  esac

At one time, I had patches so this rc.subr would lose this and just get 
the information directory from pkgsrc/mk/platform/*mk (and Linux.mk there 
appears to be correct).

It has been three years, but my pkgsrc-wip version wip/rc.subr has:

_RCCMD_su="@SU@"

and that is defined at package build time.

I thought I asked for any okay to commit my improvements but never 
received any answer. Anyone care if I improve this?

  Jeremy C. Reed