home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / unixtex-6.1b-src.tgz / tar.out / contrib / unixtex / configure < prev    next >
Text File  |  1996-10-01  |  38KB  |  1,138 lines

  1. #! /bin/sh
  2.  
  3. # Guess values for system-dependent variables and create Makefiles.
  4. # Generated automatically using autoconf version 2.10 
  5. # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
  6. #
  7. # This configure script is free software; the Free Software Foundation
  8. # gives unlimited permission to copy, distribute and modify it.
  9.  
  10. # Defaults:
  11. ac_help=
  12. ac_default_prefix=/usr/local
  13. # Any additions from configure.in:
  14.  
  15. # Initialize some variables set by options.
  16. # The variables have the same names as the options, with
  17. # dashes changed to underlines.
  18. build=NONE
  19. cache_file=./config.cache
  20. exec_prefix=NONE
  21. host=NONE
  22. no_create=
  23. nonopt=NONE
  24. no_recursion=
  25. prefix=NONE
  26. program_prefix=NONE
  27. program_suffix=NONE
  28. program_transform_name=s,x,x,
  29. silent=
  30. site=
  31. srcdir=
  32. target=NONE
  33. verbose=
  34. x_includes=NONE
  35. x_libraries=NONE
  36. bindir='${exec_prefix}/bin'
  37. sbindir='${exec_prefix}/sbin'
  38. libexecdir='${exec_prefix}/libexec'
  39. datadir='${prefix}/share'
  40. sysconfdir='${prefix}/etc'
  41. sharedstatedir='${prefix}/com'
  42. localstatedir='${prefix}/var'
  43. libdir='${exec_prefix}/lib'
  44. includedir='${prefix}/include'
  45. oldincludedir='/usr/include'
  46. infodir='${prefix}/info'
  47. guidedir='${prefix}/guide'
  48. psdir='${prefix}/ps'
  49. dvidir='${prefix}/dvi'
  50. mandir='${prefix}/man'
  51.  
  52. # Initialize some other variables.
  53. subdirs=
  54. MFLAGS= MAKEFLAGS=
  55.  
  56. ac_prev=
  57. for ac_option
  58. do
  59.  
  60.   # If the previous option needs an argument, assign it.
  61.   if test -n "$ac_prev"; then
  62.     eval "$ac_prev=\$ac_option"
  63.     ac_prev=
  64.     continue
  65.   fi
  66.  
  67.   case "$ac_option" in
  68.   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  69.   *) ac_optarg= ;;
  70.   esac
  71.  
  72.   # Accept the important Cygnus configure options, so we can diagnose typos.
  73.  
  74.   case "$ac_option" in
  75.  
  76.   -bindir | --bindir | --bindi | --bind | --bin | --bi)
  77.     ac_prev=bindir ;;
  78.   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
  79.     bindir="$ac_optarg" ;;
  80.  
  81.   -build | --build | --buil | --bui | --bu)
  82.     ac_prev=build ;;
  83.   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
  84.     build="$ac_optarg" ;;
  85.  
  86.   -cache-file | --cache-file | --cache-fil | --cache-fi \
  87.   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  88.     ac_prev=cache_file ;;
  89.   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  90.   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  91.     cache_file="$ac_optarg" ;;
  92.  
  93.   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
  94.     ac_prev=datadir ;;
  95.   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
  96.   | --da=*)
  97.     datadir="$ac_optarg" ;;
  98.  
  99.   -disable-* | --disable-*)
  100.     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
  101.     # Reject names that are not valid shell variable names.
  102.     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
  103.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  104.     fi
  105.     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  106.     eval "enable_${ac_feature}=no" ;;
  107.  
  108.   -enable-* | --enable-*)
  109.     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
  110.     # Reject names that are not valid shell variable names.
  111.     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
  112.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  113.     fi
  114.     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  115.     case "$ac_option" in
  116.       *=*) ;;
  117.       *) ac_optarg=yes ;;
  118.     esac
  119.     eval "enable_${ac_feature}='$ac_optarg'" ;;
  120.  
  121.   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  122.   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  123.   | --exec | --exe | --ex)
  124.     ac_prev=exec_prefix ;;
  125.   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  126.   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  127.   | --exec=* | --exe=* | --ex=*)
  128.     exec_prefix="$ac_optarg" ;;
  129.  
  130.   -gas | --gas | --ga | --g)
  131.     # Obsolete; use --with-gas.
  132.     with_gas=yes ;;
  133.  
  134.   -help | --help | --hel | --he)
  135.     # Omit some internal or obsolete options to make the list less imposing.
  136.     # This message is too long to be a string in the A/UX 3.1 sh.
  137.     cat << EOF
  138. Usage: configure [options] [host]
  139. Options: [defaults in brackets after descriptions]
  140. Configuration:
  141.   --cache-file=FILE       cache test results in FILE
  142.   --help                  print this message
  143.   --no-create             do not create output files
  144.   --quiet, --silent       do not print \`checking...' messages
  145.   --version               print the version of autoconf that created configure
  146. Directory and file names:
  147.   --prefix=PREFIX         install architecture-independent files in PREFIX
  148.                           [$ac_default_prefix]
  149.   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
  150.                           [same as prefix]
  151.   --bindir=DIR            user executables in DIR [EPREFIX/bin]
  152.   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
  153.   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
  154.   --datadir=DIR           read-only architecture-independent data in DIR
  155.                           [PREFIX/share]
  156.   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
  157.   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
  158.                           [PREFIX/com]
  159.   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
  160.   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
  161.   --includedir=DIR        C header files in DIR [PREFIX/include]
  162.   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
  163.   --infodir=DIR           info documentation in DIR [PREFIX/info]
  164.   --guidedir=DIR          Amigaguide documentation in DIR [PREFIX/guide]
  165.   --psdir=DIR             postscript documentation in DIR [PREFIX/ps]
  166.   --dvidir=DIR            TeX dvi documentation in DIR [PREFIX/dvi]
  167.   --mandir=DIR            man documentation in DIR [PREFIX/man]
  168.   --srcdir=DIR            find the sources in DIR [configure dir or ..]
  169.   --program-prefix=PREFIX prepend PREFIX to installed program names
  170.   --program-suffix=SUFFIX append SUFFIX to installed program names
  171.   --program-transform-name=PROGRAM
  172.                           run sed PROGRAM on installed program names
  173. EOF
  174.     cat << EOF
  175. Host type:
  176.   --build=BUILD           configure for building on BUILD [BUILD=HOST]
  177.   --host=HOST             configure for HOST [guessed]
  178.   --target=TARGET         configure for TARGET [TARGET=HOST]
  179. Features and packages:
  180.   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  181.   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  182.   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  183.   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  184.   --x-includes=DIR        X include files are in DIR
  185.   --x-libraries=DIR       X library files are in DIR
  186. EOF
  187.     if test -n "$ac_help"; then
  188.       echo "--enable and --with options recognized:$ac_help"
  189.     fi
  190.     exit 0 ;;
  191.  
  192.   -host | --host | --hos | --ho)
  193.     ac_prev=host ;;
  194.   -host=* | --host=* | --hos=* | --ho=*)
  195.     host="$ac_optarg" ;;
  196.  
  197.   -includedir | --includedir | --includedi | --included | --include \
  198.   | --includ | --inclu | --incl | --inc)
  199.     ac_prev=includedir ;;
  200.   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  201.   | --includ=* | --inclu=* | --incl=* | --inc=*)
  202.     includedir="$ac_optarg" ;;
  203.  
  204.   -infodir | --infodir | --infodi | --infod | --info | --inf)
  205.     ac_prev=infodir ;;
  206.   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
  207.     infodir="$ac_optarg" ;;
  208.  
  209.  -guidedir | --guidedir | --guidedi | --guided | --guide | --gui)
  210.    ac_prev=guidedir ;;
  211.  -guidedir=* | --guidedir=* | --guidedi=* | --guided=* | --guide=* |--gui=*)+    guidedir="$ac_optarg" ;;
  212.  
  213.  -psdir | --psdir | --psdi | --psd | --ps)
  214.    ac_prev=psdir ;;
  215.  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)+    psdir="$ac_optarg" ;;
  216.  
  217.  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
  218.    ac_prev=dvidir ;;
  219.  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* |--dv=*)+    dvidir="$ac_optarg" ;;
  220.  
  221.   -libdir | --libdir | --libdi | --libd)
  222.     ac_prev=libdir ;;
  223.   -libdir=* | --libdir=* | --libdi=* | --libd=*)
  224.     libdir="$ac_optarg" ;;
  225.  
  226.   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  227.   | --libexe | --libex | --libe)
  228.     ac_prev=libexecdir ;;
  229.   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  230.   | --libexe=* | --libex=* | --libe=*)
  231.     libexecdir="$ac_optarg" ;;
  232.  
  233.   -localstatedir | --localstatedir | --localstatedi | --localstated \
  234.   | --localstate | --localstat | --localsta | --localst \
  235.   | --locals | --local | --loca | --loc | --lo)
  236.     ac_prev=localstatedir ;;
  237.   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  238.   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
  239.   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
  240.     localstatedir="$ac_optarg" ;;
  241.  
  242.   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
  243.     ac_prev=mandir ;;
  244.   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
  245.     mandir="$ac_optarg" ;;
  246.  
  247.   -nfp | --nfp | --nf)
  248.     # Obsolete; use --without-fp.
  249.     with_fp=no ;;
  250.  
  251.   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  252.   | --no-cr | --no-c)
  253.     no_create=yes ;;
  254.  
  255.   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  256.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  257.     no_recursion=yes ;;
  258.  
  259.   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  260.   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  261.   | --oldin | --oldi | --old | --ol | --o)
  262.     ac_prev=oldincludedir ;;
  263.   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  264.   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  265.   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
  266.     oldincludedir="$ac_optarg" ;;
  267.  
  268.   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  269.     ac_prev=prefix ;;
  270.   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  271.     prefix="$ac_optarg" ;;
  272.  
  273.   -program-prefix | --program-prefix | --program-prefi | --program-pref \
  274.   | --program-pre | --program-pr | --program-p)
  275.     ac_prev=program_prefix ;;
  276.   -program-prefix=* | --program-prefix=* | --program-prefi=* \
  277.   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  278.     program_prefix="$ac_optarg" ;;
  279.  
  280.   -program-suffix | --program-suffix | --program-suffi | --program-suff \
  281.   | --program-suf | --program-su | --program-s)
  282.     ac_prev=program_suffix ;;
  283.   -program-suffix=* | --program-suffix=* | --program-suffi=* \
  284.   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  285.     program_suffix="$ac_optarg" ;;
  286.  
  287.   -program-transform-name | --program-transform-name \
  288.   | --program-transform-nam | --program-transform-na \
  289.   | --program-transform-n | --program-transform- \
  290.   | --program-transform | --program-transfor \
  291.   | --program-transfo | --program-transf \
  292.   | --program-trans | --program-tran \
  293.   | --progr-tra | --program-tr | --program-t)
  294.     ac_prev=program_transform_name ;;
  295.   -program-transform-name=* | --program-transform-name=* \
  296.   | --program-transform-nam=* | --program-transform-na=* \
  297.   | --program-transform-n=* | --program-transform-=* \
  298.   | --program-transform=* | --program-transfor=* \
  299.   | --program-transfo=* | --program-transf=* \
  300.   | --program-trans=* | --program-tran=* \
  301.   | --progr-tra=* | --program-tr=* | --program-t=*)
  302.     program_transform_name="$ac_optarg" ;;
  303.  
  304.   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  305.   | -silent | --silent | --silen | --sile | --sil)
  306.     silent=yes ;;
  307.  
  308.   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
  309.     ac_prev=sbindir ;;
  310.   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  311.   | --sbi=* | --sb=*)
  312.     sbindir="$ac_optarg" ;;
  313.  
  314.   -sharedstatedir | --sharedstatedir | --sharedstatedi \
  315.   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  316.   | --sharedst | --shareds | --shared | --share | --shar \
  317.   | --sha | --sh)
  318.     ac_prev=sharedstatedir ;;
  319.   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  320.   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  321.   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  322.   | --sha=* | --sh=*)
  323.     sharedstatedir="$ac_optarg" ;;
  324.  
  325.   -site | --site | --sit)
  326.     ac_prev=site ;;
  327.   -site=* | --site=* | --sit=*)
  328.     site="$ac_optarg" ;;
  329.  
  330.   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  331.     ac_prev=srcdir ;;
  332.   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  333.     srcdir="$ac_optarg" ;;
  334.  
  335.   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  336.   | --syscon | --sysco | --sysc | --sys | --sy)
  337.     ac_prev=sysconfdir ;;
  338.   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  339.   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
  340.     sysconfdir="$ac_optarg" ;;
  341.  
  342.   -target | --target | --targe | --targ | --tar | --ta | --t)
  343.     ac_prev=target ;;
  344.   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  345.     target="$ac_optarg" ;;
  346.  
  347.   -v | -verbose | --verbose | --verbos | --verbo | --verb)
  348.     verbose=yes ;;
  349.  
  350.   -version | --version | --versio | --versi | --vers)
  351.     echo "configure generated by autoconf version 2.10"
  352.     exit 0 ;;
  353.  
  354.   -with-* | --with-*)
  355.     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
  356.     # Reject names that are not valid shell variable names.
  357.     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
  358.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  359.     fi
  360.     ac_package=`echo $ac_package| sed 's/-/_/g'`
  361.     case "$ac_option" in
  362.       *=*) ;;
  363.       *) ac_optarg=yes ;;
  364.     esac
  365.     eval "with_${ac_package}='$ac_optarg'" ;;
  366.  
  367.   -without-* | --without-*)
  368.     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
  369.     # Reject names that are not valid shell variable names.
  370.     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
  371.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  372.     fi
  373.     ac_package=`echo $ac_package| sed 's/-/_/g'`
  374.     eval "with_${ac_package}=no" ;;
  375.  
  376.   --x)
  377.     # Obsolete; use --with-x.
  378.     with_x=yes ;;
  379.  
  380.   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  381.   | --x-incl | --x-inc | --x-in | --x-i)
  382.     ac_prev=x_includes ;;
  383.   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  384.   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  385.     x_includes="$ac_optarg" ;;
  386.  
  387.   -x-libraries | --x-libraries | --x-librarie | --x-librari \
  388.   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  389.     ac_prev=x_libraries ;;
  390.   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  391.   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  392.     x_libraries="$ac_optarg" ;;
  393.  
  394.   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
  395.     ;;
  396.  
  397.   *)
  398.     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
  399.       echo "configure: warning: $ac_option: invalid host type" 1>&2
  400.     fi
  401.     if test "x$nonopt" != xNONE; then
  402.       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
  403.     fi
  404.     nonopt="$ac_option"
  405.     ;;
  406.  
  407.   esac
  408. done
  409.  
  410. if test -n "$ac_prev"; then
  411.   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
  412. fi
  413.  
  414. trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
  415.  
  416. # File descriptor usage:
  417. # 0 standard input
  418. # 1 file creation
  419. # 2 errors and warnings
  420. # 3 some systems may open it to /dev/tty
  421. # 4 used on the Kubota Titan
  422. # 6 checking for... messages and results
  423. # 5 compiler messages saved in config.log
  424. if test "$silent" = yes; then
  425.   exec 6>/dev/null
  426. else
  427.   exec 6>&1
  428. fi
  429. exec 5>./config.log
  430.  
  431. echo "\
  432. This file contains any messages produced by compilers while
  433. running configure, to aid debugging if configure makes a mistake.
  434. " 1>&5
  435.  
  436. # Strip out --no-create and --no-recursion so they do not pile up.
  437. # Also quote any args containing shell metacharacters.
  438. ac_configure_args=
  439. for ac_arg
  440. do
  441.   case "$ac_arg" in
  442.   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  443.   | --no-cr | --no-c) ;;
  444.   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  445.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  446.   *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
  447.   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  448.   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
  449.   esac
  450. done
  451.  
  452. # NLS nuisances.
  453. # Only set LANG and LC_ALL to C if already set.
  454. # These must not be set unconditionally because not all systems understand
  455. # e.g. LANG=C (notably SCO).
  456. if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
  457. if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
  458.  
  459. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  460. rm -rf conftest* confdefs.h
  461. # AIX cpp loses on an empty file, so make sure it contains at least a newline.
  462. echo > confdefs.h
  463.  
  464. # A filename unique to this package, relative to the directory that
  465. # configure is in, which we can look for to find out if srcdir is correct.
  466. ac_unique_file=kpathsea/kpathsea.texi
  467.  
  468. # Find the source files, if location was not specified.
  469. if test -z "$srcdir"; then
  470.   ac_srcdir_defaulted=yes
  471.   # Try the directory containing this script, then its parent.
  472.   ac_prog=$0
  473.   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  474.   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  475.   srcdir=$ac_confdir
  476.   if test ! -r $srcdir/$ac_unique_file; then
  477.     srcdir=..
  478.   fi
  479. else
  480.   ac_srcdir_defaulted=no
  481. fi
  482. if test ! -r $srcdir/$ac_unique_file; then
  483.   if test "$ac_srcdir_defaulted" = yes; then
  484.     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
  485.   else
  486.     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
  487.   fi
  488. fi
  489. srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
  490.  
  491. # Prefer explicitly selected file to automatically selected ones.
  492. if test -z "$CONFIG_SITE"; then
  493.   if test "x$prefix" != xNONE; then
  494.     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
  495.   else
  496.     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  497.   fi
  498. fi
  499. for ac_site_file in $CONFIG_SITE; do
  500.   if test -r "$ac_site_file"; then
  501.     echo "loading site script $ac_site_file"
  502.     . "$ac_site_file"
  503.   fi
  504. done
  505.  
  506. if test -r "$cache_file"; then
  507.   echo "loading cache $cache_file"
  508.   . $cache_file
  509. else
  510.   echo "creating cache $cache_file"
  511.   > $cache_file
  512. fi
  513.  
  514. ac_ext=c
  515. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  516. ac_cpp='$CPP $CPPFLAGS'
  517. ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  518. ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  519.  
  520. if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
  521.   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  522.   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
  523.     ac_n= ac_c='
  524. ' ac_t='    '
  525.   else
  526.     ac_n=-n ac_c= ac_t=
  527.   fi
  528. else
  529.   ac_n= ac_c='\c' ac_t=
  530. fi
  531.  
  532.  
  533.  
  534. echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
  535. set dummy ${MAKE-make}; ac_make=$2
  536. if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
  537.   echo $ac_n "(cached) $ac_c" 1>&6
  538. else
  539.   cat > conftestmake <<\EOF
  540. all:
  541.     @echo 'ac_maketemp="${MAKE}"'
  542. EOF
  543. # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
  544. eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
  545. if test -n "$ac_maketemp"; then
  546.   eval ac_cv_prog_make_${ac_make}_set=yes
  547. else
  548.   eval ac_cv_prog_make_${ac_make}_set=no
  549. fi
  550. rm -f conftestmake
  551. fi
  552. if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
  553.   echo "$ac_t""yes" 1>&6
  554.   SET_MAKE=
  555. else
  556.   echo "$ac_t""no" 1>&6
  557.   SET_MAKE="MAKE=${MAKE-make}"
  558. fi
  559.  
  560.  
  561. # Extract the first word of "gcc", so it can be a program name with args.
  562. set dummy gcc; ac_word=$2
  563. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  564. if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
  565.   echo $ac_n "(cached) $ac_c" 1>&6
  566. else
  567.   if test -n "$CC"; then
  568.   ac_cv_prog_CC="$CC" # Let the user override the test.
  569. else
  570.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  571.   for ac_dir in $PATH; do
  572.     test -z "$ac_dir" && ac_dir=.
  573.     if test -f $ac_dir/$ac_word; then
  574.       ac_cv_prog_CC="gcc"
  575.       break
  576.     fi
  577.   done
  578.   IFS="$ac_save_ifs"
  579. fi
  580. fi
  581. CC="$ac_cv_prog_CC"
  582. if test -n "$CC"; then
  583.   echo "$ac_t""$CC" 1>&6
  584. else
  585.   echo "$ac_t""no" 1>&6
  586. fi
  587.  
  588. if test -z "$CC"; then
  589.   # Extract the first word of "cc", so it can be a program name with args.
  590. set dummy cc; ac_word=$2
  591. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  592. if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
  593.   echo $ac_n "(cached) $ac_c" 1>&6
  594. else
  595.   if test -n "$CC"; then
  596.   ac_cv_prog_CC="$CC" # Let the user override the test.
  597. else
  598.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  599.   ac_prog_rejected=no
  600.   for ac_dir in $PATH; do
  601.     test -z "$ac_dir" && ac_dir=.
  602.     if test -f $ac_dir/$ac_word; then
  603.       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
  604.         ac_prog_rejected=yes
  605.     continue
  606.       fi
  607.       ac_cv_prog_CC="cc"
  608.       break
  609.     fi
  610.   done
  611.   IFS="$ac_save_ifs"
  612. if test $ac_prog_rejected = yes; then
  613.   # We found a bogon in the path, so make sure we never use it.
  614.   set dummy $ac_cv_prog_CC
  615.   shift
  616.   if test $# -gt 0; then
  617.     # We chose a different compiler from the bogus one.
  618.     # However, it has the same basename, so the bogon will be chosen
  619.     # first if we set CC to just the basename; use the full file name.
  620.     shift
  621.     set dummy "$ac_dir/$ac_word" "$@"
  622.     shift
  623.     ac_cv_prog_CC="$@"
  624.   fi
  625. fi
  626. fi
  627. fi
  628. CC="$ac_cv_prog_CC"
  629. if test -n "$CC"; then
  630.   echo "$ac_t""$CC" 1>&6
  631. else
  632.   echo "$ac_t""no" 1>&6
  633. fi
  634.  
  635.   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
  636. fi
  637.  
  638. echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
  639. if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
  640.   echo $ac_n "(cached) $ac_c" 1>&6
  641. else
  642.   cat > conftest.c <<EOF
  643. #ifdef __GNUC__
  644.   yes;
  645. #endif
  646. EOF
  647. if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:648: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
  648.   ac_cv_prog_gcc=yes
  649. else
  650.   ac_cv_prog_gcc=no
  651. fi
  652. fi
  653.  
  654. echo "$ac_t""$ac_cv_prog_gcc" 1>&6
  655. if test $ac_cv_prog_gcc = yes; then
  656.   GCC=yes
  657.   if test "${CFLAGS+set}" != set; then
  658.     echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
  659. if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then
  660.   echo $ac_n "(cached) $ac_c" 1>&6
  661. else
  662.   echo 'void f(){}' > conftest.c
  663. if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
  664.   ac_cv_prog_gcc_g=yes
  665. else
  666.   ac_cv_prog_gcc_g=no
  667. fi
  668. rm -f conftest*
  669.  
  670. fi
  671.  
  672. echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6
  673.     if test $ac_cv_prog_gcc_g = yes; then
  674.       CFLAGS="-g -O2"
  675.     else
  676.       CFLAGS="-O2"
  677.     fi
  678.   fi
  679. else
  680.   GCC=
  681.   test "${CFLAGS+set}" = set || CFLAGS="-g"
  682. fi
  683.  
  684.  
  685. if test "x$prefix" = xNONE; then
  686. echo $ac_n "checking for prefix by ""... $ac_c" 1>&6
  687. # Extract the first word of "tex", so it can be a program name with args.
  688. set dummy tex; ac_word=$2
  689. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  690. if eval "test \"`echo '$''{'ac_cv_path_TEX'+set}'`\" = set"; then
  691.   echo $ac_n "(cached) $ac_c" 1>&6
  692. else
  693.   case "$TEX" in
  694.   /*)
  695.   ac_cv_path_TEX="$TEX" # Let the user override the test with a path.
  696.   ;;
  697.   *)
  698.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  699.   for ac_dir in $PATH; do
  700.     test -z "$ac_dir" && ac_dir=.
  701.     if test -f $ac_dir/$ac_word; then
  702.       ac_cv_path_TEX="$ac_dir/$ac_word"
  703.       break
  704.     fi
  705.   done
  706.   IFS="$ac_save_ifs"
  707.   ;;
  708. esac
  709. fi
  710. TEX="$ac_cv_path_TEX"
  711. if test -n "$TEX"; then
  712.   echo "$ac_t""$TEX" 1>&6
  713. else
  714.   echo "$ac_t""no" 1>&6
  715. fi
  716.  
  717.   if test -n "$ac_cv_path_TEX"; then
  718.     prefix=`echo $ac_cv_path_TEX|sed 's%/[^/][^/]*//*[^/][^/]*$%%'`
  719.   fi
  720. fi
  721.  
  722.  
  723. ac_aux_dir=
  724. for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
  725.   if test -f $ac_dir/install-sh; then
  726.     ac_aux_dir=$ac_dir
  727.     ac_install_sh="$ac_aux_dir/install-sh -c"
  728.     break
  729.   elif test -f $ac_dir/install.sh; then
  730.     ac_aux_dir=$ac_dir
  731.     ac_install_sh="$ac_aux_dir/install.sh -c"
  732.     break
  733.   fi
  734. done
  735. if test -z "$ac_aux_dir"; then
  736.   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
  737. fi
  738. ac_config_guess=$ac_aux_dir/config.guess
  739. ac_config_sub=$ac_aux_dir/config.sub
  740. ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
  741.  
  742. # Find a good install program.  We prefer a C program (faster),
  743. # so one script is as good as another.  But avoid the broken or
  744. # incompatible versions:
  745. # SysV /etc/install, /usr/sbin/install
  746. # SunOS /usr/etc/install
  747. # IRIX /sbin/install
  748. # AIX /bin/install
  749. # AmigaOS /c/install
  750. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  751. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  752. # ./install, which can be erroneously created by make from ./install.sh.
  753. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
  754. if test -z "$INSTALL"; then
  755. if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
  756.   echo $ac_n "(cached) $ac_c" 1>&6
  757. else
  758.     IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  759.   for ac_dir in $PATH; do
  760.     # Account for people who put trailing slashes in PATH elements.
  761.     case "$ac_dir/" in
  762.     /|./|.//|/etc/*|/c/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
  763.     *)
  764.       # OSF1 and SCO ODT 3.0 have their own names for install.
  765.       for ac_prog in ginstall installbsd scoinst install; do
  766.         if test -f $ac_dir/$ac_prog; then
  767.       if test $ac_prog = install &&
  768.             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
  769.         # AIX install.  It has an incompatible calling convention.
  770.         # OSF/1 installbsd also uses dspmsg, but is usable.
  771.         :
  772.       else
  773.         ac_cv_path_install="$ac_dir/$ac_prog -c"
  774.         break 2
  775.       fi
  776.     fi
  777.       done
  778.       ;;
  779.     esac
  780.   done
  781.   IFS="$ac_save_ifs"
  782.  
  783. fi
  784.   if test "${ac_cv_path_install+set}" = set; then
  785.     INSTALL="$ac_cv_path_install"
  786.   else
  787.     # As a last resort, use the slow shell script.  We don't cache a
  788.     # path for INSTALL within a source directory, because that will
  789.     # break other packages using the cache if that directory is
  790.     # removed, or if the path is relative.
  791.     INSTALL="$ac_install_sh"
  792.   fi
  793. fi
  794. echo "$ac_t""$INSTALL" 1>&6
  795.  
  796. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  797. # It thinks the first close brace ends the variable substitution.
  798. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  799.  
  800. test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  801.  
  802.  
  803. subdirs="kpathsea dviljk dvipsk web2c xdvik"
  804.  
  805.  
  806. trap '' 1 2 15
  807. cat > confcache <<\EOF
  808. # This file is a shell script that caches the results of configure
  809. # tests run on this system so they can be shared between configure
  810. # scripts and configure runs.  It is not useful on other systems.
  811. # If it contains results you don't want to keep, you may remove or edit it.
  812. #
  813. # By default, configure uses ./config.cache as the cache file,
  814. # creating it if it does not exist already.  You can give configure
  815. # the --cache-file=FILE option to use a different cache file; that is
  816. # what configure does when it calls configure scripts in
  817. # subdirectories, so they share the cache.
  818. # Giving --cache-file=/dev/null disables caching, for debugging configure.
  819. # config.status only pays attention to the cache file if you give it the
  820. # --recheck option to rerun configure.
  821. #
  822. EOF
  823. # Ultrix sh set writes to stderr and can't be redirected directly,
  824. # and sets the high bit in the cache file unless we assign to the vars.
  825. (set) 2>&1 |
  826.   sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
  827.   >> confcache
  828. if cmp -s $cache_file confcache; then
  829.   :
  830. else
  831.   if test -w $cache_file; then
  832.     echo "updating cache $cache_file"
  833.     cat confcache > $cache_file
  834.   else
  835.     echo "not updating unwritable cache $cache_file"
  836.   fi
  837. fi
  838. rm -f confcache
  839.  
  840. trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
  841.  
  842. test "x$prefix" = xNONE && prefix=$ac_default_prefix
  843. # Let make expand exec_prefix.
  844. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  845.  
  846. # Any assignment to VPATH causes Sun make to only execute
  847. # the first set of double-colon rules, so remove it if not needed.
  848. # If there is a colon in the path, we need to keep it.
  849. if test "x$srcdir" = x.; then
  850.   ac_vpsub='/^[     ]*VPATH[     ]*=[^:]*$/d'
  851. fi
  852.  
  853. trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
  854.  
  855. # Transform confdefs.h into DEFS.
  856. # Protect against shell expansion while executing Makefile rules.
  857. # Protect against Makefile macro expansion.
  858. cat > conftest.defs <<\EOF
  859. s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
  860. s%[     `~#$^&*(){}\\|;'"<>?]%\\&%g
  861. s%\[%\\&%g
  862. s%\]%\\&%g
  863. s%\$%$$%g
  864. EOF
  865. DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
  866. rm -f conftest.defs
  867.  
  868.  
  869. # Without the "./", some shells look in PATH for config.status.
  870. : ${CONFIG_STATUS=./config.status}
  871.  
  872. echo creating $CONFIG_STATUS
  873. # Some systems, like AmigaOS, won't allow you to remove a script that is
  874. # being executed, so just move it out of the way instead.
  875. if test -f $CONFIG_STATUS; then mv $CONFIG_STATUS $CONFIG_STATUS.old; else true; fi
  876. cat > $CONFIG_STATUS <<EOF
  877. #! /bin/sh
  878. # Generated automatically by configure.
  879. # Run this file to recreate the current configuration.
  880. # This directory was configured as follows,
  881. # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  882. #
  883. # $0 $ac_configure_args
  884. #
  885. # Compiler output produced by configure, useful for debugging
  886. # configure, is in ./config.log if it exists.
  887.  
  888. ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
  889. for ac_option
  890. do
  891.   case "\$ac_option" in
  892.   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  893.     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
  894.     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
  895.   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
  896.     echo "$CONFIG_STATUS generated by autoconf version 2.10"
  897.     exit 0 ;;
  898.   -help | --help | --hel | --he | --h)
  899.     echo "\$ac_cs_usage"; exit 0 ;;
  900.   *) echo "\$ac_cs_usage"; exit 1 ;;
  901.   esac
  902. done
  903.  
  904. ac_given_srcdir=$srcdir
  905. ac_given_INSTALL="$INSTALL"
  906.  
  907. trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
  908. EOF
  909. cat >> $CONFIG_STATUS <<EOF
  910.  
  911. # Protect against being on the right side of a sed subst in config.status. 
  912. sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g; 
  913.  s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF
  914. $ac_vpsub
  915. $extrasub
  916. s%@CFLAGS@%$CFLAGS%g
  917. s%@CPPFLAGS@%$CPPFLAGS%g
  918. s%@CXXFLAGS@%$CXXFLAGS%g
  919. s%@DEFS@%$DEFS%g
  920. s%@LDFLAGS@%$LDFLAGS%g
  921. s%@LIBS@%$LIBS%g
  922. s%@exec_prefix@%$exec_prefix%g
  923. s%@prefix@%$prefix%g
  924. s%@program_transform_name@%$program_transform_name%g
  925. s%@bindir@%$bindir%g
  926. s%@sbindir@%$sbindir%g
  927. s%@libexecdir@%$libexecdir%g
  928. s%@datadir@%$datadir%g
  929. s%@sysconfdir@%$sysconfdir%g
  930. s%@sharedstatedir@%$sharedstatedir%g
  931. s%@localstatedir@%$localstatedir%g
  932. s%@libdir@%$libdir%g
  933. s%@includedir@%$includedir%g
  934. s%@oldincludedir@%$oldincludedir%g
  935. s%@infodir@%$infodir%g
  936. s%@guidedir@%$guidedir%g
  937. s%@psdir@%$psdir%g
  938. s%@dvidir@%$dvidir%g
  939. s%@mandir@%$mandir%g
  940. s%@SET_MAKE@%$SET_MAKE%g
  941. s%@CC@%$CC%g
  942. s%@TEX@%$TEX%g
  943. s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
  944. s%@INSTALL_DATA@%$INSTALL_DATA%g
  945. s%@subdirs@%$subdirs%g
  946.  
  947. CEOF
  948. EOF
  949. cat >> $CONFIG_STATUS <<EOF
  950.  
  951. CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
  952. EOF
  953. cat >> $CONFIG_STATUS <<\EOF
  954. for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
  955.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  956.   case "$ac_file" in
  957.   *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
  958.        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  959.   *) ac_file_in="${ac_file}.in" ;;
  960.   esac
  961.  
  962.   # Adjust relative srcdir, etc. for subdirectories.
  963.  
  964.   # Remove last slash and all that follows it.  Not all systems have dirname.
  965.   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
  966.   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
  967.     # The file is in a subdirectory.
  968.     test ! -d "$ac_dir" && mkdir "$ac_dir"
  969.     ac_dir_suffix="/$ac_dir"
  970.     # A "../" for each directory in $ac_dir_suffix.
  971.     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
  972.   else
  973.     ac_dir_suffix= ac_dots=
  974.   fi
  975.  
  976.   case "$ac_given_srcdir" in
  977.   .)  srcdir=.
  978.       if test -z "$ac_dots"; then top_srcdir=.
  979.       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
  980.   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
  981.   *) # Relative path.
  982.     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
  983.     top_srcdir="$ac_dots$ac_given_srcdir" ;;
  984.   esac
  985.  
  986.   case "$ac_given_INSTALL" in
  987.   [/$]*) INSTALL="$ac_given_INSTALL" ;;
  988.   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
  989.   esac
  990.   echo creating "$ac_file"
  991.   rm -f "$ac_file"
  992.   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
  993.   case "$ac_file" in
  994.   *Makefile*) ac_comsub="1i\\
  995. # $configure_input" ;;
  996.   *) ac_comsub= ;;
  997.   esac
  998.   # Replace lines of the form ac_include foo with the contents of foo:
  999.   # first, from the ac_include lines construct a list of sed
  1000.   # commands to remove them, and include the files; then run sed.
  1001.   # Have to use sed because old (Ultrix, SunOS) awk does not support
  1002.   # getline or system. (Anyway, configure scripts aren't supposed to use awk.)
  1003.   # Use \@...@<cmd> form of sed address because the filename may contain /.
  1004.   # Can't use only one -e and commands {dr foo} because foo has to be last.
  1005.   # Use @e initially instead of -e because GNU echo has a -e option.
  1006.   # USe `X' to mean a bunch of backslashes; this is for FreeBSD.
  1007.   file_substs=`sed -n \
  1008. "/^ac_include/s%ac_include[     ]*\(.*\)%@e 'X@^&@r \1' -e 'X@^&@d'%p" \
  1009.                $ac_given_srcdir/${ac_file}.in`
  1010.   if test -n "$file_substs"; then
  1011.     # Change @e back to -e and X@^ to \@^.
  1012.     file_subst_cmd="sed `echo $file_substs \
  1013.                          | sed -e 's/@e/-e/g' -e 's/X@^/\\\\\@^/g'`"
  1014.   else
  1015.     # If no substitutions and hence no sed commands, don't choke.
  1016.     file_subst_cmd=cat
  1017.   fi
  1018.   # cd into the srcdir because the files being included more or less
  1019.   # must be part of the distribution. I can't find any way to do
  1020.   # variable substitution in the sed commands (so the user could have,
  1021.   # e.g., $top_srcdir in their ac_include line).
  1022.   (cd $ac_given_srcdir && eval $file_subst_cmd ${ac_file}.in) \
  1023.   | sed -e "$ac_comsub
  1024. s%@configure_input@%$configure_input%g
  1025. s%@srcdir@%$srcdir%g
  1026. s%@top_srcdir@%$top_srcdir%g
  1027. s%@INSTALL@%$INSTALL%g
  1028. " -f conftest.subs > $ac_file
  1029. fi; done
  1030. rm -f conftest.subs
  1031.  
  1032.  
  1033.  
  1034. exit 0
  1035. EOF
  1036. chmod +x $CONFIG_STATUS
  1037. rm -f CONFIG.STATUS.old
  1038. rm -fr confdefs* $ac_clean_files
  1039. test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
  1040.  
  1041. if test "$no_recursion" != yes; then
  1042.  
  1043.   # Remove --cache-file and --srcdir arguments so they do not pile up.
  1044.   ac_sub_configure_args=
  1045.   ac_prev=
  1046.   for ac_arg in $ac_configure_args; do
  1047.     if test -n "$ac_prev"; then
  1048.       ac_prev=
  1049.       continue
  1050.     fi
  1051.     case "$ac_arg" in
  1052.     -cache-file | --cache-file | --cache-fil | --cache-fi \
  1053.     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  1054.       ac_prev=cache_file ;;
  1055.     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  1056.     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  1057.       ;;
  1058.     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  1059.       ac_prev=srcdir ;;
  1060.     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  1061.       ;;
  1062.     *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;;
  1063.     esac
  1064.   done
  1065.  
  1066.   for ac_config_dir in kpathsea dviljk dvipsk web2c xdvik; do
  1067.  
  1068.     # Do not complain, so a configure script can configure whichever
  1069.     # parts of a large source tree are present.
  1070.     if test ! -d $srcdir/$ac_config_dir; then
  1071.       continue
  1072.     fi
  1073.  
  1074.     echo configuring in $ac_config_dir
  1075.  
  1076.     case "$srcdir" in
  1077.     .) ;;
  1078.     *)
  1079.       if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :;
  1080.       else
  1081.         { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; }
  1082.       fi
  1083.       ;;
  1084.     esac
  1085.  
  1086.     ac_popdir=`pwd`
  1087.     cd $ac_config_dir
  1088.  
  1089.     case "$srcdir" in
  1090.     .) # No --srcdir option.  We are building in place.
  1091.       ac_sub_srcdir=$srcdir ;;
  1092.     /*) # Absolute path.
  1093.       ac_sub_srcdir=$srcdir/$ac_config_dir ;;
  1094.     *) # Relative path.
  1095.       ac_sub_srcdir=../$srcdir/$ac_config_dir ;;
  1096.     esac
  1097.  
  1098.     # Check for guested configure; otherwise get Cygnus style configure.
  1099.     if test -f $ac_sub_srcdir/configure; then
  1100.       ac_sub_configure=$ac_sub_srcdir/configure
  1101.     elif test -f $ac_sub_srcdir/configure.in; then
  1102.       ac_sub_configure=$ac_configure
  1103.     else
  1104.       echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2
  1105.       ac_sub_configure=
  1106.     fi
  1107.  
  1108.     # The recursion is here.
  1109.     if test -n "$ac_sub_configure"; then
  1110.  
  1111.       # Make the cache file name correct relative to the subdirectory.
  1112.       # A "../" for each directory in /$ac_config_dir.
  1113.       ac_dots=`echo /$ac_config_dir|sed 's%/[^/]*%../%g'`
  1114.       case "$cache_file" in
  1115.       /*) ac_sub_cache_file=$cache_file ;;
  1116.       *) # Relative path.
  1117.         ac_sub_cache_file="$ac_dots$cache_file" ;;
  1118.       esac
  1119.  
  1120.   case "$ac_given_INSTALL" in
  1121.         [/$]*) INSTALL="$ac_given_INSTALL" ;;
  1122.         *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
  1123.         esac
  1124.  
  1125.       echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir"
  1126.       # The eval makes quoting arguments work.
  1127.       if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir
  1128.       then :
  1129.       else
  1130.         { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; }
  1131.       fi
  1132.     fi
  1133.  
  1134.     cd $ac_popdir
  1135.   done
  1136. fi
  1137.  
  1138.