[PATCH 3/3] Show Xserver release/version date in DIX & DDX docs

Dan Nicholson dbn.lists at gmail.com
Fri May 14 17:02:36 PDT 2010


On Fri, May 14, 2010 at 4:45 PM, Alan Coopersmith
<alan.coopersmith at oracle.com> wrote:
> Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>
> ---
>  configure.ac                    |    2 ++
>  doc/xml/Makefile.am             |    2 ++
>  doc/xml/Xserver-spec.xml        |    4 +++-
>  doc/xml/xserver.ent.in          |    3 +++
>  hw/xfree86/doc/sgml/DESIGN.xml  |    4 +++-
>  hw/xfree86/doc/sgml/Makefile.am |    6 ++++++
>  6 files changed, 19 insertions(+), 2 deletions(-)
>  create mode 100644 doc/xml/xserver.ent.in
>
> diff --git a/configure.ac b/configure.ac
> index 6593f8b..fd34b24 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -2140,6 +2140,7 @@ AC_TRY_COMPILE([
>
>  AC_DEFINE_DIR(PROJECTROOT, prefix, [Overall prefix])
>
> +AC_SUBST([RELEASE_DATE])
>  BUILD_DATE="`date +'%Y%m%d'`"
>  AC_SUBST([BUILD_DATE])
>  BUILD_TIME="`date +'1%H%M%S'`"
> @@ -2163,6 +2164,7 @@ dbe/Makefile
>  dix/Makefile
>  doc/Makefile
>  doc/xml/Makefile
> +doc/xml/xserver.ent
>  fb/Makefile
>  record/Makefile
>  config/Makefile
> diff --git a/doc/xml/Makefile.am b/doc/xml/Makefile.am
> index df4833c..000551c 100644
> --- a/doc/xml/Makefile.am
> +++ b/doc/xml/Makefile.am
> @@ -31,3 +31,5 @@ endif
>  CLEANFILES = $(CLEAN_DOC_FILES)
>
>  EXTRA_DIST = $(XML_FILES)
> +
> +Xserver-spec.xml: xserver.ent
> diff --git a/doc/xml/Xserver-spec.xml b/doc/xml/Xserver-spec.xml
> index 8691f18..5ce13c9 100644
> --- a/doc/xml/Xserver-spec.xml
> +++ b/doc/xml/Xserver-spec.xml
> @@ -1,6 +1,7 @@
>  <?xml version="1.0" encoding="ISO-8859-1"?>
>  <!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
>  "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
> + <!ENTITY % defs SYSTEM "xserver.ent"> %defs;
>  ]>
>
>  <article>
> @@ -38,7 +39,8 @@
>       <affiliation><orgname>X.org Foundation and Hewlett Packard</orgname></affiliation>
>     </author>
>     <publisher><publishername>The X.Org Foundation</publishername></publisher>
> -    <pubdate>2004</pubdate>
> +    <pubdate>&xserver.reldate;</pubdate>
> +    <releaseinfo>X server version &xserver.version;</releaseinfo>
>     <title>Definition of the Porting Layer for the X v11 Sample Server</title>
>     <titleabbrev>X Porting Layer</titleabbrev>
>     <revhistory>
> diff --git a/doc/xml/xserver.ent.in b/doc/xml/xserver.ent.in
> new file mode 100644
> index 0000000..5cb4e23
> --- /dev/null
> +++ b/doc/xml/xserver.ent.in
> @@ -0,0 +1,3 @@
> +<!-- shared -*-xml-*- entity definitions for the X server documentation -->
> +<!ENTITY xserver.version "@PACKAGE_VERSION@">
> +<!ENTITY xserver.reldate "@RELEASE_DATE@">
> diff --git a/hw/xfree86/doc/sgml/DESIGN.xml b/hw/xfree86/doc/sgml/DESIGN.xml
> index 337cf49..b995152 100644
> --- a/hw/xfree86/doc/sgml/DESIGN.xml
> +++ b/hw/xfree86/doc/sgml/DESIGN.xml
> @@ -1,6 +1,7 @@
>  <?xml version="1.0" encoding="ISO-8859-1"?>
>  <!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
>  "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
> + <!ENTITY % defs SYSTEM "xserver.ent"> %defs;
>  <!-- config file keyword markup -->
>  <!-- specific config file keywords -->
>  <!ENTITY k.device "<emphasis>Device</emphasis>">
> @@ -29,7 +30,8 @@
>       </othercredit>
>     </authorgroup>
>
> -    <pubdate>19 December 2003</pubdate>
> +    <pubdate>&xserver.reldate;</pubdate>
> +    <releaseinfo>Xorg server version &xserver.version;</releaseinfo>
>
>   </articleinfo>
>
> diff --git a/hw/xfree86/doc/sgml/Makefile.am b/hw/xfree86/doc/sgml/Makefile.am
> index 5322b42..917545f 100644
> --- a/hw/xfree86/doc/sgml/Makefile.am
> +++ b/hw/xfree86/doc/sgml/Makefile.am
> @@ -29,3 +29,9 @@ endif
>  CLEANFILES = $(CLEAN_DOC_FILES)
>
>  EXTRA_DIST = $(XML_FILES)
> +
> +DESIGN.xml: xserver.ent
> +
> +xserver.ent: $(top_builddir)/doc/xml/xserver.ent
> +       -rm -f $@
> +       ln -s $(top_builddir)/doc/xml/xserver.ent $@

Not sure this would work, but instead of copying the entity file to
the current directory, can you just pass --searchpath to xmlto? I.e.,
in xmlrules.in:

XMLTO_FLAGS = --searchpath $(top_builddir)/doc/xml

.xml.html:
	@rm -f $@
	$(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) xhtml-nochunks $<

This might only work if the SYSTEM entity references use absolute
paths with "file:///", though.

--
Dan


More information about the xorg-devel mailing list