Please bottom post....

> Not the prettiest way but here is how I check if File::Find is installed:
> 
>  perldoc -X File::Find
> 
> 
> Like I said, it's not pretty.  I figure there wouldn't be a doc on the
machine if the module wasn't there.  Bad presumtion I know.  Still,
maybe someone can help educate us.  I'm a sorta perl-newbie now (yes.. I
can be taught!)
> 

Not necessarily true. perldoc expects POD, which can be internal or
external to a particular module's source code, it is possible to remove
the documentation and still have the module installed.  Slightly better
would be to just invoke the perl interpreter with -M and see if it spits
out an error.  For instance,

perl -MCGI
(hangs waiting for input, use Ctrl+c to end)

perl -MCGId
Can't locate CGId.pm in @INC (@INC contains:
/usr/local/lib/perl5/5.6.1/sun4-solaris /usr/local/lib/perl5/5.6.1
/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris
/usr/local/lib/perl5/site_perl/5.6.1 /usr/local/lib/perl5/site_perl .).
BEGIN failed--compilation aborted.

There might be better ways still....

http://danconia.org

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to