Glen Barber <g...@freebsd.org> wrote in <20130813175335.gr2...@glenbarber.us>:
gj> On Tue, Aug 13, 2013 at 11:31:52AM -0600, Ian Lepore wrote: gj> > I'm not even sure what $0 *should* expand to in a script that was gj> > sourced in. The manpage doesn't say anything meaningful to me about it. gj> > Maybe it's a kind of "indeterminate results" thing which is pretty much gj> > what we're seeing. gj> > gj> gj> When the file is sourced, it should expand to the name of the file gj> sourcing the file. It is sourced in the osreldate.h target in Makefile, so $0 will be /bin/sh. Why $0 is used here in the first place? The previous version used $SYSDIR and it looks more reasonable to me. -- Hiroki
pgpcsMMzfqkJt.pgp
Description: PGP signature