From: Dan Anderson <[EMAIL PROTECTED]> > I'm new to Perl, and my book says that Perl can be compiled. Does > this mean there is a command like $ perl --compile --file ./script or > does this just mean that instead of parsing line by line everything is > checked for errors and then run? (i.e. Just in Time compilation)
Perl doesn't parse line by line or anything like that. It more or less compiles the whole script+modules before it starts to execute it. These parts are a bit more complex than that, but for now you can assume it does compile everything before execution. What you are after most probably is some way to create a native executable that could be executed on computers without Perl installed. There are basicaly two ways to do that. First you could use perlcc to really compile the script ... but that's highly experimental and not recommended in production. You don't want to go there yet. The other way is to wrap the script plus all modules plus the perl runtime into an executable. This is what PAR (you may find it on CPAN), perl2exe (www.perl2exe.com) and PerlApp (www.activestate.com) do. This is well tested and widely used. The executables tend to be a little big and you do not get any speed gain, but you can redistribute those easily. Jenda ===== [EMAIL PROTECTED] === http://Jenda.Krynicky.cz ===== When it comes to wine, women and song, wizards are allowed to get drunk and croon as much as they like. -- Terry Pratchett in Sourcery -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]