* build-aux/texi2dvi: Update from Subversion Texinfo.
---
ChangeLog | 6 +++++
build-aux/texi2dvi | 72 ++++++++++++++++++++++++++++++----------------------
2 files changed, 47 insertions(+), 31 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 92e5243..45dbc13 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2014-07-01 Roland Levillain <roland(a)lrde.epita.fr>
+
+ Update texi2dvi from upstream.
+
+ * build-aux/texi2dvi: Update from Subversion Texinfo.
+
2012-06-07 Guillaume Lazzara <z(a)lrde.epita.fr>
Fix last warnings with Lintian.
diff --git a/build-aux/texi2dvi b/build-aux/texi2dvi
index 6bddb06..33d6a72 100755
--- a/build-aux/texi2dvi
+++ b/build-aux/texi2dvi
@@ -1,9 +1,9 @@
#! /bin/sh
# texi2dvi --- produce DVI (or PDF) files from Texinfo (or (La)TeX) sources.
-# $Id: texi2dvi,v 1.173 2012/04/20 18:52:48 karl Exp $
+# $Id: texi2dvi 5649 2014-06-08 22:02:26Z karl $
#
# Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014
# Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
@@ -34,7 +34,7 @@ unset RUNNING_KSH
set -e
# This string is expanded automatically when this file is checked out.
-rcs_revision='$Revision: 1.173 $'
+rcs_revision='$Revision: 5649 $'
rcs_version=`set - $rcs_revision; echo $2`
program=`echo $0 | sed -e 's!.*/!!'`
@@ -52,7 +52,7 @@ escape="\\"
expand=false # true for expansion via makeinfo
includes=
line_error=true # pass --file-line-error to TeX
-max_iters=-1 # keep going forever
+max_iters=7 # when to quit
oname= # --output
out_lang=dvi
quiet=false # let the tools' message be displayed
@@ -358,7 +358,7 @@ Build modes:
defaults to TEXI2DVI_BUILD_DIRECTORY [$build_dir]
--mostly-clean remove the auxiliary files and directories
but not the output
- --max-iterations=N don't process files more than N times
+ --max-iterations=N don't process files more than N times [$max_iters]
The MODE specifies where the TeX compilation takes place, and, as a
consequence, how auxiliary files are treated. The build mode
@@ -391,8 +391,8 @@ directory, occasionally TeX won't be able to find some files
(e.g., when
using \\graphicspath): in that case, use -I to specify the additional
directories to consider.
-The values of the BIBTEX, DVIPDF, DVIPS, HEVEA, LATEX, MAKEINDEX,
-MAKEINFO, PDFLATEX, PDFTEX, T4HT, TEX, TEX4HT, TEXINDEX, and THUMBPDF
+The values of the BIBER, BIBTEX, DVIPDF, DVIPS, HEVEA, LATEX, MAKEINDEX,
+MAKEINFO, PDFLATEX, PDFTEX, T4HT, TEX, TEX4HT, TEXINDEX, and THUMBPDF_CMD
environment variables are used to run those commands, if they are set.
Regarding --dvipdf, if DVIPDF is not set in the environment, the
@@ -428,9 +428,9 @@ verbose ()
version ()
{
cat <<EOF
-texi2dvi (GNU Texinfo 4.13+dev) $rcs_version
+texi2dvi (GNU Texinfo 5.2) $rcs_version
-Copyright (C) 2012 Free Software Foundation, Inc.
+Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
@@ -709,7 +709,7 @@ move_to_dest ()
false:*) destfile=$oname
destdir=`dirname "$destfile"`;;
esac
-
+
# We want to compare the source location and the output location,
# and if they are different, do the move. But if they are the
# same, we must preserve the source. Since we can't assume
@@ -899,9 +899,13 @@ xref_files_changed ()
if grep "Rerun to get" "$in_noext.log" >&6 2>&1;
then
return 0
fi
+ # biblatex report of whether rerunning is needed.
+ if grep "biblatex.*(re)run" "$in_noext.log" >&6 2>&1;
then
+ return 0
+ fi
- # If old and new lists don't at least have the same file list,
- # then one file or another has definitely changed.
+ # If old and new lists don't have the same file list,
+ # then something has definitely changed.
xref_files_new=`generated_files_get "$in_noext" xref_file_p`
verbose "Original xref files = $xref_files_orig"
verbose "New xref files = $xref_files_new"
@@ -1073,20 +1077,19 @@ run_tex ()
# run_bibtex ()
# -------------
-# Run bibtex on current file.
+# Run bibtex on (or biber) current file.
# - If its input (AUX) exists.
# - If some citations are missing (LOG contains `Citation').
# or the LOG complains of a missing .bbl
#
# Don't try to be too smart:
-#
# 1. Running bibtex only if the bbl file exists and is older than
# the LaTeX file is wrong, since the document might include files
# that have changed.
#
# 3. Because there can be several AUX (if there are \include's),
# but a single LOG, looking for missing citations in LOG is
-# easier, though we take the risk to match false messages.
+# easier, though we take the risk of matching false messages.
run_bibtex ()
{
case $in_lang in
@@ -1100,18 +1103,24 @@ run_bibtex ()
# bibtex would never be run.
if test -r "$in_noext.aux" \
&& test -r "$in_noext.log" \
- && ((grep 'Warning:.*Citation.*undefined' "$in_noext.log"
\
+ && ( (grep 'Warning:.*Citation.*undefined' "$in_noext.log"
\
|| grep '.*Undefined citation' "$in_noext.log" \
|| grep 'No file .*\.bbl\.' "$in_noext.log") \
|| (grep 'No \.aux file' "$in_noext.log" \
- && grep '^\\bibdata' "$in_noext.aux")) \
+ && grep '^\\bibdata' "$in_noext.aux") ) \
&6 2>&1; \
then
- for f in `generated_files_get "$in_noext" bibaux_file_p`
- do
+ bibtex_aux=`generated_files_get "$in_noext" bibaux_file_p`
+ for f in $bibtex_aux; do
run $bibtex "$f"
done
fi
+
+ # biber(+biblatex) check.
+ if test -r "$in_noext.bcf" \
+ && grep '</bcf:controlfile>' "$in_noext.bcf"
>/dev/null; then
+ run ${BIBER:-biber} "$in_noext"
+ fi
}
# run_index ()
@@ -1191,7 +1200,7 @@ run_thumbpdf ()
&& test -r "$in_noext.log" \
&& grep 'thumbpdf\.sty' "$in_noext.log" >&6
2>&1; \
then
- thumbpdf=${THUMBPDF:-thumbpdf}
+ thumbpdf=${THUMBPDF_CMD:-thumbpdf}
thumbcmd="$thumbpdf $in_dir/$in_noext"
verbose "Running $thumbcmd ..."
if $thumbcmd >&5; then
@@ -1253,9 +1262,9 @@ run_tex_suite ()
xref_files_save
- # We run bibtex first, because I can see reasons for the indexes
- # to change after bibtex is run, but I see no reason for the
- # converse.
+ # We run bibtex first, because it's more likely for the indexes
+ # to change after bibtex is run than the reverse, though either
+ # would be rare.
run_bibtex
run_index
run_core_conversion
@@ -1360,7 +1369,10 @@ run_makeinfo ()
# close stdin.
$TEX txiversion.tex </dev/null >txiversion.out 2>txiversion.err
); then :; else
- report "texinfo.tex appears to be broken:"
+ report "texinfo.tex appears to be broken.
+This may be due to the environment variable TEX set to something
+other than (plain) tex, a corrupt texinfo.tex file, or
+to tex itself simply not working."
cat "$version_test_dir/txiversion.out"
cat "$version_test_dir/txiversion.err" >&2
error 1 "quitting."
@@ -1685,7 +1697,6 @@ while test x"$1" != x"$arg_sep"; do
;;
esac
- # This recognizes --quark as --quiet. Oh well.
case "$1" in
-@ ) escape=@;;
-~ ) catcode_special=false;;
@@ -1717,7 +1728,7 @@ while test x"$1" != x"$arg_sep"; do
-r | --recode) recode=true;;
--recode-from) shift; recode=true; recode_from="$1";;
--src-specials) src_specials=--src-specials;;
- --shell-escape) shell_escape=--shell-escape;;
+ --shell-escape) shell_escape=--shell-escape;;
--tex4ht) latex2html=tex4ht;;
-t | --texinfo | --command ) shift; textra="$textra\\
"`echo "$1" | sed 's/\\\\/\\\\\\\\/g'`;;
@@ -1775,9 +1786,8 @@ this script, you'll need to install TeX (if you don't have
it) or change
your PATH or TEX environment variable (if you do). See the --help
output for more details.
-For information about obtaining TeX, please see
http://www.tug.org. If
-you happen to be using Debian, you can get it with this command:
- apt-get install tetex-bin
+For information about obtaining TeX, please see
http://tug.org/texlive,
+or do a web search for TeX and your operating system or distro.
EOM
exit 1
fi
@@ -1819,12 +1829,12 @@ fi
# Enable tracing, and auxiliary tools output.
-#
+#
# This fd should be used where you'd typically use /dev/null to throw
# output away. But sometimes it is convenient to see that output (e.g.,
# from a grep) to aid debugging. Especially debugging at distance, via
# the user.
-#
+#
if $debug; then
exec 6>&1
set -vx
--
1.7.10.4