[xml/sgml] The xmlcatmgr utility

Julio M. Merino Vidal jmmv@menta.net
Wed, 22 Sep 2004 20:44:57 +0200


Hi all,

I've just installed a Debian system because I was curious about how you handle
the catalog files under /etc/{sgml,xml}/catalog at package (de)installation
time.  It looks like you (Ardo van Rangelrooij) have created two utilities,
update-catalog and update-xmlcatalog to add and remove entries from them.
These are Perl based.  (I'm not saying these are bad in any way).

We (NetBSD) had the same problem in our packaging system, which was solved by
using xmlcatmgr (http://xmlcatmgr.sourceforge.net/).  In fact, the utility was
designed with this purpose in mind, and was made a public project to let it be
used by other OSes painlessly; this resulted in FreeBSD using it too.

It handles both SGML and XML catalogs, despite its name.  It is C based,
contrary to yours; this decision was made so that the dependency tree of simple
packages - such as DTDs - is kept to a minimum (i.e., no interpreter nor
extra libraries).

It works by parsing the internal structure of the catalog files, instead of
treating them as line-based text files.  The first versions of the program
(those in the 1.x branch) handled them as plain text files, which resulted in
some annoying problems.  It looks like that your utilities work this way
(although I haven't looked at the code too much), but maybe they are just
better designed than xmlcatmgr in its first versions ;-)

This mail is just to let you know about this project.  Maybe you'd like to
avoid maintaining two custom extra utilities, when there is another "public"
one that does the same job.  Or maybe you want to remove Perl as a dependency
from some XML-related packages.

Sorry for the little spam ;-)  Ah, and please, CC me any replies, as I'm not
on the list.

Kind regards,

-- 
Julio M. Merino Vidal <jmmv@menta.net>
http://www.livejournal.com/users/jmmv/
The NetBSD Project - http://www.NetBSD.org/