Generated from configure.in
[swftools.git] / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13 
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 ac_help="$ac_help
15   --with-x                use the X Window System"
16
17 # Initialize some variables set by options.
18 # The variables have the same names as the options, with
19 # dashes changed to underlines.
20 build=NONE
21 cache_file=./config.cache
22 exec_prefix=NONE
23 host=NONE
24 no_create=
25 nonopt=NONE
26 no_recursion=
27 prefix=NONE
28 program_prefix=NONE
29 program_suffix=NONE
30 program_transform_name=s,x,x,
31 silent=
32 site=
33 srcdir=
34 target=NONE
35 verbose=
36 x_includes=NONE
37 x_libraries=NONE
38 bindir='${exec_prefix}/bin'
39 sbindir='${exec_prefix}/sbin'
40 libexecdir='${exec_prefix}/libexec'
41 datadir='${prefix}/share'
42 sysconfdir='${prefix}/etc'
43 sharedstatedir='${prefix}/com'
44 localstatedir='${prefix}/var'
45 libdir='${exec_prefix}/lib'
46 includedir='${prefix}/include'
47 oldincludedir='/usr/include'
48 infodir='${prefix}/info'
49 mandir='${prefix}/man'
50
51 # Initialize some other variables.
52 subdirs=
53 MFLAGS= MAKEFLAGS=
54 SHELL=${CONFIG_SHELL-/bin/sh}
55 # Maximum number of lines to put in a shell here document.
56 ac_max_here_lines=12
57
58 ac_prev=
59 for ac_option
60 do
61
62   # If the previous option needs an argument, assign it.
63   if test -n "$ac_prev"; then
64     eval "$ac_prev=\$ac_option"
65     ac_prev=
66     continue
67   fi
68
69   case "$ac_option" in
70   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
71   *) ac_optarg= ;;
72   esac
73
74   # Accept the important Cygnus configure options, so we can diagnose typos.
75
76   case "$ac_option" in
77
78   -bindir | --bindir | --bindi | --bind | --bin | --bi)
79     ac_prev=bindir ;;
80   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
81     bindir="$ac_optarg" ;;
82
83   -build | --build | --buil | --bui | --bu)
84     ac_prev=build ;;
85   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
86     build="$ac_optarg" ;;
87
88   -cache-file | --cache-file | --cache-fil | --cache-fi \
89   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
90     ac_prev=cache_file ;;
91   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
92   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
93     cache_file="$ac_optarg" ;;
94
95   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
96     ac_prev=datadir ;;
97   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
98   | --da=*)
99     datadir="$ac_optarg" ;;
100
101   -disable-* | --disable-*)
102     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
103     # Reject names that are not valid shell variable names.
104     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
105       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
106     fi
107     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
108     eval "enable_${ac_feature}=no" ;;
109
110   -enable-* | --enable-*)
111     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
112     # Reject names that are not valid shell variable names.
113     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
114       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
115     fi
116     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
117     case "$ac_option" in
118       *=*) ;;
119       *) ac_optarg=yes ;;
120     esac
121     eval "enable_${ac_feature}='$ac_optarg'" ;;
122
123   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
124   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
125   | --exec | --exe | --ex)
126     ac_prev=exec_prefix ;;
127   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
128   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
129   | --exec=* | --exe=* | --ex=*)
130     exec_prefix="$ac_optarg" ;;
131
132   -gas | --gas | --ga | --g)
133     # Obsolete; use --with-gas.
134     with_gas=yes ;;
135
136   -help | --help | --hel | --he)
137     # Omit some internal or obsolete options to make the list less imposing.
138     # This message is too long to be a string in the A/UX 3.1 sh.
139     cat << EOF
140 Usage: configure [options] [host]
141 Options: [defaults in brackets after descriptions]
142 Configuration:
143   --cache-file=FILE       cache test results in FILE
144   --help                  print this message
145   --no-create             do not create output files
146   --quiet, --silent       do not print \`checking...' messages
147   --version               print the version of autoconf that created configure
148 Directory and file names:
149   --prefix=PREFIX         install architecture-independent files in PREFIX
150                           [$ac_default_prefix]
151   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
152                           [same as prefix]
153   --bindir=DIR            user executables in DIR [EPREFIX/bin]
154   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
155   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
156   --datadir=DIR           read-only architecture-independent data in DIR
157                           [PREFIX/share]
158   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
159   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
160                           [PREFIX/com]
161   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
162   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
163   --includedir=DIR        C header files in DIR [PREFIX/include]
164   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
165   --infodir=DIR           info documentation in DIR [PREFIX/info]
166   --mandir=DIR            man documentation in DIR [PREFIX/man]
167   --srcdir=DIR            find the sources in DIR [configure dir or ..]
168   --program-prefix=PREFIX prepend PREFIX to installed program names
169   --program-suffix=SUFFIX append SUFFIX to installed program names
170   --program-transform-name=PROGRAM
171                           run sed PROGRAM on installed program names
172 EOF
173     cat << EOF
174 Host type:
175   --build=BUILD           configure for building on BUILD [BUILD=HOST]
176   --host=HOST             configure for HOST [guessed]
177   --target=TARGET         configure for TARGET [TARGET=HOST]
178 Features and packages:
179   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
180   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
181   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
182   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
183   --x-includes=DIR        X include files are in DIR
184   --x-libraries=DIR       X library files are in DIR
185 EOF
186     if test -n "$ac_help"; then
187       echo "--enable and --with options recognized:$ac_help"
188     fi
189     exit 0 ;;
190
191   -host | --host | --hos | --ho)
192     ac_prev=host ;;
193   -host=* | --host=* | --hos=* | --ho=*)
194     host="$ac_optarg" ;;
195
196   -includedir | --includedir | --includedi | --included | --include \
197   | --includ | --inclu | --incl | --inc)
198     ac_prev=includedir ;;
199   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
200   | --includ=* | --inclu=* | --incl=* | --inc=*)
201     includedir="$ac_optarg" ;;
202
203   -infodir | --infodir | --infodi | --infod | --info | --inf)
204     ac_prev=infodir ;;
205   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
206     infodir="$ac_optarg" ;;
207
208   -libdir | --libdir | --libdi | --libd)
209     ac_prev=libdir ;;
210   -libdir=* | --libdir=* | --libdi=* | --libd=*)
211     libdir="$ac_optarg" ;;
212
213   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
214   | --libexe | --libex | --libe)
215     ac_prev=libexecdir ;;
216   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
217   | --libexe=* | --libex=* | --libe=*)
218     libexecdir="$ac_optarg" ;;
219
220   -localstatedir | --localstatedir | --localstatedi | --localstated \
221   | --localstate | --localstat | --localsta | --localst \
222   | --locals | --local | --loca | --loc | --lo)
223     ac_prev=localstatedir ;;
224   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
225   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
226   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
227     localstatedir="$ac_optarg" ;;
228
229   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
230     ac_prev=mandir ;;
231   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
232     mandir="$ac_optarg" ;;
233
234   -nfp | --nfp | --nf)
235     # Obsolete; use --without-fp.
236     with_fp=no ;;
237
238   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
239   | --no-cr | --no-c)
240     no_create=yes ;;
241
242   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
243   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
244     no_recursion=yes ;;
245
246   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
247   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
248   | --oldin | --oldi | --old | --ol | --o)
249     ac_prev=oldincludedir ;;
250   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
251   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
252   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
253     oldincludedir="$ac_optarg" ;;
254
255   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
256     ac_prev=prefix ;;
257   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
258     prefix="$ac_optarg" ;;
259
260   -program-prefix | --program-prefix | --program-prefi | --program-pref \
261   | --program-pre | --program-pr | --program-p)
262     ac_prev=program_prefix ;;
263   -program-prefix=* | --program-prefix=* | --program-prefi=* \
264   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
265     program_prefix="$ac_optarg" ;;
266
267   -program-suffix | --program-suffix | --program-suffi | --program-suff \
268   | --program-suf | --program-su | --program-s)
269     ac_prev=program_suffix ;;
270   -program-suffix=* | --program-suffix=* | --program-suffi=* \
271   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
272     program_suffix="$ac_optarg" ;;
273
274   -program-transform-name | --program-transform-name \
275   | --program-transform-nam | --program-transform-na \
276   | --program-transform-n | --program-transform- \
277   | --program-transform | --program-transfor \
278   | --program-transfo | --program-transf \
279   | --program-trans | --program-tran \
280   | --progr-tra | --program-tr | --program-t)
281     ac_prev=program_transform_name ;;
282   -program-transform-name=* | --program-transform-name=* \
283   | --program-transform-nam=* | --program-transform-na=* \
284   | --program-transform-n=* | --program-transform-=* \
285   | --program-transform=* | --program-transfor=* \
286   | --program-transfo=* | --program-transf=* \
287   | --program-trans=* | --program-tran=* \
288   | --progr-tra=* | --program-tr=* | --program-t=*)
289     program_transform_name="$ac_optarg" ;;
290
291   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
292   | -silent | --silent | --silen | --sile | --sil)
293     silent=yes ;;
294
295   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
296     ac_prev=sbindir ;;
297   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
298   | --sbi=* | --sb=*)
299     sbindir="$ac_optarg" ;;
300
301   -sharedstatedir | --sharedstatedir | --sharedstatedi \
302   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
303   | --sharedst | --shareds | --shared | --share | --shar \
304   | --sha | --sh)
305     ac_prev=sharedstatedir ;;
306   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
307   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
308   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
309   | --sha=* | --sh=*)
310     sharedstatedir="$ac_optarg" ;;
311
312   -site | --site | --sit)
313     ac_prev=site ;;
314   -site=* | --site=* | --sit=*)
315     site="$ac_optarg" ;;
316
317   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
318     ac_prev=srcdir ;;
319   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
320     srcdir="$ac_optarg" ;;
321
322   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
323   | --syscon | --sysco | --sysc | --sys | --sy)
324     ac_prev=sysconfdir ;;
325   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
326   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
327     sysconfdir="$ac_optarg" ;;
328
329   -target | --target | --targe | --targ | --tar | --ta | --t)
330     ac_prev=target ;;
331   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
332     target="$ac_optarg" ;;
333
334   -v | -verbose | --verbose | --verbos | --verbo | --verb)
335     verbose=yes ;;
336
337   -version | --version | --versio | --versi | --vers)
338     echo "configure generated by autoconf version 2.13"
339     exit 0 ;;
340
341   -with-* | --with-*)
342     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
343     # Reject names that are not valid shell variable names.
344     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
345       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
346     fi
347     ac_package=`echo $ac_package| sed 's/-/_/g'`
348     case "$ac_option" in
349       *=*) ;;
350       *) ac_optarg=yes ;;
351     esac
352     eval "with_${ac_package}='$ac_optarg'" ;;
353
354   -without-* | --without-*)
355     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
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     eval "with_${ac_package}=no" ;;
362
363   --x)
364     # Obsolete; use --with-x.
365     with_x=yes ;;
366
367   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
368   | --x-incl | --x-inc | --x-in | --x-i)
369     ac_prev=x_includes ;;
370   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
371   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
372     x_includes="$ac_optarg" ;;
373
374   -x-libraries | --x-libraries | --x-librarie | --x-librari \
375   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
376     ac_prev=x_libraries ;;
377   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
378   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
379     x_libraries="$ac_optarg" ;;
380
381   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
382     ;;
383
384   *)
385     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
386       echo "configure: warning: $ac_option: invalid host type" 1>&2
387     fi
388     if test "x$nonopt" != xNONE; then
389       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
390     fi
391     nonopt="$ac_option"
392     ;;
393
394   esac
395 done
396
397 if test -n "$ac_prev"; then
398   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
399 fi
400
401 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
402
403 # File descriptor usage:
404 # 0 standard input
405 # 1 file creation
406 # 2 errors and warnings
407 # 3 some systems may open it to /dev/tty
408 # 4 used on the Kubota Titan
409 # 6 checking for... messages and results
410 # 5 compiler messages saved in config.log
411 if test "$silent" = yes; then
412   exec 6>/dev/null
413 else
414   exec 6>&1
415 fi
416 exec 5>./config.log
417
418 echo "\
419 This file contains any messages produced by compilers while
420 running configure, to aid debugging if configure makes a mistake.
421 " 1>&5
422
423 # Strip out --no-create and --no-recursion so they do not pile up.
424 # Also quote any args containing shell metacharacters.
425 ac_configure_args=
426 for ac_arg
427 do
428   case "$ac_arg" in
429   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
430   | --no-cr | --no-c) ;;
431   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
432   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
433   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
434   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
435   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
436   esac
437 done
438
439 # NLS nuisances.
440 # Only set these to C if already set.  These must not be set unconditionally
441 # because not all systems understand e.g. LANG=C (notably SCO).
442 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
443 # Non-C LC_CTYPE values break the ctype check.
444 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
445 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
446 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
447 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
448
449 # confdefs.h avoids OS command line length limits that DEFS can exceed.
450 rm -rf conftest* confdefs.h
451 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
452 echo > confdefs.h
453
454 # A filename unique to this package, relative to the directory that
455 # configure is in, which we can look for to find out if srcdir is correct.
456 ac_unique_file=src/
457
458 # Find the source files, if location was not specified.
459 if test -z "$srcdir"; then
460   ac_srcdir_defaulted=yes
461   # Try the directory containing this script, then its parent.
462   ac_prog=$0
463   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
464   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
465   srcdir=$ac_confdir
466   if test ! -r $srcdir/$ac_unique_file; then
467     srcdir=..
468   fi
469 else
470   ac_srcdir_defaulted=no
471 fi
472 if test ! -r $srcdir/$ac_unique_file; then
473   if test "$ac_srcdir_defaulted" = yes; then
474     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
475   else
476     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
477   fi
478 fi
479 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
480
481 # Prefer explicitly selected file to automatically selected ones.
482 if test -z "$CONFIG_SITE"; then
483   if test "x$prefix" != xNONE; then
484     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
485   else
486     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
487   fi
488 fi
489 for ac_site_file in $CONFIG_SITE; do
490   if test -r "$ac_site_file"; then
491     echo "loading site script $ac_site_file"
492     . "$ac_site_file"
493   fi
494 done
495
496 if test -r "$cache_file"; then
497   echo "loading cache $cache_file"
498   . $cache_file
499 else
500   echo "creating cache $cache_file"
501   > $cache_file
502 fi
503
504 ac_ext=c
505 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
506 ac_cpp='$CPP $CPPFLAGS'
507 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
508 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
509 cross_compiling=$ac_cv_prog_cc_cross
510
511 ac_exeext=
512 ac_objext=o
513 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
514   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
515   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
516     ac_n= ac_c='
517 ' ac_t='        '
518   else
519     ac_n=-n ac_c= ac_t=
520   fi
521 else
522   ac_n= ac_c='\c' ac_t=
523 fi
524
525
526 if test "$program_transform_name" = s,x,x,; then
527   program_transform_name=
528 else
529   # Double any \ or $.  echo might interpret backslashes.
530   cat <<\EOF_SED > conftestsed
531 s,\\,\\\\,g; s,\$,$$,g
532 EOF_SED
533   program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
534   rm -f conftestsed
535 fi
536 test "$program_prefix" != NONE &&
537   program_transform_name="s,^,${program_prefix},; $program_transform_name"
538 # Use a double $ so make ignores it.
539 test "$program_suffix" != NONE &&
540   program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
541
542 # sed with no file args requires a program.
543 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
544
545
546 export PACKAGE=swftools
547 export VERSION=pre0.1.0
548
549 export CFLAGS="-O2 -fomit-frame-pointer"
550 export CXXFLAGS="-O2 -fomit-frame-pointer"
551
552  for ac_prog in mawk gawk nawk awk
553 do
554 # Extract the first word of "$ac_prog", so it can be a program name with args.
555 set dummy $ac_prog; ac_word=$2
556 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
557 echo "configure:558: checking for $ac_word" >&5
558 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
559   echo $ac_n "(cached) $ac_c" 1>&6
560 else
561   if test -n "$AWK"; then
562   ac_cv_prog_AWK="$AWK" # Let the user override the test.
563 else
564   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
565   ac_dummy="$PATH"
566   for ac_dir in $ac_dummy; do
567     test -z "$ac_dir" && ac_dir=.
568     if test -f $ac_dir/$ac_word; then
569       ac_cv_prog_AWK="$ac_prog"
570       break
571     fi
572   done
573   IFS="$ac_save_ifs"
574 fi
575 fi
576 AWK="$ac_cv_prog_AWK"
577 if test -n "$AWK"; then
578   echo "$ac_t""$AWK" 1>&6
579 else
580   echo "$ac_t""no" 1>&6
581 fi
582
583 test -n "$AWK" && break
584 done
585
586  # Extract the first word of "gcc", so it can be a program name with args.
587 set dummy gcc; ac_word=$2
588 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
589 echo "configure:590: checking for $ac_word" >&5
590 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
591   echo $ac_n "(cached) $ac_c" 1>&6
592 else
593   if test -n "$CC"; then
594   ac_cv_prog_CC="$CC" # Let the user override the test.
595 else
596   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
597   ac_dummy="$PATH"
598   for ac_dir in $ac_dummy; do
599     test -z "$ac_dir" && ac_dir=.
600     if test -f $ac_dir/$ac_word; then
601       ac_cv_prog_CC="gcc"
602       break
603     fi
604   done
605   IFS="$ac_save_ifs"
606 fi
607 fi
608 CC="$ac_cv_prog_CC"
609 if test -n "$CC"; then
610   echo "$ac_t""$CC" 1>&6
611 else
612   echo "$ac_t""no" 1>&6
613 fi
614
615 if test -z "$CC"; then
616   # Extract the first word of "cc", so it can be a program name with args.
617 set dummy cc; ac_word=$2
618 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
619 echo "configure:620: checking for $ac_word" >&5
620 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
621   echo $ac_n "(cached) $ac_c" 1>&6
622 else
623   if test -n "$CC"; then
624   ac_cv_prog_CC="$CC" # Let the user override the test.
625 else
626   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
627   ac_prog_rejected=no
628   ac_dummy="$PATH"
629   for ac_dir in $ac_dummy; do
630     test -z "$ac_dir" && ac_dir=.
631     if test -f $ac_dir/$ac_word; then
632       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
633         ac_prog_rejected=yes
634         continue
635       fi
636       ac_cv_prog_CC="cc"
637       break
638     fi
639   done
640   IFS="$ac_save_ifs"
641 if test $ac_prog_rejected = yes; then
642   # We found a bogon in the path, so make sure we never use it.
643   set dummy $ac_cv_prog_CC
644   shift
645   if test $# -gt 0; then
646     # We chose a different compiler from the bogus one.
647     # However, it has the same basename, so the bogon will be chosen
648     # first if we set CC to just the basename; use the full file name.
649     shift
650     set dummy "$ac_dir/$ac_word" "$@"
651     shift
652     ac_cv_prog_CC="$@"
653   fi
654 fi
655 fi
656 fi
657 CC="$ac_cv_prog_CC"
658 if test -n "$CC"; then
659   echo "$ac_t""$CC" 1>&6
660 else
661   echo "$ac_t""no" 1>&6
662 fi
663
664   if test -z "$CC"; then
665     case "`uname -s`" in
666     *win32* | *WIN32*)
667       # Extract the first word of "cl", so it can be a program name with args.
668 set dummy cl; ac_word=$2
669 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
670 echo "configure:671: checking for $ac_word" >&5
671 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
672   echo $ac_n "(cached) $ac_c" 1>&6
673 else
674   if test -n "$CC"; then
675   ac_cv_prog_CC="$CC" # Let the user override the test.
676 else
677   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
678   ac_dummy="$PATH"
679   for ac_dir in $ac_dummy; do
680     test -z "$ac_dir" && ac_dir=.
681     if test -f $ac_dir/$ac_word; then
682       ac_cv_prog_CC="cl"
683       break
684     fi
685   done
686   IFS="$ac_save_ifs"
687 fi
688 fi
689 CC="$ac_cv_prog_CC"
690 if test -n "$CC"; then
691   echo "$ac_t""$CC" 1>&6
692 else
693   echo "$ac_t""no" 1>&6
694 fi
695  ;;
696     esac
697   fi
698   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
699 fi
700
701 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
702 echo "configure:703: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
703
704 ac_ext=c
705 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
706 ac_cpp='$CPP $CPPFLAGS'
707 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
708 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
709 cross_compiling=$ac_cv_prog_cc_cross
710
711 cat > conftest.$ac_ext << EOF
712
713 #line 714 "configure"
714 #include "confdefs.h"
715
716 main(){return(0);}
717 EOF
718 if { (eval echo configure:719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
719   ac_cv_prog_cc_works=yes
720   # If we can't run a trivial program, we are probably using a cross compiler.
721   if (./conftest; exit) 2>/dev/null; then
722     ac_cv_prog_cc_cross=no
723   else
724     ac_cv_prog_cc_cross=yes
725   fi
726 else
727   echo "configure: failed program was:" >&5
728   cat conftest.$ac_ext >&5
729   ac_cv_prog_cc_works=no
730 fi
731 rm -fr conftest*
732 ac_ext=c
733 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
734 ac_cpp='$CPP $CPPFLAGS'
735 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
736 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
737 cross_compiling=$ac_cv_prog_cc_cross
738
739 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
740 if test $ac_cv_prog_cc_works = no; then
741   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
742 fi
743 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
744 echo "configure:745: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
745 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
746 cross_compiling=$ac_cv_prog_cc_cross
747
748 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
749 echo "configure:750: checking whether we are using GNU C" >&5
750 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
751   echo $ac_n "(cached) $ac_c" 1>&6
752 else
753   cat > conftest.c <<EOF
754 #ifdef __GNUC__
755   yes;
756 #endif
757 EOF
758 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:759: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
759   ac_cv_prog_gcc=yes
760 else
761   ac_cv_prog_gcc=no
762 fi
763 fi
764
765 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
766
767 if test $ac_cv_prog_gcc = yes; then
768   GCC=yes
769 else
770   GCC=
771 fi
772
773 ac_test_CFLAGS="${CFLAGS+set}"
774 ac_save_CFLAGS="$CFLAGS"
775 CFLAGS=
776 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
777 echo "configure:778: checking whether ${CC-cc} accepts -g" >&5
778 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
779   echo $ac_n "(cached) $ac_c" 1>&6
780 else
781   echo 'void f(){}' > conftest.c
782 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
783   ac_cv_prog_cc_g=yes
784 else
785   ac_cv_prog_cc_g=no
786 fi
787 rm -f conftest*
788
789 fi
790
791 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
792 if test "$ac_test_CFLAGS" = set; then
793   CFLAGS="$ac_save_CFLAGS"
794 elif test $ac_cv_prog_cc_g = yes; then
795   if test "$GCC" = yes; then
796     CFLAGS="-g -O2"
797   else
798     CFLAGS="-g"
799   fi
800 else
801   if test "$GCC" = yes; then
802     CFLAGS="-O2"
803   else
804     CFLAGS=
805   fi
806 fi
807
808  echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
809 echo "configure:810: checking how to run the C preprocessor" >&5
810 # On Suns, sometimes $CPP names a directory.
811 if test -n "$CPP" && test -d "$CPP"; then
812   CPP=
813 fi
814 if test -z "$CPP"; then
815 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
816   echo $ac_n "(cached) $ac_c" 1>&6
817 else
818     # This must be in double quotes, not single quotes, because CPP may get
819   # substituted into the Makefile and "${CC-cc}" will confuse make.
820   CPP="${CC-cc} -E"
821   # On the NeXT, cc -E runs the code through the compiler's parser,
822   # not just through cpp.
823   cat > conftest.$ac_ext <<EOF
824 #line 825 "configure"
825 #include "confdefs.h"
826 #include <assert.h>
827 Syntax Error
828 EOF
829 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
830 { (eval echo configure:831: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
831 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
832 if test -z "$ac_err"; then
833   :
834 else
835   echo "$ac_err" >&5
836   echo "configure: failed program was:" >&5
837   cat conftest.$ac_ext >&5
838   rm -rf conftest*
839   CPP="${CC-cc} -E -traditional-cpp"
840   cat > conftest.$ac_ext <<EOF
841 #line 842 "configure"
842 #include "confdefs.h"
843 #include <assert.h>
844 Syntax Error
845 EOF
846 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
847 { (eval echo configure:848: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
848 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
849 if test -z "$ac_err"; then
850   :
851 else
852   echo "$ac_err" >&5
853   echo "configure: failed program was:" >&5
854   cat conftest.$ac_ext >&5
855   rm -rf conftest*
856   CPP="${CC-cc} -nologo -E"
857   cat > conftest.$ac_ext <<EOF
858 #line 859 "configure"
859 #include "confdefs.h"
860 #include <assert.h>
861 Syntax Error
862 EOF
863 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
864 { (eval echo configure:865: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
865 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
866 if test -z "$ac_err"; then
867   :
868 else
869   echo "$ac_err" >&5
870   echo "configure: failed program was:" >&5
871   cat conftest.$ac_ext >&5
872   rm -rf conftest*
873   CPP=/lib/cpp
874 fi
875 rm -f conftest*
876 fi
877 rm -f conftest*
878 fi
879 rm -f conftest*
880   ac_cv_prog_CPP="$CPP"
881 fi
882   CPP="$ac_cv_prog_CPP"
883 else
884   ac_cv_prog_CPP="$CPP"
885 fi
886 echo "$ac_t""$CPP" 1>&6
887
888  for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
889 do
890 # Extract the first word of "$ac_prog", so it can be a program name with args.
891 set dummy $ac_prog; ac_word=$2
892 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
893 echo "configure:894: checking for $ac_word" >&5
894 if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
895   echo $ac_n "(cached) $ac_c" 1>&6
896 else
897   if test -n "$CXX"; then
898   ac_cv_prog_CXX="$CXX" # Let the user override the test.
899 else
900   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
901   ac_dummy="$PATH"
902   for ac_dir in $ac_dummy; do
903     test -z "$ac_dir" && ac_dir=.
904     if test -f $ac_dir/$ac_word; then
905       ac_cv_prog_CXX="$ac_prog"
906       break
907     fi
908   done
909   IFS="$ac_save_ifs"
910 fi
911 fi
912 CXX="$ac_cv_prog_CXX"
913 if test -n "$CXX"; then
914   echo "$ac_t""$CXX" 1>&6
915 else
916   echo "$ac_t""no" 1>&6
917 fi
918
919 test -n "$CXX" && break
920 done
921 test -n "$CXX" || CXX="gcc"
922
923
924 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
925 echo "configure:926: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
926
927 ac_ext=C
928 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
929 ac_cpp='$CXXCPP $CPPFLAGS'
930 ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
931 ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
932 cross_compiling=$ac_cv_prog_cxx_cross
933
934 cat > conftest.$ac_ext << EOF
935
936 #line 937 "configure"
937 #include "confdefs.h"
938
939 int main(){return(0);}
940 EOF
941 if { (eval echo configure:942: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
942   ac_cv_prog_cxx_works=yes
943   # If we can't run a trivial program, we are probably using a cross compiler.
944   if (./conftest; exit) 2>/dev/null; then
945     ac_cv_prog_cxx_cross=no
946   else
947     ac_cv_prog_cxx_cross=yes
948   fi
949 else
950   echo "configure: failed program was:" >&5
951   cat conftest.$ac_ext >&5
952   ac_cv_prog_cxx_works=no
953 fi
954 rm -fr conftest*
955 ac_ext=c
956 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
957 ac_cpp='$CPP $CPPFLAGS'
958 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
959 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
960 cross_compiling=$ac_cv_prog_cc_cross
961
962 echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
963 if test $ac_cv_prog_cxx_works = no; then
964   { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
965 fi
966 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
967 echo "configure:968: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
968 echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
969 cross_compiling=$ac_cv_prog_cxx_cross
970
971 echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
972 echo "configure:973: checking whether we are using GNU C++" >&5
973 if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
974   echo $ac_n "(cached) $ac_c" 1>&6
975 else
976   cat > conftest.C <<EOF
977 #ifdef __GNUC__
978   yes;
979 #endif
980 EOF
981 if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:982: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
982   ac_cv_prog_gxx=yes
983 else
984   ac_cv_prog_gxx=no
985 fi
986 fi
987
988 echo "$ac_t""$ac_cv_prog_gxx" 1>&6
989
990 if test $ac_cv_prog_gxx = yes; then
991   GXX=yes
992 else
993   GXX=
994 fi
995
996 ac_test_CXXFLAGS="${CXXFLAGS+set}"
997 ac_save_CXXFLAGS="$CXXFLAGS"
998 CXXFLAGS=
999 echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
1000 echo "configure:1001: checking whether ${CXX-g++} accepts -g" >&5
1001 if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
1002   echo $ac_n "(cached) $ac_c" 1>&6
1003 else
1004   echo 'void f(){}' > conftest.cc
1005 if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
1006   ac_cv_prog_cxx_g=yes
1007 else
1008   ac_cv_prog_cxx_g=no
1009 fi
1010 rm -f conftest*
1011
1012 fi
1013
1014 echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
1015 if test "$ac_test_CXXFLAGS" = set; then
1016   CXXFLAGS="$ac_save_CXXFLAGS"
1017 elif test $ac_cv_prog_cxx_g = yes; then
1018   if test "$GXX" = yes; then
1019     CXXFLAGS="-g -O2"
1020   else
1021     CXXFLAGS="-g"
1022   fi
1023 else
1024   if test "$GXX" = yes; then
1025     CXXFLAGS="-O2"
1026   else
1027     CXXFLAGS=
1028   fi
1029 fi
1030
1031  # Extract the first word of "ranlib", so it can be a program name with args.
1032 set dummy ranlib; ac_word=$2
1033 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1034 echo "configure:1035: checking for $ac_word" >&5
1035 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1036   echo $ac_n "(cached) $ac_c" 1>&6
1037 else
1038   if test -n "$RANLIB"; then
1039   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1040 else
1041   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1042   ac_dummy="$PATH"
1043   for ac_dir in $ac_dummy; do
1044     test -z "$ac_dir" && ac_dir=.
1045     if test -f $ac_dir/$ac_word; then
1046       ac_cv_prog_RANLIB="ranlib"
1047       break
1048     fi
1049   done
1050   IFS="$ac_save_ifs"
1051   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1052 fi
1053 fi
1054 RANLIB="$ac_cv_prog_RANLIB"
1055 if test -n "$RANLIB"; then
1056   echo "$ac_t""$RANLIB" 1>&6
1057 else
1058   echo "$ac_t""no" 1>&6
1059 fi
1060
1061  echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1062 echo "configure:1063: checking whether ${MAKE-make} sets \${MAKE}" >&5
1063 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1064 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1065   echo $ac_n "(cached) $ac_c" 1>&6
1066 else
1067   cat > conftestmake <<\EOF
1068 all:
1069         @echo 'ac_maketemp="${MAKE}"'
1070 EOF
1071 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1072 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1073 if test -n "$ac_maketemp"; then
1074   eval ac_cv_prog_make_${ac_make}_set=yes
1075 else
1076   eval ac_cv_prog_make_${ac_make}_set=no
1077 fi
1078 rm -f conftestmake
1079 fi
1080 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1081   echo "$ac_t""yes" 1>&6
1082   SET_MAKE=
1083 else
1084   echo "$ac_t""no" 1>&6
1085   SET_MAKE="MAKE=${MAKE-make}"
1086 fi
1087
1088  ac_aux_dir=
1089 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1090   if test -f $ac_dir/install-sh; then
1091     ac_aux_dir=$ac_dir
1092     ac_install_sh="$ac_aux_dir/install-sh -c"
1093     break
1094   elif test -f $ac_dir/install.sh; then
1095     ac_aux_dir=$ac_dir
1096     ac_install_sh="$ac_aux_dir/install.sh -c"
1097     break
1098   fi
1099 done
1100 if test -z "$ac_aux_dir"; then
1101   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
1102 fi
1103 ac_config_guess=$ac_aux_dir/config.guess
1104 ac_config_sub=$ac_aux_dir/config.sub
1105 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
1106
1107 # Find a good install program.  We prefer a C program (faster),
1108 # so one script is as good as another.  But avoid the broken or
1109 # incompatible versions:
1110 # SysV /etc/install, /usr/sbin/install
1111 # SunOS /usr/etc/install
1112 # IRIX /sbin/install
1113 # AIX /bin/install
1114 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1115 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1116 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1117 # ./install, which can be erroneously created by make from ./install.sh.
1118 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1119 echo "configure:1120: checking for a BSD compatible install" >&5
1120 if test -z "$INSTALL"; then
1121 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1122   echo $ac_n "(cached) $ac_c" 1>&6
1123 else
1124     IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
1125   for ac_dir in $PATH; do
1126     # Account for people who put trailing slashes in PATH elements.
1127     case "$ac_dir/" in
1128     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1129     *)
1130       # OSF1 and SCO ODT 3.0 have their own names for install.
1131       # Don't use installbsd from OSF since it installs stuff as root
1132       # by default.
1133       for ac_prog in ginstall scoinst install; do
1134         if test -f $ac_dir/$ac_prog; then
1135           if test $ac_prog = install &&
1136             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1137             # AIX install.  It has an incompatible calling convention.
1138             :
1139           else
1140             ac_cv_path_install="$ac_dir/$ac_prog -c"
1141             break 2
1142           fi
1143         fi
1144       done
1145       ;;
1146     esac
1147   done
1148   IFS="$ac_save_IFS"
1149
1150 fi
1151   if test "${ac_cv_path_install+set}" = set; then
1152     INSTALL="$ac_cv_path_install"
1153   else
1154     # As a last resort, use the slow shell script.  We don't cache a
1155     # path for INSTALL within a source directory, because that will
1156     # break other packages using the cache if that directory is
1157     # removed, or if the path is relative.
1158     INSTALL="$ac_install_sh"
1159   fi
1160 fi
1161 echo "$ac_t""$INSTALL" 1>&6
1162
1163 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1164 # It thinks the first close brace ends the variable substitution.
1165 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1166
1167 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1168
1169 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1170
1171  echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1172 echo "configure:1173: checking whether ln -s works" >&5
1173 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1174   echo $ac_n "(cached) $ac_c" 1>&6
1175 else
1176   rm -f conftestdata
1177 if ln -s X conftestdata 2>/dev/null
1178 then
1179   rm -f conftestdata
1180   ac_cv_prog_LN_S="ln -s"
1181 else
1182   ac_cv_prog_LN_S=ln
1183 fi
1184 fi
1185 LN_S="$ac_cv_prog_LN_S"
1186 if test "$ac_cv_prog_LN_S" = "ln -s"; then
1187   echo "$ac_t""yes" 1>&6
1188 else
1189   echo "$ac_t""no" 1>&6
1190 fi
1191
1192
1193  echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
1194 echo "configure:1195: checking for Cygwin environment" >&5
1195 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
1196   echo $ac_n "(cached) $ac_c" 1>&6
1197 else
1198   cat > conftest.$ac_ext <<EOF
1199 #line 1200 "configure"
1200 #include "confdefs.h"
1201
1202 int main() {
1203
1204 #ifndef __CYGWIN__
1205 #define __CYGWIN__ __CYGWIN32__
1206 #endif
1207 return __CYGWIN__;
1208 ; return 0; }
1209 EOF
1210 if { (eval echo configure:1211: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1211   rm -rf conftest*
1212   ac_cv_cygwin=yes
1213 else
1214   echo "configure: failed program was:" >&5
1215   cat conftest.$ac_ext >&5
1216   rm -rf conftest*
1217   ac_cv_cygwin=no
1218 fi
1219 rm -f conftest*
1220 rm -f conftest*
1221 fi
1222
1223 echo "$ac_t""$ac_cv_cygwin" 1>&6
1224 CYGWIN=
1225 test "$ac_cv_cygwin" = yes && CYGWIN=yes
1226 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
1227 echo "configure:1228: checking for mingw32 environment" >&5
1228 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
1229   echo $ac_n "(cached) $ac_c" 1>&6
1230 else
1231   cat > conftest.$ac_ext <<EOF
1232 #line 1233 "configure"
1233 #include "confdefs.h"
1234
1235 int main() {
1236 return __MINGW32__;
1237 ; return 0; }
1238 EOF
1239 if { (eval echo configure:1240: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1240   rm -rf conftest*
1241   ac_cv_mingw32=yes
1242 else
1243   echo "configure: failed program was:" >&5
1244   cat conftest.$ac_ext >&5
1245   rm -rf conftest*
1246   ac_cv_mingw32=no
1247 fi
1248 rm -f conftest*
1249 rm -f conftest*
1250 fi
1251
1252 echo "$ac_t""$ac_cv_mingw32" 1>&6
1253 MINGW32=
1254 test "$ac_cv_mingw32" = yes && MINGW32=yes
1255
1256
1257 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
1258 echo "configure:1259: checking for executable suffix" >&5
1259 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
1260   echo $ac_n "(cached) $ac_c" 1>&6
1261 else
1262   if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
1263   ac_cv_exeext=.exe
1264 else
1265   rm -f conftest*
1266   echo 'int main () { return 0; }' > conftest.$ac_ext
1267   ac_cv_exeext=
1268   if { (eval echo configure:1269: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1269     for file in conftest.*; do
1270       case $file in
1271       *.c | *.o | *.obj) ;;
1272       *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
1273       esac
1274     done
1275   else
1276     { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
1277   fi
1278   rm -f conftest*
1279   test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
1280 fi
1281 fi
1282
1283 EXEEXT=""
1284 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
1285 echo "$ac_t""${ac_cv_exeext}" 1>&6
1286 ac_exeext=$EXEEXT
1287
1288
1289  echo $ac_n "checking for sin in -lm""... $ac_c" 1>&6
1290 echo "configure:1291: checking for sin in -lm" >&5
1291 ac_lib_var=`echo m'_'sin | sed 'y%./+-%__p_%'`
1292 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1293   echo $ac_n "(cached) $ac_c" 1>&6
1294 else
1295   ac_save_LIBS="$LIBS"
1296 LIBS="-lm  $LIBS"
1297 cat > conftest.$ac_ext <<EOF
1298 #line 1299 "configure"
1299 #include "confdefs.h"
1300 /* Override any gcc2 internal prototype to avoid an error.  */
1301 /* We use char because int might match the return type of a gcc2
1302     builtin and then its argument prototype would still apply.  */
1303 char sin();
1304
1305 int main() {
1306 sin()
1307 ; return 0; }
1308 EOF
1309 if { (eval echo configure:1310: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1310   rm -rf conftest*
1311   eval "ac_cv_lib_$ac_lib_var=yes"
1312 else
1313   echo "configure: failed program was:" >&5
1314   cat conftest.$ac_ext >&5
1315   rm -rf conftest*
1316   eval "ac_cv_lib_$ac_lib_var=no"
1317 fi
1318 rm -f conftest*
1319 LIBS="$ac_save_LIBS"
1320
1321 fi
1322 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1323   echo "$ac_t""yes" 1>&6
1324     ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1325     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1326   cat >> confdefs.h <<EOF
1327 #define $ac_tr_lib 1
1328 EOF
1329
1330   LIBS="-lm $LIBS"
1331
1332 else
1333   echo "$ac_t""no" 1>&6
1334 echo "Error: Math library not found.";
1335  exit;
1336  
1337 fi
1338
1339  echo $ac_n "checking for deflate in -lz""... $ac_c" 1>&6
1340 echo "configure:1341: checking for deflate in -lz" >&5
1341 ac_lib_var=`echo z'_'deflate | sed 'y%./+-%__p_%'`
1342 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1343   echo $ac_n "(cached) $ac_c" 1>&6
1344 else
1345   ac_save_LIBS="$LIBS"
1346 LIBS="-lz  $LIBS"
1347 cat > conftest.$ac_ext <<EOF
1348 #line 1349 "configure"
1349 #include "confdefs.h"
1350 /* Override any gcc2 internal prototype to avoid an error.  */
1351 /* We use char because int might match the return type of a gcc2
1352     builtin and then its argument prototype would still apply.  */
1353 char deflate();
1354
1355 int main() {
1356 deflate()
1357 ; return 0; }
1358 EOF
1359 if { (eval echo configure:1360: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1360   rm -rf conftest*
1361   eval "ac_cv_lib_$ac_lib_var=yes"
1362 else
1363   echo "configure: failed program was:" >&5
1364   cat conftest.$ac_ext >&5
1365   rm -rf conftest*
1366   eval "ac_cv_lib_$ac_lib_var=no"
1367 fi
1368 rm -f conftest*
1369 LIBS="$ac_save_LIBS"
1370
1371 fi
1372 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1373   echo "$ac_t""yes" 1>&6
1374     ac_tr_lib=HAVE_LIB`echo z | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1375     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1376   cat >> confdefs.h <<EOF
1377 #define $ac_tr_lib 1
1378 EOF
1379
1380   LIBS="-lz $LIBS"
1381
1382 else
1383   echo "$ac_t""no" 1>&6
1384 echo "Error: The zlib compression library is required."
1385  DISABLEPDF2SWF=true; 
1386  MISSINGLIBS="${MISSINGLIBS} zlib"
1387  
1388 fi
1389
1390  echo $ac_n "checking for jpeg_write_raw_data in -ljpeg""... $ac_c" 1>&6
1391 echo "configure:1392: checking for jpeg_write_raw_data in -ljpeg" >&5
1392 ac_lib_var=`echo jpeg'_'jpeg_write_raw_data | sed 'y%./+-%__p_%'`
1393 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1394   echo $ac_n "(cached) $ac_c" 1>&6
1395 else
1396   ac_save_LIBS="$LIBS"
1397 LIBS="-ljpeg  $LIBS"
1398 cat > conftest.$ac_ext <<EOF
1399 #line 1400 "configure"
1400 #include "confdefs.h"
1401 /* Override any gcc2 internal prototype to avoid an error.  */
1402 /* We use char because int might match the return type of a gcc2
1403     builtin and then its argument prototype would still apply.  */
1404 char jpeg_write_raw_data();
1405
1406 int main() {
1407 jpeg_write_raw_data()
1408 ; return 0; }
1409 EOF
1410 if { (eval echo configure:1411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1411   rm -rf conftest*
1412   eval "ac_cv_lib_$ac_lib_var=yes"
1413 else
1414   echo "configure: failed program was:" >&5
1415   cat conftest.$ac_ext >&5
1416   rm -rf conftest*
1417   eval "ac_cv_lib_$ac_lib_var=no"
1418 fi
1419 rm -f conftest*
1420 LIBS="$ac_save_LIBS"
1421
1422 fi
1423 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1424   echo "$ac_t""yes" 1>&6
1425     ac_tr_lib=HAVE_LIB`echo jpeg | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1426     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1427   cat >> confdefs.h <<EOF
1428 #define $ac_tr_lib 1
1429 EOF
1430
1431   LIBS="-ljpeg $LIBS"
1432
1433 else
1434   echo "$ac_t""no" 1>&6
1435 DISABLEPDF2SWF=true;
1436  DISABLEJPEG2SWF=true;
1437  MISSINGLIBS="${MISSINGLIBS} jpeglib"
1438  
1439 fi
1440
1441  echo $ac_n "checking for T1_LoadFont in -lt1""... $ac_c" 1>&6
1442 echo "configure:1443: checking for T1_LoadFont in -lt1" >&5
1443 ac_lib_var=`echo t1'_'T1_LoadFont | sed 'y%./+-%__p_%'`
1444 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1445   echo $ac_n "(cached) $ac_c" 1>&6
1446 else
1447   ac_save_LIBS="$LIBS"
1448 LIBS="-lt1  $LIBS"
1449 cat > conftest.$ac_ext <<EOF
1450 #line 1451 "configure"
1451 #include "confdefs.h"
1452 /* Override any gcc2 internal prototype to avoid an error.  */
1453 /* We use char because int might match the return type of a gcc2
1454     builtin and then its argument prototype would still apply.  */
1455 char T1_LoadFont();
1456
1457 int main() {
1458 T1_LoadFont()
1459 ; return 0; }
1460 EOF
1461 if { (eval echo configure:1462: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1462   rm -rf conftest*
1463   eval "ac_cv_lib_$ac_lib_var=yes"
1464 else
1465   echo "configure: failed program was:" >&5
1466   cat conftest.$ac_ext >&5
1467   rm -rf conftest*
1468   eval "ac_cv_lib_$ac_lib_var=no"
1469 fi
1470 rm -f conftest*
1471 LIBS="$ac_save_LIBS"
1472
1473 fi
1474 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1475   echo "$ac_t""yes" 1>&6
1476     ac_tr_lib=HAVE_LIB`echo t1 | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1477     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1478   cat >> confdefs.h <<EOF
1479 #define $ac_tr_lib 1
1480 EOF
1481
1482   LIBS="-lt1 $LIBS"
1483
1484 else
1485   echo "$ac_t""no" 1>&6
1486 DISABLEPDF2SWF=true;
1487  MISSINGLIBS="${MISSINGLIBS} T1lib"
1488  
1489 fi
1490
1491
1492
1493  
1494  # If we find X, set shell vars x_includes and x_libraries to the
1495 # paths, otherwise set no_x=yes.
1496 # Uses ac_ vars as temps to allow command line to override cache and checks.
1497 # --without-x overrides everything else, but does not touch the cache.
1498 echo $ac_n "checking for X""... $ac_c" 1>&6
1499 echo "configure:1500: checking for X" >&5
1500
1501 # Check whether --with-x or --without-x was given.
1502 if test "${with_x+set}" = set; then
1503   withval="$with_x"
1504   :
1505 fi
1506
1507 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
1508 if test "x$with_x" = xno; then
1509   # The user explicitly disabled X.
1510   have_x=disabled
1511 else
1512   if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
1513     # Both variables are already set.
1514     have_x=yes
1515   else
1516 if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
1517   echo $ac_n "(cached) $ac_c" 1>&6
1518 else
1519   # One or both of the vars are not set, and there is no cached value.
1520 ac_x_includes=NO ac_x_libraries=NO
1521 rm -fr conftestdir
1522 if mkdir conftestdir; then
1523   cd conftestdir
1524   # Make sure to not put "make" in the Imakefile rules, since we grep it out.
1525   cat > Imakefile <<'EOF'
1526 acfindx:
1527         @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
1528 EOF
1529   if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
1530     # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1531     eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
1532     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
1533     for ac_extension in a so sl; do
1534       if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
1535         test -f $ac_im_libdir/libX11.$ac_extension; then
1536         ac_im_usrlibdir=$ac_im_libdir; break
1537       fi
1538     done
1539     # Screen out bogus values from the imake configuration.  They are
1540     # bogus both because they are the default anyway, and because
1541     # using them would break gcc on systems where it needs fixed includes.
1542     case "$ac_im_incroot" in
1543         /usr/include) ;;
1544         *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
1545     esac
1546     case "$ac_im_usrlibdir" in
1547         /usr/lib | /lib) ;;
1548         *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
1549     esac
1550   fi
1551   cd ..
1552   rm -fr conftestdir
1553 fi
1554
1555 if test "$ac_x_includes" = NO; then
1556   # Guess where to find include files, by looking for this one X11 .h file.
1557   test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
1558
1559   # First, try using that file with no special directory specified.
1560 cat > conftest.$ac_ext <<EOF
1561 #line 1562 "configure"
1562 #include "confdefs.h"
1563 #include <$x_direct_test_include>
1564 EOF
1565 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1566 { (eval echo configure:1567: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1567 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1568 if test -z "$ac_err"; then
1569   rm -rf conftest*
1570   # We can compile using X headers with no special include directory.
1571 ac_x_includes=
1572 else
1573   echo "$ac_err" >&5
1574   echo "configure: failed program was:" >&5
1575   cat conftest.$ac_ext >&5
1576   rm -rf conftest*
1577   # Look for the header file in a standard set of common directories.
1578 # Check X11 before X11Rn because it is often a symlink to the current release.
1579   for ac_dir in               \
1580     /usr/X11/include          \
1581     /usr/X11R6/include        \
1582     /usr/X11R5/include        \
1583     /usr/X11R4/include        \
1584                               \
1585     /usr/include/X11          \
1586     /usr/include/X11R6        \
1587     /usr/include/X11R5        \
1588     /usr/include/X11R4        \
1589                               \
1590     /usr/local/X11/include    \
1591     /usr/local/X11R6/include  \
1592     /usr/local/X11R5/include  \
1593     /usr/local/X11R4/include  \
1594                               \
1595     /usr/local/include/X11    \
1596     /usr/local/include/X11R6  \
1597     /usr/local/include/X11R5  \
1598     /usr/local/include/X11R4  \
1599                               \
1600     /usr/X386/include         \
1601     /usr/x386/include         \
1602     /usr/XFree86/include/X11  \
1603                               \
1604     /usr/include              \
1605     /usr/local/include        \
1606     /usr/unsupported/include  \
1607     /usr/athena/include       \
1608     /usr/local/x11r5/include  \
1609     /usr/lpp/Xamples/include  \
1610                               \
1611     /usr/openwin/include      \
1612     /usr/openwin/share/include \
1613     ; \
1614   do
1615     if test -r "$ac_dir/$x_direct_test_include"; then
1616       ac_x_includes=$ac_dir
1617       break
1618     fi
1619   done
1620 fi
1621 rm -f conftest*
1622 fi # $ac_x_includes = NO
1623
1624 if test "$ac_x_libraries" = NO; then
1625   # Check for the libraries.
1626
1627   test -z "$x_direct_test_library" && x_direct_test_library=Xt
1628   test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
1629
1630   # See if we find them without any special options.
1631   # Don't add to $LIBS permanently.
1632   ac_save_LIBS="$LIBS"
1633   LIBS="-l$x_direct_test_library $LIBS"
1634 cat > conftest.$ac_ext <<EOF
1635 #line 1636 "configure"
1636 #include "confdefs.h"
1637
1638 int main() {
1639 ${x_direct_test_function}()
1640 ; return 0; }
1641 EOF
1642 if { (eval echo configure:1643: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1643   rm -rf conftest*
1644   LIBS="$ac_save_LIBS"
1645 # We can link X programs with no special library path.
1646 ac_x_libraries=
1647 else
1648   echo "configure: failed program was:" >&5
1649   cat conftest.$ac_ext >&5
1650   rm -rf conftest*
1651   LIBS="$ac_save_LIBS"
1652 # First see if replacing the include by lib works.
1653 # Check X11 before X11Rn because it is often a symlink to the current release.
1654 for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
1655     /usr/X11/lib          \
1656     /usr/X11R6/lib        \
1657     /usr/X11R5/lib        \
1658     /usr/X11R4/lib        \
1659                           \
1660     /usr/lib/X11          \
1661     /usr/lib/X11R6        \
1662     /usr/lib/X11R5        \
1663     /usr/lib/X11R4        \
1664                           \
1665     /usr/local/X11/lib    \
1666     /usr/local/X11R6/lib  \
1667     /usr/local/X11R5/lib  \
1668     /usr/local/X11R4/lib  \
1669                           \
1670     /usr/local/lib/X11    \
1671     /usr/local/lib/X11R6  \
1672     /usr/local/lib/X11R5  \
1673     /usr/local/lib/X11R4  \
1674                           \
1675     /usr/X386/lib         \
1676     /usr/x386/lib         \
1677     /usr/XFree86/lib/X11  \
1678                           \
1679     /usr/lib              \
1680     /usr/local/lib        \
1681     /usr/unsupported/lib  \
1682     /usr/athena/lib       \
1683     /usr/local/x11r5/lib  \
1684     /usr/lpp/Xamples/lib  \
1685     /lib/usr/lib/X11      \
1686                           \
1687     /usr/openwin/lib      \
1688     /usr/openwin/share/lib \
1689     ; \
1690 do
1691   for ac_extension in a so sl; do
1692     if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
1693       ac_x_libraries=$ac_dir
1694       break 2
1695     fi
1696   done
1697 done
1698 fi
1699 rm -f conftest*
1700 fi # $ac_x_libraries = NO
1701
1702 if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
1703   # Didn't find X anywhere.  Cache the known absence of X.
1704   ac_cv_have_x="have_x=no"
1705 else
1706   # Record where we found X for the cache.
1707   ac_cv_have_x="have_x=yes \
1708                 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
1709 fi
1710 fi
1711   fi
1712   eval "$ac_cv_have_x"
1713 fi # $with_x != no
1714
1715 if test "$have_x" != yes; then
1716   echo "$ac_t""$have_x" 1>&6
1717   no_x=yes
1718 else
1719   # If each of the values was on the command line, it overrides each guess.
1720   test "x$x_includes" = xNONE && x_includes=$ac_x_includes
1721   test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
1722   # Update the cache value to reflect the command line values.
1723   ac_cv_have_x="have_x=yes \
1724                 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
1725   echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
1726 fi
1727
1728  ac_header_dirent=no
1729 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1730 do
1731 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1732 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
1733 echo "configure:1734: checking for $ac_hdr that defines DIR" >&5
1734 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1735   echo $ac_n "(cached) $ac_c" 1>&6
1736 else
1737   cat > conftest.$ac_ext <<EOF
1738 #line 1739 "configure"
1739 #include "confdefs.h"
1740 #include <sys/types.h>
1741 #include <$ac_hdr>
1742 int main() {
1743 DIR *dirp = 0;
1744 ; return 0; }
1745 EOF
1746 if { (eval echo configure:1747: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1747   rm -rf conftest*
1748   eval "ac_cv_header_dirent_$ac_safe=yes"
1749 else
1750   echo "configure: failed program was:" >&5
1751   cat conftest.$ac_ext >&5
1752   rm -rf conftest*
1753   eval "ac_cv_header_dirent_$ac_safe=no"
1754 fi
1755 rm -f conftest*
1756 fi
1757 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
1758   echo "$ac_t""yes" 1>&6
1759     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1760   cat >> confdefs.h <<EOF
1761 #define $ac_tr_hdr 1
1762 EOF
1763  ac_header_dirent=$ac_hdr; break
1764 else
1765   echo "$ac_t""no" 1>&6
1766 fi
1767 done
1768 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
1769 if test $ac_header_dirent = dirent.h; then
1770 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
1771 echo "configure:1772: checking for opendir in -ldir" >&5
1772 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
1773 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1774   echo $ac_n "(cached) $ac_c" 1>&6
1775 else
1776   ac_save_LIBS="$LIBS"
1777 LIBS="-ldir  $LIBS"
1778 cat > conftest.$ac_ext <<EOF
1779 #line 1780 "configure"
1780 #include "confdefs.h"
1781 /* Override any gcc2 internal prototype to avoid an error.  */
1782 /* We use char because int might match the return type of a gcc2
1783     builtin and then its argument prototype would still apply.  */
1784 char opendir();
1785
1786 int main() {
1787 opendir()
1788 ; return 0; }
1789 EOF
1790 if { (eval echo configure:1791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1791   rm -rf conftest*
1792   eval "ac_cv_lib_$ac_lib_var=yes"
1793 else
1794   echo "configure: failed program was:" >&5
1795   cat conftest.$ac_ext >&5
1796   rm -rf conftest*
1797   eval "ac_cv_lib_$ac_lib_var=no"
1798 fi
1799 rm -f conftest*
1800 LIBS="$ac_save_LIBS"
1801
1802 fi
1803 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1804   echo "$ac_t""yes" 1>&6
1805   LIBS="$LIBS -ldir"
1806 else
1807   echo "$ac_t""no" 1>&6
1808 fi
1809
1810 else
1811 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
1812 echo "configure:1813: checking for opendir in -lx" >&5
1813 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
1814 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1815   echo $ac_n "(cached) $ac_c" 1>&6
1816 else
1817   ac_save_LIBS="$LIBS"
1818 LIBS="-lx  $LIBS"
1819 cat > conftest.$ac_ext <<EOF
1820 #line 1821 "configure"
1821 #include "confdefs.h"
1822 /* Override any gcc2 internal prototype to avoid an error.  */
1823 /* We use char because int might match the return type of a gcc2
1824     builtin and then its argument prototype would still apply.  */
1825 char opendir();
1826
1827 int main() {
1828 opendir()
1829 ; return 0; }
1830 EOF
1831 if { (eval echo configure:1832: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1832   rm -rf conftest*
1833   eval "ac_cv_lib_$ac_lib_var=yes"
1834 else
1835   echo "configure: failed program was:" >&5
1836   cat conftest.$ac_ext >&5
1837   rm -rf conftest*
1838   eval "ac_cv_lib_$ac_lib_var=no"
1839 fi
1840 rm -f conftest*
1841 LIBS="$ac_save_LIBS"
1842
1843 fi
1844 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1845   echo "$ac_t""yes" 1>&6
1846   LIBS="$LIBS -lx"
1847 else
1848   echo "$ac_t""no" 1>&6
1849 fi
1850
1851 fi
1852
1853  echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1854 echo "configure:1855: checking for ANSI C header files" >&5
1855 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1856   echo $ac_n "(cached) $ac_c" 1>&6
1857 else
1858   cat > conftest.$ac_ext <<EOF
1859 #line 1860 "configure"
1860 #include "confdefs.h"
1861 #include <stdlib.h>
1862 #include <stdarg.h>
1863 #include <string.h>
1864 #include <float.h>
1865 EOF
1866 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1867 { (eval echo configure:1868: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1868 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1869 if test -z "$ac_err"; then
1870   rm -rf conftest*
1871   ac_cv_header_stdc=yes
1872 else
1873   echo "$ac_err" >&5
1874   echo "configure: failed program was:" >&5
1875   cat conftest.$ac_ext >&5
1876   rm -rf conftest*
1877   ac_cv_header_stdc=no
1878 fi
1879 rm -f conftest*
1880
1881 if test $ac_cv_header_stdc = yes; then
1882   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1883 cat > conftest.$ac_ext <<EOF
1884 #line 1885 "configure"
1885 #include "confdefs.h"
1886 #include <string.h>
1887 EOF
1888 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1889   egrep "memchr" >/dev/null 2>&1; then
1890   :
1891 else
1892   rm -rf conftest*
1893   ac_cv_header_stdc=no
1894 fi
1895 rm -f conftest*
1896
1897 fi
1898
1899 if test $ac_cv_header_stdc = yes; then
1900   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1901 cat > conftest.$ac_ext <<EOF
1902 #line 1903 "configure"
1903 #include "confdefs.h"
1904 #include <stdlib.h>
1905 EOF
1906 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1907   egrep "free" >/dev/null 2>&1; then
1908   :
1909 else
1910   rm -rf conftest*
1911   ac_cv_header_stdc=no
1912 fi
1913 rm -f conftest*
1914
1915 fi
1916
1917 if test $ac_cv_header_stdc = yes; then
1918   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1919 if test "$cross_compiling" = yes; then
1920   :
1921 else
1922   cat > conftest.$ac_ext <<EOF
1923 #line 1924 "configure"
1924 #include "confdefs.h"
1925 #include <ctype.h>
1926 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1927 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1928 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1929 int main () { int i; for (i = 0; i < 256; i++)
1930 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1931 exit (0); }
1932
1933 EOF
1934 if { (eval echo configure:1935: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1935 then
1936   :
1937 else
1938   echo "configure: failed program was:" >&5
1939   cat conftest.$ac_ext >&5
1940   rm -fr conftest*
1941   ac_cv_header_stdc=no
1942 fi
1943 rm -fr conftest*
1944 fi
1945
1946 fi
1947 fi
1948
1949 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1950 if test $ac_cv_header_stdc = yes; then
1951   cat >> confdefs.h <<\EOF
1952 #define STDC_HEADERS 1
1953 EOF
1954
1955 fi
1956
1957  for ac_hdr in math.h fcntl.h limits.h malloc.h unistd.h memory.h zlib.h jpeglib.h t1lib.h sys/stat.h sys/types.h
1958 do
1959 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1960 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1961 echo "configure:1962: checking for $ac_hdr" >&5
1962 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1963   echo $ac_n "(cached) $ac_c" 1>&6
1964 else
1965   cat > conftest.$ac_ext <<EOF
1966 #line 1967 "configure"
1967 #include "confdefs.h"
1968 #include <$ac_hdr>
1969 EOF
1970 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1971 { (eval echo configure:1972: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1972 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1973 if test -z "$ac_err"; then
1974   rm -rf conftest*
1975   eval "ac_cv_header_$ac_safe=yes"
1976 else
1977   echo "$ac_err" >&5
1978   echo "configure: failed program was:" >&5
1979   cat conftest.$ac_ext >&5
1980   rm -rf conftest*
1981   eval "ac_cv_header_$ac_safe=no"
1982 fi
1983 rm -f conftest*
1984 fi
1985 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1986   echo "$ac_t""yes" 1>&6
1987     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1988   cat >> confdefs.h <<EOF
1989 #define $ac_tr_hdr 1
1990 EOF
1991  
1992 else
1993   echo "$ac_t""no" 1>&6
1994 fi
1995 done
1996
1997
1998 if test "x${ac_cv_header_jpeglib_h}" != "xyes"; then
1999  DISABLEPDF2SWF=true;
2000  DISABLEJPEG2SWF=true;
2001  MISSINGLIBS="${MISSINGLIBS} jpeglib.h"
2002 fi
2003 if test "x${ac_cv_header_t1lib_h}" != "xyes"; then
2004  DISABLEPDF2SWF=true;
2005  MISSINGLIBS="${MISSINGLIBS} t1lib.h"
2006 fi
2007 if test "x${ac_cv_header_zlib_h}" != "xyes"; then
2008  DISABLEPDF2SWF=true;
2009  MISSINGLIBS="${MISSINGLIBS} zlib.h"
2010 fi
2011
2012 cat >> confdefs.h <<EOF
2013 #define PACKAGE "$PACKAGE"
2014 EOF
2015
2016 cat >> confdefs.h <<EOF
2017 #define VERSION "$VERSION"
2018 EOF
2019
2020
2021
2022
2023
2024
2025
2026  echo $ac_n "checking for working const""... $ac_c" 1>&6
2027 echo "configure:2028: checking for working const" >&5
2028 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
2029   echo $ac_n "(cached) $ac_c" 1>&6
2030 else
2031   cat > conftest.$ac_ext <<EOF
2032 #line 2033 "configure"
2033 #include "confdefs.h"
2034
2035 int main() {
2036
2037 /* Ultrix mips cc rejects this.  */
2038 typedef int charset[2]; const charset x;
2039 /* SunOS 4.1.1 cc rejects this.  */
2040 char const *const *ccp;
2041 char **p;
2042 /* NEC SVR4.0.2 mips cc rejects this.  */
2043 struct point {int x, y;};
2044 static struct point const zero = {0,0};
2045 /* AIX XL C 1.02.0.0 rejects this.
2046    It does not let you subtract one const X* pointer from another in an arm
2047    of an if-expression whose if-part is not a constant expression */
2048 const char *g = "string";
2049 ccp = &g + (g ? g-g : 0);
2050 /* HPUX 7.0 cc rejects these. */
2051 ++ccp;
2052 p = (char**) ccp;
2053 ccp = (char const *const *) p;
2054 { /* SCO 3.2v4 cc rejects this.  */
2055   char *t;
2056   char const *s = 0 ? (char *) 0 : (char const *) 0;
2057
2058   *t++ = 0;
2059 }
2060 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
2061   int x[] = {25, 17};
2062   const int *foo = &x[0];
2063   ++foo;
2064 }
2065 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2066   typedef const int *iptr;
2067   iptr p = 0;
2068   ++p;
2069 }
2070 { /* AIX XL C 1.02.0.0 rejects this saying
2071      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2072   struct s { int j; const int *ap[3]; };
2073   struct s *b; b->j = 5;
2074 }
2075 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2076   const int foo = 10;
2077 }
2078
2079 ; return 0; }
2080 EOF
2081 if { (eval echo configure:2082: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2082   rm -rf conftest*
2083   ac_cv_c_const=yes
2084 else
2085   echo "configure: failed program was:" >&5
2086   cat conftest.$ac_ext >&5
2087   rm -rf conftest*
2088   ac_cv_c_const=no
2089 fi
2090 rm -f conftest*
2091 fi
2092
2093 echo "$ac_t""$ac_cv_c_const" 1>&6
2094 if test $ac_cv_c_const = no; then
2095   cat >> confdefs.h <<\EOF
2096 #define const 
2097 EOF
2098
2099 fi
2100
2101  echo $ac_n "checking for inline""... $ac_c" 1>&6
2102 echo "configure:2103: checking for inline" >&5
2103 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
2104   echo $ac_n "(cached) $ac_c" 1>&6
2105 else
2106   ac_cv_c_inline=no
2107 for ac_kw in inline __inline__ __inline; do
2108   cat > conftest.$ac_ext <<EOF
2109 #line 2110 "configure"
2110 #include "confdefs.h"
2111
2112 int main() {
2113 } $ac_kw foo() {
2114 ; return 0; }
2115 EOF
2116 if { (eval echo configure:2117: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2117   rm -rf conftest*
2118   ac_cv_c_inline=$ac_kw; break
2119 else
2120   echo "configure: failed program was:" >&5
2121   cat conftest.$ac_ext >&5
2122 fi
2123 rm -f conftest*
2124 done
2125
2126 fi
2127
2128 echo "$ac_t""$ac_cv_c_inline" 1>&6
2129 case "$ac_cv_c_inline" in
2130   inline | yes) ;;
2131   no) cat >> confdefs.h <<\EOF
2132 #define inline 
2133 EOF
2134  ;;
2135   *)  cat >> confdefs.h <<EOF
2136 #define inline $ac_cv_c_inline
2137 EOF
2138  ;;
2139 esac
2140
2141  echo $ac_n "checking for off_t""... $ac_c" 1>&6
2142 echo "configure:2143: checking for off_t" >&5
2143 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
2144   echo $ac_n "(cached) $ac_c" 1>&6
2145 else
2146   cat > conftest.$ac_ext <<EOF
2147 #line 2148 "configure"
2148 #include "confdefs.h"
2149 #include <sys/types.h>
2150 #if STDC_HEADERS
2151 #include <stdlib.h>
2152 #include <stddef.h>
2153 #endif
2154 EOF
2155 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2156   egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2157   rm -rf conftest*
2158   ac_cv_type_off_t=yes
2159 else
2160   rm -rf conftest*
2161   ac_cv_type_off_t=no
2162 fi
2163 rm -f conftest*
2164
2165 fi
2166 echo "$ac_t""$ac_cv_type_off_t" 1>&6
2167 if test $ac_cv_type_off_t = no; then
2168   cat >> confdefs.h <<\EOF
2169 #define off_t long
2170 EOF
2171
2172 fi
2173
2174  echo $ac_n "checking for size_t""... $ac_c" 1>&6
2175 echo "configure:2176: checking for size_t" >&5
2176 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
2177   echo $ac_n "(cached) $ac_c" 1>&6
2178 else
2179   cat > conftest.$ac_ext <<EOF
2180 #line 2181 "configure"
2181 #include "confdefs.h"
2182 #include <sys/types.h>
2183 #if STDC_HEADERS
2184 #include <stdlib.h>
2185 #include <stddef.h>
2186 #endif
2187 EOF
2188 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2189   egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2190   rm -rf conftest*
2191   ac_cv_type_size_t=yes
2192 else
2193   rm -rf conftest*
2194   ac_cv_type_size_t=no
2195 fi
2196 rm -f conftest*
2197
2198 fi
2199 echo "$ac_t""$ac_cv_type_size_t" 1>&6
2200 if test $ac_cv_type_size_t = no; then
2201   cat >> confdefs.h <<\EOF
2202 #define size_t unsigned
2203 EOF
2204
2205 fi
2206
2207  echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
2208 echo "configure:2209: checking whether struct tm is in sys/time.h or time.h" >&5
2209 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
2210   echo $ac_n "(cached) $ac_c" 1>&6
2211 else
2212   cat > conftest.$ac_ext <<EOF
2213 #line 2214 "configure"
2214 #include "confdefs.h"
2215 #include <sys/types.h>
2216 #include <time.h>
2217 int main() {
2218 struct tm *tp; tp->tm_sec;
2219 ; return 0; }
2220 EOF
2221 if { (eval echo configure:2222: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2222   rm -rf conftest*
2223   ac_cv_struct_tm=time.h
2224 else
2225   echo "configure: failed program was:" >&5
2226   cat conftest.$ac_ext >&5
2227   rm -rf conftest*
2228   ac_cv_struct_tm=sys/time.h
2229 fi
2230 rm -f conftest*
2231 fi
2232
2233 echo "$ac_t""$ac_cv_struct_tm" 1>&6
2234 if test $ac_cv_struct_tm = sys/time.h; then
2235   cat >> confdefs.h <<\EOF
2236 #define TM_IN_SYS_TIME 1
2237 EOF
2238
2239 fi
2240
2241      
2242  echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
2243 echo "configure:2244: checking for 8-bit clean memcmp" >&5
2244 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
2245   echo $ac_n "(cached) $ac_c" 1>&6
2246 else
2247   if test "$cross_compiling" = yes; then
2248   ac_cv_func_memcmp_clean=no
2249 else
2250   cat > conftest.$ac_ext <<EOF
2251 #line 2252 "configure"
2252 #include "confdefs.h"
2253
2254 main()
2255 {
2256   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
2257   exit(memcmp(&c0, &c2, 1) < 0 && memcmp(&c1, &c2, 1) < 0 ? 0 : 1);
2258 }
2259
2260 EOF
2261 if { (eval echo configure:2262: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2262 then
2263   ac_cv_func_memcmp_clean=yes
2264 else
2265   echo "configure: failed program was:" >&5
2266   cat conftest.$ac_ext >&5
2267   rm -fr conftest*
2268   ac_cv_func_memcmp_clean=no
2269 fi
2270 rm -fr conftest*
2271 fi
2272
2273 fi
2274
2275 echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6
2276 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}"
2277
2278  for ac_hdr in unistd.h
2279 do
2280 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2281 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2282 echo "configure:2283: checking for $ac_hdr" >&5
2283 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2284   echo $ac_n "(cached) $ac_c" 1>&6
2285 else
2286   cat > conftest.$ac_ext <<EOF
2287 #line 2288 "configure"
2288 #include "confdefs.h"
2289 #include <$ac_hdr>
2290 EOF
2291 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2292 { (eval echo configure:2293: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2293 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2294 if test -z "$ac_err"; then
2295   rm -rf conftest*
2296   eval "ac_cv_header_$ac_safe=yes"
2297 else
2298   echo "$ac_err" >&5
2299   echo "configure: failed program was:" >&5
2300   cat conftest.$ac_ext >&5
2301   rm -rf conftest*
2302   eval "ac_cv_header_$ac_safe=no"
2303 fi
2304 rm -f conftest*
2305 fi
2306 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2307   echo "$ac_t""yes" 1>&6
2308     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2309   cat >> confdefs.h <<EOF
2310 #define $ac_tr_hdr 1
2311 EOF
2312  
2313 else
2314   echo "$ac_t""no" 1>&6
2315 fi
2316 done
2317
2318 for ac_func in getpagesize
2319 do
2320 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2321 echo "configure:2322: checking for $ac_func" >&5
2322 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2323   echo $ac_n "(cached) $ac_c" 1>&6
2324 else
2325   cat > conftest.$ac_ext <<EOF
2326 #line 2327 "configure"
2327 #include "confdefs.h"
2328 /* System header to define __stub macros and hopefully few prototypes,
2329     which can conflict with char $ac_func(); below.  */
2330 #include <assert.h>
2331 /* Override any gcc2 internal prototype to avoid an error.  */
2332 /* We use char because int might match the return type of a gcc2
2333     builtin and then its argument prototype would still apply.  */
2334 char $ac_func();
2335
2336 int main() {
2337
2338 /* The GNU C library defines this for functions which it implements
2339     to always fail with ENOSYS.  Some functions are actually named
2340     something starting with __ and the normal name is an alias.  */
2341 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2342 choke me
2343 #else
2344 $ac_func();
2345 #endif
2346
2347 ; return 0; }
2348 EOF
2349 if { (eval echo configure:2350: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2350   rm -rf conftest*
2351   eval "ac_cv_func_$ac_func=yes"
2352 else
2353   echo "configure: failed program was:" >&5
2354   cat conftest.$ac_ext >&5
2355   rm -rf conftest*
2356   eval "ac_cv_func_$ac_func=no"
2357 fi
2358 rm -f conftest*
2359 fi
2360
2361 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2362   echo "$ac_t""yes" 1>&6
2363     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2364   cat >> confdefs.h <<EOF
2365 #define $ac_tr_func 1
2366 EOF
2367  
2368 else
2369   echo "$ac_t""no" 1>&6
2370 fi
2371 done
2372
2373 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
2374 echo "configure:2375: checking for working mmap" >&5
2375 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
2376   echo $ac_n "(cached) $ac_c" 1>&6
2377 else
2378   if test "$cross_compiling" = yes; then
2379   ac_cv_func_mmap_fixed_mapped=no
2380 else
2381   cat > conftest.$ac_ext <<EOF
2382 #line 2383 "configure"
2383 #include "confdefs.h"
2384
2385 /* Thanks to Mike Haertel and Jim Avera for this test.
2386    Here is a matrix of mmap possibilities:
2387         mmap private not fixed
2388         mmap private fixed at somewhere currently unmapped
2389         mmap private fixed at somewhere already mapped
2390         mmap shared not fixed
2391         mmap shared fixed at somewhere currently unmapped
2392         mmap shared fixed at somewhere already mapped
2393    For private mappings, we should verify that changes cannot be read()
2394    back from the file, nor mmap's back from the file at a different
2395    address.  (There have been systems where private was not correctly
2396    implemented like the infamous i386 svr4.0, and systems where the
2397    VM page cache was not coherent with the filesystem buffer cache
2398    like early versions of FreeBSD and possibly contemporary NetBSD.)
2399    For shared mappings, we should conversely verify that changes get
2400    propogated back to all the places they're supposed to be.
2401
2402    Grep wants private fixed already mapped.
2403    The main things grep needs to know about mmap are:
2404    * does it exist and is it safe to write into the mmap'd area
2405    * how to use it (BSD variants)  */
2406 #include <sys/types.h>
2407 #include <fcntl.h>
2408 #include <sys/mman.h>
2409
2410 /* This mess was copied from the GNU getpagesize.h.  */
2411 #ifndef HAVE_GETPAGESIZE
2412 # ifdef HAVE_UNISTD_H
2413 #  include <unistd.h>
2414 # endif
2415
2416 /* Assume that all systems that can run configure have sys/param.h.  */
2417 # ifndef HAVE_SYS_PARAM_H
2418 #  define HAVE_SYS_PARAM_H 1
2419 # endif
2420
2421 # ifdef _SC_PAGESIZE
2422 #  define getpagesize() sysconf(_SC_PAGESIZE)
2423 # else /* no _SC_PAGESIZE */
2424 #  ifdef HAVE_SYS_PARAM_H
2425 #   include <sys/param.h>
2426 #   ifdef EXEC_PAGESIZE
2427 #    define getpagesize() EXEC_PAGESIZE
2428 #   else /* no EXEC_PAGESIZE */
2429 #    ifdef NBPG
2430 #     define getpagesize() NBPG * CLSIZE
2431 #     ifndef CLSIZE
2432 #      define CLSIZE 1
2433 #     endif /* no CLSIZE */
2434 #    else /* no NBPG */
2435 #     ifdef NBPC
2436 #      define getpagesize() NBPC
2437 #     else /* no NBPC */
2438 #      ifdef PAGESIZE
2439 #       define getpagesize() PAGESIZE
2440 #      endif /* PAGESIZE */
2441 #     endif /* no NBPC */
2442 #    endif /* no NBPG */
2443 #   endif /* no EXEC_PAGESIZE */
2444 #  else /* no HAVE_SYS_PARAM_H */
2445 #   define getpagesize() 8192   /* punt totally */
2446 #  endif /* no HAVE_SYS_PARAM_H */
2447 # endif /* no _SC_PAGESIZE */
2448
2449 #endif /* no HAVE_GETPAGESIZE */
2450
2451 #ifdef __cplusplus
2452 extern "C" { void *malloc(unsigned); }
2453 #else
2454 char *malloc();
2455 #endif
2456
2457 int
2458 main()
2459 {
2460         char *data, *data2, *data3;
2461         int i, pagesize;
2462         int fd;
2463
2464         pagesize = getpagesize();
2465
2466         /*
2467          * First, make a file with some known garbage in it.
2468          */
2469         data = malloc(pagesize);
2470         if (!data)
2471                 exit(1);
2472         for (i = 0; i < pagesize; ++i)
2473                 *(data + i) = rand();
2474         umask(0);
2475         fd = creat("conftestmmap", 0600);
2476         if (fd < 0)
2477                 exit(1);
2478         if (write(fd, data, pagesize) != pagesize)
2479                 exit(1);
2480         close(fd);
2481
2482         /*
2483          * Next, try to mmap the file at a fixed address which
2484          * already has something else allocated at it.  If we can,
2485          * also make sure that we see the same garbage.
2486          */
2487         fd = open("conftestmmap", O_RDWR);
2488         if (fd < 0)
2489                 exit(1);
2490         data2 = malloc(2 * pagesize);
2491         if (!data2)
2492                 exit(1);
2493         data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
2494         if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
2495             MAP_PRIVATE | MAP_FIXED, fd, 0L))
2496                 exit(1);
2497         for (i = 0; i < pagesize; ++i)
2498                 if (*(data + i) != *(data2 + i))
2499                         exit(1);
2500
2501         /*
2502          * Finally, make sure that changes to the mapped area
2503          * do not percolate back to the file as seen by read().
2504          * (This is a bug on some variants of i386 svr4.0.)
2505          */
2506         for (i = 0; i < pagesize; ++i)
2507                 *(data2 + i) = *(data2 + i) + 1;
2508         data3 = malloc(pagesize);
2509         if (!data3)
2510                 exit(1);
2511         if (read(fd, data3, pagesize) != pagesize)
2512                 exit(1);
2513         for (i = 0; i < pagesize; ++i)
2514                 if (*(data + i) != *(data3 + i))
2515                         exit(1);
2516         close(fd);
2517         unlink("conftestmmap");
2518         exit(0);
2519 }
2520
2521 EOF
2522 if { (eval echo configure:2523: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2523 then
2524   ac_cv_func_mmap_fixed_mapped=yes
2525 else
2526   echo "configure: failed program was:" >&5
2527   cat conftest.$ac_ext >&5
2528   rm -fr conftest*
2529   ac_cv_func_mmap_fixed_mapped=no
2530 fi
2531 rm -fr conftest*
2532 fi
2533
2534 fi
2535
2536 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
2537 if test $ac_cv_func_mmap_fixed_mapped = yes; then
2538   cat >> confdefs.h <<\EOF
2539 #define HAVE_MMAP 1
2540 EOF
2541
2542 fi
2543
2544  echo $ac_n "checking for vprintf""... $ac_c" 1>&6
2545 echo "configure:2546: checking for vprintf" >&5
2546 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
2547   echo $ac_n "(cached) $ac_c" 1>&6
2548 else
2549   cat > conftest.$ac_ext <<EOF
2550 #line 2551 "configure"
2551 #include "confdefs.h"
2552 /* System header to define __stub macros and hopefully few prototypes,
2553     which can conflict with char vprintf(); below.  */
2554 #include <assert.h>
2555 /* Override any gcc2 internal prototype to avoid an error.  */
2556 /* We use char because int might match the return type of a gcc2
2557     builtin and then its argument prototype would still apply.  */
2558 char vprintf();
2559
2560 int main() {
2561
2562 /* The GNU C library defines this for functions which it implements
2563     to always fail with ENOSYS.  Some functions are actually named
2564     something starting with __ and the normal name is an alias.  */
2565 #if defined (__stub_vprintf) || defined (__stub___vprintf)
2566 choke me
2567 #else
2568 vprintf();
2569 #endif
2570
2571 ; return 0; }
2572 EOF
2573 if { (eval echo configure:2574: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2574   rm -rf conftest*
2575   eval "ac_cv_func_vprintf=yes"
2576 else
2577   echo "configure: failed program was:" >&5
2578   cat conftest.$ac_ext >&5
2579   rm -rf conftest*
2580   eval "ac_cv_func_vprintf=no"
2581 fi
2582 rm -f conftest*
2583 fi
2584
2585 if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then
2586   echo "$ac_t""yes" 1>&6
2587   cat >> confdefs.h <<\EOF
2588 #define HAVE_VPRINTF 1
2589 EOF
2590
2591 else
2592   echo "$ac_t""no" 1>&6
2593 fi
2594
2595 if test "$ac_cv_func_vprintf" != yes; then
2596 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
2597 echo "configure:2598: checking for _doprnt" >&5
2598 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
2599   echo $ac_n "(cached) $ac_c" 1>&6
2600 else
2601   cat > conftest.$ac_ext <<EOF
2602 #line 2603 "configure"
2603 #include "confdefs.h"
2604 /* System header to define __stub macros and hopefully few prototypes,
2605     which can conflict with char _doprnt(); below.  */
2606 #include <assert.h>
2607 /* Override any gcc2 internal prototype to avoid an error.  */
2608 /* We use char because int might match the return type of a gcc2
2609     builtin and then its argument prototype would still apply.  */
2610 char _doprnt();
2611
2612 int main() {
2613
2614 /* The GNU C library defines this for functions which it implements
2615     to always fail with ENOSYS.  Some functions are actually named
2616     something starting with __ and the normal name is an alias.  */
2617 #if defined (__stub__doprnt) || defined (__stub____doprnt)
2618 choke me
2619 #else
2620 _doprnt();
2621 #endif
2622
2623 ; return 0; }
2624 EOF
2625 if { (eval echo configure:2626: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2626   rm -rf conftest*
2627   eval "ac_cv_func__doprnt=yes"
2628 else
2629   echo "configure: failed program was:" >&5
2630   cat conftest.$ac_ext >&5
2631   rm -rf conftest*
2632   eval "ac_cv_func__doprnt=no"
2633 fi
2634 rm -f conftest*
2635 fi
2636
2637 if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then
2638   echo "$ac_t""yes" 1>&6
2639   cat >> confdefs.h <<\EOF
2640 #define HAVE_DOPRNT 1
2641 EOF
2642
2643 else
2644   echo "$ac_t""no" 1>&6
2645 fi
2646
2647 fi
2648
2649  for ac_func in getcwd putenv socket strcspn strdup strerror strstr
2650 do
2651 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2652 echo "configure:2653: checking for $ac_func" >&5
2653 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2654   echo $ac_n "(cached) $ac_c" 1>&6
2655 else
2656   cat > conftest.$ac_ext <<EOF
2657 #line 2658 "configure"
2658 #include "confdefs.h"
2659 /* System header to define __stub macros and hopefully few prototypes,
2660     which can conflict with char $ac_func(); below.  */
2661 #include <assert.h>
2662 /* Override any gcc2 internal prototype to avoid an error.  */
2663 /* We use char because int might match the return type of a gcc2
2664     builtin and then its argument prototype would still apply.  */
2665 char $ac_func();
2666
2667 int main() {
2668
2669 /* The GNU C library defines this for functions which it implements
2670     to always fail with ENOSYS.  Some functions are actually named
2671     something starting with __ and the normal name is an alias.  */
2672 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2673 choke me
2674 #else
2675 $ac_func();
2676 #endif
2677
2678 ; return 0; }
2679 EOF
2680 if { (eval echo configure:2681: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2681   rm -rf conftest*
2682   eval "ac_cv_func_$ac_func=yes"
2683 else
2684   echo "configure: failed program was:" >&5
2685   cat conftest.$ac_ext >&5
2686   rm -rf conftest*
2687   eval "ac_cv_func_$ac_func=no"
2688 fi
2689 rm -f conftest*
2690 fi
2691
2692 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2693   echo "$ac_t""yes" 1>&6
2694     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2695   cat >> confdefs.h <<EOF
2696 #define $ac_tr_func 1
2697 EOF
2698  
2699 else
2700   echo "$ac_t""no" 1>&6
2701 fi
2702 done
2703
2704
2705 export JPEG2SWF='jpeg2swf$(EXEEXT)'
2706 if test "x${DISABLEPDF2SWF}" = "xtrue"; then
2707   echo "***************************************************"
2708   echo "The following headers/libraries are missing: " ${MISSINGLIBS}
2709   echo "Disabling pdf2swf tool..."
2710   rm -f pdf2swf/Makefile
2711   echo all: > pdf2swf/Makefile
2712   echo install: >> pdf2swf/Makefile
2713   if test "x${DISABLEJPEG2SWF}" = "xtrue"; then
2714     echo "Disabling jpeg2swf tool..."
2715     export JPEG2SWF=
2716   fi
2717   echo "***************************************************"
2718   FILES="./release Makefile lib/Makefile src/Makefile"
2719 else
2720   FILES="./release Makefile lib/Makefile src/Makefile pdf2swf/Makefile pdf2swf/xpdf/Makefile pdf2swf/fonts/Makefile"
2721 fi
2722
2723
2724 trap '' 1 2 15
2725 cat > confcache <<\EOF
2726 # This file is a shell script that caches the results of configure
2727 # tests run on this system so they can be shared between configure
2728 # scripts and configure runs.  It is not useful on other systems.
2729 # If it contains results you don't want to keep, you may remove or edit it.
2730 #
2731 # By default, configure uses ./config.cache as the cache file,
2732 # creating it if it does not exist already.  You can give configure
2733 # the --cache-file=FILE option to use a different cache file; that is
2734 # what configure does when it calls configure scripts in
2735 # subdirectories, so they share the cache.
2736 # Giving --cache-file=/dev/null disables caching, for debugging configure.
2737 # config.status only pays attention to the cache file if you give it the
2738 # --recheck option to rerun configure.
2739 #
2740 EOF
2741 # The following way of writing the cache mishandles newlines in values,
2742 # but we know of no workaround that is simple, portable, and efficient.
2743 # So, don't put newlines in cache variables' values.
2744 # Ultrix sh set writes to stderr and can't be redirected directly,
2745 # and sets the high bit in the cache file unless we assign to the vars.
2746 (set) 2>&1 |
2747   case `(ac_space=' '; set | grep ac_space) 2>&1` in
2748   *ac_space=\ *)
2749     # `set' does not quote correctly, so add quotes (double-quote substitution
2750     # turns \\\\ into \\, and sed turns \\ into \).
2751     sed -n \
2752       -e "s/'/'\\\\''/g" \
2753       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2754     ;;
2755   *)
2756     # `set' quotes correctly as required by POSIX, so do not add quotes.
2757     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2758     ;;
2759   esac >> confcache
2760 if cmp -s $cache_file confcache; then
2761   :
2762 else
2763   if test -w $cache_file; then
2764     echo "updating cache $cache_file"
2765     cat confcache > $cache_file
2766   else
2767     echo "not updating unwritable cache $cache_file"
2768   fi
2769 fi
2770 rm -f confcache
2771
2772 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2773
2774 test "x$prefix" = xNONE && prefix=$ac_default_prefix
2775 # Let make expand exec_prefix.
2776 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2777
2778 # Any assignment to VPATH causes Sun make to only execute
2779 # the first set of double-colon rules, so remove it if not needed.
2780 # If there is a colon in the path, we need to keep it.
2781 if test "x$srcdir" = x.; then
2782   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
2783 fi
2784
2785 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2786
2787 DEFS=-DHAVE_CONFIG_H
2788
2789 # Without the "./", some shells look in PATH for config.status.
2790 : ${CONFIG_STATUS=./config.status}
2791
2792 echo creating $CONFIG_STATUS
2793 rm -f $CONFIG_STATUS
2794 cat > $CONFIG_STATUS <<EOF
2795 #! /bin/sh
2796 # Generated automatically by configure.
2797 # Run this file to recreate the current configuration.
2798 # This directory was configured as follows,
2799 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2800 #
2801 # $0 $ac_configure_args
2802 #
2803 # Compiler output produced by configure, useful for debugging
2804 # configure, is in ./config.log if it exists.
2805
2806 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2807 for ac_option
2808 do
2809   case "\$ac_option" in
2810   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2811     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2812     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2813   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2814     echo "$CONFIG_STATUS generated by autoconf version 2.13"
2815     exit 0 ;;
2816   -help | --help | --hel | --he | --h)
2817     echo "\$ac_cs_usage"; exit 0 ;;
2818   *) echo "\$ac_cs_usage"; exit 1 ;;
2819   esac
2820 done
2821
2822 ac_given_srcdir=$srcdir
2823 ac_given_INSTALL="$INSTALL"
2824
2825 trap 'rm -fr `echo "${FILES} config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2826 EOF
2827 cat >> $CONFIG_STATUS <<EOF
2828
2829 # Protect against being on the right side of a sed subst in config.status.
2830 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2831  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2832 $ac_vpsub
2833 $extrasub
2834 s%@SHELL@%$SHELL%g
2835 s%@CFLAGS@%$CFLAGS%g
2836 s%@CPPFLAGS@%$CPPFLAGS%g
2837 s%@CXXFLAGS@%$CXXFLAGS%g
2838 s%@FFLAGS@%$FFLAGS%g
2839 s%@DEFS@%$DEFS%g
2840 s%@LDFLAGS@%$LDFLAGS%g
2841 s%@LIBS@%$LIBS%g
2842 s%@exec_prefix@%$exec_prefix%g
2843 s%@prefix@%$prefix%g
2844 s%@program_transform_name@%$program_transform_name%g
2845 s%@bindir@%$bindir%g
2846 s%@sbindir@%$sbindir%g
2847 s%@libexecdir@%$libexecdir%g
2848 s%@datadir@%$datadir%g
2849 s%@sysconfdir@%$sysconfdir%g
2850 s%@sharedstatedir@%$sharedstatedir%g
2851 s%@localstatedir@%$localstatedir%g
2852 s%@libdir@%$libdir%g
2853 s%@includedir@%$includedir%g
2854 s%@oldincludedir@%$oldincludedir%g
2855 s%@infodir@%$infodir%g
2856 s%@mandir@%$mandir%g
2857 s%@AWK@%$AWK%g
2858 s%@CC@%$CC%g
2859 s%@CPP@%$CPP%g
2860 s%@CXX@%$CXX%g
2861 s%@RANLIB@%$RANLIB%g
2862 s%@SET_MAKE@%$SET_MAKE%g
2863 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2864 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
2865 s%@INSTALL_DATA@%$INSTALL_DATA%g
2866 s%@LN_S@%$LN_S%g
2867 s%@EXEEXT@%$EXEEXT%g
2868 s%@PACKAGE@%$PACKAGE%g
2869 s%@VERSION@%$VERSION%g
2870 s%@HAVE_UNISTD_H@%$HAVE_UNISTD_H%g
2871 s%@LIBOBJS@%$LIBOBJS%g
2872 s%@JPEG2SWF@%$JPEG2SWF%g
2873
2874 CEOF
2875 EOF
2876
2877 cat >> $CONFIG_STATUS <<\EOF
2878
2879 # Split the substitutions into bite-sized pieces for seds with
2880 # small command number limits, like on Digital OSF/1 and HP-UX.
2881 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
2882 ac_file=1 # Number of current file.
2883 ac_beg=1 # First line for current file.
2884 ac_end=$ac_max_sed_cmds # Line after last line for current file.
2885 ac_more_lines=:
2886 ac_sed_cmds=""
2887 while $ac_more_lines; do
2888   if test $ac_beg -gt 1; then
2889     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
2890   else
2891     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
2892   fi
2893   if test ! -s conftest.s$ac_file; then
2894     ac_more_lines=false
2895     rm -f conftest.s$ac_file
2896   else
2897     if test -z "$ac_sed_cmds"; then
2898       ac_sed_cmds="sed -f conftest.s$ac_file"
2899     else
2900       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
2901     fi
2902     ac_file=`expr $ac_file + 1`
2903     ac_beg=$ac_end
2904     ac_end=`expr $ac_end + $ac_max_sed_cmds`
2905   fi
2906 done
2907 if test -z "$ac_sed_cmds"; then
2908   ac_sed_cmds=cat
2909 fi
2910 EOF
2911
2912 cat >> $CONFIG_STATUS <<EOF
2913
2914 CONFIG_FILES=\${CONFIG_FILES-"${FILES}"}
2915 EOF
2916 cat >> $CONFIG_STATUS <<\EOF
2917 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2918   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2919   case "$ac_file" in
2920   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2921        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2922   *) ac_file_in="${ac_file}.in" ;;
2923   esac
2924
2925   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
2926
2927   # Remove last slash and all that follows it.  Not all systems have dirname.
2928   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2929   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2930     # The file is in a subdirectory.
2931     test ! -d "$ac_dir" && mkdir "$ac_dir"
2932     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2933     # A "../" for each directory in $ac_dir_suffix.
2934     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2935   else
2936     ac_dir_suffix= ac_dots=
2937   fi
2938
2939   case "$ac_given_srcdir" in
2940   .)  srcdir=.
2941       if test -z "$ac_dots"; then top_srcdir=.
2942       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2943   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2944   *) # Relative path.
2945     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2946     top_srcdir="$ac_dots$ac_given_srcdir" ;;
2947   esac
2948
2949   case "$ac_given_INSTALL" in
2950   [/$]*) INSTALL="$ac_given_INSTALL" ;;
2951   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2952   esac
2953
2954   echo creating "$ac_file"
2955   rm -f "$ac_file"
2956   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2957   case "$ac_file" in
2958   *Makefile*) ac_comsub="1i\\
2959 # $configure_input" ;;
2960   *) ac_comsub= ;;
2961   esac
2962
2963   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2964   sed -e "$ac_comsub
2965 s%@configure_input@%$configure_input%g
2966 s%@srcdir@%$srcdir%g
2967 s%@top_srcdir@%$top_srcdir%g
2968 s%@INSTALL@%$INSTALL%g
2969 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
2970 fi; done
2971 rm -f conftest.s*
2972
2973 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
2974 # NAME is the cpp macro being defined and VALUE is the value it is being given.
2975 #
2976 # ac_d sets the value in "#define NAME VALUE" lines.
2977 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
2978 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
2979 ac_dC='\3'
2980 ac_dD='%g'
2981 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
2982 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
2983 ac_uB='\([      ]\)%\1#\2define\3'
2984 ac_uC=' '
2985 ac_uD='\4%g'
2986 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
2987 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
2988 ac_eB='$%\1#\2define\3'
2989 ac_eC=' '
2990 ac_eD='%g'
2991
2992 if test "${CONFIG_HEADERS+set}" != set; then
2993 EOF
2994 cat >> $CONFIG_STATUS <<EOF
2995   CONFIG_HEADERS="config.h"
2996 EOF
2997 cat >> $CONFIG_STATUS <<\EOF
2998 fi
2999 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
3000   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3001   case "$ac_file" in
3002   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3003        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3004   *) ac_file_in="${ac_file}.in" ;;
3005   esac
3006
3007   echo creating $ac_file
3008
3009   rm -f conftest.frag conftest.in conftest.out
3010   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3011   cat $ac_file_inputs > conftest.in
3012
3013 EOF
3014
3015 # Transform confdefs.h into a sed script conftest.vals that substitutes
3016 # the proper values into config.h.in to produce config.h.  And first:
3017 # Protect against being on the right side of a sed subst in config.status.
3018 # Protect against being in an unquoted here document in config.status.
3019 rm -f conftest.vals
3020 cat > conftest.hdr <<\EOF
3021 s/[\\&%]/\\&/g
3022 s%[\\$`]%\\&%g
3023 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
3024 s%ac_d%ac_u%gp
3025 s%ac_u%ac_e%gp
3026 EOF
3027 sed -n -f conftest.hdr confdefs.h > conftest.vals
3028 rm -f conftest.hdr
3029
3030 # This sed command replaces #undef with comments.  This is necessary, for
3031 # example, in the case of _POSIX_SOURCE, which is predefined and required
3032 # on some systems where configure will not decide to define it.
3033 cat >> conftest.vals <<\EOF
3034 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
3035 EOF
3036
3037 # Break up conftest.vals because some shells have a limit on
3038 # the size of here documents, and old seds have small limits too.
3039
3040 rm -f conftest.tail
3041 while :
3042 do
3043   ac_lines=`grep -c . conftest.vals`
3044   # grep -c gives empty output for an empty file on some AIX systems.
3045   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
3046   # Write a limited-size here document to conftest.frag.
3047   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
3048   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
3049   echo 'CEOF
3050   sed -f conftest.frag conftest.in > conftest.out
3051   rm -f conftest.in
3052   mv conftest.out conftest.in
3053 ' >> $CONFIG_STATUS
3054   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
3055   rm -f conftest.vals
3056   mv conftest.tail conftest.vals
3057 done
3058 rm -f conftest.vals
3059
3060 cat >> $CONFIG_STATUS <<\EOF
3061   rm -f conftest.frag conftest.h
3062   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
3063   cat conftest.in >> conftest.h
3064   rm -f conftest.in
3065   if cmp -s $ac_file conftest.h 2>/dev/null; then
3066     echo "$ac_file is unchanged"
3067     rm -f conftest.h
3068   else
3069     # Remove last slash and all that follows it.  Not all systems have dirname.
3070       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3071       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3072       # The file is in a subdirectory.
3073       test ! -d "$ac_dir" && mkdir "$ac_dir"
3074     fi
3075     rm -f $ac_file
3076     mv conftest.h $ac_file
3077   fi
3078 fi; done
3079
3080 EOF
3081 cat >> $CONFIG_STATUS <<EOF
3082
3083 EOF
3084 cat >> $CONFIG_STATUS <<\EOF
3085
3086 exit 0
3087 EOF
3088 chmod +x $CONFIG_STATUS
3089 rm -fr confdefs* $ac_clean_files
3090 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
3091