Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

XML::simple instalation

by veerubiji (Sexton)
on Oct 03, 2011 at 09:41 UTC ( [id://929300]=perlquestion: print w/replies, xml ) Need Help??

veerubiji has asked for the wisdom of the Perl Monks concerning the following question:

Hi, I am using strawberry perl 15.12.3 version for windows xp. I am running some perl scripts. if i want to run xml::simple i need to instal it?

Replies are listed 'Best First'.
Re: XML::simple instalation
by dHarry (Abbot) on Oct 03, 2011 at 09:55 UTC

    yes

    Shortest post ever:)

    You could install it from cpan or find a strawberry package for it.

      Strawberry is different from ActiveState in that it does match closely to the way that Unix ports behave, and it accepts the use of CPAN to install CPAN packages, which generally work just as expected. It's a bit of a surprise how you must set up environment variables like PERL5LIB (you have to use an obscure system control-panel feature), but otherwise it works out very much like "using Perl as a non-root user."

        Strawberry also proivides PPM to install modules, I think that's what dHarry means by "package".

Re: XML::simple instalation
by pvaldes (Chaplain) on Oct 03, 2011 at 09:54 UTC

    You can obtain for yourself the answer, try and run

    use warnings; use xml::simple;

    If is not installed still, perl probably will show something like this:

    Can't locate xml/simple.pm

      Also see Re: use Strict: a rigorous way to break my command line variables?.

      If XML::Simple is installed, use xml::simple; on Windows will not raise an error related to xml::simple or XML::Simple:

      >perl -Mxml::simple -e "XMLin()" Undefined subroutine &main::XMLin called at -e line 1. >perl -MXML::Simple -e "XMLin()" Could not find -e.xml in .\ at -e line 1

      Because file systems on Windows are generally case insensitive, you can load modules under various names. As package names under Perl still are case sensitive, their ->import() method will not be called, which is confusing.

      In my opinion, it would have been more helpful to directly tell the OP that there is no module xml::simple.

Re: XML::simple instalation
by grantm (Parson) on Oct 05, 2011 at 07:22 UTC
    According to the Strawberry Perl web site, XML::Simple is already included in the distribution. So no, you don't need to install it.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://929300]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (4)
As of 2024-03-19 03:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found