Pathologically Eclectic Rubbish Lister | |
PerlMonks |
Re: "Strawberry Perl" - can it live together with ActivePerl 5.10.0 Build 1003 (on WinXP)?by syphilis (Archbishop) |
on Aug 24, 2008 at 09:37 UTC ( [id://706521]=note: print w/replies, xml ) | Need Help?? |
Yes, you can have as many different perls as you want on the one machine without having any interference problems - so long as you install them to separate locations and, while installing them, you don't let any of them alter the system path. (If they do add their own location to the system path during installation, then it's no big deal - you just undo those changes as soon as the installation has completed.) Then it's just a matter of setting the system path variable to find whichever perl you want to use. For me, that means that for Strawberry Perl I run: If I want to run ActivePerl build 1003: And for ActivePerl build 822: Rather than remembering where all of these different perls are installed, it's easier to put those commands in separate batch files, and then just run the appropriate batch file for whichever perl you want. For example, if I want to use ActivePerl build I just run ap822.bat which sets the path (and any other environment variables I might want set) appropriately for me. Can I define for a script which Perl to use? I don't think so (if I understand the question correctly). Any time "perl" is invoked, it will be the first "perl" executable to be found that will be run. You can, of course, always call a specific perl executable by quoting the full path to it - eg C:\strawberry\perl\bin\perl script.pl will always run C:\strawberry\perl\bin\perl.exe no matter which "perl" (if any) comes first in the path environment variable. Cheers, Rob
In Section
Seekers of Perl Wisdom
|
|