Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!usc!elroy.jpl.nasa.gov!jpl-devvax!lwall From: lwall@jpl-devvax.JPL.NASA.GOV (Larry Wall) Newsgroups: comp.lang.perl Subject: Re: perl 3@40 fails test lib.big Message-ID: <10394@jpl-devvax.JPL.NASA.GOV> Date: 15 Nov 90 18:33:59 GMT References: <1990Nov10.230258.21946@ircam.ircam.fr> <1990Nov14.140021.5953@ping.uucp> Reply-To: lwall@jpl-devvax.JPL.NASA.GOV (Larry Wall) Organization: Jet Propulsion Laboratory, Pasadena, CA Lines: 24 In article <1990Nov14.140021.5953@ping.uucp> gorpong@ping.uucp (Gordon C. Galligher) writes: : I also believe that the first line of lib.big should be ./perl -x : not just perl, in order to take advantage of the __END__ stuff in the file. : I executed ./perl lib.big and ./perl -x lib.big and it works regardless of : the -x switch. Is it a side effect that if an __END__ exists then the rest : is automatically used as and the -x is not needed, or is the -x merely : there to tell perl to skip to a #!perl and start executing to an __END__? The -x has nothing to do with __END__, other than the similarity that both are used to trim excess garbage from a script. The -x lets you trim garbage before #!. The __END__ lets you trim garbage after the __END__. The -x is really only useful when the #! line is not the first line of the file. Ordinary scripts never need it--the intent is to allow you to pipe articles to perl that contain scripts. will work any time there is an __END__. Your make problem sounds like it stems from a make that supplies a different context than the shell. Perhaps there is some subtle interaction between DATA and STD{IN,OUT,ERR}. Some makes attach STDIN to /dev/null, for instance. I don't know why that would louse up DATA though. Larry