tags:

views:

130

answers:

2

After installing the XML::Schematron::XPath module from CPAN I am getting the "Can't locate XML/XPath.pm in @INC) message.

]$sudo ls /usr/lib/perl5/site_perl/5.10.0/XML/
ESISParser.pm  Filter  Handler  Parser  PatAct  Perl2SAX.pm  SAX2Perl.pm  Schematron Schematron.pm  Validator

There is the Schematron directory, and inside of it is XPath.pm.

Why is it looking for XML/XPath.pm when I clearly state in my perl script:

use XML::Schematron::XPath;

@INC: /usr/lib/perl5/site_perl/5.10.0/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.10.0 /usr/lib/perl5/vendor_perl/5.10.0/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.10.0 /usr/lib/perl5/5.10.0/x86_64-linux-thread-multi /usr/lib/perl5/5.10.0 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl .

+3  A: 

I suggest you install XML::XPath

ennuikiller
+1  A: 

You're using XML::Path indirectly, such as inside XML::Schematron::XPath. If you installed XML::Schematron::XPath via CPAN it should have brought in the dependencies automatically, but at any rate you can install your dependencies now. See this question for more about installing a Perl module via CPAN.

Ether
Yeah, thats why I posted this question and was confused.. I used cpan to install it and I guess it missed depends for what ever reason.