Can't locate warnings.pm in @INC

Discussion in 'Perl Misc' started by Julia De Silva, Oct 10, 2005.

  1. Hi there all,

    I'm getting
    index.cgi: Can't locate warnings.pm in @INC ..............
    when running script on this server.

    Perl Executable: perl
    Perl Version: 5.00503
    PERL compile version OS: linux



    The script does not contain -w on Shebang line, nor does
    it have uses Warnings; (Perl 5.6 onwards ?)

    but it has

    use CGI qw:)standard);
    use CGI::Carp qw(fatalsToBrowser);
    use DBI;
    use Time::localtime;
    my $q = new CGI;

    Any ideas please thanks.

    J
     
    Julia De Silva, Oct 10, 2005
    #1
    1. Advertising

  2. Julia De Silva wrote:
    > I'm getting
    > index.cgi: Can't locate warnings.pm in @INC ..............
    > when running script on this server.
    > **
    > *Perl Executable:*
    > perl
    > *Perl Version:* 5.00503


    The warnings pragma was introduced in Perl 5.6.0.

    > The script does not contain -w on Shebang line,


    That's irrelevant, since it's how warnings often are enabled in programs
    written for pre 5.6.0 versions (-w does not require warnings.pm).

    > nor does
    > it have uses Warnings; (Perl 5.6 onwards ?)
    >
    > but it has
    >
    > use CGI qw:)standard);
    > use CGI::Carp qw(fatalsToBrowser);
    > use DBI;
    > use Time::localtime;


    It would surprise me if any of those modules requires 5.006, but the
    answer is probably in the complete error message.

    --
    Gunnar Hjalmarsson
    Email: http://www.gunnar.cc/cgi-bin/contact.pl
     
    Gunnar Hjalmarsson, Oct 10, 2005
    #2
    1. Advertising

  3. Gunnar Hjalmarsson wrote:
    >>
    >> use CGI qw:)standard);
    >> use CGI::Carp qw(fatalsToBrowser);
    >> use DBI;
    >> use Time::localtime;

    >
    > It would surprise me if any of those modules requires 5.006,


    Noticed that the latest version of DBI does require 5.006... Maybe
    somebody has upgraded that module without upgrading the version of Perl
    accordingly.

    But, again, no reason to keep guessing. Read the _complete_ error message.

    --
    Gunnar Hjalmarsson
    Email: http://www.gunnar.cc/cgi-bin/contact.pl
     
    Gunnar Hjalmarsson, Oct 10, 2005
    #3
  4. >>> use CGI qw:)standard);
    >>> use CGI::Carp qw(fatalsToBrowser);
    >>> use DBI;
    >>> use Time::localtime;

    >>
    >> It would surprise me if any of those modules requires 5.006,

    >
    > Noticed that the latest version of DBI does require 5.006... Maybe
    > somebody has upgraded that module without upgrading the version of Perl
    > accordingly.
    >
    > But, again, no reason to keep guessing. Read the _complete_ error message.


    Many thanks for your help. The answer is below and you are exactly right !!
    Sometimes, if I could just read the obvious ..... Sorry 'bout that. Now to
    get on the phone to the ISP.

    BEGIN failed--compilation aborted at
    /usr/lib/perl5/site_perl/5.005/i386-linux/DBD/mysql/GetInfo.pm line 20.
     
    Julia De Silva, Oct 10, 2005
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Jennifer
    Replies:
    1
    Views:
    167
    Tad McClellan
    Jun 24, 2003
  2. Michael Evanchik

    Can't locate POE.pm in @INC

    Michael Evanchik, Sep 22, 2003, in forum: Perl Misc
    Replies:
    3
    Views:
    586
    Sam Holden
    Sep 24, 2003
  3. Gary Hartl

    Perl can't locate a .pm in @INC

    Gary Hartl, Nov 4, 2003, in forum: Perl Misc
    Replies:
    7
    Views:
    182
    Gary Hartl
    Nov 5, 2003
  4. Justin Wyllie
    Replies:
    5
    Views:
    242
    Peter Pan
    Jan 11, 2005
  5. Replies:
    3
    Views:
    1,633
Loading...

Share This Page