You are not logged in.
Pages: 1
Hello, I'm running trying to run a perl script that uses XMLTV and XML::DOM and XML::DOM::NodeList. I'm pretty sure i have all the required perl packages installed.....
Everytime I try to run this script it spits out this error
Can't locate XML/DOM.pm in @INC (@INC contains: /usr/lib/perl5/5.8.8/i686-linux-thread-multi
It appears to be looking for a directory that doesn't exist or is in the wrong location perhaps?
fck art, lets dance.
Offline
Try installing perlxml.
Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB
Offline
I already had perl-xml-simple and perlxml from Current installed yeah. But I still get that error...
fck art, lets dance.
Offline
Run "pacman -Ql perlxml" and make sure the libraries are installed in the right place, and in the search path. Likewise for perl-xml-simple.
Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB
Offline
ah, it appears that the libraries aren't looking in the correct directory. Would you know how I can change the search path for perl?
pacman -Ql perlxml=
/usr/lib/perl5/site_perl/current/i686-linux-thread-multi/
it isn't looking for any path that has "current" as a directory.
thanks chrismortimore
fck art, lets dance.
Offline
You should be able to just push it onto @INC, like so:
push(@INC,"/usr/lib/perl5/site_perl/current/i686-linux-thread-multi/");
Probably not the best way to do it though. As a matter of curiousity, can you post the output of these commands:
ls -l /usr/lib/perl5/
ls -l /usr/lib/perl5/site_perl/
perl -e 'foreach my $line (@INC) { print("$linen"); }'
I just want to see how your machine is set up just now.
Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB
Offline
Arch installs perl in /usr/lib/perl5/current and /usr/lib/perl5/site_perl/current, with symlinks to /usr/lib/perl5/5.8.x and /usr/lib/perl5/site_perl/5.8.x respectively. This is, of course, to make version upgrades easier. So if your script goes looking in /usr/lib/perl5/5.8.8/*, it's actually looking in /usr/lib/perl5/current/*.
XML/DOM.pm is in the perl-template-toolkit package - do you have that installed? It's in the AUR here.
Offline
checked the directories and the do indeed symlink to current as tomk pointed out.
installed perl-template-toolkit from current, rebooted and no joy. Still getting the exact same error.
fck art, lets dance.
Offline
Again, please post the output of
perl -e 'foreach my $line (@INC) { print("$linen"); }'
The reason I ask for this is because I want to see what perl has as it's search paths just now. That way, we'll know if perl has been configured correctly or not.
Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB
Offline
Again, please post the output of
perl -e 'foreach my $line (@INC) { print("$linen"); }'
The reason I ask for this is because I want to see what perl has as it's search paths just now. That way, we'll know if perl has been configured correctly or not.
/usr/lib/perl5/5.8.8/i686-linux-thread-multi
/usr/lib/perl5/5.8.8
/usr/lib/perl5/site_perl/5.8.8/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.8
/usr/lib/perl5/site_perl/5.8.7/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.7
/usr/lib/perl5/site_perl/5.8.6/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.6
/usr/lib/perl5/site_perl/5.8.5/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.5
/usr/lib/perl5/site_perl/5.8.4/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.4
/usr/lib/perl5/site_perl/5.8.3/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.3
/usr/lib/perl5/site_perl/5.8.2/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.2
/usr/lib/perl5/site_perl/5.8.1/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.1
/usr/lib/perl5/site_perl/5.8.0/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.0
/usr/lib/perl5/site_perl
fck art, lets dance.
Offline
Right, so now we know that perl is certainly looking in the right place.. Run this and post the output:
find /usr/lib/perl5/ -iname *dom*
Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB
Offline
installed perl-template-toolkit from current
It's not in current - it's in the AUR. Are you sure you installed the right package?
Offline
clarence wrote:installed perl-template-toolkit from current
It's not in current - it's in the AUR. Are you sure you installed the right package?
It's most definately installed, yeah.
find /usr/lib/perl5/ -iname *dom*
/usr/lib/perl5/site_perl/current/i686-linux-thread-multi/auto/Net/SSLeay/randomize.al
/usr/lib/perl5/site_perl/current/i686-linux-thread-multi/XML/LibXML/DOM.pod
/usr/lib/perl5/site_perl/current/Locale/TextDomain.pm
/usr/lib/perl5/current/Net/Domain.pm
I have no idea what's happening here. I need to get off my lazy cheeks and learn more about perl I thinks.
fck art, lets dance.
Offline
There's your problem. You don't actually have XML/DOM.pm installed.
Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB
Offline
OK - this is my fault - sorry.
perl-template-toolkit provides Template::Plugin::XML::DOM, not XML::DOM. At present, there is no Arch package for XML::DOM, so installing it via CPAN would be the quickest fix, albeit not the most Arch-friendly.
If you want to do it the Arch way, take a recent Perl PKGBUILD, and change it as required. If you need any help with that, let me know.
Offline
ok cheers. I'll try making a PKGBUILD for http://www.cpan.org/authors/id/T/TJ/TJM … .44.tar.gz
Thanks for your help
fck art, lets dance.
Offline
Nice. Just created a PKGBUILD for XML-DOM and it all seems to be working so far.
I'll just triple check the PKGBUILD and upload it to aur later. Thanks very much tomk and chrismortimore
fck art, lets dance.
Offline
My pleasure, enjoy all of your XML endevours
Desktop: AMD Athlon64 3800+ Venice Core, 2GB PC3200, 2x160GB Maxtor DiamondMax 10, 2x320GB WD Caviar RE, Nvidia 6600GT 256MB
Laptop: Intel Pentium M, 512MB PC2700, 60GB IBM TravelStar, Nvidia 5200Go 64MB
Offline
Glad it worked out for you, clarence, and sorry for steering you wrong earlier.
Offline
I'm also seeking this package, please share your PKGBUILD
Check out my website, http://tatey.com
Offline
Tatey: aur'd
fck art, lets dance.
Offline
Where can I find this?
Offline
You could submit it to the [perlcpan] repository. read more about it here: http://wiki.archlinux.org/index.php/PerlCPAN_Repository
Actually upon going there myself, to make sure I don't mis-speak; it's actually already in the [perlcpan] repository. Personally I like this method better, as I don't like dealing with CPAN.
/swogs
Open Toes; Open Mind; Open Source.
Offline
Pages: 1