in reply to How to install Date::Calc on a Mac

How can I tell if I have these modules already?
In many cases you can type perl -M<module> (e.g, perl -MDigest::MD5) and perl will either pause waiting for input (if you have the module installed) or it will issue an error message (if you don't have it installed). That won't work for libnet or libwww-perl but should work for the other modules you mention.

Also I believe most modules will warn you about existing versions of the same module when you build them.

Replies are listed 'Best First'.
Re^2: How to install Date::Calc on a Mac
by bronto (Priest) on Nov 23, 2004 at 13:58 UTC
    In many cases you can type perl -M<module> (e.g, perl -MDigest::MD5) and perl will either pause waiting for input (if you have the module installed) or it will issue an error message (if you don't have it installed).

    I use to do perl -M<module> -e exit in those cases, so that it won't pause. Or, when I have to test for many modules and using a Bourne-like shell in UNIX (e.g.: bash):

    for MODULE in First::Module Second::Module Third::Module ; do perl -M$MODULE -e exit ; done

    Ciao!
    --bronto


    In theory, there is no difference between theory and practice. In practice, there is.