diff options
author | Gaetan Nadon <memsize@videotron.ca> | 2010-09-13 15:37:23 -0400 |
---|---|---|
committer | Gaetan Nadon <memsize@videotron.ca> | 2010-09-14 11:46:03 -0400 |
commit | 2f1e4820e6867fb3e7c1cf684200ed5d936dcaef (patch) | |
tree | fa462f543abc742b340b23092ab24a6c2502ed33 | |
parent | 31df41d34725f2d43e28a0247582992873ef6d5d (diff) |
config: build CTEXT spec now in DocBook XML format
Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
-rw-r--r-- | Makefile.am | 3 | ||||
-rw-r--r-- | configure.ac | 14 | ||||
-rw-r--r-- | specs/.gitignore | 5 | ||||
-rw-r--r-- | specs/CTEXT/Makefile.am | 9 | ||||
-rw-r--r-- | specs/Makefile.am | 1 | ||||
-rw-r--r-- | specs/xmlrules.in | 64 |
6 files changed, 90 insertions, 6 deletions
diff --git a/Makefile.am b/Makefile.am index dd3e2aa..36423a0 100644 --- a/Makefile.am +++ b/Makefile.am @@ -20,7 +20,7 @@ # # Process this file with autoconf to create configure. -SUBDIRS = man sgml +SUBDIRS = man sgml specs dist_doc_DATA = MAINTAINERS @@ -32,7 +32,6 @@ EXTRA_DIST = \ specs/BDF/bdf.ms \ specs/BDF/fig1.ps \ specs/BDF/fig2.ps \ - specs/CTEXT/ctext.xml \ specs/ICCCM/icccm.xml \ specs/RX/RX.mif \ specs/SIAddresses/hostname.txt \ diff --git a/configure.ac b/configure.ac index 7f6141b..80374bb 100644 --- a/configure.ac +++ b/configure.ac @@ -32,12 +32,16 @@ AC_CONFIG_SRCDIR([Makefile.am]) AM_INIT_AUTOMAKE([foreign dist-bzip2]) AM_MAINTAINER_MODE -# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS +# Require xorg-macros minimum of 1.10 for DocBook XML documentation m4_ifndef([XORG_MACROS_VERSION], - [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])]) -XORG_MACROS_VERSION(1.8) + [m4_fatal([must install xorg-macros 1.10 or later before running autoconf/autogen])]) +XORG_MACROS_VERSION(1.10) XORG_DEFAULT_OPTIONS XORG_ENABLE_DOCS +XORG_ENABLE_SPECS +XORG_WITH_XMLTO(0.0.20) +XORG_WITH_FOP +XORG_CHECK_SGML_DOCTOOLS(1.5) XORG_CHECK_DOCBOOK AC_CONFIG_FILES([Makefile @@ -47,5 +51,7 @@ AC_CONFIG_FILES([Makefile sgml/graphics/Makefile sgml/input/Makefile sgml/platforms/Makefile - sgml/security/Makefile]) + sgml/security/Makefile + specs/Makefile + specs/CTEXT/Makefile]) AC_OUTPUT diff --git a/specs/.gitignore b/specs/.gitignore new file mode 100644 index 0000000..09b6a89 --- /dev/null +++ b/specs/.gitignore @@ -0,0 +1,5 @@ +*.html +*.ps +*.pdf +*.txt +*.css diff --git a/specs/CTEXT/Makefile.am b/specs/CTEXT/Makefile.am new file mode 100644 index 0000000..1125e75 --- /dev/null +++ b/specs/CTEXT/Makefile.am @@ -0,0 +1,9 @@ +if ENABLE_SPECS + +specdir = $(docdir)/$(subdir) +doc_sources = ctext.xml +dist_spec_DATA = $(doc_sources) + +include $(top_srcdir)/specs/xmlrules.in + +endif ENABLE_SPECS diff --git a/specs/Makefile.am b/specs/Makefile.am new file mode 100644 index 0000000..677e235 --- /dev/null +++ b/specs/Makefile.am @@ -0,0 +1 @@ +SUBDIRS=CTEXT diff --git a/specs/xmlrules.in b/specs/xmlrules.in new file mode 100644 index 0000000..313d9bc --- /dev/null +++ b/specs/xmlrules.in @@ -0,0 +1,64 @@ +# +# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. +# +# Permission is hereby granted, free of charge, to any person obtaining a +# copy of this software and associated documentation files (the "Software"), +# to deal in the Software without restriction, including without limitation +# the rights to use, copy, modify, merge, publish, distribute, sublicense, +# and/or sell copies of the Software, and to permit persons to whom the +# Software is furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice (including the next +# paragraph) shall be included in all copies or substantial portions of the +# Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +# DEALINGS IN THE SOFTWARE. +# + +if HAVE_XMLTO +spec_DATA = $(doc_sources:.xml=.html) + +if HAVE_FOP +spec_DATA += $(doc_sources:.xml=.ps) $(doc_sources:.xml=.pdf) +endif + +if HAVE_XMLTO_TEXT +spec_DATA += $(doc_sources:.xml=.txt) +endif + +if HAVE_STYLESHEETS +XMLTO_FLAGS = -m $(XSL_STYLESHEET) --stringparam img.src.path=$(abs_builddir)/ + +spec_DATA += xorg.css +xorg.css: $(STYLESHEET_SRCDIR)/xorg.css + $(AM_V_GEN)cp -pf $(STYLESHEET_SRCDIR)/xorg.css $@ +endif + +CLEANFILES = $(spec_DATA) + +SUFFIXES = .xml .ps .pdf .txt .html + +%.txt: %.xml $(dist_spec_DATA) + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) txt $< + +%.html: %.xml $(dist_spec_DATA) + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) xhtml-nochunks $< + +%.pdf: %.xml $(dist_spec_DATA) + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) --with-fop pdf $< + +%.ps: %.xml $(dist_spec_DATA) + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) --with-fop ps $< + +chunked-html: $(doc_sources) + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) -o html xhtml $(doc_sources) + +CLEANFILES += html + +endif HAVE_XMLTO |