Xmlcatmgr Error on FreeBSD 9.0

Xmlcatmgr Error on freeBSD 9.0

This is a medical blog. Infact a pulmonary medicine blog, yet I was so excited after I was able to find a solution to a problem that I have been facing on my PC that I decided to write about it.

I have recently installed freeBSD 9.0 release on a desktop that was lying spare with me. I know that the folks at FreeBSD are working to release FreeBSD 9.1. 9.1 RC3 has already been released on 3rd November. I have been trying to carefully upgrade the ports and packages to avoid any major break in the system and my progress has been very slow in this regard. Anyways, when I tried to update firefox on the system by running

# portmaster www/firefox

I had to download an awful lot of packages because I had installed them from the downloaded DVD. I had to download and upgrade/update about 154 packages just to get firefox in latest version. Just halfway through I encountered an error which seemed to have no solution.  The error was

xmlcatmgr: entry already exists for `-//OASIS//ELEMENTS DocBook XML Information Pool V4.1.2//EN' of type `public'

textproc/docbook-sk would not install. I could not deinstall it too. That was a dilemma. Googling this term threw only 161 links which seemed to offer no solution to me. I kept searching for a solution till I managed to find one here. According to the link I had to manually clean out this file

usr/local/share/xml/catalog.ports

Before cleanup this file looked like this:

<?xml version="1.0"?>

<!DOCTYPE catalog PUBLIC "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN" "http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd">

<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog">
<nextCatalog catalog="/usr/local/share/xml/docbook/5.0/catalog.xml" />
<rewriteSystem systemIdStartString="http://www.oasis-open.org/docbook/xml/4.1.2" rewritePrefix="file:///usr/local/share/xml/docbook/4.1.2" />
<rewriteURI uriStartString="http://www.oasis-open.org/docbook/xml/4.1.2" rewritePrefix="file:///usr/local/share/xml/docbook/4.1.2" />
<nextCatalog catalog="/usr/local/share/xml/docbook/4.2/catalog.xml" />
<nextCatalog catalog="docbook/4.3/catalog.xml" />
<nextCatalog catalog="docbook/4.4/catalog.xml" />
<nextCatalog catalog="docbook/4.5/catalog.xml" />
<delegateSystem systemIdStartString="http://docbook.sourceforge.net/release/xsl/" catalog="file:///usr/local/share/xsl/docbook/catalog" />
<delegateURI uriStartString="http://docbook.sourceforge.net/release/xsl/" catalog="file:///usr/local/share/xsl/docbook/catalog" />
<system systemId="http://glade.gnome.org/glade-2.0.dtd" uri="/usr/local/share/xml/libglade/glade-2.0.dtd" />
<nextCatalog catalog="/usr/local/share/xml/xmlcharent/catalog.xml" />
<public publicId="-//OASIS//ELEMENTS DocBook XML Information Pool V4.1.2//EN" uri="file:///usr/local/share/xml/docbook/4.1.2/dbpoolx.mod" />
<public publicId="-//OASIS//DTD DocBook XML V4.1.2//EN" uri="file:///usr/local/share/xml/docbook/4.1.2/docbookx.dtd" />
<public publicId="-//OASIS//ENTITIES DocBook XML Character Entities V4.1.2//EN" uri="file:///usr/local/share/xml/docbook/4.1.2/dbcentx.mod" />
<public publicId="-//OASIS//ENTITIES DocBook XML Notations V4.1.2//EN" uri="file:///usr/local/share/xml/docbook/4.1.2/dbnotnx.mod" />
<public publicId="-//OASIS//ENTITIES DocBook XML Additional General Entities V4.1.2//EN" uri="file:///usr/local/share/xml/docbook/4.1.2/dbgenent.mod" />
<public publicId="-//OASIS//ELEMENTS DocBook XML Document Hierarchy V4.1.2//EN" uri="file:///usr/local/share/xml/docbook/4.1.2/dbhierx.mod" />
<public publicId="-//OASIS//DTD XML Exchange Table Model 19990315//EN" uri="file:///usr/local/share/xml/docbook/4.1.2/soextblx.dtd" />
<public publicId="-//OASIS//DTD DocBook XML CALS Table Model V4.1.2//EN" uri="file:///usr/local/share/xml/docbook/4.1.2/calstblx.dtd" />
</catalog>

As instructed in the mailing list, I just deleted all the DocBook-4.1.2 entries in this file, saved it and again ran the command:

# portmaster www/firefox .

And voila! the install process resumed and I managed to install firefox 16.0.2 on freeBSD 9.0.

Image credits: Banym’s Blog

%d bloggers like this: