pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: textproc/p5-XML-Simple broken (was: CVS commit: pkgsrc/textproc/p5-XML-SAX)



Bernd Ernesti wrote:

> So no, because I'm doing a pkg_chk update and p5-XML-LibXML was out of date:
>  textproc/p5-XML-LibXML - p5-XML-LibXML-1.62.001 < p5-XML-LibXML-1.63
> so it was removed but not the p5-XML-SAX package because it was up to date.
> 
> > If not, then I suppose your
> > registry of XML parsers is messed up, which would support my case of
> > automatic parser registration, which the commit was all about.
> 
> I don't fully get it what you mean here.

Some more details:

p5-XML-SAX is the base class for SAX parsers. It maintains a registry of
parsers in ParserDetails.ini.

During my last package updates I noticed that most of those parsers are
registered with p5-XML-SAX in the software Makefile (created from
Makefile.PL). For pkgsrc, there were either a hack in place to allow
this or a MESSAGE file told the user to change ParserDetails.ini
manually.
Since the hack did not work when installation was done using DESTDIR I
moved the registration process to INSTALL (and corresponding
DEINSTALL) files so it can take place only when it is really required:
during final installation into your system.

> But it sounds like this change requires a PKGREVISION bump of all
> affected packages.

Do you really think this is necessary? The problem would have occurred
in any case, independent of any changes of mine, because p5-XML-LibXML was
deleted without modifying ParserDetails.ini accordingly. The (now
unnecessary) MESSAGE file from textproc/p5-XML-LibXML told you

  $NetBSD: MESSAGE,v 1.2 2004/12/01 15:49:34 wiz Exp $

  You also need to config the XML parser yourself, here is an example
  of ${PREFIX}/libdata/perl5/site_perl/XML/SAX/ParserDetails.ini :
  
  [XML::LibXML::SAX::Parser]
  http://xml.org/sax/features/namespaces = 1

but there is no mechanism to tell you to modify ParserDetails.ini again
when deinstalling the package.

> A try to deinstall results in this problem:
> 
> original MD5 checksum failed, not deleting: 
> /usr/pkg/lib/perl5/vendor_perl/5.8.0/XML/SAX/ParserDetails.ini
> 
> So the file is still there :(

This happens with manually modified files :-/.
With the new INSTALL/DEINSTALL scripts, the file ParserDetails.ini
will not need to be modified by the user and so long as the add_parser()
and remove_parser() functions from XML::SAX work exactly inverse to each
other the file should match its MD5 checksum on deinstallation.

ciao
     Klaus



Home | Main Index | Thread Index | Old Index