> Ken Wolcott wrote: > > > I suppose it is in bad taste to reply to one's own posting, but I have > > an update. > > > > After reading some in the O'Reilly Perl & XML book, reading the email > > archives of this mailing list, several FAQS that some people mentioned > > from the mailing list archives and another reading of the CPAN man > > page for XML::Simple, I decided to try the OO interface, adding > > "ForceArray => 1, KeepRoot => 1, KeyAttr => 1" to my call to the > > parser. It seems now that the formatting is nice and the closing tag > > is specified properly. So, getting patient, calm, cool and collected > > rather than anxious solved part of the problem. Now the problem that > > remains is the error/warning message in the subject line: "could not > > find ParserDetails.ini in /usr/lib/perl5/vendor_perl/5.8.3/XML/SAX" > > when using XML::Simple. What do I need to do to fix that? > > > > Again, replying to my own post as nobody has reponded :-( > > I saw the "could not find ParserDetails.ini in > /usr/lib/perl5/vendor_perl/5.8.3/XML/SAX" warning/error on a Fedora Core > 2 system, but did not see the error on three Red Hat 9 systems. So I > punted by not using the Fedora system. > > Ken >
See if I can actually get somewhere with this. XML::Simple is just a wrapper around one of the lower level XML parsers. Essentially any parser can be used. XML::DOM and XML::SAX are two examples, within these examples they can/do wrap lower level C libs, such as expat[1] or libxml[2]. Alternatively they may also provide a pure Perl implementation which is likely slower, but still correct. Unless you specifically request a specific parser XML::Simple will look for one that is available and use it. In this case it appears that either you specified or it came upon XML::SAX and attempts to use. Part of the XML::SAX API allows for alternate parsers to be installed, including the two mentioned above (expat and libxml), and also provides a PurePerl version. The module also checks for a ParserDetails.ini to see if you have written your own parser that you might prefer to load before the others, or before the default pure Perl version is loaded. It appears that the file should be installed at installation time or bootstrapped by the Makefile.PL but this is kinda unclear to me. You can check the top of the source for XML::SAX to see some pod like comments about that file as well as the format it should take. So if I had to guess, the RH9 systems probably came installed with either of the parsers (or both) and the FC system did not. It would be pretty simple to have this problem if you didn't install all of the dev libraries, or selected specific packages, etc. Alternatively a previous version of XML::SAX may have installed the file and newer ones don't. It appears at some point that a makefile touched the file in place, and that may have been removed. I also suspect that it is working since the PurePerl parser is installed with XML::SAX and it is falling back to it. And the message you are seeing is just a warning. So you might check for the various libraries, check their versions, check the versions of XML::Simple/XML::SAX, and make sure that the Perl modules were installed against the most recent versions of those libs. To quiet the warning if you so desire it appears you can touch the ParserDetails.ini file in the directory that XML::SAX is installed. Take all of this with as large of a grain of salt as you wish, I am no XML expert.... http://danconia.org [1] http://expat.sourceforge.net/ [2] http://www.xmlsoft.org/ -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>