Subject: | Local installation fails when XML::SAX is installed in system paths |
I tried to install XML::LibXML locally to ~/perl5:
$cpanm XML::LibXML
--> Working on XML::LibXML
Fetching
http://search.cpan.org/CPAN/authors/id/S/SH/SHLOMIF/XML-LibXML-1.90.tar.gz
... OK
Configuring XML-LibXML-1.90 ... OK
Building and testing XML-LibXML-1.90 ... FAIL
! Installing XML::LibXML failed. See ~/.cpanm/build.log for details.
Although XML::LibXML was actually installed, the cpanm failure prevents
installing other modules that depend on XML::LibXML and users are
confused because ~/.cpanm/build.log contains:
Installing ~/perl5/lib/perl5/i686-linux-thread-multi/XML/LibXML.pm
Appending installation info to
~/perl5/lib/perl5/i686-linux-thread-multi/perllocal.pod
Cannot write to
/usr/lib/perl5/vendor_perl/5.12.4/XML/SAX/ParserDetails.ini: Permission
denied at /usr/lib/perl5/vendor_perl/5.12.4/XML/SAX.pm line 191.
make: *** [install_sax_driver] Error 13
I found a several years old patch by Petr Pajas (attached), but no bug
report, so I have no idea why was not the patch applied.
Subject: | XML-LibXML-Makefile.patch |
--- Makefile.PL.orig 2006-08-02 12:46:56.000000000 +0200
+++ Makefile.PL 2006-08-30 12:21:03.000000000 +0200
@@ -310,8 +310,8 @@
$script .= <<"INSTALL";
install_sax_driver :
-\t\@\$(PERL) -I\$(INSTALLSITELIB) -I\$(INSTALLSITEARCH) -MXML::SAX -e "XML::SAX->add_parser(q(XML::LibXML::SAX::Parser))->save_parsers()"
-\t\@\$(PERL) -I\$(INSTALLSITELIB) -I\$(INSTALLSITEARCH) -MXML::SAX -e "XML::SAX->add_parser(q(XML::LibXML::SAX))->save_parsers()"
+\t-\@\$(PERL) -I\$(INSTALLSITELIB) -I\$(INSTALLSITEARCH) -MXML::SAX -e "XML::SAX->add_parser(q(XML::LibXML::SAX::Parser))->save_parsers()"
+\t-\@\$(PERL) -I\$(INSTALLSITELIB) -I\$(INSTALLSITEARCH) -MXML::SAX -e "XML::SAX->add_parser(q(XML::LibXML::SAX))->save_parsers()"
INSTALL
} else {