XML catalog

wrobell wrobell at ite.pl
Mon May 27 14:54:34 CEST 2002


On Mon, May 27, 2002 at 01:37:45PM +0200, Artur Frysiak wrote:
> On Mon, May 27, 2002 at 01:09:25PM +0200, wrobell wrote:
> > On Mon, May 27, 2002 at 12:04:20PM +0200, Artur Frysiak wrote:
> > 
> > > I looked at docbook-dtd412-xml.spec from -r xmlcatalog. 
> > > I think this methodology is not good. 
> > > - not registering DTDs for XML documents in SGML SuperCatalog is not
> > >   good for openjade/opensp and other SGML apps with XML extensions but
> > >   without XML catalogs support.
> > Are there any SGML apps with XML extensions which are used at all?
> > SGML SuperCatalog needs some dirty hacks to use so I am determined 
> > to not support it for XML DTDs.
> 
> You may want to use openjade and dsssl stylesheets to convert XML
> DocBook 4.1.2 to jadetex/ps/pdf, and you need matching DTD in SGML
> SuperCatalog.
Yes, I know, but it is till "may want to" and it is suicide at all.
openjade/opensp is not maintained actively anymore and I do not know
any person who uses XML DocBook with DSSSL stylesheets. It is just easier
to use XSL stylesheets for XML, now. And in case of ps/pdf you have
more choices at all: renderx, fop, passivetex.
 
> > > - direct registering in /etc/xml/catalog is not good for packages
> > >   upgrades/removals.
> > No. There is no such problem. xmlcatalog can handle catalog entries
> > removing.  It is another XML Catalog strength over SGML SuperCatalog.
> 
> But look at order of %post/%postun sections:
> (very short version)
> - new %post
> - old %postun
> 
> So, all --add's from %post are --del'eted in %postun.
> Using --add nextCatalog with %{version}-%{release} fixes this.
> Yes, you may protect %post/%postun by if [ $1 == 0 ] but with this you
> can handle changes in registration scheme in future.
Having many XML catalogs has some disadvantages.  When you want to use
specified catalog, then you have to set XML_CATALOG_FILES and please
note that XML_CATALOG_FILES may only point to one file. When you want to
change catalog you have to set XML_CATALOG_FILES again.  Daniel Veillard
(libxml2 author) said that maybe he will change it to handle
XML_CATALOG_FILES as list of files, but even then it will be
inconvienient to use.

I would prefer 'if [ $1 == 0]' as it is for adding and deleting users
within packages.

[...]
> > Please look at http://xmlsoft.org/catalog.html.
> > One of the XML Catalog strengths is the rewrite system.  It is designed
> > to replace URI with another one, so for example xml validator will load
> > locally installed DTD instead of fetching DTD from net. 
> >
> > XML Catalog rewrite system gives you ability to put into you document
> > following doctype specification
> > 
> > <!DOCTYPE book "-//OASIS//DTD DocBook XML V4.1.2//EN" 
> >     "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
> > 
> > and use locally installed DTD. This way documents are not tied with
> > vendor (PLD, RH, Debian, etc.) specific DTD localization.
> 
> Yes, I know this and I suggest using rewriteSystem for "short form"
> like this listed by you in next section.
> 
> So, for docbook-dtd412-xml.dtd:
> %{_bindir}/xmlcatalog --noout --add rewriteSystem \
>         http://www.oasis-open.org/docbook/xml/%{ver}/ \
>         file://%{_datadir}/sgml/docbook/xml-dtd-%{ver}/ \
> 		%{catalog}
I have tried it but it didn't work. Maybe I have something screwed up
due to time I have been doing it (it was 3AM as I remember). I will try again.

[...]

    wrobell <wrobell at ite.pl>



More information about the pld-devel-en mailing list