configure 54.9 KB
Newer Older
Per Cederqvist's avatar
Per Cederqvist committed
1
2
#!/bin/sh

Per Cederqvist's avatar
Per Cederqvist committed
3
# From configure.in Revision: 1.25 
Per Cederqvist's avatar
Per Cederqvist committed
4

Per Cederqvist's avatar
Per Cederqvist committed
5
# Guess values for system-dependent variables and create Makefiles.
Per Cederqvist's avatar
Per Cederqvist committed
6
7
8
9
10
# Generated automatically using autoconf version 2.1 
# Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
#
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.
Per Cederqvist's avatar
Per Cederqvist committed
11

Per Cederqvist's avatar
Per Cederqvist committed
12
13
14
15
# Defaults:
ac_help=
ac_default_prefix=/usr/local
# Any additions from configure.in:
Per Cederqvist's avatar
Per Cederqvist committed
16
17
18
19
20

# Initialize some variables set by options.
# The variables have the same names as the options, with
# dashes changed to underlines.
build=NONE
Per Cederqvist's avatar
Per Cederqvist committed
21
22
cache_file=./config.cache
exec_prefix=NONE
Per Cederqvist's avatar
Per Cederqvist committed
23
24
25
host=NONE
no_create=
nonopt=NONE
Per Cederqvist's avatar
Per Cederqvist committed
26
27
28
29
30
no_recursion=
prefix=NONE
program_prefix=NONE
program_suffix=NONE
program_transform_name=s,x,x,
Per Cederqvist's avatar
Per Cederqvist committed
31
silent=
Per Cederqvist's avatar
Per Cederqvist committed
32
site=
Per Cederqvist's avatar
Per Cederqvist committed
33
34
35
srcdir=
target=NONE
verbose=
Per Cederqvist's avatar
Per Cederqvist committed
36
37
38
39
40
x_includes=NONE
x_libraries=NONE

# Initialize some other variables.
subdirs=
Per Cederqvist's avatar
Per Cederqvist committed
41
42
43

ac_prev=
for ac_option
Per Cederqvist's avatar
Per Cederqvist committed
44
do
Per Cederqvist's avatar
Per Cederqvist committed
45
46
47
48
49
50

  # If the previous option needs an argument, assign it.
  if test -n "$ac_prev"; then
    eval "$ac_prev=\$ac_option"
    ac_prev=
    continue
Per Cederqvist's avatar
Per Cederqvist committed
51
  fi
Per Cederqvist's avatar
Per Cederqvist committed
52
53
54
55
56
57

  case "$ac_option" in
  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  *) ac_optarg= ;;
  esac

Per Cederqvist's avatar
Per Cederqvist committed
58
59
  # Accept the important Cygnus configure options, so we can diagnose typos.

Per Cederqvist's avatar
Per Cederqvist committed
60
61
62
63
64
65
66
  case "$ac_option" in

  -build | --build | --buil | --bui | --bu | --b)
    ac_prev=build ;;
  -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
    build="$ac_optarg" ;;

Per Cederqvist's avatar
Per Cederqvist committed
67
68
69
70
71
72
73
  -cache-file | --cache-file | --cache-fil | --cache-fi \
  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
    ac_prev=cache_file ;;
  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
    cache_file="$ac_optarg" ;;

Per Cederqvist's avatar
Per Cederqvist committed
74
75
  -disable-* | --disable-*)
    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
Per Cederqvist's avatar
Per Cederqvist committed
76
    # Reject names that are not valid shell variable names.
Per Cederqvist's avatar
Per Cederqvist committed
77
    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
Per Cederqvist's avatar
Per Cederqvist committed
78
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
Per Cederqvist's avatar
Per Cederqvist committed
79
80
81
82
83
84
    fi
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
    eval "enable_${ac_feature}=no" ;;

  -enable-* | --enable-*)
    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
Per Cederqvist's avatar
Per Cederqvist committed
85
    # Reject names that are not valid shell variable names.
Per Cederqvist's avatar
Per Cederqvist committed
86
    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
Per Cederqvist's avatar
Per Cederqvist committed
87
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
Per Cederqvist's avatar
Per Cederqvist committed
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
    fi
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
    case "$ac_option" in
      *=*) ;;
      *) ac_optarg=yes ;;
    esac
    eval "enable_${ac_feature}='$ac_optarg'" ;;

  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  | --exec | --exe | --ex)
    ac_prev=exec_prefix ;;
  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  | --exec=* | --exe=* | --ex=*)
    exec_prefix="$ac_optarg" ;;

  -gas | --gas | --ga | --g)
Per Cederqvist's avatar
Per Cederqvist committed
106
107
    # Obsolete; use --with-gas.
    with_gas=yes ;;
Per Cederqvist's avatar
Per Cederqvist committed
108
109

  -help | --help | --hel | --he)
Per Cederqvist's avatar
Per Cederqvist committed
110
111
    # Omit some internal or obsolete options to make the list less imposing.
    # This message is too long to be a string in the A/UX 3.1 sh.
Per Cederqvist's avatar
Per Cederqvist committed
112
    cat << EOF
Per Cederqvist's avatar
Per Cederqvist committed
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
Usage: configure [options] [host]
Options: [defaults in brackets after descriptions]
Configuration:
  --cache-file=FILE       cache test results in FILE
  --help                  print this message
  --no-create             do not create output files
  --quiet, --silent       do not print \`checking...' messages
  --version               print the version of autoconf that created configure
Directory and file names:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [$ac_default_prefix]
  --exec-prefix=PREFIX    install architecture-dependent files in PREFIX
                          [same as prefix]
  --srcdir=DIR            find the sources in DIR [configure dir or ..]
  --program-prefix=PREFIX prepend PREFIX to installed program names
  --program-suffix=SUFFIX append SUFFIX to installed program names
  --program-transform-name=PROGRAM run sed PROGRAM on installed program names
Host type:
  --build=BUILD           configure for building on BUILD [BUILD=HOST]
  --host=HOST             configure for HOST [guessed]
  --target=TARGET         configure for TARGET [TARGET=HOST]
Features and packages:
  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  --x-includes=DIR        X include files are in DIR
  --x-libraries=DIR       X library files are in DIR
--enable and --with options recognized:$ac_help
Per Cederqvist's avatar
Per Cederqvist committed
142
143
144
145
146
147
148
149
150
EOF
    exit 0 ;;

  -host | --host | --hos | --ho)
    ac_prev=host ;;
  -host=* | --host=* | --hos=* | --ho=*)
    host="$ac_optarg" ;;

  -nfp | --nfp | --nf)
Per Cederqvist's avatar
Per Cederqvist committed
151
152
    # Obsolete; use --without-fp.
    with_fp=no ;;
Per Cederqvist's avatar
Per Cederqvist committed
153
154
155
156
157

  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  | --no-cr | --no-c)
    no_create=yes ;;

Per Cederqvist's avatar
Per Cederqvist committed
158
159
160
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
    no_recursion=yes ;;
Per Cederqvist's avatar
Per Cederqvist committed
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201

  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
    ac_prev=prefix ;;
  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
    prefix="$ac_optarg" ;;

  -program-prefix | --program-prefix | --program-prefi | --program-pref \
  | --program-pre | --program-pr | --program-p)
    ac_prev=program_prefix ;;
  -program-prefix=* | --program-prefix=* | --program-prefi=* \
  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
    program_prefix="$ac_optarg" ;;

  -program-suffix | --program-suffix | --program-suffi | --program-suff \
  | --program-suf | --program-su | --program-s)
    ac_prev=program_suffix ;;
  -program-suffix=* | --program-suffix=* | --program-suffi=* \
  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
    program_suffix="$ac_optarg" ;;

  -program-transform-name | --program-transform-name \
  | --program-transform-nam | --program-transform-na \
  | --program-transform-n | --program-transform- \
  | --program-transform | --program-transfor \
  | --program-transfo | --program-transf \
  | --program-trans | --program-tran \
  | --progr-tra | --program-tr | --program-t)
    ac_prev=program_transform_name ;;
  -program-transform-name=* | --program-transform-name=* \
  | --program-transform-nam=* | --program-transform-na=* \
  | --program-transform-n=* | --program-transform-=* \
  | --program-transform=* | --program-transfor=* \
  | --program-transfo=* | --program-transf=* \
  | --program-trans=* | --program-tran=* \
  | --progr-tra=* | --program-tr=* | --program-t=*)
    program_transform_name="$ac_optarg" ;;

  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  | -silent | --silent | --silen | --sile | --sil)
    silent=yes ;;

Per Cederqvist's avatar
Per Cederqvist committed
202
203
204
205
206
  -site | --site | --sit)
    ac_prev=site ;;
  -site=* | --site=* | --sit=*)
    site="$ac_optarg" ;;

Per Cederqvist's avatar
Per Cederqvist committed
207
208
209
210
211
212
213
214
215
216
217
218
219
220
  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
    ac_prev=srcdir ;;
  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
    srcdir="$ac_optarg" ;;

  -target | --target | --targe | --targ | --tar | --ta | --t)
    ac_prev=target ;;
  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
    target="$ac_optarg" ;;

  -v | -verbose | --verbose | --verbos | --verbo | --verb)
    verbose=yes ;;

  -version | --version | --versio | --versi | --vers)
Per Cederqvist's avatar
Per Cederqvist committed
221
    echo "configure generated by autoconf version 2.1"
Per Cederqvist's avatar
Per Cederqvist committed
222
223
224
225
    exit 0 ;;

  -with-* | --with-*)
    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
Per Cederqvist's avatar
Per Cederqvist committed
226
    # Reject names that are not valid shell variable names.
Per Cederqvist's avatar
Per Cederqvist committed
227
    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
Per Cederqvist's avatar
Per Cederqvist committed
228
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
Per Cederqvist's avatar
Per Cederqvist committed
229
230
231
232
233
234
235
236
237
238
    fi
    ac_package=`echo $ac_package| sed 's/-/_/g'`
    case "$ac_option" in
      *=*) ;;
      *) ac_optarg=yes ;;
    esac
    eval "with_${ac_package}='$ac_optarg'" ;;

  -without-* | --without-*)
    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
Per Cederqvist's avatar
Per Cederqvist committed
239
    # Reject names that are not valid shell variable names.
Per Cederqvist's avatar
Per Cederqvist committed
240
    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
Per Cederqvist's avatar
Per Cederqvist committed
241
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
Per Cederqvist's avatar
Per Cederqvist committed
242
243
244
245
    fi
    ac_package=`echo $ac_package| sed 's/-/_/g'`
    eval "with_${ac_package}=no" ;;

Per Cederqvist's avatar
Per Cederqvist committed
246
247
248
  --x)
    # Obsolete; use --with-x.
    with_x=yes ;;
Per Cederqvist's avatar
Per Cederqvist committed
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263

  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  | --x-incl | --x-inc | --x-in | --x-i)
    ac_prev=x_includes ;;
  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
    x_includes="$ac_optarg" ;;

  -x-libraries | --x-libraries | --x-librarie | --x-librari \
  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
    ac_prev=x_libraries ;;
  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
    x_libraries="$ac_optarg" ;;

Per Cederqvist's avatar
Per Cederqvist committed
264
  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
Per Cederqvist's avatar
Per Cederqvist committed
265
266
267
268
    ;;

  *) 
    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
Per Cederqvist's avatar
Per Cederqvist committed
269
      echo "configure: warning: $ac_option: invalid host type" 1>&2
Per Cederqvist's avatar
Per Cederqvist committed
270
271
    fi
    if test "x$nonopt" != xNONE; then
Per Cederqvist's avatar
Per Cederqvist committed
272
      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
Per Cederqvist's avatar
Per Cederqvist committed
273
274
275
276
277
    fi
    nonopt="$ac_option"
    ;;

  esac
Per Cederqvist's avatar
Per Cederqvist committed
278
279
done

Per Cederqvist's avatar
Per Cederqvist committed
280
if test -n "$ac_prev"; then
Per Cederqvist's avatar
Per Cederqvist committed
281
  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
Per Cederqvist's avatar
Per Cederqvist committed
282
283
284
285
fi

trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15

Per Cederqvist's avatar
Per Cederqvist committed
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
# File descriptor usage:
# 0 unused; standard input
# 1 file creation
# 2 errors and warnings
# 3 unused; some systems may open it to /dev/tty
# 4 checking for... messages and results
# 5 compiler messages saved in config.log
if test "$silent" = yes; then
  exec 4>/dev/null
else
  exec 4>&1
fi
exec 5>./config.log

echo "\
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
" 1>&5

# Strip out --no-create and --no-recursion so they do not pile up.
# Also quote any args containing shell metacharacters.
ac_configure_args=
for ac_arg
do
Per Cederqvist's avatar
Per Cederqvist committed
310
311
312
  case "$ac_arg" in
  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  | --no-cr | --no-c) ;;
Per Cederqvist's avatar
Per Cederqvist committed
313
314
315
316
317
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
Per Cederqvist's avatar
Per Cederqvist committed
318
319
  esac
done
Per Cederqvist's avatar
Per Cederqvist committed
320
321

# NLS nuisances.
Per Cederqvist's avatar
Per Cederqvist committed
322
# Only set LANG and LC_ALL to C if already set.
Per Cederqvist's avatar
Per Cederqvist committed
323
324
# These must not be set unconditionally because not all systems understand
# e.g. LANG=C (notably SCO).
Per Cederqvist's avatar
Per Cederqvist committed
325
326
if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
Per Cederqvist's avatar
Per Cederqvist committed
327

Per Cederqvist's avatar
Per Cederqvist committed
328
329
# confdefs.h avoids OS command line length limits that DEFS can exceed.
rm -rf conftest* confdefs.h
Per Cederqvist's avatar
Per Cederqvist committed
330
331
332
333
334
# AIX cpp loses on an empty file, so make sure it contains at least a newline.
echo > confdefs.h

# A filename unique to this package, relative to the directory that
# configure is in, which we can look for to find out if srcdir is correct.
Per Cederqvist's avatar
Per Cederqvist committed
335
ac_unique_file=src/server/lyskomd.h
Per Cederqvist's avatar
Per Cederqvist committed
336
337
338

# Find the source files, if location was not specified.
if test -z "$srcdir"; then
Per Cederqvist's avatar
Per Cederqvist committed
339
  ac_srcdir_defaulted=yes
Per Cederqvist's avatar
Per Cederqvist committed
340
  # Try the directory containing this script, then its parent.
Per Cederqvist's avatar
Per Cederqvist committed
341
342
343
344
345
  ac_prog=$0
  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  srcdir=$ac_confdir
  if test ! -r $srcdir/$ac_unique_file; then
Per Cederqvist's avatar
Per Cederqvist committed
346
347
    srcdir=..
  fi
Per Cederqvist's avatar
Per Cederqvist committed
348
349
else
  ac_srcdir_defaulted=no
Per Cederqvist's avatar
Per Cederqvist committed
350
fi
Per Cederqvist's avatar
Per Cederqvist committed
351
if test ! -r $srcdir/$ac_unique_file; then
Per Cederqvist's avatar
Per Cederqvist committed
352
353
354
355
356
357
358
359
360
361
362
363
  if test "$ac_srcdir_defaulted" = yes; then
    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
  else
    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
  fi
fi
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`

# Prefer explicitly selected file to automatically selected ones.
if test -z "$CONFIG_SITE"; then
  if test "x$prefix" != xNONE; then
    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
Per Cederqvist's avatar
Per Cederqvist committed
364
  else
Per Cederqvist's avatar
Per Cederqvist committed
365
366
367
368
369
370
371
    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  fi
fi
for ac_site_file in $CONFIG_SITE; do
  if test -r "$ac_site_file"; then
    echo "loading site script $ac_site_file"
    . "$ac_site_file"
Per Cederqvist's avatar
Per Cederqvist committed
372
  fi
Per Cederqvist's avatar
Per Cederqvist committed
373
374
375
376
377
378
379
380
done

if test -r "$cache_file"; then
  echo "loading cache $cache_file"
  . $cache_file
else
  echo "creating cache $cache_file"
  > $cache_file
Per Cederqvist's avatar
Per Cederqvist committed
381
fi
Per Cederqvist's avatar
Per Cederqvist committed
382

Per Cederqvist's avatar
Per Cederqvist committed
383
384
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
Per Cederqvist's avatar
Per Cederqvist committed
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
ac_cpp='$CPP $CPPFLAGS'
ac_compile='${CC-cc} $CFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
ac_link='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'

if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
    ac_n= ac_c='
' ac_t='	'
  else
    ac_n=-n ac_c= ac_t=
  fi
else
  ac_n= ac_c='\c' ac_t=
fi
Per Cederqvist's avatar
Per Cederqvist committed
400
401


Per Cederqvist's avatar
Per Cederqvist committed
402
403
404
405
406
407
408
409
410
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_CC'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
Per Cederqvist's avatar
Per Cederqvist committed
411
412
413
414
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
Per Cederqvist's avatar
Per Cederqvist committed
415
      ac_cv_prog_CC="gcc"
Per Cederqvist's avatar
Per Cederqvist committed
416
417
418
      break
    fi
  done
Per Cederqvist's avatar
Per Cederqvist committed
419
  IFS="$ac_save_ifs"
Per Cederqvist's avatar
Per Cederqvist committed
420
421
422
423
424
425
426
427
  test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc"
fi
fi
CC="$ac_cv_prog_CC"
if test -n "$CC"; then
  echo "$ac_t""$CC" 1>&4
else
  echo "$ac_t""no" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
428
429
fi

Per Cederqvist's avatar
Per Cederqvist committed
430
431
432
433
434
435

echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_gcc'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.c <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
436
#ifdef __GNUC__
Per Cederqvist's avatar
Per Cederqvist committed
437
  yes;
Per Cederqvist's avatar
Per Cederqvist committed
438
439
#endif
EOF
Per Cederqvist's avatar
Per Cederqvist committed
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
  ac_cv_prog_gcc=yes
else
  ac_cv_prog_gcc=no
fi
fi
echo "$ac_t""$ac_cv_prog_gcc" 1>&4
if test $ac_cv_prog_gcc = yes; then
  GCC=yes
  if test "${CFLAGS+set}" != set; then
    echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_gcc_g'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  echo 'void f(){}' > conftest.c
if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
  ac_cv_prog_gcc_g=yes
else
  ac_cv_prog_gcc_g=no
Per Cederqvist's avatar
Per Cederqvist committed
459
460
461
fi
rm -f conftest*

Per Cederqvist's avatar
Per Cederqvist committed
462
463
464
465
466
467
468
469
470
471
472
473
474
475
fi
    echo "$ac_t""$ac_cv_prog_gcc_g" 1>&4
    if test $ac_cv_prog_gcc_g = yes; then
      CFLAGS="-g -O"
    else
      CFLAGS="-O"
    fi
  fi
else
  GCC=
  test "${CFLAGS+set}" = set || CFLAGS="-g"
fi


Per Cederqvist's avatar
Per Cederqvist committed
476
477
478
479
480




INCLUDE_CURRENT=-I.
Per Cederqvist's avatar
Per Cederqvist committed
481
482
483
484
485
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&4
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
  CPP=
fi
Per Cederqvist's avatar
Per Cederqvist committed
486
if test -z "$CPP"; then
Per Cederqvist's avatar
Per Cederqvist committed
487
488
489
490
491
if eval "test \"`echo '${'ac_cv_prog_CPP'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
    # This must be in double quotes, not single quotes, because CPP may get
  # substituted into the Makefile and "${CC-cc}" will confuse make.
Per Cederqvist's avatar
Per Cederqvist committed
492
  CPP="${CC-cc} -E"
Per Cederqvist's avatar
Per Cederqvist committed
493
494
495
  # On the NeXT, cc -E runs the code through the compiler's parser,
  # not just through cpp.
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
496
#line 497 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
497
#include "confdefs.h"
Per Cederqvist's avatar
Per Cederqvist committed
498
#include <assert.h>
Per Cederqvist's avatar
Per Cederqvist committed
499
500
Syntax Error
EOF
Per Cederqvist's avatar
Per Cederqvist committed
501
502
eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
ac_err=`grep -v '^ *+' conftest.out`
Per Cederqvist's avatar
Per Cederqvist committed
503
504
505
if test -z "$ac_err"; then
  :
else
Per Cederqvist's avatar
Per Cederqvist committed
506
  echo "$ac_err" >&5
Per Cederqvist's avatar
Per Cederqvist committed
507
508
  rm -rf conftest*
  CPP="${CC-cc} -E -traditional-cpp"
Per Cederqvist's avatar
Per Cederqvist committed
509
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
510
#line 511 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
511
#include "confdefs.h"
Per Cederqvist's avatar
Per Cederqvist committed
512
#include <assert.h>
Per Cederqvist's avatar
Per Cederqvist committed
513
514
Syntax Error
EOF
Per Cederqvist's avatar
Per Cederqvist committed
515
516
eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
ac_err=`grep -v '^ *+' conftest.out`
Per Cederqvist's avatar
Per Cederqvist committed
517
if test -z "$ac_err"; then
Per Cederqvist's avatar
Per Cederqvist committed
518
519
  :
else
Per Cederqvist's avatar
Per Cederqvist committed
520
  echo "$ac_err" >&5
Per Cederqvist's avatar
Per Cederqvist committed
521
522
523
524
525
  rm -rf conftest*
  CPP=/lib/cpp
fi
rm -f conftest*
fi
Per Cederqvist's avatar
Per Cederqvist committed
526
rm -f conftest*
Per Cederqvist's avatar
Per Cederqvist committed
527
528
  ac_cv_prog_CPP="$CPP"
fi
Per Cederqvist's avatar
Per Cederqvist committed
529
fi
Per Cederqvist's avatar
Per Cederqvist committed
530
531
CPP="$ac_cv_prog_CPP"
echo "$ac_t""$CPP" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
532

Per Cederqvist's avatar
Per Cederqvist committed
533
534
echo $ac_n "checking for AIX""... $ac_c" 1>&4
cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
535
#line 536 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
536
537
538
539
540
541
#include "confdefs.h"
#ifdef _AIX
  yes
#endif

EOF
Per Cederqvist's avatar
Per Cederqvist committed
542
543
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
Per Cederqvist's avatar
Per Cederqvist committed
544
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
545
546
547
  echo "$ac_t""yes" 1>&4; cat >> confdefs.h <<\EOF
#define _ALL_SOURCE 1
EOF
Per Cederqvist's avatar
Per Cederqvist committed
548

Per Cederqvist's avatar
Per Cederqvist committed
549
550
551
else
  rm -rf conftest*
  echo "$ac_t""no" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
552
553
554
555
fi
rm -f conftest*


Per Cederqvist's avatar
Per Cederqvist committed
556
echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
557
558
559
if test -d /etc/conf/kconfig.d &&
  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
then
Per Cederqvist's avatar
Per Cederqvist committed
560
561
562
563
564
  echo "$ac_t""yes" 1>&4
  ISC=yes # If later tests want to check for ISC.
  cat >> confdefs.h <<\EOF
#define _POSIX_SOURCE 1
EOF
Per Cederqvist's avatar
Per Cederqvist committed
565

Per Cederqvist's avatar
Per Cederqvist committed
566
  if test "$GCC" = yes; then
Per Cederqvist's avatar
Per Cederqvist committed
567
568
569
570
    CC="$CC -posix"
  else
    CC="$CC -Xp"
  fi
Per Cederqvist's avatar
Per Cederqvist committed
571
572
573
else
  echo "$ac_t""no" 1>&4
  ISC=
Per Cederqvist's avatar
Per Cederqvist committed
574
575
fi

Per Cederqvist's avatar
Per Cederqvist committed
576
577
578
579
580
581
ac_safe=`echo "minix/config.h" | tr './\055' '___'`
echo $ac_n "checking for minix/config.h""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
582
#line 583 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
583
584
585
#include "confdefs.h"
#include <minix/config.h>
EOF
Per Cederqvist's avatar
Per Cederqvist committed
586
587
eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
ac_err=`grep -v '^ *+' conftest.out`
Per Cederqvist's avatar
Per Cederqvist committed
588
if test -z "$ac_err"; then
Per Cederqvist's avatar
Per Cederqvist committed
589
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
590
591
592
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
Per Cederqvist's avatar
Per Cederqvist committed
593
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
594
  eval "ac_cv_header_$ac_safe=no"
Per Cederqvist's avatar
Per Cederqvist committed
595
596
fi
rm -f conftest*
Per Cederqvist's avatar
Per Cederqvist committed
597
598
599
600
fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&4
  MINIX=yes
Per Cederqvist's avatar
Per Cederqvist committed
601
else
Per Cederqvist's avatar
Per Cederqvist committed
602
603
  echo "$ac_t""no" 1>&4
MINIX=
Per Cederqvist's avatar
Per Cederqvist committed
604
605
fi

Per Cederqvist's avatar
Per Cederqvist committed
606
607
608
609
if test "$MINIX" = yes; then
  cat >> confdefs.h <<\EOF
#define _POSIX_SOURCE 1
EOF
Per Cederqvist's avatar
Per Cederqvist committed
610

Per Cederqvist's avatar
Per Cederqvist committed
611
612
613
  cat >> confdefs.h <<\EOF
#define _POSIX_1_SOURCE 2
EOF
Per Cederqvist's avatar
Per Cederqvist committed
614

Per Cederqvist's avatar
Per Cederqvist committed
615
616
  cat >> confdefs.h <<\EOF
#define _MINIX 1
Per Cederqvist's avatar
Per Cederqvist committed
617
618
619
620
EOF

fi

Per Cederqvist's avatar
Per Cederqvist committed
621
if test -n "$GCC"; then
Per Cederqvist's avatar
Per Cederqvist committed
622
623
624
625
626
627
628
	CFLAGS="$CFLAGS -Wall -ansi"
	 kom_safe=`echo "kom_cv_compiler_${CC}_accepts_-pipe" | tr './=\055' '____'`
echo $ac_n "checking whether ${CC} accepts -pipe""... $ac_c" 1>&4
if eval "test \"`echo '${'$kom_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  kom_oldflags=$CFLAGS
Per Cederqvist's avatar
Per Cederqvist committed
629
CFLAGS="$CFLAGS -pipe"
Per Cederqvist's avatar
Per Cederqvist committed
630
cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
631
#line 632 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
632
633
634
#include "confdefs.h"

int main() { return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
635
636
637
int t() {

; return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
638
EOF
Per Cederqvist's avatar
Per Cederqvist committed
639
if eval $ac_link; then
Per Cederqvist's avatar
Per Cederqvist committed
640
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
641
  eval "$kom_safe=yes"
Per Cederqvist's avatar
Per Cederqvist committed
642
643
else
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
644
  eval "$kom_safe=no"
Per Cederqvist's avatar
Per Cederqvist committed
645
646
647
fi
rm -f conftest*

Per Cederqvist's avatar
Per Cederqvist committed
648
CFLAGS=$kom_oldflags
Per Cederqvist's avatar
Per Cederqvist committed
649
fi
Per Cederqvist's avatar
Per Cederqvist committed
650
651
652
653
654
655
echo "$ac_t""`eval echo '$'$kom_safe`" 1>&4
if test `eval echo '$'$kom_safe` = yes; then
  CFLAGS="$CFLAGS -pipe"
fi 
	DEPENDFLAG=-MM
else
Per Cederqvist's avatar
Per Cederqvist committed
656
657
658
659
660
661
	case "$CC" in
		*vcc) DEPENDFLAG=-Em
			INCLUDE_CURRENT='-I`pwd`';;
		*) DEPENDFLAG=-M;;
	esac
fi
Per Cederqvist's avatar
Per Cederqvist committed
662
663
664
665
666
667
668
echo $ac_n "checking flag to get dependencies""... $ac_c" 1>&4
echo "$ac_t""$DEPENDFLAG" 1>&4
echo $ac_n "checking for working const""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_c_const'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
669
#line 670 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
670
671
672
673
674
675
#include "confdefs.h"

int main() { return 0; }
int t() {

/* Ultrix mips cc rejects this.  */
Per Cederqvist's avatar
Per Cederqvist committed
676
677
678
679
typedef int charset[2]; const charset x;
/* SunOS 4.1.1 cc rejects this.  */
char const *const *ccp;
char **p;
Per Cederqvist's avatar
Per Cederqvist committed
680
681
682
/* NEC SVR4.0.2 mips cc rejects this.  */
struct point {int x, y;};
static struct point const zero;
Per Cederqvist's avatar
Per Cederqvist committed
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
/* AIX XL C 1.02.0.0 rejects this.
   It does not let you subtract one const X* pointer from another in an arm
   of an if-expression whose if-part is not a constant expression */
const char *g = "string";
ccp = &g + (g ? g-g : 0);
/* HPUX 7.0 cc rejects these. */
++ccp;
p = (char**) ccp;
ccp = (char const *const *) p;
{ /* SCO 3.2v4 cc rejects this.  */
  char *t;
  char const *s = 0 ? (char *) 0 : (char const *) 0;

  *t++ = 0;
}
{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
Per Cederqvist's avatar
Per Cederqvist committed
699
  int x[] = {25, 17};
Per Cederqvist's avatar
Per Cederqvist committed
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
  const int *foo = &x[0];
  ++foo;
}
{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  typedef const int *iptr;
  iptr p = 0;
  ++p;
}
{ /* AIX XL C 1.02.0.0 rejects this saying
     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  struct s { int j; const int *ap[3]; };
  struct s *b; b->j = 5;
}
{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  const int foo = 10;
Per Cederqvist's avatar
Per Cederqvist committed
715
}
Per Cederqvist's avatar
Per Cederqvist committed
716

Per Cederqvist's avatar
Per Cederqvist committed
717
; return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
718
EOF
Per Cederqvist's avatar
Per Cederqvist committed
719
if eval $ac_compile; then
Per Cederqvist's avatar
Per Cederqvist committed
720
721
  rm -rf conftest*
  ac_cv_c_const=yes
Per Cederqvist's avatar
Per Cederqvist committed
722
723
else
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
724
  ac_cv_c_const=no
Per Cederqvist's avatar
Per Cederqvist committed
725
726
727
fi
rm -f conftest*

Per Cederqvist's avatar
Per Cederqvist committed
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
fi
echo "$ac_t""$ac_cv_c_const" 1>&4
if test $ac_cv_c_const = no; then
  cat >> confdefs.h <<\EOF
#define const 
EOF

fi

# If we cannot run a trivial program, we must be cross compiling.
echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_c_cross'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  if test "$cross_compiling" = yes; then
  ac_cv_cross=yes
else
cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
746
#line 747 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
#include "confdefs.h"
main(){return(0);}
EOF
eval $ac_link
if test -s conftest && (./conftest; exit) 2>/dev/null; then
  ac_cv_c_cross=no
else
  ac_cv_c_cross=yes
fi
fi
rm -fr conftest*
fi
cross_compiling=$ac_cv_c_cross
echo "$ac_t""$ac_cv_c_cross" 1>&4

echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_header_stdc'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
767
#line 768 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
768
769
770
771
772
773
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <float.h>
EOF
Per Cederqvist's avatar
Per Cederqvist committed
774
775
eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
ac_err=`grep -v '^ *+' conftest.out`
Per Cederqvist's avatar
Per Cederqvist committed
776
if test -z "$ac_err"; then
Per Cederqvist's avatar
Per Cederqvist committed
777
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
778
779
780
781
782
783
784
785
786
  ac_cv_header_stdc=yes
else
  echo "$ac_err" >&5
  rm -rf conftest*
  ac_cv_header_stdc=no
fi
rm -f conftest*

if test $ac_cv_header_stdc = yes; then
Per Cederqvist's avatar
Per Cederqvist committed
787
  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
Per Cederqvist's avatar
Per Cederqvist committed
788
cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
789
#line 790 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
#include "confdefs.h"
#include <string.h>
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "memchr" >/dev/null 2>&1; then
  :
else
  rm -rf conftest*
  ac_cv_header_stdc=no
fi
rm -f conftest*

fi

if test $ac_cv_header_stdc = yes; then
  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
807
#line 808 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
808
809
810
811
812
813
814
#include "confdefs.h"
#include <stdlib.h>
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "free" >/dev/null 2>&1; then
  :
else
Per Cederqvist's avatar
Per Cederqvist committed
815
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
816
817
818
819
820
821
822
823
824
825
826
827
  ac_cv_header_stdc=no
fi
rm -f conftest*

fi

if test $ac_cv_header_stdc = yes; then
  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
if test "$cross_compiling" = yes; then
  ac_cv_header_stdc=no
else
cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
828
#line 829 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
829
830
831
832
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
Per Cederqvist's avatar
Per Cederqvist committed
833
#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
Per Cederqvist's avatar
Per Cederqvist committed
834
835
836
837
838
int main () { int i; for (i = 0; i < 256; i++)
if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }

EOF
Per Cederqvist's avatar
Per Cederqvist committed
839
eval $ac_link
Per Cederqvist's avatar
Per Cederqvist committed
840
if test -s conftest && (./conftest; exit) 2>/dev/null; then
Per Cederqvist's avatar
Per Cederqvist committed
841
842
843
  :
else
  ac_cv_header_stdc=no
Per Cederqvist's avatar
Per Cederqvist committed
844
fi
Per Cederqvist's avatar
Per Cederqvist committed
845
846
847
fi
rm -fr conftest*
fi
Per Cederqvist's avatar
Per Cederqvist committed
848
849
850
851
852
853
fi
echo "$ac_t""$ac_cv_header_stdc" 1>&4
if test $ac_cv_header_stdc = yes; then
  cat >> confdefs.h <<\EOF
#define STDC_HEADERS 1
EOF
Per Cederqvist's avatar
Per Cederqvist committed
854
855
856

fi

Per Cederqvist's avatar
Per Cederqvist committed
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
echo $ac_n "checking for pid_t""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_type_pid_t'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.$ac_ext <<EOF
#line 863 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
#include <stdlib.h>
#endif
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "pid_t" >/dev/null 2>&1; then
  rm -rf conftest*
  ac_cv_type_pid_t=yes
else
  rm -rf conftest*
  ac_cv_type_pid_t=no
fi
rm -f conftest*

fi
echo "$ac_t""$ac_cv_type_pid_t" 1>&4
if test $ac_cv_type_pid_t = no; then
  cat >> confdefs.h <<\EOF
#define pid_t int
EOF

fi

Per Cederqvist's avatar
Per Cederqvist committed
888
889
890
891
892
echo $ac_n "checking if _HPUX_SOURCE needs to be defined""... $ac_c" 1>&4
if eval "test \"`echo '${'kom_cv_sys_hpux_source'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
893
#line 894 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
894
#include "confdefs.h"
Per Cederqvist's avatar
Per Cederqvist committed
895
#include <sys/types.h>
Per Cederqvist's avatar
Per Cederqvist committed
896
#include <sys/socket.h>
Per Cederqvist's avatar
Per Cederqvist committed
897
int main() { return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
898
899
900
int t() {
struct sockaddr foo;
; return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
901
EOF
Per Cederqvist's avatar
Per Cederqvist committed
902
if eval $ac_link; then
Per Cederqvist's avatar
Per Cederqvist committed
903
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
904
  kom_cv_sys_hpux_source=no
Per Cederqvist's avatar
Per Cederqvist committed
905
906
else
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
907
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
908
#line 909 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
909
910
#include "confdefs.h"
#define _HPUX_SOURCE
Per Cederqvist's avatar
Per Cederqvist committed
911
#include <sys/types.h>
Per Cederqvist's avatar
Per Cederqvist committed
912
#include <sys/socket.h>
Per Cederqvist's avatar
Per Cederqvist committed
913
int main() { return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
914
915
916
int t() {
struct sockaddr foo;
; return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
917
EOF
Per Cederqvist's avatar
Per Cederqvist committed
918
if eval $ac_link; then
Per Cederqvist's avatar
Per Cederqvist committed
919
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
920
  kom_cv_sys_hpux_source=yes
Per Cederqvist's avatar
Per Cederqvist committed
921
922
else
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
923
  kom_cv_sys_hpux_source=no
Per Cederqvist's avatar
Per Cederqvist committed
924
925
926
927
928
929
fi
rm -f conftest*

fi
rm -f conftest*

Per Cederqvist's avatar
Per Cederqvist committed
930
931
932
933
934
935
936
937
938
939
fi

echo "$ac_t""$kom_cv_sys_hpux_source" 1>&4
if test $kom_cv_sys_hpux_source = yes ; then
  cat >> confdefs.h <<\EOF
#define _HPUX_SOURCE 1
EOF

fi

Per Cederqvist's avatar
Per Cederqvist committed
940
941
942
SRCTOPDIR=`cd $srcdir;pwd`

BUILDTOPDIR=`pwd`
Per Cederqvist's avatar
Per Cederqvist committed
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
ac_aux_dir=
for ac_dir in scripts $srcdir/scripts; do
  if test -f $ac_dir/install-sh; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/install-sh -c"
    break
  elif test -f $ac_dir/install.sh; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/install.sh -c"
    break
  fi
done
if test -z "$ac_aux_dir"; then
  { echo "configure: error: can not find install-sh or install.sh in scripts $srcdir/scripts" 1>&2; exit 1; }
fi
ac_config_guess=$ac_aux_dir/config.guess
ac_config_sub=$ac_aux_dir/config.sub
ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.

# Find a good install program.  We prefer a C program (faster),
# so one script is as good as another.  But avoid the broken or
# incompatible versions:
# SysV /etc/install, /usr/sbin/install
# SunOS /usr/etc/install
# IRIX /sbin/install
# AIX /bin/install
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&4
if test -z "$INSTALL"; then
if eval "test \"`echo '${'ac_cv_path_install'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
    IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
Per Cederqvist's avatar
Per Cederqvist committed
978
979
  for ac_dir in $PATH; do
    case "$ac_dir" in
Per Cederqvist's avatar
Per Cederqvist committed
980
    ''|.|/etc|/usr/sbin|/usr/etc|/sbin|/usr/afsws/bin|/usr/ucb) ;;
Per Cederqvist's avatar
Per Cederqvist committed
981
    *)
Per Cederqvist's avatar
Per Cederqvist committed
982
      # OSF1 and SCO ODT 3.0 have their own names for install.
Per Cederqvist's avatar
Per Cederqvist committed
983
      for ac_prog in ginstall installbsd scoinst install; do
Per Cederqvist's avatar
Per Cederqvist committed
984
985
986
987
988
989
990
        if test -f $ac_dir/$ac_prog; then
	  if test $ac_prog = install &&
            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
	    # AIX install.  It has an incompatible calling convention.
	    # OSF/1 installbsd also uses dspmsg, but is usable.
	    :
	  else
Per Cederqvist's avatar
Per Cederqvist committed
991
	    ac_cv_path_install="$ac_dir/$ac_prog -c"
Per Cederqvist's avatar
Per Cederqvist committed
992
993
	    break 2
	  fi
Per Cederqvist's avatar
Per Cederqvist committed
994
	fi
Per Cederqvist's avatar
Per Cederqvist committed
995
      done
Per Cederqvist's avatar
Per Cederqvist committed
996
997
998
      ;;
    esac
  done
Per Cederqvist's avatar
Per Cederqvist committed
999
1000
  IFS="$ac_save_ifs"
  # As a last resort, use the slow shell script.
Per Cederqvist's avatar
Per Cederqvist committed
1001
  test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh"
Per Cederqvist's avatar
Per Cederqvist committed
1002
fi
Per Cederqvist's avatar
Per Cederqvist committed
1003
  INSTALL="$ac_cv_path_install"
Per Cederqvist's avatar
Per Cederqvist committed
1004
fi
Per Cederqvist's avatar
Per Cederqvist committed
1005
echo "$ac_t""$INSTALL" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
1006

Per Cederqvist's avatar
Per Cederqvist committed
1007
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
Per Cederqvist's avatar
Per Cederqvist committed
1008
1009
1010
1011
# It thinks the first close brace ends the variable substitution.
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'

test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
Per Cederqvist's avatar
Per Cederqvist committed
1012

Per Cederqvist's avatar
Per Cederqvist committed
1013
1014
1015
1016
1017
1018
1019
1020
1021
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_RANLIB'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  if test -n "$RANLIB"; then
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
Per Cederqvist's avatar
Per Cederqvist committed
1022
1023
1024
1025
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
Per Cederqvist's avatar
Per Cederqvist committed
1026
      ac_cv_prog_RANLIB="ranlib"
Per Cederqvist's avatar
Per Cederqvist committed
1027
1028
1029
      break
    fi
  done
Per Cederqvist's avatar
Per Cederqvist committed
1030
  IFS="$ac_save_ifs"
Per Cederqvist's avatar
Per Cederqvist committed
1031
1032
1033
1034
1035
1036
1037
1038
  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
fi
fi
RANLIB="$ac_cv_prog_RANLIB"
if test -n "$RANLIB"; then
  echo "$ac_t""$RANLIB" 1>&4
else
  echo "$ac_t""no" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
1039
1040
fi

Per Cederqvist's avatar
Per Cederqvist committed
1041
for ac_prog in mawk gawk nawk awk
Per Cederqvist's avatar
Per Cederqvist committed
1042
do
Per Cederqvist's avatar
Per Cederqvist committed
1043
1044
1045
1046
1047
1048
1049
1050
1051
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_AWK'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  if test -n "$AWK"; then
  ac_cv_prog_AWK="$AWK" # Let the user override the test.
else
Per Cederqvist's avatar
Per Cederqvist committed
1052
1053
1054
1055
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
Per Cederqvist's avatar
Per Cederqvist committed
1056
      ac_cv_prog_AWK="$ac_prog"
Per Cederqvist's avatar
Per Cederqvist committed
1057
1058
1059
      break
    fi
  done
Per Cederqvist's avatar
Per Cederqvist committed
1060
  IFS="$ac_save_ifs"
Per Cederqvist's avatar
Per Cederqvist committed
1061
fi
Per Cederqvist's avatar
Per Cederqvist committed
1062
1063
1064
1065
1066
1067
1068
fi
AWK="$ac_cv_prog_AWK"
if test -n "$AWK"; then
  echo "$ac_t""$AWK" 1>&4
else
  echo "$ac_t""no" 1>&4
fi
Per Cederqvist's avatar
Per Cederqvist committed
1069
1070
1071
1072

test -n "$AWK" && break
done

Per Cederqvist's avatar
Per Cederqvist committed
1073
1074
1075
1076
1077
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_LN_S'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  rm -f conftestdata
Per Cederqvist's avatar
Per Cederqvist committed
1078
1079
1080
if ln -s X conftestdata 2>/dev/null
then
  rm -f conftestdata
Per Cederqvist's avatar
Per Cederqvist committed
1081
  ac_cv_prog_LN_S="ln -s"
Per Cederqvist's avatar
Per Cederqvist committed
1082
else
Per Cederqvist's avatar
Per Cederqvist committed
1083
1084
1085
1086
1087
1088
1089
1090
  ac_cv_prog_LN_S=ln
fi
fi
LN_S="$ac_cv_prog_LN_S"
if test "$ac_cv_prog_LN_S" = "ln -s"; then
  echo "$ac_t""yes" 1>&4
else
  echo "$ac_t""no" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
1091
1092
fi

Per Cederqvist's avatar
Per Cederqvist committed
1093
for ac_prog in 'bison -y' byacc
Per Cederqvist's avatar
Per Cederqvist committed
1094
do
Per Cederqvist's avatar
Per Cederqvist committed
1095
1096
1097
1098
1099
1100
1101
1102
1103
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_YACC'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  if test -n "$YACC"; then
  ac_cv_prog_YACC="$YACC" # Let the user override the test.
else
Per Cederqvist's avatar
Per Cederqvist committed
1104
1105
1106
1107
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
Per Cederqvist's avatar
Per Cederqvist committed
1108
      ac_cv_prog_YACC="$ac_prog"
Per Cederqvist's avatar
Per Cederqvist committed
1109
1110
1111
      break
    fi
  done
Per Cederqvist's avatar
Per Cederqvist committed
1112
  IFS="$ac_save_ifs"
Per Cederqvist's avatar
Per Cederqvist committed
1113
fi
Per Cederqvist's avatar
Per Cederqvist committed
1114
1115
1116
1117
1118
1119
1120
fi
YACC="$ac_cv_prog_YACC"
if test -n "$YACC"; then
  echo "$ac_t""$YACC" 1>&4
else
  echo "$ac_t""no" 1>&4
fi
Per Cederqvist's avatar
Per Cederqvist committed
1121
1122
1123
1124
1125

test -n "$YACC" && break
done
test -n "$YACC" || YACC="yacc"

Per Cederqvist's avatar
Per Cederqvist committed
1126
1127
1128
1129
1130
1131
1132
1133
1134
# Extract the first word of "flex", so it can be a program name with args.
set dummy flex; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_LEX'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  if test -n "$LEX"; then
  ac_cv_prog_LEX="$LEX" # Let the user override the test.
else
Per Cederqvist's avatar
Per Cederqvist committed
1135
1136
1137
1138
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
Per Cederqvist's avatar
Per Cederqvist committed
1139
      ac_cv_prog_LEX="flex"
Per Cederqvist's avatar
Per Cederqvist committed
1140
1141
1142
      break
    fi
  done
Per Cederqvist's avatar
Per Cederqvist committed
1143
  IFS="$ac_save_ifs"
Per Cederqvist's avatar
Per Cederqvist committed
1144
1145
1146
1147
1148
1149
1150
1151
  test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
fi
fi
LEX="$ac_cv_prog_LEX"
if test -n "$LEX"; then
  echo "$ac_t""$LEX" 1>&4
else
  echo "$ac_t""no" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
1152
1153
1154
1155
1156
fi

if test -z "$LEXLIB"
then
  case "$LEX" in
Per Cederqvist's avatar
Per Cederqvist committed
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
  flex*) ac_lib=fl ;;
  *) ac_lib=l ;;
  esac
  echo $ac_n "checking for -l$ac_lib""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_lib_$ac_lib'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  ac_save_LIBS="$LIBS"
LIBS="$LIBS -l$ac_lib "
cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
1167
#line 1168 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
1168
1169
#include "confdefs.h"

Per Cederqvist's avatar
Per Cederqvist committed
1170
int main() { return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
1171
1172
1173
int t() {
main()
; return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
1174
EOF
Per Cederqvist's avatar
Per Cederqvist committed
1175
if eval $ac_link; then
Per Cederqvist's avatar
Per Cederqvist committed
1176
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
1177
1178
1179
1180
  eval "ac_cv_lib_$ac_lib=yes"
else
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib=no"
Per Cederqvist's avatar
Per Cederqvist committed
1181
1182
fi
rm -f conftest*
Per Cederqvist's avatar
Per Cederqvist committed
1183
1184
1185
1186
1187
1188
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib`\" = yes"; then
  echo "$ac_t""yes" 1>&4
  LEXLIB="-l$ac_lib"
Per Cederqvist's avatar
Per Cederqvist committed
1189
else
Per Cederqvist's avatar
Per Cederqvist committed
1190
  echo "$ac_t""no" 1>&4
Per Cederqvist's avatar
Per Cederqvist committed
1191
fi
Per Cederqvist's avatar
Per Cederqvist committed
1192

Per Cederqvist's avatar
Per Cederqvist committed
1193
1194
fi

Per Cederqvist's avatar
Per Cederqvist committed
1195
for ac_prog in sed
Per Cederqvist's avatar
Per Cederqvist committed
1196
do
Per Cederqvist's avatar
Per Cederqvist committed
1197
1198
1199
1200
1201
1202
1203
1204
1205
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_prog_SED'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  if test -n "$SED"; then
  ac_cv_prog_SED="$SED" # Let the user override the test.
else
Per Cederqvist's avatar
Per Cederqvist committed
1206
1207
1208
1209
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
Per Cederqvist's avatar
Per Cederqvist committed
1210
      ac_cv_prog_SED="$ac_prog"
Per Cederqvist's avatar
Per Cederqvist committed
1211
1212
1213
      break
    fi
  done
Per Cederqvist's avatar
Per Cederqvist committed
1214
  IFS="$ac_save_ifs"
Per Cederqvist's avatar
Per Cederqvist committed
1215
fi
Per Cederqvist's avatar
Per Cederqvist committed
1216
1217
1218
1219
1220
1221
1222
fi
SED="$ac_cv_prog_SED"
if test -n "$SED"; then
  echo "$ac_t""$SED" 1>&4
else
  echo "$ac_t""no" 1>&4
fi
Per Cederqvist's avatar
Per Cederqvist committed
1223
1224
1225
1226

test -n "$SED" && break
done

Per Cederqvist's avatar
Per Cederqvist committed
1227
for ac_hdr in string.h memory.h strings.h sys/param.h sys/time.h
Per Cederqvist's avatar
Per Cederqvist committed
1228
do
Per Cederqvist's avatar
Per Cederqvist committed
1229
1230
1231
1232
1233
1234
ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
1235
#line 1236 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
1236
#include "confdefs.h"
Per Cederqvist's avatar
Per Cederqvist committed
1237
#include <$ac_hdr>
Per Cederqvist's avatar
Per Cederqvist committed
1238
EOF
Per Cederqvist's avatar
Per Cederqvist committed
1239
1240
eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
ac_err=`grep -v '^ *+' conftest.out`
Per Cederqvist's avatar
Per Cederqvist committed
1241
if test -z "$ac_err"; then
Per Cederqvist's avatar
Per Cederqvist committed
1242
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
1243
1244
1245
1246
1247
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Per Cederqvist's avatar
Per Cederqvist committed
1248
1249
fi
rm -f conftest*
Per Cederqvist's avatar
Per Cederqvist committed
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&4
    ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&4
fi
Per Cederqvist's avatar
Per Cederqvist committed
1261
1262
done

Per Cederqvist's avatar
Per Cederqvist committed
1263
for ac_hdr in stdarg.h stdlib.h stddef.h locale.h sys/resource.h
Per Cederqvist's avatar
Per Cederqvist committed
1264
do
Per Cederqvist's avatar
Per Cederqvist committed
1265
1266
1267
1268
1269
1270
ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
1271
#line 1272 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
1272
#include "confdefs.h"
Per Cederqvist's avatar
Per Cederqvist committed
1273
#include <$ac_hdr>
Per Cederqvist's avatar
Per Cederqvist committed
1274
EOF
Per Cederqvist's avatar
Per Cederqvist committed
1275
1276
eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
ac_err=`grep -v '^ *+' conftest.out`
Per Cederqvist's avatar
Per Cederqvist committed
1277
if test -z "$ac_err"; then
Per Cederqvist's avatar
Per Cederqvist committed
1278
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
1279
1280
1281
1282
1283
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Per Cederqvist's avatar
Per Cederqvist committed
1284
1285
fi
rm -f conftest*
Per Cederqvist's avatar
Per Cederqvist committed
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&4
    ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&4
fi
Per Cederqvist's avatar
Per Cederqvist committed
1297
1298
done

Per Cederqvist's avatar
Per Cederqvist committed
1299
1300
1301
1302
1303
echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&4
if eval "test \"`echo '${'ac_cv_header_time'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&4
else
  cat > conftest.$ac_ext <<EOF
Per Cederqvist's avatar
Per Cederqvist committed
1304
#line 1305 "configure"
Per Cederqvist's avatar
Per Cederqvist committed
1305
1306
1307
1308
#include "confdefs.h"
#include <sys/types.h>
#include <sys/time.h>
#include <time.h>
Per Cederqvist's avatar
Per Cederqvist committed
1309
int main() { return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
1310
1311
1312
int t() {
struct tm *tp;
; return 0; }
Per Cederqvist's avatar
Per Cederqvist committed
1313
EOF
Per Cederqvist's avatar
Per Cederqvist committed
1314
if eval $ac_compile; then
Per Cederqvist's avatar
Per Cederqvist committed
1315
  rm -rf conftest*
Per Cederqvist's avatar
Per Cederqvist committed
1316
1317
1318
1319
1320
1321
  ac_cv_header_time=yes
else
  rm -rf conftest*
  ac_cv_header_time=no
fi
rm -f conftest*
Per Cederqvist's avatar
Per Cederqvist committed
1322

Per Cederqvist's avatar
Per Cederqvist committed
1323
1324
1325
1326
1327
1328
fi
echo "$ac_t""$ac_cv_header_time" 1>&4
if test $ac_cv_header_time = yes; then
  cat >> confdefs.h <<\EOF
#define TIME_WITH_SYS_TIME 1
EOF
Per Cederqvist's avatar
Per Cederqvist committed