texinfo-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

texinfo update (Thu Sep 29 17:22:01 EDT 2005)


From: Karl Berry
Subject: texinfo update (Thu Sep 29 17:22:01 EDT 2005)
Date: Thu, 29 Sep 2005 17:22:45 -0400

Index: configure.ac
===================================================================
RCS file: /cvsroot/texinfo/texinfo/configure.ac,v
retrieving revision 1.59
retrieving revision 1.60
diff -c -r1.59 -r1.60
*** configure.ac        5 Aug 2005 09:25:44 -0000       1.59
--- configure.ac        29 Sep 2005 21:06:22 -0000      1.60
***************
*** 1,5 ****
  # Process this file with autoconf to produce a configure script.
! # $Id: configure.ac,v 1.59 2005/08/05 09:25:44 kasal Exp $
  #
  # This file is free software; as a special exception the author gives
  # unlimited permission to copy and/or distribute it, with or without
--- 1,5 ----
  # Process this file with autoconf to produce a configure script.
! # $Id: configure.ac,v 1.60 2005/09/29 21:06:22 karl Exp $
  #
  # This file is free software; as a special exception the author gives
  # unlimited permission to copy and/or distribute it, with or without
***************
*** 83,89 ****
  # We need to run some of our own binaries, most notably makedoc, but as
  # long as we have this process, we also use our own makeinfo and
  # install-info.
! # 
  # This means that if we are cross compiling, we have to configure the
  # package twice: once with the native compiler (this is done in a
  # subdirectory $native_tools), and once with the cross compiler.
--- 83,89 ----
  # We need to run some of our own binaries, most notably makedoc, but as
  # long as we have this process, we also use our own makeinfo and
  # install-info.
! #
  # This means that if we are cross compiling, we have to configure the
  # package twice: once with the native compiler (this is done in a
  # subdirectory $native_tools), and once with the cross compiler.
***************
*** 208,213 ****
--- 208,215 ----
  # gettextize -f -c
  AM_GNU_GETTEXT_VERSION([0.14.5])
  AM_GNU_GETTEXT([external])
+ 
+ dnl util/defs
  
  AC_CONFIG_FILES([
    Makefile
Index: doc/Makefile.am
===================================================================
RCS file: /cvsroot/texinfo/texinfo/doc/Makefile.am,v
retrieving revision 1.29
retrieving revision 1.30
diff -c -r1.29 -r1.30
*** doc/Makefile.am     17 Aug 2005 12:43:06 -0000      1.29
--- doc/Makefile.am     29 Sep 2005 21:06:22 -0000      1.30
***************
*** 1,4 ****
! # $Id: Makefile.am,v 1.29 2005/08/17 12:43:06 karl Exp $
  # Makefile.am for texinfo/doc.
  # Run automake in .. to produce Makefile.in from this.
  #
--- 1,4 ----
! # $Id: Makefile.am,v 1.30 2005/09/29 21:06:22 karl Exp $
  # Makefile.am for texinfo/doc.
  # Run automake in .. to produce Makefile.in from this.
  #
***************
*** 27,33 ****
  
  TXI_XLATE = txi-cs.tex txi-de.tex txi-en.tex txi-es.tex txi-fr.tex \
            txi-it.tex txi-nl.tex txi-no.tex txi-pl.tex txi-pt.tex \
!           txi-sr.tex txi-tr.tex 
  
  # Include our texinfo.tex, not Automake's.
  EXTRA_DIST = epsf.tex pdfcolor.tex texinfo.tex \
--- 27,33 ----
  
  TXI_XLATE = txi-cs.tex txi-de.tex txi-en.tex txi-es.tex txi-fr.tex \
            txi-it.tex txi-nl.tex txi-no.tex txi-pl.tex txi-pt.tex \
!           txi-sr.tex txi-tr.tex
  
  # Include our texinfo.tex, not Automake's.
  EXTRA_DIST = epsf.tex pdfcolor.tex texinfo.tex \
***************
*** 97,108 ****
        mv $@ address@hidden
        sed '/^\.IP$$/N;/\nAlso/s/I//;/\nThe/s/I//' address@hidden >$@
        rm address@hidden
!       
  $(srcdir)/texindex.1: $(top_srcdir)/util/texindex.c $(common_mandeps)
        @name="sort Texinfo index files" && $(man_rule_bin)
  
! $(srcdir)/texi2dvi.1: $(top_srcdir)/util/texi2dvi $(common_mandeps)
!       $(HELP2MAN) --name="print Texinfo documents" 
$(top_srcdir)/util/texi2dvi >$@
  
  # Do not create info files for distribution.
  dist-info:
--- 97,118 ----
        mv $@ address@hidden
        sed '/^\.IP$$/N;/\nAlso/s/I//;/\nThe/s/I//' address@hidden >$@
        rm address@hidden
! 
  $(srcdir)/texindex.1: $(top_srcdir)/util/texindex.c $(common_mandeps)
        @name="sort Texinfo index files" && $(man_rule_bin)
  
! 
! common_texi2dvi_deps = $(common_mandeps) \
!                        $(top_srcdir)/util/texi2dvi $(top_srcdir)/util/texi2pdf
! 
! $(srcdir)/texi2dvi.1: $(common_texi2dvi_deps)
!       $(HELP2MAN) --name="convert Texinfo documents to DVI" 
$(top_srcdir)/util/texi2dvi >$@
! 
! $(srcdir)/texi2pdf.1: $(common_texi2dvi_deps)
!       $(HELP2MAN) --name="convert Texinfo documents to PDF" 
$(top_srcdir)/util/texi2pdf >$@
! 
! $(srcdir)/pdftexi2dvi.1:  $(common_texi2dvi_deps)
!       $(HELP2MAN) --name="convert Texinfo documents to PDF" 
$(top_srcdir)/util/pdftexi2dvi >$@
  
  # Do not create info files for distribution.
  dist-info:
Index: doc/texinfo.txi
===================================================================
RCS file: /cvsroot/texinfo/texinfo/doc/texinfo.txi,v
retrieving revision 1.148
retrieving revision 1.149
diff -c -r1.148 -r1.149
*** doc/texinfo.txi     19 Sep 2005 12:50:54 -0000      1.148
--- doc/texinfo.txi     29 Sep 2005 21:06:23 -0000      1.149
***************
*** 1,5 ****
  \input texinfo.tex    @c -*-texinfo-*-
! @c $Id: texinfo.txi,v 1.148 2005/09/19 12:50:54 karl Exp $
  @c Ordinarily, Texinfo files have the extension .texi.  But texinfo.texi
  @c clashes with texinfo.tex on 8.3 filesystems, so we use texinfo.txi.
  
--- 1,5 ----
  \input texinfo.tex    @c -*-texinfo-*-
! @c $Id: texinfo.txi,v 1.149 2005/09/29 21:06:23 karl Exp $
  @c Ordinarily, Texinfo files have the extension .texi.  But texinfo.texi
  @c clashes with texinfo.tex on 8.3 filesystems, so we use texinfo.txi.
  
***************
*** 60,65 ****
--- 60,66 ----
  * install-info: (texinfo)Invoking install-info. Update info/dir entries.
  * texi2dvi: (texinfo)Format with texi2dvi.      Print Texinfo documents.
  * texi2pdf: (texinfo)PDF Output.                PDF output for Texinfo.
+ * pdftexi2dvi: (texinfo)PDF Output.             PDF output for Texinfo.
  * texindex: (texinfo)Format with tex/texindex.  Sort Texinfo index files.
  * makeinfo: (texinfo)Invoking makeinfo.         Translate Texinfo source.
  @end direntry
***************
*** 14242,14248 ****
  With the @option{--pdf} option, @command{texi2dvi} produces PDF output
  instead of DVI (@pxref{PDF Output}), by running @command{pdftex}
  instead of @command{tex}.  Alternatively, the command
! @command{texi2pdf} is an abbreviation for running @samp{texi2dvi --pdf}.
  
  @cindex @LaTeX{}, processing with @command{texi2dvi}
  @command{texi2dvi} can also be used to process @LaTeX{} files; simply
--- 14243,14252 ----
  With the @option{--pdf} option, @command{texi2dvi} produces PDF output
  instead of DVI (@pxref{PDF Output}), by running @command{pdftex}
  instead of @command{tex}.  Alternatively, the command
! @command{texi2pdf} is an abbreviation for running @samp{texi2dvi
! --pdf}.  The command @command{pdftexi2dvi} is also supported as a
! convenience to address@hidden users, since the latter merely prepends
! @samp{pdf} to DVI producing tools to have PDF producing tools.
  
  @cindex @LaTeX{}, processing with @command{texi2dvi}
  @command{texi2dvi} can also be used to process @LaTeX{} files; simply
***************
*** 14919,14930 ****
  
  @pindex pdftex
  The simplest way to generate PDF output from Texinfo source is to run
! the convenience script @command{texi2pdf}; this simply executes the
! @command{texi2dvi} script with the @option{--pdf} option
! (@pxref{Format with texi2dvi}).  If for some reason you want to
! process by hand, simply run the @command{pdftex} program instead of
! plain @command{tex}.  That is, run @samp{pdftex foo.texi} instead of
! @samp{tex foo.texi}.
  
  @dfn{PDF} stands for `Portable Document Format'. It was invented by
  Adobe Systems some years ago for document interchange, based on their
--- 14923,14934 ----
  
  @pindex pdftex
  The simplest way to generate PDF output from Texinfo source is to run
! the convenience script @command{texi2pdf} (or @command{pdftexi2dvi});
! this simply executes the @command{texi2dvi} script with the
! @option{--pdf} option (@pxref{Format with texi2dvi}).  If for some
! reason you want to process the document by hand, simply run the
! @command{pdftex} program instead of plain @command{tex}.  That is, run
! @samp{pdftex foo.texi} instead of @samp{tex foo.texi}.
  
  @dfn{PDF} stands for `Portable Document Format'. It was invented by
  Adobe Systems some years ago for document interchange, based on their
***************
*** 18589,18595 ****
  (@url{http://www.gnu.org/software/rcs}) version control systems, which
  expand it into a string such as:
  @example
! $Id: texinfo.txi,v 1.148 2005/09/19 12:50:54 karl Exp $
  @end example
  (This is useful in all sources that use version control, not just manuals.)
  You may wish to include the @samp{$Id:} comment in the @code{@@copying}
--- 18593,18599 ----
  (@url{http://www.gnu.org/software/rcs}) version control systems, which
  expand it into a string such as:
  @example
! $Id: texinfo.txi,v 1.149 2005/09/29 21:06:23 karl Exp $
  @end example
  (This is useful in all sources that use version control, not just manuals.)
  You may wish to include the @samp{$Id:} comment in the @code{@@copying}
***************
*** 18655,18661 ****
  
  @verbatim
  \input texinfo   @c -*-texinfo-*-
! @comment $Id: texinfo.txi,v 1.148 2005/09/19 12:50:54 karl Exp $
  @comment %**start of header
  @setfilename sample.info
  @include version.texi
--- 18659,18665 ----
  
  @verbatim
  \input texinfo   @c -*-texinfo-*-
! @comment $Id: texinfo.txi,v 1.149 2005/09/29 21:06:23 karl Exp $
  @comment %**start of header
  @setfilename sample.info
  @include version.texi
Index: util/Makefile.am
===================================================================
RCS file: /cvsroot/texinfo/texinfo/util/Makefile.am,v
retrieving revision 1.18
retrieving revision 1.19
diff -c -r1.18 -r1.19
*** util/Makefile.am    29 Sep 2005 12:25:07 -0000      1.18
--- util/Makefile.am    29 Sep 2005 21:06:23 -0000      1.19
***************
*** 1,4 ****
! # $Id: Makefile.am,v 1.18 2005/09/29 12:25:07 karl Exp $
  # Makefile.am for texinfo/util.
  # Run automake in .. to produce Makefile.in from this.
  #
--- 1,4 ----
! # $Id: Makefile.am,v 1.19 2005/09/29 21:06:23 karl Exp $
  # Makefile.am for texinfo/util.
  # Run automake in .. to produce Makefile.in from this.
  #
***************
*** 47,49 ****
--- 47,67 ----
    prepinfo.awk tex3patch texi-docstring-magic.el texi2dvi texi2pdf txitextest 
\
    $(dist_pkgdata_DATA) texinfo-cat.in
  CLEANFILES = $(pkgdata_DATA)
+ 
+ 
+ ## ------- ##
+ ## Tests.  ##
+ ## ------- ##
+ 
+ XFAIL_TESTS =
+ 
+ TESTS =       \
+ local.test texi2dvi.test
+ 
+ EXTRA_DIST += $(TESTS)
+ 
+ # Each test case depends on defs.
+ check_SCRIPTS = defs
+ 
+ distclean-local:
+       -rm -rf testSubDir
Index: util/texi2dvi
===================================================================
RCS file: /cvsroot/texinfo/texinfo/util/texi2dvi,v
retrieving revision 1.62
retrieving revision 1.63
diff -c -r1.62 -r1.63
*** util/texi2dvi       23 Sep 2005 00:05:45 -0000      1.62
--- util/texi2dvi       29 Sep 2005 21:06:23 -0000      1.63
***************
*** 1,6 ****
  #! /bin/sh
  # texi2dvi --- produce DVI (or PDF) files from Texinfo (or (La)TeX) sources.
! # $Id: texi2dvi,v 1.62 2005/09/23 00:05:45 karl Exp $
  #
  # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001,
  # 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
--- 1,6 ----
  #! /bin/sh
  # texi2dvi --- produce DVI (or PDF) files from Texinfo (or (La)TeX) sources.
! # $Id: texi2dvi,v 1.63 2005/09/29 21:06:23 karl Exp $
  #
  # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001,
  # 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
***************
*** 32,38 ****
  unset RUNNING_KSH
  
  # This string is expanded by rcs automatically when this file is checked out.
! rcs_revision='$Revision: 1.62 $'
  rcs_version=`set - $rcs_revision; echo $2`
  program=`echo $0 | sed -e 's!.*/!!'`
  version="texi2dvi (GNU Texinfo 4.8) $rcs_version
--- 32,38 ----
  unset RUNNING_KSH
  
  # This string is expanded by rcs automatically when this file is checked out.
! rcs_revision='$Revision: 1.63 $'
  rcs_version=`set - $rcs_revision; echo $2`
  program=`echo $0 | sed -e 's!.*/!!'`
  version="texi2dvi (GNU Texinfo 4.8) $rcs_version
***************
*** 147,153 ****
  recode=false
  set_language=
  textra=         # Extra TeX commands to insert in the input file.
- textra_cmd=     # sed command to insert TEXTRA where appropriate
  txincludes=     # TEXINPUTS extensions, with trailing colon
  txiprereq=19990129 # minimum texinfo.tex version with macro expansion
  verb=false      # true for verbose mode
--- 147,152 ----
***************
*** 174,179 ****
--- 173,194 ----
  ## Auxiliary functions.  ##
  ## --------------------- ##
  
+ 
+ # In case `local' is not supported by the shell.
+ (
+   foo=bar
+   test_local () {
+     local foo=foo
+   }
+   test_local
+   test $foo = bar
+ ) || local () {
+   case $1 in
+     *=*) eval "$1";;
+   esac
+ }
+ 
+ 
  # func_dirname FILE
  # -----------------
  # Return the directory part of FILE.
***************
*** 183,195 ****
    || { echo "$1" | sed 's!/[^/]*$!!;s!^$!.!'; }
  }
  
! # return true if program $1 is somewhere in PATH, else false.
! #
  findprog ()
  {
!   foundprog=false
! 
!   saveIFS=$IFS
    IFS=$path_sep  # break path components at the path separator
    for dir in $PATH; do
      IFS=$saveIFS
--- 198,209 ----
    || { echo "$1" | sed 's!/[^/]*$!!;s!^$!.!'; }
  }
  
! # findprog PROG
! # -------------
! # Return true if PROG is somewhere in PATH, else false.
  findprog ()
  {
!   local saveIFS=$IFS
    IFS=$path_sep  # break path components at the path separator
    for dir in $PATH; do
      IFS=$saveIFS
***************
*** 204,214 ****
      #
      if  { test -f "$dir/$1"   && test -x "$dir/$1"; } ||
        { test -f "$dir/$1.exe" && test -x "$dir/$1.exe"; }; then
!       foundprog=true
!       break
      fi
    done
!   $foundprog
  }
  
  # report LINE1 LINE2...
--- 218,227 ----
      #
      if  { test -f "$dir/$1"   && test -x "$dir/$1"; } ||
        { test -f "$dir/$1.exe" && test -x "$dir/$1.exe"; }; then
!       return 0
      fi
    done
!   return 1
  }
  
  # report LINE1 LINE2...
***************
*** 266,301 ****
  done
  
  
- # get_xref_files FILENAME-NOEXT
- # -----------------------------
- # Compute the list of xref files (indexes, tables and lists).
- get_xref_files ()
- {
-   if $tidy; then
-     # In a tidy build, all the files around as actual outputs.
-     ls * 2>/dev/null
-   else
-     # Find all files having root filename with a two-letter extension,
-     # saves the ones that are really Texinfo-related files.
-     # - .?o?
-     #   .toc, .log, LaTeX tables and lists, FiXme's .lox, maybe more.
-     # - bu[0-9]*.aux
-     #   Sub bibliography when using the LaTeX bibunits package.
-     ls "$1".?o? "$1".aux bu[0-9]*.aux "$1".?? "$1".idx 2>/dev/null
-   fi |
-   while read file; do
-     # If the file is not suitable to be an index or xref file, don't
-     # process it.  It's suitable if the first character is a
-     # backslash or right quote or at, as long as the first line isn't
-     # \input texinfo.
-     case `sed '1q' $file` in
-       "\\input texinfo"*) ;;
-       [\\''@]*) echo "./$file";;
-     esac
-   done
- }
- 
- 
  # get_index_files FILE1 FILE2...
  # ------------------------------
  # Select the files that are indexes to run texindex/makeindex onto.
--- 279,284 ----
***************
*** 319,347 ****
  # Hopefully no one will have an actual directory named EMPTY.
  absolute_filenames ()
  {
!   replace_empty="-e 's/^$path_sep/EMPTY$path_sep/g' \
!                  -e 's/$path_sep\$/${path_sep}EMPTY/g' \
!                  -e 's/$path_sep$path_sep/${path_sep}EMPTY:/g'"
!   _res=`echo "$1" | eval sed $replace_empty`
    save_IFS=$IFS
    IFS=$path_sep
!   set x $_res; shift
!   _res=.
    for dir
    do
      case $dir in
        EMPTY)
!         _res=$_res$path_sep
          ;;
        [\\/]* | ?:[\\/]*)        # Absolute paths don't need to be expanded.
!         test -d $dir && _res=$_res$path_sep$dir
          ;;
        *)
!         test -d $dir && abs=`cd "$dir" && pwd` && _res=$_res$path_sep$abs
          ;;
      esac
    done
!   echo "$_res"
  }
  
  # move_to_dest FILE
--- 302,330 ----
  # Hopefully no one will have an actual directory named EMPTY.
  absolute_filenames ()
  {
!   local replace_empty="-e 's/^$path_sep/EMPTY$path_sep/g' \
!                        -e 's/$path_sep\$/${path_sep}EMPTY/g' \
!                        -e 's/$path_sep$path_sep/${path_sep}EMPTY:/g'"
!   local res=`echo "$1" | eval sed $replace_empty`
    save_IFS=$IFS
    IFS=$path_sep
!   set x $res; shift
!   res=.
    for dir
    do
      case $dir in
        EMPTY)
!         res=$res$path_sep
          ;;
        [\\/]* | ?:[\\/]*)        # Absolute paths don't need to be expanded.
!         test -d $dir && res=$res$path_sep$dir
          ;;
        *)
!         test -d $dir && abs=`cd "$dir" && pwd` && res=$res$path_sep$abs
          ;;
      esac
    done
!   echo "$res"
  }
  
  # move_to_dest FILE
***************
*** 351,376 ****
  # file with the same base name.
  move_to_dest ()
  {
!   _file_noext=`echo "$1" | sed 's/\.[^.]*$//'`
!   _file_ext=`echo "$1" | sed 's/^.*\.//'`
!   _out_noext=`echo "$oname" | sed 's/\.[^.]*$//'`
!   _out_ext=`echo "$oname" | sed 's/^.*\.//'`
  
    case $tidy:$oname in
!     true:)  _dest=$orig_pwd;;
!     false:) _dest=;;
!     *:*)    _dest=$_out_noext.$_file_ext;;
    esac
    if test ! -f "$1"; then
      fatal 1 "no such file or directory: $1"
    fi
!   if test -n "$_dest"; then
!     verbose "Copying $1 to $_dest"
!     cp -p "$1" "$_dest"
    fi
  }
  
  
  ## ----------------------- ##
  ## Running the TeX suite.  ##
  ## ----------------------- ##
--- 334,444 ----
  # file with the same base name.
  move_to_dest ()
  {
!   local file_noext=`echo "$1" | sed 's/\.[^.]*$//'`
!   local file_ext=`echo "$1" | sed 's/^.*\.//'`
!   local out_noext=`echo "$oname" | sed 's/\.[^.]*$//'`
!   local out_ext=`echo "$oname" | sed 's/^.*\.//'`
!   local dest
  
    case $tidy:$oname in
!     true:)  dest=$orig_pwd;;
!     false:) dest=;;
!     *:*)    dest=$out_noext.$file_ext;;
    esac
    if test ! -f "$1"; then
      fatal 1 "no such file or directory: $1"
    fi
!   if test -n "$dest"; then
!     verbose "Copying $1 to $dest"
!     cp -p "$1" "$dest"
!   fi
! }
! 
! 
! ## --------------------- ##
! ## Managing xref files.  ##
! ## --------------------- ##
! 
! 
! # xref_files_get FILENAME-NOEXT
! # -----------------------------
! # Compute the list of xref files (indexes, tables and lists).
! xref_files_get ()
! {
!   if $tidy; then
!     # In a tidy build, all the files around as actual outputs.
!     ls * 2>/dev/null
!   else
!     # Find all files having root filename with a two-letter extension,
!     # saves the ones that are really Texinfo-related files.
!     # - .?o?
!     #   .toc, .log, LaTeX tables and lists, FiXme's .lox, maybe more.
!     # - bu[0-9]*.aux
!     #   Sub bibliography when using the LaTeX bibunits package.
!     ls "$1".?o? "$1".aux bu[0-9]*.aux "$1".?? "$1".idx 2>/dev/null
!   fi |
!   while read file; do
!     # If the file is not suitable to be an index or xref file, don't
!     # process it.  It's suitable if the first character is a
!     # backslash or right quote or at, as long as the first line isn't
!     # \input texinfo.
!     case `sed '1q' $file` in
!       "\\input texinfo"*) ;;
!       [\\''@]*) echo "./$file";;
!     esac
!   done
! }
! 
! # xref_files_save
! # ---------------
! # Save the xref files.
! xref_files_save ()
! {
!   # Save copies of auxiliary files for later comparison.
!   xref_files_orig=`xref_files_get  "$filename_noext"`
!   if test -n "$xref_files_orig"; then
!     verbose "Backing up xref files: $xref_files_orig"
!     cp $xref_files_orig "$work_bak"
    fi
  }
  
  
+ # xref_files_changed
+ # ------------------
+ # Whether the xref files were changed since the previous run.
+ xref_files_changed ()
+ {
+   # LaTeX (and the package changebar) report in the LOG file if it
+   # should be rerun.  This is needed for files included from
+   # subdirs, since texi2dvi does not try to compare xref files in
+   # subdirs.  Performing xref files test is still good since LaTeX
+   # does not report changes in xref files.
+   grep "Rerun to get" "$filename_noext.log" >&6 2>&1 &&
+     return 0
+ 
+   # If old and new lists don't at least have the same file list,
+   # then one file or another has definitely changed.
+   xref_files_new=`xref_files_get  "$filename_noext"`
+   verbose "Original xref files = $xref_files_orig"
+   verbose "New xref files      = $xref_files_new"
+   test "x$xref_files_orig" != "x$xref_files_new" &&
+     return 0
+ 
+   # Compare each file until we find a difference.
+   for this_file in $xref_files_new; do
+     verbose "Comparing xref file `echo $this_file | sed 's|\./||g'` ..."
+     # cmp -s returns nonzero exit status if files differ.
+     if cmp -s "$this_file" "$work_bak/$this_file"; then :; else
+       verbose "xref file `echo $this_file | sed 's|\./||g'` differed ..."
+       $debug && diff -u "$work_bak/$this_file" "$this_file"
+       return 0
+     fi
+   done
+ 
+   # No change.
+   return 1
+ }
+ 
  ## ----------------------- ##
  ## Running the TeX suite.  ##
  ## ----------------------- ##
***************
*** 381,388 ****
  run_tex ()
  {
    case $language:$oformat in
-     latex:pdf)   tex=${PDFLATEX:-pdflatex};;
      latex:dvi)   tex=${LATEX:-latex};;
      texinfo:pdf) tex=$PDFTEX;;
      texinfo:dvi)
          # MetaPost also uses the TEX environment variable.  If the user
--- 449,456 ----
  run_tex ()
  {
    case $language:$oformat in
      latex:dvi)   tex=${LATEX:-latex};;
+     latex:pdf)   tex=${PDFLATEX:-pdflatex};;
      texinfo:pdf) tex=$PDFTEX;;
      texinfo:dvi)
          # MetaPost also uses the TEX environment variable.  If the user
***************
*** 507,513 ****
      latex)   texindex=${MAKEINDEX:-makeindex};;
      texinfo) texindex=${TEXINDEX:-texindex};;
    esac
!   index_files=`get_index_files $orig_xref_files`
    if test -n "$texindex" && test -n "$index_files"; then
      verbose "Running $texindex $index_files ..."
      $texindex $index_files 2>&5 1>&2 ||
--- 575,581 ----
      latex)   texindex=${MAKEINDEX:-makeindex};;
      texinfo) texindex=${TEXINDEX:-texindex};;
    esac
!   index_files=`get_index_files $xref_files_orig`
    if test -n "$texindex" && test -n "$index_files"; then
      verbose "Running $texindex $index_files ..."
      $texindex $index_files 2>&5 1>&2 ||
***************
*** 536,541 ****
--- 604,635 ----
  }
  
  
+ # run_tex_suite
+ # -------------
+ # Run the TeX tools until a fix point is reached.
+ run_tex_suite ()
+ {
+   # Count the number of cycles.
+   cycle=0
+ 
+   while :; do
+     cycle=`expr $cycle + 1`
+     verbose "Cycle $cycle for $command_line_filename"
+ 
+     xref_files_save
+ 
+     run_bibtex
+     run_index
+     run_te
      report "cannot read $command_line_filename, skipping."
      continue
--- 1013,1018 ----
***************
*** 967,999 ****
      eval verbose "$var=\'\$${var}\'"
    done
  
!   # If the user explicitly specified the language, use that.
!   # Otherwise, if the first line is \input texinfo, assume it's texinfo.
!   # Otherwise, guess from the file extension.
!   if test -n "$set_language"; then
!     language=$set_language
!   elif sed 1q "$command_line_filename" | grep 'input texinfo' >&6; then
!     language=texinfo
!   else
!     language=
!   fi
! 
!   # Get the type of the file (latex or texinfo) from the given language
!   # we just guessed, or from the file extension if not set yet.
!   case ${language:-$filename_ext} in
!     [lL]a[tT]e[xX] | *.ltx | *.tex | *.drv | *.dtx)
!       # Assume a LaTeX file.  LaTeX needs bibtex and uses latex for
!       # compilation.  No makeinfo.
!       language=latex
!       textra_cmd=1i
!       ;;
! 
!     *)
!       # Assume a Texinfo file.
!       language=texinfo
!       textra_cmd='/address@hidden/a'
!       ;;
!   esac
  
    # --expand
    run_makeinfo
--- 1090,1097 ----
      eval verbose "$var=\'\$${var}\'"
    done
  
!   # `texinfo' or `latex'?
!   language=`compute_language $command_line_filename`
  
    # --expand
    run_makeinfo
***************
*** 1004,1067 ****
    # --recode
    run_recode
  
-   # Count the number of cycles.
-   cycle=0
- 
    # Move to the working directory.
    if $tidy; then
      verbose "cd $work_build"
      cd "$work_build" || exit 1
    fi
  
!   while :; do # will break out of loop below
!     cycle=`expr $cycle + 1`
!     verbose "Cycle $cycle for $command_line_filename"
! 
!     # Save copies of auxiliary files for later comparison.
!     orig_xref_files=`get_xref_files  "$filename_noext"`
!     if test -n "$orig_xref_files"; then
!       verbose "Backing up xref files: $orig_xref_files"
!       cp $orig_xref_files "$work_bak"
!     fi
! 
!     run_bibtex
!     run_index
!     run_tex
! 
!     # LaTeX (and the package changebar) report in the LOG file if it
!     # should be rerun.  This is needed for files included from
!     # subdirs, since texi2dvi does not try to compare xref files in
!     # subdirs.  Performing xref files test is still good since LaTeX
!     # does not report changes in xref files.
!     grep "Rerun to get" "$filename_noext.log" >&6 2>&1 &&
!       continue
! 
!     # If old and new lists don't at least have the same file list,
!     # then one file or another has definitely changed.
!     new_xref_files=`get_xref_files  "$filename_noext"`
!     verbose "Original xref files = $orig_xref_files"
!     verbose "New xref files      = $new_xref_files"
!     test "x$orig_xref_files" != "x$new_xref_files" &&
!       continue
! 
!     # Compare each file until we find a difference.
!     for this_file in $new_xref_files; do
!       verbose "Comparing xref file `echo $this_file | sed 's|\./||g'` ..."
!       # cmp -s returns nonzero exit status if files differ.
!       if cmp -s "$this_file" "$work_bak/$this_file"; then :; else
!         verbose "xref file `echo $this_file | sed 's|\./||g'` differed ..."
!         $debug && diff -u "$work_bak/$this_file" "$this_file"
!         continue 2
!       fi
!     done
! 
!     # We're done.
!     break
!   done # while :;
! 
!   # If we were using thumbpdf and producing PDF, then run thumbpdf
!   # and TeX one last time.
!   run_thumbpdf
  
    # Both to make sure we can remove $t2ddir (we might have cd'd into
    # it), and in case $orig_pwd is on a different drive (for DOS).
--- 1102,1115 ----
    # --recode
    run_recode
  
    # Move to the working directory.
    if $tidy; then
      verbose "cd $work_build"
      cd "$work_build" || exit 1
    fi
  
!   # Run until a fix point is reached.
!   run_tex_suite
  
    # Both to make sure we can remove $t2ddir (we might have cd'd into
    # it), and in case $orig_pwd is on a different drive (for DOS).
P configure.ac
P doc/Makefile.am
P doc/texinfo.txi
P util/Makefile.am
P util/texi2dvi


reply via email to

[Prev in Thread] Current Thread [Next in Thread]