[PATCH sgml-doctools] Upgrade xorg-sgml-doctools to Autoconf 2.60 directory architecture

Alan Coopersmith alan.coopersmith at oracle.com
Mon Nov 8 16:08:35 PST 2010


Gaetan Nadon wrote:
> Currently the value of sgmlrootdir is hard coded relative to $prefix.
> In Autoconf 2.60, $datarootdir has been added to define the architecture
> independent data directory.
> 
>   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
> 
> Relative to that location, a number of subdirectories have been defined:
> 
>   --datadir=DIR      read-only architecture-independent data [DATAROOTDIR]
>   --infodir=DIR      info documentation [DATAROOTDIR/info]
>   --localedir=DIR    locale-dependent data [DATAROOTDIR/locale]
>   --mandir=DIR       man documentation [DATAROOTDIR/man]
>   --docdir=DIR       documentation root
>                      [DATAROOTDIR/doc/xorg-sgml-doctools]
>   --htmldir=DIR      html documentation [DOCDIR]
>   --dvidir=DIR       dvi documentation [DOCDIR]
>   --pdfdir=DIR       pdf documentation [DOCDIR]
>   --psdir=DIR        ps documentation [DOCDIR]
> 
> The sgmlrootdir should hang off datarootdir. If there is a need to specify
> a different location, a new configure option should be added:
> 
>   --sgmldir=DIR      sgml stylesheets and entities [DATAROOTDIR/sgml]
> 
> An sgmlrootdir Automake variable is defined in configure.ac to provide
> a unique value holder for the sgmlrootdir.
> 
> Variable PACKAGE_VERSION is preferred over the undocumented VERSION variable.
> 
> Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
> ---
>  Makefile.am              |    2 +-
>  configure.ac             |    2 ++
>  xorg-sgml-doctools.pc.in |    7 ++++---
>  3 files changed, 7 insertions(+), 4 deletions(-)
> 
> diff --git a/Makefile.am b/Makefile.am
> index 049abac..e3fcca5 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -19,7 +19,7 @@
>  #  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
>  #  PERFORMANCE OF THIS SOFTWARE.
>  
> -sgmldir = $(prefix)/share/sgml/X11
> +sgmldir = $(sgmlrootdir)/X11
>  
>  dist_sgml_DATA = defs.ent xorg.css xorg.xsl
>  
> diff --git a/configure.ac b/configure.ac
> index 6ca9198..9a05526 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -34,6 +34,8 @@ m4_ifndef([XORG_MACROS_VERSION],
>  XORG_MACROS_VERSION(1.3)
>  XORG_DEFAULT_OPTIONS
>  
> +AC_SUBST([sgmlrootdir],['${datarootdir}/sgml'])
> +
>  AC_PROG_INSTALL
>  
>  AC_OUTPUT([
> diff --git a/xorg-sgml-doctools.pc.in b/xorg-sgml-doctools.pc.in
> index ae1422a..9546fa7 100644
> --- a/xorg-sgml-doctools.pc.in
> +++ b/xorg-sgml-doctools.pc.in
> @@ -1,6 +1,7 @@
>  prefix=@prefix@
> -sgmlrootdir=${prefix}/share/sgml
> +datarootdir=@datarootdir@
> +sgmlrootdir=@sgmlrootdir@
>  
>  Name: xorg-sgml-doctools
> -Description: SGML entities for X.Org documentation
> -Version: @VERSION@
> +Description: Stylesheets and entities for X.Org documentation
> +Version: @PACKAGE_VERSION@

Reviewed-by: Alan Coopersmith <alan.coopersmith at oracle.com>

-- 
	-Alan Coopersmith-        alan.coopersmith at oracle.com
	 Oracle Solaris Platform Engineering: X Window System



More information about the xorg-devel mailing list