Newbie Question: XML::Parser & Expat build problems 
Author Message
 Newbie Question: XML::Parser & Expat build problems


email.  This address is long defunct.)

Hello and please forgive the xpost.
I'm trying to install the XML::Parser and Expat.
My setup: SuSE Linux 7.1, Perl 5.6.0
Stuff I downloaded:  XML-Parser-2.30.tar.gz and expat-1.95.3.tar.gz.

As root, I ran the installs and makes, etc.  
When I first attempted to run the samples, I got the awful and
horrible "Can't locate XML::Parser."  To heck with it, I said, and
mv'ed the XML-Parser.pm and Expat directory into the paths that Perl
claims it can see.  Yes, I know that was wishful thinking.

Now I'm getting "Can't find loadable object for module
XML::Parser::Expat," something I'm sure has appeared here before, if
not under more stupid circumstances.

I've scoured the web and CPAN and found nothing but oldbies attempting
to emulate Larry Wall's style of humor while assuming that the reader
is a MS grad and veteran of C and Java.  Can anyone out there break it
down to an idiot's level so that I can get this parsing stuff going on
my machine?  This is the first time I've tried to install a Perl
module, having been content to write my own stuff up until now.  Under
my ow brainpower I've gotten Oracle installed on this silly Linux
thingie, but this Perl module stuff is making me insane.  I am bummed
out.  Please help.

Thanks,

Eric



Sat, 04 Dec 2004 00:46:00 GMT  
 Newbie Question: XML::Parser & Expat build problems

Quote:
> I'm trying to install the XML::Parser and Expat.
> My setup: SuSE Linux 7.1, Perl 5.6.0
> Stuff I downloaded:  XML-Parser-2.30.tar.gz and expat-1.95.3.tar.gz.
> As root, I ran the installs and makes, etc.  
> When I first attempted to run the samples, I got the awful and
> horrible "Can't locate XML::Parser."  To heck with it, I said, and
> mv'ed the XML-Parser.pm and Expat directory into the paths that Perl
> claims it can see.  Yes, I know that was wishful thinking.

First of all, undo the "mv"s you did earlier!

Now let's see what the possibilities are.

1. The README for XML::Parser says that it requires expat already to
have been installed. Have you done so? How did you install it, and have
you verified that it works (or at least, appears to work)?

2. Can you please describe exactly what you did to configure, compile,
test, and install XML::Parser. We'll also need the results of any errors
or warnings this processes produces.

Cheers,
Chris

until$s[$i];$c=$s[$i];print$c;undef$s[$i];$i=($i+(ord$c))%$l}



Sat, 04 Dec 2004 19:02:58 GMT  
 Newbie Question: XML::Parser & Expat build problems

Quote:


> > I'm trying to install the XML::Parser and Expat.
> > My setup: SuSE Linux 7.1, Perl 5.6.0
> > Stuff I downloaded:  XML-Parser-2.30.tar.gz and expat-1.95.3.tar.gz.

> > As root, I ran the installs and makes, etc.  
> > When I first attempted to run the samples, I got the awful and
> > horrible "Can't locate XML::Parser."  To heck with it, I said, and
> > mv'ed the XML-Parser.pm and Expat directory into the paths that Perl
> > claims it can see.  Yes, I know that was wishful thinking.

> First of all, undo the "mv"s you did earlier!

Did that, and reinstalled to the defaults.  Still the same business.
Thanks very much for the response, by the way, Chris.

Quote:
> Now let's see what the possibilities are.

> 1. The README for XML::Parser says that it requires expat already to
> have been installed. Have you done so? How did you install it, and have
> you verified that it works (or at least, appears to work)?

I should have mentioned that.  Yes, I was very diligent about the
documentation, and installed Expat.  I have no clue as to how to
verify it works, though.
I've checked a few other web sources in the meantime, and it appears
that this isn't as rare a problem as I thought.  Expat installs by
default into

Quote:
> 2. Can you please describe exactly what you did to configure, compile,
> test, and install XML::Parser.

Certainly.  
I had tried previously under the superuser, so this time I logged in
as the user "oracle" to see if it would make a difference.

To install Expat, I untarred the expat-1.95.3.tar.gz file in a
directory I created (/usr/expat), then ran:
             ./configure
...to which the configuration echoed a bunch of "checking" this and
that, and it eventually created the Makefile and expat_config.h and
./config.status.
Then I typed:
             make
...and it echoed a dozen or so gcc -g lines.

I then untarred the XML-Parser-2.30.tar.gz (I first tried "gunzip
XML-Parser-2.30.tzr.gz" but it didn't like that, so I just did a tar
xvf).
No problems so far.

Then I cd'ed to /usr/XML-Parser-2.30 and followed the directions:
           perl -w Makefile.PL
...returned 5 warnings:
Name "main::PERL_VERSION" used only once: possible typo at Makefile.PL
line 78.
Name "main::OSNAME" used only once: possible typo at Makefile.PL line
78.
Name "ExtUtils::MakeMaker::Version" used only once: possible typo at
Makefile.PL line 84.
Use of uninitialized value in numeric ge (>=) at Makefile.PL line 76.
Use of uninitialized value in numeric ge (>=) at Makefile.PL line 81.

The rest of it went well, from what I'd guess, with "...looks good"
and "Writing Makefile" for XML::Parser::Expat and XML::Parser.
Then I did:
          make
...and it did a bunch of mkdir's and cp's, chmod 644 on Expat.bs, etc.
then ended with "Manifying blib/man3/XML::Parser.3pm".

Finally I ran "make test".  It did the t/* and returned "all tests
successful".
Then I tried running each of the samples, and same old business:

contains
/usr/lib/perl5/5.6.0/i586-linux
/usr/lib/perl5/5.6.0
/usr/lib/perl5/site_perl/5.6.0/i586-linux
/usr/lib/perl5/site_perl/5.6.0
/usr/lib/perl5/site_perl) at /usr/lib/perl5/site_perl/XML/Parser.pm
line 15" (that was the result of trying the xmlcomments sample)

Just reiterating, the setup is SuSE 7.1.  The machine is a Celeron 1.1
ghz with 256 RAM.  The main HD runs XP; SuSE is on a second HD.  I
have not messed at all with the Linux kernel (and hopefully never
will).

I did a find for Parser.pm, and it's in these directories:
/usr/lib/perl5/site_perl/5.6.0/i586-linux/HTML
/usr/XML-Parser-2.30/blib/lib/XML

On the advice of some web site, I had tried putting it in
/usr/lib/perl5/site_perl/XML (that was the mv I mentioned earlier).

Post-install, Expat.pm ended up in:
/usr/XML-Parser-2.30/blib/lib/XML/Parser

If I can get this running, I'm going to document and web it up for the
benefit of beleagered MIS guys and assorted "because it's there"
clodhoppers like myself.  I seriously do not want to resort to
Microsoft's greedy XML garbage, mainly because I'm really growing to
like Perl and I do think it should be fantastic for XML parsing.
I've seen a few comments from people along the lines of "Expat linking
to Perl - Oh the agony," but I intend to fight on, even if it has to
be done on the XP side of my box, in which case I wouldn't feel as
though I'd accomplished anything halfway exciting, if that makes
sense.  The Rebel Forces have quite a bit left to do before laying
waste to Billy's Death Star, but IMO something's going to have to
break PDQ.
Anyway.
Again, I sure appreciate your time here, Chris.  Reminder that my good

Best,

Eric



Mon, 06 Dec 2004 10:48:56 GMT  
 Newbie Question: XML::Parser & Expat build problems

Quote:


>> > I'm trying to install the XML::Parser and Expat.
>> 2. Can you please describe exactly what you did to configure, compile,
>> test, and install XML::Parser.
> Certainly.  
> [...]

You never mention doing a "make install" (as root or owner of the
directory tree where public perl modules go) after your successful
"make" and "make test" runs.  Could that be the problem?

Martin



Mon, 06 Dec 2004 17:18:27 GMT  
 Newbie Question: XML::Parser & Expat build problems

Quote:




> >> > I'm trying to install the XML::Parser and Expat.
> >> 2. Can you please describe exactly what you did to configure, compile,
> >> test, and install XML::Parser.
> > Certainly.  
> > [...]

> You never mention doing a "make install" (as root or owner of the
> directory tree where public perl modules go) after your successful
> "make" and "make test" runs.  Could that be the problem?

> Martin

Hello Martin,
Yes, that was exactly what I missed.  That step is indeed in the
readme, but after the step for specifying a different location for the
install, so I missed it.  Nobody to blame but me.
Thanks very much, Martin.  You guys have gone above and beyond, and I
really appreciate it.

Best,

Eric



Tue, 07 Dec 2004 07:51:17 GMT  
 Newbie Question: XML::Parser & Expat build problems

Quote:
> You guys have gone above and beyond, and I really appreciate it.

No problem. You ask a well phrased and clear question, and you'll
(probably) get a sensible answer  :-)

Chris

until$s[$i];$c=$s[$i];print$c;undef$s[$i];$i=($i+(ord$c))%$l}



Tue, 07 Dec 2004 19:59:32 GMT  
 
 [ 6 post ] 

 Relevant Pages 

1. XML::Parser/XML::Parser::Expat

2. XML-PARSER-2_30 expat compile expat.h missing

3. Expat XML:Parser install and Running ActivePerl and IndigoPerl

4. Expat and xml::parser on windows server.

5. XML-Parser and Expat

6. Perl, XML Parser and Expat

7. expat: XML::Parser

8. expat XML parser

9. XML::Parser::Expat

10. Solution: Building expat-1.95.2 for perl (For XML::Parse)

11. XML-Parser build problems

12. Newbie: XML::DOM and Expat

 

 
Powered by phpBB® Forum Software