root/trunk/configure

Revision 96, 63.8 kB (checked in by tibob, 6 years ago)

- added an option in ./configure to activate additional IP checks
- updated TODO

  • Property svn:eol-style set to native
  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
Line 
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:
11ac_help=
12ac_default_prefix=/usr/local
13# Any additions from configure.in:
14ac_help="$ac_help
15  --enable-debug-messages      Use debug messages"
16ac_help="$ac_help
17  --enable-ip-check      Additional IP packets checks"
18
19# Initialize some variables set by options.
20# The variables have the same names as the options, with
21# dashes changed to underlines.
22build=NONE
23cache_file=./config.cache
24exec_prefix=NONE
25host=NONE
26no_create=
27nonopt=NONE
28no_recursion=
29prefix=NONE
30program_prefix=NONE
31program_suffix=NONE
32program_transform_name=s,x,x,
33silent=
34site=
35srcdir=
36target=NONE
37verbose=
38x_includes=NONE
39x_libraries=NONE
40bindir='${exec_prefix}/bin'
41sbindir='${exec_prefix}/sbin'
42libexecdir='${exec_prefix}/libexec'
43datadir='${prefix}/share'
44sysconfdir='${prefix}/etc'
45sharedstatedir='${prefix}/com'
46localstatedir='${prefix}/var'
47libdir='${exec_prefix}/lib'
48includedir='${prefix}/include'
49oldincludedir='/usr/include'
50infodir='${prefix}/info'
51mandir='${prefix}/man'
52
53# Initialize some other variables.
54subdirs=
55MFLAGS= MAKEFLAGS=
56SHELL=${CONFIG_SHELL-/bin/sh}
57# Maximum number of lines to put in a shell here document.
58ac_max_here_lines=12
59
60ac_prev=
61for ac_option
62do
63
64  # If the previous option needs an argument, assign it.
65  if test -n "$ac_prev"; then
66    eval "$ac_prev=\$ac_option"
67    ac_prev=
68    continue
69  fi
70
71  case "$ac_option" in
72  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
73  *) ac_optarg= ;;
74  esac
75
76  # Accept the important Cygnus configure options, so we can diagnose typos.
77
78  case "$ac_option" in
79
80  -bindir | --bindir | --bindi | --bind | --bin | --bi)
81    ac_prev=bindir ;;
82  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
83    bindir="$ac_optarg" ;;
84
85  -build | --build | --buil | --bui | --bu)
86    ac_prev=build ;;
87  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
88    build="$ac_optarg" ;;
89
90  -cache-file | --cache-file | --cache-fil | --cache-fi \
91  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
92    ac_prev=cache_file ;;
93  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
94  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
95    cache_file="$ac_optarg" ;;
96
97  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
98    ac_prev=datadir ;;
99  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
100  | --da=*)
101    datadir="$ac_optarg" ;;
102
103  -disable-* | --disable-*)
104    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
105    # Reject names that are not valid shell variable names.
106    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
107      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
108    fi
109    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
110    eval "enable_${ac_feature}=no" ;;
111
112  -enable-* | --enable-*)
113    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
114    # Reject names that are not valid shell variable names.
115    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
116      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
117    fi
118    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
119    case "$ac_option" in
120      *=*) ;;
121      *) ac_optarg=yes ;;
122    esac
123    eval "enable_${ac_feature}='$ac_optarg'" ;;
124
125  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
126  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
127  | --exec | --exe | --ex)
128    ac_prev=exec_prefix ;;
129  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
130  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
131  | --exec=* | --exe=* | --ex=*)
132    exec_prefix="$ac_optarg" ;;
133
134  -gas | --gas | --ga | --g)
135    # Obsolete; use --with-gas.
136    with_gas=yes ;;
137
138  -help | --help | --hel | --he)
139    # Omit some internal or obsolete options to make the list less imposing.
140    # This message is too long to be a string in the A/UX 3.1 sh.
141    cat << EOF
142Usage: configure [options] [host]
143Options: [defaults in brackets after descriptions]
144Configuration:
145  --cache-file=FILE       cache test results in FILE
146  --help                  print this message
147  --no-create             do not create output files
148  --quiet, --silent       do not print \`checking...' messages
149  --version               print the version of autoconf that created configure
150Directory and file names:
151  --prefix=PREFIX         install architecture-independent files in PREFIX
152                          [$ac_default_prefix]
153  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
154                          [same as prefix]
155  --bindir=DIR            user executables in DIR [EPREFIX/bin]
156  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
157  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
158  --datadir=DIR           read-only architecture-independent data in DIR
159                          [PREFIX/share]
160  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
161  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
162                          [PREFIX/com]
163  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
164  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
165  --includedir=DIR        C header files in DIR [PREFIX/include]
166  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
167  --infodir=DIR           info documentation in DIR [PREFIX/info]
168  --mandir=DIR            man documentation in DIR [PREFIX/man]
169  --srcdir=DIR            find the sources in DIR [configure dir or ..]
170  --program-prefix=PREFIX prepend PREFIX to installed program names
171  --program-suffix=SUFFIX append SUFFIX to installed program names
172  --program-transform-name=PROGRAM
173                          run sed PROGRAM on installed program names
174EOF
175    cat << EOF
176Host type:
177  --build=BUILD           configure for building on BUILD [BUILD=HOST]
178  --host=HOST             configure for HOST [guessed]
179  --target=TARGET         configure for TARGET [TARGET=HOST]
180Features and packages:
181  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
182  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
183  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
184  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
185  --x-includes=DIR        X include files are in DIR
186  --x-libraries=DIR       X library files are in DIR
187EOF
188    if test -n "$ac_help"; then
189      echo "--enable and --with options recognized:$ac_help"
190    fi
191    exit 0 ;;
192
193  -host | --host | --hos | --ho)
194    ac_prev=host ;;
195  -host=* | --host=* | --hos=* | --ho=*)
196    host="$ac_optarg" ;;
197
198  -includedir | --includedir | --includedi | --included | --include \
199  | --includ | --inclu | --incl | --inc)
200    ac_prev=includedir ;;
201  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
202  | --includ=* | --inclu=* | --incl=* | --inc=*)
203    includedir="$ac_optarg" ;;
204
205  -infodir | --infodir | --infodi | --infod | --info | --inf)
206    ac_prev=infodir ;;
207  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
208    infodir="$ac_optarg" ;;
209
210  -libdir | --libdir | --libdi | --libd)
211    ac_prev=libdir ;;
212  -libdir=* | --libdir=* | --libdi=* | --libd=*)
213    libdir="$ac_optarg" ;;
214
215  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
216  | --libexe | --libex | --libe)
217    ac_prev=libexecdir ;;
218  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
219  | --libexe=* | --libex=* | --libe=*)
220    libexecdir="$ac_optarg" ;;
221
222  -localstatedir | --localstatedir | --localstatedi | --localstated \
223  | --localstate | --localstat | --localsta | --localst \
224  | --locals | --local | --loca | --loc | --lo)
225    ac_prev=localstatedir ;;
226  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
227  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
228  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
229    localstatedir="$ac_optarg" ;;
230
231  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
232    ac_prev=mandir ;;
233  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
234    mandir="$ac_optarg" ;;
235
236  -nfp | --nfp | --nf)
237    # Obsolete; use --without-fp.
238    with_fp=no ;;
239
240  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
241  | --no-cr | --no-c)
242    no_create=yes ;;
243
244  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
245  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
246    no_recursion=yes ;;
247
248  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
249  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
250  | --oldin | --oldi | --old | --ol | --o)
251    ac_prev=oldincludedir ;;
252  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
253  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
254  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
255    oldincludedir="$ac_optarg" ;;
256
257  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
258    ac_prev=prefix ;;
259  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
260    prefix="$ac_optarg" ;;
261
262  -program-prefix | --program-prefix | --program-prefi | --program-pref \
263  | --program-pre | --program-pr | --program-p)
264    ac_prev=program_prefix ;;
265  -program-prefix=* | --program-prefix=* | --program-prefi=* \
266  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
267    program_prefix="$ac_optarg" ;;
268
269  -program-suffix | --program-suffix | --program-suffi | --program-suff \
270  | --program-suf | --program-su | --program-s)
271    ac_prev=program_suffix ;;
272  -program-suffix=* | --program-suffix=* | --program-suffi=* \
273  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
274    program_suffix="$ac_optarg" ;;
275
276  -program-transform-name | --program-transform-name \
277  | --program-transform-nam | --program-transform-na \
278  | --program-transform-n | --program-transform- \
279  | --program-transform | --program-transfor \
280  | --program-transfo | --program-transf \
281  | --program-trans | --program-tran \
282  | --progr-tra | --program-tr | --program-t)
283    ac_prev=program_transform_name ;;
284  -program-transform-name=* | --program-transform-name=* \
285  | --program-transform-nam=* | --program-transform-na=* \
286  | --program-transform-n=* | --program-transform-=* \
287  | --program-transform=* | --program-transfor=* \
288  | --program-transfo=* | --program-transf=* \
289  | --program-trans=* | --program-tran=* \
290  | --progr-tra=* | --program-tr=* | --program-t=*)
291    program_transform_name="$ac_optarg" ;;
292
293  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
294  | -silent | --silent | --silen | --sile | --sil)
295    silent=yes ;;
296
297  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
298    ac_prev=sbindir ;;
299  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
300  | --sbi=* | --sb=*)
301    sbindir="$ac_optarg" ;;
302
303  -sharedstatedir | --sharedstatedir | --sharedstatedi \
304  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
305  | --sharedst | --shareds | --shared | --share | --shar \
306  | --sha | --sh)
307    ac_prev=sharedstatedir ;;
308  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
309  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
310  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
311  | --sha=* | --sh=*)
312    sharedstatedir="$ac_optarg" ;;
313
314  -site | --site | --sit)
315    ac_prev=site ;;
316  -site=* | --site=* | --sit=*)
317    site="$ac_optarg" ;;
318
319  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
320    ac_prev=srcdir ;;
321  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
322    srcdir="$ac_optarg" ;;
323
324  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
325  | --syscon | --sysco | --sysc | --sys | --sy)
326    ac_prev=sysconfdir ;;
327  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
328  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
329    sysconfdir="$ac_optarg" ;;
330
331  -target | --target | --targe | --targ | --tar | --ta | --t)
332    ac_prev=target ;;
333  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
334    target="$ac_optarg" ;;
335
336  -v | -verbose | --verbose | --verbos | --verbo | --verb)
337    verbose=yes ;;
338
339  -version | --version | --versio | --versi | --vers)
340    echo "configure generated by autoconf version 2.13"
341    exit 0 ;;
342
343  -with-* | --with-*)
344    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
345    # Reject names that are not valid shell variable names.
346    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
347      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
348    fi
349    ac_package=`echo $ac_package| sed 's/-/_/g'`
350    case "$ac_option" in
351      *=*) ;;
352      *) ac_optarg=yes ;;
353    esac
354    eval "with_${ac_package}='$ac_optarg'" ;;
355
356  -without-* | --without-*)
357    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
358    # Reject names that are not valid shell variable names.
359    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
360      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
361    fi
362    ac_package=`echo $ac_package| sed 's/-/_/g'`
363    eval "with_${ac_package}=no" ;;
364
365  --x)
366    # Obsolete; use --with-x.
367    with_x=yes ;;
368
369  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
370  | --x-incl | --x-inc | --x-in | --x-i)
371    ac_prev=x_includes ;;
372  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
373  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
374    x_includes="$ac_optarg" ;;
375
376  -x-libraries | --x-libraries | --x-librarie | --x-librari \
377  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
378    ac_prev=x_libraries ;;
379  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
380  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
381    x_libraries="$ac_optarg" ;;
382
383  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
384    ;;
385
386  *)
387    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
388      echo "configure: warning: $ac_option: invalid host type" 1>&2
389    fi
390    if test "x$nonopt" != xNONE; then
391      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
392    fi
393    nonopt="$ac_option"
394    ;;
395
396  esac
397done
398
399if test -n "$ac_prev"; then
400  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
401fi
402
403trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
404
405# File descriptor usage:
406# 0 standard input
407# 1 file creation
408# 2 errors and warnings
409# 3 some systems may open it to /dev/tty
410# 4 used on the Kubota Titan
411# 6 checking for... messages and results
412# 5 compiler messages saved in config.log
413if test "$silent" = yes; then
414  exec 6>/dev/null
415else
416  exec 6>&1
417fi
418exec 5>./config.log
419
420echo "\
421This file contains any messages produced by compilers while
422running configure, to aid debugging if configure makes a mistake.
423" 1>&5
424
425# Strip out --no-create and --no-recursion so they do not pile up.
426# Also quote any args containing shell metacharacters.
427ac_configure_args=
428for ac_arg
429do
430  case "$ac_arg" in
431  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
432  | --no-cr | --no-c) ;;
433  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
434  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
435  *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
436  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
437  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
438  esac
439done
440
441# NLS nuisances.
442# Only set these to C if already set.  These must not be set unconditionally
443# because not all systems understand e.g. LANG=C (notably SCO).
444# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
445# Non-C LC_CTYPE values break the ctype check.
446if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
447if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
448if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
449if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
450
451# confdefs.h avoids OS command line length limits that DEFS can exceed.
452rm -rf conftest* confdefs.h
453# AIX cpp loses on an empty file, so make sure it contains at least a newline.
454echo > confdefs.h
455
456# A filename unique to this package, relative to the directory that
457# configure is in, which we can look for to find out if srcdir is correct.
458ac_unique_file=Makefile.in
459
460# Find the source files, if location was not specified.
461if test -z "$srcdir"; then
462  ac_srcdir_defaulted=yes
463  # Try the directory containing this script, then its parent.
464  ac_prog=$0
465  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
466  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
467  srcdir=$ac_confdir
468  if test ! -r $srcdir/$ac_unique_file; then
469    srcdir=..
470  fi
471else
472  ac_srcdir_defaulted=no
473fi
474if test ! -r $srcdir/$ac_unique_file; then
475  if test "$ac_srcdir_defaulted" = yes; then
476    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
477  else
478    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
479  fi
480fi
481srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
482
483# Prefer explicitly selected file to automatically selected ones.
484if test -z "$CONFIG_SITE"; then
485  if test "x$prefix" != xNONE; then
486    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
487  else
488    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
489  fi
490fi
491for ac_site_file in $CONFIG_SITE; do
492  if test -r "$ac_site_file"; then
493    echo "loading site script $ac_site_file"
494    . "$ac_site_file"
495  fi
496done
497
498if test -r "$cache_file"; then
499  echo "loading cache $cache_file"
500  . $cache_file
501else
502  echo "creating cache $cache_file"
503  > $cache_file
504fi
505
506ac_ext=c
507# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
508ac_cpp='$CPP $CPPFLAGS'
509ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
510ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
511cross_compiling=$ac_cv_prog_cc_cross
512
513ac_exeext=
514ac_objext=o
515if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
516  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
517  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
518    ac_n= ac_c='
519' ac_t='        '
520  else
521    ac_n=-n ac_c= ac_t=
522  fi
523else
524  ac_n= ac_c='\c' ac_t=
525fi
526
527
528
529
530
531# Check whether --enable-debug-messages or --disable-debug-messages was given.
532if test "${enable_debug_messages+set}" = set; then
533  enableval="$enable_debug_messages"
534 
535  if test $enableval = "yes"; then
536    cat >> confdefs.h <<\EOF
537#define DEBUG_MESSAGES 1
538EOF
539
540  fi
541
542fi
543
544
545# Check whether --enable-ip-check or --disable-ip-check was given.
546if test "${enable_ip_check+set}" = set; then
547  enableval="$enable_ip_check"
548 
549  if test $enableval = "yes"; then
550    cat >> confdefs.h <<\EOF
551#define IP_CHECK 1
552EOF
553
554  fi
555
556fi
557
558
559
560
561VERSION=`cat $srcdir/VERSION`
562
563
564echo "Configuring ipfm $VERSION..."
565echo
566
567# Extract the first word of "uname", so it can be a program name with args.
568set dummy uname; ac_word=$2
569echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
570echo "configure:571: checking for $ac_word" >&5
571if eval "test \"`echo '$''{'ac_cv_prog_UNAME'+set}'`\" = set"; then
572  echo $ac_n "(cached) $ac_c" 1>&6
573else
574  if test -n "$UNAME"; then
575  ac_cv_prog_UNAME="$UNAME" # Let the user override the test.
576else
577  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
578  ac_dummy="$PATH"
579  for ac_dir in $ac_dummy; do
580    test -z "$ac_dir" && ac_dir=.
581    if test -f $ac_dir/$ac_word; then
582      ac_cv_prog_UNAME="uname"
583      break
584    fi
585  done
586  IFS="$ac_save_ifs"
587fi
588fi
589UNAME="$ac_cv_prog_UNAME"
590if test -n "$UNAME"; then
591  echo "$ac_t""$UNAME" 1>&6
592else
593  echo "$ac_t""no" 1>&6
594fi
595
596if test "x$UNAME" = "x"; then
597  echo
598  echo "No uname. can't find your OS"
599  echo
600  exit 1
601fi
602
603echo $ac_n "checking your OS""... $ac_c" 1>&6
604echo "configure:605: checking your OS" >&5
605system=`$UNAME`
606case $system in
607  Linux)
608    echo "$ac_t""Linux" 1>&6
609    cat >> confdefs.h <<\EOF
610#define __OS_LINUX__ 1
611EOF
612
613    ;;
614  FreeBSD)
615    echo "$ac_t""FreeBSD" 1>&6
616    cat >> confdefs.h <<\EOF
617#define __OS_FREEBSD__ 1
618EOF
619
620    ;;
621  OpenBSD)
622    echo "$ac_t""OpenBSD" 1>&6
623    cat >> confdefs.h <<\EOF
624#define __OS_OPENBSD__ 1
625EOF
626
627    ;;
628  SunOS)
629    echo "$ac_t""SunOS" 1>&6
630    cat >> confdefs.h <<\EOF
631#define __OS_SUNOS__ 1
632EOF
633
634    LIBS="$LIBS -lnsl -lsocket"
635    ;;
636  AIX)
637    echo "$ac_t""AIX" 1>&6
638    cat >> confdefs.h <<\EOF
639#define __OS_AIX__ 1
640EOF
641
642    ;;
643  HP-UX)
644    echo "$ac_t""HPUX" 1>&6
645    cat >> confdefs.h <<\EOF
646#define __OS_HPUX__ 1
647EOF
648
649    ;;
650  OSF1)
651    echo "$ac_t""OSF1" 1>&6
652    cat >> confdefs.h <<\EOF
653#define __OS_OSF1__ 1
654EOF
655
656    ;;
657esac
658
659# Extract the first word of "gcc", so it can be a program name with args.
660set dummy gcc; ac_word=$2
661echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
662echo "configure:663: checking for $ac_word" >&5
663if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
664  echo $ac_n "(cached) $ac_c" 1>&6
665else
666  if test -n "$CC"; then
667  ac_cv_prog_CC="$CC" # Let the user override the test.
668else
669  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
670  ac_dummy="$PATH"
671  for ac_dir in $ac_dummy; do
672    test -z "$ac_dir" && ac_dir=.
673    if test -f $ac_dir/$ac_word; then
674      ac_cv_prog_CC="gcc"
675      break
676    fi
677  done
678  IFS="$ac_save_ifs"
679fi
680fi
681CC="$ac_cv_prog_CC"
682if test -n "$CC"; then
683  echo "$ac_t""$CC" 1>&6
684else
685  echo "$ac_t""no" 1>&6
686fi
687
688if test -z "$CC"; then
689  # Extract the first word of "cc", so it can be a program name with args.
690set dummy cc; ac_word=$2
691echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
692echo "configure:693: checking for $ac_word" >&5
693if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
694  echo $ac_n "(cached) $ac_c" 1>&6
695else
696  if test -n "$CC"; then
697  ac_cv_prog_CC="$CC" # Let the user override the test.
698else
699  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
700  ac_prog_rejected=no
701  ac_dummy="$PATH"
702  for ac_dir in $ac_dummy; do
703    test -z "$ac_dir" && ac_dir=.
704    if test -f $ac_dir/$ac_word; then
705      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
706        ac_prog_rejected=yes
707        continue
708      fi
709      ac_cv_prog_CC="cc"
710      break
711    fi
712  done
713  IFS="$ac_save_ifs"
714if test $ac_prog_rejected = yes; then
715  # We found a bogon in the path, so make sure we never use it.
716  set dummy $ac_cv_prog_CC
717  shift
718  if test $# -gt 0; then
719    # We chose a different compiler from the bogus one.
720    # However, it has the same basename, so the bogon will be chosen
721    # first if we set CC to just the basename; use the full file name.
722    shift
723    set dummy "$ac_dir/$ac_word" "$@"
724    shift
725    ac_cv_prog_CC="$@"
726  fi
727fi
728fi
729fi
730CC="$ac_cv_prog_CC"
731if test -n "$CC"; then
732  echo "$ac_t""$CC" 1>&6
733else
734  echo "$ac_t""no" 1>&6
735fi
736
737  if test -z "$CC"; then
738    case "`uname -s`" in
739    *win32* | *WIN32*)
740      # Extract the first word of "cl", so it can be a program name with args.
741set dummy cl; ac_word=$2
742echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
743echo "configure:744: checking for $ac_word" >&5
744if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
745  echo $ac_n "(cached) $ac_c" 1>&6
746else
747  if test -n "$CC"; then
748  ac_cv_prog_CC="$CC" # Let the user override the test.
749else
750  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
751  ac_dummy="$PATH"
752  for ac_dir in $ac_dummy; do
753    test -z "$ac_dir" && ac_dir=.
754    if test -f $ac_dir/$ac_word; then
755      ac_cv_prog_CC="cl"
756      break
757    fi
758  done
759  IFS="$ac_save_ifs"
760fi
761fi
762CC="$ac_cv_prog_CC"
763if test -n "$CC"; then
764  echo "$ac_t""$CC" 1>&6
765else
766  echo "$ac_t""no" 1>&6
767fi
768 ;;
769    esac
770  fi
771  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
772fi
773
774echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
775echo "configure:776: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
776
777ac_ext=c
778# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
779ac_cpp='$CPP $CPPFLAGS'
780ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
781ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
782cross_compiling=$ac_cv_prog_cc_cross
783
784cat > conftest.$ac_ext << EOF
785
786#line 787 "configure"
787#include "confdefs.h"
788
789main(){return(0);}
790EOF
791if { (eval echo configure:792: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
792  ac_cv_prog_cc_works=yes
793  # If we can't run a trivial program, we are probably using a cross compiler.
794  if (./conftest; exit) 2>/dev/null; then
795    ac_cv_prog_cc_cross=no
796  else
797    ac_cv_prog_cc_cross=yes
798  fi
799else
800  echo "configure: failed program was:" >&5
801  cat conftest.$ac_ext >&5
802  ac_cv_prog_cc_works=no
803fi
804rm -fr conftest*
805ac_ext=c
806# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
807ac_cpp='$CPP $CPPFLAGS'
808ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
809ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
810cross_compiling=$ac_cv_prog_cc_cross
811
812echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
813if test $ac_cv_prog_cc_works = no; then
814  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
815fi
816echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
817echo "configure:818: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
818echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
819cross_compiling=$ac_cv_prog_cc_cross
820
821echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
822echo "configure:823: checking whether we are using GNU C" >&5
823if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
824  echo $ac_n "(cached) $ac_c" 1>&6
825else
826  cat > conftest.c <<EOF
827#ifdef __GNUC__
828  yes;
829#endif
830EOF
831if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:832: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
832  ac_cv_prog_gcc=yes
833else
834  ac_cv_prog_gcc=no
835fi
836fi
837
838echo "$ac_t""$ac_cv_prog_gcc" 1>&6
839
840if test $ac_cv_prog_gcc = yes; then
841  GCC=yes
842else
843  GCC=
844fi
845
846ac_test_CFLAGS="${CFLAGS+set}"
847ac_save_CFLAGS="$CFLAGS"
848CFLAGS=
849echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
850echo "configure:851: checking whether ${CC-cc} accepts -g" >&5
851if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
852  echo $ac_n "(cached) $ac_c" 1>&6
853else
854  echo 'void f(){}' > conftest.c
855if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
856  ac_cv_prog_cc_g=yes
857else
858  ac_cv_prog_cc_g=no
859fi
860rm -f conftest*
861
862fi
863
864echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
865if test "$ac_test_CFLAGS" = set; then
866  CFLAGS="$ac_save_CFLAGS"
867elif test $ac_cv_prog_cc_g = yes; then
868  if test "$GCC" = yes; then
869    CFLAGS="-g -O2"
870  else
871    CFLAGS="-g"
872  fi
873else
874  if test "$GCC" = yes; then
875    CFLAGS="-O2"
876  else
877    CFLAGS=
878  fi
879fi
880
881echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
882echo "configure:883: checking how to run the C preprocessor" >&5
883# On Suns, sometimes $CPP names a directory.
884if test -n "$CPP" && test -d "$CPP"; then
885  CPP=
886fi
887if test -z "$CPP"; then
888if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
889  echo $ac_n "(cached) $ac_c" 1>&6
890else
891    # This must be in double quotes, not single quotes, because CPP may get
892  # substituted into the Makefile and "${CC-cc}" will confuse make.
893  CPP="${CC-cc} -E"
894  # On the NeXT, cc -E runs the code through the compiler's parser,
895  # not just through cpp.
896  cat > conftest.$ac_ext <<EOF
897#line 898 "configure"
898#include "confdefs.h"
899#include <assert.h>
900Syntax Error
901EOF
902ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
903{ (eval echo configure:904: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
904ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
905if test -z "$ac_err"; then
906  :
907else
908  echo "$ac_err" >&5
909  echo "configure: failed program was:" >&5
910  cat conftest.$ac_ext >&5
911  rm -rf conftest*
912  CPP="${CC-cc} -E -traditional-cpp"
913  cat > conftest.$ac_ext <<EOF
914#line 915 "configure"
915#include "confdefs.h"
916#include <assert.h>
917Syntax Error
918EOF
919ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
920{ (eval echo configure:921: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
921ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
922if test -z "$ac_err"; then
923  :
924else
925  echo "$ac_err" >&5
926  echo "configure: failed program was:" >&5
927  cat conftest.$ac_ext >&5
928  rm -rf conftest*
929  CPP="${CC-cc} -nologo -E"
930  cat > conftest.$ac_ext <<EOF
931#line 932 "configure"
932#include "confdefs.h"
933#include <assert.h>
934Syntax Error
935EOF
936ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
937{ (eval echo configure:938: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
938ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
939if test -z "$ac_err"; then
940  :
941else
942  echo "$ac_err" >&5
943  echo "configure: failed program was:" >&5
944  cat conftest.$ac_ext >&5
945  rm -rf conftest*
946  CPP=/lib/cpp
947fi
948rm -f conftest*
949fi
950rm -f conftest*
951fi
952rm -f conftest*
953  ac_cv_prog_CPP="$CPP"
954fi
955  CPP="$ac_cv_prog_CPP"
956else
957  ac_cv_prog_CPP="$CPP"
958fi
959echo "$ac_t""$CPP" 1>&6
960
961ac_aux_dir=
962for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
963  if test -f $ac_dir/install-sh; then
964    ac_aux_dir=$ac_dir
965    ac_install_sh="$ac_aux_dir/install-sh -c"
966    break
967  elif test -f $ac_dir/install.sh; then
968    ac_aux_dir=$ac_dir
969    ac_install_sh="$ac_aux_dir/install.sh -c"
970    break
971  fi
972done
973if test -z "$ac_aux_dir"; then
974  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
975fi
976ac_config_guess=$ac_aux_dir/config.guess
977ac_config_sub=$ac_aux_dir/config.sub
978ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
979
980# Find a good install program.  We prefer a C program (faster),
981# so one script is as good as another.  But avoid the broken or
982# incompatible versions:
983# SysV /etc/install, /usr/sbin/install
984# SunOS /usr/etc/install
985# IRIX /sbin/install
986# AIX /bin/install
987# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
988# AFS /usr/afsws/bin/install, which mishandles nonexistent args
989# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
990# ./install, which can be erroneously created by make from ./install.sh.
991echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
992echo "configure:993: checking for a BSD compatible install" >&5
993if test -z "$INSTALL"; then
994if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
995  echo $ac_n "(cached) $ac_c" 1>&6
996else
997    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
998  for ac_dir in $PATH; do
999    # Account for people who put trailing slashes in PATH elements.
1000    case "$ac_dir/" in
1001    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1002    *)
1003      # OSF1 and SCO ODT 3.0 have their own names for install.
1004      # Don't use installbsd from OSF since it installs stuff as root
1005      # by default.
1006      for ac_prog in ginstall scoinst install; do
1007        if test -f $ac_dir/$ac_prog; then
1008          if test $ac_prog = install &&
1009            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1010            # AIX install.  It has an incompatible calling convention.
1011            :
1012          else
1013            ac_cv_path_install="$ac_dir/$ac_prog -c"
1014            break 2
1015          fi
1016        fi
1017      done
1018      ;;
1019    esac
1020  done
1021  IFS="$ac_save_IFS"
1022
1023fi
1024  if test "${ac_cv_path_install+set}" = set; then
1025    INSTALL="$ac_cv_path_install"
1026  else
1027    # As a last resort, use the slow shell script.  We don't cache a
1028    # path for INSTALL within a source directory, because that will
1029    # break other packages using the cache if that directory is
1030    # removed, or if the path is relative.
1031    INSTALL="$ac_install_sh"
1032  fi
1033fi
1034echo "$ac_t""$INSTALL" 1>&6
1035
1036# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1037# It thinks the first close brace ends the variable substitution.
1038test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1039
1040test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1041
1042test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1043
1044# Extract the first word of "flex", so it can be a program name with args.
1045set dummy flex; ac_word=$2
1046echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1047echo "configure:1048: checking for $ac_word" >&5
1048if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1049  echo $ac_n "(cached) $ac_c" 1>&6
1050else
1051  if test -n "$LEX"; then
1052  ac_cv_prog_LEX="$LEX" # Let the user override the test.
1053else
1054  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1055  ac_dummy="$PATH"
1056  for ac_dir in $ac_dummy; do
1057    test -z "$ac_dir" && ac_dir=.
1058    if test -f $ac_dir/$ac_word; then
1059      ac_cv_prog_LEX="flex"
1060      break
1061    fi
1062  done
1063  IFS="$ac_save_ifs"
1064  test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
1065fi
1066fi
1067LEX="$ac_cv_prog_LEX"
1068if test -n "$LEX"; then
1069  echo "$ac_t""$LEX" 1>&6
1070else
1071  echo "$ac_t""no" 1>&6
1072fi
1073
1074if test -z "$LEXLIB"
1075then
1076  case "$LEX" in
1077  flex*) ac_lib=fl ;;
1078  *) ac_lib=l ;;
1079  esac
1080  echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
1081echo "configure:1082: checking for yywrap in -l$ac_lib" >&5
1082ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
1083if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1084  echo $ac_n "(cached) $ac_c" 1>&6
1085else
1086  ac_save_LIBS="$LIBS"
1087LIBS="-l$ac_lib  $LIBS"
1088cat > conftest.$ac_ext <<EOF
1089#line 1090 "configure"
1090#include "confdefs.h"
1091/* Override any gcc2 internal prototype to avoid an error.  */
1092/* We use char because int might match the return type of a gcc2
1093    builtin and then its argument prototype would still apply.  */
1094char yywrap();
1095
1096int main() {
1097yywrap()
1098; return 0; }
1099EOF
1100if { (eval echo configure:1101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1101  rm -rf conftest*
1102  eval "ac_cv_lib_$ac_lib_var=yes"
1103else
1104  echo "configure: failed program was:" >&5
1105  cat conftest.$ac_ext >&5
1106  rm -rf conftest*
1107  eval "ac_cv_lib_$ac_lib_var=no"
1108fi
1109rm -f conftest*
1110LIBS="$ac_save_LIBS"
1111
1112fi
1113if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1114  echo "$ac_t""yes" 1>&6
1115  LEXLIB="-l$ac_lib"
1116else
1117  echo "$ac_t""no" 1>&6
1118fi
1119
1120fi
1121
1122# Extract the first word of "ranlib", so it can be a program name with args.
1123set dummy ranlib; ac_word=$2
1124echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1125echo "configure:1126: checking for $ac_word" >&5
1126if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1127  echo $ac_n "(cached) $ac_c" 1>&6
1128else
1129  if test -n "$RANLIB"; then
1130  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1131else
1132  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1133  ac_dummy="$PATH"
1134  for ac_dir in $ac_dummy; do
1135    test -z "$ac_dir" && ac_dir=.
1136    if test -f $ac_dir/$ac_word; then
1137      ac_cv_prog_RANLIB="ranlib"
1138      break
1139    fi
1140  done
1141  IFS="$ac_save_ifs"
1142  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1143fi
1144fi
1145RANLIB="$ac_cv_prog_RANLIB"
1146if test -n "$RANLIB"; then
1147  echo "$ac_t""$RANLIB" 1>&6
1148else
1149  echo "$ac_t""no" 1>&6
1150fi
1151
1152for ac_prog in 'bison -y' byacc
1153do
1154# Extract the first word of "$ac_prog", so it can be a program name with args.
1155set dummy $ac_prog; ac_word=$2
1156echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1157echo "configure:1158: checking for $ac_word" >&5
1158if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
1159  echo $ac_n "(cached) $ac_c" 1>&6
1160else
1161  if test -n "$YACC"; then
1162  ac_cv_prog_YACC="$YACC" # Let the user override the test.
1163else
1164  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1165  ac_dummy="$PATH"
1166  for ac_dir in $ac_dummy; do
1167    test -z "$ac_dir" && ac_dir=.
1168    if test -f $ac_dir/$ac_word; then
1169      ac_cv_prog_YACC="$ac_prog"
1170      break
1171    fi
1172  done
1173  IFS="$ac_save_ifs"
1174fi
1175fi
1176YACC="$ac_cv_prog_YACC"
1177if test -n "$YACC"; then
1178  echo "$ac_t""$YACC" 1>&6
1179else
1180  echo "$ac_t""no" 1>&6
1181fi
1182
1183test -n "$YACC" && break
1184done
1185test -n "$YACC" || YACC="yacc"
1186
1187# Extract the first word of "ar", so it can be a program name with args.
1188set dummy ar; ac_word=$2
1189echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1190echo "configure:1191: checking for $ac_word" >&5
1191if eval "test \"`echo '$''{'ac_cv_path_AR'+set}'`\" = set"; then
1192  echo $ac_n "(cached) $ac_c" 1>&6
1193else
1194  case "$AR" in
1195  /*)
1196  ac_cv_path_AR="$AR" # Let the user override the test with a path.
1197  ;;
1198  ?:/*)                 
1199  ac_cv_path_AR="$AR" # Let the user override the test with a dos path.
1200  ;;
1201  *)
1202  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1203  ac_dummy="$PATH"
1204  for ac_dir in $ac_dummy; do
1205    test -z "$ac_dir" && ac_dir=.
1206    if test -f $ac_dir/$ac_word; then
1207      ac_cv_path_AR="$ac_dir/$ac_word"
1208      break
1209    fi
1210  done
1211  IFS="$ac_save_ifs"
1212  ;;
1213esac
1214fi
1215AR="$ac_cv_path_AR"
1216if test -n "$AR"; then
1217  echo "$ac_t""$AR" 1>&6
1218else
1219  echo "$ac_t""no" 1>&6
1220fi
1221
1222
1223if test -z "$AR" ; then
1224        { echo "configure: error: You need 'ar' in order to compile ipfm" 1>&2; exit 1; }
1225fi
1226
1227
1228echo $ac_n "checking for local libpcap""... $ac_c" 1>&6
1229echo "configure:1230: checking for local libpcap" >&5
1230pcapdirs=`ls .. | grep libpcap | sed -e 's:/$::' -e 's:^:../:' | tr '\n' ' '`
1231libpcap=FAIL
1232for pcapdir in `echo $pcapdirs` ; do
1233  pcapdir=`pwd`/$pcapdir
1234  if test -d $pcapdir -a -f $pcapdir/libpcap.a -a -f $pcapdir/pcap.h ; then
1235    libpcap=$pcapdir/libpcap.a
1236    echo "$ac_t""Using $libpcap" 1>&6
1237    INCLS="-I$pcapdir"
1238    break
1239  fi
1240done
1241
1242if test "x$libpcap" = "xFAIL" ; then
1243  echo "$ac_t""no" 1>&6
1244  echo $ac_n "checking for main in -lpcap""... $ac_c" 1>&6
1245echo "configure:1246: checking for main in -lpcap" >&5
1246ac_lib_var=`echo pcap'_'main | sed 'y%./+-%__p_%'`
1247if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1248  echo $ac_n "(cached) $ac_c" 1>&6
1249else
1250  ac_save_LIBS="$LIBS"
1251LIBS="-lpcap  $LIBS"
1252cat > conftest.$ac_ext <<EOF
1253#line 1254 "configure"
1254#include "confdefs.h"
1255
1256int main() {
1257main()
1258; return 0; }
1259EOF
1260if { (eval echo configure:1261: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1261  rm -rf conftest*
1262  eval "ac_cv_lib_$ac_lib_var=yes"
1263else
1264  echo "configure: failed program was:" >&5
1265  cat conftest.$ac_ext >&5
1266  rm -rf conftest*
1267  eval "ac_cv_lib_$ac_lib_var=no"
1268fi
1269rm -f conftest*
1270LIBS="$ac_save_LIBS"
1271
1272fi
1273if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1274  echo "$ac_t""yes" 1>&6
1275  libpcap="-lpcap"
1276else
1277  echo "$ac_t""no" 1>&6
1278{ echo "configure: error: You need libpcap in order to use ipfm" 1>&2; exit 1; }
1279fi
1280
1281  pcapdir=""
1282    ac_safe=`echo "pcap.h" | sed 'y%./+-%__p_%'`
1283echo $ac_n "checking for pcap.h""... $ac_c" 1>&6
1284echo "configure:1285: checking for pcap.h" >&5
1285if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1286  echo $ac_n "(cached) $ac_c" 1>&6
1287else
1288  cat > conftest.$ac_ext <<EOF
1289#line 1290 "configure"
1290#include "confdefs.h"
1291#include <pcap.h>
1292EOF
1293ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1294{ (eval echo configure:1295: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1295ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1296if test -z "$ac_err"; then
1297  rm -rf conftest*
1298  eval "ac_cv_header_$ac_safe=yes"
1299else
1300  echo "$ac_err" >&5
1301  echo "configure: failed program was:" >&5
1302  cat conftest.$ac_ext >&5
1303  rm -rf conftest*
1304  eval "ac_cv_header_$ac_safe=no"
1305fi
1306rm -f conftest*
1307fi
1308if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1309  echo "$ac_t""yes" 1>&6
1310  :
1311else
1312  echo "$ac_t""no" 1>&6
1313NO_PCAP_H=1
1314fi
1315
1316  if test "x$NO_PCAP_H" = "x1"; then
1317    echo $ac_n "checking for exotic pcap.h places""... $ac_c" 1>&6
1318echo "configure:1319: checking for exotic pcap.h places" >&5
1319    if test -r /usr/include/pcap/pcap.h; then
1320      INCLS="$INCLS -I/usr/include/pcap"
1321      echo "$ac_t""/usr/include/pcap/" 1>&6
1322    else if test -r /usr/local/include/pcap.h; then
1323      INCLS="$INCLS -I/usr/local/include"
1324      echo "$ac_t""/usr/local/include/" 1>&6
1325    else
1326      echo "configure: warning: pcap.h not found." 1>&2
1327      echo "configure: warning: Specify pcap.h PATH in source/Makefile (INCLS=-I/pcap/path)" 1>&2
1328    fi; fi