On Sunday, December 1, 2002, at 01:25 PM, [EMAIL PROTECTED] wrote:
On Friday, November 29, 2002, at 09:19 PM, Ken Williams wrote:
I see that in MacPerl (not perl for OS X), $Config{startperl}
is set to
"Perl -Sx \"{0}\" {\"Parameters\"}; Exit {Status}\n#!perl"
in Config.pm . I'm not sure what that extra stuff is before
the shebang, but when I run a script that contains that
(using MacPerl 5.6.1), I just get a perl syntax error. When
I remove it, all is > well.
Can anyone enlighten about what that first line is for?
That line is a MacPerl compatibility with MPW (Macintosh
Programmer's Workshop), the old Mac development environment.
According the MacPerl book, this line allow scripts to be
called directly from MPW without the need to call the Perl
tool directly. MacPerl knows to ignore this line, but Mac OS
X perl does not.
Hmm, from my testing, MacPerl 5.6.1 didn't know how to ignore
that line either. I got syntax errors until I removed it.
I think it is safe to leave it out (and only include the
appropriate shebang line), as if anyone is still using MPW,
they are probably used to adding that line to Perl scripts.
Okay, thanks, that's what I'll do.
-Ken