configure
Upload User: zlh9724
Upload Date: 2007-01-04
Package Size: 1991k
Code Size: 43k
Category:

Browser Client

Development Platform:

Unix_Linux

  1. #! /bin/sh
  2. # Guess values for system-dependent variables and create Makefiles.
  3. # Generated automatically using autoconf version 2.4 
  4. # Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
  5. #
  6. # This configure script is free software; the Free Software Foundation
  7. # gives unlimited permission to copy, distribute and modify it.
  8. # Defaults:
  9. ac_help=
  10. ac_default_prefix=/usr/local
  11. # Any additions from configure.in:
  12. ac_help="$ac_help
  13.   --enable-maxmem[=N]     enable use of temp files, set max mem usage to N MB"
  14. ac_help="$ac_help
  15. "
  16. # Initialize some variables set by options.
  17. # The variables have the same names as the options, with
  18. # dashes changed to underlines.
  19. build=NONE
  20. cache_file=./config.cache
  21. exec_prefix=NONE
  22. host=NONE
  23. no_create=
  24. nonopt=NONE
  25. no_recursion=
  26. prefix=NONE
  27. program_prefix=NONE
  28. program_suffix=NONE
  29. program_transform_name=s,x,x,
  30. silent=
  31. site=
  32. srcdir=
  33. target=NONE
  34. verbose=
  35. x_includes=NONE
  36. x_libraries=NONE
  37. # Initialize some other variables.
  38. subdirs=
  39. ac_prev=
  40. for ac_option
  41. do
  42.   # If the previous option needs an argument, assign it.
  43.   if test -n "$ac_prev"; then
  44.     eval "$ac_prev=$ac_option"
  45.     ac_prev=
  46.     continue
  47.   fi
  48.   case "$ac_option" in
  49.   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  50.   *) ac_optarg= ;;
  51.   esac
  52.   # Accept the important Cygnus configure options, so we can diagnose typos.
  53.   case "$ac_option" in
  54.   -build | --build | --buil | --bui | --bu | --b)
  55.     ac_prev=build ;;
  56.   -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
  57.     build="$ac_optarg" ;;
  58.   -cache-file | --cache-file | --cache-fil | --cache-fi 
  59.   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  60.     ac_prev=cache_file ;;
  61.   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* 
  62.   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  63.     cache_file="$ac_optarg" ;;
  64.   -disable-* | --disable-*)
  65.     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
  66.     # Reject names that are not valid shell variable names.
  67.     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
  68.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  69.     fi
  70.     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  71.     eval "enable_${ac_feature}=no" ;;
  72.   -enable-* | --enable-*)
  73.     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
  74.     # Reject names that are not valid shell variable names.
  75.     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
  76.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  77.     fi
  78.     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  79.     case "$ac_option" in
  80.       *=*) ;;
  81.       *) ac_optarg=yes ;;
  82.     esac
  83.     eval "enable_${ac_feature}='$ac_optarg'" ;;
  84.   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi 
  85.   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- 
  86.   | --exec | --exe | --ex)
  87.     ac_prev=exec_prefix ;;
  88.   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* 
  89.   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* 
  90.   | --exec=* | --exe=* | --ex=*)
  91.     exec_prefix="$ac_optarg" ;;
  92.   -gas | --gas | --ga | --g)
  93.     # Obsolete; use --with-gas.
  94.     with_gas=yes ;;
  95.   -help | --help | --hel | --he)
  96.     # Omit some internal or obsolete options to make the list less imposing.
  97.     # This message is too long to be a string in the A/UX 3.1 sh.
  98.     cat << EOF
  99. Usage: configure [options] [host]
  100. Options: [defaults in brackets after descriptions]
  101. Configuration:
  102.   --cache-file=FILE       cache test results in FILE
  103.   --help                  print this message
  104.   --no-create             do not create output files
  105.   --quiet, --silent       do not print `checking...' messages
  106.   --version               print the version of autoconf that created configure
  107. Directory and file names:
  108.   --prefix=PREFIX         install architecture-independent files in PREFIX
  109.                           [$ac_default_prefix]
  110.   --exec-prefix=PREFIX    install architecture-dependent files in PREFIX
  111.                           [same as prefix]
  112.   --srcdir=DIR            find the sources in DIR [configure dir or ..]
  113.   --program-prefix=PREFIX prepend PREFIX to installed program names
  114.   --program-suffix=SUFFIX append SUFFIX to installed program names
  115.   --program-transform-name=PROGRAM run sed PROGRAM on installed program names
  116. Host type:
  117.   --build=BUILD           configure for building on BUILD [BUILD=HOST]
  118.   --host=HOST             configure for HOST [guessed]
  119.   --target=TARGET         configure for TARGET [TARGET=HOST]
  120. Features and packages:
  121.   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  122.   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  123.   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  124.   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  125.   --x-includes=DIR        X include files are in DIR
  126.   --x-libraries=DIR       X library files are in DIR
  127. --enable and --with options recognized:$ac_help
  128. EOF
  129.     exit 0 ;;
  130.   -host | --host | --hos | --ho)
  131.     ac_prev=host ;;
  132.   -host=* | --host=* | --hos=* | --ho=*)
  133.     host="$ac_optarg" ;;
  134.   -nfp | --nfp | --nf)
  135.     # Obsolete; use --without-fp.
  136.     with_fp=no ;;
  137.   -no-create | --no-create | --no-creat | --no-crea | --no-cre 
  138.   | --no-cr | --no-c)
  139.     no_create=yes ;;
  140.   -no-recursion | --no-recursion | --no-recursio | --no-recursi 
  141.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  142.     no_recursion=yes ;;
  143.   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  144.     ac_prev=prefix ;;
  145.   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  146.     prefix="$ac_optarg" ;;
  147.   -program-prefix | --program-prefix | --program-prefi | --program-pref 
  148.   | --program-pre | --program-pr | --program-p)
  149.     ac_prev=program_prefix ;;
  150.   -program-prefix=* | --program-prefix=* | --program-prefi=* 
  151.   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  152.     program_prefix="$ac_optarg" ;;
  153.   -program-suffix | --program-suffix | --program-suffi | --program-suff 
  154.   | --program-suf | --program-su | --program-s)
  155.     ac_prev=program_suffix ;;
  156.   -program-suffix=* | --program-suffix=* | --program-suffi=* 
  157.   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  158.     program_suffix="$ac_optarg" ;;
  159.   -program-transform-name | --program-transform-name 
  160.   | --program-transform-nam | --program-transform-na 
  161.   | --program-transform-n | --program-transform- 
  162.   | --program-transform | --program-transfor 
  163.   | --program-transfo | --program-transf 
  164.   | --program-trans | --program-tran 
  165.   | --progr-tra | --program-tr | --program-t)
  166.     ac_prev=program_transform_name ;;
  167.   -program-transform-name=* | --program-transform-name=* 
  168.   | --program-transform-nam=* | --program-transform-na=* 
  169.   | --program-transform-n=* | --program-transform-=* 
  170.   | --program-transform=* | --program-transfor=* 
  171.   | --program-transfo=* | --program-transf=* 
  172.   | --program-trans=* | --program-tran=* 
  173.   | --progr-tra=* | --program-tr=* | --program-t=*)
  174.     program_transform_name="$ac_optarg" ;;
  175.   -q | -quiet | --quiet | --quie | --qui | --qu | --q 
  176.   | -silent | --silent | --silen | --sile | --sil)
  177.     silent=yes ;;
  178.   -site | --site | --sit)
  179.     ac_prev=site ;;
  180.   -site=* | --site=* | --sit=*)
  181.     site="$ac_optarg" ;;
  182.   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  183.     ac_prev=srcdir ;;
  184.   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  185.     srcdir="$ac_optarg" ;;
  186.   -target | --target | --targe | --targ | --tar | --ta | --t)
  187.     ac_prev=target ;;
  188.   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  189.     target="$ac_optarg" ;;
  190.   -v | -verbose | --verbose | --verbos | --verbo | --verb)
  191.     verbose=yes ;;
  192.   -version | --version | --versio | --versi | --vers)
  193.     echo "configure generated by autoconf version 2.4"
  194.     exit 0 ;;
  195.   -with-* | --with-*)
  196.     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
  197.     # Reject names that are not valid shell variable names.
  198.     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
  199.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  200.     fi
  201.     ac_package=`echo $ac_package| sed 's/-/_/g'`
  202.     case "$ac_option" in
  203.       *=*) ;;
  204.       *) ac_optarg=yes ;;
  205.     esac
  206.     eval "with_${ac_package}='$ac_optarg'" ;;
  207.   -without-* | --without-*)
  208.     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
  209.     # Reject names that are not valid shell variable names.
  210.     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
  211.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  212.     fi
  213.     ac_package=`echo $ac_package| sed 's/-/_/g'`
  214.     eval "with_${ac_package}=no" ;;
  215.   --x)
  216.     # Obsolete; use --with-x.
  217.     with_x=yes ;;
  218.   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu 
  219.   | --x-incl | --x-inc | --x-in | --x-i)
  220.     ac_prev=x_includes ;;
  221.   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* 
  222.   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  223.     x_includes="$ac_optarg" ;;
  224.   -x-libraries | --x-libraries | --x-librarie | --x-librari 
  225.   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  226.     ac_prev=x_libraries ;;
  227.   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* 
  228.   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  229.     x_libraries="$ac_optarg" ;;
  230.   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
  231.     ;;
  232.   *=*)
  233.     varname=`echo "$ac_option"|sed -e 's/=.*//'`
  234.     # Reject names that aren't valid shell variable names.
  235.     if test -n "`echo $varname| sed 's/[a-zA-Z0-9_]//g'`"; then
  236.       { echo "configure: error: $varname: invalid shell variable name" 1>&2; exit 1; }
  237.     fi
  238.     val="`echo "$ac_option"|sed 's/[^=]*=//'`"
  239.     test -n "$verbose" && echo " setting shell variable $varname to $val"
  240.     eval "$varname='$val'"
  241.     eval "export $varname" ;;
  242.   *) 
  243.     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
  244.       echo "configure: warning: $ac_option: invalid host type" 1>&2
  245.     fi
  246.     if test "x$nonopt" != xNONE; then
  247.       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
  248.     fi
  249.     nonopt="$ac_option"
  250.     ;;
  251.   esac
  252. done
  253. if test -n "$ac_prev"; then
  254.   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
  255. fi
  256. trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
  257. # File descriptor usage:
  258. # 0 standard input
  259. # 1 file creation
  260. # 2 errors and warnings
  261. # 3 some systems may open it to /dev/tty
  262. # 4 used on the Kubota Titan
  263. # 6 checking for... messages and results
  264. # 5 compiler messages saved in config.log
  265. if test "$silent" = yes; then
  266.   exec 6>/dev/null
  267. else
  268.   exec 6>&1
  269. fi
  270. exec 5>./config.log
  271. echo "
  272. This file contains any messages produced by compilers while
  273. running configure, to aid debugging if configure makes a mistake.
  274. " 1>&5
  275. # Strip out --no-create and --no-recursion so they do not pile up.
  276. # Also quote any args containing shell metacharacters.
  277. ac_configure_args=
  278. for ac_arg
  279. do
  280.   case "$ac_arg" in
  281.   -no-create | --no-create | --no-creat | --no-crea | --no-cre 
  282.   | --no-cr | --no-c) ;;
  283.   -no-recursion | --no-recursion | --no-recursio | --no-recursi 
  284.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  285.   *" "*|*" "*|*[[]~#$^&*(){}\|;<>?]*)
  286.   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  287.   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
  288.   esac
  289. done
  290. # NLS nuisances.
  291. # Only set LANG and LC_ALL to C if already set.
  292. # These must not be set unconditionally because not all systems understand
  293. # e.g. LANG=C (notably SCO).
  294. if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
  295. if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
  296. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  297. rm -rf conftest* confdefs.h
  298. # AIX cpp loses on an empty file, so make sure it contains at least a newline.
  299. echo > confdefs.h
  300. # A filename unique to this package, relative to the directory that
  301. # configure is in, which we can look for to find out if srcdir is correct.
  302. ac_unique_file=jcmaster.c
  303. # Find the source files, if location was not specified.
  304. if test -z "$srcdir"; then
  305.   ac_srcdir_defaulted=yes
  306.   # Try the directory containing this script, then its parent.
  307.   ac_prog=$0
  308.   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  309.   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  310.   srcdir=$ac_confdir
  311.   if test ! -r $srcdir/$ac_unique_file; then
  312.     srcdir=..
  313.   fi
  314. else
  315.   ac_srcdir_defaulted=no
  316. fi
  317. if test ! -r $srcdir/$ac_unique_file; then
  318.   if test "$ac_srcdir_defaulted" = yes; then
  319.     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
  320.   else
  321.     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
  322.   fi
  323. fi
  324. srcdir=`echo "${srcdir}" | sed 's%([^/])/*$%1%'`
  325. # Prefer explicitly selected file to automatically selected ones.
  326. if test -z "$CONFIG_SITE"; then
  327.   if test "x$prefix" != xNONE; then
  328.     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
  329.   else
  330.     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  331.   fi
  332. fi
  333. for ac_site_file in $CONFIG_SITE; do
  334.   if test -r "$ac_site_file"; then
  335.     echo "loading site script $ac_site_file"
  336.     . "$ac_site_file"
  337.   fi
  338. done
  339. ac_ext=c
  340. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  341. ac_cpp='$CPP $CPPFLAGS'
  342. ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5 2>&5'
  343. ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5 2>&5'
  344. if (echo "testingc"; echo 1,2,3) | grep c >/dev/null; then
  345.   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  346.   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
  347.     ac_n= ac_c='
  348. ' ac_t=' '
  349.   else
  350.     ac_n=-n ac_c= ac_t=
  351.   fi
  352. else
  353.   ac_n= ac_c='c' ac_t=
  354. fi
  355. # Extract the first word of "gcc", so it can be a program name with args.
  356. set dummy gcc; ac_word=$2
  357. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  358. if eval "test "`echo '$''{'ac_cv_prog_CC'+set}'`" = set"; then
  359.   echo $ac_n "(cached) $ac_c" 1>&6
  360. else
  361.   if test -n "$CC"; then
  362.   ac_cv_prog_CC="$CC" # Let the user override the test.
  363. else
  364.   IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  365.   for ac_dir in $PATH; do
  366.     test -z "$ac_dir" && ac_dir=.
  367.     if test -f $ac_dir/$ac_word; then
  368.       ac_cv_prog_CC="gcc"
  369.       break
  370.     fi
  371.   done
  372.   IFS="$ac_save_ifs"
  373.   test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc"
  374. fi
  375. fi
  376. CC="$ac_cv_prog_CC"
  377. if test -n "$CC"; then
  378.   echo "$ac_t""$CC" 1>&6
  379. else
  380.   echo "$ac_t""no" 1>&6
  381. fi
  382. echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
  383. if eval "test "`echo '$''{'ac_cv_prog_gcc'+set}'`" = set"; then
  384.   echo $ac_n "(cached) $ac_c" 1>&6
  385. else
  386.   cat > conftest.c <<EOF
  387. #ifdef __GNUC__
  388.   yes;
  389. #endif
  390. EOF
  391. if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
  392.   ac_cv_prog_gcc=yes
  393. else
  394.   ac_cv_prog_gcc=no
  395. fi
  396. fi
  397. echo "$ac_t""$ac_cv_prog_gcc" 1>&6
  398. if test $ac_cv_prog_gcc = yes; then
  399.   GCC=yes
  400. else
  401.   GCC=
  402. fi
  403. if test "${CFLAGS+set}" != set; then
  404.   echo $ac_n "checking whether ${CC-cc} accepts -O""... $ac_c" 1>&6
  405. if eval "test "`echo '$''{'ac_cv_prog_cc_o'+set}'`" = set"; then
  406.   echo $ac_n "(cached) $ac_c" 1>&6
  407. else
  408.   echo 'int f(){ return 0; }' > conftest.c
  409. if test -z "`${CC-cc} -O -c conftest.c 2>&1`"; then
  410.   ac_cv_prog_cc_o=yes
  411. else
  412.   ac_cv_prog_cc_o=no
  413. fi
  414. rm -f conftest*
  415. fi
  416.   echo "$ac_t""$ac_cv_prog_cc_o" 1>&6
  417.   if test $ac_cv_prog_cc_o = yes; then
  418.     CFLAGS="-O"
  419.   else
  420.     CFLAGS=""
  421.   fi
  422. fi
  423. echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
  424. # On Suns, sometimes $CPP names a directory.
  425. if test -n "$CPP" && test -d "$CPP"; then
  426.   CPP=
  427. fi
  428. if test -z "$CPP"; then
  429. if eval "test "`echo '$''{'ac_cv_prog_CPP'+set}'`" = set"; then
  430.   echo $ac_n "(cached) $ac_c" 1>&6
  431. else
  432.     # This must be in double quotes, not single quotes, because CPP may get
  433.   # substituted into the Makefile and "${CC-cc}" will confuse make.
  434.   CPP="${CC-cc} -E"
  435.   # On the NeXT, cc -E runs the code through the compiler's parser,
  436.   # not just through cpp.
  437.   cat > conftest.$ac_ext <<EOF
  438. #line 498 "configure"
  439. #include "confdefs.h"
  440. #include <assert.h>
  441. Syntax Error
  442. EOF
  443. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  444. ac_err=`grep -v '^ *+' conftest.out`
  445. if test -z "$ac_err"; then
  446.   :
  447. else
  448.   echo "$ac_err" >&5
  449.   rm -rf conftest*
  450.   CPP="${CC-cc} -E -traditional-cpp"
  451.   cat > conftest.$ac_ext <<EOF
  452. #line 512 "configure"
  453. #include "confdefs.h"
  454. #include <assert.h>
  455. Syntax Error
  456. EOF
  457. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  458. ac_err=`grep -v '^ *+' conftest.out`
  459. if test -z "$ac_err"; then
  460.   :
  461. else
  462.   echo "$ac_err" >&5
  463.   rm -rf conftest*
  464.   CPP=/lib/cpp
  465. fi
  466. rm -f conftest*
  467. fi
  468. rm -f conftest*
  469.   ac_cv_prog_CPP="$CPP"
  470. fi
  471.   CPP="$ac_cv_prog_CPP"
  472. else
  473.   ac_cv_prog_CPP="$CPP"
  474. fi
  475. echo "$ac_t""$CPP" 1>&6
  476. # If we cannot run a trivial program, we must be cross compiling.
  477. echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6
  478. if eval "test "`echo '$''{'ac_cv_c_cross'+set}'`" = set"; then
  479.   echo $ac_n "(cached) $ac_c" 1>&6
  480. else
  481.   if test "$cross_compiling" = yes; then
  482.   ac_cv_c_cross=yes
  483. else
  484. cat > conftest.$ac_ext <<EOF
  485. #line 546 "configure"
  486. #include "confdefs.h"
  487. main(){return(0);}
  488. EOF
  489. eval $ac_link
  490. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  491.   ac_cv_c_cross=no
  492. else
  493.   ac_cv_c_cross=yes
  494. fi
  495. fi
  496. rm -fr conftest*
  497. fi
  498. cross_compiling=$ac_cv_c_cross
  499. echo "$ac_t""$ac_cv_c_cross" 1>&6
  500. echo $ac_n "checking for function prototypes""... $ac_c" 1>&6
  501. if eval "test "`echo '$''{'ijg_cv_have_prototypes'+set}'`" = set"; then
  502.   echo $ac_n "(cached) $ac_c" 1>&6
  503. else
  504.   cat > conftest.$ac_ext <<EOF
  505. #line 567 "configure"
  506. #include "confdefs.h"
  507. int testfunction (int arg1, int * arg2); /* check prototypes */
  508. struct methods_struct { /* check method-pointer declarations */
  509.   int (*error_exit) (char *msgtext);
  510.   int (*trace_message) (char *msgtext);
  511.   int (*another_method) (void);
  512. };
  513. int testfunction (int arg1, int * arg2) /* check definitions */
  514. { return arg2[arg1]; }
  515. int test2function (void) /* check void arg list */
  516. { return 0; }
  517. int main() { return 0; }
  518. int t() {
  519.  
  520. ; return 0; }
  521. EOF
  522. if eval $ac_compile; then
  523.   rm -rf conftest*
  524.   ijg_cv_have_prototypes=yes
  525. else
  526.   rm -rf conftest*
  527.   ijg_cv_have_prototypes=no
  528. fi
  529. rm -f conftest*
  530. fi
  531. echo "$ac_t""$ijg_cv_have_prototypes" 1>&6
  532. if test $ijg_cv_have_prototypes = yes; then
  533.   cat >> confdefs.h <<EOF
  534. #define HAVE_PROTOTYPES 
  535. EOF
  536. else
  537.   echo Your compiler does not seem to know about function prototypes.
  538.   echo Perhaps it needs a special switch to enable ANSI C mode.
  539.   echo If so, we recommend running configure like this:
  540.   echo "   ./configure  CC='cc -switch'"
  541.   echo where -switch is the proper switch.
  542. fi
  543. ac_safe=`echo "stddef.h" | tr './55' '___'`
  544. echo $ac_n "checking for stddef.h""... $ac_c" 1>&6
  545. if eval "test "`echo '$''{'ac_cv_header_$ac_safe'+set}'`" = set"; then
  546.   echo $ac_n "(cached) $ac_c" 1>&6
  547. else
  548.   cat > conftest.$ac_ext <<EOF
  549. #line 615 "configure"
  550. #include "confdefs.h"
  551. #include <stddef.h>
  552. EOF
  553. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  554. ac_err=`grep -v '^ *+' conftest.out`
  555. if test -z "$ac_err"; then
  556.   rm -rf conftest*
  557.   eval "ac_cv_header_$ac_safe=yes"
  558. else
  559.   echo "$ac_err" >&5
  560.   rm -rf conftest*
  561.   eval "ac_cv_header_$ac_safe=no"
  562. fi
  563. rm -f conftest*
  564. fi
  565. if eval "test "`echo '$ac_cv_header_'$ac_safe`" = yes"; then
  566.   echo "$ac_t""yes" 1>&6
  567.   cat >> confdefs.h <<EOF
  568. #define HAVE_STDDEF_H 
  569. EOF
  570. else
  571.   echo "$ac_t""no" 1>&6
  572. fi
  573. ac_safe=`echo "stdlib.h" | tr './55' '___'`
  574. echo $ac_n "checking for stdlib.h""... $ac_c" 1>&6
  575. if eval "test "`echo '$''{'ac_cv_header_$ac_safe'+set}'`" = set"; then
  576.   echo $ac_n "(cached) $ac_c" 1>&6
  577. else
  578.   cat > conftest.$ac_ext <<EOF
  579. #line 647 "configure"
  580. #include "confdefs.h"
  581. #include <stdlib.h>
  582. EOF
  583. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  584. ac_err=`grep -v '^ *+' conftest.out`
  585. if test -z "$ac_err"; then
  586.   rm -rf conftest*
  587.   eval "ac_cv_header_$ac_safe=yes"
  588. else
  589.   echo "$ac_err" >&5
  590.   rm -rf conftest*
  591.   eval "ac_cv_header_$ac_safe=no"
  592. fi
  593. rm -f conftest*
  594. fi
  595. if eval "test "`echo '$ac_cv_header_'$ac_safe`" = yes"; then
  596.   echo "$ac_t""yes" 1>&6
  597.   cat >> confdefs.h <<EOF
  598. #define HAVE_STDLIB_H 
  599. EOF
  600. else
  601.   echo "$ac_t""no" 1>&6
  602. fi
  603. ac_safe=`echo "string.h" | tr './55' '___'`
  604. echo $ac_n "checking for string.h""... $ac_c" 1>&6
  605. if eval "test "`echo '$''{'ac_cv_header_$ac_safe'+set}'`" = set"; then
  606.   echo $ac_n "(cached) $ac_c" 1>&6
  607. else
  608.   cat > conftest.$ac_ext <<EOF
  609. #line 679 "configure"
  610. #include "confdefs.h"
  611. #include <string.h>
  612. EOF
  613. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  614. ac_err=`grep -v '^ *+' conftest.out`
  615. if test -z "$ac_err"; then
  616.   rm -rf conftest*
  617.   eval "ac_cv_header_$ac_safe=yes"
  618. else
  619.   echo "$ac_err" >&5
  620.   rm -rf conftest*
  621.   eval "ac_cv_header_$ac_safe=no"
  622. fi
  623. rm -f conftest*
  624. fi
  625. if eval "test "`echo '$ac_cv_header_'$ac_safe`" = yes"; then
  626.   echo "$ac_t""yes" 1>&6
  627.   :
  628. else
  629.   echo "$ac_t""no" 1>&6
  630. cat >> confdefs.h <<EOF
  631. #define NEED_BSD_STRINGS 
  632. EOF
  633. fi
  634. echo $ac_n "checking for size_t""... $ac_c" 1>&6
  635. cat > conftest.$ac_ext <<EOF
  636. #line 708 "configure"
  637. #include "confdefs.h"
  638. #ifdef HAVE_STDDEF_H
  639. #include <stddef.h>
  640. #endif
  641. #ifdef HAVE_STDLIB_H
  642. #include <stdlib.h>
  643. #endif
  644. #include <stdio.h>
  645. #ifdef NEED_BSD_STRINGS
  646. #include <strings.h>
  647. #else
  648. #include <string.h>
  649. #endif
  650. typedef size_t my_size_t;
  651. int main() { return 0; }
  652. int t() {
  653.  my_size_t foovar; 
  654. ; return 0; }
  655. EOF
  656. if eval $ac_compile; then
  657.   rm -rf conftest*
  658.   ijg_size_t_ok=yes
  659. else
  660.   rm -rf conftest*
  661.   ijg_size_t_ok="not ANSI, perhaps it is in sys/types.h"
  662. fi
  663. rm -f conftest*
  664. echo "$ac_t""$ijg_size_t_ok" 1>&6
  665. if test "$ijg_size_t_ok" != yes; then
  666. ac_safe=`echo "sys/types.h" | tr './55' '___'`
  667. echo $ac_n "checking for sys/types.h""... $ac_c" 1>&6
  668. if eval "test "`echo '$''{'ac_cv_header_$ac_safe'+set}'`" = set"; then
  669.   echo $ac_n "(cached) $ac_c" 1>&6
  670. else
  671.   cat > conftest.$ac_ext <<EOF
  672. #line 747 "configure"
  673. #include "confdefs.h"
  674. #include <sys/types.h>
  675. EOF
  676. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  677. ac_err=`grep -v '^ *+' conftest.out`
  678. if test -z "$ac_err"; then
  679.   rm -rf conftest*
  680.   eval "ac_cv_header_$ac_safe=yes"
  681. else
  682.   echo "$ac_err" >&5
  683.   rm -rf conftest*
  684.   eval "ac_cv_header_$ac_safe=no"
  685. fi
  686. rm -f conftest*
  687. fi
  688. if eval "test "`echo '$ac_cv_header_'$ac_safe`" = yes"; then
  689.   echo "$ac_t""yes" 1>&6
  690.   cat >> confdefs.h <<EOF
  691. #define NEED_SYS_TYPES_H 
  692. EOF
  693. cat > conftest.$ac_ext <<EOF
  694. #line 770 "configure"
  695. #include "confdefs.h"
  696. #include <sys/types.h>
  697. EOF
  698. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  699.   egrep "size_t" >/dev/null 2>&1; then
  700.   rm -rf conftest*
  701.   ijg_size_t_ok="size_t is in sys/types.h"
  702. else
  703.   rm -rf conftest*
  704.   ijg_size_t_ok=no
  705. fi
  706. rm -f conftest*
  707. else
  708.   echo "$ac_t""no" 1>&6
  709. ijg_size_t_ok=no
  710. fi
  711. echo "$ac_t""$ijg_size_t_ok" 1>&6
  712. if test "$ijg_size_t_ok" = no; then
  713.   echo Type size_t is not defined in any of the usual places.
  714.   echo Try putting '"typedef unsigned int size_t;"' in jconfig.h.
  715. fi
  716. fi
  717. echo $ac_n "checking for type unsigned char""... $ac_c" 1>&6
  718. cat > conftest.$ac_ext <<EOF
  719. #line 797 "configure"
  720. #include "confdefs.h"
  721. int main() { return 0; }
  722. int t() {
  723.  unsigned char un_char; 
  724. ; return 0; }
  725. EOF
  726. if eval $ac_compile; then
  727.   rm -rf conftest*
  728.   echo "$ac_t""yes" 1>&6
  729. cat >> confdefs.h <<EOF
  730. #define HAVE_UNSIGNED_CHAR 
  731. EOF
  732. else
  733.   rm -rf conftest*
  734.   echo "$ac_t""no" 1>&6
  735. fi
  736. rm -f conftest*
  737. echo $ac_n "checking for type unsigned short""... $ac_c" 1>&6
  738. cat > conftest.$ac_ext <<EOF
  739. #line 819 "configure"
  740. #include "confdefs.h"
  741. int main() { return 0; }
  742. int t() {
  743.  unsigned short un_short; 
  744. ; return 0; }
  745. EOF
  746. if eval $ac_compile; then
  747.   rm -rf conftest*
  748.   echo "$ac_t""yes" 1>&6
  749. cat >> confdefs.h <<EOF
  750. #define HAVE_UNSIGNED_SHORT 
  751. EOF
  752. else
  753.   rm -rf conftest*
  754.   echo "$ac_t""no" 1>&6
  755. fi
  756. rm -f conftest*
  757. echo $ac_n "checking for type void""... $ac_c" 1>&6
  758. cat > conftest.$ac_ext <<EOF
  759. #line 841 "configure"
  760. #include "confdefs.h"
  761. /* Caution: a C++ compiler will insist on valid prototypes */
  762. typedef void * void_ptr; /* check void * */
  763. #ifdef HAVE_PROTOTYPES /* check ptr to function returning void */
  764. typedef void (*void_func) (int a, int b);
  765. #else
  766. typedef void (*void_func) ();
  767. #endif
  768. #ifdef HAVE_PROTOTYPES /* check void function result */
  769. void test3function (void_ptr arg1, void_func arg2)
  770. #else
  771. void test3function (arg1, arg2)
  772.      void_ptr arg1;
  773.      void_func arg2;
  774. #endif
  775. {
  776.   char * locptr = (char *) arg1; /* check casting to and from void * */
  777.   arg1 = (void *) locptr;
  778.   (*arg2) (1, 2); /* check call of fcn returning void */
  779. }
  780. int main() { return 0; }
  781. int t() {
  782.  
  783. ; return 0; }
  784. EOF
  785. if eval $ac_compile; then
  786.   rm -rf conftest*
  787.   echo "$ac_t""yes" 1>&6
  788. else
  789.   rm -rf conftest*
  790.   echo "$ac_t""no" 1>&6
  791. cat >> confdefs.h <<EOF
  792. #define void char
  793. EOF
  794. fi
  795. rm -f conftest*
  796. echo $ac_n "checking for working const""... $ac_c" 1>&6
  797. if eval "test "`echo '$''{'ac_cv_c_const'+set}'`" = set"; then
  798.   echo $ac_n "(cached) $ac_c" 1>&6
  799. else
  800.   cat > conftest.$ac_ext <<EOF
  801. #line 887 "configure"
  802. #include "confdefs.h"
  803. int main() { return 0; }
  804. int t() {
  805. /* Ultrix mips cc rejects this.  */
  806. typedef int charset[2]; const charset x;
  807. /* SunOS 4.1.1 cc rejects this.  */
  808. char const *const *ccp;
  809. char **p;
  810. /* NEC SVR4.0.2 mips cc rejects this.  */
  811. struct point {int x, y;};
  812. static struct point const zero = {0,0};
  813. /* AIX XL C 1.02.0.0 rejects this.
  814.    It does not let you subtract one const X* pointer from another in an arm
  815.    of an if-expression whose if-part is not a constant expression */
  816. const char *g = "string";
  817. ccp = &g + (g ? g-g : 0);
  818. /* HPUX 7.0 cc rejects these. */
  819. ++ccp;
  820. p = (char**) ccp;
  821. ccp = (char const *const *) p;
  822. { /* SCO 3.2v4 cc rejects this.  */
  823.   char *t;
  824.   char const *s = 0 ? (char *) 0 : (char const *) 0;
  825.   *t++ = 0;
  826. }
  827. { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
  828.   int x[] = {25, 17};
  829.   const int *foo = &x[0];
  830.   ++foo;
  831. }
  832. { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  833.   typedef const int *iptr;
  834.   iptr p = 0;
  835.   ++p;
  836. }
  837. { /* AIX XL C 1.02.0.0 rejects this saying
  838.      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  839.   struct s { int j; const int *ap[3]; };
  840.   struct s *b; b->j = 5;
  841. }
  842. { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  843.   const int foo = 10;
  844. }
  845. ; return 0; }
  846. EOF
  847. if eval $ac_compile; then
  848.   rm -rf conftest*
  849.   ac_cv_c_const=yes
  850. else
  851.   rm -rf conftest*
  852.   ac_cv_c_const=no
  853. fi
  854. rm -f conftest*
  855. fi
  856. echo "$ac_t""$ac_cv_c_const" 1>&6
  857. if test $ac_cv_c_const = no; then
  858.   cat >> confdefs.h <<EOF
  859. #define const 
  860. EOF
  861. fi
  862. echo $ac_n "checking for inline""... $ac_c" 1>&6
  863. ijg_cv_inline=""
  864. cat > conftest.$ac_ext <<EOF
  865. #line 958 "configure"
  866. #include "confdefs.h"
  867. int main() { return 0; }
  868. int t() {
  869. } inline int foo() { return 0; }
  870. int bar() { return foo();
  871. ; return 0; }
  872. EOF
  873. if eval $ac_compile; then
  874.   rm -rf conftest*
  875.   ijg_cv_inline="inline"
  876. else
  877.   rm -rf conftest*
  878.   cat > conftest.$ac_ext <<EOF
  879. #line 973 "configure"
  880. #include "confdefs.h"
  881. int main() { return 0; }
  882. int t() {
  883. } __inline__ int foo() { return 0; }
  884. int bar() { return foo();
  885. ; return 0; }
  886. EOF
  887. if eval $ac_compile; then
  888.   rm -rf conftest*
  889.   ijg_cv_inline="__inline__"
  890. else
  891.   rm -rf conftest*
  892.   cat > conftest.$ac_ext <<EOF
  893. #line 988 "configure"
  894. #include "confdefs.h"
  895. int main() { return 0; }
  896. int t() {
  897. } __inline int foo() { return 0; }
  898. int bar() { return foo();
  899. ; return 0; }
  900. EOF
  901. if eval $ac_compile; then
  902.   rm -rf conftest*
  903.   ijg_cv_inline="__inline"
  904. fi
  905. rm -f conftest*
  906. fi
  907. rm -f conftest*
  908. fi
  909. rm -f conftest*
  910. echo "$ac_t""$ijg_cv_inline" 1>&6
  911. cat >> confdefs.h <<EOF
  912. #define INLINE $ijg_cv_inline
  913. EOF
  914. echo $ac_n "checking for broken incomplete types""... $ac_c" 1>&6
  915. cat > conftest.$ac_ext <<EOF
  916. #line 1014 "configure"
  917. #include "confdefs.h"
  918.  typedef struct undefined_structure * undef_struct_ptr; 
  919. int main() { return 0; }
  920. int t() {
  921. ; return 0; }
  922. EOF
  923. if eval $ac_compile; then
  924.   rm -rf conftest*
  925.   echo "$ac_t""ok" 1>&6
  926. else
  927.   rm -rf conftest*
  928.   echo "$ac_t""broken" 1>&6
  929. cat >> confdefs.h <<EOF
  930. #define INCOMPLETE_TYPES_BROKEN 
  931. EOF
  932. fi
  933. rm -f conftest*
  934. echo $ac_n "checking for short external names""... $ac_c" 1>&6
  935. cat > conftest.$ac_ext <<EOF
  936. #line 1036 "configure"
  937. #include "confdefs.h"
  938. int possibly_duplicate_function () { return 0; }
  939. int possibly_dupli_function () { return 1; }
  940. int main() { return 0; }
  941. int t() {
  942.  
  943. ; return 0; }
  944. EOF
  945. if eval $ac_link; then
  946.   rm -rf conftest*
  947.   echo "$ac_t""ok" 1>&6
  948. else
  949.   rm -rf conftest*
  950.   echo "$ac_t""short" 1>&6
  951. cat >> confdefs.h <<EOF
  952. #define NEED_SHORT_EXTERNAL_NAMES 
  953. EOF
  954. fi
  955. rm -f conftest*
  956. echo $ac_n "checking to see if char is signed""... $ac_c" 1>&6
  957. if test "$cross_compiling" = yes; then
  958.   echo Assuming that char is signed on target machine.
  959. echo If it is unsigned, this will be a little bit inefficient.
  960. else
  961. cat > conftest.$ac_ext <<EOF
  962. #line 1067 "configure"
  963. #include "confdefs.h"
  964. #ifdef HAVE_PROTOTYPES
  965. int is_char_signed (int arg)
  966. #else
  967. int is_char_signed (arg)
  968.      int arg;
  969. #endif
  970. {
  971.   if (arg == 189) { /* expected result for unsigned char */
  972.     return 0; /* type char is unsigned */
  973.   }
  974.   else if (arg != -67) { /* expected result for signed char */
  975.     printf("Hmm, it seems 'char' is not eight bits wide on your machine.n");
  976.     printf("I fear the JPEG software will not work at all.nn");
  977.   }
  978.   return 1; /* assume char is signed otherwise */
  979. }
  980. char signed_char_check = (char) (-67);
  981. main() {
  982.   exit(is_char_signed((int) signed_char_check));
  983. }
  984. EOF
  985. eval $ac_link
  986. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  987.   echo "$ac_t""no" 1>&6
  988. cat >> confdefs.h <<EOF
  989. #define CHAR_IS_UNSIGNED 
  990. EOF
  991. else
  992.   echo "$ac_t""yes" 1>&6
  993. fi
  994. fi
  995. rm -fr conftest*
  996. echo $ac_n "checking to see if right shift is signed""... $ac_c" 1>&6
  997. if test "$cross_compiling" = yes; then
  998.   echo "$ac_t""Assuming that right shift is signed on target machine." 1>&6
  999. else
  1000. cat > conftest.$ac_ext <<EOF
  1001. #line 1108 "configure"
  1002. #include "confdefs.h"
  1003. #ifdef HAVE_PROTOTYPES
  1004. int is_shifting_signed (long arg)
  1005. #else
  1006. int is_shifting_signed (arg)
  1007.      long arg;
  1008. #endif
  1009. /* See whether right-shift on a long is signed or not. */
  1010. {
  1011.   long res = arg >> 4;
  1012.   if (res == -0x7F7E80CL) { /* expected result for signed shift */
  1013.     return 1; /* right shift is signed */
  1014.   }
  1015.   /* see if unsigned-shift hack will fix it. */
  1016.   /* we can't just test exact value since it depends on width of long... */
  1017.   res |= (~0L) << (32-4);
  1018.   if (res == -0x7F7E80CL) { /* expected result now? */
  1019.     return 0; /* right shift is unsigned */
  1020.   }
  1021.   printf("Right shift isn't acting as I expect it to.n");
  1022.   printf("I fear the JPEG software will not work at all.nn");
  1023.   return 0; /* try it with unsigned anyway */
  1024. }
  1025. main() {
  1026.   exit(is_shifting_signed(-0x7F7E80B1L));
  1027. }
  1028. EOF
  1029. eval $ac_link
  1030. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1031.   echo "$ac_t""no" 1>&6
  1032. cat >> confdefs.h <<EOF
  1033. #define RIGHT_SHIFT_IS_UNSIGNED 
  1034. EOF
  1035. else
  1036.   echo "$ac_t""yes" 1>&6
  1037. fi
  1038. fi
  1039. rm -fr conftest*
  1040. echo $ac_n "checking to see if fopen accepts b spec""... $ac_c" 1>&6
  1041. if test "$cross_compiling" = yes; then
  1042.   echo "$ac_t""Assuming that it does." 1>&6
  1043. else
  1044. cat > conftest.$ac_ext <<EOF
  1045. #line 1155 "configure"
  1046. #include "confdefs.h"
  1047. #include <stdio.h>
  1048. main() {
  1049.   if (fopen("conftestdata", "wb") != NULL)
  1050.     exit(0);
  1051.   exit(1);
  1052. }
  1053. EOF
  1054. eval $ac_link
  1055. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1056.   echo "$ac_t""yes" 1>&6
  1057. else
  1058.   echo "$ac_t""no" 1>&6
  1059. cat >> confdefs.h <<EOF
  1060. #define DONT_USE_B_MODE 
  1061. EOF
  1062. fi
  1063. fi
  1064. rm -fr conftest*
  1065. # Find a good install program.  We prefer a C program (faster),
  1066. # so one script is as good as another.  But avoid the broken or
  1067. # incompatible versions:
  1068. # SysV /etc/install, /usr/sbin/install
  1069. # SunOS /usr/etc/install
  1070. # IRIX /sbin/install
  1071. # AIX /bin/install
  1072. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  1073. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  1074. # ./install, which can be erroneously created by make from ./install.sh.
  1075. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
  1076. if test -z "$INSTALL"; then
  1077. if eval "test "`echo '$''{'ijg_cv_path_install'+set}'`" = set"; then
  1078.   echo $ac_n "(cached) $ac_c" 1>&6
  1079. else
  1080.     IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  1081.   for ac_dir in $PATH; do
  1082.     # Account for people who put trailing slashes in PATH elements.
  1083.     case "$ac_dir/" in
  1084.     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
  1085.     *)
  1086.       # OSF1 and SCO ODT 3.0 have their own names for install.
  1087.       for ac_prog in ginstall installbsd scoinst install; do
  1088.         if test -f $ac_dir/$ac_prog; then
  1089.   if test $ac_prog = install &&
  1090.             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
  1091.     # AIX install.  It has an incompatible calling convention.
  1092.     # OSF/1 installbsd also uses dspmsg, but is usable.
  1093.     :
  1094.   else
  1095.     ijg_cv_path_install="$ac_dir/$ac_prog -c"
  1096.     break 2
  1097.   fi
  1098. fi
  1099.       done
  1100.       ;;
  1101.     esac
  1102.   done
  1103.   IFS="$ac_save_ifs"
  1104.   # As a last resort, use cp
  1105.   test -z "$ijg_cv_path_install" && ijg_cv_path_install="cp"
  1106. fi
  1107.   INSTALL="$ijg_cv_path_install"
  1108. fi
  1109. echo "$ac_t""$INSTALL" 1>&6
  1110. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  1111. # It thinks the first close brace ends the variable substitution.
  1112. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  1113. if test -z "$INSTALL_DATA"; then
  1114.   if test "$INSTALL" = cp; then
  1115.     INSTALL_DATA='${INSTALL}'
  1116.   else
  1117.     INSTALL_DATA='${INSTALL} -m 644'
  1118.   fi
  1119. fi
  1120. # Extract the first word of "ranlib", so it can be a program name with args.
  1121. set dummy ranlib; ac_word=$2
  1122. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  1123. if eval "test "`echo '$''{'ac_cv_prog_RANLIB'+set}'`" = set"; then
  1124.   echo $ac_n "(cached) $ac_c" 1>&6
  1125. else
  1126.   if test -n "$RANLIB"; then
  1127.   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  1128. else
  1129.   IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  1130.   for ac_dir in $PATH; do
  1131.     test -z "$ac_dir" && ac_dir=.
  1132.     if test -f $ac_dir/$ac_word; then
  1133.       ac_cv_prog_RANLIB="ranlib"
  1134.       break
  1135.     fi
  1136.   done
  1137.   IFS="$ac_save_ifs"
  1138.   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
  1139. fi
  1140. fi
  1141. RANLIB="$ac_cv_prog_RANLIB"
  1142. if test -n "$RANLIB"; then
  1143.   echo "$ac_t""$RANLIB" 1>&6
  1144. else
  1145.   echo "$ac_t""no" 1>&6
  1146. fi
  1147. MEMORYMGR="jmemnobs.o"
  1148. MAXMEM="no"
  1149. # Check whether --enable-maxmem or --disable-maxmem was given.
  1150. enableval="$enable_maxmem"
  1151. if test -n "$enableval"; then
  1152.   MAXMEM="$enableval"
  1153. fi
  1154. # support --with-maxmem for backwards compatibility with IJG V5.
  1155. # Check whether --with-maxmem or --without-maxmem was given.
  1156. withval="$with_maxmem"
  1157. if test -n "$withval"; then
  1158.   MAXMEM="$withval"
  1159. fi
  1160. if test "x$MAXMEM" = xyes; then
  1161.   MAXMEM=1
  1162. fi
  1163. if test "x$MAXMEM" != xno; then
  1164.   if test -n "`echo $MAXMEM | sed 's/[0-9]//g'`"; then
  1165.     { echo "configure: error: non-numeric argument to --enable-maxmem" 1>&2; exit 1; }
  1166.   fi
  1167.   DEFAULTMAXMEM=`expr $MAXMEM * 1048576`
  1168. cat >> confdefs.h <<EOF
  1169. #define DEFAULT_MAX_MEM ${DEFAULTMAXMEM}
  1170. EOF
  1171. echo $ac_n "checking for 'tmpfile()'""... $ac_c" 1>&6
  1172. cat > conftest.$ac_ext <<EOF
  1173. #line 1293 "configure"
  1174. #include "confdefs.h"
  1175. #include <stdio.h>
  1176. int main() { return 0; }
  1177. int t() {
  1178.  FILE * tfile = tmpfile(); 
  1179. ; return 0; }
  1180. EOF
  1181. if eval $ac_link; then
  1182.   rm -rf conftest*
  1183.   echo "$ac_t""yes" 1>&6
  1184. MEMORYMGR="jmemansi.o"
  1185. else
  1186.   rm -rf conftest*
  1187.   echo "$ac_t""no" 1>&6
  1188. MEMORYMGR="jmemname.o"
  1189. cat >> confdefs.h <<EOF
  1190. #define NEED_SIGNAL_CATCHER 
  1191. EOF
  1192. echo $ac_n "checking for 'mktemp()'""... $ac_c" 1>&6
  1193. cat > conftest.$ac_ext <<EOF
  1194. #line 1314 "configure"
  1195. #include "confdefs.h"
  1196. int main() { return 0; }
  1197. int t() {
  1198.  char fname[80]; mktemp(fname); 
  1199. ; return 0; }
  1200. EOF
  1201. if eval $ac_link; then
  1202.   rm -rf conftest*
  1203.   echo "$ac_t""yes" 1>&6
  1204. else
  1205.   rm -rf conftest*
  1206.   echo "$ac_t""no" 1>&6
  1207. cat >> confdefs.h <<EOF
  1208. #define NO_MKTEMP 
  1209. EOF
  1210. fi
  1211. rm -f conftest*
  1212. fi
  1213. rm -f conftest*
  1214. fi
  1215. # Prepare to massage makefile.cfg correctly.
  1216. if test $ijg_cv_have_prototypes = yes; then
  1217.   ANSI2KNR=""
  1218.   ISANSICOM="# "
  1219. else
  1220.   ANSI2KNR="ansi2knr"
  1221.   ISANSICOM=""
  1222. fi
  1223. # ansi2knr needs -DBSD if string.h is missing
  1224. if test $ac_cv_header_string_h = no; then
  1225.   ANSI2KNRFLAGS="-DBSD"
  1226. else
  1227.   ANSI2KNRFLAGS=""
  1228. fi
  1229. # Set up -I directives
  1230. if test "x$srcdir" = x.; then
  1231.   INCLUDEFLAGS='-I$(srcdir)'
  1232. else
  1233.   INCLUDEFLAGS='-I. -I$(srcdir)'
  1234. fi
  1235. trap '' 1 2 15
  1236. trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
  1237. test "x$prefix" = xNONE && prefix=$ac_default_prefix
  1238. # Let make expand exec_prefix.
  1239. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  1240. # Any assignment to VPATH causes Sun make to only execute
  1241. # the first set of double-colon rules, so remove it if not needed.
  1242. # If there is a colon in the path, we need to keep it.
  1243. if test "x$srcdir" = x.; then
  1244.   ac_vpsub='/^[  ]*VPATH[  ]*=[^:]*$/d'
  1245. fi
  1246. trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
  1247. DEFS=-DHAVE_CONFIG_H
  1248. # Without the "./", some shells look in PATH for config.status.
  1249. : ${CONFIG_STATUS=./config.status}
  1250. echo creating $CONFIG_STATUS
  1251. rm -f $CONFIG_STATUS
  1252. cat > $CONFIG_STATUS <<EOF
  1253. #! /bin/sh
  1254. # Generated automatically by configure.
  1255. # Run this file to recreate the current configuration.
  1256. # This directory was configured as follows,
  1257. # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  1258. #
  1259. # $0 $ac_configure_args
  1260. #
  1261. # Compiler output produced by configure, useful for debugging
  1262. # configure, is in ./config.log if it exists.
  1263. ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
  1264. for ac_option
  1265. do
  1266.   case "$ac_option" in
  1267.   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  1268.     echo "running ${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
  1269.     exec ${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
  1270.   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
  1271.     echo "$CONFIG_STATUS generated by autoconf version 2.4"
  1272.     exit 0 ;;
  1273.   -help | --help | --hel | --he | --h)
  1274.     echo "$ac_cs_usage"; exit 0 ;;
  1275.   *) echo "$ac_cs_usage"; exit 1 ;;
  1276.   esac
  1277. done
  1278. ac_given_srcdir=$srcdir
  1279. trap 'rm -fr `echo "Makefile:makefile.cfg jconfig.h:jconfig.cfg" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
  1280. # Protect against being on the right side of a sed subst in config.status. 
  1281. sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\&%]/\\&/g; 
  1282.  s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<CEOF
  1283. $ac_vpsub
  1284. $extrasub
  1285. s%@CFLAGS@%$CFLAGS%g
  1286. s%@CPPFLAGS@%$CPPFLAGS%g
  1287. s%@CXXFLAGS@%$CXXFLAGS%g
  1288. s%@DEFS@%$DEFS%g
  1289. s%@LDFLAGS@%$LDFLAGS%g
  1290. s%@LIBS@%$LIBS%g
  1291. s%@exec_prefix@%$exec_prefix%g
  1292. s%@prefix@%$prefix%g
  1293. s%@program_transform_name@%$program_transform_name%g
  1294. s%@CC@%$CC%g
  1295. s%@CPP@%$CPP%g
  1296. s%@INSTALL@%$INSTALL%g
  1297. s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
  1298. s%@INSTALL_DATA@%$INSTALL_DATA%g
  1299. s%@RANLIB@%$RANLIB%g
  1300. s%@MEMORYMGR@%$MEMORYMGR%g
  1301. s%@ANSI2KNR@%$ANSI2KNR%g
  1302. s%@ISANSICOM@%$ISANSICOM%g
  1303. s%@ANSI2KNRFLAGS@%$ANSI2KNRFLAGS%g
  1304. s%@INCLUDEFLAGS@%$INCLUDEFLAGS%g
  1305. CEOF
  1306. EOF
  1307. cat >> $CONFIG_STATUS <<EOF
  1308. CONFIG_FILES=${CONFIG_FILES-"Makefile:makefile.cfg"}
  1309. EOF
  1310. cat >> $CONFIG_STATUS <<EOF
  1311. for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
  1312.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  1313.   case "$ac_file" in
  1314.   *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
  1315.        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  1316.   *) ac_file_in="${ac_file}.in" ;;
  1317.   esac
  1318.   # Adjust relative srcdir, etc. for subdirectories.
  1319.   # Remove last slash and all that follows it.  Not all systems have dirname.
  1320.   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
  1321.   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
  1322.     # The file is in a subdirectory.
  1323.     test ! -d "$ac_dir" && mkdir "$ac_dir"
  1324.     ac_dir_suffix="/`echo $ac_dir|sed 's%^./%%'`"
  1325.     # A "../" for each directory in $ac_dir_suffix.
  1326.     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
  1327.   else
  1328.     ac_dir_suffix= ac_dots=
  1329.   fi
  1330.   case "$ac_given_srcdir" in
  1331.   .)  srcdir=.
  1332.       if test -z "$ac_dots"; then top_srcdir=.
  1333.       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
  1334.   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
  1335.   *) # Relative path.
  1336.     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
  1337.     top_srcdir="$ac_dots$ac_given_srcdir" ;;
  1338.   esac
  1339.   echo creating "$ac_file"
  1340.   rm -f "$ac_file"
  1341.   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
  1342.   case "$ac_file" in
  1343.   *Makefile*) ac_comsub="1i\
  1344. # $configure_input" ;;
  1345.   *) ac_comsub= ;;
  1346.   esac
  1347.   sed -e "$ac_comsub
  1348. s%@configure_input@%$configure_input%g
  1349. s%@srcdir@%$srcdir%g
  1350. s%@top_srcdir@%$top_srcdir%g
  1351. " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
  1352. fi; done
  1353. rm -f conftest.subs
  1354. # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
  1355. # NAME is the cpp macro being defined and VALUE is the value it is being given.
  1356. #
  1357. # ac_d sets the value in "#define NAME VALUE" lines.
  1358. ac_dA='s%^([  ]*)#([  ]*define[  ][  ]*)'
  1359. ac_dB='([  ][  ]*)[^  ]*%1#2'
  1360. ac_dC='3'
  1361. ac_dD='%g'
  1362. # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
  1363. ac_uA='s%^([  ]*)#([  ]*)undef([  ][  ]*)'
  1364. ac_uB='([  ])%1#2define3'
  1365. ac_uC=' '
  1366. ac_uD='4%g'
  1367. # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
  1368. ac_eA='s%^([  ]*)#([  ]*)undef([  ][  ]*)'
  1369. ac_eB='$%1#2define3'
  1370. ac_eC=' '
  1371. ac_eD='%g'
  1372. CONFIG_HEADERS=${CONFIG_HEADERS-"jconfig.h:jconfig.cfg"}
  1373. for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
  1374.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  1375.   case "$ac_file" in
  1376.   *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
  1377.        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  1378.   *) ac_file_in="${ac_file}.in" ;;
  1379.   esac
  1380.   echo creating $ac_file
  1381.   rm -f conftest.frag conftest.in conftest.out
  1382.   cp $ac_given_srcdir/$ac_file_in conftest.in
  1383. EOF
  1384. # Transform confdefs.h into a sed script conftest.vals that substitutes
  1385. # the proper values into config.h.in to produce config.h.  And first:
  1386. # Protect against being on the right side of a sed subst in config.status. 
  1387. # Protect against being in an unquoted here document in config.status.
  1388. rm -f conftest.vals
  1389. cat > conftest.hdr <<EOF
  1390. s/[\&%]/\&/g
  1391. s%[\$`]%\&%g
  1392. s%#define ([A-Za-z_][A-Za-z0-9_]*) (.*)%${ac_dA}1${ac_dB}1${ac_dC}2${ac_dD}%gp
  1393. s%ac_d%ac_u%gp
  1394. s%ac_u%ac_e%gp
  1395. EOF
  1396. sed -n -f conftest.hdr confdefs.h > conftest.vals
  1397. rm -f conftest.hdr
  1398. # This sed command replaces #undef with comments.  This is necessary, for
  1399. # example, in the case of _POSIX_SOURCE, which is predefined and required
  1400. # on some systems where configure will not decide to define it.
  1401. cat >> conftest.vals <<EOF
  1402. EOF
  1403. # Break up conftest.vals because some shells have a limit on
  1404. # the size of here documents, and old seds have small limits too.
  1405. # Maximum number of lines to put in a single here document.
  1406. ac_max_here_lines=12
  1407. rm -f conftest.tail
  1408. while :
  1409. do
  1410.   ac_lines=`grep -c . conftest.vals`
  1411.   # grep -c gives empty output for an empty file on some AIX systems.
  1412.   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
  1413.   # Write a limited-size here document to conftest.frag.
  1414.   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
  1415.   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
  1416.   echo 'CEOF
  1417.   sed -f conftest.frag conftest.in > conftest.out
  1418.   rm -f conftest.in
  1419.   mv conftest.out conftest.in
  1420. ' >> $CONFIG_STATUS
  1421.   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
  1422.   rm -f conftest.vals
  1423.   mv conftest.tail conftest.vals
  1424. done
  1425. rm -f conftest.vals
  1426. cat >> $CONFIG_STATUS <<EOF
  1427.   rm -f conftest.frag conftest.h
  1428.   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
  1429.   cat conftest.in >> conftest.h
  1430.   rm -f conftest.in
  1431.   if cmp -s $ac_file conftest.h 2>/dev/null; then
  1432.     echo "$ac_file is unchanged"
  1433.     rm -f conftest.h
  1434.   else
  1435.     rm -f $ac_file
  1436.     mv conftest.h $ac_file
  1437.   fi
  1438. fi; done
  1439. exit 0
  1440. EOF
  1441. chmod +x $CONFIG_STATUS
  1442. rm -fr confdefs* $ac_clean_files
  1443. test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1