[xml/sgml-commit] r1145 - in /packages/sgml-base: ./ trunk/ trunk/MAKE/ trunk/debian/ trunk/examples/ trunk/tools/

dleidert-guest at users.alioth.debian.org dleidert-guest at users.alioth.debian.org
Tue Sep 2 11:59:06 UTC 2008


Author: dleidert-guest
Date: Tue Sep  2 11:59:05 2008
New Revision: 1145

URL: http://svn.debian.org/wsvn/debian-xml-sgml/?sc=1&rev=1145
Log:
[svn-inject] Installing original source of sgml-base

Added:
    packages/sgml-base/
    packages/sgml-base/trunk/
    packages/sgml-base/trunk/MAKE/
    packages/sgml-base/trunk/MAKE/include
    packages/sgml-base/trunk/Makefile
    packages/sgml-base/trunk/README
    packages/sgml-base/trunk/debian/
    packages/sgml-base/trunk/debian/README.Debian
    packages/sgml-base/trunk/debian/TODO
    packages/sgml-base/trunk/debian/changelog
    packages/sgml-base/trunk/debian/compat
    packages/sgml-base/trunk/debian/control
    packages/sgml-base/trunk/debian/copyright
    packages/sgml-base/trunk/debian/rules   (with props)
    packages/sgml-base/trunk/debian/sgml-base.examples
    packages/sgml-base/trunk/debian/sgml-base.install
    packages/sgml-base/trunk/debian/sgml-base.postinst
    packages/sgml-base/trunk/debian/sgml-base.postrm
    packages/sgml-base/trunk/debian/sgml-base.preinst
    packages/sgml-base/trunk/debian/sgml-base.prerm
    packages/sgml-base/trunk/examples/
    packages/sgml-base/trunk/examples/postinst   (with props)
    packages/sgml-base/trunk/examples/postrm   (with props)
    packages/sgml-base/trunk/examples/prerm   (with props)
    packages/sgml-base/trunk/tools/
    packages/sgml-base/trunk/tools/Makefile
    packages/sgml-base/trunk/tools/catalog.centralized
    packages/sgml-base/trunk/tools/catalog.super
    packages/sgml-base/trunk/tools/install-sgmlcatalog   (with props)
    packages/sgml-base/trunk/tools/install-sgmlcatalog.8
    packages/sgml-base/trunk/tools/transitional.cat
    packages/sgml-base/trunk/tools/update-catalog   (with props)
    packages/sgml-base/trunk/tools/update-catalog.8

Added: packages/sgml-base/trunk/MAKE/include
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/MAKE/include?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/MAKE/include (added)
+++ packages/sgml-base/trunk/MAKE/include Tue Sep  2 11:59:05 2008
@@ -1,0 +1,46 @@
+## ----------------------------------------------------------------------
+## MAKE/include : include makefile for sgml-base
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+## System directory definitions
+prefix		= /usr
+bin_dir		= $(prefix)/bin
+sbin_dir	= $(prefix)/sbin
+share_dir	= $(prefix)/share
+
+## ----------------------------------------------------------------------
+## Local directory definitions
+local_dir	= $(prefix)/local
+local_share_dir	= $(local_dir)/share
+
+## ----------------------------------------------------------------------
+## Manual pages directory definitions
+man_dir		= $(share_dir)/man
+man1_ext	= 1
+man1_dir	= $(man_dir)/man$(man1_ext)
+man8_ext	= 8
+man8_dir	= $(man_dir)/man$(man8_ext)
+
+## ----------------------------------------------------------------------
+## SGML directory definitions
+sgml_dir	= $(share_dir)/sgml
+local_sgml_dir	= $(local_share_dir)/sgml
+
+## ----------------------------------------------------------------------
+## Package directory definitions
+pkg_name	:= sgml-base
+pkg_share_dir	:= $(share_dir)/$(pkg_name)
+
+## ----------------------------------------------------------------------
+## Build definitions
+POD2MAN		= pod2man
+
+## ----------------------------------------------------------------------
+## Install definitions
+INSTALL		= install
+INSTALL_DIR	= $(INSTALL) -m 755 -d
+INSTALL_BIN	= $(INSTALL) -m 755
+INSTALL_FILE	= $(INSTALL) -m 644
+
+## ----------------------------------------------------------------------

Added: packages/sgml-base/trunk/Makefile
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/Makefile?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/Makefile (added)
+++ packages/sgml-base/trunk/Makefile Tue Sep  2 11:59:05 2008
@@ -1,0 +1,52 @@
+## ----------------------------------------------------------------------
+## Makefile : makefile for sgml-base
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+include MAKE/include
+
+## ----------------------------------------------------------------------
+## source package subdirectory definitions
+subdirs		= \
+		tools
+
+## ----------------------------------------------------------------------
+## SGML infrastructure directory definitions
+sgml_dirs	= \
+		declaration \
+		dtd \
+		entities \
+		misc \
+		stylesheet
+
+## ----------------------------------------------------------------------
+## targets
+
+all:
+
+		set -e; \
+		for d in $(subdirs); \
+		do \
+			$(MAKE) -C $${d} ${@}; \
+		done
+
+install:
+
+		set -e; \
+		for d in $(sgml_dirs); \
+		do \
+			$(INSTALL_DIR) $(sgml_dir)/$${d}; \
+			$(INSTALL_DIR) $(local_sgml_dir)/$${d}; \
+		done
+
+		set -e; \
+		for d in $(subdirs); \
+		do \
+			$(MAKE) -C $${d} ${@}; \
+		done
+
+.PHONY:		\
+		all \
+		install
+
+## ----------------------------------------------------------------------

Added: packages/sgml-base/trunk/README
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/README?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/README (added)
+++ packages/sgml-base/trunk/README Tue Sep  2 11:59:05 2008
@@ -1,0 +1,7 @@
+This is the Debian sgml-base package.  To install it on a non-Debian
+system edit the Makefile and then run `make`, `make install`.
+
+The changelog is in the 'debian' directory.
+
+--
+Ardo van Rangelrooij <ardo at debian.org>

Added: packages/sgml-base/trunk/debian/README.Debian
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/README.Debian?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/README.Debian (added)
+++ packages/sgml-base/trunk/debian/README.Debian Tue Sep  2 11:59:05 2008
@@ -1,0 +1,36 @@
+sgml-base for Debian
+--------------------
+
+De-Facto Standard Tool for Debian SGML Catalog System Maintenance
+----------------------------------------------------------------
+update-sgmlcatalog(8) in the sgml-base package is the de-facto standard
+tool to be used to maintain SGML catalog files on a Debian system,
+just as update-xmlcatalog(8) in the xml-core package is the standard
+tool to be used to maintain XML catalog files on a Debian system.  A
+Debian XML/SGML Policy document to this effect is currently under
+development.
+
+Debhelper Support
+-----------------
+The debhelper package contains the debhelper script dh_installcatalogs
+to support installing SGML package catalog files and registering SGML
+package catalog files in the SGML catalog system.  It complies with the
+current draft Debian XML/SGML policy.  For more information see the
+manual page.
+
+Debian XML & SGML Mailing List
+------------------------------
+The Debian mailing list 'debian-sgml at lists.debian.org' is used to
+discuss issues related to XML and SGML on Debian systems, with an
+emphasis on proper integration of tools, packaging standards and the
+writing of documentation for XML and SGML users.
+
+Debian XML & SGML Group Project
+-------------------------------
+The 'Debian XML/SGML Group' project (http://debian-xml-sgml.alioth.debian.org/)
+has been setup on Debian Alioth (http://alioth.debian.org/) to develop
+and maintain XML and SGML packages for the Debian Project in a
+collaborative effort.
+
+--
+Ardo van Rangelrooij <ardo at debian.org>

Added: packages/sgml-base/trunk/debian/TODO
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/TODO?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/TODO (added)
+++ packages/sgml-base/trunk/debian/TODO Tue Sep  2 11:59:05 2008
@@ -1,0 +1,32 @@
+------------------------------------------------------------------------------
+To do list for sgml-base
+------------------------------------------------------------------------------
+
+BUGS:
+------------------------------------------------------------------------------
+Number Description
+------------------------------------------------------------------------------
+ 88008 update-catalog should change its name
+125706 does not remove /etc/sgml, /usr/lib/sgml on purge
+------------------------------------------------------------------------------
+
+WISHLIST:
+------------------------------------------------------------------------------
+Number Description
+------------------------------------------------------------------------------
+ 85682 install-catalog (or whatever) should support filename derivative lines
+       in SGML dir
+ 88010 please consider catalog design change
+------------------------------------------------------------------------------
+
+VARIOUS:
+------------------------------------------------------------------------------
+* implement an `sgml-config` tool ala `pkg-config` (look at `sgmlwhich`):
+   * SGML_CATALOG_FILES=`sgml-config --catalogs xml-resume`
+   * other options:
+      --dtd           list the dtd path of such package
+      --decl          list the declaration file associate
+      --doctype       produce a valid doctype header for a document
+* move `sgml-catalog-check.pl` from 'sgml-data' to 'sgml-base'
+* 'xsltproc --catalogs [..]'
+------------------------------------------------------------------------------

Added: packages/sgml-base/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/changelog?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/changelog (added)
+++ packages/sgml-base/trunk/debian/changelog Tue Sep  2 11:59:05 2008
@@ -1,0 +1,303 @@
+sgml-base (1.26) unstable; urgency=low
+
+  * Removed creation of the transitional catalog in a installation
+    - debian/sgml-base.postinst
+    - debian/sgml-base.prerm
+    - tools/install-sgmlcatalog
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sat, 14 Aug 2004 10:03:56 -0500
+
+sgml-base (1.25) unstable; urgency=low
+
+  * debian/sgml-base.postinst: fixed transitional SGML catalog initialization
+    (closes: Bug#255627)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Tue, 22 Jun 2004 20:06:53 -0500
+
+sgml-base (1.24) unstable; urgency=low
+
+  * debian/sgml-base.*inst: moved SGML root catalog initialization from the
+    preinst to the postinst
+    (closes: Bug#255472)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Mon, 21 Jun 2004 13:58:25 -0500
+
+sgml-base (1.23) unstable; urgency=low
+
+  * Removed support for '/usr/lib/sgml'
+    - debian/sgml-base.p*: remove support for '/usr/lib/sgml/catalog'
+    - debian/sgml-base.p*: moved transitional SGML catalog to /etc/sgml
+    - tools/install-sgmlcatalog: updated accordingly
+    - tools/install-sgmlcatalog.8: updated accordingly
+  * debian/control: rewrote short and long description
+  * README: updated
+  * Added README.Debian
+  * debian/copyright: updated
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 20 Jun 2004 16:59:11 -0500
+
+sgml-base (1.22) unstable; urgency=low
+
+  * Added SGML infrastructure directories
+    - Makefile: created the SGML infrastructure directories under
+      /usr/share/sgml and under /usr/share/local/sgml
+    - debian/rules: updated to use 'dh_usrlocal'
+  * Moved 'update-catalog*', 'install-sgmlcatalog*' and SGML catalog
+    templates to 'tools' directory
+  * Added Makefiles to 'tools' subdirectory and put all the common parts
+    in 'MAKE/include'
+  * tools/update-catalog: absorbed manual page in POD format
+  * tools/install-sgmlcatalog: absorbed manual page in POD format
+  * debian/control: changed 'Maintainer' to 'Debian XML/SGML Group
+    <debian-xml-sgml-pkgs at lists.alioth.debian.org>' and added current
+    maintainer to 'Uploaders'
+  * debian/control: upgraded to Debian Policy 3.6.1 (no changes)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Wed, 21 Apr 2004 14:34:27 -0500
+
+sgml-base (1.21) unstable; urgency=low
+
+  * debian/sgml-base.prerm: updated to remove the transitional catalog from the
+    super catalog also during package upgrade per current sgml-base practice
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 21 Sep 2003 16:14:18 -0500
+
+sgml-base (1.20) unstable; urgency=low
+
+  * Added examples
+  * debian/sgml-base.p*:various cosmetic changes
+  * debian/control: upgraded to Debian Policy 3.6.1 (no changes)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 21 Sep 2003 16:02:18 -0500
+
+sgml-base (1.19) unstable; urgency=low
+
+  * install-sgmlcatalog: re-added '--quiet' option
+    (closes: Bug#204891)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Mon, 11 Aug 2003 05:36:09 -0500
+
+sgml-base (1.18) unstable; urgency=low
+
+  * install-sgmlcatalog: marked '--install' option as deprecated
+    (closes: Bug#174831)
+  * debian/rules: moved debhelper compatibility level setting to
+    'debian/compat' per latest debhelper best practices
+  * debian/control: changed build dependency on 'debhelper' to '(>= 4.1)'
+  * debian/copyright: updated
+  * debian/control: upgraded to Debian Policy 3.6.0 (no changes)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 10 Aug 2003 17:43:56 -0500
+
+sgml-base (1.17) unstable; urgency=low
+
+  * debian/control: updated short description and long description
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sat, 10 Aug 2002 19:00:51 -0500
+
+sgml-base (1.16) unstable; urgency=low
+
+  * debian/rules: upgraded to debhelper v4
+  * debian/control: changed build dependency on debhelper accordingly
+  * debian/rules: migrated from 'dh_movefiles' to 'dh_install'
+  * debian/rules: split off 'install' target from 'binary-indep' target
+  * debian/copyright: added pointer to license
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sat, 10 Aug 2002 13:37:14 -0500
+
+sgml-base (1.15) unstable; urgency=low
+
+  * debian/control: removed explicit and versioned dependency on 'sed'
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 26 May 2002 16:49:02 -0500
+
+sgml-base (1.14) unstable; urgency=low
+
+  * '/usr/share/sgml-base/catalog' -> '/usr/share/sgml-base/catalog.super'
+    (closes: Bug#135279)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Fri, 22 Feb 2002 21:01:54 -0600
+
+sgml-base (1.13) unstable; urgency=low
+
+  * Moved documentation into a separate package
+    (closes: Bug#130208)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 17 Feb 2002 14:17:29 -0600
+
+sgml-base (1.12) unstable; urgency=low
+
+  * debian/sgml-base.prerm: split into prerm and postrm to remove catalog
+    files properly upon purge
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sat, 15 Dec 2001 09:55:45 -0600
+
+sgml-base (1.11) unstable; urgency=low
+
+  * Removed explicit dhelp support since doc-base now takes care of this
+  * debian/control: added build dependency on sp
+  * Added documentation in PDF format
+  * debian/control: added build dependency on 'libpaperg', 'tetex-bin'
+    and 'tetex-extra'
+  * debian/control: removed obsolete build dependency on 'perl'
+  * debian/control: upgraded to Debian Policy 3.5.6
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun,  4 Nov 2001 13:29:14 -0600
+
+sgml-base (1.10) unstable; urgency=low
+
+  * debian/postinst: corrected install of 'transitional.cat'
+    (closes: Bug#96163)
+  * debian/prerm: added purge handling
+    (closes: Bug#93036)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Thu,  3 May 2001 12:05:03 -0500
+
+sgml-base (1.09) unstable; urgency=low
+
+  * Moved the transitional catalog from '/etc/sgml' to '/usr/lib/sgml'
+    (closes: Bug#87943, Bug#90164)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Tue, 10 Apr 2001 20:35:14 -0500
+
+sgml-base (1.08) unstable; urgency=low
+
+  * debian/control: added Conflicts with 'sgmltools-2 (< 2.0.2-5)'
+    (closes: Bug#88078)
+  * debian/postinst: remove circular catalog
+    (closes: Bug#86603, Bug#88009, Bug#88339, Bug#89538, Bug#90766)
+  * debian/postinst: no conffiles anymore
+    (closes: Bug#88003)
+  * debian/control: updated dependencies
+  * debian/control: upgraded to Debian Policy 3.5.2
+  * debian/control: upgraded to Debian Perl Policy 1.17
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Mon,  9 Apr 2001 20:44:57 -0500
+
+sgml-base (1.07) unstable; urgency=low
+
+  * debian/postinst: forgot to `mkdir -p /usr/lib/sgml`
+  * debian/postinst: put various steps in correct order
+    (closes: Bug#87704)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Mon, 26 Feb 2001 09:47:45 -0600
+
+sgml-base (1.06) unstable; urgency=low
+
+  * debian/postinst: forgot to `mkdir -p /etc/sgml`
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 25 Feb 2001 13:10:52 -0600
+
+sgml-base (1.05) unstable; urgency=low
+
+  * Install '/etc/sgml/catalog' and '/etc/sgml/transitional.cat' as
+    templates from '/usr/share/sgml-base'
+    (closes: Bug#86600)
+  * debian/rules: updated to install to 'debian/tmp' and use 'dh_movefiles'
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 25 Feb 2001 12:37:03 -0600
+
+sgml-base (1.04) unstable; urgency=low
+
+  * First steps in migrating '/usr/lib/sgml' to '/usr/share/sgml'
+  * Moved '/etc/sgml.catalog' to '/etc/sgml/transitional.cat'
+  * install-sgmlcatalog: updated to reflect catalog change
+  * install-sgmlcatalog.8: updated to reflect catalog change
+  * Added empty super catalog '/etc/sgml/catalog'
+  * /usr/lib/sgml/catalog: updated to point to the super catalog
+  * Added template for centralized catalogs
+  * Added `update-catalog` for maintaining the super catalog and
+    centralized catalogs
+  * Added various policy documents
+  * README: updated
+  * Added TODO
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Sun, 18 Feb 2001 11:28:05 -0600
+
+sgml-base (1.03) unstable; urgency=low
+
+  * debian/rules: split functionality between 'Makefile' and 'debian/rules'
+  * Makefile: cleaned-up
+  * debian/rules: cleaned up and migrated to debhelper
+  * debian/control: upgraded to Debian Policy 3.2.1
+  * Added doc-base support
+    (closes: Bug#31188)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Tue,  9 Jan 2001 21:22:46 -0600
+
+sgml-base (1.02) unstable; urgency=low
+
+  * New maintainer.
+  * debian/rules: moved manpage to /usr/share/man
+    (closes: Bug#80768)
+
+ -- Ardo van Rangelrooij <ardo at debian.org>  Mon,  8 Jan 2001 09:17:42 -0600
+
+sgml-base (1.01) unstable; urgency=high
+
+  * Arrgh. It was creating the link in /usr/lib/sgml-base/catalog! My
+    bad. closes: Bug#19873
+
+ -- Manoj Srivastava <srivasta at debian.org>  Wed, 18 Mar 1998 00:16:08 -0600
+
+sgml-base (1.00) unstable; urgency=low
+
+  * New maintainer.
+  * Added the SGML entity management document (thanks to aph at debian.org),
+    and normalized the sgml (I like normalized sgml), and modified and
+    expanded the document. Since an agreement has been reached about the
+    location of declaration files (and, by extention, notations), I
+    incorporatred them as such in the document)
+  * Changed the rules file to conform to my standard rule file
+  * Imported to CVS using cvs-inject
+  * Use cvs-buildpackage to update
+  * Put the text and HTML vversions of the Entity Management docs in
+    /usr/doc. 
+
+ -- Manoj Srivastava <srivasta at debian.org>  Sun, 15 Mar 1998 16:33:58 -0600
+
+sgml-base (0.4.2) unstable; urgency=low
+
+  * changed usr/lib/sgml/catalog into an absolute link
+    (reported by Lintian)
+  * debian/control: Upgraded to Standards Version 2.4.0.0 (no changes)
+
+ -- Christian Schwarz <schwarz at debian.org>  Sat, 14 Feb 1998 01:05:39 +0100
+
+sgml-base (0.4.1) unstable; urgency=low
+
+  * debian/rules: Don't use debstd anymore
+  * debian/rules: Compress changelog file (fixes:#15403)
+  * debian/control: Upgraded to Standards Version 2.3.0.1
+  * debian/control: Removed perl dependency (perl-base is tagged
+    `Essential')
+
+ -- Christian Schwarz <schwarz at debian.org>  Wed, 24 Dec 1997 12:19:22 +0100
+
+sgml-base (0.4) unstable; urgency=low
+
+  * Don't fail if /etc/sgml.catalog does not exist when removing an entry
+    (fixes #13937)
+  * Upgraded to Standards Version 2.3.0.0
+
+ -- Christian Schwarz <schwarz at debian.org>  Fri, 17 Oct 1997 16:00:44 +0200
+
+sgml-base (0.3) unstable; urgency=low
+
+  * Use absolute path spec for conffile "/etc/sgml.catalog" (fixes #9755)
+  * Conflict with sgml-data <= 0.02 (fixes #9941)
+
+ -- Christian Schwarz <schwarz at debian.org>  Sun, 25 May 1997 14:24:36 +0200
+
+sgml-base (0.2) unstable; urgency=low
+
+  * Removed symlink /usr/lib/sgml/sgml.catalog .
+  * Wrote README.debian (Guidelines for SGML packages). 
+
+ -- Christian Schwarz <schwarz at debian.org>  Thu, 8 May 1997 11:06:35 +0200
+
+sgml-base (0.1) unstable; urgency=low
+
+  * Initial release.
+
+ -- Christian Schwarz <schwarz at debian.org>  Tue, 6 May 1997 16:51:44 +0200

Added: packages/sgml-base/trunk/debian/compat
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/compat?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/compat (added)
+++ packages/sgml-base/trunk/debian/compat Tue Sep  2 11:59:05 2008
@@ -1,0 +1,1 @@
+4

Added: packages/sgml-base/trunk/debian/control
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/control?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/control (added)
+++ packages/sgml-base/trunk/debian/control Tue Sep  2 11:59:05 2008
@@ -1,0 +1,27 @@
+Source: sgml-base
+Section: text
+Priority: optional
+Maintainer: Debian XML/SGML Group <debian-xml-sgml-pkgs at lists.alioth.debian.org>
+Uploaders: Ardo van Rangelrooij <ardo at debian.org>
+Standards-Version: 3.6.1
+Build-Depends-Indep: debhelper (>= 4.1)
+
+Package: sgml-base
+Section: text
+Priority: optional
+Architecture: all
+Conflicts: sgml-data (<= 0.02), sgmltools-2 (<= 2.0.2-4)
+Depends: ${perl:Depends}
+Suggests: sgml-base-doc
+Description: SGML infrastructure and SGML catalog file support
+ This package creates the SGML infrastructure directories and provides
+ SGML catalog file support in compliance with the current Debian SGML
+ Policy draft:
+ .
+   * infrastructure directories:
+      - /etc/sgml
+      - /usr/share/sgml/{declaration,dtd,entities,misc,stylesheet}
+      - /usr/share/local/sgml/{declaration,dtd,entities,misc,stylesheet}
+ .
+   * update-catalog(8): tool for maintaining the root SGML catalog
+     file and the package SGML catalog files in the '/etc/sgml' directory

Added: packages/sgml-base/trunk/debian/copyright
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/copyright?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/copyright (added)
+++ packages/sgml-base/trunk/debian/copyright Tue Sep  2 11:59:05 2008
@@ -1,0 +1,21 @@
+This the Debian package of sgml-base.  It was assembled by Christian
+Schwarz <schwarz at debian.org>.  It is currently maintained by Ardo van
+Rangelrooij <ardo at debian.org>.
+
+Copyright:
+
+Copyright (C) 1997 Christian Schwarz <schwarz at debian.org>.
+Copyright (C) 2001-2004 Ardo van Rangelrooij <ardo at debian.org>
+
+This is free software; you may redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 2, or (at your option) any later
+version.
+
+This is distributed in the hope that it will be useful, but without
+any warranty; without even the implied warranty of merchantability or
+fitness for a particular purpose.  See the GNU General Public License
+for more details.
+
+On a Debian system a copy of the GNU General Public Licence can be
+found in the file '/usr/share/common-licenses/GPL'.

Added: packages/sgml-base/trunk/debian/rules
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/rules?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/rules (added)
+++ packages/sgml-base/trunk/debian/rules Tue Sep  2 11:59:05 2008
@@ -1,0 +1,59 @@
+#!/usr/bin/make -f
+## ----------------------------------------------------------------------
+## debian/rules : package script for sgml-base
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+## uncomment this to turn on verbose mode
+#export DH_VERBOSE=1
+
+## ----------------------------------------------------------------------
+TMP_DIR		= debian/tmp
+
+## ----------------------------------------------------------------------
+## targets
+
+clean:
+		dh_testdir
+		dh_testroot
+		dh_clean
+		rm -f build-stamp install-stamp
+
+build:		build-stamp
+build-stamp:
+		dh_testdir
+		$(MAKE)
+		touch build-stamp
+
+install:	install-stamp
+install-stamp:	build
+		dh_testdir
+		dh_testroot
+		dh_clean -k
+		dh_installdirs
+		$(MAKE) install prefix=$(PWD)/$(TMP_DIR)/usr
+		touch install-stamp
+
+binary-indep:	build install
+		dh_testdir
+		dh_testroot
+		dh_install --sourcedir=$(TMP_DIR)
+		dh_installdocs
+		dh_installexamples
+		dh_installchangelogs
+		dh_usrlocal
+		dh_compress
+		dh_fixperms
+		dh_installdeb
+		dh_perl
+		dh_gencontrol
+		dh_md5sums
+		dh_builddeb
+
+binary-arch:
+
+binary:		binary-indep binary-arch
+
+.PHONY:		clean build install binary-indep binary-arch binary
+
+## ----------------------------------------------------------------------

Propchange: packages/sgml-base/trunk/debian/rules
------------------------------------------------------------------------------
    svn:executable = 

Added: packages/sgml-base/trunk/debian/sgml-base.examples
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/sgml-base.examples?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/sgml-base.examples (added)
+++ packages/sgml-base/trunk/debian/sgml-base.examples Tue Sep  2 11:59:05 2008
@@ -1,0 +1,1 @@
+examples/*

Added: packages/sgml-base/trunk/debian/sgml-base.install
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/sgml-base.install?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/sgml-base.install (added)
+++ packages/sgml-base/trunk/debian/sgml-base.install Tue Sep  2 11:59:05 2008
@@ -1,0 +1,1 @@
+usr

Added: packages/sgml-base/trunk/debian/sgml-base.postinst
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/sgml-base.postinst?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/sgml-base.postinst (added)
+++ packages/sgml-base/trunk/debian/sgml-base.postinst Tue Sep  2 11:59:05 2008
@@ -1,0 +1,88 @@
+#!/bin/sh
+## ----------------------------------------------------------------------
+## debian/postinst : postinstallation script for sgml-base
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+set -e
+
+## ----------------------------------------------------------------------
+if [ "$1" = "configure" ]
+then
+
+    ## ------------------------------------------------------------------
+    ## create SGML root catalog
+    [ ! -f /etc/sgml/catalog ] \
+	&& cp -a /usr/share/sgml-base/catalog.super /etc/sgml/catalog
+
+    ## ------------------------------------------------------------------
+    ## clean up /usr/lib/sgml
+    if [ -d /usr/lib/sgml ]
+    then
+
+	## --------------------------------------------------------------
+        ## remove nasty old circular catalog
+	update-catalog --remove --super /usr/lib/sgml/catalog || true
+
+	## --------------------------------------------------------------
+	## remove symlink to /etc/sgml/catalog
+	rm -f /usr/lib/sgml/catalog
+
+        ## --------------------------------------------------------------
+	## move transitional SGML catalog to /etc/sgml
+	TRANSCAT=transitional.cat
+	if [ -f /usr/lib/sgml/${TRANSCAT} ]
+	then
+	    update-catalog --remove --super /usr/lib/sgml/${TRANSCAT} || true
+	    mv -f /usr/lib/sgml/${TRANSCAT} /etc/sgml/${TRANSCAT}
+	    if [ -f /usr/lib/sgml/${TRANSCAT}.old ]
+	    then
+		mv -f /usr/lib/sgml/${TRANSCAT}.old /etc/sgml/${TRANSCAT}.old
+	    fi
+	fi
+
+        ## --------------------------------------------------------------
+        ## remove /usr/lib/sgml
+	cd /usr/lib
+	rmdir --ignore-fail-on-non-empty sgml
+	cd - >/dev/null
+
+    fi
+
+    ## ------------------------------------------------------------------
+    ## evolve legacy /etc/sgml.catalog
+    OCATALOG=/etc/sgml.catalog
+    if [ -f ${OCATALOG} ]
+    then
+	TRANSCAT=/etc/sgml/transitional.cat
+	if [ -f ${TRANSCAT} ]
+	then
+	    cp ${TRANSCAT} ${TRANSCAT}.old
+	else
+	    cp /usr/share/sgml-base/transitional.cat ${TRANSCAT}
+	fi
+	sed -e '1,10d' <${OCATALOG} >>${TRANSCAT}
+	rm -f ${OCATALOG}
+	if [ -f ${OCATALOG}.old ]
+	then
+	    sed -e '1,10d' <${OCATALOG}.old >>${TRANSCAT}.old
+	    rm -f ${OCATALOG}.old
+	fi
+    fi
+
+    ## ------------------------------------------------------------------
+    TRANSCAT=/etc/sgml/transitional.cat
+    if [ -f ${TRANSCAT} ]
+    then
+	update-catalog --add --super ${TRANSCAT}
+    fi
+
+fi
+
+## ---------------------------------------------------------------------- 
+## automatically generated debhelper commands
+#DEBHELPER#
+
+exit 0
+
+## ----------------------------------------------------------------------

Added: packages/sgml-base/trunk/debian/sgml-base.postrm
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/sgml-base.postrm?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/sgml-base.postrm (added)
+++ packages/sgml-base/trunk/debian/sgml-base.postrm Tue Sep  2 11:59:05 2008
@@ -1,0 +1,37 @@
+#!/bin/sh
+## ----------------------------------------------------------------------
+## debian/postrm : postremoval script for sgml-base
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+set -e
+
+## ----------------------------------------------------------------------
+if [ "$1" = "purge" ]
+then
+
+    ## ------------------------------------------------------------------
+    ## remove SGML root catalog
+    rm -f /etc/sgml/catalog /etc/sgml/catalog.old
+
+    ## ------------------------------------------------------------------
+    ## remove /etc/sgml
+    cd /etc
+    rmdir --ignore-fail-on-non-empty sgml
+    cd - >/dev/null
+
+    ## ------------------------------------------------------------------
+    ## remove /var/lib/sgml-base
+    cd /var/lib
+    rmdir --ignore-fail-on-non-empty sgml-base
+    cd - >/dev/null
+
+fi
+
+## ---------------------------------------------------------------------- 
+## automatically generated debhelper commands
+#DEBHELPER#
+
+exit 0
+
+## ----------------------------------------------------------------------

Added: packages/sgml-base/trunk/debian/sgml-base.preinst
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/sgml-base.preinst?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/sgml-base.preinst (added)
+++ packages/sgml-base/trunk/debian/sgml-base.preinst Tue Sep  2 11:59:05 2008
@@ -1,0 +1,35 @@
+#!/bin/sh
+## ----------------------------------------------------------------------
+## debian/preinst : preinstallation script for sgml-base
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+set -e
+
+## ----------------------------------------------------------------------
+if [ "$1" = "install" -o "$1" = "upgrade" ]
+then
+
+    ## ------------------------------------------------------------------
+    ## create /var/lib/sgml-base
+    if [ ! -d /var/lib/sgml-base ]
+    then
+	mkdir /var/lib/sgml-base 2>/dev/null
+    fi
+
+    ## ------------------------------------------------------------------
+    ## create /etc/sgml
+    if [ ! -d /etc/sgml ]
+    then
+	mkdir /etc/sgml 2>/dev/null
+    fi
+
+fi
+
+## ---------------------------------------------------------------------- 
+## automatically generated debhelper commands
+#DEBHELPER#
+
+exit 0
+
+## ----------------------------------------------------------------------

Added: packages/sgml-base/trunk/debian/sgml-base.prerm
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/debian/sgml-base.prerm?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/debian/sgml-base.prerm (added)
+++ packages/sgml-base/trunk/debian/sgml-base.prerm Tue Sep  2 11:59:05 2008
@@ -1,0 +1,29 @@
+#!/bin/sh
+## ----------------------------------------------------------------------
+## debian/prerm : preremoval script for sgml-base
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+set -e
+
+## ----------------------------------------------------------------------
+if [ "$1" = "remove" ] || [ "$1" = "upgrade" ]
+then
+
+    ## ------------------------------------------------------------------
+    TRANSCAT=/etc/sgml/transitional.cat
+    if [ -f ${TRANSCAT} ]
+    then
+	update-catalog --remove --super ${TRANSCAT} || true
+	rm -f ${TRANSCAT} ${TRANSCAT}.old
+    fi
+
+fi
+
+## ---------------------------------------------------------------------- 
+## automatically generated debhelper commands
+#DEBHELPER#
+
+exit 0
+
+## ----------------------------------------------------------------------

Added: packages/sgml-base/trunk/examples/postinst
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/examples/postinst?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/examples/postinst (added)
+++ packages/sgml-base/trunk/examples/postinst Tue Sep  2 11:59:05 2008
@@ -1,0 +1,31 @@
+#!/bin/sh
+## ----------------------------------------------------------------------
+## debian/postinst: postinstallation script for foo
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+## Abort if any command returns an error value
+set -e
+
+## --------------------------------------------------------------
+## Install SGML catalog entries
+PACKAGE=foo
+CENTRALCAT="/etc/sgml/${PACKAGE}.cat"
+ORDCATS="${PACKAGE}/dtd/sgml/1.0/catalog ${PACKAGE}/entities/catalog"
+if [ "$1" = "configure" ]
+then
+    install-sgmlcatalog --quiet --remove ${PACKAGE} || true
+    for ordcat in ${ORDCATS}
+    do
+        update-catalog --quiet --add ${CENTRALCAT} /usr/share/sgml/${ordcat}
+    done
+    update-catalog --quiet --add --super ${CENTRALCAT}
+fi
+
+## ----------------------------------------------------------------------
+## Automatically added sections
+#DEBHELPER#
+
+exit 0
+
+## ----------------------------------------------------------------------

Propchange: packages/sgml-base/trunk/examples/postinst
------------------------------------------------------------------------------
    svn:executable = 

Added: packages/sgml-base/trunk/examples/postrm
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/examples/postrm?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/examples/postrm (added)
+++ packages/sgml-base/trunk/examples/postrm Tue Sep  2 11:59:05 2008
@@ -1,0 +1,25 @@
+#!/bin/sh
+## ----------------------------------------------------------------------
+## debian/postrm: postremoval script for foo
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+## Abort if any command returns an error value
+set -e
+
+## --------------------------------------------------------------
+## Remove SGML catalog entries
+PACKAGE=foo
+CENTRALCAT="/etc/sgml/${PACKAGE}.cat"
+if [ "$1" = "purge" ]
+then
+    rm -f ${CENTRALCAT} ${CENTRALCAT}.old
+fi
+
+## ----------------------------------------------------------------------
+## Automatically added sections
+#DEBHELPER#
+
+exit 0
+
+## ----------------------------------------------------------------------

Propchange: packages/sgml-base/trunk/examples/postrm
------------------------------------------------------------------------------
    svn:executable = 

Added: packages/sgml-base/trunk/examples/prerm
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/examples/prerm?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/examples/prerm (added)
+++ packages/sgml-base/trunk/examples/prerm Tue Sep  2 11:59:05 2008
@@ -1,0 +1,25 @@
+#!/bin/sh
+## ----------------------------------------------------------------------
+## debian/prerm: preremoval script for foo
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+## Abort if any command returns an error value
+set -e
+
+## --------------------------------------------------------------
+## Remove SGML catalog entries
+PACKAGE=foo
+CENTRALCAT="/etc/sgml/${PACKAGE}.cat"
+if [ "$1" = "remove" ] || [ "$1" = "upgrade" ]
+then
+    update-catalog --quiet --remove --super ${CENTRALCAT}
+fi
+
+## ----------------------------------------------------------------------
+## Automatically added sections
+#DEBHELPER#
+
+exit 0
+
+## ----------------------------------------------------------------------

Propchange: packages/sgml-base/trunk/examples/prerm
------------------------------------------------------------------------------
    svn:executable = 

Added: packages/sgml-base/trunk/tools/Makefile
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/tools/Makefile?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/tools/Makefile (added)
+++ packages/sgml-base/trunk/tools/Makefile Tue Sep  2 11:59:05 2008
@@ -1,0 +1,57 @@
+## ----------------------------------------------------------------------
+## Makefile : makefile for sgml-base/tools
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+include ../MAKE/include
+
+## ----------------------------------------------------------------------
+## Package file definitions
+templates	= \
+		catalog.super \
+		catalog.centralized \
+		transitional.cat
+sbins		= \
+		update-catalog \
+		install-sgmlcatalog
+man8s		= \
+		$(addsuffix .$(man8_ext),$(sbins))
+
+## ----------------------------------------------------------------------
+## targets
+
+all:		$(man8s)
+
+%.$(man8_ext):	%
+
+		$(POD2MAN) --section $(man8_ext) --center $(pkg_name) ${<} ${@}
+
+
+install:
+
+		set -e; \
+		$(INSTALL_DIR) $(pkg_share_dir); \
+		for f in $(templates); \
+		do \
+			$(INSTALL_FILE) $${f} $(pkg_share_dir); \
+		done
+
+		set -e; \
+		$(INSTALL_DIR) $(sbin_dir); \
+		for f in $(sbins); \
+		do \
+			$(INSTALL_BIN) $${f} $(sbin_dir); \
+		done
+
+		set -e; \
+		$(INSTALL_DIR) $(man8_dir); \
+		for f in $(man8s); \
+		do \
+			$(INSTALL_FILE) $${f} $(man8_dir); \
+		done
+
+.PHONY:		\
+		all \
+		install
+
+## ----------------------------------------------------------------------

Added: packages/sgml-base/trunk/tools/catalog.centralized
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/tools/catalog.centralized?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/tools/catalog.centralized (added)
+++ packages/sgml-base/trunk/tools/catalog.centralized Tue Sep  2 11:59:05 2008
@@ -1,0 +1,7 @@
+-- 
+## ======================================================================
+## CATALOG : SGML Open Style centralized catalog
+## ======================================================================
+## Please use update-catalog(8) to modify this file.
+## ======================================================================
+--

Added: packages/sgml-base/trunk/tools/catalog.super
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/tools/catalog.super?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/tools/catalog.super (added)
+++ packages/sgml-base/trunk/tools/catalog.super Tue Sep  2 11:59:05 2008
@@ -1,0 +1,7 @@
+-- 
+## ======================================================================
+## /etc/sgml/catalog : SGML Open Style super catalog
+## ======================================================================
+## Please use update-catalog(8) to modify this file.
+## ======================================================================
+--

Added: packages/sgml-base/trunk/tools/install-sgmlcatalog
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/tools/install-sgmlcatalog?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/tools/install-sgmlcatalog (added)
+++ packages/sgml-base/trunk/tools/install-sgmlcatalog Tue Sep  2 11:59:05 2008
@@ -1,0 +1,157 @@
+#!/usr/bin/perl
+## ----------------------------------------------------------------------
+## install-sgmlcatalog : Debian SGML catalog management tool
+## ----------------------------------------------------------------------
+## Copyright (c) 1997 Christian Schwarz
+## Copyright (c) 2001-2004 Ardo van Rangelrooij
+##
+## This is free software; see the GNU General Public Licence version 2
+## or later for copying conditions.  There is NO warranty.
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+use strict;
+use warnings;
+
+## ----------------------------------------------------------------------
+use Getopt::Long qw( &GetOptions );
+
+## ----------------------------------------------------------------------
+$0 =~ m|[^/]+$|;
+
+## ----------------------------------------------------------------------
+my $name = $&;
+
+## ----------------------------------------------------------------------
+use vars qw( $package );
+use vars qw( $quiet );
+
+## ----------------------------------------------------------------------
+Getopt::Long::Configure( 'no_ignore_case' );
+if ( ! GetOptions(
+		  'quiet' => \$quiet,
+		  'remove=s' => \$package,
+		  )
+     )
+{
+    &usage();
+    exit 1;
+}
+
+## ----------------------------------------------------------------------
+if ( ! defined( $package ) )
+{
+    &usage();
+    exit -1;
+}
+
+## ----------------------------------------------------------------------
+&remove( $package );
+
+## ----------------------------------------------------------------------
+exit 0;
+
+## ----------------------------------------------------------------------
+sub remove
+{
+
+    ## ------------------------------------------------------------------
+    my $package = $_[0];
+
+    ## ----------------------------------------------------------------------
+    my $catalog = '/etc/sgml/transitional.cat';
+    my $backup  = '/etc/sgml/transitional.cat.old';
+
+    ## ------------------------------------------------------------------
+    return if ( ! -f $catalog );
+
+    ## ----------------------------------------------------------------------
+    my $top_marker    = '-- START SGML CATALOG ENTRY FOR PACKAGE';
+    my $bottom_marker = '-- END SGML CATALOG ENTRY FOR PACKAGE';
+    my $eol_marker    = '--';
+
+    ## ------------------------------------------------------------------
+    my @data;
+
+   ## -------------------------------------------------------------------
+    open( CATALOG, '<', $catalog )
+	or &error( "cannot open SGML catalog $catalog for reading: $!" );
+
+   ## -------------------------------------------------------------------
+    while ( <CATALOG> )
+    {
+	chop;
+	if ( /$top_marker $package $eol_marker/o )
+	{
+	    if ( $data[ $#data ] =~ /^\s*/o )
+	    {
+		pop( @data );
+	    }
+	    while ( !/$bottom_marker $package $eol_marker/o )
+	    {
+		if ( not ($_ = <CATALOG>) )
+		{
+		    &error( "cannot find bottom marker for package $package:\n    $bottom_marker $package $eol_marker\nplease remove the entry for $package manually" );
+		}
+	    }
+	}
+	else
+	{
+	    push( @data, $_ );
+	}
+    }
+
+    ## ------------------------------------------------------------------
+    close( CATALOG )
+	or &error( "cannot close SGML catalog $catalog: $!" );
+
+    ## ------------------------------------------------------------------
+    if ( -f $catalog )
+    {
+	if ( -f $backup )
+	{
+	    unlink( $backup )
+		or &error( "cannot remove backup of catalog $backup: $!" );
+	}
+	rename( $catalog, $backup )
+	    or &error( "cannot rename $catalog to $backup: $!" );
+    }
+
+    ## ------------------------------------------------------------------
+    open( CATALOG, '>', $catalog )
+	or &error( "cannot open SGML catalog $catalog for writing: $!" );
+
+    ## ------------------------------------------------------------------
+    for ( @data )
+    {
+	print CATALOG "$_\n";
+    }
+
+    ## ------------------------------------------------------------------
+    close( CATALOG )
+	or &error( "cannot close SGML catalog $catalog: $!" );
+
+} ## remove
+
+## ----------------------------------------------------------------------
+sub usage
+{
+
+    ## ------------------------------------------------------------------
+    print STDERR <<END;
+Usage:
+    $name --remove package
+END
+
+} ## usage
+
+## ----------------------------------------------------------------------
+sub error
+{
+
+    ## ------------------------------------------------------------------
+    die "$name: error: $_[0]\n";
+
+} ## error
+
+## ----------------------------------------------------------------------

Propchange: packages/sgml-base/trunk/tools/install-sgmlcatalog
------------------------------------------------------------------------------
    svn:executable = 

Added: packages/sgml-base/trunk/tools/install-sgmlcatalog.8
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/tools/install-sgmlcatalog.8?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/tools/install-sgmlcatalog.8 (added)
+++ packages/sgml-base/trunk/tools/install-sgmlcatalog.8 Tue Sep  2 11:59:05 2008
@@ -1,0 +1,56 @@
+.\" -*- nroff -*-
+.\" ----------------------------------------------------------------------
+.\" install-sgmlcatalog.8 : manual page for install-sgmlcatalog(8)
+.\" ----------------------------------------------------------------------
+.\" Copyright (c) 1997 Christian Schwarz
+.\" Copyright (c) 2001-2004 Ardo van Rangelrooij
+.\"
+.\" This is free software; see the GNU General Public Licence version 2
+.\" or later for copying conditions.  There is NO warranty.
+.\" ----------------------------------------------------------------------
+.\"
+.\" ----------------------------------------------------------------------
+.TH INSTALL-SGMLCATALOG 8 "August 2004" "Debian Project" "Debian"
+.\"
+.\" ----------------------------------------------------------------------
+.SH NAME
+install-sgmlcatalog \- maintain transitional SGML catalog
+.\"
+.\" ----------------------------------------------------------------------
+.SH SYNOPSIS
+.B install-sgmlcatalog
+.B \-\-remove
+.I package
+.\"
+.\" ----------------------------------------------------------------------
+.SH DESCRIPTION
+.PP
+.B install-sgmlcatalog
+removes entries from the transitional SGML catalog file
+.BR /etc/sgml/transitional.cat .
+.\"
+.\" ----------------------------------------------------------------------
+.SH OPTIONS
+.TP
+.BI \-\-remove \ package
+Indicates to remove the entry for the package
+.IR package .
+.\"
+.\" ----------------------------------------------------------------------
+.SH AUTHOR
+Ardo van Rangelrooij <ardo at debian.org>
+.br
+Christian Schwarz (original version)
+.\"
+.\" ----------------------------------------------------------------------
+.SH COPYRIGHT
+Copyright \(co 1997 Christian Schwarz
+.br
+Copyright \(co 2001-2004 Ardo van Rangelrooij
+
+This is free software; see the GNU General Public Licence version 2 or
+later for copying conditions.  There is
+.I no
+warranty.
+.\"
+.\" ----------------------------------------------------------------------

Added: packages/sgml-base/trunk/tools/transitional.cat
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/tools/transitional.cat?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/tools/transitional.cat (added)
+++ packages/sgml-base/trunk/tools/transitional.cat Tue Sep  2 11:59:05 2008
@@ -1,0 +1,7 @@
+-- 
+## ======================================================================
+## /usr/lib/sgml/transitional.cat : SGML Open style entity catalog
+## ======================================================================
+## Please use install-sgmlcatalog(8) to modify this file.
+## ======================================================================
+--

Added: packages/sgml-base/trunk/tools/update-catalog
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/tools/update-catalog?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/tools/update-catalog (added)
+++ packages/sgml-base/trunk/tools/update-catalog Tue Sep  2 11:59:05 2008
@@ -1,0 +1,245 @@
+#!/usr/bin/perl
+## ----------------------------------------------------------------------
+## Debian GNU/Linux update-catalog version 0.2
+## ----------------------------------------------------------------------
+## Copyright (c) 2001-2004 Ardo van Rangelrooij
+##
+## This is free software; see the GNU General Public Licence version 2
+## or later for copying conditions.  There is NO warranty.
+## ----------------------------------------------------------------------
+
+## ----------------------------------------------------------------------
+use strict;
+
+## ----------------------------------------------------------------------
+$0 =~ m|[^/]+$|;
+
+## ----------------------------------------------------------------------
+use vars qw( $name );
+$name = $&;
+
+## ----------------------------------------------------------------------
+use vars qw( $add );
+use vars qw( $backup );
+use vars qw( $catalog );
+use vars qw( @data );
+use vars qw( $debug );
+use vars qw( $entry );
+use vars qw( $quiet );
+use vars qw( $remove );
+use vars qw( $super );
+use vars qw( $template );
+use vars qw( $type );
+
+## ----------------------------------------------------------------------
+while ( $ARGV[0] =~ m/^--/ )
+{
+    $_ = shift( @ARGV );
+    last if $_ eq '--';
+    if ( $_ eq '--add' )
+    {
+        $add = 1;
+    }
+    elsif ( $_ eq '--remove' )
+    {
+        $remove = 1;
+    }
+    elsif ( $_ eq '--quiet' )
+    {
+        $quiet = 1;
+    }
+    elsif ( $_ eq '--super' )
+    {
+        $super = 1;
+    }
+    elsif ( $_ eq '--test' )
+    {
+        $debug = 1;
+    }
+    elsif ( $_ eq '--help' )
+    {
+        &help;
+	exit -1;
+    }
+    elsif ( $_ eq '--version' )
+    {
+        &help;
+	exit -1;
+    }
+    else
+    {
+        print STDERR "$name: unknown option \`$_'\n";
+	&help;
+	exit 1;
+    }
+}
+
+## ----------------------------------------------------------------------
+if ( ! @ARGV )
+{
+    print STDERR "\n";
+    &help;
+    exit 1;
+}
+
+## ----------------------------------------------------------------------
+if ( $add || $remove )
+{
+    if ( $super )
+    {
+	$catalog = '/etc/sgml/catalog';
+    }
+    else
+    {
+	$catalog = shift( @ARGV );
+    }
+}
+
+## ----------------------------------------------------------------------
+if ( ! @ARGV )
+{
+    print STDERR "\n";
+    &help;
+    exit 1;
+}
+
+## ----------------------------------------------------------------------
+$entry = shift( @ARGV );
+
+## ----------------------------------------------------------------------
+if ( @ARGV )
+{
+    print STDERR "$name: too many arguments\n";
+    &help;
+    exit 1;
+}
+
+## ----------------------------------------------------------------------
+if ( $add == $remove )
+{
+    print "Huh? You have to use --add or --remove (not both).\n";
+    exit 1;
+}
+
+## ----------------------------------------------------------------------
+print STDERR "$name: test mode - catalog file will not be updated\n"
+    if $debug && ! $quiet;
+
+## ----------------------------------------------------------------------
+if ( $add )
+{
+    print "Adding entry $entry to catalog $catalog...\n"
+        unless $quiet;
+    
+    &read_catalog_without_entry;
+    &add_entry;
+    &write_catalog;
+}
+elsif ( $remove )
+{
+    print "Removing entry $entry from catalog $catalog...\n"
+        unless $quiet;
+    
+    &read_catalog_without_entry;
+    &write_catalog;
+}
+
+## ----------------------------------------------------------------------
+exit 0;
+
+## ----------------------------------------------------------------------
+ sub read_catalog_without_entry
+{
+    if ( -f $catalog )
+    {
+	print "Reading catalog $catalog and removing entry $entry...\n"
+	    if $debug;
+	open( CATALOG, "<$catalog" )
+	    or die "cannot open catalog $catalog for reading: $!";
+	while ( <CATALOG> )
+	{
+	    chop;
+	    push( @data, $_ ) unless m/$entry/;
+	}
+	close( CATALOG );
+    }
+    else
+    {
+	$type = $super ? 'super' : 'centralized';
+	$template = "/usr/share/sgml-base/catalog.$type";
+	print "Reading template $template...\n"
+	    if $debug;
+	open( TEMPLATE, "<$template" )
+	    or die "cannot open template $template for reading: $!";
+	while ( <TEMPLATE> )
+	{
+	    chop;
+	    s|CATALOG|$catalog| if m/CATALOG/;
+	    push( @data, $_ );
+	}
+	close( TEMPLATE );
+    }
+}
+
+## ----------------------------------------------------------------------
+sub add_entry
+{
+    print "Appending entry $entry...\n" if $debug;
+    push( @data, "CATALOG $entry" );
+}
+
+## ----------------------------------------------------------------------
+sub write_catalog
+{
+    $backup = $catalog . '.old';
+    if ( not $debug )
+    {
+	if ( -f $catalog )
+	{
+	    # remove old backup file
+	    if ( -f $backup )
+	    {
+		unlink( $backup )
+		    or die "cannot remove backup copy $backup: $!";
+	    }
+	    rename( $catalog, $backup )
+		or die "cannot rename $catalog to $backup: $!";
+	}
+	open( CATALOG, ">$catalog" )
+	    or die "cannot open catalog $catalog for writing: $!";
+	for ( @data ) { print CATALOG "$_\n"; };
+	close( CATALOG );
+    }
+    else
+    {
+	print "Writing new entry to $catalog...\n";
+	for ( @data ) { print "$_\n"; };
+    }
+}
+
+## ----------------------------------------------------------------------
+sub help
+{
+    print STDERR <<END;
+Usage:
+    $name <options> --add --super <centralized_catalog>
+    $name <options> --add <centralized_catalog> <ordinary_catalog>
+or
+    $name <options> --remove --super <centralized_catalog>
+    $name <options> --remove <centralized_catalog> <ordinary_catalog>
+
+Options:
+    --quiet         be quiet
+    --test          do not modify any files, enables debugging mode
+    --version       display version number
+    --help          display this text
+END
+}
+
+## ----------------------------------------------------------------------
+sub version
+{
+    print "Debian $name version 0.2\n";
+}
+
+## ----------------------------------------------------------------------

Propchange: packages/sgml-base/trunk/tools/update-catalog
------------------------------------------------------------------------------
    svn:executable = 

Added: packages/sgml-base/trunk/tools/update-catalog.8
URL: http://svn.debian.org/wsvn/debian-xml-sgml/packages/sgml-base/trunk/tools/update-catalog.8?rev=1145&op=file
==============================================================================
--- packages/sgml-base/trunk/tools/update-catalog.8 (added)
+++ packages/sgml-base/trunk/tools/update-catalog.8 Tue Sep  2 11:59:05 2008
@@ -1,0 +1,97 @@
+.\" -*- nroff -*-
+.\" ----------------------------------------------------------------------
+.\" Copyright (c) 2001-2004 Ardo van Rangelrooij
+.\"
+.\" This is free software; see the GNU General Public Licence version 2
+.\" or later for copying conditions.  There is NO warranty.
+.\" ----------------------------------------------------------------------
+.\"
+.\" ----------------------------------------------------------------------
+.TH UPDATE-CATALOG 8 "June 2004" "Debian Project" "Debian"
+.\"
+.\" ----------------------------------------------------------------------
+.SH NAME
+update-catalog \- create or update entry in SGML catalog file
+.\"
+.\" ----------------------------------------------------------------------
+.SH SYNOPSIS
+.B update-catalog
+.RI [ options ]
+.B --add --super
+.I centralized_catalog
+.PP
+.B update-catalog
+.RI [ options ]
+.B --add
+.I centralized_catalog ordinary_catalog
+.PP
+.B update-catalog
+.RI [ options ]
+.B --remove --super
+.I centralized_catalog
+.PP
+.B update-catalog
+.RI [ options ]
+.B --remove
+.I centralized_catalog ordinary_catalog
+.\"
+.\" ----------------------------------------------------------------------
+.SH DESCRIPTION
+.PP
+.B update-catalog
+inserts, updates or removes entries in the SGML super catalog
+.I /etc/sgml/catalog
+and the
+SGML centralized catalogs located in
+.IR /etc/sgml .
+.\"
+.\" ----------------------------------------------------------------------
+.SH OPTIONS
+.TP
+.B --add
+Adds an entry for the
+.I centralized_catalog
+in the super catalog
+.IR /etc/sgml/catalog ,
+or an entry for the
+.I ordinary_catalog
+in the
+.IR centralized_catalog .
+.TP
+.B --remove
+Removes the entry for the
+.I centralized_catalog
+from the super catalog
+.IR /etc/sgml/catalog ,
+or the entry for the
+.I ordinary_catalog
+from the
+.IR centralized_catalog .
+.TP
+.B --quiet
+Prevents the usual diagnostic output.
+.TP
+.B --test
+Prevents the update of the catalog and writes the resulting SGML
+catalog to standard output.
+.TP
+.B --version
+Displays the version information and exits.
+.TP
+.B --help
+Display the usage information and exits.
+.\"
+.\" ----------------------------------------------------------------------
+.SH AUTHOR
+Ardo van Rangelrooij <ardo at debian.org>
+.\"
+.\" ----------------------------------------------------------------------
+.SH COPYRIGHT
+Copyright \(co 2001-2004 Ardo van Rangelrooij
+
+This is free software; see the GNU General Public Licence version 2 or
+later for copying conditions.  There is
+.I no
+warranty.
+.\"
+.\" ----------------------------------------------------------------------




More information about the debian-xml-sgml-commit mailing list