Stories
Slash Boxes
Comments

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

Ovid (2709)

Ovid
  (email not shown publicly)
http://publius-ovidius.livejournal.com/
AOL IM: ovidperl (Add Buddy, Send Message)

Stuff with the Perl Foundation. A couple of patches in the Perl core. A few CPAN modules. That about sums it up.

Journal of Ovid (2709)

Monday August 07, 2006
07:33 AM

How to tell if Perl is installed on your computer

[ #30554 ]

Every once in a while I find myself sitting up and thinking "why the hell did I just write that?" I still remember the time I needed a one-off to read the end of a logfile and keeping reading lines as they appeared, so I started to write some Perl code for that ...

After a couple of lines of realizing how stupid I was being, I very quietly deleted the code and hoped no one would notice. So today, I was quite amused to see I'm not the only one who does silly things. In a discussion of whether or not Perl was available on a particular Sun product, someone posted a handy shell script you can use to see if Perl is installed:

#!/bin/ksh
which perl
perl -V

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • If Perl isn't installed on a Sun product, that Sun product will likely not work properly. :-P

    And don't even *think* about upgrading the default Perl installation on a Solaris box.

    • And don't even *think* about upgrading the default Perl installation on a Solaris box.

      And rightly so. But unless many Linux distribution, Solaris doesn't mind at all if you install your own Perl build in /usr/bin/perl. See, on Solaris, /usr/bin/perl is just a link to the "default" Perl install of the Solaris box, and all system utilities use the real path, and not /usr/bin/perl. So, replacing /usr/bin/perl with your own build is all handy-dandy on Solaris. Which you cannot say of every other platform.