[auton-users] arch*.sh scripts

Dan Pelleg dpelleg+ at cs.cmu.edu
Mon Jun 23 15:29:43 EDT 2003


Paul Komarek writes:
 > On Mon, 2003-06-23 at 14:57, Dan Pelleg wrote:
 > > Both of the new scripts fail on FreeBSD because /bin/bash is not installed
 > > there. There are many other systems in which this is true as well.
 > > 
 > > As far as I know /bin/sh is pretty much guaranteed to exist on any
 > > UNIX-like system.
 > 
 > I agree that there are many borken systems out there. ;-)
 > 
 > Would you mind checking for sh compatibility?  On GNU/Linux systems, sh
 > is a symlink to bash, and bash doesn't completely disable all bash-isms
 > in sh-mode.  Perhaps the easiest thing to do is symlink /bin/bash ->
 > /bin/sh and try running them.
 > 
 > -Paul

Paul already found one non-standard call ( $() instead of `` - I'd have
missed this since the FreeBSD sh also happens to support this). Apart from
that, "make" needs to be "gmake" everywhere.

With this change I can make "sh ../smallbutuseful/archdir.sh" work.

archexe.sh doesn't like the pushd/popd. Maybe just enclose a big chunk in a
() block (meaning to spawn a subshell for it, which forget all the "cd"s
you do after it terminates).



More information about the Autonlab-users mailing list