OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [tags/] [gdb/] [gdb-6.8/] [gdb-6.8.openrisc-2.1/] [readline/] [doc/] [texi2dvi] - Diff between revs 24 and 33

Only display areas with differences | Details | Blame | View Log

Rev 24 Rev 33
#! /bin/sh
#! /bin/sh
# texi2dvi --- produce DVI (or PDF) files from Texinfo (or LaTeX) sources.
# texi2dvi --- produce DVI (or PDF) files from Texinfo (or LaTeX) sources.
# $Id: texi2dvi,v 1.14 2003/02/05 00:42:33 karl Exp $
# $Id: texi2dvi,v 1.14 2003/02/05 00:42:33 karl Exp $
#
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001,
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001,
# 2002, 2003 Free Software Foundation, Inc.
# 2002, 2003 Free Software Foundation, Inc.
#
#
# This program is free software; you can redistribute it and/or modify
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
# any later version.
#
#
# This program is distributed in the hope that it will be useful,
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
# GNU General Public License for more details.
#
#
# You should have received a copy of the GNU General Public License
# You should have received a copy of the GNU General Public License
# along with this program; if not, you can either send email to this
# along with this program; if not, you can either send email to this
# program's maintainer or write to: The Free Software Foundation,
# program's maintainer or write to: The Free Software Foundation,
# Inc.; 59 Temple Place, Suite 330; Boston, MA 02111-1307, USA.
# Inc.; 59 Temple Place, Suite 330; Boston, MA 02111-1307, USA.
#
#
# Original author: Noah Friedman .
# Original author: Noah Friedman .
#
#
# Please send bug reports, etc. to bug-texinfo@gnu.org.
# Please send bug reports, etc. to bug-texinfo@gnu.org.
# If possible, please send a copy of the output of the script called with
# If possible, please send a copy of the output of the script called with
# the `--debug' option when making a bug report.
# the `--debug' option when making a bug report.
# This string is expanded by rcs automatically when this file is checked out.
# This string is expanded by rcs automatically when this file is checked out.
rcs_revision='$Revision: 1.14 $'
rcs_revision='$Revision: 1.14 $'
rcs_version=`set - $rcs_revision; echo $2`
rcs_version=`set - $rcs_revision; echo $2`
program=`echo $0 | sed -e 's!.*/!!'`
program=`echo $0 | sed -e 's!.*/!!'`
version="texi2dvi (GNU Texinfo 4.5) $rcs_version
version="texi2dvi (GNU Texinfo 4.5) $rcs_version
Copyright (C) 2003 Free Software Foundation, Inc.
Copyright (C) 2003 Free Software Foundation, Inc.
There is NO warranty.  You may redistribute this software
There is NO warranty.  You may redistribute this software
under the terms of the GNU General Public License.
under the terms of the GNU General Public License.
For more information about these matters, see the files named COPYING."
For more information about these matters, see the files named COPYING."
usage="Usage: $program [OPTION]... FILE...
usage="Usage: $program [OPTION]... FILE...
Run each Texinfo or LaTeX FILE through TeX in turn until all
Run each Texinfo or LaTeX FILE through TeX in turn until all
cross-references are resolved, building all indices.  The directory
cross-references are resolved, building all indices.  The directory
containing each FILE is searched for included files.  The suffix of FILE
containing each FILE is searched for included files.  The suffix of FILE
is used to determine its language (LaTeX or Texinfo).
is used to determine its language (LaTeX or Texinfo).
Makeinfo is used to perform Texinfo macro expansion before running TeX
Makeinfo is used to perform Texinfo macro expansion before running TeX
when needed.
when needed.
Operation modes:
Operation modes:
  -b, --batch         no interaction
  -b, --batch         no interaction
  -c, --clean         remove all auxiliary files
  -c, --clean         remove all auxiliary files
  -D, --debug         turn on shell debugging (set -x)
  -D, --debug         turn on shell debugging (set -x)
  -h, --help          display this help and exit successfully
  -h, --help          display this help and exit successfully
  -o, --output=OFILE  leave output in OFILE (implies --clean);
  -o, --output=OFILE  leave output in OFILE (implies --clean);
                      Only one input FILE may be specified in this case
                      Only one input FILE may be specified in this case
  -q, --quiet         no output unless errors (implies --batch)
  -q, --quiet         no output unless errors (implies --batch)
  -s, --silent        same as --quiet
  -s, --silent        same as --quiet
  -v, --version       display version information and exit successfully
  -v, --version       display version information and exit successfully
  -V, --verbose       report on what is done
  -V, --verbose       report on what is done
TeX tuning:
TeX tuning:
  -@                   use @input instead of \input; for preloaded Texinfo
  -@                   use @input instead of \input; for preloaded Texinfo
  -e, -E, --expand     force macro expansion using makeinfo
  -e, -E, --expand     force macro expansion using makeinfo
  -I DIR               search DIR for Texinfo files
  -I DIR               search DIR for Texinfo files
  -l, --language=LANG  specify the LANG of FILE (LaTeX or Texinfo)
  -l, --language=LANG  specify the LANG of FILE (LaTeX or Texinfo)
  -p, --pdf            use pdftex or pdflatex for processing
  -p, --pdf            use pdftex or pdflatex for processing
  -t, --texinfo=CMD    insert CMD after @setfilename in copy of input file
  -t, --texinfo=CMD    insert CMD after @setfilename in copy of input file
                       multiple values accumulate
                       multiple values accumulate
The values of the BIBTEX, LATEX (or PDFLATEX), MAKEINDEX, MAKEINFO,
The values of the BIBTEX, LATEX (or PDFLATEX), MAKEINDEX, MAKEINFO,
TEX (or PDFTEX), and TEXINDEX environment variables are used to run
TEX (or PDFTEX), and TEXINDEX environment variables are used to run
those commands, if they are set.
those commands, if they are set.
Email bug reports to ,
Email bug reports to ,
general questions and discussion to .
general questions and discussion to .
Texinfo home page: http://www.gnu.org/software/texinfo/"
Texinfo home page: http://www.gnu.org/software/texinfo/"
# Initialize variables for option overriding and otherwise.
# Initialize variables for option overriding and otherwise.
# Don't use `unset' since old bourne shells don't have this command.
# Don't use `unset' since old bourne shells don't have this command.
# Instead, assign them an empty value.
# Instead, assign them an empty value.
batch=false     # eval for batch mode
batch=false     # eval for batch mode
clean=
clean=
debug=
debug=
escape='\'
escape='\'
expand=         # t for expansion via makeinfo
expand=         # t for expansion via makeinfo
miincludes=     # makeinfo include path
miincludes=     # makeinfo include path
oformat=dvi
oformat=dvi
oname=          # --output
oname=          # --output
quiet=          # by default let the tools' message be displayed
quiet=          # by default let the tools' message be displayed
set_language=
set_language=
textra=
textra=
tmpdir=${TMPDIR:-/tmp}/t2d$$  # avoid collisions on 8.3 filesystems.
tmpdir=${TMPDIR:-/tmp}/t2d$$  # avoid collisions on 8.3 filesystems.
txincludes=     # TEXINPUTS extensions, with trailing colon
txincludes=     # TEXINPUTS extensions, with trailing colon
txiprereq=19990129 # minimum texinfo.tex version to have macro expansion
txiprereq=19990129 # minimum texinfo.tex version to have macro expansion
verbose=false   # echo for verbose mode
verbose=false   # echo for verbose mode
orig_pwd=`pwd`
orig_pwd=`pwd`
# Systems which define $COMSPEC or $ComSpec use semicolons to separate
# Systems which define $COMSPEC or $ComSpec use semicolons to separate
# directories in TEXINPUTS.
# directories in TEXINPUTS.
if test -n "$COMSPEC$ComSpec"; then
if test -n "$COMSPEC$ComSpec"; then
  path_sep=";"
  path_sep=";"
else
else
  path_sep=":"
  path_sep=":"
fi
fi
# Pacify verbose cds.
# Pacify verbose cds.
CDPATH=${ZSH_VERSION+.}$path_sep
CDPATH=${ZSH_VERSION+.}$path_sep
# In case someone crazy insists on using grep -E.
# In case someone crazy insists on using grep -E.
: ${EGREP=egrep}
: ${EGREP=egrep}
# Save this so we can construct a new TEXINPUTS path for each file.
# Save this so we can construct a new TEXINPUTS path for each file.
TEXINPUTS_orig="$TEXINPUTS"
TEXINPUTS_orig="$TEXINPUTS"
# Unfortunately makeindex does not read TEXINPUTS.
# Unfortunately makeindex does not read TEXINPUTS.
INDEXSTYLE_orig="$INDEXSTYLE"
INDEXSTYLE_orig="$INDEXSTYLE"
export TEXINPUTS INDEXSTYLE
export TEXINPUTS INDEXSTYLE
# Push a token among the arguments that will be used to notice when we
# Push a token among the arguments that will be used to notice when we
# ended options/arguments parsing.
# ended options/arguments parsing.
# Use "set dummy ...; shift" rather than 'set - ..." because on
# Use "set dummy ...; shift" rather than 'set - ..." because on
# Solaris set - turns off set -x (but keeps set -e).
# Solaris set - turns off set -x (but keeps set -e).
# Use ${1+"$@"} rather than "$@" because Digital Unix and Ultrix 4.3
# Use ${1+"$@"} rather than "$@" because Digital Unix and Ultrix 4.3
# still expand "$@" to a single argument (the empty string) rather
# still expand "$@" to a single argument (the empty string) rather
# than nothing at all.
# than nothing at all.
arg_sep="$$--$$"
arg_sep="$$--$$"
set dummy ${1+"$@"} "$arg_sep"; shift
set dummy ${1+"$@"} "$arg_sep"; shift
# 
# 
# Parse command line arguments.
# Parse command line arguments.
while test x"$1" != x"$arg_sep"; do
while test x"$1" != x"$arg_sep"; do
  # Handle --option=value by splitting apart and putting back on argv.
  # Handle --option=value by splitting apart and putting back on argv.
  case "$1" in
  case "$1" in
    --*=*)
    --*=*)
      opt=`echo "$1" | sed -e 's/=.*//'`
      opt=`echo "$1" | sed -e 's/=.*//'`
      val=`echo "$1" | sed -e 's/[^=]*=//'`
      val=`echo "$1" | sed -e 's/[^=]*=//'`
      shift
      shift
      set dummy "$opt" "$val" ${1+"$@"}; shift
      set dummy "$opt" "$val" ${1+"$@"}; shift
      ;;
      ;;
  esac
  esac
  # This recognizes --quark as --quiet.  So what.
  # This recognizes --quark as --quiet.  So what.
  case "$1" in
  case "$1" in
    -@ ) escape=@;;
    -@ ) escape=@;;
    # Silently and without documentation accept -b and --b[atch] as synonyms.
    # Silently and without documentation accept -b and --b[atch] as synonyms.
    -b | --b*) batch=eval;;
    -b | --b*) batch=eval;;
    -q | -s | --q* | --s*) quiet=t; batch=eval;;
    -q | -s | --q* | --s*) quiet=t; batch=eval;;
    -c | --c*) clean=t;;
    -c | --c*) clean=t;;
    -D | --d*) debug=t;;
    -D | --d*) debug=t;;
    -e | -E | --e*) expand=t;;
    -e | -E | --e*) expand=t;;
    -h | --h*) echo "$usage"; exit 0;;
    -h | --h*) echo "$usage"; exit 0;;
    -I | --I*)
    -I | --I*)
      shift
      shift
      miincludes="$miincludes -I $1"
      miincludes="$miincludes -I $1"
      txincludes="$txincludes$1$path_sep"
      txincludes="$txincludes$1$path_sep"
      ;;
      ;;
    -l | --l*) shift; set_language=$1;;
    -l | --l*) shift; set_language=$1;;
    -o | --o*)
    -o | --o*)
      shift
      shift
      clean=t
      clean=t
      case "$1" in
      case "$1" in
        /* | ?:/*) oname=$1;;
        /* | ?:/*) oname=$1;;
                *) oname="$orig_pwd/$1";;
                *) oname="$orig_pwd/$1";;
      esac;;
      esac;;
    -p | --p*) oformat=pdf;;
    -p | --p*) oformat=pdf;;
    -t | --t*) shift; textra="$textra\\
    -t | --t*) shift; textra="$textra\\
$1";;
$1";;
    -v | --vers*) echo "$version"; exit 0;;
    -v | --vers*) echo "$version"; exit 0;;
    -V | --verb*) verbose=echo;;
    -V | --verb*) verbose=echo;;
    --) # What remains are not options.
    --) # What remains are not options.
      shift
      shift
      while test x"$1" != x"$arg_sep"; do
      while test x"$1" != x"$arg_sep"; do
        set dummy ${1+"$@"} "$1"; shift
        set dummy ${1+"$@"} "$1"; shift
        shift
        shift
      done
      done
      break;;
      break;;
    -*)
    -*)
      echo "$0: Unknown or ambiguous option \`$1'." >&2
      echo "$0: Unknown or ambiguous option \`$1'." >&2
      echo "$0: Try \`--help' for more information." >&2
      echo "$0: Try \`--help' for more information." >&2
      exit 1;;
      exit 1;;
    *) set dummy ${1+"$@"} "$1"; shift;;
    *) set dummy ${1+"$@"} "$1"; shift;;
   esac
   esac
   shift
   shift
done
done
# Pop the token
# Pop the token
shift
shift
# Interpret remaining command line args as filenames.
# Interpret remaining command line args as filenames.
case $# in
case $# in
 0)
 0)
  echo "$0: Missing file arguments." >&2
  echo "$0: Missing file arguments." >&2
  echo "$0: Try \`--help' for more information." >&2
  echo "$0: Try \`--help' for more information." >&2
  exit 2
  exit 2
  ;;
  ;;
 1) ;;
 1) ;;
 *)
 *)
  if test -n "$oname"; then
  if test -n "$oname"; then
    echo "$0: Can't use option \`--output' with more than one argument." >&2
    echo "$0: Can't use option \`--output' with more than one argument." >&2
    exit 2
    exit 2
  fi
  fi
  ;;
  ;;
esac
esac
# Prepare the temporary directory.  Remove it at exit, unless debugging.
# Prepare the temporary directory.  Remove it at exit, unless debugging.
if test -z "$debug"; then
if test -z "$debug"; then
  trap "cd / && rm -rf $tmpdir" 0 1 2 15
  trap "cd / && rm -rf $tmpdir" 0 1 2 15
fi
fi
# Create the temporary directory with strict rights
# Create the temporary directory with strict rights
(umask 077 && mkdir $tmpdir) || exit 1
(umask 077 && mkdir $tmpdir) || exit 1
# Prepare the tools we might need.  This may be extra work in some
# Prepare the tools we might need.  This may be extra work in some
# cases, but improves the readibility of the script.
# cases, but improves the readibility of the script.
utildir=$tmpdir/utils
utildir=$tmpdir/utils
mkdir $utildir || exit 1
mkdir $utildir || exit 1
# A sed script that preprocesses Texinfo sources in order to keep the
# A sed script that preprocesses Texinfo sources in order to keep the
# iftex sections only.  We want to remove non TeX sections, and
# iftex sections only.  We want to remove non TeX sections, and
# comment (with `@c texi2dvi') TeX sections so that makeinfo does not
# comment (with `@c texi2dvi') TeX sections so that makeinfo does not
# try to parse them.  Nevertheless, while commenting TeX sections,
# try to parse them.  Nevertheless, while commenting TeX sections,
# don't comment @macro/@end macro so that makeinfo does propagate
# don't comment @macro/@end macro so that makeinfo does propagate
# them.  Unfortunately makeinfo --iftex --no-ifhtml --no-ifinfo
# them.  Unfortunately makeinfo --iftex --no-ifhtml --no-ifinfo
# doesn't work well enough (yet) to use that, so work around with sed.
# doesn't work well enough (yet) to use that, so work around with sed.
comment_iftex_sed=$utildir/comment.sed
comment_iftex_sed=$utildir/comment.sed
cat <$comment_iftex_sed
cat <$comment_iftex_sed
/^@tex/,/^@end tex/{
/^@tex/,/^@end tex/{
  s/^/@c texi2dvi/
  s/^/@c texi2dvi/
}
}
/^@iftex/,/^@end iftex/{
/^@iftex/,/^@end iftex/{
  s/^/@c texi2dvi/
  s/^/@c texi2dvi/
  /^@c texi2dvi@macro/,/^@c texi2dvi@end macro/{
  /^@c texi2dvi@macro/,/^@c texi2dvi@end macro/{
    s/^@c texi2dvi//
    s/^@c texi2dvi//
  }
  }
}
}
/^@html/,/^@end html/{
/^@html/,/^@end html/{
  s/^/@c (texi2dvi)/
  s/^/@c (texi2dvi)/
}
}
/^@ifhtml/,/^@end ifhtml/{
/^@ifhtml/,/^@end ifhtml/{
  s/^/@c (texi2dvi)/
  s/^/@c (texi2dvi)/
}
}
/^@ifnottex/,/^@end ifnottex/{
/^@ifnottex/,/^@end ifnottex/{
  s/^/@c (texi2dvi)/
  s/^/@c (texi2dvi)/
}
}
/^@ifinfo/,/^@end ifinfo/{
/^@ifinfo/,/^@end ifinfo/{
  /^@node/p
  /^@node/p
  /^@menu/,/^@end menu/p
  /^@menu/,/^@end menu/p
  t
  t
  s/^/@c (texi2dvi)/
  s/^/@c (texi2dvi)/
}
}
s/^@ifnotinfo/@c texi2dvi@ifnotinfo/
s/^@ifnotinfo/@c texi2dvi@ifnotinfo/
s/^@end ifnotinfo/@c texi2dvi@end ifnotinfo/
s/^@end ifnotinfo/@c texi2dvi@end ifnotinfo/
EOF
EOF
# Uncommenting is simple: Remove any leading `@c texi2dvi'.
# Uncommenting is simple: Remove any leading `@c texi2dvi'.
uncomment_iftex_sed=$utildir/uncomment.sed
uncomment_iftex_sed=$utildir/uncomment.sed
cat <$uncomment_iftex_sed
cat <$uncomment_iftex_sed
s/^@c texi2dvi//
s/^@c texi2dvi//
EOF
EOF
# A shell script that computes the list of xref files.
# A shell script that computes the list of xref files.
# Takes the filename (without extension) of which we look for xref
# Takes the filename (without extension) of which we look for xref
# files as argument.  The index files must be reported last.
# files as argument.  The index files must be reported last.
get_xref_files=$utildir/get_xref.sh
get_xref_files=$utildir/get_xref.sh
cat <<\EOF >$get_xref_files
cat <<\EOF >$get_xref_files
#! /bin/sh
#! /bin/sh
# Get list of xref files (indexes, tables and lists).
# Get list of xref files (indexes, tables and lists).
# Find all files having root filename with a two-letter extension,
# Find all files having root filename with a two-letter extension,
# saves the ones that are really Texinfo-related files.  .?o? catches
# saves the ones that are really Texinfo-related files.  .?o? catches
# many files: .toc, .log, LaTeX tables and lists, FiXme's .lox, maybe more.
# many files: .toc, .log, LaTeX tables and lists, FiXme's .lox, maybe more.
for this_file in "$1".?o? "$1".aux "$1".?? "$1".idx; do
for this_file in "$1".?o? "$1".aux "$1".?? "$1".idx; do
  # If file is empty, skip it.
  # If file is empty, skip it.
  test -s "$this_file" || continue
  test -s "$this_file" || continue
  # If the file is not suitable to be an index or xref file, don't
  # If the file is not suitable to be an index or xref file, don't
  # process it.  The file can't be if its first character is not a
  # process it.  The file can't be if its first character is not a
  # backslash or single quote.
  # backslash or single quote.
  first_character=`sed -n '1s/^\(.\).*$/\1/p;q' $this_file`
  first_character=`sed -n '1s/^\(.\).*$/\1/p;q' $this_file`
  if test "x$first_character" = "x\\" \
  if test "x$first_character" = "x\\" \
     || test "x$first_character" = "x'"; then
     || test "x$first_character" = "x'"; then
    xref_files="$xref_files ./$this_file"
    xref_files="$xref_files ./$this_file"
  fi
  fi
done
done
echo "$xref_files"
echo "$xref_files"
EOF
EOF
chmod 500 $get_xref_files
chmod 500 $get_xref_files
# File descriptor usage:
# File descriptor usage:
# 0 standard input
# 0 standard input
# 1 standard output (--verbose messages)
# 1 standard output (--verbose messages)
# 2 standard error
# 2 standard error
# 3 some systems may open it to /dev/tty
# 3 some systems may open it to /dev/tty
# 4 used on the Kubota Titan
# 4 used on the Kubota Titan
# 5 tools output (turned off by --quiet)
# 5 tools output (turned off by --quiet)
# Tools' output.  If quiet, discard, else redirect to the message flow.
# Tools' output.  If quiet, discard, else redirect to the message flow.
if test "$quiet" = t; then
if test "$quiet" = t; then
  exec 5>/dev/null
  exec 5>/dev/null
else
else
  exec 5>&1
  exec 5>&1
fi
fi
# Enable tracing
# Enable tracing
test "$debug" = t && set -x
test "$debug" = t && set -x
# 
# 
# TeXify files.
# TeXify files.
for command_line_filename in ${1+"$@"}; do
for command_line_filename in ${1+"$@"}; do
  $verbose "Processing $command_line_filename ..."
  $verbose "Processing $command_line_filename ..."
  # If the COMMAND_LINE_FILENAME is not absolute (e.g., --debug.tex),
  # If the COMMAND_LINE_FILENAME is not absolute (e.g., --debug.tex),
  # prepend `./' in order to avoid that the tools take it as an option.
  # prepend `./' in order to avoid that the tools take it as an option.
  echo "$command_line_filename" | $EGREP '^(/|[A-z]:/)' >/dev/null \
  echo "$command_line_filename" | $EGREP '^(/|[A-z]:/)' >/dev/null \
  || command_line_filename="./$command_line_filename"
  || command_line_filename="./$command_line_filename"
  # See if the file exists.  If it doesn't we're in trouble since, even
  # See if the file exists.  If it doesn't we're in trouble since, even
  # though the user may be able to reenter a valid filename at the tex
  # though the user may be able to reenter a valid filename at the tex
  # prompt (assuming they're attending the terminal), this script won't
  # prompt (assuming they're attending the terminal), this script won't
  # be able to find the right xref files and so forth.
  # be able to find the right xref files and so forth.
  if test ! -r "$command_line_filename"; then
  if test ! -r "$command_line_filename"; then
    echo "$0: Could not read $command_line_filename, skipping." >&2
    echo "$0: Could not read $command_line_filename, skipping." >&2
    continue
    continue
  fi
  fi
  # Get the name of the current directory.  We want the full path
  # Get the name of the current directory.  We want the full path
  # because in clean mode we are in tmp, in which case a relative
  # because in clean mode we are in tmp, in which case a relative
  # path has no meaning.
  # path has no meaning.
  filename_dir=`echo $command_line_filename | sed 's!/[^/]*$!!;s!^$!.!'`
  filename_dir=`echo $command_line_filename | sed 's!/[^/]*$!!;s!^$!.!'`
  filename_dir=`cd "$filename_dir" >/dev/null && pwd`
  filename_dir=`cd "$filename_dir" >/dev/null && pwd`
  # Strip directory part but leave extension.
  # Strip directory part but leave extension.
  filename_ext=`basename "$command_line_filename"`
  filename_ext=`basename "$command_line_filename"`
  # Strip extension.
  # Strip extension.
  filename_noext=`echo "$filename_ext" | sed 's/\.[^.]*$//'`
  filename_noext=`echo "$filename_ext" | sed 's/\.[^.]*$//'`
  ext=`echo "$filename_ext" | sed 's/^.*\.//'`
  ext=`echo "$filename_ext" | sed 's/^.*\.//'`
  # _src.  Use same basename since we want to generate aux files with
  # _src.  Use same basename since we want to generate aux files with
  # the same basename as the manual.  If --expand, then output the
  # the same basename as the manual.  If --expand, then output the
  # macro-expanded file to here, else copy the original file.
  # macro-expanded file to here, else copy the original file.
  tmpdir_src=$tmpdir/src
  tmpdir_src=$tmpdir/src
  filename_src=$tmpdir_src/$filename_noext.$ext
  filename_src=$tmpdir_src/$filename_noext.$ext
  # _xtr.  The file with the user's extra commands.
  # _xtr.  The file with the user's extra commands.
  tmpdir_xtr=$tmpdir/xtr
  tmpdir_xtr=$tmpdir/xtr
  filename_xtr=$tmpdir_xtr/$filename_noext.$ext
  filename_xtr=$tmpdir_xtr/$filename_noext.$ext
  # _bak.  Copies of the previous xref files (another round is run if
  # _bak.  Copies of the previous xref files (another round is run if
  # they differ from the new one).
  # they differ from the new one).
  tmpdir_bak=$tmpdir/bak
  tmpdir_bak=$tmpdir/bak
  # Make all those directories and give up if we can't succeed.
  # Make all those directories and give up if we can't succeed.
  mkdir $tmpdir_src $tmpdir_xtr $tmpdir_bak || exit 1
  mkdir $tmpdir_src $tmpdir_xtr $tmpdir_bak || exit 1
  # Source file might include additional sources.
  # Source file might include additional sources.
  # We want `.:$orig_pwd' before anything else.  (We'll add `.:' later
  # We want `.:$orig_pwd' before anything else.  (We'll add `.:' later
  # after all other directories have been turned into absolute paths.)
  # after all other directories have been turned into absolute paths.)
  # `.' goes first to ensure that any old .aux, .cps,
  # `.' goes first to ensure that any old .aux, .cps,
  # etc. files in ${directory} don't get used in preference to fresher
  # etc. files in ${directory} don't get used in preference to fresher
  # files in `.'.  Include orig_pwd in case we are in clean mode, where
  # files in `.'.  Include orig_pwd in case we are in clean mode, where
  # we've cd'd to a temp directory.
  # we've cd'd to a temp directory.
  common="$orig_pwd$path_sep$filename_dir$path_sep$txincludes"
  common="$orig_pwd$path_sep$filename_dir$path_sep$txincludes"
   TEXINPUTS="$common$TEXINPUTS_orig"
   TEXINPUTS="$common$TEXINPUTS_orig"
  INDEXSTYLE="$common$INDEXSTYLE_orig"
  INDEXSTYLE="$common$INDEXSTYLE_orig"
  # Convert relative paths to absolute paths, so we can run in another
  # Convert relative paths to absolute paths, so we can run in another
  # directory (e.g., in --clean mode, or during the macro-support
  # directory (e.g., in --clean mode, or during the macro-support
  # detection.)
  # detection.)
  #
  #
  # Empty path components are meaningful to tex.  We rewrite them
  # Empty path components are meaningful to tex.  We rewrite them
  # as `EMPTY' so they don't get lost when we split on $path_sep.
  # as `EMPTY' so they don't get lost when we split on $path_sep.
   TEXINPUTS=`echo $TEXINPUTS  |sed 's/^:/EMPTY:/;s/:$/:EMPTY/;s/::/:EMPTY:/g'`
   TEXINPUTS=`echo $TEXINPUTS  |sed 's/^:/EMPTY:/;s/:$/:EMPTY/;s/::/:EMPTY:/g'`
  INDEXSTYLE=`echo $INDEXSTYLE |sed 's/^:/EMPTY:/;s/:$/:EMPTY/;s/::/:EMPTY:/g'`
  INDEXSTYLE=`echo $INDEXSTYLE |sed 's/^:/EMPTY:/;s/:$/:EMPTY/;s/::/:EMPTY:/g'`
  save_IFS=$IFS
  save_IFS=$IFS
  IFS=$path_sep
  IFS=$path_sep
  set x $TEXINPUTS; shift
  set x $TEXINPUTS; shift
  TEXINPUTS=.
  TEXINPUTS=.
  for dir
  for dir
  do
  do
    case $dir in
    case $dir in
      EMPTY)
      EMPTY)
        TEXINPUTS=$TEXINPUTS$path_sep
        TEXINPUTS=$TEXINPUTS$path_sep
        ;;
        ;;
      [\\/]* | ?:[\\/]*)        # Absolute paths don't need to be expansed.
      [\\/]* | ?:[\\/]*)        # Absolute paths don't need to be expansed.
        TEXINPUTS=$TEXINPUTS$path_sep$dir
        TEXINPUTS=$TEXINPUTS$path_sep$dir
        ;;
        ;;
      *)
      *)
        abs=`cd "$dir" && pwd` && TEXINPUTS=$TEXINPUTS$path_sep$abs
        abs=`cd "$dir" && pwd` && TEXINPUTS=$TEXINPUTS$path_sep$abs
        ;;
        ;;
    esac
    esac
  done
  done
  set x $INDEXSTYLE; shift
  set x $INDEXSTYLE; shift
  INDEXSTYLE=.
  INDEXSTYLE=.
  for dir
  for dir
  do
  do
    case $dir in
    case $dir in
      EMPTY)
      EMPTY)
        INDEXSTYLE=$INDEXSTYLE$path_sep
        INDEXSTYLE=$INDEXSTYLE$path_sep
        ;;
        ;;
      [\\/]* | ?:[\\/]*)        # Absolute paths don't need to be expansed.
      [\\/]* | ?:[\\/]*)        # Absolute paths don't need to be expansed.
        INDEXSTYLE=$INDEXSTYLE$path_sep$dir
        INDEXSTYLE=$INDEXSTYLE$path_sep$dir
        ;;
        ;;
      *)
      *)
        abs=`cd "$dir" && pwd` && INDEXSTYLE=$INDEXSTYLE$path_sep$abs
        abs=`cd "$dir" && pwd` && INDEXSTYLE=$INDEXSTYLE$path_sep$abs
        ;;
        ;;
    esac
    esac
  done
  done
  IFS=$save_IFS
  IFS=$save_IFS
  # If the user explicitly specified the language, use that.
  # If the user explicitly specified the language, use that.
  # Otherwise, if the first line is \input texinfo, assume it's texinfo.
  # Otherwise, if the first line is \input texinfo, assume it's texinfo.
  # Otherwise, guess from the file extension.
  # Otherwise, guess from the file extension.
  if test -n "$set_language"; then
  if test -n "$set_language"; then
    language=$set_language
    language=$set_language
  elif sed 1q "$command_line_filename" | grep 'input texinfo' >/dev/null; then
  elif sed 1q "$command_line_filename" | grep 'input texinfo' >/dev/null; then
    language=texinfo
    language=texinfo
  else
  else
    language=
    language=
  fi
  fi
  # Get the type of the file (latex or texinfo) from the given language
  # 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.
  # we just guessed, or from the file extension if not set yet.
  case ${language:-$filename_ext} in
  case ${language:-$filename_ext} in
    [lL]a[tT]e[xX] | *.ltx | *.tex)
    [lL]a[tT]e[xX] | *.ltx | *.tex)
      # Assume a LaTeX file.  LaTeX needs bibtex and uses latex for
      # Assume a LaTeX file.  LaTeX needs bibtex and uses latex for
      # compilation.  No makeinfo.
      # compilation.  No makeinfo.
      bibtex=${BIBTEX:-bibtex}
      bibtex=${BIBTEX:-bibtex}
      makeinfo= # no point in running makeinfo on latex source.
      makeinfo= # no point in running makeinfo on latex source.
      texindex=${MAKEINDEX:-makeindex}
      texindex=${MAKEINDEX:-makeindex}
      if test $oformat = dvi; then
      if test $oformat = dvi; then
        tex=${LATEX:-latex}
        tex=${LATEX:-latex}
      else
      else
        tex=${PDFLATEX:-pdflatex}
        tex=${PDFLATEX:-pdflatex}
      fi
      fi
      ;;
      ;;
    *)
    *)
      # Assume a Texinfo file.  Texinfo files need makeinfo, texindex and tex.
      # Assume a Texinfo file.  Texinfo files need makeinfo, texindex and tex.
      bibtex=
      bibtex=
      texindex=${TEXINDEX:-texindex}
      texindex=${TEXINDEX:-texindex}
      if test $oformat = dvi; then
      if test $oformat = dvi; then
        tex=${TEX:-tex}
        tex=${TEX:-tex}
      else
      else
        tex=${PDFTEX:-pdftex}
        tex=${PDFTEX:-pdftex}
      fi
      fi
      # Unless required by the user, makeinfo expansion is wanted only
      # Unless required by the user, makeinfo expansion is wanted only
      # if texinfo.tex is too old.
      # if texinfo.tex is too old.
      if test "$expand" = t; then
      if test "$expand" = t; then
        makeinfo=${MAKEINFO:-makeinfo}
        makeinfo=${MAKEINFO:-makeinfo}
      else
      else
        # Check if texinfo.tex performs macro expansion by looking for
        # Check if texinfo.tex performs macro expansion by looking for
        # its version.  The version is a date of the form YEAR-MO-DA.
        # its version.  The version is a date of the form YEAR-MO-DA.
        # We don't need to use [0-9] to match the digits since anyway
        # We don't need to use [0-9] to match the digits since anyway
        # the comparison with $txiprereq, a number, will fail with non
        # the comparison with $txiprereq, a number, will fail with non
        # digits.
        # digits.
        txiversion_tex=txiversion.tex
        txiversion_tex=txiversion.tex
        echo '\input texinfo.tex @bye' >$tmpdir/$txiversion_tex
        echo '\input texinfo.tex @bye' >$tmpdir/$txiversion_tex
        # Run in the tmpdir to avoid leaving files.
        # Run in the tmpdir to avoid leaving files.
        eval `cd $tmpdir >/dev/null &&
        eval `cd $tmpdir >/dev/null &&
              $tex $txiversion_tex 2>/dev/null |
              $tex $txiversion_tex 2>/dev/null |
              sed -n 's/^.*\[\(.*\)version \(....\)-\(..\)-\(..\).*$/txiformat=\1 txiversion="\2\3\4"/p'`
              sed -n 's/^.*\[\(.*\)version \(....\)-\(..\)-\(..\).*$/txiformat=\1 txiversion="\2\3\4"/p'`
        $verbose "texinfo.tex preloaded as \`$txiformat', version is \`$txiversion' ..."
        $verbose "texinfo.tex preloaded as \`$txiformat', version is \`$txiversion' ..."
        if test "$txiprereq" -le "$txiversion" >/dev/null 2>&1; then
        if test "$txiprereq" -le "$txiversion" >/dev/null 2>&1; then
          makeinfo=
          makeinfo=
        else
        else
          makeinfo=${MAKEINFO:-makeinfo}
          makeinfo=${MAKEINFO:-makeinfo}
        fi
        fi
        # As long as we had to run TeX, offer the user this convenience
        # As long as we had to run TeX, offer the user this convenience
        if test "$txiformat" = Texinfo; then
        if test "$txiformat" = Texinfo; then
          escape=@
          escape=@
        fi
        fi
      fi
      fi
      ;;
      ;;
  esac
  esac
  # Expand macro commands in the original source file using Makeinfo.
  # Expand macro commands in the original source file using Makeinfo.
  # Always use `end' footnote style, since the `separate' style
  # Always use `end' footnote style, since the `separate' style
  #   generates different output (arguably this is a bug in -E).
  #   generates different output (arguably this is a bug in -E).
  # Discard main info output, the user asked to run TeX, not makeinfo.
  # Discard main info output, the user asked to run TeX, not makeinfo.
  if test -n "$makeinfo"; then
  if test -n "$makeinfo"; then
    $verbose "Macro-expanding $command_line_filename to $filename_src ..."
    $verbose "Macro-expanding $command_line_filename to $filename_src ..."
    sed -f $comment_iftex_sed "$command_line_filename" \
    sed -f $comment_iftex_sed "$command_line_filename" \
      | $makeinfo --footnote-style=end -I "$filename_dir" $miincludes \
      | $makeinfo --footnote-style=end -I "$filename_dir" $miincludes \
        -o /dev/null --macro-expand=- \
        -o /dev/null --macro-expand=- \
      | sed -f $uncomment_iftex_sed >"$filename_src"
      | sed -f $uncomment_iftex_sed >"$filename_src"
    filename_input=$filename_src
    filename_input=$filename_src
  fi
  fi
  # If makeinfo failed (or was not even run), use the original file as input.
  # If makeinfo failed (or was not even run), use the original file as input.
  if test $? -ne 0 \
  if test $? -ne 0 \
     || test ! -r "$filename_src"; then
     || test ! -r "$filename_src"; then
    $verbose "Reverting to $command_line_filename ..."
    $verbose "Reverting to $command_line_filename ..."
    filename_input=$filename_dir/$filename_ext
    filename_input=$filename_dir/$filename_ext
  fi
  fi
  # Used most commonly for @finalout, @smallbook, etc.
  # Used most commonly for @finalout, @smallbook, etc.
  if test -n "$textra"; then
  if test -n "$textra"; then
    $verbose "Inserting extra commands: $textra"
    $verbose "Inserting extra commands: $textra"
    sed '/^@setfilename/a\
    sed '/^@setfilename/a\
'"$textra" "$filename_input" >$filename_xtr
'"$textra" "$filename_input" >$filename_xtr
    filename_input=$filename_xtr
    filename_input=$filename_xtr
  fi
  fi
  # If clean mode was specified, then move to the temporary directory.
  # If clean mode was specified, then move to the temporary directory.
  if test "$clean" = t; then
  if test "$clean" = t; then
    $verbose "cd $tmpdir_src"
    $verbose "cd $tmpdir_src"
    cd "$tmpdir_src" || exit 1
    cd "$tmpdir_src" || exit 1
  fi
  fi
  while :; do # will break out of loop below
  while :; do # will break out of loop below
    orig_xref_files=`$get_xref_files "$filename_noext"`
    orig_xref_files=`$get_xref_files "$filename_noext"`
    # Save copies of originals for later comparison.
    # Save copies of originals for later comparison.
    if test -n "$orig_xref_files"; then
    if test -n "$orig_xref_files"; then
      $verbose "Backing up xref files: `echo $orig_xref_files | sed 's|\./||g'`"
      $verbose "Backing up xref files: `echo $orig_xref_files | sed 's|\./||g'`"
      cp $orig_xref_files $tmpdir_bak
      cp $orig_xref_files $tmpdir_bak
    fi
    fi
    # Run bibtex on current file.
    # Run bibtex on current file.
    # - If its input (AUX) exists.
    # - If its input (AUX) exists.
    # - If AUX contains both `\bibdata' and `\bibstyle'.
    # - If AUX contains both `\bibdata' and `\bibstyle'.
    # - If some citations are missing (LOG contains `Citation').
    # - If some citations are missing (LOG contains `Citation').
    #   or the LOG complains of a missing .bbl
    #   or the LOG complains of a missing .bbl
    #
    #
    # We run bibtex first, because I can see reasons for the indexes
    # 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
    # to change after bibtex is run, but I see no reason for the
    # converse.
    # converse.
    #
    #
    # Don't try to be too smart.  Running bibtex only if the bbl file
    # Don't try to be too smart.  Running bibtex only if the bbl file
    # exists and is older than the LaTeX file is wrong, since the
    # exists and is older than the LaTeX file is wrong, since the
    # document might include files that have changed.  Because there
    # document might include files that have changed.  Because there
    # can be several AUX (if there are \include's), but a single LOG,
    # can be several AUX (if there are \include's), but a single LOG,
    # looking for missing citations in LOG is easier, though we take
    # looking for missing citations in LOG is easier, though we take
    # the risk to match false messages.
    # the risk to match false messages.
    if test -n "$bibtex" \
    if test -n "$bibtex" \
       && test -r "$filename_noext.aux" \
       && test -r "$filename_noext.aux" \
       && test -r "$filename_noext.log" \
       && test -r "$filename_noext.log" \
       && (grep '^\\bibdata[{]'  "$filename_noext.aux" \
       && (grep '^\\bibdata[{]'  "$filename_noext.aux" \
           && grep '^\\bibstyle[{]' "$filename_noext.aux" \
           && grep '^\\bibstyle[{]' "$filename_noext.aux" \
           && (grep 'Warning:.*Citation.*undefined' "$filename_noext.log" \
           && (grep 'Warning:.*Citation.*undefined' "$filename_noext.log" \
               || grep 'No file .*\.bbl\.' "$filename_noext.log")) \
               || grep 'No file .*\.bbl\.' "$filename_noext.log")) \
          >/dev/null 2>&1; \
          >/dev/null 2>&1; \
    then
    then
      $verbose "Running $bibtex $filename_noext ..."
      $verbose "Running $bibtex $filename_noext ..."
      if $bibtex "$filename_noext" >&5; then :; else
      if $bibtex "$filename_noext" >&5; then :; else
        echo "$0: $bibtex exited with bad status, quitting." >&2
        echo "$0: $bibtex exited with bad status, quitting." >&2
        exit 1
        exit 1
      fi
      fi
    fi
    fi
    # What we'll run texindex on -- exclude non-index files.
    # What we'll run texindex on -- exclude non-index files.
    # Since we know index files are last, it is correct to remove everything
    # Since we know index files are last, it is correct to remove everything
    # before .aux and .?o?.  But don't really do o
    # before .aux and .?o?.  But don't really do o
    # -- don't match whitespace as .
    # -- don't match whitespace as .
    # Otherwise, if orig_xref_files contains something like
    # Otherwise, if orig_xref_files contains something like
    #   foo.xo foo.whatever
    #   foo.xo foo.whatever
    # the space after the o will get matched.
    # the space after the o will get matched.
    index_files=`echo "$orig_xref_files" \
    index_files=`echo "$orig_xref_files" \
                 | sed "s!.*\.aux!!g;
                 | sed "s!.*\.aux!!g;
                        s!./$filename_noext\.[^ ]o[^ ]!!g;
                        s!./$filename_noext\.[^ ]o[^ ]!!g;
                        s/^[ ]*//;s/[ ]*$//"`
                        s/^[ ]*//;s/[ ]*$//"`
    # Run texindex (or makeindex) on current index files.  If they
    # Run texindex (or makeindex) on current index files.  If they
    # already exist, and after running TeX a first time the index
    # already exist, and after running TeX a first time the index
    # files don't change, then there's no reason to run TeX again.
    # files don't change, then there's no reason to run TeX again.
    # But we won't know that if the index files are out of date or
    # But we won't know that if the index files are out of date or
    # nonexistent.
    # nonexistent.
    if test -n "$texindex" && test -n "$index_files"; then
    if test -n "$texindex" && test -n "$index_files"; then
      $verbose "Running $texindex $index_files ..."
      $verbose "Running $texindex $index_files ..."
      if $texindex $index_files 2>&5 1>&2; then :; else
      if $texindex $index_files 2>&5 1>&2; then :; else
         echo "$0: $texindex exited with bad status, quitting." >&2
         echo "$0: $texindex exited with bad status, quitting." >&2
         exit 1
         exit 1
      fi
      fi
    fi
    fi
    # Finally, run TeX.
    # Finally, run TeX.
    # Prevent $ESCAPE from being interpreted by the shell if it happens
    # Prevent $ESCAPE from being interpreted by the shell if it happens
    # to be `/'.
    # to be `/'.
    $batch tex_args="\\${escape}nonstopmode\ \\${escape}input"
    $batch tex_args="\\${escape}nonstopmode\ \\${escape}input"
    cmd="$tex $tex_args $filename_input"
    cmd="$tex $tex_args $filename_input"
    $verbose "Running $cmd ..."
    $verbose "Running $cmd ..."
    if $cmd >&5; then :; else
    if $cmd >&5; then :; else
      echo "$0: $tex exited with bad status, quitting." >&2
      echo "$0: $tex exited with bad status, quitting." >&2
      echo "$0: see $filename_noext.log for errors." >&2
      echo "$0: see $filename_noext.log for errors." >&2
      test "$clean" = t \
      test "$clean" = t \
        && cp "$filename_noext.log" "$orig_pwd"
        && cp "$filename_noext.log" "$orig_pwd"
      exit 1
      exit 1
    fi
    fi
    # Decide if looping again is needed.
    # Decide if looping again is needed.
    finished=t
    finished=t
    # LaTeX (and the package changebar) report in the LOG file if it
    # LaTeX (and the package changebar) report in the LOG file if it
    # should be rerun.  This is needed for files included from
    # should be rerun.  This is needed for files included from
    # subdirs, since texi2dvi does not try to compare xref files in
    # subdirs, since texi2dvi does not try to compare xref files in
    # subdirs.  Performing xref files test is still good since LaTeX
    # subdirs.  Performing xref files test is still good since LaTeX
    # does not report changes in xref files.
    # does not report changes in xref files.
    if grep "Rerun to get" "$filename_noext.log" >/dev/null 2>&1; then
    if grep "Rerun to get" "$filename_noext.log" >/dev/null 2>&1; then
      finished=
      finished=
    fi
    fi
    # Check if xref files changed.
    # Check if xref files changed.
    new_xref_files=`$get_xref_files "$filename_noext"`
    new_xref_files=`$get_xref_files "$filename_noext"`
    $verbose "Original xref files = `echo $orig_xref_files | sed 's|\./||g'`"
    $verbose "Original xref files = `echo $orig_xref_files | sed 's|\./||g'`"
    $verbose "New xref files      = `echo $new_xref_files | sed 's|\./||g'`"
    $verbose "New xref files      = `echo $new_xref_files | sed 's|\./||g'`"
    # If old and new lists don't at least have the same file list,
    # If old and new lists don't at least have the same file list,
    # then one file or another has definitely changed.
    # then one file or another has definitely changed.
    test "x$orig_xref_files" != "x$new_xref_files" && finished=
    test "x$orig_xref_files" != "x$new_xref_files" && finished=
    # File list is the same.  We must compare each file until we find
    # File list is the same.  We must compare each file until we find
    # a difference.
    # a difference.
    if test -n "$finished"; then
    if test -n "$finished"; then
      for this_file in $new_xref_files; do
      for this_file in $new_xref_files; do
        $verbose "Comparing xref file `echo $this_file | sed 's|\./||g'` ..."
        $verbose "Comparing xref file `echo $this_file | sed 's|\./||g'` ..."
        # cmp -s returns nonzero exit status if files differ.
        # cmp -s returns nonzero exit status if files differ.
        if cmp -s "$this_file" "$tmpdir_bak/$this_file"; then :; else
        if cmp -s "$this_file" "$tmpdir_bak/$this_file"; then :; else
          # We only need to keep comparing until we find one that
          # We only need to keep comparing until we find one that
          # differs, because we'll have to run texindex & tex again no
          # differs, because we'll have to run texindex & tex again no
          # matter how many more there might be.
          # matter how many more there might be.
          finished=
          finished=
          $verbose "xref file `echo $this_file | sed 's|\./||g'` differed ..."
          $verbose "xref file `echo $this_file | sed 's|\./||g'` differed ..."
          test "$debug" = t && diff -c "$tmpdir_bak/$this_file" "$this_file"
          test "$debug" = t && diff -c "$tmpdir_bak/$this_file" "$this_file"
          break
          break
        fi
        fi
      done
      done
    fi
    fi
    # If finished, exit the loop, else rerun the loop.
    # If finished, exit the loop, else rerun the loop.
    test -n "$finished" && break
    test -n "$finished" && break
  done
  done
  # If we were in clean mode, compilation was in a tmp directory.
  # If we were in clean mode, compilation was in a tmp directory.
  # Copy the DVI (or PDF) file into the directory where the compilation
  # Copy the DVI (or PDF) file into the directory where the compilation
  # has been done.  (The temp dir is about to get removed anyway.)
  # has been done.  (The temp dir is about to get removed anyway.)
  # We also return to the original directory so that
  # We also return to the original directory so that
  # - the next file is processed in correct conditions
  # - the next file is processed in correct conditions
  # - the temporary file can be removed
  # - the temporary file can be removed
  if test -n "$clean"; then
  if test -n "$clean"; then
    if test -n "$oname"; then
    if test -n "$oname"; then
       dest=$oname
       dest=$oname
    else
    else
       dest=$orig_pwd
       dest=$orig_pwd
    fi
    fi
    $verbose "Copying $oformat file from `pwd` to $dest"
    $verbose "Copying $oformat file from `pwd` to $dest"
    cp -p "./$filename_noext.$oformat" "$dest"
    cp -p "./$filename_noext.$oformat" "$dest"
    cd / # in case $orig_pwd is on a different drive (for DOS)
    cd / # in case $orig_pwd is on a different drive (for DOS)
    cd $orig_pwd || exit 1
    cd $orig_pwd || exit 1
  fi
  fi
  # Remove temporary files.
  # Remove temporary files.
  if test "x$debug" = "x"; then
  if test "x$debug" = "x"; then
    $verbose "Removing $tmpdir_src $tmpdir_xtr $tmpdir_bak ..."
    $verbose "Removing $tmpdir_src $tmpdir_xtr $tmpdir_bak ..."
    cd /
    cd /
    rm -rf $tmpdir_src $tmpdir_xtr $tmpdir_bak
    rm -rf $tmpdir_src $tmpdir_xtr $tmpdir_bak
  fi
  fi
done
done
$verbose "$0 done."
$verbose "$0 done."
exit 0 # exit successfully, not however we ended the loop.
exit 0 # exit successfully, not however we ended the loop.
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.