Subject: Re: pkgsrc bootstrap kit for Solaris 10?
To: Alan Barrett <email@example.com>
From: Malcolm Herbert <firstname.lastname@example.org>
Date: 08/22/2006 10:08:46
On Thu, Aug 17, 2006 at 06:57:30PM +0200, Alan Barrett wrote:
|On Thu, 17 Aug 2006, Malcolm Herbert wrote:
|> I've unpacked the 2006Q2 pkgsrc snapshot and am trying to get it
|> working on this machine. For some reason I can't yet fathom, running
|> su - root sh -c "blah"
|> doesn't actually run blah, but brings up an interactive shell.
|The extra "sh" shouldn't be there. Try this:
| su - root -c "blah"
yes, sorry - that was a typo on my behalf
| * Use SU_CMD=su -m root -c (where the "-m" insuead of "-" is intended
| to make su invoke your $SHELL insteasd of the shell mentioned in
| root's entry in /etc/passwd), or SU_CMD=sudo /usr/xpg4/bin/sh -c.
I'm still having Issues getting pkgsrc to use /usr/xpg4/bin/sh
consistently, with su or sudo even when run as root with SHELL set
appropriately. Unfortunately I wasn't able to find a version of su which
accepts the -m flag (/bin/su, /sbin/su nor /usr/bin/su)
Is there any config-file magic to allow sudo to change the environment
for a command run under it that ISN'T dependant on the calling
environment (ie, NOT using the -s option on the command-line, which
imports the calling SHELL)? That would solve my problems, I think ...
Malcolm Herbert This brain intentionally
email@example.com left blank