On Fri, Jun 17, 2005 at 09:14:04AM +0200, Werner LEMBERG wrote:
> Well, the platform is NetBSD 1.6 (GENERIC), the default shell is
> apparently /bin/ksh on Nelson's setup.  Thomas, do you have time to
> build
> 
>   http://groff.ffii.org/groff/devel/groff-1.19.2.pre-20050527.tar.gz
> 
> and report whether you have failures?  [But please don't install it --
> you might also test the current CVS which would be even better.]  In
> case the pdfroff script fails, please run
> 
>   touch  foo  bar
>   sh  -vx  pdfroff  --style=foo  bar  >  /dev/null  2> pdfroff.log
> 
> so that we get more meaningful diagnostic messages.

I don't have a 1.6, but I tested it on 1.6.2.
Build failed with (BSD) make:
Making groff_mom.n from groff_mom.man
pdfroff
make: exec(pdfroff) failed (No such file or directory)
*** Error code 1

With GNU make I got a bit further:
export GROFF_COMMAND_PREFIX; GROFF_COMMAND_PREFIX=''; export GROFF_BIN_DIR; 
GROFF_BIN_DIR=/home/wiz/groff-1.19.2.pre-20050527/src/roff/groff; export 
GROFF_BIN_PATH; GROFF_BIN_PATH=`echo 
/home/wiz/groff-1.19.2.pre-20050527/src/roff/groff 
/home/wiz/groff-1.19.2.pre-20050527/src/roff/troff 
/home/wiz/groff-1.19.2.pre-20050527/src/devices/grops | sed -e 's|  *|:|g'`; 
./pdfroff -F/home/wiz/groff-1.19.2.pre-20050527/font 
-F/home/wiz/groff-1.19.2.pre-20050527/font -M. 
-M/home/wiz/groff-1.19.2.pre-20050527/tmac 
-M/home/wiz/groff-1.19.2.pre-20050527/tmac -dpaper=A4 -P-pA4 -mspdf 
--style=./cover.ms pdfmark.ms >pdfmark.pdf
./pdfroff: 561: Syntax error: "}" unexpected (expecting "fi")

pdfroff.log as suggested attached to this mail.

Cheers,
 Thomas
#! /bin/sh
# ------------------------------------------------------------------------------
#
# Function: Format PDF Output from groff Markup
#
# Copyright (C) 2005, Free Software Foundation, Inc.
# Written by Keith Marshall ([EMAIL PROTECTED])
# 
# This file is part of groff.
# 
# groff is free software; you can redistribute it and/or modify it under
# the terms of the GNU General Public License as published by the Free
# Software Foundation; either version 2, or (at your option) any later
# version.
# 
# groff is distributed in the hope that it will be useful, but WITHOUT ANY
# WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
# for more details.
# 
# You should have received a copy of the GNU General Public License along
# with groff; see the file COPYING.  If not, write to the Free Software
# Foundation, 51 Franklin St - Fifth Floor, Boston, MA 02110-1301, USA.
#
# ------------------------------------------------------------------------------
#
# Set up an identifier for the NULL device.
# In most cases "/dev/null" will be correct, but some shells on
# MS-DOS/MS-Windows systems may require us to use "NUL".
#
  NULLDEV="/dev/null"
+ NULLDEV=/dev/null
  test -c $NULLDEV || NULDEV="NUL"
+ test -c /dev/null
#
# Set up the command name to use in diagnostic messages.
# (We can't assume we have 'basename', so use the full path if required.
#  Also use the 'exec 2>...' workaround for a bug in Cygwin's 'ash').
#
  CMD=`exec 2>$NULLDEV; basename $0` || CMD=$0
+ exec
+ CMD=pdfroff.sh
#
# To ensure that prerequisite helper programs are available, and are
# executable, a [fairly] portable method of detecting such programs is
# provided by function `searchpath'.
#
  searchpath(){
  #
  # Usage:  searchpath progname path
  #
    IFS="${PATH_SEPARATOR-":"}" prog=':'
    for dir in $2
    do
      for ext in '' '.exe'
      #
      # try `progname' with all well known extensions
      # (e.g. Win32 may require `progname.exe')
      #
      do
        try="$dir/$1$ext"
        test -f "$try" && test -x "$try" && prog="$try" && break
      done
      test "$prog" = ":" || break
    done
    echo "$prog"
  }
# @PATH_SEARCH_SETUP@
#
# We need both 'grep' and 'sed' programs, to parse script options,
# and we also need 'cat', to display help and some error messages,
# so ensure they are all installed, before we continue.
#
  CAT=`searchpath cat "$PATH"`
+ searchpath cat 
/usr/bin:/bin:/usr/pkg/bin:/usr/local/bin:/usr/X11R6/bin:/home/wiz/bin:/usr/sbin:/sbin
+ IFS=: prog=:
+ try=/usr/bin/cat
+ test -f /usr/bin/cat
+ try=/usr/bin/cat.exe
+ test -f /usr/bin/cat.exe
+ test : = :
+ try=/bin/cat
+ test -f /bin/cat
+ test -x /bin/cat
+ prog=/bin/cat
+ break
+ test /bin/cat = :
+ break
+ echo /bin/cat
+ CAT=/bin/cat
  GREP=`searchpath grep "$PATH"`
+ searchpath grep 
/usr/bin:/bin:/usr/pkg/bin:/usr/local/bin:/usr/X11R6/bin:/home/wiz/bin:/usr/sbin:/sbin
+ IFS=: prog=:
+ try=/usr/bin/grep
+ test -f /usr/bin/grep
+ test -x /usr/bin/grep
+ prog=/usr/bin/grep
+ break
+ test /usr/bin/grep = :
+ break
+ echo /usr/bin/grep
+ GREP=/usr/bin/grep
  SED=`searchpath sed "$PATH"`
+ searchpath sed 
/usr/bin:/bin:/usr/pkg/bin:/usr/local/bin:/usr/X11R6/bin:/home/wiz/bin:/usr/sbin:/sbin
+ IFS=: prog=:
+ try=/usr/bin/sed
+ test -f /usr/bin/sed
+ test -x /usr/bin/sed
+ prog=/usr/bin/sed
+ break
+ test /usr/bin/sed = :
+ break
+ echo /usr/bin/sed
+ SED=/usr/bin/sed
#
# Another fundamental requirement is the 'groff' program itself;
# we MUST use a 'groff' program located in 'GROFF_BIN_DIR', if this
# is specified; if not, we will search 'GROFF_BIN_PATH', only falling
# back to a 'PATH' search, if neither of these is specified.
#
  if test -n "$GROFF_BIN_DIR"
  then
    GPATH=GROFF_BIN_DIR
    GROFF=`searchpath groff "$GROFF_BIN_DIR"`
#
  elif test -n "$GROFF_BIN_PATH"
  then
    GPATH=GROFF_BIN_PATH
    GROFF=`searchpath groff "$GROFF_BIN_PATH"`
#
  else
    GPATH=PATH
    GROFF=`searchpath groff "$PATH"`
  fi
+ test -n 
+ test -n 
+ GPATH=PATH
+ searchpath groff 
/usr/bin:/bin:/usr/pkg/bin:/usr/local/bin:/usr/X11R6/bin:/home/wiz/bin:/usr/sbin:/sbin
+ IFS=: prog=:
+ try=/usr/bin/groff
+ test -f /usr/bin/groff
+ test -x /usr/bin/groff
+ prog=/usr/bin/groff
+ break
+ test /usr/bin/groff = :
+ break
+ echo /usr/bin/groff
+ GROFF=/usr/bin/groff
#
# If one or more of these is missing, diagnose and bail out.
#
  NO='' NOPROG="$CMD: installation problem: cannot find program"
+ NO= NOPROG=pdfroff.sh: installation problem: cannot find program
  test "$CAT" = ":" && echo >&2 "$NOPROG 'cat' in PATH" && NO="$NO 'cat'"
+ test /bin/cat = :
  test "$GREP" = ":" && echo >&2 "$NOPROG 'grep' in PATH" && NO="$NO 'grep'"
+ test /usr/bin/grep = :
  test "$GROFF" = ":" && echo >&2 "$NOPROG 'groff' in $GPATH" && NO="$NO 
'groff'"
+ test /usr/bin/groff = :
  test "$SED" = ":" && echo >&2 "$NOPROG 'sed' in PATH" && NO="$NO 'sed'"
+ test /usr/bin/sed = :
  if test -n "$NO"
  then
    set $NO
    test $# -gt 1 && NO="s" IS="are" || NO='' IS="is"
    while test $# -gt 0
    do
      test $# -gt 2 && NO="$NO $1,"
      test $# -eq 2 && NO="$NO $1 and" && shift
      test $# -lt 2 && NO="$NO $1"
      shift
    done
    $CAT >&2 <<-ETX

        *** FATAL INSTALLATION ERROR ***

        The program$NO $IS required by '$CMD',
        but cannot be found; '$CMD' is unable to continue.

        ETX
    exit 1
  fi
+ test -n 
#
# Set up temporary/intermediate file locations.
#
  WRKFILE=${GROFF_TMPDIR=${TMPDIR-${TMP-${TEMP-"."}}}}/pdf$$.tmp
+ WRKFILE=./pdf11291.tmp
#
  REFCOPY=${GROFF_TMPDIR}/pdf$$.cmp
+ REFCOPY=./pdf11291.cmp
  REFFILE=${GROFF_TMPDIR}/pdf$$.ref
+ REFFILE=./pdf11291.ref
#
  CS_DATA=""
+ CS_DATA=
  TC_DATA=${GROFF_TMPDIR}/pdf$$.tc
+ TC_DATA=./pdf11291.tc
  BD_DATA=${GROFF_TMPDIR}/pdf$$.ps
+ BD_DATA=./pdf11291.ps
#
# Set a trap, to delete temporary files on exit.
# (FIXME: may want to include other signals, in released version).
#
  trap "rm -f ${GROFF_TMPDIR}/pdf$$.*" 0
+ trap rm -f ./pdf11291.* 0
#
# Initialise 'groff' format control settings,
# to discriminate table of contents and document body formatting passes.
#
  TOC_FORMAT="-rPHASE=1"
+ TOC_FORMAT=-rPHASE=1
  BODY_FORMAT="-rPHASE=2"
+ BODY_FORMAT=-rPHASE=2
#
  LONGOPTS="
    help        reference-dictionary    no-reference-dictionary
    stylesheet  pdf-output              no-pdf-output
    version     report-progress         no-toc-relocation
    "
+ LONGOPTS=
    help        reference-dictionary    no-reference-dictionary
    stylesheet  pdf-output              no-pdf-output
    version     report-progress         no-toc-relocation
    
# Parse the command line, to identify 'pdfroff' specific options.
# Collect all other parameters into new argument and file lists,
# to be passed on to 'groff', enforcing the '-Tps' option.
#
  DIFF="" STREAM="" INPUT_FILES=""
+ DIFF= STREAM= INPUT_FILES=
  SHOW_VERSION="" ARGLIST="-Tps" GROFF_STYLE="$GROFF -Tps"
+ SHOW_VERSION= ARGLIST=-Tps GROFF_STYLE=/usr/bin/groff -Tps
  while test $# -gt 0
  do
    case "$1" in
#
#     Long options must be processed locally ...
#
      --*)
#
#          First identify, matching any abbreviation to its full form.
#
           MATCH="" OPTNAME=`IFS==; set dummy $1; echo $2`
           for OPT in $LONGOPTS
           do
             MATCH="$MATCH`echo --$OPT | $GREP "^$OPTNAME"`"
           done
#
#          For options in the form --option=value
#          capture any specified value into $OPTARG.
#
           OPTARG=`echo $1 | $SED -n s?"^${OPTNAME}="??p`
#
#          Perform case specific processing for matched option ...
#
           case "$MATCH" in

             --help)
               $CAT >&2 <<-ETX
                Usage: $CMD [-option ...] [--long-option ...] [file ...]

                Options:
                  -h
                  --help
                        Display this usage summary, and exit.

                  -v
                  --version
                        Display a version identification message and exit.

                  --report-progress
                        Enable console messages, indicating the progress of the
                        PDF document formatting process.

                  --pdf-output=name
                        Write the PDF output stream to file 'name'; if this 
option
                        is unspecified, standard output is used for PDF output.

                  --no-pdf-output
                        Suppress the generation of PDF output entirely; use this
                        with the --reference-dictionary option, if processing a
                        document stream to produce only a reference dictionary.

                  --no-reference-dictionary
                        Suppress the generation of a '$CMD' reference dictionary
                        for the PDF document.  Normally '$CMD' will create a
                        reference dictionary, at the start of document 
processing;
                        this option can accelerate processing, if it is known in
                        advance, that no reference dictionary is required.

                  --reference-dictionary=name
                        Save the document reference dictionary in file 'name'.
                        If 'name' already exists, when processing commences, it
                        will be used as the base case, from which the updated
                        dictionary will be derived.  If this option is not used,
                        then the reference dictionary, created during the normal
                        execution of '$CMD', will be deleted on completion of
                        document processing.

                  --stylesheet=name
                        Use the file 'name' as a 'groff' style sheet, to control
                        the appearance of the document's front cover section.  
If
                        this option is not specified, then no special formatting
                        is applied, to create a front cover section.

                  --no-toc-relocation
                        Suppress the multiple pass 'groff' processing, which is
                        normally required to position the table of contents at 
the
                        start of a PDF document.

                ETX
               exit 0
               ;;

             --version)
               ARGLIST="$ARGLIST \"$1\""
               SHOW_VERSION="GNU pdfroff (groff) version @VERSION@"
               ;;

             --report-progress)
               SHOW_PROGRESS=echo
               ;;

             --pdf-output)
               PDF_OUTPUT="$OPTARG"
               ;;

             --no-pdf-output)
               PDF_OUTPUT="$NULLDEV"
               ;;

             --reference-dictionary)
               REFFILE="$OPTARG"
               ;;

             --no-reference-dictionary)
               AWK=":" DIFF=":" REFFILE="$NULLDEV" REFCOPY="$NULLDEV"
               ;;

             --stylesheet)
               STYLESHEET="$OPTARG" CS_DATA=${GROFF_TMPDIR}/pdf$$.cs
               ;;

             --no-toc-relocation)
               TC_DATA="" TOC_FORMAT="" BODY_FORMAT=""
               ;;
#
#          any other non-null match must have matched more than one defined 
case,
#          so report the ambiguity, and bail out.
#
             --*)
               echo >&2 "$CMD: ambiguous abbreviation in option '$1'"
               exit 1
               ;;
#
#          while no match at all simply represents an undefined case.
#
             *)
               echo >&2 "$CMD: unknown option '$1'"
               exit 1
               ;;
           esac
           ;;
#
#     A solitary hyphen, as an argument, means "stream STDIN through groff",
#     while the "-i" option means "append STDIN stream to specified input 
files",
#     so set up a mechanism to achieve this, for ALL 'groff' passes.
#
      - | -i*)
           STREAM="$CAT ${GROFF_TMPDIR}/pdf$$.in |"
           ARGLIST="$ARGLIST $1" INPUT_FILES="$INPUT_FILES $1"
           ;;
#
#     Those standard options which expect an argument, but are specified with
#     an intervening space, between flag and argument, must be reparsed, so we
#     can trap illegal use of '-T dev', or missing input files.
#
      -[dfFILmMnoPrTwW])
           OPTNAME="$1"
           shift; set reparse "$OPTNAME$@"
           ;;
#
#     Among standard options, '-Tdev' is treated as a special case.
#     '-Tps' is automatically enforced, so if specified, is silently ignored.
#
      -Tps) ;;
#
#     No other '-Tdev' option is permitted.
#
      -T*) echo >&2 "$CMD: option '$1' is incompatible with PDF output"
           exit 1
           ;;
#
#     '-h' and '-v' options redirect to their equivalent long forms ...
#
      -h*) set redirect --help
           ;;
#
      -v*) shift; set redirect --version "$@"
           ;;
#
#     All other standard options are simply passed through to 'groff',
#     with no validation beforehand.
#
      -*)  ARGLIST="$ARGLIST \"$1\"" GROFF_STYLE="$GROFF_STYLE \"$1\""
           ;;
#
#     All non-option arguments are considered as possible input file names,
#     and are passed on to 'groff', unaltered.
#
      *)   ARGLIST="$ARGLIST \"$1\""
           test -f "$1" && INPUT_FILES="$INPUT_FILES \"$1\""
           ;;
    esac
    shift
  done
+ test 2 -gt 0
+ IFS==
+ set dummy --style foo
+ echo --style
+ MATCH= OPTNAME=--style
+ echo --help
+ /usr/bin/grep ^--style
+ MATCH=
+ echo --reference-dictionary
+ /usr/bin/grep ^--style
+ MATCH=
+ echo --no-reference-dictionary
+ /usr/bin/grep ^--style
+ MATCH=
+ echo --stylesheet
+ /usr/bin/grep ^--style
+ MATCH=--stylesheet
+ echo --pdf-output
+ /usr/bin/grep ^--style
+ MATCH=--stylesheet
+ echo --no-pdf-output
+ /usr/bin/grep ^--style
+ MATCH=--stylesheet
+ echo --version
+ /usr/bin/grep ^--style
+ MATCH=--stylesheet
+ echo --report-progress
+ /usr/bin/grep ^--style
+ MATCH=--stylesheet
+ echo --no-toc-relocation
+ /usr/bin/grep ^--style
+ MATCH=--stylesheet
+ echo --style=foo
+ /usr/bin/sed -n s?^--style=??p
+ OPTARG=foo
+ STYLESHEET=foo CS_DATA=./pdf11291.cs
+ shift
+ test 1 -gt 0
+ ARGLIST=-Tps "bar"
+ test -f bar
+ INPUT_FILES= "bar"
+ shift
+ test 0 -gt 0
#
# If the '-v' or '--version' option was specified,
# then we simply emulate the behaviour of 'groff', with this option,
# and quit.
#
  if test -n "$SHOW_VERSION"
  then
    echo >&2 "$SHOW_VERSION"
    echo >&2; eval $GROFF $ARGLIST
    exit $?
  fi
+ test -n 
#
# Establish how to invoke 'echo', suppressing the terminating newline.
# (Adapted from 'autoconf' code, as found in 'configure' scripts).
#
  case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
    *c*,*-n*)  n=''   c=''   ;;
    *c*)       n='-n' c=''   ;;
    *)         n=''   c='\c' ;;
  esac
+ echo testing\c
+ echo 1,2,3
+ echo -n testing
+ echo 1,2,3
+ n=-n c=
#
# If STDIN is specified among the input files,
# or if no input files are specified, then we need to capture STDIN,
# so we can replay it into each 'groff' processing pass.
#
  test -z "$INPUT_FILES" && STREAM="$CAT ${GROFF_TMPDIR}/pdf$$.in |"
+ test -z  "bar"
  test -n "$STREAM" && $CAT > ${GROFF_TMPDIR}/pdf$$.in
+ test -n 
#
# Unless reference resolution is explicitly suppressed,
# we initiate it by touching the cross reference dictionary file,
# and initialise the comparator, to kickstart the reference resolver loop.
#
  SAY=":"
+ SAY=:
  if test -z "$DIFF"
  then
    >> $REFFILE
    echo kickstart > $REFCOPY
    test "${SHOW_PROGRESS+"set"}" = "set" && SAY=echo
#
#   In order to correctly resolve 'pdfmark' references,
#   we need to have both the 'awk' and 'diff' programs available.
#
    NO=''
    if test -n "$GROFF_AWK_INTERPRETER"
    then
      AWK="$GROFF_AWK_INTERPRETER"
      test -f "$AWK" && test -x "$AWK" || AWK=":"
    else
      for prog in @GROFF_AWK_INTERPRETERS@
      do
        AWK=`searchpath $prog "$PATH"`
        test "$AWK" = ":" || break
      done
    fi
    DIFF=`searchpath diff "$PATH"`
    test "$AWK" = ":" && echo >&2 "$NOPROG 'awk' in PATH" && NO="$NO 'awk'"
    test "$DIFF" = ":" && echo >&2 "$NOPROG 'diff' in PATH" && NO="$NO 'diff'"
    if test -n "$NO"
    then
      set $NO
      SAY=":" AWK=":" DIFF=":"
      test $# -gt 1 && NO="s $1 and $2 are" || NO=" $1 is"
      $CAT >&2 <<-ETX

        *** WARNING ***

        The program$NO required, but cannot be found;
        consequently, '$CMD' is unable to resolve 'pdfmark' references.

        Document processing will continue, but no 'pdfmark' reference dictionary
        will be compiled; if any 'pdfmark' reference appears in the resulting 
PDF
        document, the formatting may not be correct.

        ETX
    fi
  fi
+ test -z 
+
+ echo kickstart
+ test  = set
+ NO=
+ test -n 
+ searchpath @GROFF_AWK_INTERPRETERS@ 
/usr/bin:/bin:/usr/pkg/bin:/usr/local/bin:/usr/X11R6/bin:/home/wiz/bin:/usr/sbin:/sbin
+ IFS=: prog=:
+ try=/usr/bin/@GROFF_AWK_INTERPRETERS@
+ test -f /usr/bin/@GROFF_AWK_INTERPRETERS@
+ try=/usr/bin/@[EMAIL PROTECTED]
+ test -f /usr/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/bin/@GROFF_AWK_INTERPRETERS@
+ test -f /bin/@GROFF_AWK_INTERPRETERS@
+ try=/bin/@[EMAIL PROTECTED]
+ test -f /bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/usr/pkg/bin/@GROFF_AWK_INTERPRETERS@
+ test -f /usr/pkg/bin/@GROFF_AWK_INTERPRETERS@
+ try=/usr/pkg/bin/@[EMAIL PROTECTED]
+ test -f /usr/pkg/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/usr/local/bin/@GROFF_AWK_INTERPRETERS@
+ test -f /usr/local/bin/@GROFF_AWK_INTERPRETERS@
+ try=/usr/local/bin/@[EMAIL PROTECTED]
+ test -f /usr/local/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/usr/X11R6/bin/@GROFF_AWK_INTERPRETERS@
+ test -f /usr/X11R6/bin/@GROFF_AWK_INTERPRETERS@
+ try=/usr/X11R6/bin/@[EMAIL PROTECTED]
+ test -f /usr/X11R6/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/home/wiz/bin/@GROFF_AWK_INTERPRETERS@
+ test -f /home/wiz/bin/@GROFF_AWK_INTERPRETERS@
+ try=/home/wiz/bin/@[EMAIL PROTECTED]
+ test -f /home/wiz/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/usr/sbin/@GROFF_AWK_INTERPRETERS@
+ test -f /usr/sbin/@GROFF_AWK_INTERPRETERS@
+ try=/usr/sbin/@[EMAIL PROTECTED]
+ test -f /usr/sbin/@[EMAIL PROTECTED]
+ test : = :
+ try=/sbin/@GROFF_AWK_INTERPRETERS@
+ test -f /sbin/@GROFF_AWK_INTERPRETERS@
+ try=/sbin/@[EMAIL PROTECTED]
+ test -f /sbin/@[EMAIL PROTECTED]
+ test : = :
+ echo :
+ AWK=:
+ test : = :
+ searchpath diff 
/usr/bin:/bin:/usr/pkg/bin:/usr/local/bin:/usr/X11R6/bin:/home/wiz/bin:/usr/sbin:/sbin
+ IFS=: prog=:
+ try=/usr/bin/diff
+ test -f /usr/bin/diff
+ test -x /usr/bin/diff
+ prog=/usr/bin/diff
+ break
+ test /usr/bin/diff = :
+ break
+ echo /usr/bin/diff
+ DIFF=/usr/bin/diff
+ test : = :
+ echo pdfroff.sh: installation problem: cannot find program 'awk' in PATH
pdfroff.sh: installation problem: cannot find program 'awk' in PATH
+ NO= 'awk'
+ test /usr/bin/diff = :
+ test -n  'awk'
+ set 'awk'
+ SAY=: AWK=: DIFF=:
+ test 1 -gt 1
+ NO= 'awk' is
+ /bin/cat

*** WARNING ***

The program 'awk' is required, but cannot be found;
consequently, 'pdfroff.sh' is unable to resolve 'pdfmark' references.

Document processing will continue, but no 'pdfmark' reference dictionary
will be compiled; if any 'pdfmark' reference appears in the resulting PDF
document, the formatting may not be correct.

#
# Run the multi-pass 'pdfmark' reference resolver loop ...
#
  $SAY >&2 $n Resolving references ..$c
+ : -n Resolving references ..
  until $DIFF $REFCOPY $REFFILE 1>$NULLDEV 2>&1
  do
#
#   until all references are resolved, to yield consistent values
#   in each of two consecutive passes, or until it seems that no consistent
#   resolution is achievable.
#
    $SAY >&2 $n .$c
    PASS_INDICATOR="${PASS_INDICATOR}."
    if test "$PASS_INDICATOR" = "...."
    then
#
#     More than three passes required indicates a probable inconsistency
#     in the source document; diagnose, and bail out.
#
      $SAY >&2 " failed"
      $CAT >&2 <<-ETX
        $CMD: unable to resolve references consistently after three passes
        $CMD: the source document may exhibit instability about the 
reference(s) ...
        ETX
#
#     Report the unresolved references, as a diff between the two pass files,
#     preferring 'unified' or 'context' diffs, when available
#
      DIFFOPT=''
      $DIFF -c0 $NULLDEV $NULLDEV 1>$NULLDEV 2>&1 && DIFFOPT='-c0'
      $DIFF -u0 $NULLDEV $NULLDEV 1>$NULLDEV 2>&1 && DIFFOPT='-u0'
      $DIFF >&2 $DIFFOPT $REFCOPY $REFFILE
      exit 1
    fi
#
#   Replace the comparison file copy from any previous pass,
#   with the most recently updated copy of the reference dictionary.
#   (Some versions of 'mv' may not support overwriting of an existing file,
#    so remove the old comparison file first).
#
    rm -f $REFCOPY
    mv $REFFILE $REFCOPY
#
#   Run 'groff' and 'awk', to identify reference marks in the document source,
#   filtering them into the reference dictionary; discard incomplete 'groff' 
output
#   at this stage.
#
    eval $STREAM $GROFF -Z 1>$NULLDEV 2>$WRKFILE $REFCOPY $ARGLIST
    $AWK '/^gropdf-info:href/ {$1 = ".pdfhref D -N"; print}' $WRKFILE > $REFFILE
  done
+ : ./pdf11291.cmp ./pdf11291.ref
  $SAY >&2 " done"
+ :  done
#
# To get to here ...
# We MUST have resolved all 'pdfmark' references, such that the content of the
# updated reference dictionary file EXACTLY matches the last saved copy.
#
# If PDF output has been suppressed, then there is nothing more to do.
#
  test "$PDF_OUTPUT" = "$NULLDEV" && exit 0
+ test  = /dev/null
#
# We are now ready to start preparing the intermediate PostScript files,
# from which the PDF output will be compiled -- but before proceding further ...
# let's make sure we have a GhostScript interpreter to convert them!
#
  if test -n "$GROFF_GHOSTSCRIPT_INTERPRETER"
  then
    GS="$GROFF_GHOSTSCRIPT_INTERPRETER"
    test -f "$GS" && test -x "$GS" || GS=":"
  else
    for prog in @GROFF_GHOSTSCRIPT_INTERPRETERS@
    do
      GS=`searchpath $prog "$PATH"`
      test "$GS" = ":" || break
    done
  fi
+ test -n 
+ searchpath @GROFF_GHOSTSCRIPT_INTERPRETERS@ 
/usr/bin:/bin:/usr/pkg/bin:/usr/local/bin:/usr/X11R6/bin:/home/wiz/bin:/usr/sbin:/sbin
+ IFS=: prog=:
+ try=/usr/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ test -f /usr/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ try=/usr/bin/@[EMAIL PROTECTED]
+ test -f /usr/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ test -f /bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ try=/bin/@[EMAIL PROTECTED]
+ test -f /bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/usr/pkg/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ test -f /usr/pkg/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ try=/usr/pkg/bin/@[EMAIL PROTECTED]
+ test -f /usr/pkg/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/usr/local/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ test -f /usr/local/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ try=/usr/local/bin/@[EMAIL PROTECTED]
+ test -f /usr/local/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/usr/X11R6/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ test -f /usr/X11R6/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ try=/usr/X11R6/bin/@[EMAIL PROTECTED]
+ test -f /usr/X11R6/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/home/wiz/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ test -f /home/wiz/bin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ try=/home/wiz/bin/@[EMAIL PROTECTED]
+ test -f /home/wiz/bin/@[EMAIL PROTECTED]
+ test : = :
+ try=/usr/sbin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ test -f /usr/sbin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ try=/usr/sbin/@[EMAIL PROTECTED]
+ test -f /usr/sbin/@[EMAIL PROTECTED]
+ test : = :
+ try=/sbin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ test -f /sbin/@GROFF_GHOSTSCRIPT_INTERPRETERS@
+ try=/sbin/@[EMAIL PROTECTED]
+ test -f /sbin/@[EMAIL PROTECTED]
+ test : = :
+ echo :
+ GS=:
+ test : = :
#
# If we could not find a GhostScript interpreter, then we can do no more.
#
  if test "$GS" = ":"
  then
    echo >&2 "$CMD: installation problem: cannot find GhostScript interpreter"
    $CAT >&2 <<-ETX

        *** FATAL INSTALLATION ERROR ***

        '$CMD' requires a GhostScript interpreter to convert PostScript to PDF.
        Since you do not appear to have one installed, '$CMD' connot continue.

        ETX
    exit 1
  fi
+ test : = :
+ echo pdfroff.sh: installation problem: cannot find GhostScript interpreter
pdfroff.sh: installation problem: cannot find GhostScript interpreter
+ /bin/cat

*** FATAL INSTALLATION ERROR ***

'pdfroff.sh' requires a GhostScript interpreter to convert PostScript to PDF.
Since you do not appear to have one installed, 'pdfroff.sh' connot continue.

+ exit 1
+ rm -f ./pdf11291.cmp ./pdf11291.ref
_______________________________________________
Groff mailing list
Groff@gnu.org
http://lists.gnu.org/mailman/listinfo/groff

Reply via email to