| 1 |
#! /bin/sh |
| 2 |
|
| 3 |
# Guess values for system-dependent variables and create Makefiles. |
| 4 |
# Generated automatically using autoconf version 2.13 |
| 5 |
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. |
| 6 |
# |
| 7 |
# This configure script is free software; the Free Software Foundation |
| 8 |
# gives unlimited permission to copy, distribute and modify it. |
| 9 |
|
| 10 |
# Defaults: |
| 11 |
ac_help= |
| 12 |
ac_default_prefix=/usr/local |
| 13 |
# Any additions from configure.in: |
| 14 |
ac_help="$ac_help |
| 15 |
--disable-ccdv disable use of ccdv program in Makefiles" |
| 16 |
ac_help="$ac_help |
| 17 |
--without-curses do not try to find and use the curses library" |
| 18 |
ac_help="$ac_help |
| 19 |
--enable-debug enable debugging symbols" |
| 20 |
ac_help="$ac_help |
| 21 |
--without-ncurses do not try to find and use the ncurses library" |
| 22 |
ac_help="$ac_help |
| 23 |
--disable-precomp disable use of precompiled header files" |
| 24 |
ac_help="$ac_help |
| 25 |
--with-socks5 try to find and use the SOCKS5 library" |
| 26 |
ac_help="$ac_help |
| 27 |
--enable-ssp use stack smashing protection if available" |
| 28 |
ac_help="$ac_help |
| 29 |
--disable-universal disable production of universal binaries on Mac OS X" |
| 30 |
ac_help="$ac_help |
| 31 |
--with-dnssec-local-validation Enable local DNSSEC validation using libval (no)" |
| 32 |
|
| 33 |
# Initialize some variables set by options. |
| 34 |
# The variables have the same names as the options, with |
| 35 |
# dashes changed to underlines. |
| 36 |
build=NONE |
| 37 |
cache_file=./config.cache |
| 38 |
exec_prefix=NONE |
| 39 |
host=NONE |
| 40 |
no_create= |
| 41 |
nonopt=NONE |
| 42 |
no_recursion= |
| 43 |
prefix=NONE |
| 44 |
program_prefix=NONE |
| 45 |
program_suffix=NONE |
| 46 |
program_transform_name=s,x,x, |
| 47 |
silent= |
| 48 |
site= |
| 49 |
srcdir= |
| 50 |
target=NONE |
| 51 |
verbose= |
| 52 |
x_includes=NONE |
| 53 |
x_libraries=NONE |
| 54 |
bindir='${exec_prefix}/bin' |
| 55 |
sbindir='${exec_prefix}/sbin' |
| 56 |
libexecdir='${exec_prefix}/libexec' |
| 57 |
datadir='${prefix}/share' |
| 58 |
sysconfdir='${prefix}/etc' |
| 59 |
sharedstatedir='${prefix}/com' |
| 60 |
localstatedir='${prefix}/var' |
| 61 |
libdir='${exec_prefix}/lib' |
| 62 |
includedir='${prefix}/include' |
| 63 |
oldincludedir='/usr/include' |
| 64 |
infodir='${prefix}/info' |
| 65 |
mandir='${prefix}/man' |
| 66 |
|
| 67 |
# Initialize some other variables. |
| 68 |
subdirs= |
| 69 |
MFLAGS= MAKEFLAGS= |
| 70 |
SHELL=${CONFIG_SHELL-/bin/sh} |
| 71 |
# Maximum number of lines to put in a shell here document. |
| 72 |
ac_max_here_lines=12 |
| 73 |
|
| 74 |
ac_prev= |
| 75 |
for ac_option |
| 76 |
do |
| 77 |
|
| 78 |
# If the previous option needs an argument, assign it. |
| 79 |
if test -n "$ac_prev"; then |
| 80 |
eval "$ac_prev=\$ac_option" |
| 81 |
ac_prev= |
| 82 |
continue |
| 83 |
fi |
| 84 |
|
| 85 |
case "$ac_option" in |
| 86 |
-*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
| 87 |
*) ac_optarg= ;; |
| 88 |
esac |
| 89 |
|
| 90 |
# Accept the important Cygnus configure options, so we can diagnose typos. |
| 91 |
|
| 92 |
case "$ac_option" in |
| 93 |
|
| 94 |
-bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 95 |
ac_prev=bindir ;; |
| 96 |
-bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 97 |
bindir="$ac_optarg" ;; |
| 98 |
|
| 99 |
-build | --build | --buil | --bui | --bu) |
| 100 |
ac_prev=build ;; |
| 101 |
-build=* | --build=* | --buil=* | --bui=* | --bu=*) |
| 102 |
build="$ac_optarg" ;; |
| 103 |
|
| 104 |
-cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 105 |
| --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 106 |
ac_prev=cache_file ;; |
| 107 |
-cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 108 |
| --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 109 |
cache_file="$ac_optarg" ;; |
| 110 |
|
| 111 |
-datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 112 |
ac_prev=datadir ;; |
| 113 |
-datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 114 |
| --da=*) |
| 115 |
datadir="$ac_optarg" ;; |
| 116 |
|
| 117 |
-disable-* | --disable-*) |
| 118 |
ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
| 119 |
# Reject names that are not valid shell variable names. |
| 120 |
if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then |
| 121 |
{ echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } |
| 122 |
fi |
| 123 |
ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 124 |
eval "enable_${ac_feature}=no" ;; |
| 125 |
|
| 126 |
-enable-* | --enable-*) |
| 127 |
ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
| 128 |
# Reject names that are not valid shell variable names. |
| 129 |
if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then |
| 130 |
{ echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } |
| 131 |
fi |
| 132 |
ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 133 |
case "$ac_option" in |
| 134 |
*=*) ;; |
| 135 |
*) ac_optarg=yes ;; |
| 136 |
esac |
| 137 |
eval "enable_${ac_feature}='$ac_optarg'" ;; |
| 138 |
|
| 139 |
-exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 140 |
| --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 141 |
| --exec | --exe | --ex) |
| 142 |
ac_prev=exec_prefix ;; |
| 143 |
-exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 144 |
| --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 145 |
| --exec=* | --exe=* | --ex=*) |
| 146 |
exec_prefix="$ac_optarg" ;; |
| 147 |
|
| 148 |
-gas | --gas | --ga | --g) |
| 149 |
# Obsolete; use --with-gas. |
| 150 |
with_gas=yes ;; |
| 151 |
|
| 152 |
-help | --help | --hel | --he) |
| 153 |
# Omit some internal or obsolete options to make the list less imposing. |
| 154 |
# This message is too long to be a string in the A/UX 3.1 sh. |
| 155 |
cat << EOF |
| 156 |
Usage: configure [options] [host] |
| 157 |
Options: [defaults in brackets after descriptions] |
| 158 |
Configuration: |
| 159 |
--cache-file=FILE cache test results in FILE |
| 160 |
--help print this message |
| 161 |
--no-create do not create output files |
| 162 |
--quiet, --silent do not print \`checking...' messages |
| 163 |
--version print the version of autoconf that created configure |
| 164 |
Directory and file names: |
| 165 |
--prefix=PREFIX install architecture-independent files in PREFIX |
| 166 |
[$ac_default_prefix] |
| 167 |
--exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
| 168 |
[same as prefix] |
| 169 |
--bindir=DIR user executables in DIR [EPREFIX/bin] |
| 170 |
--sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
| 171 |
--libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
| 172 |
--datadir=DIR read-only architecture-independent data in DIR |
| 173 |
[PREFIX/share] |
| 174 |
--sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
| 175 |
--sharedstatedir=DIR modifiable architecture-independent data in DIR |
| 176 |
[PREFIX/com] |
| 177 |
--localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
| 178 |
--libdir=DIR object code libraries in DIR [EPREFIX/lib] |
| 179 |
--includedir=DIR C header files in DIR [PREFIX/include] |
| 180 |
--oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
| 181 |
--infodir=DIR info documentation in DIR [PREFIX/info] |
| 182 |
--mandir=DIR man documentation in DIR [PREFIX/man] |
| 183 |
--srcdir=DIR find the sources in DIR [configure dir or ..] |
| 184 |
--program-prefix=PREFIX prepend PREFIX to installed program names |
| 185 |
--program-suffix=SUFFIX append SUFFIX to installed program names |
| 186 |
--program-transform-name=PROGRAM |
| 187 |
run sed PROGRAM on installed program names |
| 188 |
EOF |
| 189 |
cat << EOF |
| 190 |
Host type: |
| 191 |
--build=BUILD configure for building on BUILD [BUILD=HOST] |
| 192 |
--host=HOST configure for HOST [guessed] |
| 193 |
--target=TARGET configure for TARGET [TARGET=HOST] |
| 194 |
Features and packages: |
| 195 |
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 196 |
--enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 197 |
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 198 |
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 199 |
--x-includes=DIR X include files are in DIR |
| 200 |
--x-libraries=DIR X library files are in DIR |
| 201 |
EOF |
| 202 |
if test -n "$ac_help"; then |
| 203 |
echo "--enable and --with options recognized:$ac_help" |
| 204 |
fi |
| 205 |
exit 0 ;; |
| 206 |
|
| 207 |
-host | --host | --hos | --ho) |
| 208 |
ac_prev=host ;; |
| 209 |
-host=* | --host=* | --hos=* | --ho=*) |
| 210 |
host="$ac_optarg" ;; |
| 211 |
|
| 212 |
-includedir | --includedir | --includedi | --included | --include \ |
| 213 |
| --includ | --inclu | --incl | --inc) |
| 214 |
ac_prev=includedir ;; |
| 215 |
-includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 216 |
| --includ=* | --inclu=* | --incl=* | --inc=*) |
| 217 |
includedir="$ac_optarg" ;; |
| 218 |
|
| 219 |
-infodir | --infodir | --infodi | --infod | --info | --inf) |
| 220 |
ac_prev=infodir ;; |
| 221 |
-infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 222 |
infodir="$ac_optarg" ;; |
| 223 |
|
| 224 |
-libdir | --libdir | --libdi | --libd) |
| 225 |
ac_prev=libdir ;; |
| 226 |
-libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 227 |
libdir="$ac_optarg" ;; |
| 228 |
|
| 229 |
-libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 230 |
| --libexe | --libex | --libe) |
| 231 |
ac_prev=libexecdir ;; |
| 232 |
-libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 233 |
| --libexe=* | --libex=* | --libe=*) |
| 234 |
libexecdir="$ac_optarg" ;; |
| 235 |
|
| 236 |
-localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 237 |
| --localstate | --localstat | --localsta | --localst \ |
| 238 |
| --locals | --local | --loca | --loc | --lo) |
| 239 |
ac_prev=localstatedir ;; |
| 240 |
-localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 241 |
| --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 242 |
| --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 243 |
localstatedir="$ac_optarg" ;; |
| 244 |
|
| 245 |
-mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 246 |
ac_prev=mandir ;; |
| 247 |
-mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 248 |
mandir="$ac_optarg" ;; |
| 249 |
|
| 250 |
-nfp | --nfp | --nf) |
| 251 |
# Obsolete; use --without-fp. |
| 252 |
with_fp=no ;; |
| 253 |
|
| 254 |
-no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 255 |
| --no-cr | --no-c) |
| 256 |
no_create=yes ;; |
| 257 |
|
| 258 |
-no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 259 |
| --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 260 |
no_recursion=yes ;; |
| 261 |
|
| 262 |
-oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 263 |
| --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 264 |
| --oldin | --oldi | --old | --ol | --o) |
| 265 |
ac_prev=oldincludedir ;; |
| 266 |
-oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 267 |
| --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 268 |
| --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 269 |
oldincludedir="$ac_optarg" ;; |
| 270 |
|
| 271 |
-prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 272 |
ac_prev=prefix ;; |
| 273 |
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 274 |
prefix="$ac_optarg" ;; |
| 275 |
|
| 276 |
-program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 277 |
| --program-pre | --program-pr | --program-p) |
| 278 |
ac_prev=program_prefix ;; |
| 279 |
-program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 280 |
| --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 281 |
program_prefix="$ac_optarg" ;; |
| 282 |
|
| 283 |
-program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 284 |
| --program-suf | --program-su | --program-s) |
| 285 |
ac_prev=program_suffix ;; |
| 286 |
-program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 287 |
| --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 288 |
program_suffix="$ac_optarg" ;; |
| 289 |
|
| 290 |
-program-transform-name | --program-transform-name \ |
| 291 |
| --program-transform-nam | --program-transform-na \ |
| 292 |
| --program-transform-n | --program-transform- \ |
| 293 |
| --program-transform | --program-transfor \ |
| 294 |
| --program-transfo | --program-transf \ |
| 295 |
| --program-trans | --program-tran \ |
| 296 |
| --progr-tra | --program-tr | --program-t) |
| 297 |
ac_prev=program_transform_name ;; |
| 298 |
-program-transform-name=* | --program-transform-name=* \ |
| 299 |
| --program-transform-nam=* | --program-transform-na=* \ |
| 300 |
| --program-transform-n=* | --program-transform-=* \ |
| 301 |
| --program-transform=* | --program-transfor=* \ |
| 302 |
| --program-transfo=* | --program-transf=* \ |
| 303 |
| --program-trans=* | --program-tran=* \ |
| 304 |
| --progr-tra=* | --program-tr=* | --program-t=*) |
| 305 |
program_transform_name="$ac_optarg" ;; |
| 306 |
|
| 307 |
-q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 308 |
| -silent | --silent | --silen | --sile | --sil) |
| 309 |
silent=yes ;; |
| 310 |
|
| 311 |
-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 312 |
ac_prev=sbindir ;; |
| 313 |
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 314 |
| --sbi=* | --sb=*) |
| 315 |
sbindir="$ac_optarg" ;; |
| 316 |
|
| 317 |
-sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 318 |
| --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 319 |
| --sharedst | --shareds | --shared | --share | --shar \ |
| 320 |
| --sha | --sh) |
| 321 |
ac_prev=sharedstatedir ;; |
| 322 |
-sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 323 |
| --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 324 |
| --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 325 |
| --sha=* | --sh=*) |
| 326 |
sharedstatedir="$ac_optarg" ;; |
| 327 |
|
| 328 |
-site | --site | --sit) |
| 329 |
ac_prev=site ;; |
| 330 |
-site=* | --site=* | --sit=*) |
| 331 |
site="$ac_optarg" ;; |
| 332 |
|
| 333 |
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 334 |
ac_prev=srcdir ;; |
| 335 |
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 336 |
srcdir="$ac_optarg" ;; |
| 337 |
|
| 338 |
-sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 339 |
| --syscon | --sysco | --sysc | --sys | --sy) |
| 340 |
ac_prev=sysconfdir ;; |
| 341 |
-sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 342 |
| --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 343 |
sysconfdir="$ac_optarg" ;; |
| 344 |
|
| 345 |
-target | --target | --targe | --targ | --tar | --ta | --t) |
| 346 |
ac_prev=target ;; |
| 347 |
-target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 348 |
target="$ac_optarg" ;; |
| 349 |
|
| 350 |
-v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 351 |
verbose=yes ;; |
| 352 |
|
| 353 |
-version | --version | --versio | --versi | --vers) |
| 354 |
echo "configure generated by autoconf version 2.13" |
| 355 |
exit 0 ;; |
| 356 |
|
| 357 |
-with-* | --with-*) |
| 358 |
ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
| 359 |
# Reject names that are not valid shell variable names. |
| 360 |
if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then |
| 361 |
{ echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } |
| 362 |
fi |
| 363 |
ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 364 |
case "$ac_option" in |
| 365 |
*=*) ;; |
| 366 |
*) ac_optarg=yes ;; |
| 367 |
esac |
| 368 |
eval "with_${ac_package}='$ac_optarg'" ;; |
| 369 |
|
| 370 |
-without-* | --without-*) |
| 371 |
ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
| 372 |
# Reject names that are not valid shell variable names. |
| 373 |
if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then |
| 374 |
{ echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } |
| 375 |
fi |
| 376 |
ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 377 |
eval "with_${ac_package}=no" ;; |
| 378 |
|
| 379 |
--x) |
| 380 |
# Obsolete; use --with-x. |
| 381 |
with_x=yes ;; |
| 382 |
|
| 383 |
-x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 384 |
| --x-incl | --x-inc | --x-in | --x-i) |
| 385 |
ac_prev=x_includes ;; |
| 386 |
-x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 387 |
| --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 388 |
x_includes="$ac_optarg" ;; |
| 389 |
|
| 390 |
-x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 391 |
| --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 392 |
ac_prev=x_libraries ;; |
| 393 |
-x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 394 |
| --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 395 |
x_libraries="$ac_optarg" ;; |
| 396 |
|
| 397 |
-*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } |
| 398 |
;; |
| 399 |
|
| 400 |
*) |
| 401 |
if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then |
| 402 |
echo "configure: warning: $ac_option: invalid host type" 1>&2 |
| 403 |
fi |
| 404 |
if test "x$nonopt" != xNONE; then |
| 405 |
{ echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } |
| 406 |
fi |
| 407 |
nonopt="$ac_option" |
| 408 |
;; |
| 409 |
|
| 410 |
esac |
| 411 |
done |
| 412 |
|
| 413 |
if test -n "$ac_prev"; then |
| 414 |
{ echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } |
| 415 |
fi |
| 416 |
|
| 417 |
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
| 418 |
|
| 419 |
# File descriptor usage: |
| 420 |
# 0 standard input |
| 421 |
# 1 file creation |
| 422 |
# 2 errors and warnings |
| 423 |
# 3 some systems may open it to /dev/tty |
| 424 |
# 4 used on the Kubota Titan |
| 425 |
# 6 checking for... messages and results |
| 426 |
# 5 compiler messages saved in config.log |
| 427 |
if test "$silent" = yes; then |
| 428 |
exec 6>/dev/null |
| 429 |
else |
| 430 |
exec 6>&1 |
| 431 |
fi |
| 432 |
exec 5>./config.log |
| 433 |
|
| 434 |
echo "\ |
| 435 |
This file contains any messages produced by compilers while |
| 436 |
running configure, to aid debugging if configure makes a mistake. |
| 437 |
" 1>&5 |
| 438 |
|
| 439 |
# Strip out --no-create and --no-recursion so they do not pile up. |
| 440 |
# Also quote any args containing shell metacharacters. |
| 441 |
ac_configure_args= |
| 442 |
for ac_arg |
| 443 |
do |
| 444 |
case "$ac_arg" in |
| 445 |
-no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 446 |
| --no-cr | --no-c) ;; |
| 447 |
-no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 448 |
| --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 449 |
*" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
| 450 |
ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
| 451 |
*) ac_configure_args="$ac_configure_args $ac_arg" ;; |
| 452 |
esac |
| 453 |
done |
| 454 |
|
| 455 |
# NLS nuisances. |
| 456 |
# Only set these to C if already set. These must not be set unconditionally |
| 457 |
# because not all systems understand e.g. LANG=C (notably SCO). |
| 458 |
# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! |
| 459 |
# Non-C LC_CTYPE values break the ctype check. |
| 460 |
if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
| 461 |
if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
| 462 |
if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi |
| 463 |
if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi |
| 464 |
|
| 465 |
# confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 466 |
rm -rf conftest* confdefs.h |
| 467 |
# AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 468 |
echo > confdefs.h |
| 469 |
|
| 470 |
# A filename unique to this package, relative to the directory that |
| 471 |
# configure is in, which we can look for to find out if srcdir is correct. |
| 472 |
ac_unique_file=ncftp/main.c |
| 473 |
|
| 474 |
# Find the source files, if location was not specified. |
| 475 |
if test -z "$srcdir"; then |
| 476 |
ac_srcdir_defaulted=yes |
| 477 |
# Try the directory containing this script, then its parent. |
| 478 |
ac_prog=$0 |
| 479 |
ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
| 480 |
test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 481 |
srcdir=$ac_confdir |
| 482 |
if test ! -r $srcdir/$ac_unique_file; then |
| 483 |
srcdir=.. |
| 484 |
fi |
| 485 |
else |
| 486 |
ac_srcdir_defaulted=no |
| 487 |
fi |
| 488 |
if test ! -r $srcdir/$ac_unique_file; then |
| 489 |
if test "$ac_srcdir_defaulted" = yes; then |
| 490 |
{ echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } |
| 491 |
else |
| 492 |
{ echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } |
| 493 |
fi |
| 494 |
fi |
| 495 |
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
| 496 |
|
| 497 |
# Prefer explicitly selected file to automatically selected ones. |
| 498 |
if test -z "$CONFIG_SITE"; then |
| 499 |
if test "x$prefix" != xNONE; then |
| 500 |
CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 501 |
else |
| 502 |
CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 503 |
fi |
| 504 |
fi |
| 505 |
for ac_site_file in $CONFIG_SITE; do |
| 506 |
if test -r "$ac_site_file"; then |
| 507 |
echo "loading site script $ac_site_file" |
| 508 |
. "$ac_site_file" |
| 509 |
fi |
| 510 |
done |
| 511 |
|
| 512 |
if test -r "$cache_file"; then |
| 513 |
echo "loading cache $cache_file" |
| 514 |
. $cache_file |
| 515 |
else |
| 516 |
echo "creating cache $cache_file" |
| 517 |
> $cache_file |
| 518 |
fi |
| 519 |
|
| 520 |
ac_ext=c |
| 521 |
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 522 |
ac_cpp='$CPP $CPPFLAGS' |
| 523 |
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 524 |
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 525 |
cross_compiling=$ac_cv_prog_cc_cross |
| 526 |
|
| 527 |
ac_exeext= |
| 528 |
ac_objext=o |
| 529 |
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
| 530 |
# Stardent Vistra SVR4 grep lacks -e, says [email protected]. |
| 531 |
if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
| 532 |
ac_n= ac_c=' |
| 533 |
' ac_t=' ' |
| 534 |
else |
| 535 |
ac_n=-n ac_c= ac_t= |
| 536 |
fi |
| 537 |
else |
| 538 |
ac_n= ac_c='\c' ac_t= |
| 539 |
fi |
| 540 |
|
| 541 |
|
| 542 |
|
| 543 |
|
| 544 |
|
| 545 |
# Check whether --enable-ccdv or --disable-ccdv was given. |
| 546 |
if test "${enable_ccdv+set}" = set; then |
| 547 |
enableval="$enable_ccdv" |
| 548 |
use_ccdv="$enableval" |
| 549 |
else |
| 550 |
use_ccdv=yes |
| 551 |
fi |
| 552 |
|
| 553 |
|
| 554 |
# Check whether --with-curses or --without-curses was given. |
| 555 |
if test "${with_curses+set}" = set; then |
| 556 |
withval="$with_curses" |
| 557 |
nc_cv_curses=$withval |
| 558 |
else |
| 559 |
nc_cv_curses=yes |
| 560 |
fi |
| 561 |
|
| 562 |
|
| 563 |
# if DEBUGBUILD is yes, other macros try to set up a compilation environment |
| 564 |
# with debugging symbols enabled. Example macros which are affected are |
| 565 |
# wi_CFLAGS and wi_SFLAG. |
| 566 |
# |
| 567 |
# Check whether --enable-debug or --disable-debug was given. |
| 568 |
if test "${enable_debug+set}" = set; then |
| 569 |
enableval="$enable_debug" |
| 570 |
|
| 571 |
DEBUGBUILD=no |
| 572 |
DEBUGCONFIGUREFLAG="" |
| 573 |
if test "$enableval" != "no" ; then |
| 574 |
DEBUGBUILD=yes |
| 575 |
DEBUGCONFIGUREFLAG="--enable-debug" |
| 576 |
fi |
| 577 |
|
| 578 |
else |
| 579 |
|
| 580 |
DEBUGBUILD=no |
| 581 |
DEBUGCONFIGUREFLAG="" |
| 582 |
|
| 583 |
fi |
| 584 |
|
| 585 |
|
| 586 |
# Check whether --with-ncurses or --without-ncurses was given. |
| 587 |
if test "${with_ncurses+set}" = set; then |
| 588 |
withval="$with_ncurses" |
| 589 |
nc_cv_ncurses=$withval |
| 590 |
else |
| 591 |
nc_cv_ncurses=yes |
| 592 |
fi |
| 593 |
|
| 594 |
|
| 595 |
# Check whether --enable-precomp or --disable-precomp was given. |
| 596 |
if test "${enable_precomp+set}" = set; then |
| 597 |
enableval="$enable_precomp" |
| 598 |
use_precomp="$enableval" |
| 599 |
else |
| 600 |
use_precomp=yes |
| 601 |
fi |
| 602 |
|
| 603 |
|
| 604 |
|
| 605 |
# Check whether --with-socks5 or --without-socks5 was given. |
| 606 |
if test "${with_socks5+set}" = set; then |
| 607 |
withval="$with_socks5" |
| 608 |
wi_want_socks5=$withval |
| 609 |
else |
| 610 |
wi_want_socks5=no |
| 611 |
fi |
| 612 |
|
| 613 |
|
| 614 |
|
| 615 |
# Check whether --enable-ssp or --disable-ssp was given. |
| 616 |
if test "${enable_ssp+set}" = set; then |
| 617 |
enableval="$enable_ssp" |
| 618 |
use_ssp="$enableval" |
| 619 |
else |
| 620 |
use_ssp=no |
| 621 |
fi |
| 622 |
|
| 623 |
|
| 624 |
|
| 625 |
# Check whether --enable-universal or --disable-universal was given. |
| 626 |
if test "${enable_universal+set}" = set; then |
| 627 |
enableval="$enable_universal" |
| 628 |
use_macosx_universal="$enableval" |
| 629 |
else |
| 630 |
use_macosx_universal=yes |
| 631 |
fi |
| 632 |
|
| 633 |
|
| 634 |
|
| 635 |
|
| 636 |
|
| 637 |
|
| 638 |
echo $ac_n "checking if you set and exported the environment variable CC""... $ac_c" 1>&6 |
| 639 |
echo "configure:640: checking if you set and exported the environment variable CC" >&5 |
| 640 |
if test "x$CC" = x ; then |
| 641 |
echo "$ac_t""no (configure will try to locate a suitable C compiler)" 1>&6 |
| 642 |
had_CC="no" |
| 643 |
else |
| 644 |
echo "$ac_t""$CC" 1>&6 |
| 645 |
had_CC="yes" |
| 646 |
fi |
| 647 |
echo $ac_n "checking for environment variable CFLAGS""... $ac_c" 1>&6 |
| 648 |
echo "configure:649: checking for environment variable CFLAGS" >&5 |
| 649 |
if test "x$CFLAGS" = x ; then |
| 650 |
echo "$ac_t""no (we will choose a default set for you)" 1>&6 |
| 651 |
else |
| 652 |
echo "$ac_t""$CFLAGS" 1>&6 |
| 653 |
fi |
| 654 |
echo $ac_n "checking for environment variable CPPFLAGS""... $ac_c" 1>&6 |
| 655 |
echo "configure:656: checking for environment variable CPPFLAGS" >&5 |
| 656 |
echo "$ac_t""${CPPFLAGS-no}" 1>&6 |
| 657 |
echo $ac_n "checking for environment variable LDFLAGS""... $ac_c" 1>&6 |
| 658 |
echo "configure:659: checking for environment variable LDFLAGS" >&5 |
| 659 |
echo "$ac_t""${LDFLAGS-no}" 1>&6 |
| 660 |
echo $ac_n "checking for environment variable LIBS""... $ac_c" 1>&6 |
| 661 |
echo "configure:662: checking for environment variable LIBS" >&5 |
| 662 |
echo "$ac_t""${LIBS-no}" 1>&6 |
| 663 |
|
| 664 |
|
| 665 |
if test "x$had_CC" = "x" ; then |
| 666 |
echo $ac_n "checking for CC environment variable""... $ac_c" 1>&6 |
| 667 |
echo "configure:668: checking for CC environment variable" >&5 |
| 668 |
echo "$ac_t"""${CC-no}"" 1>&6 |
| 669 |
fi |
| 670 |
|
| 671 |
echo $ac_n "checking for clang C compiler""... $ac_c" 1>&6 |
| 672 |
echo "configure:673: checking for clang C compiler" >&5 |
| 673 |
CLANG_CC=`which "clang" 2>/dev/null` |
| 674 |
old_CC="$CC" |
| 675 |
CC="$CLANG_CC" |
| 676 |
cat > conftest.$ac_ext <<EOF |
| 677 |
#line 678 "configure" |
| 678 |
#include "confdefs.h" |
| 679 |
#include <stdlib.h> |
| 680 |
int main(void) { |
| 681 |
extern void exit(int status); |
| 682 |
; return 0; } |
| 683 |
EOF |
| 684 |
if { (eval echo configure:685: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 685 |
rm -rf conftest* |
| 686 |
|
| 687 |
echo "$ac_t"""$CLANG_CC"" 1>&6 |
| 688 |
|
| 689 |
else |
| 690 |
echo "configure: failed program was:" >&5 |
| 691 |
cat conftest.$ac_ext >&5 |
| 692 |
rm -rf conftest* |
| 693 |
|
| 694 |
echo "$ac_t"""no"" 1>&6 |
| 695 |
unset CLANG_CC |
| 696 |
|
| 697 |
fi |
| 698 |
rm -rf conftest* |
| 699 |
CC="$old_CC"; unset old_CC |
| 700 |
|
| 701 |
echo $ac_n "checking if CC should now be set""... $ac_c" 1>&6 |
| 702 |
echo "configure:703: checking if CC should now be set" >&5 |
| 703 |
if test "x$CC" = "x" ; then |
| 704 |
if test "x$CLANG_CC" != "x" ; then |
| 705 |
CC="$CLANG_CC" |
| 706 |
export CC |
| 707 |
echo "$ac_t"""$CC"" 1>&6 |
| 708 |
else |
| 709 |
echo "$ac_t""no" 1>&6 |
| 710 |
fi |
| 711 |
else |
| 712 |
echo "$ac_t""no" 1>&6 |
| 713 |
fi |
| 714 |
# Extract the first word of "gcc", so it can be a program name with args. |
| 715 |
set dummy gcc; ac_word=$2 |
| 716 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 717 |
echo "configure:718: checking for $ac_word" >&5 |
| 718 |
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 719 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 720 |
else |
| 721 |
if test -n "$CC"; then |
| 722 |
ac_cv_prog_CC="$CC" # Let the user override the test. |
| 723 |
else |
| 724 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 725 |
ac_dummy="$PATH" |
| 726 |
for ac_dir in $ac_dummy; do |
| 727 |
test -z "$ac_dir" && ac_dir=. |
| 728 |
if test -f $ac_dir/$ac_word; then |
| 729 |
ac_cv_prog_CC="gcc" |
| 730 |
break |
| 731 |
fi |
| 732 |
done |
| 733 |
IFS="$ac_save_ifs" |
| 734 |
fi |
| 735 |
fi |
| 736 |
CC="$ac_cv_prog_CC" |
| 737 |
if test -n "$CC"; then |
| 738 |
echo "$ac_t""$CC" 1>&6 |
| 739 |
else |
| 740 |
echo "$ac_t""no" 1>&6 |
| 741 |
fi |
| 742 |
|
| 743 |
if test -z "$CC"; then |
| 744 |
# Extract the first word of "cc", so it can be a program name with args. |
| 745 |
set dummy cc; ac_word=$2 |
| 746 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 747 |
echo "configure:748: checking for $ac_word" >&5 |
| 748 |
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 749 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 750 |
else |
| 751 |
if test -n "$CC"; then |
| 752 |
ac_cv_prog_CC="$CC" # Let the user override the test. |
| 753 |
else |
| 754 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 755 |
ac_prog_rejected=no |
| 756 |
ac_dummy="$PATH" |
| 757 |
for ac_dir in $ac_dummy; do |
| 758 |
test -z "$ac_dir" && ac_dir=. |
| 759 |
if test -f $ac_dir/$ac_word; then |
| 760 |
if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
| 761 |
ac_prog_rejected=yes |
| 762 |
continue |
| 763 |
fi |
| 764 |
ac_cv_prog_CC="cc" |
| 765 |
break |
| 766 |
fi |
| 767 |
done |
| 768 |
IFS="$ac_save_ifs" |
| 769 |
if test $ac_prog_rejected = yes; then |
| 770 |
# We found a bogon in the path, so make sure we never use it. |
| 771 |
set dummy $ac_cv_prog_CC |
| 772 |
shift |
| 773 |
if test $# -gt 0; then |
| 774 |
# We chose a different compiler from the bogus one. |
| 775 |
# However, it has the same basename, so the bogon will be chosen |
| 776 |
# first if we set CC to just the basename; use the full file name. |
| 777 |
shift |
| 778 |
set dummy "$ac_dir/$ac_word" "$@" |
| 779 |
shift |
| 780 |
ac_cv_prog_CC="$@" |
| 781 |
fi |
| 782 |
fi |
| 783 |
fi |
| 784 |
fi |
| 785 |
CC="$ac_cv_prog_CC" |
| 786 |
if test -n "$CC"; then |
| 787 |
echo "$ac_t""$CC" 1>&6 |
| 788 |
else |
| 789 |
echo "$ac_t""no" 1>&6 |
| 790 |
fi |
| 791 |
|
| 792 |
if test -z "$CC"; then |
| 793 |
case "`uname -s`" in |
| 794 |
*win32* | *WIN32*) |
| 795 |
# Extract the first word of "cl", so it can be a program name with args. |
| 796 |
set dummy cl; ac_word=$2 |
| 797 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 798 |
echo "configure:799: checking for $ac_word" >&5 |
| 799 |
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
| 800 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 801 |
else |
| 802 |
if test -n "$CC"; then |
| 803 |
ac_cv_prog_CC="$CC" # Let the user override the test. |
| 804 |
else |
| 805 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 806 |
ac_dummy="$PATH" |
| 807 |
for ac_dir in $ac_dummy; do |
| 808 |
test -z "$ac_dir" && ac_dir=. |
| 809 |
if test -f $ac_dir/$ac_word; then |
| 810 |
ac_cv_prog_CC="cl" |
| 811 |
break |
| 812 |
fi |
| 813 |
done |
| 814 |
IFS="$ac_save_ifs" |
| 815 |
fi |
| 816 |
fi |
| 817 |
CC="$ac_cv_prog_CC" |
| 818 |
if test -n "$CC"; then |
| 819 |
echo "$ac_t""$CC" 1>&6 |
| 820 |
else |
| 821 |
echo "$ac_t""no" 1>&6 |
| 822 |
fi |
| 823 |
;; |
| 824 |
esac |
| 825 |
fi |
| 826 |
test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
| 827 |
fi |
| 828 |
|
| 829 |
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
| 830 |
echo "configure:831: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
| 831 |
|
| 832 |
ac_ext=c |
| 833 |
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 834 |
ac_cpp='$CPP $CPPFLAGS' |
| 835 |
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 836 |
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 837 |
cross_compiling=$ac_cv_prog_cc_cross |
| 838 |
|
| 839 |
cat > conftest.$ac_ext << EOF |
| 840 |
|
| 841 |
#line 842 "configure" |
| 842 |
#include "confdefs.h" |
| 843 |
|
| 844 |
int main(void){return(0);} |
| 845 |
EOF |
| 846 |
if { (eval echo configure:847: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 847 |
ac_cv_prog_cc_works=yes |
| 848 |
# If we can't run a trivial program, we are probably using a cross compiler. |
| 849 |
if (./conftest; exit) 2>/dev/null; then |
| 850 |
ac_cv_prog_cc_cross=no |
| 851 |
else |
| 852 |
ac_cv_prog_cc_cross=yes |
| 853 |
fi |
| 854 |
else |
| 855 |
echo "configure: failed program was:" >&5 |
| 856 |
cat conftest.$ac_ext >&5 |
| 857 |
ac_cv_prog_cc_works=no |
| 858 |
fi |
| 859 |
rm -fr conftest* |
| 860 |
ac_ext=c |
| 861 |
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 862 |
ac_cpp='$CPP $CPPFLAGS' |
| 863 |
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 864 |
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 865 |
cross_compiling=$ac_cv_prog_cc_cross |
| 866 |
|
| 867 |
echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 |
| 868 |
if test $ac_cv_prog_cc_works = no; then |
| 869 |
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } |
| 870 |
fi |
| 871 |
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
| 872 |
echo "configure:873: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
| 873 |
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
| 874 |
cross_compiling=$ac_cv_prog_cc_cross |
| 875 |
|
| 876 |
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
| 877 |
echo "configure:878: checking whether we are using GNU C" >&5 |
| 878 |
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
| 879 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 880 |
else |
| 881 |
cat > conftest.c <<EOF |
| 882 |
#ifdef __GNUC__ |
| 883 |
yes; |
| 884 |
#endif |
| 885 |
EOF |
| 886 |
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:887: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
| 887 |
ac_cv_prog_gcc=yes |
| 888 |
else |
| 889 |
ac_cv_prog_gcc=no |
| 890 |
fi |
| 891 |
fi |
| 892 |
|
| 893 |
echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
| 894 |
|
| 895 |
if test $ac_cv_prog_gcc = yes; then |
| 896 |
GCC=yes |
| 897 |
else |
| 898 |
GCC= |
| 899 |
fi |
| 900 |
|
| 901 |
ac_test_CFLAGS="${CFLAGS+set}" |
| 902 |
ac_save_CFLAGS="$CFLAGS" |
| 903 |
CFLAGS= |
| 904 |
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
| 905 |
echo "configure:906: checking whether ${CC-cc} accepts -g" >&5 |
| 906 |
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
| 907 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 908 |
else |
| 909 |
echo 'void f(){}' > conftest.c |
| 910 |
if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then |
| 911 |
ac_cv_prog_cc_g=yes |
| 912 |
else |
| 913 |
ac_cv_prog_cc_g=no |
| 914 |
fi |
| 915 |
rm -rf conftest* |
| 916 |
|
| 917 |
fi |
| 918 |
|
| 919 |
echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 |
| 920 |
if test "$ac_test_CFLAGS" = set; then |
| 921 |
CFLAGS="$ac_save_CFLAGS" |
| 922 |
elif test $ac_cv_prog_cc_g = yes; then |
| 923 |
if test "$GCC" = yes; then |
| 924 |
CFLAGS="-g -O2" |
| 925 |
else |
| 926 |
CFLAGS="-g" |
| 927 |
fi |
| 928 |
else |
| 929 |
if test "$GCC" = yes; then |
| 930 |
CFLAGS="-O2" |
| 931 |
else |
| 932 |
CFLAGS= |
| 933 |
fi |
| 934 |
fi |
| 935 |
|
| 936 |
|
| 937 |
|
| 938 |
# |
| 939 |
# Take note if the user is or is not exporting a CFLAGS env var. |
| 940 |
# |
| 941 |
wi_orig_CFLAGS="$CFLAGS" |
| 942 |
wi_CFLAGS_TO_ADD_LATER="" |
| 943 |
if [ -x "$HOME/bin/OS" ] ; then |
| 944 |
HOME_OS=`$HOME/bin/OS 2>/dev/null` |
| 945 |
HOME_OS="$HOME/$HOME_OS" |
| 946 |
else |
| 947 |
HOME_OS="$HOME" |
| 948 |
fi |
| 949 |
host=`uname -n 2>/dev/null | tr '[A-Z]' '[a-z]'` |
| 950 |
os=`uname -s 2>/dev/null | tr '[A-Z]' '[a-z]'` |
| 951 |
if [ "$os" = "TvoPT" ] ; then os="sunos" ; fi |
| 952 |
os_v=`uname -v 2>/dev/null | sed 's/^[^0-9.]*//;s/[^0-9.].*$//;'` |
| 953 |
os_r=`uname -r 2>/dev/null | sed 's/^[^0-9.]*//;s/[^0-9.].*$//;'` |
| 954 |
os_r1=`echo "${os_r}" | cut -c1` |
| 955 |
arch=`uname -m 2>/dev/null | tr '[A-Z]' '[a-z]'` |
| 956 |
archp=`uname -p 2>/dev/null | tr '[A-Z]' '[a-z]'` |
| 957 |
OS='' |
| 958 |
SYS='' |
| 959 |
NDEFS='' |
| 960 |
unset CDPATH # Not relevant here, but needs to be done eventually. |
| 961 |
|
| 962 |
# Special case a few systems where if your CFLAGS appear |
| 963 |
# to want to generate for 32 bit, use that mode rather |
| 964 |
# than 64 bit. |
| 965 |
# |
| 966 |
case "$os,$CFLAGS" in |
| 967 |
irix64,*-n32*) |
| 968 |
os=irix |
| 969 |
# then go to regular "irix" instead of "irix64" below. |
| 970 |
;; |
| 971 |
esac |
| 972 |
|
| 973 |
case "$os" in |
| 974 |
osf1) |
| 975 |
case "$os_r" in |
| 976 |
3*|4*) |
| 977 |
OS="digitalunix${os_r}-$arch" |
| 978 |
SYS=digitalunix |
| 979 |
NDEFS="$NDEFS -DDIGITAL_UNIX=$os_r1" |
| 980 |
;; |
| 981 |
*) |
| 982 |
OS="tru64unix${os_r}-$arch" |
| 983 |
SYS=tru64unix |
| 984 |
NDEFS="$NDEFS -DTRU64UNIX=$os_r1" |
| 985 |
;; |
| 986 |
esac |
| 987 |
;; |
| 988 |
aix) |
| 989 |
os_lev=`/usr/bin/oslevel 2>/dev/null` |
| 990 |
if [ "$os_lev" = "" ] ; then |
| 991 |
if [ "$os_r" = "" ] ; then os_r=0 ; fi |
| 992 |
OS="aix${os_v}.${os_r}" |
| 993 |
os_int=`expr $os_v$os_r '*' 10` |
| 994 |
else |
| 995 |
os_v=`echo "$os_lev" | cut -d. -f1-3` |
| 996 |
os_v1=`echo "$os_v" | cut -d. -f1` |
| 997 |
os_v2=`echo "$os_v" | cut -d. -f2` |
| 998 |
if [ "$os_v2" = "" ] ; then os_v2=0 ; fi |
| 999 |
os_v3=`echo "$os_v" | cut -d. -f3` |
| 1000 |
if [ "$os_v3" = "" ] ; then os_v3=0 ; fi |
| 1001 |
os_int=`expr "$os_v1" '*' 100 + "$os_v2" '*' 10 + "$os_v3"` |
| 1002 |
OS="aix${os_v}" |
| 1003 |
fi |
| 1004 |
SYS=aix |
| 1005 |
NDEFS="$NDEFS -DAIX=${os_int}" |
| 1006 |
;; |
| 1007 |
irix) |
| 1008 |
OS="irix${os_r}" |
| 1009 |
SYS=irix |
| 1010 |
NDEFS="$NDEFS -DIRIX=$os_r1" |
| 1011 |
;; |
| 1012 |
irix64) |
| 1013 |
OS="irix64_${os_r}" |
| 1014 |
SYS=irix64 |
| 1015 |
NDEFS="$NDEFS -DIRIX=$os_r1 -DIRIX64=$os_r1" |
| 1016 |
;; |
| 1017 |
hp-ux) |
| 1018 |
os_r=`echo "${os_r}" | cut -d. -f2-` |
| 1019 |
os_r1=`echo "$os_r" | cut -d. -f1` |
| 1020 |
os_r2=`echo "${os_r}" | cut -d. -f2` |
| 1021 |
os_int=`expr "$os_r1" '*' 100 + "$os_r2"` |
| 1022 |
if [ "$arch" != "ia64" ] ; then |
| 1023 |
arch="hppa" |
| 1024 |
fi |
| 1025 |
OS="hpux${os_r}-$arch" |
| 1026 |
SYS=hpux |
| 1027 |
NDEFS="$NDEFS -DHPUX=$os_int" |
| 1028 |
;; |
| 1029 |
freebsd) |
| 1030 |
if [ "$arch" = "amd64" ] ; then arch="x86_64" ; fi |
| 1031 |
OS="freebsd${os_r}-$arch" |
| 1032 |
os_r1=`echo "$os_r" | cut -d. -f1` |
| 1033 |
os_r2=`echo "$os_r" | cut -d. -f2` |
| 1034 |
if [ "$os_r2" = "" ] ; then os_r2=0 ; fi |
| 1035 |
os_r3=`echo "$os_r" | cut -d. -f3` |
| 1036 |
if [ "$os_r3" = "" ] ; then os_r3=0 ; fi |
| 1037 |
os_int=`expr "$os_r1" '*' 100 + "$os_r2" '*' 10 + "$os_r3"` |
| 1038 |
SYS=freebsd |
| 1039 |
NDEFS="$NDEFS -DFREEBSD=$os_int" |
| 1040 |
;; |
| 1041 |
netbsd) |
| 1042 |
if [ "$arch" = "amd64" ] ; then arch="x86_64" ; fi |
| 1043 |
OS="netbsd${os_r}-$arch" |
| 1044 |
os_r1=`echo "$os_r" | cut -d. -f1` |
| 1045 |
os_r2=`echo "$os_r" | cut -d. -f2` |
| 1046 |
if [ "$os_r2" = "" ] ; then os_r2=0 ; fi |
| 1047 |
os_r3=`echo "$os_r" | cut -d. -f3` |
| 1048 |
if [ "$os_r3" = "" ] ; then os_r3=0 ; fi |
| 1049 |
os_int=`expr "$os_r1" '*' 100 + "$os_r2" '*' 10 + "$os_r3"` |
| 1050 |
NDEFS="$NDEFS -DNETBSD=$os_int" |
| 1051 |
SYS=netbsd |
| 1052 |
;; |
| 1053 |
openbsd) |
| 1054 |
if [ "$arch" = "amd64" ] ; then arch="x86_64" ; fi |
| 1055 |
OS="openbsd${os_r}-$arch" |
| 1056 |
os_r1=`echo "$os_r" | cut -d. -f1` |
| 1057 |
os_r2=`echo "$os_r" | cut -d. -f2` |
| 1058 |
if [ "$os_r2" = "" ] ; then os_r2=0 ; fi |
| 1059 |
os_r3=`echo "$os_r" | cut -d. -f3` |
| 1060 |
if [ "$os_r3" = "" ] ; then os_r3=0 ; fi |
| 1061 |
os_int=`expr "$os_r1" '*' 100 + "$os_r2" '*' 10 + "$os_r3"` |
| 1062 |
SYS=openbsd |
| 1063 |
NDEFS="$NDEFS -DOPENBSD=$os_int" |
| 1064 |
;; |
| 1065 |
sco*) |
| 1066 |
OS=scosv |
| 1067 |
SYS=sco |
| 1068 |
os_v1=`echo "$os_v" | cut -d. -f1` |
| 1069 |
case "$os_v1" in |
| 1070 |
[1-9]) |
| 1071 |
os_v2=`echo "$os_v" | cut -d. -f2` |
| 1072 |
if [ "$os_v2" = "" ] ; then os_v2=0 ; fi |
| 1073 |
os_v3=`echo "$os_v" | cut -d. -f3` |
| 1074 |
if [ "$os_v3" = "" ] ; then os_v3=0 ; fi |
| 1075 |
os_int=`expr "$os_v1" '*' 100 + "$os_v2" '*' 10 + "$os_v3"` |
| 1076 |
NDEFS="$NDEFS -DSCO=$os_int" |
| 1077 |
;; |
| 1078 |
*) |
| 1079 |
NDEFS="$NDEFS -DSCO=1" |
| 1080 |
;; |
| 1081 |
esac |
| 1082 |
;; |
| 1083 |
dynix*) |
| 1084 |
OS="dynixptx${os_v}" |
| 1085 |
SYS=dynixptx |
| 1086 |
os_v1=`echo "$os_v" | cut -d. -f1` |
| 1087 |
os_v2=`echo "$os_v" | cut -d. -f2` |
| 1088 |
os_v3=`echo "$os_v" | cut -d. -f3` |
| 1089 |
if [ "$os_v3" = "" ] ; then os_v3=0 ; fi |
| 1090 |
os_int=`expr "$os_v1" '*' 100 + "$os_v2" '*' 10 + "$os_v3"` |
| 1091 |
NDEFS="$NDEFS -DDYNIX=$os_int" |
| 1092 |
;; |
| 1093 |
linux) |
| 1094 |
case "$arch" in |
| 1095 |
*86) |
| 1096 |
arch=x86 |
| 1097 |
;; |
| 1098 |
esac |
| 1099 |
|
| 1100 |
libc="" |
| 1101 |
[ -z "$os_r" ] && os_r="2.2.26" |
| 1102 |
os_r1=`echo "$os_r" | cut -d. -f1` |
| 1103 |
os_r2=`echo "$os_r" | cut -d. -f2` |
| 1104 |
os_r3=`echo "$os_r" | cut -d- -f1 | cut -d. -f3` |
| 1105 |
os_int=`expr "$os_r1" '*' 10000 + "$os_r2" '*' 1000 + "$os_r3"` |
| 1106 |
NDEFS="$NDEFS -DLINUX=$os_int" |
| 1107 |
|
| 1108 |
vertest="./vertest.$$" |
| 1109 |
rm -f "$vertest" "$vertest.c" |
| 1110 |
cat <<EOF > "$vertest.c" |
| 1111 |
#include <stdio.h> |
| 1112 |
#ifdef HAVE_STDLIB_H |
| 1113 |
# include <stdlib.h> |
| 1114 |
#endif |
| 1115 |
#include <gnu/libc-version.h> |
| 1116 |
|
| 1117 |
int main(void) |
| 1118 |
{ |
| 1119 |
const char *ver = gnu_get_libc_version(); |
| 1120 |
const char *rel = gnu_get_libc_release(); |
| 1121 |
|
| 1122 |
fprintf(stdout, "glibc%s\n", ver); |
| 1123 |
exit(0); |
| 1124 |
} |
| 1125 |
EOF |
| 1126 |
echo $ac_n "checking version of C library""... $ac_c" 1>&6 |
| 1127 |
echo "configure:: checking version of C library" >&5 |
| 1128 |
${CC-cc} $DEFS $CPPFLAGS $CFLAGS "$vertest.c" -o "$vertest" >/dev/null 2>&1 |
| 1129 |
if [ -x "$vertest" ] ; then libc=`$vertest 2>/dev/null` ; fi |
| 1130 |
rm -f "$vertest" "$vertest.c" |
| 1131 |
|
| 1132 |
if [ "$libc" = "" ] ; then |
| 1133 |
libc_sysroot=`"${CC-gcc}" -v 2>&1 | sed -n '/with-libc_sysroot/{s/^.*--with-libc_sysroot=//;s/ .*//;p;q;}'` # Only results in non-empty with a GCC cross-compiler |
| 1134 |
|
| 1135 |
libc_file=`/bin/ls -1 -t "${libc_sysroot}"/lib/libc.so.* 2>/dev/null | sed -n 1,1p` |
| 1136 |
if [ "$libc_file" != "" ] ; then |
| 1137 |
libc_file=`echo "$libc_file" | sed 's|^.*/||'` |
| 1138 |
libc_file="$libc_sysroot/lib/$libc_file" |
| 1139 |
elif [ -f "$libc_sysroot/usr/lib/libc.a" ] ; then |
| 1140 |
libc_file="$libc_sysroot/usr/lib/libc.a" |
| 1141 |
else |
| 1142 |
libc_file="/error" |
| 1143 |
fi |
| 1144 |
|
| 1145 |
libc=`strings -n 40 "$libc_file" 2>/dev/null | fgrep 'GNU C Library' | sed 's/^.*version //;s/[^0-9\.].*$//;' | sed -n 1,1p` |
| 1146 |
|
| 1147 |
if [ "$libc" != "" ] ; then |
| 1148 |
libc="glibc${libc}" |
| 1149 |
fi |
| 1150 |
fi |
| 1151 |
|
| 1152 |
case "$libc" in |
| 1153 |
glibc*) |
| 1154 |
echo "$libc" 1>&6 |
| 1155 |
glibc_r=`echo "$libc" | sed 's/glibc//'` |
| 1156 |
glibc_r1=`echo "$glibc_r" | cut -d. -f1` |
| 1157 |
glibc_r2=`echo "$glibc_r" | cut -d. -f2` |
| 1158 |
glibc_r3=`echo "$glibc_r" | cut -d- -f1 | cut -d. -f3` |
| 1159 |
if test "$glibc_r1" = "" ; then glibc_r1=0 ; fi |
| 1160 |
if test "$glibc_r2" = "" ; then glibc_r2=0 ; fi |
| 1161 |
if test "$glibc_r3" = "" ; then glibc_r3=0 ; fi |
| 1162 |
glibc_int=`expr "$glibc_r1" '*' 10000 + "$glibc_r2" '*' 100 + "$glibc_r3"` |
| 1163 |
NDEFS="$NDEFS -DLINUX_GLIBC=$glibc_int" |
| 1164 |
libc="glibc${glibc_r1}.${glibc_r2}" |
| 1165 |
OS="linux-$arch" |
| 1166 |
;; |
| 1167 |
*) |
| 1168 |
if test -f /lib/libc-2.1.3.so ; then |
| 1169 |
NDEFS="$NDEFS -DLINUX_GLIBC=20103" |
| 1170 |
libc="glibc2.1" |
| 1171 |
OS="linux-$arch" |
| 1172 |
elif test -f /lib/libc-2.1.2.so ; then |
| 1173 |
NDEFS="$NDEFS -DLINUX_GLIBC=20102" |
| 1174 |
libc="glibc2.1" |
| 1175 |
OS="linux-$arch" |
| 1176 |
elif test -f /lib/libc-2.1.1.so ; then |
| 1177 |
NDEFS="$NDEFS -DLINUX_GLIBC=20101" |
| 1178 |
libc="glibc2.1" |
| 1179 |
OS="linux-$arch" |
| 1180 |
elif test -f /lib/libc.so.6 ; then |
| 1181 |
NDEFS="$NDEFS -DLINUX_GLIBC=20000" |
| 1182 |
libc="glibc2.0" |
| 1183 |
OS="linux-$arch" |
| 1184 |
elif test -f /lib/libc.so.6.1 ; then |
| 1185 |
NDEFS="$NDEFS -DLINUX_GLIBC=20001" |
| 1186 |
libc="glibc2.0" |
| 1187 |
OS="linux-$arch" |
| 1188 |
else |
| 1189 |
NDEFS="$NDEFS -DLINUX_LIBC=5" |
| 1190 |
libc="libc5" |
| 1191 |
OS="linux-$arch" |
| 1192 |
fi |
| 1193 |
echo "$libc" 1>&6 |
| 1194 |
;; |
| 1195 |
esac |
| 1196 |
SYS=linux |
| 1197 |
;; |
| 1198 |
bsd/os) |
| 1199 |
OS="bsdos${os_r}" |
| 1200 |
SYS=bsdos |
| 1201 |
NDEFS="$NDEFS -DBSDOS=$os_r1" |
| 1202 |
;; |
| 1203 |
ultrix) |
| 1204 |
OS="ultrix-$arch" |
| 1205 |
SYS=ultrix |
| 1206 |
NDEFS="$NDEFS -DULTRIX" |
| 1207 |
;; |
| 1208 |
unixware) |
| 1209 |
OS="unixware${os_v}" |
| 1210 |
SYS=unixware |
| 1211 |
os_v1=`echo "$os_v" | cut -d. -f1` |
| 1212 |
case "$os_v1" in |
| 1213 |
[1-9]) |
| 1214 |
os_v2=`echo "$os_v" | cut -d. -f2` |
| 1215 |
os_v3=`echo "$os_v" | cut -d. -f3` |
| 1216 |
if [ "$os_v3" = "" ] ; then os_v3=0 ; fi |
| 1217 |
os_int=`expr "$os_v1" '*' 100 + "$os_v2" '*' 10 + "$os_v3"` |
| 1218 |
NDEFS="$NDEFS -DUNIXWARE=$os_int" |
| 1219 |
;; |
| 1220 |
*) |
| 1221 |
NDEFS="$NDEFS -DUNIXWARE=1" |
| 1222 |
;; |
| 1223 |
esac |
| 1224 |
;; |
| 1225 |
openunix) |
| 1226 |
OS="openunix${os_v}" |
| 1227 |
SYS=openunix |
| 1228 |
os_v1=`echo "$os_v" | cut -d. -f1` |
| 1229 |
os_v2=`echo "$os_v" | cut -d. -f2` |
| 1230 |
os_v3=`echo "$os_v" | cut -d. -f3` |
| 1231 |
if [ "$os_v3" = "" ] ; then os_v3=0 ; fi |
| 1232 |
os_int=`expr "$os_v1" '*' 100 + "$os_v2" '*' 10 + "$os_v3"` |
| 1233 |
NDEFS="$NDEFS -DOPENUNIX=$os_int -DUNIXWARE=$os_int" |
| 1234 |
;; |
| 1235 |
macos*|darwin|rhapsody) |
| 1236 |
OS="macosx" |
| 1237 |
SYS="macosx" |
| 1238 |
os_v=`perl -e '{open(F, "< /System/Library/CoreServices/SystemVersion.plist") or exit(2); my ($doc) = ""; my ($line); while (defined($line = <F>)) { $doc .= $line; } close(F); $doc =~ s/\s+//gs; if ($doc =~ /<key>ProductVersion<\/key><string>([^<]+)<\/string>/) { print , "\n"; exit(0); } exit(1); }' 2>/dev/null` |
| 1239 |
if [ "$os_v" = "" ] && [ -x "$HOME/bin/macosver" ] ; then |
| 1240 |
os_v=`"$HOME/bin/macosver" 2>/dev/null` |
| 1241 |
fi |
| 1242 |
if [ "$os_v" = "" ] ; then |
| 1243 |
cat > "$HOME/macosver.c" <<EOF |
| 1244 |
/* |
| 1245 |
<?xml version="1.0" encoding="UTF-8"?> |
| 1246 |
<!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd"> |
| 1247 |
<plist version="0.9"> |
| 1248 |
<dict> |
| 1249 |
<key>ProductBuildVersion</key> |
| 1250 |
<string>5S66</string> |
| 1251 |
<key>ProductName</key> |
| 1252 |
<string>Mac OS X</string> |
| 1253 |
<key>ProductVersion</key> |
| 1254 |
<string>10.1.5</string> |
| 1255 |
</dict> |
| 1256 |
</plist> |
| 1257 |
*/ |
| 1258 |
|
| 1259 |
#include <stdio.h> |
| 1260 |
#include <string.h> |
| 1261 |
#ifdef HAVE_STDLIB_H |
| 1262 |
# include <stdlib.h> |
| 1263 |
#endif |
| 1264 |
#include <ctype.h> |
| 1265 |
|
| 1266 |
int main(void) |
| 1267 |
{ |
| 1268 |
char line[256], *cp, *cp2; |
| 1269 |
FILE *fp; |
| 1270 |
|
| 1271 |
fp = fopen("/System/Library/CoreServices/SystemVersion.plist", "r"); |
| 1272 |
|
| 1273 |
if (fp != NULL) { |
| 1274 |
memset(line, 0, sizeof(line)); |
| 1275 |
while (fgets(line, sizeof(line) - 1, fp) != NULL) { |
| 1276 |
cp = strstr(line, "<key>ProductVersion</key>"); |
| 1277 |
if (cp != NULL) { |
| 1278 |
memset(line, 0, sizeof(line)); |
| 1279 |
if (fgets(line, sizeof(line) - 2, fp) != NULL) { |
| 1280 |
for (cp = line; ((*cp != '\0') && (! isdigit(*cp))); ) cp++; |
| 1281 |
for (cp2 = cp; ((*cp2 != '\0') && (! isspace(*cp2)) && (*cp2 != '<') && (*cp2 != '>')); ) cp2++; |
| 1282 |
cp2[0] = '\0'; |
| 1283 |
fclose(fp); |
| 1284 |
fprintf(stdout, "%s\n", cp); |
| 1285 |
exit(0); |
| 1286 |
} |
| 1287 |
} |
| 1288 |
} |
| 1289 |
} |
| 1290 |
fclose(fp); |
| 1291 |
exit(1); |
| 1292 |
} |
| 1293 |
EOF |
| 1294 |
${CC-cc} "$HOME/macosver.c" -o "$HOME/macosver" > /dev/null 2>&1 |
| 1295 |
os_v=`"$HOME/macosver" 2>/dev/null` |
| 1296 |
mv "$HOME/macosver" "$HOME/bin/macosver" 2>/dev/null |
| 1297 |
rm -f "$HOME/macosver.c" "$HOME/macosver" |
| 1298 |
fi |
| 1299 |
if [ "$os_v" != "" ] ; then |
| 1300 |
OS="macosx${os_v}" |
| 1301 |
os_v1=`echo "$os_v" | cut -d. -f1` |
| 1302 |
os_v2=`echo "$os_v" | cut -d. -f2` |
| 1303 |
os_v3=`echo "$os_v" | cut -d. -f3` |
| 1304 |
if [ "$os_v3" = "" ] ; then os_v3=0 ; fi |
| 1305 |
os_int=`expr "$os_v1" '*' 1000 + "$os_v2" '*' 100 + "$os_v3"` |
| 1306 |
NDEFS="$NDEFS -DMACOSX=$os_int" |
| 1307 |
else |
| 1308 |
NDEFS="$NDEFS -DMACOSX" |
| 1309 |
fi |
| 1310 |
;; |
| 1311 |
sunos) |
| 1312 |
if [ "$arch" = "" ] ; then arch="sparc" ; fi |
| 1313 |
if [ "$archp" = "" ] ; then archp="$arch" ; fi |
| 1314 |
case "$os_r" in |
| 1315 |
5.*) |
| 1316 |
case "$os_r" in |
| 1317 |
5.[023456]*|5.1) |
| 1318 |
os_r=`echo "$os_r" | sed 's/^5/2/;'` |
| 1319 |
os_r1=`echo "$os_r" | cut -d. -f1` |
| 1320 |
os_r2=`echo "$os_r" | cut -d. -f2` |
| 1321 |
if [ "$os_r2" = "" ] ; then os_r2=0 ; fi |
| 1322 |
os_r3=`echo "$os_r" | cut -d. -f3` |
| 1323 |
if [ "$os_r3" = "" ] ; then os_r3=0 ; fi |
| 1324 |
os_int=`expr "$os_r1" '*' 100 + "$os_r2" '*' 10 + "$os_r3"` |
| 1325 |
;; |
| 1326 |
5.[789]*|5.1[0-9]*) |
| 1327 |
os_r1=`echo "$os_r" | cut -d. -f2` |
| 1328 |
os_r2=`echo "$os_r" | cut -d. -f3` |
| 1329 |
if [ "$os_r2" = "" ] ; then os_r2=0 ; fi |
| 1330 |
os_r3=`echo "$os_r" | cut -d. -f4` |
| 1331 |
if [ "$os_r3" = "" ] ; then os_r3=0 ; fi |
| 1332 |
os_int=`expr "$os_r1" '*' 100 + "$os_r2" '*' 10 + "$os_r3"` |
| 1333 |
os_r=`echo "$os_r" | cut -c3-` |
| 1334 |
;; |
| 1335 |
esac |
| 1336 |
case "`/usr/bin/isainfo -n 2>/dev/null`" in |
| 1337 |
amd64) |
| 1338 |
OS="solaris${os_r}-x86_64" |
| 1339 |
;; |
| 1340 |
*86) |
| 1341 |
OS="solaris${os_r}-x86" |
| 1342 |
;; |
| 1343 |
sparcv9*|sparcv1[0-9]*) |
| 1344 |
OS="solaris${os_r}-sparc64" |
| 1345 |
;; |
| 1346 |
*) |
| 1347 |
OS="solaris${os_r}-$archp" |
| 1348 |
;; |
| 1349 |
esac |
| 1350 |
NDEFS="$NDEFS -DSOLARIS=$os_int" |
| 1351 |
SYS=solaris |
| 1352 |
;; |
| 1353 |
4.*) |
| 1354 |
OS="sunos${os_r}-sparc" |
| 1355 |
NDEFS="$NDEFS -DSUNOS=\\\"$os_r\\\"" |
| 1356 |
SYS=sunos |
| 1357 |
;; |
| 1358 |
*) |
| 1359 |
os_r1=`echo "$os_r" | cut -d. -f1` |
| 1360 |
if [ "$os_r1" = "" ] ; then os_r1=0 ; fi |
| 1361 |
os_r2=`echo "$os_r" | cut -d. -f2` |
| 1362 |
if [ "$os_r2" = "" ] ; then os_r2=0 ; fi |
| 1363 |
os_r3=`echo "$os_r" | cut -d. -f3` |
| 1364 |
if [ "$os_r3" = "" ] ; then os_r3=0 ; fi |
| 1365 |
os_int=`expr "$os_r1" '*' 100 + "$os_r2" '*' 10 + "$os_r3"` |
| 1366 |
OS="solaris${os_r}-$archp" |
| 1367 |
NDEFS="$NDEFS -DSOLARIS=$os_int" |
| 1368 |
SYS=solaris |
| 1369 |
;; |
| 1370 |
esac |
| 1371 |
;; |
| 1372 |
*) |
| 1373 |
OS="$os" |
| 1374 |
SYS="$os" |
| 1375 |
|
| 1376 |
if grep Novell /usr/include/sys/types.h ; then |
| 1377 |
OS="unixware${os_v}" |
| 1378 |
SYS="unixware" |
| 1379 |
fi |
| 1380 |
;; |
| 1381 |
esac |
| 1382 |
|
| 1383 |
if [ "x$wi_cv_OS" != "x" ] && [ "$wi_cv_OS" != "$OS" ] ; then |
| 1384 |
|
| 1385 |
{ echo "configure: error: Your config.cache file is invalid. It was created on $wi_cv_OS, but this machine is running $OS. Remove the config.cache file if you wish to continue." 1>&2; exit 1; } |
| 1386 |
fi |
| 1387 |
wi_cv_OS="$OS" |
| 1388 |
|
| 1389 |
if test "x$HOME_OS" = "x" && test "x$OS" != "x" ; then |
| 1390 |
HOME_OS="$HOME/$OS" |
| 1391 |
fi |
| 1392 |
|
| 1393 |
|
| 1394 |
|
| 1395 |
|
| 1396 |
|
| 1397 |
echo $ac_n "checking platform""... $ac_c" 1>&6 |
| 1398 |
echo "configure:1399: checking platform" >&5 |
| 1399 |
echo "$ac_t"""$OS"" 1>&6 |
| 1400 |
|
| 1401 |
|
| 1402 |
case "$os" in |
| 1403 |
linux) |
| 1404 |
OS="linux-$arch-$libc" |
| 1405 |
;; |
| 1406 |
esac |
| 1407 |
|
| 1408 |
if test -f sh/install-sh ; then chmod 755 sh/*.sh sh/config.* sh/install-sh ; fi |
| 1409 |
ac_aux_dir= |
| 1410 |
for ac_dir in sh $srcdir/sh; do |
| 1411 |
if test -f $ac_dir/install-sh; then |
| 1412 |
ac_aux_dir=$ac_dir |
| 1413 |
ac_install_sh="$ac_aux_dir/install-sh -c" |
| 1414 |
break |
| 1415 |
elif test -f $ac_dir/install.sh; then |
| 1416 |
ac_aux_dir=$ac_dir |
| 1417 |
ac_install_sh="$ac_aux_dir/install.sh -c" |
| 1418 |
break |
| 1419 |
fi |
| 1420 |
done |
| 1421 |
if test -z "$ac_aux_dir"; then |
| 1422 |
{ echo "configure: error: can not find install-sh or install.sh in sh $srcdir/sh" 1>&2; exit 1; } |
| 1423 |
fi |
| 1424 |
ac_config_guess=$ac_aux_dir/config.guess |
| 1425 |
ac_config_sub=$ac_aux_dir/config.sub |
| 1426 |
ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. |
| 1427 |
|
| 1428 |
|
| 1429 |
echo $ac_n "checking if the C compiler can use precompiled headers""... $ac_c" 1>&6 |
| 1430 |
echo "configure:1431: checking if the C compiler can use precompiled headers" >&5 |
| 1431 |
if eval "test \"`echo '$''{'wi_cv_cc_precomp'+set}'`\" = set"; then |
| 1432 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 1433 |
else |
| 1434 |
|
| 1435 |
result="no" |
| 1436 |
if test "${use_macosx_universal}" != no ; then |
| 1437 |
# Precompiling the headers doesn't seem to work when building universal binaries |
| 1438 |
use_precomp=no |
| 1439 |
fi |
| 1440 |
if test "${use_precomp-yes}" != no ; then |
| 1441 |
wi_cv_cc_precomp_type="unknown" |
| 1442 |
rm -f pchtest.h pchtest.p pchtest.c pchtest.o pchtest csetc.pch pchtest.pch pchtest.h.gch |
| 1443 |
cat <<EOF > pchtest.h |
| 1444 |
/* pchtest.h */ |
| 1445 |
#include <stdio.h> |
| 1446 |
#include <string.h> |
| 1447 |
#include <stdlib.h> |
| 1448 |
#define FOOBAR 33 /* Make sure it can compile custom headers too */ |
| 1449 |
EOF |
| 1450 |
cat <<EOF > pchtest.c |
| 1451 |
/* pchtest.c */ |
| 1452 |
#include "pchtest.h" |
| 1453 |
|
| 1454 |
int main(int argc, char **argv) |
| 1455 |
{ |
| 1456 |
if (FOOBAR == 33) |
| 1457 |
exit(0); |
| 1458 |
exit(1); |
| 1459 |
} |
| 1460 |
EOF |
| 1461 |
if test "$GCC" = yes ; then |
| 1462 |
# |
| 1463 |
# Try gcc 3.4's built-in implementation first |
| 1464 |
# |
| 1465 |
echo ${CC-cc} $CPPFLAGS pchtest.h -c >&5 |
| 1466 |
${CC-cc} $CPPFLAGS pchtest.h -c >&5 2>&5 |
| 1467 |
if test -f pchtest.h.gch ; then |
| 1468 |
# |
| 1469 |
# Good, the .gch file was created. |
| 1470 |
# Odds are we're good to go. |
| 1471 |
# |
| 1472 |
echo "Successfully compiled pchtest.h into the precompiled header file pchtest.h.gch." >&5 |
| 1473 |
cat > conftest.$ac_ext <<EOF |
| 1474 |
#line 1475 "configure" |
| 1475 |
#include "confdefs.h" |
| 1476 |
#include "pchtest.h" |
| 1477 |
int main(void) { |
| 1478 |
if (FOOBAR == 33) exit(0) |
| 1479 |
; return 0; } |
| 1480 |
EOF |
| 1481 |
if { (eval echo configure:1482: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 1482 |
rm -rf conftest* |
| 1483 |
result="yes" ; wi_cv_cc_precomp_type="gcc_gch_files" |
| 1484 |
else |
| 1485 |
echo "configure: failed program was:" >&5 |
| 1486 |
cat conftest.$ac_ext >&5 |
| 1487 |
rm -rf conftest* |
| 1488 |
result="no" |
| 1489 |
fi |
| 1490 |
rm -rf conftest* |
| 1491 |
else |
| 1492 |
echo "This version of GCC did not compile pchtest.h into the precompiled header file pchtest.h.gch." >&5 |
| 1493 |
# |
| 1494 |
# See if Apple's implementation works. |
| 1495 |
# |
| 1496 |
echo ${CC-cc} $CPPFLAGS -precomp pchtest.h -o pchtest.p >&5 |
| 1497 |
${CC-cc} $CPPFLAGS -precomp pchtest.h -o pchtest.p >&5 2>&5 |
| 1498 |
if test -s pchtest.p ; then |
| 1499 |
cat > conftest.$ac_ext <<EOF |
| 1500 |
#line 1501 "configure" |
| 1501 |
#include "confdefs.h" |
| 1502 |
#include "pchtest.h" |
| 1503 |
int main(void) { |
| 1504 |
if (FOOBAR == 33) exit(0) |
| 1505 |
; return 0; } |
| 1506 |
EOF |
| 1507 |
if { (eval echo configure:1508: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 1508 |
rm -rf conftest* |
| 1509 |
result="yes" ; wi_cv_cc_precomp_type="gcc_dash_precomp" |
| 1510 |
else |
| 1511 |
echo "configure: failed program was:" >&5 |
| 1512 |
cat conftest.$ac_ext >&5 |
| 1513 |
rm -rf conftest* |
| 1514 |
result="no" |
| 1515 |
fi |
| 1516 |
rm -rf conftest* |
| 1517 |
fi |
| 1518 |
fi |
| 1519 |
elif test "${result}_${SYS-aix}_${GCC}" = "no_aix_no" ; then |
| 1520 |
# |
| 1521 |
# AIX xlc |
| 1522 |
# |
| 1523 |
echo ${CC-cc} $CPPFLAGS -qusepcomp -qgenpcomp pchtest.c -o pchtest >&5 |
| 1524 |
${CC-cc} $CPPFLAGS -qusepcomp -qgenpcomp pchtest.c -o pchtest >&5 2>&5 |
| 1525 |
if test -s pchtest ; then |
| 1526 |
result="yes" |
| 1527 |
wi_cv_cc_precomp_type="xlc" |
| 1528 |
wi_CFLAGS_TO_ADD_LATER="$wi_CFLAGS_TO_ADD_LATER -qusepcomp -qgenpcomp" |
| 1529 |
fi |
| 1530 |
else |
| 1531 |
# |
| 1532 |
# IRIX, Compaq C, Sun C |
| 1533 |
# |
| 1534 |
cat <<EOF > pchtest.c |
| 1535 |
#include "pchtest.h" |
| 1536 |
#pragma hdrstop |
| 1537 |
#include <stdarg.h> |
| 1538 |
|
| 1539 |
int main(int argc, char **argv) |
| 1540 |
{ |
| 1541 |
if (FOOBAR == 33) |
| 1542 |
exit(0); |
| 1543 |
exit(1); |
| 1544 |
} |
| 1545 |
EOF |
| 1546 |
for pchflags in "-xpch=auto" "-pch -no_pch_messages" "-pch" "-LANG:pch" |
| 1547 |
do |
| 1548 |
rm -rf SunWS_cache pchtest.pch pchtest.cpch |
| 1549 |
echo ${CC-cc} $CPPFLAGS $pchflags pchtest.c -o pchtest >&5 |
| 1550 |
${CC-cc} $CPPFLAGS $pchflags pchtest.c -o pchtest >&5 2>&5 |
| 1551 |
if test -f pchtest.pch ; then |
| 1552 |
result="yes" |
| 1553 |
wi_cv_cc_precomp_type="ccc" |
| 1554 |
wi_CFLAGS_TO_ADD_LATER="$wi_CFLAGS_TO_ADD_LATER $pchflags" |
| 1555 |
cat >> confdefs.h <<\EOF |
| 1556 |
#define PRAGMA_HDRSTOP 1 |
| 1557 |
EOF |
| 1558 |
|
| 1559 |
break |
| 1560 |
elif test -d SunWS_cache ; then |
| 1561 |
result="yes" |
| 1562 |
wi_cv_cc_precomp_type="SunWS" |
| 1563 |
wi_CFLAGS_TO_ADD_LATER="$wi_CFLAGS_TO_ADD_LATER $pchflags -erroff=E_PCH_CONDITIONAL_PREFIX" |
| 1564 |
cat >> confdefs.h <<\EOF |
| 1565 |
#define PRAGMA_HDRSTOP 1 |
| 1566 |
EOF |
| 1567 |
|
| 1568 |
break |
| 1569 |
fi |
| 1570 |
done |
| 1571 |
unset pchflags |
| 1572 |
fi |
| 1573 |
rm -rf SunWS_cache pchtest.h pchtest.p pchtest.c pchtest.o pchtest csetc.pch pchtest.pch pchtest.cpch pchtest.h.gch |
| 1574 |
fi |
| 1575 |
wi_cv_cc_precomp="$result" |
| 1576 |
|
| 1577 |
fi |
| 1578 |
|
| 1579 |
echo "$ac_t""$wi_cv_cc_precomp" 1>&6 |
| 1580 |
|
| 1581 |
|
| 1582 |
wi_request_no_y2k_warnings=yes |
| 1583 |
|
| 1584 |
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
| 1585 |
echo "configure:1586: checking how to run the C preprocessor" >&5 |
| 1586 |
# On Suns, sometimes $CPP names a directory. |
| 1587 |
if test -n "$CPP" && test -d "$CPP"; then |
| 1588 |
CPP= |
| 1589 |
fi |
| 1590 |
if test -z "$CPP"; then |
| 1591 |
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
| 1592 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 1593 |
else |
| 1594 |
# This must be in double quotes, not single quotes, because CPP may get |
| 1595 |
# substituted into the Makefile and "${CC-cc}" will confuse make. |
| 1596 |
CPP="${CC-cc} -E" |
| 1597 |
# On the NeXT, cc -E runs the code through the compiler's parser, |
| 1598 |
# not just through cpp. |
| 1599 |
cat > conftest.$ac_ext <<EOF |
| 1600 |
#line 1601 "configure" |
| 1601 |
#include "confdefs.h" |
| 1602 |
#include <assert.h> |
| 1603 |
Syntax Error |
| 1604 |
EOF |
| 1605 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 1606 |
{ (eval echo configure:1607: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 1607 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1608 |
if test -z "$ac_err"; then |
| 1609 |
: |
| 1610 |
else |
| 1611 |
echo "$ac_err" >&5 |
| 1612 |
echo "configure: failed program was:" >&5 |
| 1613 |
cat conftest.$ac_ext >&5 |
| 1614 |
rm -rf conftest* |
| 1615 |
CPP="${CC-cc} -E -traditional-cpp" |
| 1616 |
cat > conftest.$ac_ext <<EOF |
| 1617 |
#line 1618 "configure" |
| 1618 |
#include "confdefs.h" |
| 1619 |
#include <assert.h> |
| 1620 |
Syntax Error |
| 1621 |
EOF |
| 1622 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 1623 |
{ (eval echo configure:1624: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 1624 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1625 |
if test -z "$ac_err"; then |
| 1626 |
: |
| 1627 |
else |
| 1628 |
echo "$ac_err" >&5 |
| 1629 |
echo "configure: failed program was:" >&5 |
| 1630 |
cat conftest.$ac_ext >&5 |
| 1631 |
rm -rf conftest* |
| 1632 |
CPP="${CC-cc} -nologo -E" |
| 1633 |
cat > conftest.$ac_ext <<EOF |
| 1634 |
#line 1635 "configure" |
| 1635 |
#include "confdefs.h" |
| 1636 |
#include <assert.h> |
| 1637 |
Syntax Error |
| 1638 |
EOF |
| 1639 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 1640 |
{ (eval echo configure:1641: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 1641 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1642 |
if test -z "$ac_err"; then |
| 1643 |
: |
| 1644 |
else |
| 1645 |
echo "$ac_err" >&5 |
| 1646 |
echo "configure: failed program was:" >&5 |
| 1647 |
cat conftest.$ac_ext >&5 |
| 1648 |
rm -rf conftest* |
| 1649 |
CPP=/lib/cpp |
| 1650 |
fi |
| 1651 |
rm -rf conftest* |
| 1652 |
fi |
| 1653 |
rm -rf conftest* |
| 1654 |
fi |
| 1655 |
rm -rf conftest* |
| 1656 |
ac_cv_prog_CPP="$CPP" |
| 1657 |
fi |
| 1658 |
CPP="$ac_cv_prog_CPP" |
| 1659 |
else |
| 1660 |
ac_cv_prog_CPP="$CPP" |
| 1661 |
fi |
| 1662 |
echo "$ac_t""$CPP" 1>&6 |
| 1663 |
|
| 1664 |
|
| 1665 |
wi_cv_lfs_type="lfs" |
| 1666 |
if test "$SYS" = "linux" ; then |
| 1667 |
case "$libc" in |
| 1668 |
libc5) |
| 1669 |
wi_cv_lfs_type="lfs64" |
| 1670 |
;; |
| 1671 |
glibc2.[012]*) |
| 1672 |
wi_cv_lfs_type="lfs64" |
| 1673 |
;; |
| 1674 |
esac |
| 1675 |
fi |
| 1676 |
case "$OS" in |
| 1677 |
bsdos*) |
| 1678 |
wi_cv_lfs_type="lfs64" |
| 1679 |
;; |
| 1680 |
freebsd[234]*) |
| 1681 |
wi_cv_lfs_type="lfs64" |
| 1682 |
;; |
| 1683 |
hpux9.*|hpux10.*) |
| 1684 |
wi_cv_lfs_type="lfs64" |
| 1685 |
;; |
| 1686 |
solaris2.*|solaris7*) |
| 1687 |
wi_cv_lfs_type="lfs64" |
| 1688 |
;; |
| 1689 |
esac |
| 1690 |
if test "$wi_cv_lfs_type" = "lfs64" ; then |
| 1691 |
|
| 1692 |
|
| 1693 |
|
| 1694 |
|
| 1695 |
|
| 1696 |
if test "$GCC" = yes ; then |
| 1697 |
echo $ac_n "checking the version of GCC""... $ac_c" 1>&6 |
| 1698 |
echo "configure:1699: checking the version of GCC" >&5 |
| 1699 |
if eval "test \"`echo '$''{'wi_cv_gcc_version'+set}'`\" = set"; then |
| 1700 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 1701 |
else |
| 1702 |
|
| 1703 |
wi_cv_gcc_version=`$CC -v 2>&1 | sed -n '/gcc version/{s/^.*gcc version//;s/^[^1-9]*//;s/\ .*//;p;q;}'` |
| 1704 |
|
| 1705 |
fi |
| 1706 |
|
| 1707 |
echo "$ac_t""$wi_cv_gcc_version" 1>&6 |
| 1708 |
else |
| 1709 |
wi_cv_gcc_version="0" |
| 1710 |
fi |
| 1711 |
|
| 1712 |
|
| 1713 |
|
| 1714 |
|
| 1715 |
if test "${SYS}_${GCC}" != solaris_no ; then |
| 1716 |
wi_cv_cc_is_sunwspro_cc="no" |
| 1717 |
wi_cv_sunwspro_cc_version="0" |
| 1718 |
wi_cv_sunwspro_cc_version2="0" |
| 1719 |
else |
| 1720 |
echo $ac_n "checking if the C compiler is Sun WorkShop C""... $ac_c" 1>&6 |
| 1721 |
echo "configure:1722: checking if the C compiler is Sun WorkShop C" >&5 |
| 1722 |
if eval "test \"`echo '$''{'wi_cv_cc_is_sunwspro_cc'+set}'`\" = set"; then |
| 1723 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 1724 |
else |
| 1725 |
|
| 1726 |
# |
| 1727 |
# cc: Sun WorkShop 6 update 2 C 5.3 2001/05/15 |
| 1728 |
# usage: cc [ options] files. Use 'cc -flags' for details |
| 1729 |
# |
| 1730 |
# cc: WorkShop Compilers 4.2 30 Oct 1996 C 4.2 |
| 1731 |
# usage: cc [ options] files. Use 'cc -flags' for details |
| 1732 |
# |
| 1733 |
wi_cv_sunwspro_cc_version=`$CC -V 2>&1 | sed -n '/WorkShop.*C\ [1-9]/{s/^.*C/C/;s/^C\ \([^\ ]*\).*/\1/;p;q;}'` |
| 1734 |
case "$wi_cv_sunwspro_cc_version" in |
| 1735 |
[1-9]*) |
| 1736 |
wi_cv_cc_is_sunwspro_cc="yes" |
| 1737 |
ver1=`echo "$wi_cv_sunwspro_cc_version" | cut -d. -f1` |
| 1738 |
ver2=`echo "$wi_cv_sunwspro_cc_version" | cut -d. -f2` |
| 1739 |
ver3=0 |
| 1740 |
wi_cv_sunwspro_cc_version2=`expr "$ver1" '*' 100 + "$ver2" "*" 10 + "$ver3"` |
| 1741 |
unset ver1 ver2 ver3 |
| 1742 |
;; |
| 1743 |
*) |
| 1744 |
wi_cv_cc_is_sunwspro_cc="no" |
| 1745 |
wi_cv_sunwspro_cc_version="0" |
| 1746 |
wi_cv_sunwspro_cc_version2="0" |
| 1747 |
;; |
| 1748 |
esac |
| 1749 |
|
| 1750 |
fi |
| 1751 |
|
| 1752 |
echo "$ac_t""$wi_cv_cc_is_sunwspro_cc" 1>&6 |
| 1753 |
if test "$wi_cv_cc_is_sunwspro_cc" = yes ; then |
| 1754 |
echo $ac_n "checking output of "cc -V" to determine version of Sun WorkShop C""... $ac_c" 1>&6 |
| 1755 |
echo "configure:1756: checking output of "cc -V" to determine version of Sun WorkShop C" >&5 |
| 1756 |
echo "$ac_t"""version $wi_cv_sunwspro_cc_version"" 1>&6 |
| 1757 |
fi |
| 1758 |
fi |
| 1759 |
|
| 1760 |
|
| 1761 |
echo $ac_n "checking if we should customize your CFLAGS environment variable""... $ac_c" 1>&6 |
| 1762 |
echo "configure:1763: checking if we should customize your CFLAGS environment variable" >&5 |
| 1763 |
wi_replace_O_with_g="no" |
| 1764 |
case "$wi_orig_CFLAGS" in |
| 1765 |
"") |
| 1766 |
wi_replace_O_with_g="no" |
| 1767 |
;; |
| 1768 |
"-g -O2") |
| 1769 |
wi_replace_O_with_g="no" |
| 1770 |
;; |
| 1771 |
"-g -O") |
| 1772 |
wi_replace_O_with_g="no" |
| 1773 |
;; |
| 1774 |
"-O2 -g") |
| 1775 |
wi_replace_O_with_g="no" |
| 1776 |
;; |
| 1777 |
"-O -g") |
| 1778 |
wi_replace_O_with_g="no" |
| 1779 |
;; |
| 1780 |
-g) |
| 1781 |
wi_replace_O_with_g="yes" |
| 1782 |
;; |
| 1783 |
esac |
| 1784 |
|
| 1785 |
# |
| 1786 |
# See if your CFLAGS environment variable wasn't set or exported, |
| 1787 |
# or if you are using a conservative default. If so, we will |
| 1788 |
# add some additional flags for better performance, warning reporting, |
| 1789 |
# etc. |
| 1790 |
# |
| 1791 |
# Note we are now checking the current value of CFLAGS, which may have |
| 1792 |
# been changed by configure. |
| 1793 |
# |
| 1794 |
wi_os_default_cflags="no" |
| 1795 |
case "$CFLAGS" in |
| 1796 |
"") |
| 1797 |
wi_os_default_cflags="yes" |
| 1798 |
;; |
| 1799 |
"-g -O2") |
| 1800 |
wi_os_default_cflags="yes" |
| 1801 |
;; |
| 1802 |
"-g -O") |
| 1803 |
wi_os_default_cflags="yes" |
| 1804 |
;; |
| 1805 |
"-O2 -g") |
| 1806 |
wi_os_default_cflags="yes" |
| 1807 |
;; |
| 1808 |
"-O -g") |
| 1809 |
wi_os_default_cflags="yes" |
| 1810 |
;; |
| 1811 |
-g) |
| 1812 |
wi_os_default_cflags="yes" |
| 1813 |
;; |
| 1814 |
-O) |
| 1815 |
wi_os_default_cflags="yes" |
| 1816 |
;; |
| 1817 |
-O2) |
| 1818 |
wi_os_default_cflags="yes" |
| 1819 |
;; |
| 1820 |
esac |
| 1821 |
|
| 1822 |
CC_is_clang="no" |
| 1823 |
case "$CC" in |
| 1824 |
*clang*) |
| 1825 |
CC_is_clang="yes" |
| 1826 |
;; |
| 1827 |
*) |
| 1828 |
cc_dash_v=`${CC-gcc} -v 2>&1 | grep clang 2>/dev/null` |
| 1829 |
if test -n "$cc_dash_v" ; then |
| 1830 |
CC_is_clang="yes" |
| 1831 |
fi |
| 1832 |
;; |
| 1833 |
esac |
| 1834 |
|
| 1835 |
if test "$wi_os_default_cflags" = yes ; then |
| 1836 |
if test "$CC_is_clang" = yes ; then |
| 1837 |
wi_os_default_cflags="-Weverything -Wno-unknown-warning-option -Wno-disabled-macro-expansion -Wno-missing-variable-declarations -Wno-date-time" |
| 1838 |
if test "$wi_replace_O_with_g" = yes ; then |
| 1839 |
wi_os_default_cflags="-g $wi_os_default_cflags" |
| 1840 |
else |
| 1841 |
wi_os_default_cflags="-O2 $wi_os_default_cflags" |
| 1842 |
fi |
| 1843 |
elif test "$GCC" = yes ; then |
| 1844 |
# |
| 1845 |
# gcc |
| 1846 |
# |
| 1847 |
wi_gcc_optimizer_flags='' |
| 1848 |
case "$wi_cv_gcc_version" in |
| 1849 |
2.7.*|2.8.*|2.9*) |
| 1850 |
wi_os_default_cflags="-W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Wbad-function-cast -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wmissing-declarations -Winline" |
| 1851 |
;; |
| 1852 |
345.*) |
| 1853 |
wi_os_default_cflags="-W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Wbad-function-cast -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wmissing-declarations -Winline -Wmissing-format-attribute -Wformat-security" |
| 1854 |
wi_gcc_optimizer_flags='-Wdisabled-optimization' |
| 1855 |
;; |
| 1856 |
*) |
| 1857 |
wi_os_default_cflags="-W -Wall" |
| 1858 |
;; |
| 1859 |
esac |
| 1860 |
if test "$wi_replace_O_with_g" = yes ; then |
| 1861 |
wi_os_default_cflags="-g $wi_os_default_cflags" |
| 1862 |
else |
| 1863 |
wi_os_default_cflags="-O2 $wi_os_default_cflags" |
| 1864 |
if test "$wi_gcc_optimizer_flags" != "" ; then |
| 1865 |
wi_os_default_cflags="$wi_os_default_cflags $wi_gcc_optimizer_flags" |
| 1866 |
fi |
| 1867 |
fi |
| 1868 |
case "$OS" in |
| 1869 |
hpux*) |
| 1870 |
wi_os_default_cflags="-D_HPUX_SOURCE $wi_os_default_cflags" |
| 1871 |
;; |
| 1872 |
bsdos*) |
| 1873 |
wi_os_default_cflags=`echo "$wi_os_default_cflags" | sed 's/\ -Wcast-qual//g'` # avoid va_start() problem |
| 1874 |
wi_os_default_cflags=`echo "$wi_os_default_cflags" | sed 's/\ -Wredundant-decls//g'` |
| 1875 |
;; |
| 1876 |
openbsd*|unixware*|openunix*) |
| 1877 |
wi_os_default_cflags=`echo "$wi_os_default_cflags" | sed 's/\ -Wredundant-decls//g'` |
| 1878 |
;; |
| 1879 |
esac |
| 1880 |
else |
| 1881 |
# |
| 1882 |
# regular cc |
| 1883 |
# |
| 1884 |
case "${wi_replace_O_with_g}_${OS}" in |
| 1885 |
no_aix*) |
| 1886 |
wi_os_default_cflags="-O -qinfo=cmp:cnd:dcl:eff:gen:ini:par:pro:rea:use -qlonglong -qro -qroconst -qlanglvl=extended -qsrcmsg -qmaxmem=20480 -qsuppress=1506-469:1506-409" |
| 1887 |
;; |
| 1888 |
yes_aix*) |
| 1889 |
wi_os_default_cflags="-g -qinfo=cmp:cnd:dcl:eff:gen:ini:par:pro:rea:use -qlonglong -qro -qroconst -qlanglvl=extended -qsrcmsg -qmaxmem=20480 -qsuppress=1506-469:1506-409" |
| 1890 |
;; |
| 1891 |
no_irix2345*|no_irix6.01234*) |
| 1892 |
wi_os_default_cflags="-O2 -xansi -fullwarn -use_readonly_const -G0 -rdata_shared" |
| 1893 |
;; |
| 1894 |
yes_irix2345*|yes_irix6.01234*) |
| 1895 |
wi_os_default_cflags="-g -xansi -fullwarn -use_readonly_const -G0 -rdata_shared" |
| 1896 |
;; |
| 1897 |
no_irix*) |
| 1898 |
wi_os_default_cflags="-O2 -IPA -xansi -fullwarn -use_readonly_const -G0 -rdata_shared -woff 1174" |
| 1899 |
;; |
| 1900 |
yes_irix*) |
| 1901 |
wi_os_default_cflags="-g -xansi -fullwarn -use_readonly_const -G0 -rdata_shared -woff 1174" |
| 1902 |
;; |
| 1903 |
no_digitalunix*) |
| 1904 |
wi_os_default_cflags="-O4 -std1 -portable -readonly_strings" |
| 1905 |
;; |
| 1906 |
yes_digitalunix*) |
| 1907 |
wi_os_default_cflags="-g -std1 -portable -readonly_strings" |
| 1908 |
;; |
| 1909 |
no_hpux*) |
| 1910 |
wi_os_default_cflags="-Ae +O2 +Ovolatile +Olibcalls +ESlit +w1 +DAportable" |
| 1911 |
;; |
| 1912 |
yes_hpux*) |
| 1913 |
wi_os_default_cflags="-Ae -g +w1 +DAportable" |
| 1914 |
;; |
| 1915 |
no_solaris*86|no_solaris*intel) |
| 1916 |
# Not really any significant differences |
| 1917 |
# from the sparc flags, but reserved for |
| 1918 |
# future use. |
| 1919 |
# |
| 1920 |
if test "$wi_cv_sunwspro_cc_version2" -ge 530 ; then |
| 1921 |
wi_os_default_cflags="-xipo -xO4 -xc99 -xbuiltin -xstrconst -dalign -Qn -errtags=yes -erroff=E_END_OF_LOOP_CODE_NOT_REACHED -mc" |
| 1922 |
else |
| 1923 |
wi_os_default_cflags="-xO4 -xstrconst -dalign -Qn" |
| 1924 |
fi |
| 1925 |
;; |
| 1926 |
yes_solaris*86|yes_solaris*intel) |
| 1927 |
if test "$wi_cv_sunwspro_cc_version2" -ge 530 ; then |
| 1928 |
wi_os_default_cflags="-g -xc99 -xstrconst -dalign -Qn -errtags=yes -erroff=E_END_OF_LOOP_CODE_NOT_REACHED" |
| 1929 |
else |
| 1930 |
wi_os_default_cflags="-g -xstrconst -dalign -Qn" |
| 1931 |
fi |
| 1932 |
;; |
| 1933 |
no_solaris*) |
| 1934 |
if test "$wi_cv_sunwspro_cc_version2" -ge 530 ; then |
| 1935 |
wi_os_default_cflags="-xipo -xO5 -xc99 -xbuiltin -xstrconst -dalign -Qn -errtags=yes -erroff=E_END_OF_LOOP_CODE_NOT_REACHED -mc" |
| 1936 |
else |
| 1937 |
wi_os_default_cflags="-xO4 -xstrconst -dalign -Qn" |
| 1938 |
fi |
| 1939 |
;; |
| 1940 |
yes_solaris*) |
| 1941 |
if test "$wi_cv_sunwspro_cc_version2" -ge 530 ; then |
| 1942 |
wi_os_default_cflags="-g -xc99 -xstrconst -dalign -Qn -errtags=yes -erroff=E_END_OF_LOOP_CODE_NOT_REACHED" |
| 1943 |
else |
| 1944 |
wi_os_default_cflags="-g -xstrconst -dalign -Qn" |
| 1945 |
fi |
| 1946 |
;; |
| 1947 |
no_tru64*) |
| 1948 |
wi_os_default_cflags="-O4 -tune host -std1 -readonly_strings -portable -warnprotos -msg_enable level6 -msg_disable longlongtype,hexoctunsign,unusedincl,unnecincl,nestincl,unusedtop,unknownmacro,ignorecallval,strctpadding,truncintasn,truncintcast,trunclongcast,ansialiascast,conststocls,unrefsdecl,subscrbounds2,intconcastsgn,longlongsufx,unreachcode,valuepres,embedcomment" |
| 1949 |
;; |
| 1950 |
yes_tru64*) |
| 1951 |
wi_os_default_cflags="-g -std1 -readonly_strings -portable -warnprotos -msg_enable level6 -msg_disable longlongtype,hexoctunsign,unusedincl,unnecincl,nestincl,unusedtop,unknownmacro,ignorecallval,strctpadding,truncintasn,truncintcast,trunclongcast,ansialiascast,conststocls,unrefsdecl,subscrbounds2,intconcastsgn,longlongsufx,unreachcode,valuepres,embedcomment" |
| 1952 |
;; |
| 1953 |
no_unixware*|no_openunix*) |
| 1954 |
wi_os_default_cflags='-O -K inline -K host -Q n' |
| 1955 |
;; |
| 1956 |
yes_unixware*|yes_openunix*) |
| 1957 |
wi_os_default_cflags='-g -K host -Q n' |
| 1958 |
;; |
| 1959 |
*) |
| 1960 |
wi_os_default_cflags="no" |
| 1961 |
;; |
| 1962 |
esac |
| 1963 |
fi |
| 1964 |
fi |
| 1965 |
if test "$wi_os_default_cflags" != "no" ; then |
| 1966 |
CFLAGS="$wi_os_default_cflags" |
| 1967 |
fi |
| 1968 |
echo "$ac_t""$wi_os_default_cflags" 1>&6 |
| 1969 |
|
| 1970 |
|
| 1971 |
case "$OS" in |
| 1972 |
"solaris"*"-x86_64") |
| 1973 |
if test "$GCC" = "yes" ; then |
| 1974 |
case "$CFLAGS" in |
| 1975 |
*"-m64"*) |
| 1976 |
;; |
| 1977 |
*) |
| 1978 |
CFLAGS="-m64 $CFLAGS" |
| 1979 |
;; |
| 1980 |
esac |
| 1981 |
fi |
| 1982 |
;; |
| 1983 |
esac |
| 1984 |
|
| 1985 |
|
| 1986 |
|
| 1987 |
if test "x$wi_request_no_y2k_warnings" = xyes ; then |
| 1988 |
case "${wi_cv_gcc_version-0}" in |
| 1989 |
0|1.*|2.[012345678].*) |
| 1990 |
;; |
| 1991 |
*) |
| 1992 |
case "$CFLAGS" in |
| 1993 |
*-Wno-format-y2k*) |
| 1994 |
;; |
| 1995 |
*) |
| 1996 |
oldCFLAGS="$CFLAGS" |
| 1997 |
CFLAGS="$CFLAGS -Wno-format-y2k" |
| 1998 |
# |
| 1999 |
# Now check if this version of GCC |
| 2000 |
# accepts this flag... |
| 2001 |
# |
| 2002 |
cat > conftest.$ac_ext <<EOF |
| 2003 |
#line 2004 "configure" |
| 2004 |
#include "confdefs.h" |
| 2005 |
|
| 2006 |
int main(void) { |
| 2007 |
int junk; |
| 2008 |
; return 0; } |
| 2009 |
EOF |
| 2010 |
if { (eval echo configure:2011: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 2011 |
: |
| 2012 |
else |
| 2013 |
echo "configure: failed program was:" >&5 |
| 2014 |
cat conftest.$ac_ext >&5 |
| 2015 |
rm -rf conftest* |
| 2016 |
CFLAGS="$oldCFLAGS" |
| 2017 |
fi |
| 2018 |
rm -rf conftest* |
| 2019 |
unset oldCFLAGS |
| 2020 |
;; |
| 2021 |
esac |
| 2022 |
;; |
| 2023 |
esac |
| 2024 |
fi |
| 2025 |
|
| 2026 |
|
| 2027 |
echo $ac_n "checking for ldd""... $ac_c" 1>&6 |
| 2028 |
echo "configure:2029: checking for ldd" >&5 |
| 2029 |
if eval "test \"`echo '$''{'wi_cv_prog_ldd'+set}'`\" = set"; then |
| 2030 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 2031 |
else |
| 2032 |
|
| 2033 |
wi_cv_prog_ldd="no" |
| 2034 |
cat > conftest.c <<EOF |
| 2035 |
#include <stdio.h> |
| 2036 |
#include <stdlib.h> |
| 2037 |
int main(int argc, char **argv) |
| 2038 |
{ |
| 2039 |
(void) printf("%s\n", ((argc > 66) ? argv[0] : "Hello World")); |
| 2040 |
exit(0); |
| 2041 |
} |
| 2042 |
EOF |
| 2043 |
${CC-cc} $CFLAGS $CPPFLAGS conftest.c -o conftest 1>&5 |
| 2044 |
wi_cv_prog_ldd=`ldd ./conftest 2>&1 | sed -n -e '/lib/{s/.*/yes/g;p;q;}' -e '${s/.*/no/g;p;q;}'` |
| 2045 |
/bin/rm -rf conftest* |
| 2046 |
|
| 2047 |
fi |
| 2048 |
|
| 2049 |
echo "$ac_t""$wi_cv_prog_ldd" 1>&6 |
| 2050 |
|
| 2051 |
if test "$use_ssp" = yes ;then |
| 2052 |
|
| 2053 |
|
| 2054 |
ac_cv_ssp_flags='-fstack-protector-all -D_FORTIFY_SOURCE=2' |
| 2055 |
oldCFLAGS="$CFLAGS" |
| 2056 |
# remove existing ssp flags, if present |
| 2057 |
CFLAGS=`echo "$CFLAGS" | sed 's/-D_FORTIFY_SOURCE//g'` |
| 2058 |
CFLAGS=`echo "$CFLAGS" | sed 's/-D_FORTIFY_SOURCE=.//g'` |
| 2059 |
CFLAGS=`echo "$CFLAGS" | sed 's/-fstack-prot[a-z\-]*//g'` |
| 2060 |
# try these |
| 2061 |
CFLAGS="$CFLAGS $ac_cv_ssp_flags" |
| 2062 |
cat > conftest.$ac_ext <<EOF |
| 2063 |
#line 2064 "configure" |
| 2064 |
#include "confdefs.h" |
| 2065 |
|
| 2066 |
#include <stdio.h> |
| 2067 |
#ifdef HAVE_STDLIB_H |
| 2068 |
# include <stdlib.h> |
| 2069 |
#endif |
| 2070 |
char testvar[64]; |
| 2071 |
|
| 2072 |
int main(void) { |
| 2073 |
|
| 2074 |
strncpy(testvar, "hello world", sizeof(testvar) - 1); |
| 2075 |
|
| 2076 |
; return 0; } |
| 2077 |
EOF |
| 2078 |
if { (eval echo configure:2079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 2079 |
: |
| 2080 |
else |
| 2081 |
echo "configure: failed program was:" >&5 |
| 2082 |
cat conftest.$ac_ext >&5 |
| 2083 |
rm -rf conftest* |
| 2084 |
CFLAGS="$oldCFLAGS" ; ac_cv_ssp_flags="no" |
| 2085 |
fi |
| 2086 |
rm -rf conftest* |
| 2087 |
if test "$SYS" = macosx ; then |
| 2088 |
if test "${use_macosx_universal}" != no ; then |
| 2089 |
CFLAGS="$oldCFLAGS" ; ac_cv_ssp_flags="not compatible with Mac OS X universal" |
| 2090 |
fi |
| 2091 |
fi |
| 2092 |
unset oldCFLAGS |
| 2093 |
echo $ac_n "checking if stack protection CFLAGS can be used""... $ac_c" 1>&6 |
| 2094 |
echo "configure:2095: checking if stack protection CFLAGS can be used" >&5 |
| 2095 |
echo "$ac_t""$ac_cv_ssp_flags" 1>&6 |
| 2096 |
|
| 2097 |
fi |
| 2098 |
|
| 2099 |
echo $ac_n "checking if compiled programs use a shared library version of libgcc""... $ac_c" 1>&6 |
| 2100 |
echo "configure:2101: checking if compiled programs use a shared library version of libgcc" >&5 |
| 2101 |
if eval "test \"`echo '$''{'wi_cv_shared_libgcc'+set}'`\" = set"; then |
| 2102 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 2103 |
else |
| 2104 |
|
| 2105 |
if test "$wi_cv_prog_ldd" = no ; then |
| 2106 |
wi_cv_shared_libgcc="unknown (ldd is not available to check)" |
| 2107 |
else |
| 2108 |
cat > conftest.c <<EOF |
| 2109 |
#include <stdio.h> |
| 2110 |
#include <stdlib.h> |
| 2111 |
int main(int argc, char **argv) |
| 2112 |
{ |
| 2113 |
(void) printf("%s\n", ((argc > 66) ? argv[0] : "Hello World")); |
| 2114 |
exit(0); |
| 2115 |
} |
| 2116 |
EOF |
| 2117 |
${CC-cc} $CFLAGS $CPPFLAGS conftest.c -o conftest 1>&5 |
| 2118 |
wi_cv_shared_libgcc=`ldd ./conftest 2>&1 | sed -n -e '/libgcc/{s/.*/yes/g;p;q;}' -e '${s/.*/no/g;p;q;}'` |
| 2119 |
/bin/rm -rf conftest* |
| 2120 |
fi |
| 2121 |
|
| 2122 |
fi |
| 2123 |
|
| 2124 |
echo "$ac_t""$wi_cv_shared_libgcc" 1>&6 |
| 2125 |
if test "$wi_cv_shared_libgcc" != no ; then |
| 2126 |
|
| 2127 |
if test "x$ac_cv_prog_gcc" = "xyes" ; then |
| 2128 |
case "$CFLAGS" in |
| 2129 |
*-static-libgcc*) |
| 2130 |
;; |
| 2131 |
*) |
| 2132 |
oldCFLAGS="$CFLAGS" |
| 2133 |
CFLAGS="$CFLAGS -static-libgcc" |
| 2134 |
# |
| 2135 |
# Now check if this version of GCC |
| 2136 |
# accepts this flag... |
| 2137 |
# |
| 2138 |
cat > conftest.$ac_ext <<EOF |
| 2139 |
#line 2140 "configure" |
| 2140 |
#include "confdefs.h" |
| 2141 |
|
| 2142 |
#include <stdio.h> |
| 2143 |
#ifdef HAVE_STDLIB_H |
| 2144 |
# include <stdlib.h> |
| 2145 |
#endif |
| 2146 |
char testvar[64]; |
| 2147 |
|
| 2148 |
int main(void) { |
| 2149 |
strncpy(testvar, "hello world", sizeof(testvar) - 1); |
| 2150 |
; return 0; } |
| 2151 |
EOF |
| 2152 |
if { (eval echo configure:2153: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 2153 |
: |
| 2154 |
else |
| 2155 |
echo "configure: failed program was:" >&5 |
| 2156 |
cat conftest.$ac_ext >&5 |
| 2157 |
rm -rf conftest* |
| 2158 |
CFLAGS="$oldCFLAGS" |
| 2159 |
fi |
| 2160 |
rm -rf conftest* |
| 2161 |
unset oldCFLAGS |
| 2162 |
;; |
| 2163 |
esac |
| 2164 |
fi |
| 2165 |
|
| 2166 |
fi |
| 2167 |
|
| 2168 |
|
| 2169 |
if test "x$cross_compiling" = "xyes" ; then |
| 2170 |
|
| 2171 |
if test "x$ac_cv_prog_gcc" = "xyes" ; then |
| 2172 |
case "$CFLAGS" in |
| 2173 |
*-static-libgcc*) |
| 2174 |
;; |
| 2175 |
*) |
| 2176 |
oldCFLAGS="$CFLAGS" |
| 2177 |
CFLAGS="$CFLAGS -static-libgcc" |
| 2178 |
# |
| 2179 |
# Now check if this version of GCC |
| 2180 |
# accepts this flag... |
| 2181 |
# |
| 2182 |
cat > conftest.$ac_ext <<EOF |
| 2183 |
#line 2184 "configure" |
| 2184 |
#include "confdefs.h" |
| 2185 |
|
| 2186 |
#include <stdio.h> |
| 2187 |
#ifdef HAVE_STDLIB_H |
| 2188 |
# include <stdlib.h> |
| 2189 |
#endif |
| 2190 |
char testvar[64]; |
| 2191 |
|
| 2192 |
int main(void) { |
| 2193 |
strncpy(testvar, "hello world", sizeof(testvar) - 1); |
| 2194 |
; return 0; } |
| 2195 |
EOF |
| 2196 |
if { (eval echo configure:2197: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 2197 |
: |
| 2198 |
else |
| 2199 |
echo "configure: failed program was:" >&5 |
| 2200 |
cat conftest.$ac_ext >&5 |
| 2201 |
rm -rf conftest* |
| 2202 |
CFLAGS="$oldCFLAGS" |
| 2203 |
fi |
| 2204 |
rm -rf conftest* |
| 2205 |
unset oldCFLAGS |
| 2206 |
;; |
| 2207 |
esac |
| 2208 |
fi |
| 2209 |
|
| 2210 |
fi |
| 2211 |
|
| 2212 |
add_O0="no" |
| 2213 |
if [ "$NOOPTCFLAGS" = "" ] ; then |
| 2214 |
NOOPTCFLAGS=`echo "$CFLAGS" | sed 's/[-+]O[0-9A-Za-z]*//g;s/-xO[0-9]//g;s/-Wc,-O3//g;s/-IPA//g;s/-xipo=?[0-9]?//g;s/\ \ */ /g;s/^\ *//;s/\ *$//;'` |
| 2215 |
if [ "$GCC" = "yes" ] ; then |
| 2216 |
add_O0="yes" |
| 2217 |
else |
| 2218 |
case "$CC" in |
| 2219 |
ccc|*/ccc) |
| 2220 |
# Compaq CC |
| 2221 |
add_O0="yes" |
| 2222 |
;; |
| 2223 |
esac |
| 2224 |
fi |
| 2225 |
fi |
| 2226 |
if [ "$DEBUGCFLAGS" = "" ] ; then |
| 2227 |
DEBUGCFLAGS="-g $NOOPTCFLAGS" |
| 2228 |
fi |
| 2229 |
if [ "$add_O0" = yes ] ; then |
| 2230 |
NOOPTCFLAGS="-O0 $NOOPTCFLAGS" |
| 2231 |
fi |
| 2232 |
# |
| 2233 |
# Was it ./configure --enable-debug ? |
| 2234 |
# |
| 2235 |
echo $ac_n "checking if this is a debug build""... $ac_c" 1>&6 |
| 2236 |
echo "configure:2237: checking if this is a debug build" >&5 |
| 2237 |
if test "$DEBUGBUILD" = yes ; then |
| 2238 |
echo "$ac_t""yes" 1>&6 |
| 2239 |
CFLAGS="$DEBUGCFLAGS" |
| 2240 |
else |
| 2241 |
echo "$ac_t""no" 1>&6 |
| 2242 |
fi |
| 2243 |
|
| 2244 |
result="no" |
| 2245 |
wi_cv_lfs64="no" |
| 2246 |
if test "os_${os}_gcc_${GCC}" = os_hp-ux_gcc_yes ; then |
| 2247 |
|
| 2248 |
CFLAGS=`echo "$CFLAGS" | sed s/-D__STDC_EXT__//g` |
| 2249 |
echo $ac_n "checking if -D__STDC_EXT__ is needed with GCC on HP-UX""... $ac_c" 1>&6 |
| 2250 |
echo "configure:2251: checking if -D__STDC_EXT__ is needed with GCC on HP-UX" >&5 |
| 2251 |
if test "$cross_compiling" = yes; then |
| 2252 |
|
| 2253 |
# action if cross-compiling, guess |
| 2254 |
CFLAGS="-D__STDC_EXT__ $CFLAGS" |
| 2255 |
echo "$ac_t""(guessing) yes" 1>&6 |
| 2256 |
|
| 2257 |
else |
| 2258 |
cat > conftest.$ac_ext <<EOF |
| 2259 |
#line 2260 "configure" |
| 2260 |
#include "confdefs.h" |
| 2261 |
|
| 2262 |
#include <stdio.h> |
| 2263 |
#ifdef HAVE_STDLIB_H |
| 2264 |
# include <stdlib.h> |
| 2265 |
#endif |
| 2266 |
|
| 2267 |
int main(void) |
| 2268 |
{ |
| 2269 |
#ifdef __STDC_EXT__ |
| 2270 |
if (__STDC_EXT__ == 0) |
| 2271 |
exit(1); /* have __STDC_EXT__=0 */ |
| 2272 |
exit(0); /* have __STDC_EXT__=1 */ |
| 2273 |
#else |
| 2274 |
exit(1); /* do not have __STDC_EXT__ */ |
| 2275 |
#endif |
| 2276 |
} |
| 2277 |
EOF |
| 2278 |
if { (eval echo configure:2279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2279 |
then |
| 2280 |
|
| 2281 |
# action if true |
| 2282 |
# |
| 2283 |
# Already have it defined. |
| 2284 |
# |
| 2285 |
echo "$ac_t""no" 1>&6 |
| 2286 |
|
| 2287 |
else |
| 2288 |
echo "configure: failed program was:" >&5 |
| 2289 |
cat conftest.$ac_ext >&5 |
| 2290 |
rm -fr conftest* |
| 2291 |
|
| 2292 |
# action if false |
| 2293 |
# |
| 2294 |
# Not defined -- we need to define it then. |
| 2295 |
# This is required for the extended |
| 2296 |
# namespace symbols for Large Files. |
| 2297 |
# |
| 2298 |
CFLAGS="-D__STDC_EXT__ $CFLAGS" |
| 2299 |
echo "$ac_t""yes" 1>&6 |
| 2300 |
|
| 2301 |
fi |
| 2302 |
rm -fr conftest* |
| 2303 |
fi |
| 2304 |
|
| 2305 |
|
| 2306 |
fi |
| 2307 |
for ac_hdr in unistd.h |
| 2308 |
do |
| 2309 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 2310 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 2311 |
echo "configure:2312: checking for $ac_hdr" >&5 |
| 2312 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 2313 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 2314 |
else |
| 2315 |
cat > conftest.$ac_ext <<EOF |
| 2316 |
#line 2317 "configure" |
| 2317 |
#include "confdefs.h" |
| 2318 |
#include <$ac_hdr> |
| 2319 |
EOF |
| 2320 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 2321 |
{ (eval echo configure:2322: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 2322 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 2323 |
if test -z "$ac_err"; then |
| 2324 |
rm -rf conftest* |
| 2325 |
eval "ac_cv_header_$ac_safe=yes" |
| 2326 |
else |
| 2327 |
echo "$ac_err" >&5 |
| 2328 |
echo "configure: failed program was:" >&5 |
| 2329 |
cat conftest.$ac_ext >&5 |
| 2330 |
rm -rf conftest* |
| 2331 |
eval "ac_cv_header_$ac_safe=no" |
| 2332 |
fi |
| 2333 |
rm -rf conftest* |
| 2334 |
fi |
| 2335 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 2336 |
echo "$ac_t""yes" 1>&6 |
| 2337 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 2338 |
cat >> confdefs.h <<EOF |
| 2339 |
#define $ac_tr_hdr 1 |
| 2340 |
EOF |
| 2341 |
|
| 2342 |
else |
| 2343 |
echo "$ac_t""no" 1>&6 |
| 2344 |
fi |
| 2345 |
done |
| 2346 |
|
| 2347 |
if test "x$ac_cv_sizeof_stat_st_size" = x ; then |
| 2348 |
|
| 2349 |
echo $ac_n "checking size of st_size field in struct stat""... $ac_c" 1>&6 |
| 2350 |
echo "configure:2351: checking size of st_size field in struct stat" >&5 |
| 2351 |
|
| 2352 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 2353 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_ST_SIZE." 1>&2; exit 1; } |
| 2354 |
fi |
| 2355 |
|
| 2356 |
if test "$cross_compiling" = yes; then |
| 2357 |
|
| 2358 |
# action if cross compiling |
| 2359 |
x="unknown" |
| 2360 |
ac_cv_sizeof_stat_st_size="4" |
| 2361 |
rm -f conftest.out |
| 2362 |
|
| 2363 |
else |
| 2364 |
cat > conftest.$ac_ext <<EOF |
| 2365 |
#line 2366 "configure" |
| 2366 |
#include "confdefs.h" |
| 2367 |
|
| 2368 |
/* program */ |
| 2369 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 2370 |
# define _ALL_SOURCE 1 |
| 2371 |
#endif |
| 2372 |
#ifdef HAVE_UNISTD_H |
| 2373 |
# include <unistd.h> |
| 2374 |
#endif |
| 2375 |
#include <sys/types.h> |
| 2376 |
#include <sys/stat.h> |
| 2377 |
#include <stdio.h> |
| 2378 |
#ifdef HAVE_STDLIB_H |
| 2379 |
# include <stdlib.h> |
| 2380 |
#endif |
| 2381 |
|
| 2382 |
int main(void) |
| 2383 |
{ |
| 2384 |
struct stat x; |
| 2385 |
FILE *fp; |
| 2386 |
|
| 2387 |
fp = fopen("conftest.out", "w"); |
| 2388 |
if (fp != NULL) { |
| 2389 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x.st_size)); |
| 2390 |
fclose(fp); |
| 2391 |
exit(0); /* OK */ |
| 2392 |
} |
| 2393 |
exit(1); /* Not OK */ |
| 2394 |
} |
| 2395 |
|
| 2396 |
EOF |
| 2397 |
if { (eval echo configure:2398: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2398 |
then |
| 2399 |
|
| 2400 |
# action if true |
| 2401 |
x=`cat conftest.out` |
| 2402 |
case "$x" in |
| 2403 |
[0-9]*) |
| 2404 |
ac_cv_sizeof_stat_st_size="$x" |
| 2405 |
;; |
| 2406 |
*) |
| 2407 |
x="failed" |
| 2408 |
ac_cv_sizeof_stat_st_size="4" |
| 2409 |
;; |
| 2410 |
esac |
| 2411 |
rm -f conftest.out |
| 2412 |
|
| 2413 |
else |
| 2414 |
echo "configure: failed program was:" >&5 |
| 2415 |
cat conftest.$ac_ext >&5 |
| 2416 |
rm -fr conftest* |
| 2417 |
|
| 2418 |
# action if false |
| 2419 |
x="failed" |
| 2420 |
ac_cv_sizeof_stat_st_size="4" |
| 2421 |
rm -f conftest.out |
| 2422 |
|
| 2423 |
fi |
| 2424 |
rm -fr conftest* |
| 2425 |
fi |
| 2426 |
|
| 2427 |
echo "$ac_t""$x" 1>&6 |
| 2428 |
|
| 2429 |
fi |
| 2430 |
if test "x$ac_cv_sizeof_off_t" = x ; then |
| 2431 |
|
| 2432 |
echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
| 2433 |
echo "configure:2434: checking size of off_t" >&5 |
| 2434 |
|
| 2435 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 2436 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_OFF_T." 1>&2; exit 1; } |
| 2437 |
fi |
| 2438 |
|
| 2439 |
if test "$cross_compiling" = yes; then |
| 2440 |
|
| 2441 |
# action if cross compiling |
| 2442 |
x="unknown" |
| 2443 |
ac_cv_sizeof_off_t="4" |
| 2444 |
rm -f conftest.out |
| 2445 |
|
| 2446 |
else |
| 2447 |
cat > conftest.$ac_ext <<EOF |
| 2448 |
#line 2449 "configure" |
| 2449 |
#include "confdefs.h" |
| 2450 |
|
| 2451 |
/* program */ |
| 2452 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 2453 |
# define _ALL_SOURCE 1 |
| 2454 |
#endif |
| 2455 |
#ifdef HAVE_UNISTD_H |
| 2456 |
# include <unistd.h> |
| 2457 |
#endif |
| 2458 |
#include <sys/types.h> |
| 2459 |
#include <sys/stat.h> |
| 2460 |
#include <stdio.h> |
| 2461 |
#ifdef HAVE_STDLIB_H |
| 2462 |
# include <stdlib.h> |
| 2463 |
#endif |
| 2464 |
|
| 2465 |
int main(void) |
| 2466 |
{ |
| 2467 |
off_t x = 0; |
| 2468 |
FILE *fp; |
| 2469 |
|
| 2470 |
fp = fopen("conftest.out", "w"); |
| 2471 |
if (fp != NULL) { |
| 2472 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 2473 |
fclose(fp); |
| 2474 |
exit(0); /* OK */ |
| 2475 |
} |
| 2476 |
exit(1); /* Not OK */ |
| 2477 |
} |
| 2478 |
|
| 2479 |
EOF |
| 2480 |
if { (eval echo configure:2481: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2481 |
then |
| 2482 |
|
| 2483 |
# action if true |
| 2484 |
x=`cat conftest.out` |
| 2485 |
case "$x" in |
| 2486 |
[0-9]*) |
| 2487 |
ac_cv_sizeof_off_t="$x" |
| 2488 |
;; |
| 2489 |
*) |
| 2490 |
x="failed" |
| 2491 |
ac_cv_sizeof_off_t="4" |
| 2492 |
;; |
| 2493 |
esac |
| 2494 |
rm -f conftest.out |
| 2495 |
|
| 2496 |
else |
| 2497 |
echo "configure: failed program was:" >&5 |
| 2498 |
cat conftest.$ac_ext >&5 |
| 2499 |
rm -fr conftest* |
| 2500 |
|
| 2501 |
# action if false |
| 2502 |
x="failed" |
| 2503 |
ac_cv_sizeof_off_t="4" |
| 2504 |
rm -f conftest.out |
| 2505 |
|
| 2506 |
fi |
| 2507 |
rm -fr conftest* |
| 2508 |
fi |
| 2509 |
|
| 2510 |
echo "$ac_t""$x" 1>&6 |
| 2511 |
|
| 2512 |
fi |
| 2513 |
if test "$ac_cv_sizeof_stat_st_size" -le 4 || test "$ac_cv_sizeof_off_t" -le 4 ; then |
| 2514 |
unset ac_cv_sizeof_stat_st_size ac_cv_sizeof_off_t |
| 2515 |
case "$CFLAGS" in |
| 2516 |
*-D_LARGEFILE64_SOURCE*) |
| 2517 |
result="already included -D_LARGEFILE64_SOURCE" |
| 2518 |
;; |
| 2519 |
*) |
| 2520 |
CFLAGS="-D_LARGEFILE64_SOURCE $CFLAGS" |
| 2521 |
DEBUGCFLAGS="-D_LARGEFILE64_SOURCE $DEBUGCFLAGS" |
| 2522 |
NOOPTCFLAGS="-D_LARGEFILE64_SOURCE $NOOPTCFLAGS" |
| 2523 |
result="-D_LARGEFILE64_SOURCE" |
| 2524 |
;; |
| 2525 |
esac |
| 2526 |
wi_cv_lfs64="yes" |
| 2527 |
|
| 2528 |
echo $ac_n "checking size of st_size field in struct stat64""... $ac_c" 1>&6 |
| 2529 |
echo "configure:2530: checking size of st_size field in struct stat64" >&5 |
| 2530 |
|
| 2531 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 2532 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_STAT64_ST_SIZE." 1>&2; exit 1; } |
| 2533 |
fi |
| 2534 |
|
| 2535 |
if test "$cross_compiling" = yes; then |
| 2536 |
|
| 2537 |
# action if cross compiling |
| 2538 |
x="unknown" |
| 2539 |
ac_cv_sizeof_stat64_st_size="8" |
| 2540 |
rm -f conftest.out |
| 2541 |
|
| 2542 |
else |
| 2543 |
cat > conftest.$ac_ext <<EOF |
| 2544 |
#line 2545 "configure" |
| 2545 |
#include "confdefs.h" |
| 2546 |
|
| 2547 |
/* program */ |
| 2548 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 2549 |
# define _ALL_SOURCE 1 |
| 2550 |
#endif |
| 2551 |
#ifdef HAVE_UNISTD_H |
| 2552 |
# include <unistd.h> |
| 2553 |
#endif |
| 2554 |
#include <sys/types.h> |
| 2555 |
#include <sys/stat.h> |
| 2556 |
#include <stdio.h> |
| 2557 |
#ifdef HAVE_STDLIB_H |
| 2558 |
# include <stdlib.h> |
| 2559 |
#endif |
| 2560 |
|
| 2561 |
int main(void) |
| 2562 |
{ |
| 2563 |
struct stat64 x; |
| 2564 |
FILE *fp; |
| 2565 |
|
| 2566 |
fp = fopen("conftest.out", "w"); |
| 2567 |
if (fp != NULL) { |
| 2568 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x.st_size)); |
| 2569 |
fclose(fp); |
| 2570 |
exit(0); /* OK */ |
| 2571 |
} |
| 2572 |
exit(1); /* Not OK */ |
| 2573 |
} |
| 2574 |
|
| 2575 |
EOF |
| 2576 |
if { (eval echo configure:2577: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2577 |
then |
| 2578 |
|
| 2579 |
# action if true |
| 2580 |
x=`cat conftest.out` |
| 2581 |
case "$x" in |
| 2582 |
[0-9]*) |
| 2583 |
cat >> confdefs.h <<EOF |
| 2584 |
#define SIZEOF_STAT64_ST_SIZE $x |
| 2585 |
EOF |
| 2586 |
|
| 2587 |
ac_cv_sizeof_stat64_st_size="$x" |
| 2588 |
;; |
| 2589 |
*) |
| 2590 |
x="failed" |
| 2591 |
ac_cv_sizeof_stat64_st_size="4" |
| 2592 |
;; |
| 2593 |
esac |
| 2594 |
rm -f conftest.out |
| 2595 |
|
| 2596 |
else |
| 2597 |
echo "configure: failed program was:" >&5 |
| 2598 |
cat conftest.$ac_ext >&5 |
| 2599 |
rm -fr conftest* |
| 2600 |
|
| 2601 |
# action if false |
| 2602 |
x="failed" |
| 2603 |
ac_cv_sizeof_stat64_st_size="4" |
| 2604 |
rm -f conftest.out |
| 2605 |
|
| 2606 |
fi |
| 2607 |
rm -fr conftest* |
| 2608 |
fi |
| 2609 |
|
| 2610 |
echo "$ac_t""$x" 1>&6 |
| 2611 |
|
| 2612 |
|
| 2613 |
echo $ac_n "checking size of off64_t""... $ac_c" 1>&6 |
| 2614 |
echo "configure:2615: checking size of off64_t" >&5 |
| 2615 |
|
| 2616 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 2617 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_OFF64_T." 1>&2; exit 1; } |
| 2618 |
fi |
| 2619 |
|
| 2620 |
if test "$cross_compiling" = yes; then |
| 2621 |
|
| 2622 |
# action if cross compiling |
| 2623 |
x="unknown" |
| 2624 |
ac_cv_sizeof_off64_t="8" |
| 2625 |
rm -f conftest.out |
| 2626 |
|
| 2627 |
else |
| 2628 |
cat > conftest.$ac_ext <<EOF |
| 2629 |
#line 2630 "configure" |
| 2630 |
#include "confdefs.h" |
| 2631 |
|
| 2632 |
/* program */ |
| 2633 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 2634 |
# define _ALL_SOURCE 1 |
| 2635 |
#endif |
| 2636 |
#ifdef HAVE_UNISTD_H |
| 2637 |
# include <unistd.h> |
| 2638 |
#endif |
| 2639 |
#include <sys/types.h> |
| 2640 |
#include <sys/stat.h> |
| 2641 |
#include <stdio.h> |
| 2642 |
#ifdef HAVE_STDLIB_H |
| 2643 |
# include <stdlib.h> |
| 2644 |
#endif |
| 2645 |
|
| 2646 |
int main(void) |
| 2647 |
{ |
| 2648 |
off64_t x = 0; |
| 2649 |
FILE *fp; |
| 2650 |
|
| 2651 |
fp = fopen("conftest.out", "w"); |
| 2652 |
if (fp != NULL) { |
| 2653 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 2654 |
fclose(fp); |
| 2655 |
exit(0); /* OK */ |
| 2656 |
} |
| 2657 |
exit(1); /* Not OK */ |
| 2658 |
} |
| 2659 |
|
| 2660 |
EOF |
| 2661 |
if { (eval echo configure:2662: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2662 |
then |
| 2663 |
|
| 2664 |
# action if true |
| 2665 |
x=`cat conftest.out` |
| 2666 |
case "$x" in |
| 2667 |
[0-9]*) |
| 2668 |
cat >> confdefs.h <<EOF |
| 2669 |
#define SIZEOF_OFF64_T $x |
| 2670 |
EOF |
| 2671 |
|
| 2672 |
ac_cv_sizeof_off64_t="$x" |
| 2673 |
;; |
| 2674 |
*) |
| 2675 |
x="failed" |
| 2676 |
ac_cv_sizeof_off64_t="4" |
| 2677 |
;; |
| 2678 |
esac |
| 2679 |
rm -f conftest.out |
| 2680 |
|
| 2681 |
else |
| 2682 |
echo "configure: failed program was:" >&5 |
| 2683 |
cat conftest.$ac_ext >&5 |
| 2684 |
rm -fr conftest* |
| 2685 |
|
| 2686 |
# action if false |
| 2687 |
x="failed" |
| 2688 |
ac_cv_sizeof_off64_t="4" |
| 2689 |
rm -f conftest.out |
| 2690 |
|
| 2691 |
fi |
| 2692 |
rm -fr conftest* |
| 2693 |
fi |
| 2694 |
|
| 2695 |
echo "$ac_t""$x" 1>&6 |
| 2696 |
|
| 2697 |
|
| 2698 |
echo $ac_n "checking size of st_size field in struct stat""... $ac_c" 1>&6 |
| 2699 |
echo "configure:2700: checking size of st_size field in struct stat" >&5 |
| 2700 |
|
| 2701 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 2702 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_ST_SIZE." 1>&2; exit 1; } |
| 2703 |
fi |
| 2704 |
|
| 2705 |
if test "$cross_compiling" = yes; then |
| 2706 |
|
| 2707 |
# action if cross compiling |
| 2708 |
x="unknown" |
| 2709 |
ac_cv_sizeof_stat_st_size="4" |
| 2710 |
rm -f conftest.out |
| 2711 |
|
| 2712 |
else |
| 2713 |
cat > conftest.$ac_ext <<EOF |
| 2714 |
#line 2715 "configure" |
| 2715 |
#include "confdefs.h" |
| 2716 |
|
| 2717 |
/* program */ |
| 2718 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 2719 |
# define _ALL_SOURCE 1 |
| 2720 |
#endif |
| 2721 |
#ifdef HAVE_UNISTD_H |
| 2722 |
# include <unistd.h> |
| 2723 |
#endif |
| 2724 |
#include <sys/types.h> |
| 2725 |
#include <sys/stat.h> |
| 2726 |
#include <stdio.h> |
| 2727 |
#ifdef HAVE_STDLIB_H |
| 2728 |
# include <stdlib.h> |
| 2729 |
#endif |
| 2730 |
|
| 2731 |
int main(void) |
| 2732 |
{ |
| 2733 |
struct stat x; |
| 2734 |
FILE *fp; |
| 2735 |
|
| 2736 |
fp = fopen("conftest.out", "w"); |
| 2737 |
if (fp != NULL) { |
| 2738 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x.st_size)); |
| 2739 |
fclose(fp); |
| 2740 |
exit(0); /* OK */ |
| 2741 |
} |
| 2742 |
exit(1); /* Not OK */ |
| 2743 |
} |
| 2744 |
|
| 2745 |
EOF |
| 2746 |
if { (eval echo configure:2747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2747 |
then |
| 2748 |
|
| 2749 |
# action if true |
| 2750 |
x=`cat conftest.out` |
| 2751 |
case "$x" in |
| 2752 |
[0-9]*) |
| 2753 |
ac_cv_sizeof_stat_st_size="$x" |
| 2754 |
;; |
| 2755 |
*) |
| 2756 |
x="failed" |
| 2757 |
ac_cv_sizeof_stat_st_size="4" |
| 2758 |
;; |
| 2759 |
esac |
| 2760 |
rm -f conftest.out |
| 2761 |
|
| 2762 |
else |
| 2763 |
echo "configure: failed program was:" >&5 |
| 2764 |
cat conftest.$ac_ext >&5 |
| 2765 |
rm -fr conftest* |
| 2766 |
|
| 2767 |
# action if false |
| 2768 |
x="failed" |
| 2769 |
ac_cv_sizeof_stat_st_size="4" |
| 2770 |
rm -f conftest.out |
| 2771 |
|
| 2772 |
fi |
| 2773 |
rm -fr conftest* |
| 2774 |
fi |
| 2775 |
|
| 2776 |
echo "$ac_t""$x" 1>&6 |
| 2777 |
|
| 2778 |
|
| 2779 |
echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
| 2780 |
echo "configure:2781: checking size of off_t" >&5 |
| 2781 |
|
| 2782 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 2783 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_OFF_T." 1>&2; exit 1; } |
| 2784 |
fi |
| 2785 |
|
| 2786 |
if test "$cross_compiling" = yes; then |
| 2787 |
|
| 2788 |
# action if cross compiling |
| 2789 |
x="unknown" |
| 2790 |
ac_cv_sizeof_off_t="4" |
| 2791 |
rm -f conftest.out |
| 2792 |
|
| 2793 |
else |
| 2794 |
cat > conftest.$ac_ext <<EOF |
| 2795 |
#line 2796 "configure" |
| 2796 |
#include "confdefs.h" |
| 2797 |
|
| 2798 |
/* program */ |
| 2799 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 2800 |
# define _ALL_SOURCE 1 |
| 2801 |
#endif |
| 2802 |
#ifdef HAVE_UNISTD_H |
| 2803 |
# include <unistd.h> |
| 2804 |
#endif |
| 2805 |
#include <sys/types.h> |
| 2806 |
#include <sys/stat.h> |
| 2807 |
#include <stdio.h> |
| 2808 |
#ifdef HAVE_STDLIB_H |
| 2809 |
# include <stdlib.h> |
| 2810 |
#endif |
| 2811 |
|
| 2812 |
int main(void) |
| 2813 |
{ |
| 2814 |
off_t x = 0; |
| 2815 |
FILE *fp; |
| 2816 |
|
| 2817 |
fp = fopen("conftest.out", "w"); |
| 2818 |
if (fp != NULL) { |
| 2819 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 2820 |
fclose(fp); |
| 2821 |
exit(0); /* OK */ |
| 2822 |
} |
| 2823 |
exit(1); /* Not OK */ |
| 2824 |
} |
| 2825 |
|
| 2826 |
EOF |
| 2827 |
if { (eval echo configure:2828: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 2828 |
then |
| 2829 |
|
| 2830 |
# action if true |
| 2831 |
x=`cat conftest.out` |
| 2832 |
case "$x" in |
| 2833 |
[0-9]*) |
| 2834 |
ac_cv_sizeof_off_t="$x" |
| 2835 |
;; |
| 2836 |
*) |
| 2837 |
x="failed" |
| 2838 |
ac_cv_sizeof_off_t="4" |
| 2839 |
;; |
| 2840 |
esac |
| 2841 |
rm -f conftest.out |
| 2842 |
|
| 2843 |
else |
| 2844 |
echo "configure: failed program was:" >&5 |
| 2845 |
cat conftest.$ac_ext >&5 |
| 2846 |
rm -fr conftest* |
| 2847 |
|
| 2848 |
# action if false |
| 2849 |
x="failed" |
| 2850 |
ac_cv_sizeof_off_t="4" |
| 2851 |
rm -f conftest.out |
| 2852 |
|
| 2853 |
fi |
| 2854 |
rm -fr conftest* |
| 2855 |
fi |
| 2856 |
|
| 2857 |
echo "$ac_t""$x" 1>&6 |
| 2858 |
|
| 2859 |
fi |
| 2860 |
|
| 2861 |
if test "x$ac_cv_sizeof_stat_st_size" != x ; then |
| 2862 |
cat >> confdefs.h <<EOF |
| 2863 |
#define SIZEOF_ST_SIZE $ac_cv_sizeof_stat_st_size |
| 2864 |
EOF |
| 2865 |
|
| 2866 |
fi |
| 2867 |
if test "x$ac_cv_sizeof_off_t" != x ; then |
| 2868 |
cat >> confdefs.h <<EOF |
| 2869 |
#define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
| 2870 |
EOF |
| 2871 |
|
| 2872 |
fi |
| 2873 |
|
| 2874 |
echo $ac_n "checking if we should add CFLAGS for LFS64 support""... $ac_c" 1>&6 |
| 2875 |
echo "configure:2876: checking if we should add CFLAGS for LFS64 support" >&5 |
| 2876 |
echo "$ac_t""$result" 1>&6 |
| 2877 |
|
| 2878 |
else |
| 2879 |
|
| 2880 |
|
| 2881 |
|
| 2882 |
|
| 2883 |
|
| 2884 |
if test "$GCC" = yes ; then |
| 2885 |
echo $ac_n "checking the version of GCC""... $ac_c" 1>&6 |
| 2886 |
echo "configure:2887: checking the version of GCC" >&5 |
| 2887 |
if eval "test \"`echo '$''{'wi_cv_gcc_version'+set}'`\" = set"; then |
| 2888 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 2889 |
else |
| 2890 |
|
| 2891 |
wi_cv_gcc_version=`$CC -v 2>&1 | sed -n '/gcc version/{s/^.*gcc version//;s/^[^1-9]*//;s/\ .*//;p;q;}'` |
| 2892 |
|
| 2893 |
fi |
| 2894 |
|
| 2895 |
echo "$ac_t""$wi_cv_gcc_version" 1>&6 |
| 2896 |
else |
| 2897 |
wi_cv_gcc_version="0" |
| 2898 |
fi |
| 2899 |
|
| 2900 |
|
| 2901 |
|
| 2902 |
|
| 2903 |
if test "${SYS}_${GCC}" != solaris_no ; then |
| 2904 |
wi_cv_cc_is_sunwspro_cc="no" |
| 2905 |
wi_cv_sunwspro_cc_version="0" |
| 2906 |
wi_cv_sunwspro_cc_version2="0" |
| 2907 |
else |
| 2908 |
echo $ac_n "checking if the C compiler is Sun WorkShop C""... $ac_c" 1>&6 |
| 2909 |
echo "configure:2910: checking if the C compiler is Sun WorkShop C" >&5 |
| 2910 |
if eval "test \"`echo '$''{'wi_cv_cc_is_sunwspro_cc'+set}'`\" = set"; then |
| 2911 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 2912 |
else |
| 2913 |
|
| 2914 |
# |
| 2915 |
# cc: Sun WorkShop 6 update 2 C 5.3 2001/05/15 |
| 2916 |
# usage: cc [ options] files. Use 'cc -flags' for details |
| 2917 |
# |
| 2918 |
# cc: WorkShop Compilers 4.2 30 Oct 1996 C 4.2 |
| 2919 |
# usage: cc [ options] files. Use 'cc -flags' for details |
| 2920 |
# |
| 2921 |
wi_cv_sunwspro_cc_version=`$CC -V 2>&1 | sed -n '/WorkShop.*C\ [1-9]/{s/^.*C/C/;s/^C\ \([^\ ]*\).*/\1/;p;q;}'` |
| 2922 |
case "$wi_cv_sunwspro_cc_version" in |
| 2923 |
[1-9]*) |
| 2924 |
wi_cv_cc_is_sunwspro_cc="yes" |
| 2925 |
ver1=`echo "$wi_cv_sunwspro_cc_version" | cut -d. -f1` |
| 2926 |
ver2=`echo "$wi_cv_sunwspro_cc_version" | cut -d. -f2` |
| 2927 |
ver3=0 |
| 2928 |
wi_cv_sunwspro_cc_version2=`expr "$ver1" '*' 100 + "$ver2" "*" 10 + "$ver3"` |
| 2929 |
unset ver1 ver2 ver3 |
| 2930 |
;; |
| 2931 |
*) |
| 2932 |
wi_cv_cc_is_sunwspro_cc="no" |
| 2933 |
wi_cv_sunwspro_cc_version="0" |
| 2934 |
wi_cv_sunwspro_cc_version2="0" |
| 2935 |
;; |
| 2936 |
esac |
| 2937 |
|
| 2938 |
fi |
| 2939 |
|
| 2940 |
echo "$ac_t""$wi_cv_cc_is_sunwspro_cc" 1>&6 |
| 2941 |
if test "$wi_cv_cc_is_sunwspro_cc" = yes ; then |
| 2942 |
echo $ac_n "checking output of "cc -V" to determine version of Sun WorkShop C""... $ac_c" 1>&6 |
| 2943 |
echo "configure:2944: checking output of "cc -V" to determine version of Sun WorkShop C" >&5 |
| 2944 |
echo "$ac_t"""version $wi_cv_sunwspro_cc_version"" 1>&6 |
| 2945 |
fi |
| 2946 |
fi |
| 2947 |
|
| 2948 |
|
| 2949 |
echo $ac_n "checking if we should customize your CFLAGS environment variable""... $ac_c" 1>&6 |
| 2950 |
echo "configure:2951: checking if we should customize your CFLAGS environment variable" >&5 |
| 2951 |
wi_replace_O_with_g="no" |
| 2952 |
case "$wi_orig_CFLAGS" in |
| 2953 |
"") |
| 2954 |
wi_replace_O_with_g="no" |
| 2955 |
;; |
| 2956 |
"-g -O2") |
| 2957 |
wi_replace_O_with_g="no" |
| 2958 |
;; |
| 2959 |
"-g -O") |
| 2960 |
wi_replace_O_with_g="no" |
| 2961 |
;; |
| 2962 |
"-O2 -g") |
| 2963 |
wi_replace_O_with_g="no" |
| 2964 |
;; |
| 2965 |
"-O -g") |
| 2966 |
wi_replace_O_with_g="no" |
| 2967 |
;; |
| 2968 |
-g) |
| 2969 |
wi_replace_O_with_g="yes" |
| 2970 |
;; |
| 2971 |
esac |
| 2972 |
|
| 2973 |
# |
| 2974 |
# See if your CFLAGS environment variable wasn't set or exported, |
| 2975 |
# or if you are using a conservative default. If so, we will |
| 2976 |
# add some additional flags for better performance, warning reporting, |
| 2977 |
# etc. |
| 2978 |
# |
| 2979 |
# Note we are now checking the current value of CFLAGS, which may have |
| 2980 |
# been changed by configure. |
| 2981 |
# |
| 2982 |
wi_os_default_cflags="no" |
| 2983 |
case "$CFLAGS" in |
| 2984 |
"") |
| 2985 |
wi_os_default_cflags="yes" |
| 2986 |
;; |
| 2987 |
"-g -O2") |
| 2988 |
wi_os_default_cflags="yes" |
| 2989 |
;; |
| 2990 |
"-g -O") |
| 2991 |
wi_os_default_cflags="yes" |
| 2992 |
;; |
| 2993 |
"-O2 -g") |
| 2994 |
wi_os_default_cflags="yes" |
| 2995 |
;; |
| 2996 |
"-O -g") |
| 2997 |
wi_os_default_cflags="yes" |
| 2998 |
;; |
| 2999 |
-g) |
| 3000 |
wi_os_default_cflags="yes" |
| 3001 |
;; |
| 3002 |
-O) |
| 3003 |
wi_os_default_cflags="yes" |
| 3004 |
;; |
| 3005 |
-O2) |
| 3006 |
wi_os_default_cflags="yes" |
| 3007 |
;; |
| 3008 |
esac |
| 3009 |
|
| 3010 |
CC_is_clang="no" |
| 3011 |
case "$CC" in |
| 3012 |
*clang*) |
| 3013 |
CC_is_clang="yes" |
| 3014 |
;; |
| 3015 |
*) |
| 3016 |
cc_dash_v=`${CC-gcc} -v 2>&1 | grep clang 2>/dev/null` |
| 3017 |
if test -n "$cc_dash_v" ; then |
| 3018 |
CC_is_clang="yes" |
| 3019 |
fi |
| 3020 |
;; |
| 3021 |
esac |
| 3022 |
|
| 3023 |
if test "$wi_os_default_cflags" = yes ; then |
| 3024 |
if test "$CC_is_clang" = yes ; then |
| 3025 |
wi_os_default_cflags="-Weverything -Wno-unknown-warning-option -Wno-disabled-macro-expansion -Wno-missing-variable-declarations -Wno-date-time" |
| 3026 |
if test "$wi_replace_O_with_g" = yes ; then |
| 3027 |
wi_os_default_cflags="-g $wi_os_default_cflags" |
| 3028 |
else |
| 3029 |
wi_os_default_cflags="-O2 $wi_os_default_cflags" |
| 3030 |
fi |
| 3031 |
elif test "$GCC" = yes ; then |
| 3032 |
# |
| 3033 |
# gcc |
| 3034 |
# |
| 3035 |
wi_gcc_optimizer_flags='' |
| 3036 |
case "$wi_cv_gcc_version" in |
| 3037 |
2.7.*|2.8.*|2.9*) |
| 3038 |
wi_os_default_cflags="-W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Wbad-function-cast -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wmissing-declarations -Winline" |
| 3039 |
;; |
| 3040 |
345.*) |
| 3041 |
wi_os_default_cflags="-W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Wbad-function-cast -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wmissing-declarations -Winline -Wmissing-format-attribute -Wformat-security" |
| 3042 |
wi_gcc_optimizer_flags='-Wdisabled-optimization' |
| 3043 |
;; |
| 3044 |
*) |
| 3045 |
wi_os_default_cflags="-W -Wall" |
| 3046 |
;; |
| 3047 |
esac |
| 3048 |
if test "$wi_replace_O_with_g" = yes ; then |
| 3049 |
wi_os_default_cflags="-g $wi_os_default_cflags" |
| 3050 |
else |
| 3051 |
wi_os_default_cflags="-O2 $wi_os_default_cflags" |
| 3052 |
if test "$wi_gcc_optimizer_flags" != "" ; then |
| 3053 |
wi_os_default_cflags="$wi_os_default_cflags $wi_gcc_optimizer_flags" |
| 3054 |
fi |
| 3055 |
fi |
| 3056 |
case "$OS" in |
| 3057 |
hpux*) |
| 3058 |
wi_os_default_cflags="-D_HPUX_SOURCE $wi_os_default_cflags" |
| 3059 |
;; |
| 3060 |
bsdos*) |
| 3061 |
wi_os_default_cflags=`echo "$wi_os_default_cflags" | sed 's/\ -Wcast-qual//g'` # avoid va_start() problem |
| 3062 |
wi_os_default_cflags=`echo "$wi_os_default_cflags" | sed 's/\ -Wredundant-decls//g'` |
| 3063 |
;; |
| 3064 |
openbsd*|unixware*|openunix*) |
| 3065 |
wi_os_default_cflags=`echo "$wi_os_default_cflags" | sed 's/\ -Wredundant-decls//g'` |
| 3066 |
;; |
| 3067 |
esac |
| 3068 |
else |
| 3069 |
# |
| 3070 |
# regular cc |
| 3071 |
# |
| 3072 |
case "${wi_replace_O_with_g}_${OS}" in |
| 3073 |
no_aix*) |
| 3074 |
wi_os_default_cflags="-O -qinfo=cmp:cnd:dcl:eff:gen:ini:par:pro:rea:use -qlonglong -qro -qroconst -qlanglvl=extended -qsrcmsg -qmaxmem=20480 -qsuppress=1506-469:1506-409" |
| 3075 |
;; |
| 3076 |
yes_aix*) |
| 3077 |
wi_os_default_cflags="-g -qinfo=cmp:cnd:dcl:eff:gen:ini:par:pro:rea:use -qlonglong -qro -qroconst -qlanglvl=extended -qsrcmsg -qmaxmem=20480 -qsuppress=1506-469:1506-409" |
| 3078 |
;; |
| 3079 |
no_irix2345*|no_irix6.01234*) |
| 3080 |
wi_os_default_cflags="-O2 -xansi -fullwarn -use_readonly_const -G0 -rdata_shared" |
| 3081 |
;; |
| 3082 |
yes_irix2345*|yes_irix6.01234*) |
| 3083 |
wi_os_default_cflags="-g -xansi -fullwarn -use_readonly_const -G0 -rdata_shared" |
| 3084 |
;; |
| 3085 |
no_irix*) |
| 3086 |
wi_os_default_cflags="-O2 -IPA -xansi -fullwarn -use_readonly_const -G0 -rdata_shared -woff 1174" |
| 3087 |
;; |
| 3088 |
yes_irix*) |
| 3089 |
wi_os_default_cflags="-g -xansi -fullwarn -use_readonly_const -G0 -rdata_shared -woff 1174" |
| 3090 |
;; |
| 3091 |
no_digitalunix*) |
| 3092 |
wi_os_default_cflags="-O4 -std1 -portable -readonly_strings" |
| 3093 |
;; |
| 3094 |
yes_digitalunix*) |
| 3095 |
wi_os_default_cflags="-g -std1 -portable -readonly_strings" |
| 3096 |
;; |
| 3097 |
no_hpux*) |
| 3098 |
wi_os_default_cflags="-Ae +O2 +Ovolatile +Olibcalls +ESlit +w1 +DAportable" |
| 3099 |
;; |
| 3100 |
yes_hpux*) |
| 3101 |
wi_os_default_cflags="-Ae -g +w1 +DAportable" |
| 3102 |
;; |
| 3103 |
no_solaris*86|no_solaris*intel) |
| 3104 |
# Not really any significant differences |
| 3105 |
# from the sparc flags, but reserved for |
| 3106 |
# future use. |
| 3107 |
# |
| 3108 |
if test "$wi_cv_sunwspro_cc_version2" -ge 530 ; then |
| 3109 |
wi_os_default_cflags="-xipo -xO4 -xc99 -xbuiltin -xstrconst -dalign -Qn -errtags=yes -erroff=E_END_OF_LOOP_CODE_NOT_REACHED -mc" |
| 3110 |
else |
| 3111 |
wi_os_default_cflags="-xO4 -xstrconst -dalign -Qn" |
| 3112 |
fi |
| 3113 |
;; |
| 3114 |
yes_solaris*86|yes_solaris*intel) |
| 3115 |
if test "$wi_cv_sunwspro_cc_version2" -ge 530 ; then |
| 3116 |
wi_os_default_cflags="-g -xc99 -xstrconst -dalign -Qn -errtags=yes -erroff=E_END_OF_LOOP_CODE_NOT_REACHED" |
| 3117 |
else |
| 3118 |
wi_os_default_cflags="-g -xstrconst -dalign -Qn" |
| 3119 |
fi |
| 3120 |
;; |
| 3121 |
no_solaris*) |
| 3122 |
if test "$wi_cv_sunwspro_cc_version2" -ge 530 ; then |
| 3123 |
wi_os_default_cflags="-xipo -xO5 -xc99 -xbuiltin -xstrconst -dalign -Qn -errtags=yes -erroff=E_END_OF_LOOP_CODE_NOT_REACHED -mc" |
| 3124 |
else |
| 3125 |
wi_os_default_cflags="-xO4 -xstrconst -dalign -Qn" |
| 3126 |
fi |
| 3127 |
;; |
| 3128 |
yes_solaris*) |
| 3129 |
if test "$wi_cv_sunwspro_cc_version2" -ge 530 ; then |
| 3130 |
wi_os_default_cflags="-g -xc99 -xstrconst -dalign -Qn -errtags=yes -erroff=E_END_OF_LOOP_CODE_NOT_REACHED" |
| 3131 |
else |
| 3132 |
wi_os_default_cflags="-g -xstrconst -dalign -Qn" |
| 3133 |
fi |
| 3134 |
;; |
| 3135 |
no_tru64*) |
| 3136 |
wi_os_default_cflags="-O4 -tune host -std1 -readonly_strings -portable -warnprotos -msg_enable level6 -msg_disable longlongtype,hexoctunsign,unusedincl,unnecincl,nestincl,unusedtop,unknownmacro,ignorecallval,strctpadding,truncintasn,truncintcast,trunclongcast,ansialiascast,conststocls,unrefsdecl,subscrbounds2,intconcastsgn,longlongsufx,unreachcode,valuepres,embedcomment" |
| 3137 |
;; |
| 3138 |
yes_tru64*) |
| 3139 |
wi_os_default_cflags="-g -std1 -readonly_strings -portable -warnprotos -msg_enable level6 -msg_disable longlongtype,hexoctunsign,unusedincl,unnecincl,nestincl,unusedtop,unknownmacro,ignorecallval,strctpadding,truncintasn,truncintcast,trunclongcast,ansialiascast,conststocls,unrefsdecl,subscrbounds2,intconcastsgn,longlongsufx,unreachcode,valuepres,embedcomment" |
| 3140 |
;; |
| 3141 |
no_unixware*|no_openunix*) |
| 3142 |
wi_os_default_cflags='-O -K inline -K host -Q n' |
| 3143 |
;; |
| 3144 |
yes_unixware*|yes_openunix*) |
| 3145 |
wi_os_default_cflags='-g -K host -Q n' |
| 3146 |
;; |
| 3147 |
*) |
| 3148 |
wi_os_default_cflags="no" |
| 3149 |
;; |
| 3150 |
esac |
| 3151 |
fi |
| 3152 |
fi |
| 3153 |
if test "$wi_os_default_cflags" != "no" ; then |
| 3154 |
CFLAGS="$wi_os_default_cflags" |
| 3155 |
fi |
| 3156 |
echo "$ac_t""$wi_os_default_cflags" 1>&6 |
| 3157 |
|
| 3158 |
|
| 3159 |
case "$OS" in |
| 3160 |
"solaris"*"-x86_64") |
| 3161 |
if test "$GCC" = "yes" ; then |
| 3162 |
case "$CFLAGS" in |
| 3163 |
*"-m64"*) |
| 3164 |
;; |
| 3165 |
*) |
| 3166 |
CFLAGS="-m64 $CFLAGS" |
| 3167 |
;; |
| 3168 |
esac |
| 3169 |
fi |
| 3170 |
;; |
| 3171 |
esac |
| 3172 |
|
| 3173 |
|
| 3174 |
|
| 3175 |
if test "x$wi_request_no_y2k_warnings" = xyes ; then |
| 3176 |
case "${wi_cv_gcc_version-0}" in |
| 3177 |
0|1.*|2.[012345678].*) |
| 3178 |
;; |
| 3179 |
*) |
| 3180 |
case "$CFLAGS" in |
| 3181 |
*-Wno-format-y2k*) |
| 3182 |
;; |
| 3183 |
*) |
| 3184 |
oldCFLAGS="$CFLAGS" |
| 3185 |
CFLAGS="$CFLAGS -Wno-format-y2k" |
| 3186 |
# |
| 3187 |
# Now check if this version of GCC |
| 3188 |
# accepts this flag... |
| 3189 |
# |
| 3190 |
cat > conftest.$ac_ext <<EOF |
| 3191 |
#line 3192 "configure" |
| 3192 |
#include "confdefs.h" |
| 3193 |
|
| 3194 |
int main(void) { |
| 3195 |
int junk; |
| 3196 |
; return 0; } |
| 3197 |
EOF |
| 3198 |
if { (eval echo configure:3199: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 3199 |
: |
| 3200 |
else |
| 3201 |
echo "configure: failed program was:" >&5 |
| 3202 |
cat conftest.$ac_ext >&5 |
| 3203 |
rm -rf conftest* |
| 3204 |
CFLAGS="$oldCFLAGS" |
| 3205 |
fi |
| 3206 |
rm -rf conftest* |
| 3207 |
unset oldCFLAGS |
| 3208 |
;; |
| 3209 |
esac |
| 3210 |
;; |
| 3211 |
esac |
| 3212 |
fi |
| 3213 |
|
| 3214 |
|
| 3215 |
echo $ac_n "checking for ldd""... $ac_c" 1>&6 |
| 3216 |
echo "configure:3217: checking for ldd" >&5 |
| 3217 |
if eval "test \"`echo '$''{'wi_cv_prog_ldd'+set}'`\" = set"; then |
| 3218 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 3219 |
else |
| 3220 |
|
| 3221 |
wi_cv_prog_ldd="no" |
| 3222 |
cat > conftest.c <<EOF |
| 3223 |
#include <stdio.h> |
| 3224 |
#include <stdlib.h> |
| 3225 |
int main(int argc, char **argv) |
| 3226 |
{ |
| 3227 |
(void) printf("%s\n", ((argc > 66) ? argv[0] : "Hello World")); |
| 3228 |
exit(0); |
| 3229 |
} |
| 3230 |
EOF |
| 3231 |
${CC-cc} $CFLAGS $CPPFLAGS conftest.c -o conftest 1>&5 |
| 3232 |
wi_cv_prog_ldd=`ldd ./conftest 2>&1 | sed -n -e '/lib/{s/.*/yes/g;p;q;}' -e '${s/.*/no/g;p;q;}'` |
| 3233 |
/bin/rm -rf conftest* |
| 3234 |
|
| 3235 |
fi |
| 3236 |
|
| 3237 |
echo "$ac_t""$wi_cv_prog_ldd" 1>&6 |
| 3238 |
|
| 3239 |
if test "$use_ssp" = yes ;then |
| 3240 |
|
| 3241 |
|
| 3242 |
ac_cv_ssp_flags='-fstack-protector-all -D_FORTIFY_SOURCE=2' |
| 3243 |
oldCFLAGS="$CFLAGS" |
| 3244 |
# remove existing ssp flags, if present |
| 3245 |
CFLAGS=`echo "$CFLAGS" | sed 's/-D_FORTIFY_SOURCE//g'` |
| 3246 |
CFLAGS=`echo "$CFLAGS" | sed 's/-D_FORTIFY_SOURCE=.//g'` |
| 3247 |
CFLAGS=`echo "$CFLAGS" | sed 's/-fstack-prot[a-z\-]*//g'` |
| 3248 |
# try these |
| 3249 |
CFLAGS="$CFLAGS $ac_cv_ssp_flags" |
| 3250 |
cat > conftest.$ac_ext <<EOF |
| 3251 |
#line 3252 "configure" |
| 3252 |
#include "confdefs.h" |
| 3253 |
|
| 3254 |
#include <stdio.h> |
| 3255 |
#ifdef HAVE_STDLIB_H |
| 3256 |
# include <stdlib.h> |
| 3257 |
#endif |
| 3258 |
char testvar[64]; |
| 3259 |
|
| 3260 |
int main(void) { |
| 3261 |
|
| 3262 |
strncpy(testvar, "hello world", sizeof(testvar) - 1); |
| 3263 |
|
| 3264 |
; return 0; } |
| 3265 |
EOF |
| 3266 |
if { (eval echo configure:3267: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 3267 |
: |
| 3268 |
else |
| 3269 |
echo "configure: failed program was:" >&5 |
| 3270 |
cat conftest.$ac_ext >&5 |
| 3271 |
rm -rf conftest* |
| 3272 |
CFLAGS="$oldCFLAGS" ; ac_cv_ssp_flags="no" |
| 3273 |
fi |
| 3274 |
rm -rf conftest* |
| 3275 |
if test "$SYS" = macosx ; then |
| 3276 |
if test "${use_macosx_universal}" != no ; then |
| 3277 |
CFLAGS="$oldCFLAGS" ; ac_cv_ssp_flags="not compatible with Mac OS X universal" |
| 3278 |
fi |
| 3279 |
fi |
| 3280 |
unset oldCFLAGS |
| 3281 |
echo $ac_n "checking if stack protection CFLAGS can be used""... $ac_c" 1>&6 |
| 3282 |
echo "configure:3283: checking if stack protection CFLAGS can be used" >&5 |
| 3283 |
echo "$ac_t""$ac_cv_ssp_flags" 1>&6 |
| 3284 |
|
| 3285 |
fi |
| 3286 |
|
| 3287 |
echo $ac_n "checking if compiled programs use a shared library version of libgcc""... $ac_c" 1>&6 |
| 3288 |
echo "configure:3289: checking if compiled programs use a shared library version of libgcc" >&5 |
| 3289 |
if eval "test \"`echo '$''{'wi_cv_shared_libgcc'+set}'`\" = set"; then |
| 3290 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 3291 |
else |
| 3292 |
|
| 3293 |
if test "$wi_cv_prog_ldd" = no ; then |
| 3294 |
wi_cv_shared_libgcc="unknown (ldd is not available to check)" |
| 3295 |
else |
| 3296 |
cat > conftest.c <<EOF |
| 3297 |
#include <stdio.h> |
| 3298 |
#include <stdlib.h> |
| 3299 |
int main(int argc, char **argv) |
| 3300 |
{ |
| 3301 |
(void) printf("%s\n", ((argc > 66) ? argv[0] : "Hello World")); |
| 3302 |
exit(0); |
| 3303 |
} |
| 3304 |
EOF |
| 3305 |
${CC-cc} $CFLAGS $CPPFLAGS conftest.c -o conftest 1>&5 |
| 3306 |
wi_cv_shared_libgcc=`ldd ./conftest 2>&1 | sed -n -e '/libgcc/{s/.*/yes/g;p;q;}' -e '${s/.*/no/g;p;q;}'` |
| 3307 |
/bin/rm -rf conftest* |
| 3308 |
fi |
| 3309 |
|
| 3310 |
fi |
| 3311 |
|
| 3312 |
echo "$ac_t""$wi_cv_shared_libgcc" 1>&6 |
| 3313 |
if test "$wi_cv_shared_libgcc" != no ; then |
| 3314 |
|
| 3315 |
if test "x$ac_cv_prog_gcc" = "xyes" ; then |
| 3316 |
case "$CFLAGS" in |
| 3317 |
*-static-libgcc*) |
| 3318 |
;; |
| 3319 |
*) |
| 3320 |
oldCFLAGS="$CFLAGS" |
| 3321 |
CFLAGS="$CFLAGS -static-libgcc" |
| 3322 |
# |
| 3323 |
# Now check if this version of GCC |
| 3324 |
# accepts this flag... |
| 3325 |
# |
| 3326 |
cat > conftest.$ac_ext <<EOF |
| 3327 |
#line 3328 "configure" |
| 3328 |
#include "confdefs.h" |
| 3329 |
|
| 3330 |
#include <stdio.h> |
| 3331 |
#ifdef HAVE_STDLIB_H |
| 3332 |
# include <stdlib.h> |
| 3333 |
#endif |
| 3334 |
char testvar[64]; |
| 3335 |
|
| 3336 |
int main(void) { |
| 3337 |
strncpy(testvar, "hello world", sizeof(testvar) - 1); |
| 3338 |
; return 0; } |
| 3339 |
EOF |
| 3340 |
if { (eval echo configure:3341: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 3341 |
: |
| 3342 |
else |
| 3343 |
echo "configure: failed program was:" >&5 |
| 3344 |
cat conftest.$ac_ext >&5 |
| 3345 |
rm -rf conftest* |
| 3346 |
CFLAGS="$oldCFLAGS" |
| 3347 |
fi |
| 3348 |
rm -rf conftest* |
| 3349 |
unset oldCFLAGS |
| 3350 |
;; |
| 3351 |
esac |
| 3352 |
fi |
| 3353 |
|
| 3354 |
fi |
| 3355 |
|
| 3356 |
|
| 3357 |
if test "x$cross_compiling" = "xyes" ; then |
| 3358 |
|
| 3359 |
if test "x$ac_cv_prog_gcc" = "xyes" ; then |
| 3360 |
case "$CFLAGS" in |
| 3361 |
*-static-libgcc*) |
| 3362 |
;; |
| 3363 |
*) |
| 3364 |
oldCFLAGS="$CFLAGS" |
| 3365 |
CFLAGS="$CFLAGS -static-libgcc" |
| 3366 |
# |
| 3367 |
# Now check if this version of GCC |
| 3368 |
# accepts this flag... |
| 3369 |
# |
| 3370 |
cat > conftest.$ac_ext <<EOF |
| 3371 |
#line 3372 "configure" |
| 3372 |
#include "confdefs.h" |
| 3373 |
|
| 3374 |
#include <stdio.h> |
| 3375 |
#ifdef HAVE_STDLIB_H |
| 3376 |
# include <stdlib.h> |
| 3377 |
#endif |
| 3378 |
char testvar[64]; |
| 3379 |
|
| 3380 |
int main(void) { |
| 3381 |
strncpy(testvar, "hello world", sizeof(testvar) - 1); |
| 3382 |
; return 0; } |
| 3383 |
EOF |
| 3384 |
if { (eval echo configure:3385: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 3385 |
: |
| 3386 |
else |
| 3387 |
echo "configure: failed program was:" >&5 |
| 3388 |
cat conftest.$ac_ext >&5 |
| 3389 |
rm -rf conftest* |
| 3390 |
CFLAGS="$oldCFLAGS" |
| 3391 |
fi |
| 3392 |
rm -rf conftest* |
| 3393 |
unset oldCFLAGS |
| 3394 |
;; |
| 3395 |
esac |
| 3396 |
fi |
| 3397 |
|
| 3398 |
fi |
| 3399 |
|
| 3400 |
add_O0="no" |
| 3401 |
if [ "$NOOPTCFLAGS" = "" ] ; then |
| 3402 |
NOOPTCFLAGS=`echo "$CFLAGS" | sed 's/[-+]O[0-9A-Za-z]*//g;s/-xO[0-9]//g;s/-Wc,-O3//g;s/-IPA//g;s/-xipo=?[0-9]?//g;s/\ \ */ /g;s/^\ *//;s/\ *$//;'` |
| 3403 |
if [ "$GCC" = "yes" ] ; then |
| 3404 |
add_O0="yes" |
| 3405 |
else |
| 3406 |
case "$CC" in |
| 3407 |
ccc|*/ccc) |
| 3408 |
# Compaq CC |
| 3409 |
add_O0="yes" |
| 3410 |
;; |
| 3411 |
esac |
| 3412 |
fi |
| 3413 |
fi |
| 3414 |
if [ "$DEBUGCFLAGS" = "" ] ; then |
| 3415 |
DEBUGCFLAGS="-g $NOOPTCFLAGS" |
| 3416 |
fi |
| 3417 |
if [ "$add_O0" = yes ] ; then |
| 3418 |
NOOPTCFLAGS="-O0 $NOOPTCFLAGS" |
| 3419 |
fi |
| 3420 |
# |
| 3421 |
# Was it ./configure --enable-debug ? |
| 3422 |
# |
| 3423 |
echo $ac_n "checking if this is a debug build""... $ac_c" 1>&6 |
| 3424 |
echo "configure:3425: checking if this is a debug build" >&5 |
| 3425 |
if test "$DEBUGBUILD" = yes ; then |
| 3426 |
echo "$ac_t""yes" 1>&6 |
| 3427 |
CFLAGS="$DEBUGCFLAGS" |
| 3428 |
else |
| 3429 |
echo "$ac_t""no" 1>&6 |
| 3430 |
fi |
| 3431 |
|
| 3432 |
wi_cv_lfs="no" |
| 3433 |
result="no" |
| 3434 |
if test "os_${os}_gcc_${GCC}" = os_hp-ux_gcc_yes ; then |
| 3435 |
|
| 3436 |
CFLAGS=`echo "$CFLAGS" | sed s/-D__STDC_EXT__//g` |
| 3437 |
echo $ac_n "checking if -D__STDC_EXT__ is needed with GCC on HP-UX""... $ac_c" 1>&6 |
| 3438 |
echo "configure:3439: checking if -D__STDC_EXT__ is needed with GCC on HP-UX" >&5 |
| 3439 |
if test "$cross_compiling" = yes; then |
| 3440 |
|
| 3441 |
# action if cross-compiling, guess |
| 3442 |
CFLAGS="-D__STDC_EXT__ $CFLAGS" |
| 3443 |
echo "$ac_t""(guessing) yes" 1>&6 |
| 3444 |
|
| 3445 |
else |
| 3446 |
cat > conftest.$ac_ext <<EOF |
| 3447 |
#line 3448 "configure" |
| 3448 |
#include "confdefs.h" |
| 3449 |
|
| 3450 |
#include <stdio.h> |
| 3451 |
#ifdef HAVE_STDLIB_H |
| 3452 |
# include <stdlib.h> |
| 3453 |
#endif |
| 3454 |
|
| 3455 |
int main(void) |
| 3456 |
{ |
| 3457 |
#ifdef __STDC_EXT__ |
| 3458 |
if (__STDC_EXT__ == 0) |
| 3459 |
exit(1); /* have __STDC_EXT__=0 */ |
| 3460 |
exit(0); /* have __STDC_EXT__=1 */ |
| 3461 |
#else |
| 3462 |
exit(1); /* do not have __STDC_EXT__ */ |
| 3463 |
#endif |
| 3464 |
} |
| 3465 |
EOF |
| 3466 |
if { (eval echo configure:3467: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 3467 |
then |
| 3468 |
|
| 3469 |
# action if true |
| 3470 |
# |
| 3471 |
# Already have it defined. |
| 3472 |
# |
| 3473 |
echo "$ac_t""no" 1>&6 |
| 3474 |
|
| 3475 |
else |
| 3476 |
echo "configure: failed program was:" >&5 |
| 3477 |
cat conftest.$ac_ext >&5 |
| 3478 |
rm -fr conftest* |
| 3479 |
|
| 3480 |
# action if false |
| 3481 |
# |
| 3482 |
# Not defined -- we need to define it then. |
| 3483 |
# This is required for the extended |
| 3484 |
# namespace symbols for Large Files. |
| 3485 |
# |
| 3486 |
CFLAGS="-D__STDC_EXT__ $CFLAGS" |
| 3487 |
echo "$ac_t""yes" 1>&6 |
| 3488 |
|
| 3489 |
fi |
| 3490 |
rm -fr conftest* |
| 3491 |
fi |
| 3492 |
|
| 3493 |
|
| 3494 |
fi |
| 3495 |
for ac_hdr in unistd.h |
| 3496 |
do |
| 3497 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 3498 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 3499 |
echo "configure:3500: checking for $ac_hdr" >&5 |
| 3500 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 3501 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 3502 |
else |
| 3503 |
cat > conftest.$ac_ext <<EOF |
| 3504 |
#line 3505 "configure" |
| 3505 |
#include "confdefs.h" |
| 3506 |
#include <$ac_hdr> |
| 3507 |
EOF |
| 3508 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 3509 |
{ (eval echo configure:3510: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 3510 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 3511 |
if test -z "$ac_err"; then |
| 3512 |
rm -rf conftest* |
| 3513 |
eval "ac_cv_header_$ac_safe=yes" |
| 3514 |
else |
| 3515 |
echo "$ac_err" >&5 |
| 3516 |
echo "configure: failed program was:" >&5 |
| 3517 |
cat conftest.$ac_ext >&5 |
| 3518 |
rm -rf conftest* |
| 3519 |
eval "ac_cv_header_$ac_safe=no" |
| 3520 |
fi |
| 3521 |
rm -rf conftest* |
| 3522 |
fi |
| 3523 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3524 |
echo "$ac_t""yes" 1>&6 |
| 3525 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 3526 |
cat >> confdefs.h <<EOF |
| 3527 |
#define $ac_tr_hdr 1 |
| 3528 |
EOF |
| 3529 |
|
| 3530 |
else |
| 3531 |
echo "$ac_t""no" 1>&6 |
| 3532 |
fi |
| 3533 |
done |
| 3534 |
|
| 3535 |
if test "x$ac_cv_sizeof_stat_st_size" = x ; then |
| 3536 |
|
| 3537 |
echo $ac_n "checking size of st_size field in struct stat""... $ac_c" 1>&6 |
| 3538 |
echo "configure:3539: checking size of st_size field in struct stat" >&5 |
| 3539 |
|
| 3540 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 3541 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_ST_SIZE." 1>&2; exit 1; } |
| 3542 |
fi |
| 3543 |
|
| 3544 |
if test "$cross_compiling" = yes; then |
| 3545 |
|
| 3546 |
# action if cross compiling |
| 3547 |
x="unknown" |
| 3548 |
ac_cv_sizeof_stat_st_size="4" |
| 3549 |
rm -f conftest.out |
| 3550 |
|
| 3551 |
else |
| 3552 |
cat > conftest.$ac_ext <<EOF |
| 3553 |
#line 3554 "configure" |
| 3554 |
#include "confdefs.h" |
| 3555 |
|
| 3556 |
/* program */ |
| 3557 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 3558 |
# define _ALL_SOURCE 1 |
| 3559 |
#endif |
| 3560 |
#ifdef HAVE_UNISTD_H |
| 3561 |
# include <unistd.h> |
| 3562 |
#endif |
| 3563 |
#include <sys/types.h> |
| 3564 |
#include <sys/stat.h> |
| 3565 |
#include <stdio.h> |
| 3566 |
#ifdef HAVE_STDLIB_H |
| 3567 |
# include <stdlib.h> |
| 3568 |
#endif |
| 3569 |
|
| 3570 |
int main(void) |
| 3571 |
{ |
| 3572 |
struct stat x; |
| 3573 |
FILE *fp; |
| 3574 |
|
| 3575 |
fp = fopen("conftest.out", "w"); |
| 3576 |
if (fp != NULL) { |
| 3577 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x.st_size)); |
| 3578 |
fclose(fp); |
| 3579 |
exit(0); /* OK */ |
| 3580 |
} |
| 3581 |
exit(1); /* Not OK */ |
| 3582 |
} |
| 3583 |
|
| 3584 |
EOF |
| 3585 |
if { (eval echo configure:3586: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 3586 |
then |
| 3587 |
|
| 3588 |
# action if true |
| 3589 |
x=`cat conftest.out` |
| 3590 |
case "$x" in |
| 3591 |
[0-9]*) |
| 3592 |
ac_cv_sizeof_stat_st_size="$x" |
| 3593 |
;; |
| 3594 |
*) |
| 3595 |
x="failed" |
| 3596 |
ac_cv_sizeof_stat_st_size="4" |
| 3597 |
;; |
| 3598 |
esac |
| 3599 |
rm -f conftest.out |
| 3600 |
|
| 3601 |
else |
| 3602 |
echo "configure: failed program was:" >&5 |
| 3603 |
cat conftest.$ac_ext >&5 |
| 3604 |
rm -fr conftest* |
| 3605 |
|
| 3606 |
# action if false |
| 3607 |
x="failed" |
| 3608 |
ac_cv_sizeof_stat_st_size="4" |
| 3609 |
rm -f conftest.out |
| 3610 |
|
| 3611 |
fi |
| 3612 |
rm -fr conftest* |
| 3613 |
fi |
| 3614 |
|
| 3615 |
echo "$ac_t""$x" 1>&6 |
| 3616 |
|
| 3617 |
fi |
| 3618 |
if test "x$ac_cv_sizeof_off_t" = x ; then |
| 3619 |
|
| 3620 |
echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
| 3621 |
echo "configure:3622: checking size of off_t" >&5 |
| 3622 |
|
| 3623 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 3624 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_OFF_T." 1>&2; exit 1; } |
| 3625 |
fi |
| 3626 |
|
| 3627 |
if test "$cross_compiling" = yes; then |
| 3628 |
|
| 3629 |
# action if cross compiling |
| 3630 |
x="unknown" |
| 3631 |
ac_cv_sizeof_off_t="4" |
| 3632 |
rm -f conftest.out |
| 3633 |
|
| 3634 |
else |
| 3635 |
cat > conftest.$ac_ext <<EOF |
| 3636 |
#line 3637 "configure" |
| 3637 |
#include "confdefs.h" |
| 3638 |
|
| 3639 |
/* program */ |
| 3640 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 3641 |
# define _ALL_SOURCE 1 |
| 3642 |
#endif |
| 3643 |
#ifdef HAVE_UNISTD_H |
| 3644 |
# include <unistd.h> |
| 3645 |
#endif |
| 3646 |
#include <sys/types.h> |
| 3647 |
#include <sys/stat.h> |
| 3648 |
#include <stdio.h> |
| 3649 |
#ifdef HAVE_STDLIB_H |
| 3650 |
# include <stdlib.h> |
| 3651 |
#endif |
| 3652 |
|
| 3653 |
int main(void) |
| 3654 |
{ |
| 3655 |
off_t x = 0; |
| 3656 |
FILE *fp; |
| 3657 |
|
| 3658 |
fp = fopen("conftest.out", "w"); |
| 3659 |
if (fp != NULL) { |
| 3660 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 3661 |
fclose(fp); |
| 3662 |
exit(0); /* OK */ |
| 3663 |
} |
| 3664 |
exit(1); /* Not OK */ |
| 3665 |
} |
| 3666 |
|
| 3667 |
EOF |
| 3668 |
if { (eval echo configure:3669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 3669 |
then |
| 3670 |
|
| 3671 |
# action if true |
| 3672 |
x=`cat conftest.out` |
| 3673 |
case "$x" in |
| 3674 |
[0-9]*) |
| 3675 |
ac_cv_sizeof_off_t="$x" |
| 3676 |
;; |
| 3677 |
*) |
| 3678 |
x="failed" |
| 3679 |
ac_cv_sizeof_off_t="4" |
| 3680 |
;; |
| 3681 |
esac |
| 3682 |
rm -f conftest.out |
| 3683 |
|
| 3684 |
else |
| 3685 |
echo "configure: failed program was:" >&5 |
| 3686 |
cat conftest.$ac_ext >&5 |
| 3687 |
rm -fr conftest* |
| 3688 |
|
| 3689 |
# action if false |
| 3690 |
x="failed" |
| 3691 |
ac_cv_sizeof_off_t="4" |
| 3692 |
rm -f conftest.out |
| 3693 |
|
| 3694 |
fi |
| 3695 |
rm -fr conftest* |
| 3696 |
fi |
| 3697 |
|
| 3698 |
echo "$ac_t""$x" 1>&6 |
| 3699 |
|
| 3700 |
fi |
| 3701 |
if test "x$ac_cv_sizeof_size_t" = x ; then |
| 3702 |
|
| 3703 |
echo $ac_n "checking size of size_t""... $ac_c" 1>&6 |
| 3704 |
echo "configure:3705: checking size of size_t" >&5 |
| 3705 |
|
| 3706 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 3707 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_SIZE_T." 1>&2; exit 1; } |
| 3708 |
fi |
| 3709 |
|
| 3710 |
if test "$cross_compiling" = yes; then |
| 3711 |
|
| 3712 |
# action if cross compiling |
| 3713 |
x="unknown" |
| 3714 |
ac_cv_sizeof_size_t="4" |
| 3715 |
rm -f conftest.out |
| 3716 |
|
| 3717 |
else |
| 3718 |
cat > conftest.$ac_ext <<EOF |
| 3719 |
#line 3720 "configure" |
| 3720 |
#include "confdefs.h" |
| 3721 |
|
| 3722 |
/* program */ |
| 3723 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 3724 |
# define _ALL_SOURCE 1 |
| 3725 |
#endif |
| 3726 |
#ifdef HAVE_UNISTD_H |
| 3727 |
# include <unistd.h> |
| 3728 |
#endif |
| 3729 |
#include <sys/types.h> |
| 3730 |
#include <sys/stat.h> |
| 3731 |
#include <stdio.h> |
| 3732 |
#ifdef HAVE_STDLIB_H |
| 3733 |
# include <stdlib.h> |
| 3734 |
#endif |
| 3735 |
|
| 3736 |
int main(void) |
| 3737 |
{ |
| 3738 |
size_t x = 0; |
| 3739 |
FILE *fp; |
| 3740 |
|
| 3741 |
fp = fopen("conftest.out", "w"); |
| 3742 |
if (fp != NULL) { |
| 3743 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 3744 |
fclose(fp); |
| 3745 |
exit(0); /* OK */ |
| 3746 |
} |
| 3747 |
exit(1); /* Not OK */ |
| 3748 |
} |
| 3749 |
|
| 3750 |
EOF |
| 3751 |
if { (eval echo configure:3752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 3752 |
then |
| 3753 |
|
| 3754 |
# action if true |
| 3755 |
x=`cat conftest.out` |
| 3756 |
case "$x" in |
| 3757 |
[0-9]*) |
| 3758 |
ac_cv_sizeof_size_t="$x" |
| 3759 |
;; |
| 3760 |
*) |
| 3761 |
x="failed" |
| 3762 |
ac_cv_sizeof_size_t="4" |
| 3763 |
;; |
| 3764 |
esac |
| 3765 |
rm -f conftest.out |
| 3766 |
|
| 3767 |
else |
| 3768 |
echo "configure: failed program was:" >&5 |
| 3769 |
cat conftest.$ac_ext >&5 |
| 3770 |
rm -fr conftest* |
| 3771 |
|
| 3772 |
# action if false |
| 3773 |
x="failed" |
| 3774 |
ac_cv_sizeof_size_t="4" |
| 3775 |
rm -f conftest.out |
| 3776 |
|
| 3777 |
fi |
| 3778 |
rm -fr conftest* |
| 3779 |
fi |
| 3780 |
|
| 3781 |
echo "$ac_t""$x" 1>&6 |
| 3782 |
|
| 3783 |
fi |
| 3784 |
orig_CFLAGS="$CFLAGS" |
| 3785 |
if test "$ac_cv_sizeof_stat_st_size" -le 4 || test "$ac_cv_sizeof_off_t" -le 4 ; then |
| 3786 |
unset ac_cv_sizeof_stat_st_size ac_cv_sizeof_off_t |
| 3787 |
CFLAGS=`echo "$CFLAGS" | sed 's/-D_LARGEFILE64_SOURCE//g'` |
| 3788 |
case "$CFLAGS" in |
| 3789 |
*-D_LARGEFILE_SOURCE*) |
| 3790 |
result="already included -D_LARGEFILE_SOURCE" |
| 3791 |
;; |
| 3792 |
*) |
| 3793 |
CFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $CFLAGS" |
| 3794 |
DEBUGCFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $DEBUGCFLAGS" |
| 3795 |
NOOPTCFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $NOOPTCFLAGS" |
| 3796 |
result="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" |
| 3797 |
;; |
| 3798 |
esac |
| 3799 |
wi_cv_lfs="yes" |
| 3800 |
fi |
| 3801 |
if test "x$ac_cv_sizeof_off_t" = x ; then |
| 3802 |
# Recheck, to see if the defines took effect. |
| 3803 |
|
| 3804 |
echo $ac_n "checking size of st_size field in struct stat""... $ac_c" 1>&6 |
| 3805 |
echo "configure:3806: checking size of st_size field in struct stat" >&5 |
| 3806 |
|
| 3807 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 3808 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_ST_SIZE." 1>&2; exit 1; } |
| 3809 |
fi |
| 3810 |
|
| 3811 |
if test "$cross_compiling" = yes; then |
| 3812 |
|
| 3813 |
# action if cross compiling |
| 3814 |
x="unknown" |
| 3815 |
ac_cv_sizeof_stat_st_size="4" |
| 3816 |
rm -f conftest.out |
| 3817 |
|
| 3818 |
else |
| 3819 |
cat > conftest.$ac_ext <<EOF |
| 3820 |
#line 3821 "configure" |
| 3821 |
#include "confdefs.h" |
| 3822 |
|
| 3823 |
/* program */ |
| 3824 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 3825 |
# define _ALL_SOURCE 1 |
| 3826 |
#endif |
| 3827 |
#ifdef HAVE_UNISTD_H |
| 3828 |
# include <unistd.h> |
| 3829 |
#endif |
| 3830 |
#include <sys/types.h> |
| 3831 |
#include <sys/stat.h> |
| 3832 |
#include <stdio.h> |
| 3833 |
#ifdef HAVE_STDLIB_H |
| 3834 |
# include <stdlib.h> |
| 3835 |
#endif |
| 3836 |
|
| 3837 |
int main(void) |
| 3838 |
{ |
| 3839 |
struct stat x; |
| 3840 |
FILE *fp; |
| 3841 |
|
| 3842 |
fp = fopen("conftest.out", "w"); |
| 3843 |
if (fp != NULL) { |
| 3844 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x.st_size)); |
| 3845 |
fclose(fp); |
| 3846 |
exit(0); /* OK */ |
| 3847 |
} |
| 3848 |
exit(1); /* Not OK */ |
| 3849 |
} |
| 3850 |
|
| 3851 |
EOF |
| 3852 |
if { (eval echo configure:3853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 3853 |
then |
| 3854 |
|
| 3855 |
# action if true |
| 3856 |
x=`cat conftest.out` |
| 3857 |
case "$x" in |
| 3858 |
[0-9]*) |
| 3859 |
ac_cv_sizeof_stat_st_size="$x" |
| 3860 |
;; |
| 3861 |
*) |
| 3862 |
x="failed" |
| 3863 |
ac_cv_sizeof_stat_st_size="4" |
| 3864 |
;; |
| 3865 |
esac |
| 3866 |
rm -f conftest.out |
| 3867 |
|
| 3868 |
else |
| 3869 |
echo "configure: failed program was:" >&5 |
| 3870 |
cat conftest.$ac_ext >&5 |
| 3871 |
rm -fr conftest* |
| 3872 |
|
| 3873 |
# action if false |
| 3874 |
x="failed" |
| 3875 |
ac_cv_sizeof_stat_st_size="4" |
| 3876 |
rm -f conftest.out |
| 3877 |
|
| 3878 |
fi |
| 3879 |
rm -fr conftest* |
| 3880 |
fi |
| 3881 |
|
| 3882 |
echo "$ac_t""$x" 1>&6 |
| 3883 |
|
| 3884 |
|
| 3885 |
echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
| 3886 |
echo "configure:3887: checking size of off_t" >&5 |
| 3887 |
|
| 3888 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 3889 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_OFF_T." 1>&2; exit 1; } |
| 3890 |
fi |
| 3891 |
|
| 3892 |
if test "$cross_compiling" = yes; then |
| 3893 |
|
| 3894 |
# action if cross compiling |
| 3895 |
x="unknown" |
| 3896 |
ac_cv_sizeof_off_t="4" |
| 3897 |
rm -f conftest.out |
| 3898 |
|
| 3899 |
else |
| 3900 |
cat > conftest.$ac_ext <<EOF |
| 3901 |
#line 3902 "configure" |
| 3902 |
#include "confdefs.h" |
| 3903 |
|
| 3904 |
/* program */ |
| 3905 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 3906 |
# define _ALL_SOURCE 1 |
| 3907 |
#endif |
| 3908 |
#ifdef HAVE_UNISTD_H |
| 3909 |
# include <unistd.h> |
| 3910 |
#endif |
| 3911 |
#include <sys/types.h> |
| 3912 |
#include <sys/stat.h> |
| 3913 |
#include <stdio.h> |
| 3914 |
#ifdef HAVE_STDLIB_H |
| 3915 |
# include <stdlib.h> |
| 3916 |
#endif |
| 3917 |
|
| 3918 |
int main(void) |
| 3919 |
{ |
| 3920 |
off_t x = 0; |
| 3921 |
FILE *fp; |
| 3922 |
|
| 3923 |
fp = fopen("conftest.out", "w"); |
| 3924 |
if (fp != NULL) { |
| 3925 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 3926 |
fclose(fp); |
| 3927 |
exit(0); /* OK */ |
| 3928 |
} |
| 3929 |
exit(1); /* Not OK */ |
| 3930 |
} |
| 3931 |
|
| 3932 |
EOF |
| 3933 |
if { (eval echo configure:3934: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 3934 |
then |
| 3935 |
|
| 3936 |
# action if true |
| 3937 |
x=`cat conftest.out` |
| 3938 |
case "$x" in |
| 3939 |
[0-9]*) |
| 3940 |
ac_cv_sizeof_off_t="$x" |
| 3941 |
;; |
| 3942 |
*) |
| 3943 |
x="failed" |
| 3944 |
ac_cv_sizeof_off_t="4" |
| 3945 |
;; |
| 3946 |
esac |
| 3947 |
rm -f conftest.out |
| 3948 |
|
| 3949 |
else |
| 3950 |
echo "configure: failed program was:" >&5 |
| 3951 |
cat conftest.$ac_ext >&5 |
| 3952 |
rm -fr conftest* |
| 3953 |
|
| 3954 |
# action if false |
| 3955 |
x="failed" |
| 3956 |
ac_cv_sizeof_off_t="4" |
| 3957 |
rm -f conftest.out |
| 3958 |
|
| 3959 |
fi |
| 3960 |
rm -fr conftest* |
| 3961 |
fi |
| 3962 |
|
| 3963 |
echo "$ac_t""$x" 1>&6 |
| 3964 |
|
| 3965 |
|
| 3966 |
echo $ac_n "checking size of size_t""... $ac_c" 1>&6 |
| 3967 |
echo "configure:3968: checking size of size_t" >&5 |
| 3968 |
|
| 3969 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 3970 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_SIZE_T." 1>&2; exit 1; } |
| 3971 |
fi |
| 3972 |
|
| 3973 |
if test "$cross_compiling" = yes; then |
| 3974 |
|
| 3975 |
# action if cross compiling |
| 3976 |
x="unknown" |
| 3977 |
ac_cv_sizeof_size_t="4" |
| 3978 |
rm -f conftest.out |
| 3979 |
|
| 3980 |
else |
| 3981 |
cat > conftest.$ac_ext <<EOF |
| 3982 |
#line 3983 "configure" |
| 3983 |
#include "confdefs.h" |
| 3984 |
|
| 3985 |
/* program */ |
| 3986 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 3987 |
# define _ALL_SOURCE 1 |
| 3988 |
#endif |
| 3989 |
#ifdef HAVE_UNISTD_H |
| 3990 |
# include <unistd.h> |
| 3991 |
#endif |
| 3992 |
#include <sys/types.h> |
| 3993 |
#include <sys/stat.h> |
| 3994 |
#include <stdio.h> |
| 3995 |
#ifdef HAVE_STDLIB_H |
| 3996 |
# include <stdlib.h> |
| 3997 |
#endif |
| 3998 |
|
| 3999 |
int main(void) |
| 4000 |
{ |
| 4001 |
size_t x = 0; |
| 4002 |
FILE *fp; |
| 4003 |
|
| 4004 |
fp = fopen("conftest.out", "w"); |
| 4005 |
if (fp != NULL) { |
| 4006 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 4007 |
fclose(fp); |
| 4008 |
exit(0); /* OK */ |
| 4009 |
} |
| 4010 |
exit(1); /* Not OK */ |
| 4011 |
} |
| 4012 |
|
| 4013 |
EOF |
| 4014 |
if { (eval echo configure:4015: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 4015 |
then |
| 4016 |
|
| 4017 |
# action if true |
| 4018 |
x=`cat conftest.out` |
| 4019 |
case "$x" in |
| 4020 |
[0-9]*) |
| 4021 |
ac_cv_sizeof_size_t="$x" |
| 4022 |
;; |
| 4023 |
*) |
| 4024 |
x="failed" |
| 4025 |
ac_cv_sizeof_size_t="4" |
| 4026 |
;; |
| 4027 |
esac |
| 4028 |
rm -f conftest.out |
| 4029 |
|
| 4030 |
else |
| 4031 |
echo "configure: failed program was:" >&5 |
| 4032 |
cat conftest.$ac_ext >&5 |
| 4033 |
rm -fr conftest* |
| 4034 |
|
| 4035 |
# action if false |
| 4036 |
x="failed" |
| 4037 |
ac_cv_sizeof_size_t="4" |
| 4038 |
rm -f conftest.out |
| 4039 |
|
| 4040 |
fi |
| 4041 |
rm -fr conftest* |
| 4042 |
fi |
| 4043 |
|
| 4044 |
echo "$ac_t""$x" 1>&6 |
| 4045 |
|
| 4046 |
if test "$ac_cv_sizeof_stat_st_size" -le 4 || test "$ac_cv_sizeof_off_t" -le 4 ; then |
| 4047 |
CFLAGS="$orig_CFLAGS" |
| 4048 |
unset orig_CFLAGS |
| 4049 |
wi_cv_lfs64="yes" |
| 4050 |
CFLAGS="-D_LARGEFILE64_SOURCE $CFLAGS" |
| 4051 |
DEBUGCFLAGS="-D_LARGEFILE64_SOURCE $DEBUGCFLAGS" |
| 4052 |
NOOPTCFLAGS="-D_LARGEFILE64_SOURCE $NOOPTCFLAGS" |
| 4053 |
result="-D_LARGEFILE64_SOURCE" |
| 4054 |
# Re-re-check, to see if the defines took effect. |
| 4055 |
unset ac_cv_sizeof_stat_st_size ac_cv_sizeof_off_t |
| 4056 |
|
| 4057 |
echo $ac_n "checking size of st_size field in struct stat64""... $ac_c" 1>&6 |
| 4058 |
echo "configure:4059: checking size of st_size field in struct stat64" >&5 |
| 4059 |
|
| 4060 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 4061 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_STAT64_ST_SIZE." 1>&2; exit 1; } |
| 4062 |
fi |
| 4063 |
|
| 4064 |
if test "$cross_compiling" = yes; then |
| 4065 |
|
| 4066 |
# action if cross compiling |
| 4067 |
x="unknown" |
| 4068 |
ac_cv_sizeof_stat64_st_size="8" |
| 4069 |
rm -f conftest.out |
| 4070 |
|
| 4071 |
else |
| 4072 |
cat > conftest.$ac_ext <<EOF |
| 4073 |
#line 4074 "configure" |
| 4074 |
#include "confdefs.h" |
| 4075 |
|
| 4076 |
/* program */ |
| 4077 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 4078 |
# define _ALL_SOURCE 1 |
| 4079 |
#endif |
| 4080 |
#ifdef HAVE_UNISTD_H |
| 4081 |
# include <unistd.h> |
| 4082 |
#endif |
| 4083 |
#include <sys/types.h> |
| 4084 |
#include <sys/stat.h> |
| 4085 |
#include <stdio.h> |
| 4086 |
#ifdef HAVE_STDLIB_H |
| 4087 |
# include <stdlib.h> |
| 4088 |
#endif |
| 4089 |
|
| 4090 |
int main(void) |
| 4091 |
{ |
| 4092 |
struct stat64 x; |
| 4093 |
FILE *fp; |
| 4094 |
|
| 4095 |
fp = fopen("conftest.out", "w"); |
| 4096 |
if (fp != NULL) { |
| 4097 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x.st_size)); |
| 4098 |
fclose(fp); |
| 4099 |
exit(0); /* OK */ |
| 4100 |
} |
| 4101 |
exit(1); /* Not OK */ |
| 4102 |
} |
| 4103 |
|
| 4104 |
EOF |
| 4105 |
if { (eval echo configure:4106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 4106 |
then |
| 4107 |
|
| 4108 |
# action if true |
| 4109 |
x=`cat conftest.out` |
| 4110 |
case "$x" in |
| 4111 |
[0-9]*) |
| 4112 |
cat >> confdefs.h <<EOF |
| 4113 |
#define SIZEOF_STAT64_ST_SIZE $x |
| 4114 |
EOF |
| 4115 |
|
| 4116 |
ac_cv_sizeof_stat64_st_size="$x" |
| 4117 |
;; |
| 4118 |
*) |
| 4119 |
x="failed" |
| 4120 |
ac_cv_sizeof_stat64_st_size="4" |
| 4121 |
;; |
| 4122 |
esac |
| 4123 |
rm -f conftest.out |
| 4124 |
|
| 4125 |
else |
| 4126 |
echo "configure: failed program was:" >&5 |
| 4127 |
cat conftest.$ac_ext >&5 |
| 4128 |
rm -fr conftest* |
| 4129 |
|
| 4130 |
# action if false |
| 4131 |
x="failed" |
| 4132 |
ac_cv_sizeof_stat64_st_size="4" |
| 4133 |
rm -f conftest.out |
| 4134 |
|
| 4135 |
fi |
| 4136 |
rm -fr conftest* |
| 4137 |
fi |
| 4138 |
|
| 4139 |
echo "$ac_t""$x" 1>&6 |
| 4140 |
|
| 4141 |
|
| 4142 |
echo $ac_n "checking size of off64_t""... $ac_c" 1>&6 |
| 4143 |
echo "configure:4144: checking size of off64_t" >&5 |
| 4144 |
|
| 4145 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 4146 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_OFF64_T." 1>&2; exit 1; } |
| 4147 |
fi |
| 4148 |
|
| 4149 |
if test "$cross_compiling" = yes; then |
| 4150 |
|
| 4151 |
# action if cross compiling |
| 4152 |
x="unknown" |
| 4153 |
ac_cv_sizeof_off64_t="8" |
| 4154 |
rm -f conftest.out |
| 4155 |
|
| 4156 |
else |
| 4157 |
cat > conftest.$ac_ext <<EOF |
| 4158 |
#line 4159 "configure" |
| 4159 |
#include "confdefs.h" |
| 4160 |
|
| 4161 |
/* program */ |
| 4162 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 4163 |
# define _ALL_SOURCE 1 |
| 4164 |
#endif |
| 4165 |
#ifdef HAVE_UNISTD_H |
| 4166 |
# include <unistd.h> |
| 4167 |
#endif |
| 4168 |
#include <sys/types.h> |
| 4169 |
#include <sys/stat.h> |
| 4170 |
#include <stdio.h> |
| 4171 |
#ifdef HAVE_STDLIB_H |
| 4172 |
# include <stdlib.h> |
| 4173 |
#endif |
| 4174 |
|
| 4175 |
int main(void) |
| 4176 |
{ |
| 4177 |
off64_t x = 0; |
| 4178 |
FILE *fp; |
| 4179 |
|
| 4180 |
fp = fopen("conftest.out", "w"); |
| 4181 |
if (fp != NULL) { |
| 4182 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 4183 |
fclose(fp); |
| 4184 |
exit(0); /* OK */ |
| 4185 |
} |
| 4186 |
exit(1); /* Not OK */ |
| 4187 |
} |
| 4188 |
|
| 4189 |
EOF |
| 4190 |
if { (eval echo configure:4191: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 4191 |
then |
| 4192 |
|
| 4193 |
# action if true |
| 4194 |
x=`cat conftest.out` |
| 4195 |
case "$x" in |
| 4196 |
[0-9]*) |
| 4197 |
cat >> confdefs.h <<EOF |
| 4198 |
#define SIZEOF_OFF64_T $x |
| 4199 |
EOF |
| 4200 |
|
| 4201 |
ac_cv_sizeof_off64_t="$x" |
| 4202 |
;; |
| 4203 |
*) |
| 4204 |
x="failed" |
| 4205 |
ac_cv_sizeof_off64_t="4" |
| 4206 |
;; |
| 4207 |
esac |
| 4208 |
rm -f conftest.out |
| 4209 |
|
| 4210 |
else |
| 4211 |
echo "configure: failed program was:" >&5 |
| 4212 |
cat conftest.$ac_ext >&5 |
| 4213 |
rm -fr conftest* |
| 4214 |
|
| 4215 |
# action if false |
| 4216 |
x="failed" |
| 4217 |
ac_cv_sizeof_off64_t="4" |
| 4218 |
rm -f conftest.out |
| 4219 |
|
| 4220 |
fi |
| 4221 |
rm -fr conftest* |
| 4222 |
fi |
| 4223 |
|
| 4224 |
echo "$ac_t""$x" 1>&6 |
| 4225 |
|
| 4226 |
|
| 4227 |
echo $ac_n "checking size of st_size field in struct stat""... $ac_c" 1>&6 |
| 4228 |
echo "configure:4229: checking size of st_size field in struct stat" >&5 |
| 4229 |
|
| 4230 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 4231 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_ST_SIZE." 1>&2; exit 1; } |
| 4232 |
fi |
| 4233 |
|
| 4234 |
if test "$cross_compiling" = yes; then |
| 4235 |
|
| 4236 |
# action if cross compiling |
| 4237 |
x="unknown" |
| 4238 |
ac_cv_sizeof_stat_st_size="4" |
| 4239 |
rm -f conftest.out |
| 4240 |
|
| 4241 |
else |
| 4242 |
cat > conftest.$ac_ext <<EOF |
| 4243 |
#line 4244 "configure" |
| 4244 |
#include "confdefs.h" |
| 4245 |
|
| 4246 |
/* program */ |
| 4247 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 4248 |
# define _ALL_SOURCE 1 |
| 4249 |
#endif |
| 4250 |
#ifdef HAVE_UNISTD_H |
| 4251 |
# include <unistd.h> |
| 4252 |
#endif |
| 4253 |
#include <sys/types.h> |
| 4254 |
#include <sys/stat.h> |
| 4255 |
#include <stdio.h> |
| 4256 |
#ifdef HAVE_STDLIB_H |
| 4257 |
# include <stdlib.h> |
| 4258 |
#endif |
| 4259 |
|
| 4260 |
int main(void) |
| 4261 |
{ |
| 4262 |
struct stat x; |
| 4263 |
FILE *fp; |
| 4264 |
|
| 4265 |
fp = fopen("conftest.out", "w"); |
| 4266 |
if (fp != NULL) { |
| 4267 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x.st_size)); |
| 4268 |
fclose(fp); |
| 4269 |
exit(0); /* OK */ |
| 4270 |
} |
| 4271 |
exit(1); /* Not OK */ |
| 4272 |
} |
| 4273 |
|
| 4274 |
EOF |
| 4275 |
if { (eval echo configure:4276: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 4276 |
then |
| 4277 |
|
| 4278 |
# action if true |
| 4279 |
x=`cat conftest.out` |
| 4280 |
case "$x" in |
| 4281 |
[0-9]*) |
| 4282 |
ac_cv_sizeof_stat_st_size="$x" |
| 4283 |
;; |
| 4284 |
*) |
| 4285 |
x="failed" |
| 4286 |
ac_cv_sizeof_stat_st_size="4" |
| 4287 |
;; |
| 4288 |
esac |
| 4289 |
rm -f conftest.out |
| 4290 |
|
| 4291 |
else |
| 4292 |
echo "configure: failed program was:" >&5 |
| 4293 |
cat conftest.$ac_ext >&5 |
| 4294 |
rm -fr conftest* |
| 4295 |
|
| 4296 |
# action if false |
| 4297 |
x="failed" |
| 4298 |
ac_cv_sizeof_stat_st_size="4" |
| 4299 |
rm -f conftest.out |
| 4300 |
|
| 4301 |
fi |
| 4302 |
rm -fr conftest* |
| 4303 |
fi |
| 4304 |
|
| 4305 |
echo "$ac_t""$x" 1>&6 |
| 4306 |
|
| 4307 |
|
| 4308 |
echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
| 4309 |
echo "configure:4310: checking size of off_t" >&5 |
| 4310 |
|
| 4311 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 4312 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SIZEOF_OFF_T." 1>&2; exit 1; } |
| 4313 |
fi |
| 4314 |
|
| 4315 |
if test "$cross_compiling" = yes; then |
| 4316 |
|
| 4317 |
# action if cross compiling |
| 4318 |
x="unknown" |
| 4319 |
ac_cv_sizeof_off_t="4" |
| 4320 |
rm -f conftest.out |
| 4321 |
|
| 4322 |
else |
| 4323 |
cat > conftest.$ac_ext <<EOF |
| 4324 |
#line 4325 "configure" |
| 4325 |
#include "confdefs.h" |
| 4326 |
|
| 4327 |
/* program */ |
| 4328 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 4329 |
# define _ALL_SOURCE 1 |
| 4330 |
#endif |
| 4331 |
#ifdef HAVE_UNISTD_H |
| 4332 |
# include <unistd.h> |
| 4333 |
#endif |
| 4334 |
#include <sys/types.h> |
| 4335 |
#include <sys/stat.h> |
| 4336 |
#include <stdio.h> |
| 4337 |
#ifdef HAVE_STDLIB_H |
| 4338 |
# include <stdlib.h> |
| 4339 |
#endif |
| 4340 |
|
| 4341 |
int main(void) |
| 4342 |
{ |
| 4343 |
off_t x = 0; |
| 4344 |
FILE *fp; |
| 4345 |
|
| 4346 |
fp = fopen("conftest.out", "w"); |
| 4347 |
if (fp != NULL) { |
| 4348 |
fprintf(fp, "%u\n", (unsigned int) sizeof(x)); |
| 4349 |
fclose(fp); |
| 4350 |
exit(0); /* OK */ |
| 4351 |
} |
| 4352 |
exit(1); /* Not OK */ |
| 4353 |
} |
| 4354 |
|
| 4355 |
EOF |
| 4356 |
if { (eval echo configure:4357: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 4357 |
then |
| 4358 |
|
| 4359 |
# action if true |
| 4360 |
x=`cat conftest.out` |
| 4361 |
case "$x" in |
| 4362 |
[0-9]*) |
| 4363 |
ac_cv_sizeof_off_t="$x" |
| 4364 |
;; |
| 4365 |
*) |
| 4366 |
x="failed" |
| 4367 |
ac_cv_sizeof_off_t="4" |
| 4368 |
;; |
| 4369 |
esac |
| 4370 |
rm -f conftest.out |
| 4371 |
|
| 4372 |
else |
| 4373 |
echo "configure: failed program was:" >&5 |
| 4374 |
cat conftest.$ac_ext >&5 |
| 4375 |
rm -fr conftest* |
| 4376 |
|
| 4377 |
# action if false |
| 4378 |
x="failed" |
| 4379 |
ac_cv_sizeof_off_t="4" |
| 4380 |
rm -f conftest.out |
| 4381 |
|
| 4382 |
fi |
| 4383 |
rm -fr conftest* |
| 4384 |
fi |
| 4385 |
|
| 4386 |
echo "$ac_t""$x" 1>&6 |
| 4387 |
|
| 4388 |
fi |
| 4389 |
fi |
| 4390 |
echo $ac_n "checking if we should add CFLAGS for Large File Support""... $ac_c" 1>&6 |
| 4391 |
echo "configure:4392: checking if we should add CFLAGS for Large File Support" >&5 |
| 4392 |
echo "$ac_t""$result" 1>&6 |
| 4393 |
unset orig_CFLAGS |
| 4394 |
|
| 4395 |
if test "x$ac_cv_sizeof_stat_st_size" != x ; then |
| 4396 |
cat >> confdefs.h <<EOF |
| 4397 |
#define SIZEOF_ST_SIZE $ac_cv_sizeof_stat_st_size |
| 4398 |
EOF |
| 4399 |
|
| 4400 |
fi |
| 4401 |
if test "x$ac_cv_sizeof_off_t" != x ; then |
| 4402 |
cat >> confdefs.h <<EOF |
| 4403 |
#define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
| 4404 |
EOF |
| 4405 |
|
| 4406 |
fi |
| 4407 |
|
| 4408 |
|
| 4409 |
fi |
| 4410 |
|
| 4411 |
|
| 4412 |
result="no" |
| 4413 |
case "$CFLAGS" in |
| 4414 |
*-D_REENTRANT*) |
| 4415 |
result="already included" |
| 4416 |
;; |
| 4417 |
*) |
| 4418 |
CFLAGS="-D_REENTRANT $CFLAGS" |
| 4419 |
result="-D_REENTRANT" |
| 4420 |
;; |
| 4421 |
esac |
| 4422 |
echo $ac_n "checking if we should add CFLAGS for reentrancy""... $ac_c" 1>&6 |
| 4423 |
echo "configure:4424: checking if we should add CFLAGS for reentrancy" >&5 |
| 4424 |
echo "$ac_t""$result" 1>&6 |
| 4425 |
|
| 4426 |
|
| 4427 |
|
| 4428 |
if test "$SYS" = macosx ; then |
| 4429 |
ac_cv_macosx_cflags=no |
| 4430 |
ac_cv_macosx_ldflags=no |
| 4431 |
|
| 4432 |
echo $ac_n "checking if MACOSX_DEPLOYMENT_TARGET environment variable is set""... $ac_c" 1>&6 |
| 4433 |
echo "configure:4434: checking if MACOSX_DEPLOYMENT_TARGET environment variable is set" >&5 |
| 4434 |
echo "$ac_t""${MACOSX_DEPLOYMENT_TARGET-no}" 1>&6 |
| 4435 |
|
| 4436 |
test_macosx_sdk_path=`/bin/ls -1d /Developer/SDKs/MacOSX10.*u.sdk 2>/dev/null | sed -n 1,1p` |
| 4437 |
if test "${test_macosx_sdk_path}" = "" ; then |
| 4438 |
test_macosx_sdk_path="no" |
| 4439 |
fi |
| 4440 |
case "$test_macosx_sdk_path" in |
| 4441 |
*/MacOSX10.4u.sdk) |
| 4442 |
# |
| 4443 |
# On Snow Leopard, you can't use gcc-4.2 to build the |
| 4444 |
# universal binary, but you can use gcc-4.0 if that |
| 4445 |
# is also installed. |
| 4446 |
# |
| 4447 |
case "$wi_cv_gcc_version" in |
| 4448 |
[56789]*|4.[123456789]*) |
| 4449 |
if [ -e "/usr/bin/gcc-4.0" ] ; then |
| 4450 |
CC="/usr/bin/gcc-4.0" |
| 4451 |
GCC="/usr/bin/gcc-4.0" |
| 4452 |
wi_cv_gcc_version="4.0.1" |
| 4453 |
else |
| 4454 |
test_macosx_sdk_path="no" |
| 4455 |
fi |
| 4456 |
;; |
| 4457 |
esac |
| 4458 |
;; |
| 4459 |
esac |
| 4460 |
echo $ac_n "checking if Mac OS X universal SDK is available""... $ac_c" 1>&6 |
| 4461 |
echo "configure:4462: checking if Mac OS X universal SDK is available" >&5 |
| 4462 |
echo "$ac_t""${test_macosx_sdk_path-no}" 1>&6 |
| 4463 |
|
| 4464 |
if test "${use_macosx_universal}" != no && test "${test_macosx_sdk_path}" != "no" ; then |
| 4465 |
# Note SDK path, e.g., macosx_sdk_path="/Developer/SDKs/MacOSX10.4u.sdk" |
| 4466 |
macosx_sdk_path="$test_macosx_sdk_path" |
| 4467 |
macosx_sdk_ver=`echo "$macosx_sdk_path" | sed 's/^.*OSX1/1/;s/u.sdk.*$//;'` # E.g., "10.4" |
| 4468 |
|
| 4469 |
# Calculate corresponding ver_int, e.g., "10400" |
| 4470 |
macosx_sdk_ver_int_maj=`echo "$macosx_sdk_ver" | cut -d. -f1` |
| 4471 |
macosx_sdk_ver_int_min=`echo "$macosx_sdk_ver" | cut -d. -f2` |
| 4472 |
macosx_sdk_ver_int_minmin=`echo "$macosx_sdk_ver" | cut -d. -f3` |
| 4473 |
macosx_sdk_ver_int=`expr "$macosx_sdk_ver_int_maj" '*' 1000 + "$macosx_sdk_ver_int_min" '*' 100 + "${macosx_sdk_ver_int_minmin-0}"` |
| 4474 |
|
| 4475 |
os_base_int=`expr "$os_int" - '(' "$os_int" '%' 10 ')'` |
| 4476 |
# Add OS X minimum version, if SDK is older than version of OS X on the build machine. |
| 4477 |
if test "$os_base_int" -gt "$macosx_sdk_ver_int" && test "x$MACOSX_DEPLOYMENT_TARGET" = "x" ; then |
| 4478 |
# Thanks, Toshi NAGATA |
| 4479 |
macosx_sdk_path="${macosx_sdk_path} -mmacosx-version-min=${macosx_sdk_ver}" |
| 4480 |
fi |
| 4481 |
# macosx_arch_flags="-arch x86_64 -arch i386 -arch ppc" # This works too |
| 4482 |
macosx_arch_flags="-arch i386 -arch ppc" |
| 4483 |
case "$CFLAGS" in |
| 4484 |
*"-isysroot"*"-arch"*|*"-arch"*"-isysroot"*) |
| 4485 |
# User already had both SDK path and desired architecture(s) in CFLAGS |
| 4486 |
;; |
| 4487 |
*"-arch"*) |
| 4488 |
ac_cv_macosx_cflags="-isysroot ${macosx_sdk_path}" |
| 4489 |
CFLAGS="${ac_cv_macosx_cflags} ${CFLAGS}" |
| 4490 |
;; |
| 4491 |
*"-isysroot"*) |
| 4492 |
ac_cv_macosx_cflags="${macosx_arch_flags}" |
| 4493 |
CFLAGS="${ac_cv_macosx_cflags} ${CFLAGS}" |
| 4494 |
;; |
| 4495 |
*) |
| 4496 |
ac_cv_macosx_cflags="-isysroot ${macosx_sdk_path} ${macosx_arch_flags}" |
| 4497 |
CFLAGS="${ac_cv_macosx_cflags} ${CFLAGS}" |
| 4498 |
;; |
| 4499 |
esac |
| 4500 |
|
| 4501 |
# |
| 4502 |
# Apparently, only libtool (glibtool) needs this -syslibroot flag. |
| 4503 |
# |
| 4504 |
# case "$LDFLAGS" in |
| 4505 |
# *"-syslibroot"*) |
| 4506 |
# # User already had SDK path in LDFLAGS |
| 4507 |
# ;; |
| 4508 |
# *) |
| 4509 |
# ac_cv_macosx_ldflags="-syslibroot ${macosx_sdk_path}" |
| 4510 |
# LDFLAGS="${ac_cv_macosx_ldflags} ${LDFLAGS}" |
| 4511 |
# ;; |
| 4512 |
# esac |
| 4513 |
fi |
| 4514 |
echo $ac_n "checking if we should add CFLAGS for Mac OS X""... $ac_c" 1>&6 |
| 4515 |
echo "configure:4516: checking if we should add CFLAGS for Mac OS X" >&5 |
| 4516 |
echo "$ac_t""$ac_cv_macosx_cflags" 1>&6 |
| 4517 |
fi |
| 4518 |
|
| 4519 |
|
| 4520 |
echo $ac_n "checking for strip""... $ac_c" 1>&6 |
| 4521 |
echo "configure:4522: checking for strip" >&5 |
| 4522 |
STRIP="strip" |
| 4523 |
if [ "x$cross_compiling" = "xyes" ] ; then |
| 4524 |
machine=`${CC-gcc} -dumpmachine 2>/dev/null` |
| 4525 |
case "$CC" in |
| 4526 |
*${machine}*) |
| 4527 |
f=`echo "$CC" | sed 's|/[^/]*$||'` |
| 4528 |
if [ -x "$f/${machine}-strip" ] ; then |
| 4529 |
STRIP="$f/${machine}-strip" |
| 4530 |
elif [ -x "$f/strip" ] ; then |
| 4531 |
STRIP="$f/strip" |
| 4532 |
fi |
| 4533 |
;; |
| 4534 |
esac |
| 4535 |
unset machine f |
| 4536 |
fi |
| 4537 |
echo "$ac_t""$STRIP" 1>&6 |
| 4538 |
|
| 4539 |
if test "$SFLAG" = "" ; then |
| 4540 |
SFLAG="-s" |
| 4541 |
case "$OS" in |
| 4542 |
macosx*) |
| 4543 |
SFLAG='-Wl,-x' |
| 4544 |
;; |
| 4545 |
esac |
| 4546 |
fi |
| 4547 |
# |
| 4548 |
# Was it ./configure --enable-debug ? |
| 4549 |
# |
| 4550 |
if test "$DEBUGBUILD" = yes ; then |
| 4551 |
# It was directly indicated by the user with --enable-debug. |
| 4552 |
SFLAG="" |
| 4553 |
if test "x$STRIP" = "x" ; then |
| 4554 |
STRIP=":" |
| 4555 |
else |
| 4556 |
STRIP=": #${STRIP}" |
| 4557 |
fi |
| 4558 |
else |
| 4559 |
# Not directly indicated, but maybe their CFLAGS hint at a debug build. |
| 4560 |
case "$CFLAGS" in |
| 4561 |
"-g"|"-g "*|*" -g"|*" -g "*|*"-g"0-9*) |
| 4562 |
# SFLAG="# $SFLAG" |
| 4563 |
SFLAG="" |
| 4564 |
if test "x$STRIP" = "x" ; then |
| 4565 |
STRIP=":" |
| 4566 |
else |
| 4567 |
STRIP=": #${STRIP}" |
| 4568 |
fi |
| 4569 |
;; |
| 4570 |
esac |
| 4571 |
fi |
| 4572 |
STRIPFLAG="$SFLAG" |
| 4573 |
|
| 4574 |
echo $ac_n "checking for object suffix""... $ac_c" 1>&6 |
| 4575 |
echo "configure:4576: checking for object suffix" >&5 |
| 4576 |
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then |
| 4577 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4578 |
else |
| 4579 |
rm -rf conftest* |
| 4580 |
if test "x${SYS}" = "xmacosx" ; then |
| 4581 |
ac_cv_objext="o" |
| 4582 |
else |
| 4583 |
echo 'int i = 1;' > conftest.$ac_ext |
| 4584 |
if { (eval echo configure:4585: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 4585 |
for ac_file in conftest.*; do |
| 4586 |
case $ac_file in |
| 4587 |
*.c) ;; |
| 4588 |
*) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;; |
| 4589 |
esac |
| 4590 |
done |
| 4591 |
else |
| 4592 |
{ echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; } |
| 4593 |
fi |
| 4594 |
fi |
| 4595 |
rm -rf conftest* |
| 4596 |
fi |
| 4597 |
|
| 4598 |
echo "$ac_t""$ac_cv_objext" 1>&6 |
| 4599 |
OBJEXT=$ac_cv_objext |
| 4600 |
ac_objext=$ac_cv_objext |
| 4601 |
|
| 4602 |
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 |
| 4603 |
echo "configure:4604: checking for Cygwin environment" >&5 |
| 4604 |
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then |
| 4605 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4606 |
else |
| 4607 |
cat > conftest.$ac_ext <<EOF |
| 4608 |
#line 4609 "configure" |
| 4609 |
#include "confdefs.h" |
| 4610 |
|
| 4611 |
int main(void) { |
| 4612 |
|
| 4613 |
#ifndef __CYGWIN__ |
| 4614 |
#define __CYGWIN__ __CYGWIN32__ |
| 4615 |
#endif |
| 4616 |
return __CYGWIN__; |
| 4617 |
; return 0; } |
| 4618 |
EOF |
| 4619 |
if { (eval echo configure:4620: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 4620 |
rm -rf conftest* |
| 4621 |
ac_cv_cygwin=yes |
| 4622 |
else |
| 4623 |
echo "configure: failed program was:" >&5 |
| 4624 |
cat conftest.$ac_ext >&5 |
| 4625 |
rm -rf conftest* |
| 4626 |
ac_cv_cygwin=no |
| 4627 |
fi |
| 4628 |
rm -rf conftest* |
| 4629 |
rm -rf conftest* |
| 4630 |
fi |
| 4631 |
|
| 4632 |
echo "$ac_t""$ac_cv_cygwin" 1>&6 |
| 4633 |
CYGWIN= |
| 4634 |
test "$ac_cv_cygwin" = yes && CYGWIN=yes |
| 4635 |
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 |
| 4636 |
echo "configure:4637: checking for mingw32 environment" >&5 |
| 4637 |
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then |
| 4638 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4639 |
else |
| 4640 |
cat > conftest.$ac_ext <<EOF |
| 4641 |
#line 4642 "configure" |
| 4642 |
#include "confdefs.h" |
| 4643 |
|
| 4644 |
int main(void) { |
| 4645 |
return __MINGW32__; |
| 4646 |
; return 0; } |
| 4647 |
EOF |
| 4648 |
if { (eval echo configure:4649: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 4649 |
rm -rf conftest* |
| 4650 |
ac_cv_mingw32=yes |
| 4651 |
else |
| 4652 |
echo "configure: failed program was:" >&5 |
| 4653 |
cat conftest.$ac_ext >&5 |
| 4654 |
rm -rf conftest* |
| 4655 |
ac_cv_mingw32=no |
| 4656 |
fi |
| 4657 |
rm -rf conftest* |
| 4658 |
rm -rf conftest* |
| 4659 |
fi |
| 4660 |
|
| 4661 |
echo "$ac_t""$ac_cv_mingw32" 1>&6 |
| 4662 |
MINGW32= |
| 4663 |
test "$ac_cv_mingw32" = yes && MINGW32=yes |
| 4664 |
|
| 4665 |
|
| 4666 |
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 |
| 4667 |
echo "configure:4668: checking for executable suffix" >&5 |
| 4668 |
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then |
| 4669 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4670 |
else |
| 4671 |
if test "$CYGWIN" = yes || test "$MINGW32" = yes; then |
| 4672 |
ac_cv_exeext=.exe |
| 4673 |
elif test "x${SYS}" = "xmacosx" ; then |
| 4674 |
ac_cv_exeext="" |
| 4675 |
else |
| 4676 |
rm -rf conftest* |
| 4677 |
echo 'int main () { return 0; }' > conftest.$ac_ext |
| 4678 |
ac_cv_exeext= |
| 4679 |
if { (eval echo configure:4680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
| 4680 |
for file in conftest.*; do |
| 4681 |
case $file in |
| 4682 |
*.c | *.o | *.obj) ;; |
| 4683 |
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; |
| 4684 |
esac |
| 4685 |
done |
| 4686 |
else |
| 4687 |
{ echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } |
| 4688 |
fi |
| 4689 |
rm -rf conftest* |
| 4690 |
test x"${ac_cv_exeext}" = x && ac_cv_exeext=no |
| 4691 |
fi |
| 4692 |
fi |
| 4693 |
|
| 4694 |
EXEEXT="" |
| 4695 |
test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} |
| 4696 |
echo "$ac_t""${ac_cv_exeext}" 1>&6 |
| 4697 |
ac_exeext=$EXEEXT |
| 4698 |
|
| 4699 |
|
| 4700 |
# Get first 127 chars of all uname information. Some folks have |
| 4701 |
# way too much stuff there, so grab only the first 127. |
| 4702 |
unam=`uname -a 2>/dev/null | cut -c1-127 | sed 's-"-\\"-g'` |
| 4703 |
if test "$unam" != "" ; then |
| 4704 |
cat >> confdefs.h <<EOF |
| 4705 |
#define UNAME "$unam" |
| 4706 |
EOF |
| 4707 |
|
| 4708 |
fi |
| 4709 |
|
| 4710 |
|
| 4711 |
if test "${SYS-sunos}" = sunos ; then |
| 4712 |
echo $ac_n "checking for System V compatibility directories""... $ac_c" 1>&6 |
| 4713 |
echo "configure:4714: checking for System V compatibility directories" >&5 |
| 4714 |
echo "$ac_t""" 1>&6 |
| 4715 |
|
| 4716 |
incdir=""/usr/5include"" |
| 4717 |
echo "wi_extra_idir $incdir" 1>&5 |
| 4718 |
if test -r "$incdir" ; then |
| 4719 |
case "$CPPFLAGS" in |
| 4720 |
*${incdir}*) |
| 4721 |
echo " + already had $incdir" 1>&5 |
| 4722 |
;; |
| 4723 |
*) |
| 4724 |
if test "$CPPFLAGS" = "" ; then |
| 4725 |
CPPFLAGS="-I$incdir" |
| 4726 |
else |
| 4727 |
CPPFLAGS="$CPPFLAGS -I$incdir" |
| 4728 |
fi |
| 4729 |
echo " + found $incdir" 1>&5 |
| 4730 |
;; |
| 4731 |
esac |
| 4732 |
fi |
| 4733 |
|
| 4734 |
|
| 4735 |
libdir=""/usr/5lib"" |
| 4736 |
echo "wi_extra_ldir $libdir" 1>&5 |
| 4737 |
if test -r "$libdir" ; then |
| 4738 |
case "$LDFLAGS" in |
| 4739 |
*${libdir}*) |
| 4740 |
echo " + already had $libdir" 1>&5 |
| 4741 |
;; |
| 4742 |
*) |
| 4743 |
if test "$LDFLAGS" = "" ; then |
| 4744 |
LDFLAGS="-L$libdir" |
| 4745 |
else |
| 4746 |
LDFLAGS="$LDFLAGS -L$libdir" |
| 4747 |
fi |
| 4748 |
echo " + found $libdir" 1>&5 |
| 4749 |
;; |
| 4750 |
esac |
| 4751 |
fi |
| 4752 |
|
| 4753 |
fi |
| 4754 |
|
| 4755 |
if test "${prefix-NONE}" != "NONE" && test "$prefix" != "/usr/local" && test "$prefix" != "/usr"; then |
| 4756 |
cat >> confdefs.h <<EOF |
| 4757 |
#define PREFIX_BINDIR "$prefix/bin" |
| 4758 |
EOF |
| 4759 |
|
| 4760 |
fi |
| 4761 |
|
| 4762 |
|
| 4763 |
|
| 4764 |
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
| 4765 |
echo "configure:4766: checking for ANSI C header files" >&5 |
| 4766 |
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
| 4767 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4768 |
else |
| 4769 |
cat > conftest.$ac_ext <<EOF |
| 4770 |
#line 4771 "configure" |
| 4771 |
#include "confdefs.h" |
| 4772 |
#include <stdlib.h> |
| 4773 |
#include <stdarg.h> |
| 4774 |
#include <string.h> |
| 4775 |
#include <float.h> |
| 4776 |
EOF |
| 4777 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 4778 |
{ (eval echo configure:4779: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 4779 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 4780 |
if test -z "$ac_err"; then |
| 4781 |
rm -rf conftest* |
| 4782 |
ac_cv_header_stdc=yes |
| 4783 |
else |
| 4784 |
echo "$ac_err" >&5 |
| 4785 |
echo "configure: failed program was:" >&5 |
| 4786 |
cat conftest.$ac_ext >&5 |
| 4787 |
rm -rf conftest* |
| 4788 |
ac_cv_header_stdc=no |
| 4789 |
fi |
| 4790 |
rm -rf conftest* |
| 4791 |
|
| 4792 |
if test $ac_cv_header_stdc = yes; then |
| 4793 |
# SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 4794 |
cat > conftest.$ac_ext <<EOF |
| 4795 |
#line 4796 "configure" |
| 4796 |
#include "confdefs.h" |
| 4797 |
#include <string.h> |
| 4798 |
EOF |
| 4799 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4800 |
egrep "memchr" >/dev/null 2>&1; then |
| 4801 |
: |
| 4802 |
else |
| 4803 |
rm -rf conftest* |
| 4804 |
ac_cv_header_stdc=no |
| 4805 |
fi |
| 4806 |
rm -rf conftest* |
| 4807 |
|
| 4808 |
fi |
| 4809 |
|
| 4810 |
if test $ac_cv_header_stdc = yes; then |
| 4811 |
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 4812 |
cat > conftest.$ac_ext <<EOF |
| 4813 |
#line 4814 "configure" |
| 4814 |
#include "confdefs.h" |
| 4815 |
#include <stdlib.h> |
| 4816 |
EOF |
| 4817 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4818 |
egrep "free" >/dev/null 2>&1; then |
| 4819 |
: |
| 4820 |
else |
| 4821 |
rm -rf conftest* |
| 4822 |
ac_cv_header_stdc=no |
| 4823 |
fi |
| 4824 |
rm -rf conftest* |
| 4825 |
|
| 4826 |
fi |
| 4827 |
|
| 4828 |
if test $ac_cv_header_stdc = yes; then |
| 4829 |
# /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 4830 |
if test "$cross_compiling" = yes; then |
| 4831 |
: |
| 4832 |
else |
| 4833 |
cat > conftest.$ac_ext <<EOF |
| 4834 |
#line 4835 "configure" |
| 4835 |
#include "confdefs.h" |
| 4836 |
#include <ctype.h> |
| 4837 |
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 4838 |
#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 4839 |
#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 4840 |
int main () { int i; for (i = 0; i < 256; i++) |
| 4841 |
if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
| 4842 |
exit (0); } |
| 4843 |
|
| 4844 |
EOF |
| 4845 |
if { (eval echo configure:4846: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 4846 |
then |
| 4847 |
: |
| 4848 |
else |
| 4849 |
echo "configure: failed program was:" >&5 |
| 4850 |
cat conftest.$ac_ext >&5 |
| 4851 |
rm -fr conftest* |
| 4852 |
ac_cv_header_stdc=no |
| 4853 |
fi |
| 4854 |
rm -fr conftest* |
| 4855 |
fi |
| 4856 |
|
| 4857 |
fi |
| 4858 |
fi |
| 4859 |
|
| 4860 |
echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
| 4861 |
if test $ac_cv_header_stdc = yes; then |
| 4862 |
cat >> confdefs.h <<\EOF |
| 4863 |
#define STDC_HEADERS 1 |
| 4864 |
EOF |
| 4865 |
|
| 4866 |
fi |
| 4867 |
|
| 4868 |
for ac_hdr in arpa/nameser.h gnu/libc-version.h locale.h net/errno.h nserve.h resolv.h sgtty.h string.h strings.h sys/id.h sys/ioctl.h syslog.h sys/sendfile.h sys/socket.h sys/time.h sys/types.h sys/utsname.h sys/systeminfo.h termio.h termios.h time.h utime.h unistd.h gnu/libc-version.h |
| 4869 |
do |
| 4870 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 4871 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 4872 |
echo "configure:4873: checking for $ac_hdr" >&5 |
| 4873 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 4874 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4875 |
else |
| 4876 |
cat > conftest.$ac_ext <<EOF |
| 4877 |
#line 4878 "configure" |
| 4878 |
#include "confdefs.h" |
| 4879 |
#include <$ac_hdr> |
| 4880 |
EOF |
| 4881 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 4882 |
{ (eval echo configure:4883: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 4883 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 4884 |
if test -z "$ac_err"; then |
| 4885 |
rm -rf conftest* |
| 4886 |
eval "ac_cv_header_$ac_safe=yes" |
| 4887 |
else |
| 4888 |
echo "$ac_err" >&5 |
| 4889 |
echo "configure: failed program was:" >&5 |
| 4890 |
cat conftest.$ac_ext >&5 |
| 4891 |
rm -rf conftest* |
| 4892 |
eval "ac_cv_header_$ac_safe=no" |
| 4893 |
fi |
| 4894 |
rm -rf conftest* |
| 4895 |
fi |
| 4896 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 4897 |
echo "$ac_t""yes" 1>&6 |
| 4898 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 4899 |
cat >> confdefs.h <<EOF |
| 4900 |
#define $ac_tr_hdr 1 |
| 4901 |
EOF |
| 4902 |
|
| 4903 |
else |
| 4904 |
echo "$ac_t""no" 1>&6 |
| 4905 |
fi |
| 4906 |
done |
| 4907 |
|
| 4908 |
echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
| 4909 |
echo "configure:4910: checking whether time.h and sys/time.h may both be included" >&5 |
| 4910 |
if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
| 4911 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4912 |
else |
| 4913 |
cat > conftest.$ac_ext <<EOF |
| 4914 |
#line 4915 "configure" |
| 4915 |
#include "confdefs.h" |
| 4916 |
#include <sys/types.h> |
| 4917 |
#include <sys/time.h> |
| 4918 |
#include <time.h> |
| 4919 |
int main(void) { |
| 4920 |
struct tm *tp; |
| 4921 |
; return 0; } |
| 4922 |
EOF |
| 4923 |
if { (eval echo configure:4924: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 4924 |
rm -rf conftest* |
| 4925 |
ac_cv_header_time=yes |
| 4926 |
else |
| 4927 |
echo "configure: failed program was:" >&5 |
| 4928 |
cat conftest.$ac_ext >&5 |
| 4929 |
rm -rf conftest* |
| 4930 |
ac_cv_header_time=no |
| 4931 |
fi |
| 4932 |
rm -rf conftest* |
| 4933 |
fi |
| 4934 |
|
| 4935 |
echo "$ac_t""$ac_cv_header_time" 1>&6 |
| 4936 |
if test $ac_cv_header_time = yes; then |
| 4937 |
cat >> confdefs.h <<\EOF |
| 4938 |
#define TIME_WITH_SYS_TIME 1 |
| 4939 |
EOF |
| 4940 |
|
| 4941 |
fi |
| 4942 |
|
| 4943 |
|
| 4944 |
if test "x$want_unix_domain_sockets" != xno ; then |
| 4945 |
|
| 4946 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 4947 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_UNIX_DOMAIN_SOCKETS." 1>&2; exit 1; } |
| 4948 |
fi |
| 4949 |
|
| 4950 |
for ac_hdr in sys/un.h |
| 4951 |
do |
| 4952 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 4953 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 4954 |
echo "configure:4955: checking for $ac_hdr" >&5 |
| 4955 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 4956 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4957 |
else |
| 4958 |
cat > conftest.$ac_ext <<EOF |
| 4959 |
#line 4960 "configure" |
| 4960 |
#include "confdefs.h" |
| 4961 |
#include <$ac_hdr> |
| 4962 |
EOF |
| 4963 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 4964 |
{ (eval echo configure:4965: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 4965 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 4966 |
if test -z "$ac_err"; then |
| 4967 |
rm -rf conftest* |
| 4968 |
eval "ac_cv_header_$ac_safe=yes" |
| 4969 |
else |
| 4970 |
echo "$ac_err" >&5 |
| 4971 |
echo "configure: failed program was:" >&5 |
| 4972 |
cat conftest.$ac_ext >&5 |
| 4973 |
rm -rf conftest* |
| 4974 |
eval "ac_cv_header_$ac_safe=no" |
| 4975 |
fi |
| 4976 |
rm -rf conftest* |
| 4977 |
fi |
| 4978 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 4979 |
echo "$ac_t""yes" 1>&6 |
| 4980 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 4981 |
cat >> confdefs.h <<EOF |
| 4982 |
#define $ac_tr_hdr 1 |
| 4983 |
EOF |
| 4984 |
|
| 4985 |
else |
| 4986 |
echo "$ac_t""no" 1>&6 |
| 4987 |
fi |
| 4988 |
done |
| 4989 |
|
| 4990 |
echo $ac_n "checking for UNIX domain sockets""... $ac_c" 1>&6 |
| 4991 |
echo "configure:4992: checking for UNIX domain sockets" >&5 |
| 4992 |
if eval "test \"`echo '$''{'wi_cv_unix_domain_sockets'+set}'`\" = set"; then |
| 4993 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 4994 |
else |
| 4995 |
|
| 4996 |
if test "$cross_compiling" = yes; then |
| 4997 |
|
| 4998 |
# action if cross-compiling, guess |
| 4999 |
guess="(guessing) " |
| 5000 |
wi_cv_unix_domain_sockets=yes |
| 5001 |
|
| 5002 |
else |
| 5003 |
cat > conftest.$ac_ext <<EOF |
| 5004 |
#line 5005 "configure" |
| 5005 |
#include "confdefs.h" |
| 5006 |
|
| 5007 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 5008 |
# define _ALL_SOURCE 1 |
| 5009 |
#endif |
| 5010 |
#ifdef HAVE_UNISTD_H |
| 5011 |
# include <unistd.h> |
| 5012 |
#endif |
| 5013 |
#include <sys/types.h> |
| 5014 |
#include <sys/socket.h> |
| 5015 |
#ifdef HAVE_SYS_UN_H |
| 5016 |
#include <sys/un.h> |
| 5017 |
#endif |
| 5018 |
#ifdef HAVE_STDLIB_H |
| 5019 |
# include <stdlib.h> |
| 5020 |
#endif |
| 5021 |
|
| 5022 |
int main(void) |
| 5023 |
{ |
| 5024 |
int sfd; |
| 5025 |
|
| 5026 |
sfd = socket(AF_UNIX, SOCK_STREAM, 0); |
| 5027 |
if (sfd < 0) |
| 5028 |
exit(1); /* do not have UNIX domain sockets */ |
| 5029 |
close(sfd); |
| 5030 |
exit(0); /* do have UNIX domain sockets */ |
| 5031 |
} |
| 5032 |
EOF |
| 5033 |
if { (eval echo configure:5034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 5034 |
then |
| 5035 |
|
| 5036 |
# action if true |
| 5037 |
guess="" |
| 5038 |
wi_cv_unix_domain_sockets=yes |
| 5039 |
|
| 5040 |
else |
| 5041 |
echo "configure: failed program was:" >&5 |
| 5042 |
cat conftest.$ac_ext >&5 |
| 5043 |
rm -fr conftest* |
| 5044 |
|
| 5045 |
# action if false |
| 5046 |
guess="" |
| 5047 |
wi_cv_unix_domain_sockets=no |
| 5048 |
|
| 5049 |
fi |
| 5050 |
rm -fr conftest* |
| 5051 |
fi |
| 5052 |
|
| 5053 |
|
| 5054 |
fi |
| 5055 |
|
| 5056 |
echo "$ac_t""$guess$wi_cv_unix_domain_sockets" 1>&6 |
| 5057 |
guess="" |
| 5058 |
|
| 5059 |
if test "x$wi_cv_unix_domain_sockets" = xyes ; then |
| 5060 |
cat >> confdefs.h <<\EOF |
| 5061 |
#define HAVE_UNIX_DOMAIN_SOCKETS 1 |
| 5062 |
EOF |
| 5063 |
|
| 5064 |
fi |
| 5065 |
|
| 5066 |
echo $ac_n "checking for sun_len field in struct sockaddr_un""... $ac_c" 1>&6 |
| 5067 |
echo "configure:5068: checking for sun_len field in struct sockaddr_un" >&5 |
| 5068 |
if eval "test \"`echo '$''{'wi_cv_sockaddr_un_sun_len'+set}'`\" = set"; then |
| 5069 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5070 |
else |
| 5071 |
|
| 5072 |
cat > conftest.$ac_ext <<EOF |
| 5073 |
#line 5074 "configure" |
| 5074 |
#include "confdefs.h" |
| 5075 |
|
| 5076 |
/* includes */ |
| 5077 |
#include <unistd.h> |
| 5078 |
#ifdef HAVE_STDLIB_H |
| 5079 |
# include <stdlib.h> |
| 5080 |
#endif |
| 5081 |
#include <sys/types.h> |
| 5082 |
#include <sys/uio.h> |
| 5083 |
#include <sys/socket.h> |
| 5084 |
#include <sys/un.h> |
| 5085 |
|
| 5086 |
int main(void) { |
| 5087 |
|
| 5088 |
struct sockaddr_un uaddr; |
| 5089 |
|
| 5090 |
uaddr.sun_len = strlen("/tmp/test.sock"); |
| 5091 |
exit(((int) uaddr.sun_len); /* bogus code, of course. */ |
| 5092 |
|
| 5093 |
; return 0; } |
| 5094 |
EOF |
| 5095 |
if { (eval echo configure:5096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5096 |
rm -rf conftest* |
| 5097 |
|
| 5098 |
wi_cv_sockaddr_un_sun_len=yes |
| 5099 |
|
| 5100 |
else |
| 5101 |
echo "configure: failed program was:" >&5 |
| 5102 |
cat conftest.$ac_ext >&5 |
| 5103 |
rm -rf conftest* |
| 5104 |
|
| 5105 |
wi_cv_sockaddr_un_sun_len=no |
| 5106 |
|
| 5107 |
fi |
| 5108 |
rm -rf conftest* |
| 5109 |
|
| 5110 |
fi |
| 5111 |
|
| 5112 |
echo "$ac_t""$wi_cv_sockaddr_un_sun_len" 1>&6 |
| 5113 |
if test "$wi_cv_sockaddr_un_sun_len" = yes ; then |
| 5114 |
cat >> confdefs.h <<\EOF |
| 5115 |
#define HAVE_SOCKADDR_UN_SUN_LEN 1 |
| 5116 |
EOF |
| 5117 |
|
| 5118 |
fi |
| 5119 |
|
| 5120 |
fi |
| 5121 |
|
| 5122 |
SIO_OBJS_U='' |
| 5123 |
SIO_SOBJS_U='' |
| 5124 |
if test "$wi_cv_unix_domain_sockets" = yes ; then |
| 5125 |
SIO_OBJS_U='$(OBJS_U) ' |
| 5126 |
SIO_SOBJS_U='$(SOBJS_U) ' |
| 5127 |
fi |
| 5128 |
|
| 5129 |
|
| 5130 |
|
| 5131 |
|
| 5132 |
|
| 5133 |
|
| 5134 |
# Mostly for SunOS 4 -- needs to come first because other libs depend on it |
| 5135 |
|
| 5136 |
echo $ac_n "checking for strerror""... $ac_c" 1>&6 |
| 5137 |
echo "configure:5138: checking for strerror" >&5 |
| 5138 |
if eval "test \"`echo '$''{'ac_cv_func_strerror'+set}'`\" = set"; then |
| 5139 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5140 |
else |
| 5141 |
cat > conftest.$ac_ext <<EOF |
| 5142 |
#line 5143 "configure" |
| 5143 |
#include "confdefs.h" |
| 5144 |
/* System header to define __stub macros and hopefully few prototypes, |
| 5145 |
which can conflict with char strerror(); below. */ |
| 5146 |
#include <assert.h> |
| 5147 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5148 |
/* We use char because int might match the return type of a gcc2 |
| 5149 |
builtin and then its argument prototype would still apply. */ |
| 5150 |
char strerror(); |
| 5151 |
|
| 5152 |
int main(void) { |
| 5153 |
|
| 5154 |
/* The GNU C library defines this for functions which it implements |
| 5155 |
to always fail with ENOSYS. Some functions are actually named |
| 5156 |
something starting with __ and the normal name is an alias. */ |
| 5157 |
#if defined (__stub_strerror) || defined (__stub___strerror) |
| 5158 |
choke me |
| 5159 |
#else |
| 5160 |
strerror(); |
| 5161 |
#endif |
| 5162 |
|
| 5163 |
; return 0; } |
| 5164 |
EOF |
| 5165 |
if { (eval echo configure:5166: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5166 |
rm -rf conftest* |
| 5167 |
eval "ac_cv_func_strerror=yes" |
| 5168 |
else |
| 5169 |
echo "configure: failed program was:" >&5 |
| 5170 |
cat conftest.$ac_ext >&5 |
| 5171 |
rm -rf conftest* |
| 5172 |
eval "ac_cv_func_strerror=no" |
| 5173 |
fi |
| 5174 |
rm -rf conftest* |
| 5175 |
fi |
| 5176 |
|
| 5177 |
if eval "test \"`echo '$ac_cv_func_'strerror`\" = yes"; then |
| 5178 |
echo "$ac_t""yes" 1>&6 |
| 5179 |
a=yes |
| 5180 |
else |
| 5181 |
echo "$ac_t""no" 1>&6 |
| 5182 |
a=no |
| 5183 |
fi |
| 5184 |
|
| 5185 |
if test "$a" = no ; then |
| 5186 |
# Not in libc, try lib44bsd. |
| 5187 |
echo $ac_n "checking for strerror in -l44bsd""... $ac_c" 1>&6 |
| 5188 |
echo "configure:5189: checking for strerror in -l44bsd" >&5 |
| 5189 |
ac_lib_var=`echo 44bsd'_'strerror | sed 'y%./+-%__p_%'` |
| 5190 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5191 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5192 |
else |
| 5193 |
ac_save_LIBS="$LIBS" |
| 5194 |
LIBS="-l44bsd $LIBS" |
| 5195 |
cat > conftest.$ac_ext <<EOF |
| 5196 |
#line 5197 "configure" |
| 5197 |
#include "confdefs.h" |
| 5198 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5199 |
/* We use char because int might match the return type of a gcc2 |
| 5200 |
builtin and then its argument prototype would still apply. */ |
| 5201 |
char strerror(); |
| 5202 |
|
| 5203 |
int main(void) { |
| 5204 |
strerror() |
| 5205 |
; return 0; } |
| 5206 |
EOF |
| 5207 |
if { (eval echo configure:5208: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5208 |
rm -rf conftest* |
| 5209 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5210 |
else |
| 5211 |
echo "configure: failed program was:" >&5 |
| 5212 |
cat conftest.$ac_ext >&5 |
| 5213 |
rm -rf conftest* |
| 5214 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5215 |
fi |
| 5216 |
rm -rf conftest* |
| 5217 |
LIBS="$ac_save_LIBS" |
| 5218 |
|
| 5219 |
fi |
| 5220 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5221 |
echo "$ac_t""yes" 1>&6 |
| 5222 |
ac_tr_lib=HAVE_LIB`echo 44bsd | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 5223 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 5224 |
cat >> confdefs.h <<EOF |
| 5225 |
#define $ac_tr_lib 1 |
| 5226 |
EOF |
| 5227 |
|
| 5228 |
LIBS="-l44bsd $LIBS" |
| 5229 |
|
| 5230 |
else |
| 5231 |
echo "$ac_t""no" 1>&6 |
| 5232 |
fi |
| 5233 |
|
| 5234 |
fi |
| 5235 |
|
| 5236 |
|
| 5237 |
|
| 5238 |
echo $ac_n "checking for socket""... $ac_c" 1>&6 |
| 5239 |
echo "configure:5240: checking for socket" >&5 |
| 5240 |
if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then |
| 5241 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5242 |
else |
| 5243 |
cat > conftest.$ac_ext <<EOF |
| 5244 |
#line 5245 "configure" |
| 5245 |
#include "confdefs.h" |
| 5246 |
/* System header to define __stub macros and hopefully few prototypes, |
| 5247 |
which can conflict with char socket(); below. */ |
| 5248 |
#include <assert.h> |
| 5249 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5250 |
/* We use char because int might match the return type of a gcc2 |
| 5251 |
builtin and then its argument prototype would still apply. */ |
| 5252 |
char socket(); |
| 5253 |
|
| 5254 |
int main(void) { |
| 5255 |
|
| 5256 |
/* The GNU C library defines this for functions which it implements |
| 5257 |
to always fail with ENOSYS. Some functions are actually named |
| 5258 |
something starting with __ and the normal name is an alias. */ |
| 5259 |
#if defined (__stub_socket) || defined (__stub___socket) |
| 5260 |
choke me |
| 5261 |
#else |
| 5262 |
socket(); |
| 5263 |
#endif |
| 5264 |
|
| 5265 |
; return 0; } |
| 5266 |
EOF |
| 5267 |
if { (eval echo configure:5268: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5268 |
rm -rf conftest* |
| 5269 |
eval "ac_cv_func_socket=yes" |
| 5270 |
else |
| 5271 |
echo "configure: failed program was:" >&5 |
| 5272 |
cat conftest.$ac_ext >&5 |
| 5273 |
rm -rf conftest* |
| 5274 |
eval "ac_cv_func_socket=no" |
| 5275 |
fi |
| 5276 |
rm -rf conftest* |
| 5277 |
fi |
| 5278 |
|
| 5279 |
if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then |
| 5280 |
echo "$ac_t""yes" 1>&6 |
| 5281 |
a=yes |
| 5282 |
else |
| 5283 |
echo "$ac_t""no" 1>&6 |
| 5284 |
a=no |
| 5285 |
fi |
| 5286 |
|
| 5287 |
if test "$a" = no ; then |
| 5288 |
# Not in libc, try libsocket. |
| 5289 |
echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 |
| 5290 |
echo "configure:5291: checking for socket in -lsocket" >&5 |
| 5291 |
ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'` |
| 5292 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5293 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5294 |
else |
| 5295 |
ac_save_LIBS="$LIBS" |
| 5296 |
LIBS="-lsocket $LIBS" |
| 5297 |
cat > conftest.$ac_ext <<EOF |
| 5298 |
#line 5299 "configure" |
| 5299 |
#include "confdefs.h" |
| 5300 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5301 |
/* We use char because int might match the return type of a gcc2 |
| 5302 |
builtin and then its argument prototype would still apply. */ |
| 5303 |
char socket(); |
| 5304 |
|
| 5305 |
int main(void) { |
| 5306 |
socket() |
| 5307 |
; return 0; } |
| 5308 |
EOF |
| 5309 |
if { (eval echo configure:5310: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5310 |
rm -rf conftest* |
| 5311 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5312 |
else |
| 5313 |
echo "configure: failed program was:" >&5 |
| 5314 |
cat conftest.$ac_ext >&5 |
| 5315 |
rm -rf conftest* |
| 5316 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5317 |
fi |
| 5318 |
rm -rf conftest* |
| 5319 |
LIBS="$ac_save_LIBS" |
| 5320 |
|
| 5321 |
fi |
| 5322 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5323 |
echo "$ac_t""yes" 1>&6 |
| 5324 |
ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 5325 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 5326 |
cat >> confdefs.h <<EOF |
| 5327 |
#define $ac_tr_lib 1 |
| 5328 |
EOF |
| 5329 |
|
| 5330 |
LIBS="-lsocket $LIBS" |
| 5331 |
|
| 5332 |
else |
| 5333 |
echo "$ac_t""no" 1>&6 |
| 5334 |
fi |
| 5335 |
|
| 5336 |
fi |
| 5337 |
|
| 5338 |
|
| 5339 |
if test "$SYS" = unixware ; then |
| 5340 |
case "$OS" in |
| 5341 |
unixware2*) |
| 5342 |
# So far, only UnixWare needs this. |
| 5343 |
echo $ac_n "checking for syslog in -lgen""... $ac_c" 1>&6 |
| 5344 |
echo "configure:5345: checking for syslog in -lgen" >&5 |
| 5345 |
ac_lib_var=`echo gen'_'syslog | sed 'y%./+-%__p_%'` |
| 5346 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5347 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5348 |
else |
| 5349 |
ac_save_LIBS="$LIBS" |
| 5350 |
LIBS="-lgen $LIBS" |
| 5351 |
cat > conftest.$ac_ext <<EOF |
| 5352 |
#line 5353 "configure" |
| 5353 |
#include "confdefs.h" |
| 5354 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5355 |
/* We use char because int might match the return type of a gcc2 |
| 5356 |
builtin and then its argument prototype would still apply. */ |
| 5357 |
char syslog(); |
| 5358 |
|
| 5359 |
int main(void) { |
| 5360 |
syslog() |
| 5361 |
; return 0; } |
| 5362 |
EOF |
| 5363 |
if { (eval echo configure:5364: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5364 |
rm -rf conftest* |
| 5365 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5366 |
else |
| 5367 |
echo "configure: failed program was:" >&5 |
| 5368 |
cat conftest.$ac_ext >&5 |
| 5369 |
rm -rf conftest* |
| 5370 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5371 |
fi |
| 5372 |
rm -rf conftest* |
| 5373 |
LIBS="$ac_save_LIBS" |
| 5374 |
|
| 5375 |
fi |
| 5376 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5377 |
echo "$ac_t""yes" 1>&6 |
| 5378 |
ac_tr_lib=HAVE_LIB`echo gen | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 5379 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 5380 |
cat >> confdefs.h <<EOF |
| 5381 |
#define $ac_tr_lib 1 |
| 5382 |
EOF |
| 5383 |
|
| 5384 |
LIBS="-lgen $LIBS" |
| 5385 |
|
| 5386 |
else |
| 5387 |
echo "$ac_t""no" 1>&6 |
| 5388 |
fi |
| 5389 |
|
| 5390 |
|
| 5391 |
if test -f /usr/ucblib/libucb.a ; then |
| 5392 |
LDFLAGS="$LDFLAGS -L/usr/ucblib" |
| 5393 |
LIBS="$LIBS -lucb" |
| 5394 |
fi |
| 5395 |
if test -f /usr/include/unistd.h ; then |
| 5396 |
ac_cv_header_unistd_h=yes |
| 5397 |
fi |
| 5398 |
|
| 5399 |
# UnixWare 2 needs both lsocket and lnsl, and configure |
| 5400 |
# script won't detect this condition properly because |
| 5401 |
# the libraries are interdependent. |
| 5402 |
# |
| 5403 |
LIBS="$LIBS -lsocket -lnsl" |
| 5404 |
|
| 5405 |
# Now look for socket() |
| 5406 |
# |
| 5407 |
# AC_CHECK_FUNC(socket,[a=yes],[a=no]) |
| 5408 |
# |
| 5409 |
echo $ac_n "checking for socket""... $ac_c" 1>&6 |
| 5410 |
echo "configure:5411: checking for socket" >&5 |
| 5411 |
if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then |
| 5412 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5413 |
else |
| 5414 |
cat > conftest.$ac_ext <<EOF |
| 5415 |
#line 5416 "configure" |
| 5416 |
#include "confdefs.h" |
| 5417 |
/* System header to define __stub macros and hopefully few prototypes, |
| 5418 |
which can conflict with char socket(); below. */ |
| 5419 |
#include <assert.h> |
| 5420 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5421 |
/* We use char because int might match the return type of a gcc2 |
| 5422 |
builtin and then its argument prototype would still apply. */ |
| 5423 |
char socket(); |
| 5424 |
|
| 5425 |
int main(void) { |
| 5426 |
|
| 5427 |
/* The GNU C library defines this for functions which it implements |
| 5428 |
to always fail with ENOSYS. Some functions are actually named |
| 5429 |
something starting with __ and the normal name is an alias. */ |
| 5430 |
#if defined (__stub_socket) || defined (__stub___socket) |
| 5431 |
choke me |
| 5432 |
#else |
| 5433 |
socket(); |
| 5434 |
#endif |
| 5435 |
|
| 5436 |
; return 0; } |
| 5437 |
EOF |
| 5438 |
if { (eval echo configure:5439: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5439 |
rm -rf conftest* |
| 5440 |
eval "ac_cv_func_socket=yes" |
| 5441 |
else |
| 5442 |
echo "configure: failed program was:" >&5 |
| 5443 |
cat conftest.$ac_ext >&5 |
| 5444 |
rm -rf conftest* |
| 5445 |
eval "ac_cv_func_socket=no" |
| 5446 |
fi |
| 5447 |
rm -rf conftest* |
| 5448 |
fi |
| 5449 |
|
| 5450 |
if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then |
| 5451 |
echo "$ac_t""yes" 1>&6 |
| 5452 |
a=yes |
| 5453 |
else |
| 5454 |
echo "$ac_t""no" 1>&6 |
| 5455 |
a=no |
| 5456 |
fi |
| 5457 |
|
| 5458 |
;; |
| 5459 |
*) |
| 5460 |
;; |
| 5461 |
esac |
| 5462 |
fi |
| 5463 |
|
| 5464 |
|
| 5465 |
|
| 5466 |
|
| 5467 |
case "$OS" in |
| 5468 |
hpux1123456789*) |
| 5469 |
# HP-UX 11 uses NSL for YP services |
| 5470 |
echo $ac_n "checking for getpwent in -lnsl""... $ac_c" 1>&6 |
| 5471 |
echo "configure:5472: checking for getpwent in -lnsl" >&5 |
| 5472 |
ac_lib_var=`echo nsl'_'getpwent | sed 'y%./+-%__p_%'` |
| 5473 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5474 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5475 |
else |
| 5476 |
ac_save_LIBS="$LIBS" |
| 5477 |
LIBS="-lnsl $LIBS" |
| 5478 |
cat > conftest.$ac_ext <<EOF |
| 5479 |
#line 5480 "configure" |
| 5480 |
#include "confdefs.h" |
| 5481 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5482 |
/* We use char because int might match the return type of a gcc2 |
| 5483 |
builtin and then its argument prototype would still apply. */ |
| 5484 |
char getpwent(); |
| 5485 |
|
| 5486 |
int main(void) { |
| 5487 |
getpwent() |
| 5488 |
; return 0; } |
| 5489 |
EOF |
| 5490 |
if { (eval echo configure:5491: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5491 |
rm -rf conftest* |
| 5492 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5493 |
else |
| 5494 |
echo "configure: failed program was:" >&5 |
| 5495 |
cat conftest.$ac_ext >&5 |
| 5496 |
rm -rf conftest* |
| 5497 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5498 |
fi |
| 5499 |
rm -rf conftest* |
| 5500 |
LIBS="$ac_save_LIBS" |
| 5501 |
|
| 5502 |
fi |
| 5503 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5504 |
echo "$ac_t""yes" 1>&6 |
| 5505 |
ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 5506 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 5507 |
cat >> confdefs.h <<EOF |
| 5508 |
#define $ac_tr_lib 1 |
| 5509 |
EOF |
| 5510 |
|
| 5511 |
LIBS="-lnsl $LIBS" |
| 5512 |
|
| 5513 |
else |
| 5514 |
echo "$ac_t""no" 1>&6 |
| 5515 |
fi |
| 5516 |
|
| 5517 |
;; |
| 5518 |
|
| 5519 |
*) |
| 5520 |
echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 |
| 5521 |
echo "configure:5522: checking for gethostbyname" >&5 |
| 5522 |
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then |
| 5523 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5524 |
else |
| 5525 |
cat > conftest.$ac_ext <<EOF |
| 5526 |
#line 5527 "configure" |
| 5527 |
#include "confdefs.h" |
| 5528 |
/* System header to define __stub macros and hopefully few prototypes, |
| 5529 |
which can conflict with char gethostbyname(); below. */ |
| 5530 |
#include <assert.h> |
| 5531 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5532 |
/* We use char because int might match the return type of a gcc2 |
| 5533 |
builtin and then its argument prototype would still apply. */ |
| 5534 |
char gethostbyname(); |
| 5535 |
|
| 5536 |
int main(void) { |
| 5537 |
|
| 5538 |
/* The GNU C library defines this for functions which it implements |
| 5539 |
to always fail with ENOSYS. Some functions are actually named |
| 5540 |
something starting with __ and the normal name is an alias. */ |
| 5541 |
#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) |
| 5542 |
choke me |
| 5543 |
#else |
| 5544 |
gethostbyname(); |
| 5545 |
#endif |
| 5546 |
|
| 5547 |
; return 0; } |
| 5548 |
EOF |
| 5549 |
if { (eval echo configure:5550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5550 |
rm -rf conftest* |
| 5551 |
eval "ac_cv_func_gethostbyname=yes" |
| 5552 |
else |
| 5553 |
echo "configure: failed program was:" >&5 |
| 5554 |
cat conftest.$ac_ext >&5 |
| 5555 |
rm -rf conftest* |
| 5556 |
eval "ac_cv_func_gethostbyname=no" |
| 5557 |
fi |
| 5558 |
rm -rf conftest* |
| 5559 |
fi |
| 5560 |
|
| 5561 |
if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then |
| 5562 |
echo "$ac_t""yes" 1>&6 |
| 5563 |
a=yes |
| 5564 |
else |
| 5565 |
echo "$ac_t""no" 1>&6 |
| 5566 |
a=no |
| 5567 |
fi |
| 5568 |
|
| 5569 |
if test "$a" = no ; then |
| 5570 |
# Not in libc, try libnsl. |
| 5571 |
echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 |
| 5572 |
echo "configure:5573: checking for gethostbyname in -lnsl" >&5 |
| 5573 |
ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` |
| 5574 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5575 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5576 |
else |
| 5577 |
ac_save_LIBS="$LIBS" |
| 5578 |
LIBS="-lnsl $LIBS" |
| 5579 |
cat > conftest.$ac_ext <<EOF |
| 5580 |
#line 5581 "configure" |
| 5581 |
#include "confdefs.h" |
| 5582 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 5583 |
/* We use char because int might match the return type of a gcc2 |
| 5584 |
builtin and then its argument prototype would still apply. */ |
| 5585 |
char gethostbyname(); |
| 5586 |
|
| 5587 |
int main(void) { |
| 5588 |
gethostbyname() |
| 5589 |
; return 0; } |
| 5590 |
EOF |
| 5591 |
if { (eval echo configure:5592: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5592 |
rm -rf conftest* |
| 5593 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5594 |
else |
| 5595 |
echo "configure: failed program was:" >&5 |
| 5596 |
cat conftest.$ac_ext >&5 |
| 5597 |
rm -rf conftest* |
| 5598 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5599 |
fi |
| 5600 |
rm -rf conftest* |
| 5601 |
LIBS="$ac_save_LIBS" |
| 5602 |
|
| 5603 |
fi |
| 5604 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5605 |
echo "$ac_t""yes" 1>&6 |
| 5606 |
ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 5607 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 5608 |
cat >> confdefs.h <<EOF |
| 5609 |
#define $ac_tr_lib 1 |
| 5610 |
EOF |
| 5611 |
|
| 5612 |
LIBS="-lnsl $LIBS" |
| 5613 |
|
| 5614 |
else |
| 5615 |
echo "$ac_t""no" 1>&6 |
| 5616 |
fi |
| 5617 |
|
| 5618 |
fi |
| 5619 |
;; |
| 5620 |
esac |
| 5621 |
|
| 5622 |
|
| 5623 |
|
| 5624 |
# See if we could access two well-known sites without help of any special |
| 5625 |
# libraries, like resolv. |
| 5626 |
echo $ac_n "checking if we need to look for a separate DNS resolver library""... $ac_c" 1>&6 |
| 5627 |
echo "configure:5628: checking if we need to look for a separate DNS resolver library" >&5 |
| 5628 |
if eval "test \"`echo '$''{'wi_cv_look_for_resolv'+set}'`\" = set"; then |
| 5629 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5630 |
else |
| 5631 |
|
| 5632 |
|
| 5633 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 5634 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_LIB_RESOLV." 1>&2; exit 1; } |
| 5635 |
fi |
| 5636 |
|
| 5637 |
if test "$cross_compiling" = yes; then |
| 5638 |
|
| 5639 |
# action if cross compiling |
| 5640 |
guess="(guessing) " |
| 5641 |
wi_cv_look_for_resolv=yes |
| 5642 |
|
| 5643 |
else |
| 5644 |
cat > conftest.$ac_ext <<EOF |
| 5645 |
#line 5646 "configure" |
| 5646 |
#include "confdefs.h" |
| 5647 |
|
| 5648 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 5649 |
# define _ALL_SOURCE 1 |
| 5650 |
#endif |
| 5651 |
#ifdef HAVE_UNISTD_H |
| 5652 |
# include <unistd.h> |
| 5653 |
#endif |
| 5654 |
#ifdef HAVE_STDLIB_H |
| 5655 |
# include <stdlib.h> |
| 5656 |
#endif |
| 5657 |
#include <sys/types.h> |
| 5658 |
#include <sys/socket.h> |
| 5659 |
#include <netinet/in.h> |
| 5660 |
#include <netdb.h> |
| 5661 |
|
| 5662 |
int main(void) |
| 5663 |
{ |
| 5664 |
struct hostent *hp1, *hp2; |
| 5665 |
|
| 5666 |
hp1 = gethostbyname("ftp.ncftp.com"); |
| 5667 |
if (hp1 == (struct hostent *) 0) { |
| 5668 |
hp2 = gethostbyname("www.ibm.com"); |
| 5669 |
if (hp2 == (struct hostent *) 0) |
| 5670 |
exit(1); |
| 5671 |
} |
| 5672 |
exit(0); |
| 5673 |
} |
| 5674 |
EOF |
| 5675 |
if { (eval echo configure:5676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 5676 |
then |
| 5677 |
|
| 5678 |
# action if true |
| 5679 |
guess="" |
| 5680 |
wi_cv_look_for_resolv=no |
| 5681 |
|
| 5682 |
else |
| 5683 |
echo "configure: failed program was:" >&5 |
| 5684 |
cat conftest.$ac_ext >&5 |
| 5685 |
rm -fr conftest* |
| 5686 |
|
| 5687 |
# action if false |
| 5688 |
guess="" |
| 5689 |
wi_cv_look_for_resolv=yes |
| 5690 |
|
| 5691 |
fi |
| 5692 |
rm -fr conftest* |
| 5693 |
fi |
| 5694 |
|
| 5695 |
fi |
| 5696 |
|
| 5697 |
echo "$ac_t""$guess$wi_cv_look_for_resolv" 1>&6 |
| 5698 |
guess="" |
| 5699 |
|
| 5700 |
|
| 5701 |
if test "$wi_cv_look_for_resolv" = yes ; then |
| 5702 |
echo $ac_n "checking for main in -lresolv""... $ac_c" 1>&6 |
| 5703 |
echo "configure:5704: checking for main in -lresolv" >&5 |
| 5704 |
ac_lib_var=`echo resolv'_'main | sed 'y%./+-%__p_%'` |
| 5705 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5706 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5707 |
else |
| 5708 |
ac_save_LIBS="$LIBS" |
| 5709 |
LIBS="-lresolv $LIBS" |
| 5710 |
cat > conftest.$ac_ext <<EOF |
| 5711 |
#line 5712 "configure" |
| 5712 |
#include "confdefs.h" |
| 5713 |
|
| 5714 |
int main(void) { |
| 5715 |
main() |
| 5716 |
; return 0; } |
| 5717 |
EOF |
| 5718 |
if { (eval echo configure:5719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5719 |
rm -rf conftest* |
| 5720 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5721 |
else |
| 5722 |
echo "configure: failed program was:" >&5 |
| 5723 |
cat conftest.$ac_ext >&5 |
| 5724 |
rm -rf conftest* |
| 5725 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5726 |
fi |
| 5727 |
rm -rf conftest* |
| 5728 |
LIBS="$ac_save_LIBS" |
| 5729 |
|
| 5730 |
fi |
| 5731 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5732 |
echo "$ac_t""yes" 1>&6 |
| 5733 |
ac_tr_lib=HAVE_LIB`echo resolv | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 5734 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 5735 |
cat >> confdefs.h <<EOF |
| 5736 |
#define $ac_tr_lib 1 |
| 5737 |
EOF |
| 5738 |
|
| 5739 |
LIBS="-lresolv $LIBS" |
| 5740 |
|
| 5741 |
else |
| 5742 |
echo "$ac_t""no" 1>&6 |
| 5743 |
fi |
| 5744 |
|
| 5745 |
else |
| 5746 |
ac_cv_lib_resolv=no |
| 5747 |
fi |
| 5748 |
|
| 5749 |
|
| 5750 |
if test "$SYS" = dynixptx ; then |
| 5751 |
LIBS="$LIBS -lsocket -lnsl" |
| 5752 |
fi |
| 5753 |
|
| 5754 |
|
| 5755 |
|
| 5756 |
if test "$wi_want_socks5" != yes ; then |
| 5757 |
ac_cv_lib_socks5_SOCKSinit=no |
| 5758 |
else |
| 5759 |
# Look for the "SOCKS" library for use with Firewalls/Gateways. |
| 5760 |
SOCKS_LIBS='' |
| 5761 |
|
| 5762 |
# First check for extra libraries that may be needed to |
| 5763 |
# link against socks. If we already checked for one or |
| 5764 |
# more of these libraries, we don't want to count them |
| 5765 |
# in the socks-only list. |
| 5766 |
# |
| 5767 |
if test "x$ac_cv_lib_db_main" = "x" ; then |
| 5768 |
echo $ac_n "checking for main in -ldb""... $ac_c" 1>&6 |
| 5769 |
echo "configure:5770: checking for main in -ldb" >&5 |
| 5770 |
ac_lib_var=`echo db'_'main | sed 'y%./+-%__p_%'` |
| 5771 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5772 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5773 |
else |
| 5774 |
ac_save_LIBS="$LIBS" |
| 5775 |
LIBS="-ldb $LIBS" |
| 5776 |
cat > conftest.$ac_ext <<EOF |
| 5777 |
#line 5778 "configure" |
| 5778 |
#include "confdefs.h" |
| 5779 |
|
| 5780 |
int main(void) { |
| 5781 |
main() |
| 5782 |
; return 0; } |
| 5783 |
EOF |
| 5784 |
if { (eval echo configure:5785: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5785 |
rm -rf conftest* |
| 5786 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5787 |
else |
| 5788 |
echo "configure: failed program was:" >&5 |
| 5789 |
cat conftest.$ac_ext >&5 |
| 5790 |
rm -rf conftest* |
| 5791 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5792 |
fi |
| 5793 |
rm -rf conftest* |
| 5794 |
LIBS="$ac_save_LIBS" |
| 5795 |
|
| 5796 |
fi |
| 5797 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5798 |
echo "$ac_t""yes" 1>&6 |
| 5799 |
SOCKS_LIBS="$SOCKS_LIBS -ldb" |
| 5800 |
else |
| 5801 |
echo "$ac_t""no" 1>&6 |
| 5802 |
fi |
| 5803 |
|
| 5804 |
fi |
| 5805 |
if test "x$ac_cv_lib_isode_main" = "x" ; then |
| 5806 |
echo $ac_n "checking for main in -lisode""... $ac_c" 1>&6 |
| 5807 |
echo "configure:5808: checking for main in -lisode" >&5 |
| 5808 |
ac_lib_var=`echo isode'_'main | sed 'y%./+-%__p_%'` |
| 5809 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5810 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5811 |
else |
| 5812 |
ac_save_LIBS="$LIBS" |
| 5813 |
LIBS="-lisode $LIBS" |
| 5814 |
cat > conftest.$ac_ext <<EOF |
| 5815 |
#line 5816 "configure" |
| 5816 |
#include "confdefs.h" |
| 5817 |
|
| 5818 |
int main(void) { |
| 5819 |
main() |
| 5820 |
; return 0; } |
| 5821 |
EOF |
| 5822 |
if { (eval echo configure:5823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5823 |
rm -rf conftest* |
| 5824 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5825 |
else |
| 5826 |
echo "configure: failed program was:" >&5 |
| 5827 |
cat conftest.$ac_ext >&5 |
| 5828 |
rm -rf conftest* |
| 5829 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5830 |
fi |
| 5831 |
rm -rf conftest* |
| 5832 |
LIBS="$ac_save_LIBS" |
| 5833 |
|
| 5834 |
fi |
| 5835 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5836 |
echo "$ac_t""yes" 1>&6 |
| 5837 |
SOCKS_LIBS="$SOCKS_LIBS -lisode" |
| 5838 |
else |
| 5839 |
echo "$ac_t""no" 1>&6 |
| 5840 |
fi |
| 5841 |
|
| 5842 |
fi |
| 5843 |
if test "x$ac_cv_lib_com_err_main" = "x" ; then |
| 5844 |
echo $ac_n "checking for main in -lcom_err""... $ac_c" 1>&6 |
| 5845 |
echo "configure:5846: checking for main in -lcom_err" >&5 |
| 5846 |
ac_lib_var=`echo com_err'_'main | sed 'y%./+-%__p_%'` |
| 5847 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5848 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5849 |
else |
| 5850 |
ac_save_LIBS="$LIBS" |
| 5851 |
LIBS="-lcom_err $LIBS" |
| 5852 |
cat > conftest.$ac_ext <<EOF |
| 5853 |
#line 5854 "configure" |
| 5854 |
#include "confdefs.h" |
| 5855 |
|
| 5856 |
int main(void) { |
| 5857 |
main() |
| 5858 |
; return 0; } |
| 5859 |
EOF |
| 5860 |
if { (eval echo configure:5861: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5861 |
rm -rf conftest* |
| 5862 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5863 |
else |
| 5864 |
echo "configure: failed program was:" >&5 |
| 5865 |
cat conftest.$ac_ext >&5 |
| 5866 |
rm -rf conftest* |
| 5867 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5868 |
fi |
| 5869 |
rm -rf conftest* |
| 5870 |
LIBS="$ac_save_LIBS" |
| 5871 |
|
| 5872 |
fi |
| 5873 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5874 |
echo "$ac_t""yes" 1>&6 |
| 5875 |
SOCKS_LIBS="$SOCKS_LIBS -lcom_err" |
| 5876 |
else |
| 5877 |
echo "$ac_t""no" 1>&6 |
| 5878 |
fi |
| 5879 |
|
| 5880 |
fi |
| 5881 |
if test "x$ac_cv_lib_crypto_main" = "x" ; then |
| 5882 |
echo $ac_n "checking for main in -lcrypto""... $ac_c" 1>&6 |
| 5883 |
echo "configure:5884: checking for main in -lcrypto" >&5 |
| 5884 |
ac_lib_var=`echo crypto'_'main | sed 'y%./+-%__p_%'` |
| 5885 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5886 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5887 |
else |
| 5888 |
ac_save_LIBS="$LIBS" |
| 5889 |
LIBS="-lcrypto $LIBS" |
| 5890 |
cat > conftest.$ac_ext <<EOF |
| 5891 |
#line 5892 "configure" |
| 5892 |
#include "confdefs.h" |
| 5893 |
|
| 5894 |
int main(void) { |
| 5895 |
main() |
| 5896 |
; return 0; } |
| 5897 |
EOF |
| 5898 |
if { (eval echo configure:5899: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5899 |
rm -rf conftest* |
| 5900 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5901 |
else |
| 5902 |
echo "configure: failed program was:" >&5 |
| 5903 |
cat conftest.$ac_ext >&5 |
| 5904 |
rm -rf conftest* |
| 5905 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5906 |
fi |
| 5907 |
rm -rf conftest* |
| 5908 |
LIBS="$ac_save_LIBS" |
| 5909 |
|
| 5910 |
fi |
| 5911 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5912 |
echo "$ac_t""yes" 1>&6 |
| 5913 |
SOCKS_LIBS="$SOCKS_LIBS -lcrypto" |
| 5914 |
else |
| 5915 |
echo "$ac_t""no" 1>&6 |
| 5916 |
fi |
| 5917 |
|
| 5918 |
fi |
| 5919 |
if test "x$ac_cv_lib_krb5_main" = "x" ; then |
| 5920 |
echo $ac_n "checking for main in -lkrb5""... $ac_c" 1>&6 |
| 5921 |
echo "configure:5922: checking for main in -lkrb5" >&5 |
| 5922 |
ac_lib_var=`echo krb5'_'main | sed 'y%./+-%__p_%'` |
| 5923 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5924 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5925 |
else |
| 5926 |
ac_save_LIBS="$LIBS" |
| 5927 |
LIBS="-lkrb5 $LIBS" |
| 5928 |
cat > conftest.$ac_ext <<EOF |
| 5929 |
#line 5930 "configure" |
| 5930 |
#include "confdefs.h" |
| 5931 |
|
| 5932 |
int main(void) { |
| 5933 |
main() |
| 5934 |
; return 0; } |
| 5935 |
EOF |
| 5936 |
if { (eval echo configure:5937: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5937 |
rm -rf conftest* |
| 5938 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5939 |
else |
| 5940 |
echo "configure: failed program was:" >&5 |
| 5941 |
cat conftest.$ac_ext >&5 |
| 5942 |
rm -rf conftest* |
| 5943 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5944 |
fi |
| 5945 |
rm -rf conftest* |
| 5946 |
LIBS="$ac_save_LIBS" |
| 5947 |
|
| 5948 |
fi |
| 5949 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5950 |
echo "$ac_t""yes" 1>&6 |
| 5951 |
SOCKS_LIBS="$SOCKS_LIBS -lkrb5" |
| 5952 |
else |
| 5953 |
echo "$ac_t""no" 1>&6 |
| 5954 |
fi |
| 5955 |
|
| 5956 |
fi |
| 5957 |
if test "x$ac_cv_lib_gssapi_krb5_main" = "x" ; then |
| 5958 |
echo $ac_n "checking for main in -lgssapi_krb5""... $ac_c" 1>&6 |
| 5959 |
echo "configure:5960: checking for main in -lgssapi_krb5" >&5 |
| 5960 |
ac_lib_var=`echo gssapi_krb5'_'main | sed 'y%./+-%__p_%'` |
| 5961 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 5962 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 5963 |
else |
| 5964 |
ac_save_LIBS="$LIBS" |
| 5965 |
LIBS="-lgssapi_krb5 $LIBS" |
| 5966 |
cat > conftest.$ac_ext <<EOF |
| 5967 |
#line 5968 "configure" |
| 5968 |
#include "confdefs.h" |
| 5969 |
|
| 5970 |
int main(void) { |
| 5971 |
main() |
| 5972 |
; return 0; } |
| 5973 |
EOF |
| 5974 |
if { (eval echo configure:5975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 5975 |
rm -rf conftest* |
| 5976 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 5977 |
else |
| 5978 |
echo "configure: failed program was:" >&5 |
| 5979 |
cat conftest.$ac_ext >&5 |
| 5980 |
rm -rf conftest* |
| 5981 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 5982 |
fi |
| 5983 |
rm -rf conftest* |
| 5984 |
LIBS="$ac_save_LIBS" |
| 5985 |
|
| 5986 |
fi |
| 5987 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 5988 |
echo "$ac_t""yes" 1>&6 |
| 5989 |
SOCKS_LIBS="$SOCKS_LIBS -lgssapi_krb5" |
| 5990 |
else |
| 5991 |
echo "$ac_t""no" 1>&6 |
| 5992 |
fi |
| 5993 |
|
| 5994 |
fi |
| 5995 |
|
| 5996 |
echo $ac_n "checking for SOCKSinit in -lsocks5""... $ac_c" 1>&6 |
| 5997 |
echo "configure:5998: checking for SOCKSinit in -lsocks5" >&5 |
| 5998 |
ac_lib_var=`echo socks5'_'SOCKSinit | sed 'y%./+-%__p_%'` |
| 5999 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6000 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6001 |
else |
| 6002 |
ac_save_LIBS="$LIBS" |
| 6003 |
LIBS="-lsocks5 $LIBS" |
| 6004 |
cat > conftest.$ac_ext <<EOF |
| 6005 |
#line 6006 "configure" |
| 6006 |
#include "confdefs.h" |
| 6007 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6008 |
/* We use char because int might match the return type of a gcc2 |
| 6009 |
builtin and then its argument prototype would still apply. */ |
| 6010 |
char SOCKSinit(); |
| 6011 |
|
| 6012 |
int main(void) { |
| 6013 |
SOCKSinit() |
| 6014 |
; return 0; } |
| 6015 |
EOF |
| 6016 |
if { (eval echo configure:6017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6017 |
rm -rf conftest* |
| 6018 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6019 |
else |
| 6020 |
echo "configure: failed program was:" >&5 |
| 6021 |
cat conftest.$ac_ext >&5 |
| 6022 |
rm -rf conftest* |
| 6023 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6024 |
fi |
| 6025 |
rm -rf conftest* |
| 6026 |
LIBS="$ac_save_LIBS" |
| 6027 |
|
| 6028 |
fi |
| 6029 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6030 |
echo "$ac_t""yes" 1>&6 |
| 6031 |
SOCKS_LIBS="$SOCKS_LIBS -lsocks5" |
| 6032 |
else |
| 6033 |
echo "$ac_t""no" 1>&6 |
| 6034 |
fi |
| 6035 |
|
| 6036 |
for ac_hdr in socks.h socks5p.h |
| 6037 |
do |
| 6038 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 6039 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 6040 |
echo "configure:6041: checking for $ac_hdr" >&5 |
| 6041 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 6042 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6043 |
else |
| 6044 |
cat > conftest.$ac_ext <<EOF |
| 6045 |
#line 6046 "configure" |
| 6046 |
#include "confdefs.h" |
| 6047 |
#include <$ac_hdr> |
| 6048 |
EOF |
| 6049 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 6050 |
{ (eval echo configure:6051: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 6051 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 6052 |
if test -z "$ac_err"; then |
| 6053 |
rm -rf conftest* |
| 6054 |
eval "ac_cv_header_$ac_safe=yes" |
| 6055 |
else |
| 6056 |
echo "$ac_err" >&5 |
| 6057 |
echo "configure: failed program was:" >&5 |
| 6058 |
cat conftest.$ac_ext >&5 |
| 6059 |
rm -rf conftest* |
| 6060 |
eval "ac_cv_header_$ac_safe=no" |
| 6061 |
fi |
| 6062 |
rm -rf conftest* |
| 6063 |
fi |
| 6064 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 6065 |
echo "$ac_t""yes" 1>&6 |
| 6066 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 6067 |
cat >> confdefs.h <<EOF |
| 6068 |
#define $ac_tr_hdr 1 |
| 6069 |
EOF |
| 6070 |
|
| 6071 |
else |
| 6072 |
echo "$ac_t""no" 1>&6 |
| 6073 |
fi |
| 6074 |
done |
| 6075 |
|
| 6076 |
|
| 6077 |
if test "$ac_cv_lib_socks5_SOCKSinit" != yes ; then |
| 6078 |
ac_cv_lib_socks5_SOCKSinit=no |
| 6079 |
unset SOCKS_LIBS |
| 6080 |
else |
| 6081 |
|
| 6082 |
cat >> confdefs.h <<\EOF |
| 6083 |
#define SOCKS 5 |
| 6084 |
EOF |
| 6085 |
|
| 6086 |
fi |
| 6087 |
fi |
| 6088 |
echo $ac_n "checking if SOCKS5 will be used""... $ac_c" 1>&6 |
| 6089 |
echo "configure:6090: checking if SOCKS5 will be used" >&5 |
| 6090 |
echo "$ac_t""$ac_cv_lib_socks5_SOCKSinit" 1>&6 |
| 6091 |
|
| 6092 |
case "$OS" in |
| 6093 |
solaris8-*) |
| 6094 |
saved_LIBS="$LIBS" |
| 6095 |
echo $ac_n "checking for sendfilev in -lsendfile""... $ac_c" 1>&6 |
| 6096 |
echo "configure:6097: checking for sendfilev in -lsendfile" >&5 |
| 6097 |
ac_lib_var=`echo sendfile'_'sendfilev | sed 'y%./+-%__p_%'` |
| 6098 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6099 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6100 |
else |
| 6101 |
ac_save_LIBS="$LIBS" |
| 6102 |
LIBS="-lsendfile $LIBS" |
| 6103 |
cat > conftest.$ac_ext <<EOF |
| 6104 |
#line 6105 "configure" |
| 6105 |
#include "confdefs.h" |
| 6106 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6107 |
/* We use char because int might match the return type of a gcc2 |
| 6108 |
builtin and then its argument prototype would still apply. */ |
| 6109 |
char sendfilev(); |
| 6110 |
|
| 6111 |
int main(void) { |
| 6112 |
sendfilev() |
| 6113 |
; return 0; } |
| 6114 |
EOF |
| 6115 |
if { (eval echo configure:6116: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6116 |
rm -rf conftest* |
| 6117 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6118 |
else |
| 6119 |
echo "configure: failed program was:" >&5 |
| 6120 |
cat conftest.$ac_ext >&5 |
| 6121 |
rm -rf conftest* |
| 6122 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6123 |
fi |
| 6124 |
rm -rf conftest* |
| 6125 |
LIBS="$ac_save_LIBS" |
| 6126 |
|
| 6127 |
fi |
| 6128 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6129 |
echo "$ac_t""yes" 1>&6 |
| 6130 |
ac_tr_lib=HAVE_LIB`echo sendfile | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 6131 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 6132 |
cat >> confdefs.h <<EOF |
| 6133 |
#define $ac_tr_lib 1 |
| 6134 |
EOF |
| 6135 |
|
| 6136 |
LIBS="-lsendfile $LIBS" |
| 6137 |
|
| 6138 |
else |
| 6139 |
echo "$ac_t""no" 1>&6 |
| 6140 |
fi |
| 6141 |
|
| 6142 |
for ac_func in sendfilev sendfilev64 |
| 6143 |
do |
| 6144 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 6145 |
echo "configure:6146: checking for $ac_func" >&5 |
| 6146 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 6147 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6148 |
else |
| 6149 |
cat > conftest.$ac_ext <<EOF |
| 6150 |
#line 6151 "configure" |
| 6151 |
#include "confdefs.h" |
| 6152 |
/* System header to define __stub macros and hopefully few prototypes, |
| 6153 |
which can conflict with char $ac_func(); below. */ |
| 6154 |
#include <assert.h> |
| 6155 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6156 |
/* We use char because int might match the return type of a gcc2 |
| 6157 |
builtin and then its argument prototype would still apply. */ |
| 6158 |
char $ac_func(); |
| 6159 |
|
| 6160 |
int main(void) { |
| 6161 |
|
| 6162 |
/* The GNU C library defines this for functions which it implements |
| 6163 |
to always fail with ENOSYS. Some functions are actually named |
| 6164 |
something starting with __ and the normal name is an alias. */ |
| 6165 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 6166 |
choke me |
| 6167 |
#else |
| 6168 |
$ac_func(); |
| 6169 |
#endif |
| 6170 |
|
| 6171 |
; return 0; } |
| 6172 |
EOF |
| 6173 |
if { (eval echo configure:6174: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6174 |
rm -rf conftest* |
| 6175 |
eval "ac_cv_func_$ac_func=yes" |
| 6176 |
else |
| 6177 |
echo "configure: failed program was:" >&5 |
| 6178 |
cat conftest.$ac_ext >&5 |
| 6179 |
rm -rf conftest* |
| 6180 |
eval "ac_cv_func_$ac_func=no" |
| 6181 |
fi |
| 6182 |
rm -rf conftest* |
| 6183 |
fi |
| 6184 |
|
| 6185 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 6186 |
echo "$ac_t""yes" 1>&6 |
| 6187 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 6188 |
cat >> confdefs.h <<EOF |
| 6189 |
#define $ac_tr_func 1 |
| 6190 |
EOF |
| 6191 |
|
| 6192 |
else |
| 6193 |
echo "$ac_t""no" 1>&6 |
| 6194 |
fi |
| 6195 |
done |
| 6196 |
|
| 6197 |
LIBS="$saved_LIBS" |
| 6198 |
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 |
| 6199 |
echo "configure:6200: checking for dlopen in -ldl" >&5 |
| 6200 |
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
| 6201 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6202 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6203 |
else |
| 6204 |
ac_save_LIBS="$LIBS" |
| 6205 |
LIBS="-ldl $LIBS" |
| 6206 |
cat > conftest.$ac_ext <<EOF |
| 6207 |
#line 6208 "configure" |
| 6208 |
#include "confdefs.h" |
| 6209 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6210 |
/* We use char because int might match the return type of a gcc2 |
| 6211 |
builtin and then its argument prototype would still apply. */ |
| 6212 |
char dlopen(); |
| 6213 |
|
| 6214 |
int main(void) { |
| 6215 |
dlopen() |
| 6216 |
; return 0; } |
| 6217 |
EOF |
| 6218 |
if { (eval echo configure:6219: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6219 |
rm -rf conftest* |
| 6220 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6221 |
else |
| 6222 |
echo "configure: failed program was:" >&5 |
| 6223 |
cat conftest.$ac_ext >&5 |
| 6224 |
rm -rf conftest* |
| 6225 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6226 |
fi |
| 6227 |
rm -rf conftest* |
| 6228 |
LIBS="$ac_save_LIBS" |
| 6229 |
|
| 6230 |
fi |
| 6231 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6232 |
echo "$ac_t""yes" 1>&6 |
| 6233 |
ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 6234 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 6235 |
cat >> confdefs.h <<EOF |
| 6236 |
#define $ac_tr_lib 1 |
| 6237 |
EOF |
| 6238 |
|
| 6239 |
LIBS="-ldl $LIBS" |
| 6240 |
|
| 6241 |
else |
| 6242 |
echo "$ac_t""no" 1>&6 |
| 6243 |
fi |
| 6244 |
|
| 6245 |
;; |
| 6246 |
solaris9-*|solaris1[0-9]-*) |
| 6247 |
echo $ac_n "checking for sendfilev in -lsendfile""... $ac_c" 1>&6 |
| 6248 |
echo "configure:6249: checking for sendfilev in -lsendfile" >&5 |
| 6249 |
ac_lib_var=`echo sendfile'_'sendfilev | sed 'y%./+-%__p_%'` |
| 6250 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6251 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6252 |
else |
| 6253 |
ac_save_LIBS="$LIBS" |
| 6254 |
LIBS="-lsendfile $LIBS" |
| 6255 |
cat > conftest.$ac_ext <<EOF |
| 6256 |
#line 6257 "configure" |
| 6257 |
#include "confdefs.h" |
| 6258 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6259 |
/* We use char because int might match the return type of a gcc2 |
| 6260 |
builtin and then its argument prototype would still apply. */ |
| 6261 |
char sendfilev(); |
| 6262 |
|
| 6263 |
int main(void) { |
| 6264 |
sendfilev() |
| 6265 |
; return 0; } |
| 6266 |
EOF |
| 6267 |
if { (eval echo configure:6268: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6268 |
rm -rf conftest* |
| 6269 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6270 |
else |
| 6271 |
echo "configure: failed program was:" >&5 |
| 6272 |
cat conftest.$ac_ext >&5 |
| 6273 |
rm -rf conftest* |
| 6274 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6275 |
fi |
| 6276 |
rm -rf conftest* |
| 6277 |
LIBS="$ac_save_LIBS" |
| 6278 |
|
| 6279 |
fi |
| 6280 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6281 |
echo "$ac_t""yes" 1>&6 |
| 6282 |
ac_tr_lib=HAVE_LIB`echo sendfile | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 6283 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 6284 |
cat >> confdefs.h <<EOF |
| 6285 |
#define $ac_tr_lib 1 |
| 6286 |
EOF |
| 6287 |
|
| 6288 |
LIBS="-lsendfile $LIBS" |
| 6289 |
|
| 6290 |
else |
| 6291 |
echo "$ac_t""no" 1>&6 |
| 6292 |
fi |
| 6293 |
|
| 6294 |
for ac_func in sendfilev sendfilev64 |
| 6295 |
do |
| 6296 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 6297 |
echo "configure:6298: checking for $ac_func" >&5 |
| 6298 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 6299 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6300 |
else |
| 6301 |
cat > conftest.$ac_ext <<EOF |
| 6302 |
#line 6303 "configure" |
| 6303 |
#include "confdefs.h" |
| 6304 |
/* System header to define __stub macros and hopefully few prototypes, |
| 6305 |
which can conflict with char $ac_func(); below. */ |
| 6306 |
#include <assert.h> |
| 6307 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6308 |
/* We use char because int might match the return type of a gcc2 |
| 6309 |
builtin and then its argument prototype would still apply. */ |
| 6310 |
char $ac_func(); |
| 6311 |
|
| 6312 |
int main(void) { |
| 6313 |
|
| 6314 |
/* The GNU C library defines this for functions which it implements |
| 6315 |
to always fail with ENOSYS. Some functions are actually named |
| 6316 |
something starting with __ and the normal name is an alias. */ |
| 6317 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 6318 |
choke me |
| 6319 |
#else |
| 6320 |
$ac_func(); |
| 6321 |
#endif |
| 6322 |
|
| 6323 |
; return 0; } |
| 6324 |
EOF |
| 6325 |
if { (eval echo configure:6326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6326 |
rm -rf conftest* |
| 6327 |
eval "ac_cv_func_$ac_func=yes" |
| 6328 |
else |
| 6329 |
echo "configure: failed program was:" >&5 |
| 6330 |
cat conftest.$ac_ext >&5 |
| 6331 |
rm -rf conftest* |
| 6332 |
eval "ac_cv_func_$ac_func=no" |
| 6333 |
fi |
| 6334 |
rm -rf conftest* |
| 6335 |
fi |
| 6336 |
|
| 6337 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 6338 |
echo "$ac_t""yes" 1>&6 |
| 6339 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 6340 |
cat >> confdefs.h <<EOF |
| 6341 |
#define $ac_tr_func 1 |
| 6342 |
EOF |
| 6343 |
|
| 6344 |
else |
| 6345 |
echo "$ac_t""no" 1>&6 |
| 6346 |
fi |
| 6347 |
done |
| 6348 |
|
| 6349 |
;; |
| 6350 |
esac |
| 6351 |
|
| 6352 |
LIBCURSES='' |
| 6353 |
if test "$nc_cv_curses" = yes ; then |
| 6354 |
|
| 6355 |
|
| 6356 |
echo $ac_n "checking for curses library headers""... $ac_c" 1>&6 |
| 6357 |
echo "configure:6358: checking for curses library headers" >&5 |
| 6358 |
if test "$wi_cv_ncurses" != "no" ; then |
| 6359 |
for ac_hdr in ncurses.h curses.h termios.h termio.h sgtty.h sys/ioctl.h |
| 6360 |
do |
| 6361 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 6362 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 6363 |
echo "configure:6364: checking for $ac_hdr" >&5 |
| 6364 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 6365 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6366 |
else |
| 6367 |
cat > conftest.$ac_ext <<EOF |
| 6368 |
#line 6369 "configure" |
| 6369 |
#include "confdefs.h" |
| 6370 |
#include <$ac_hdr> |
| 6371 |
EOF |
| 6372 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 6373 |
{ (eval echo configure:6374: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 6374 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 6375 |
if test -z "$ac_err"; then |
| 6376 |
rm -rf conftest* |
| 6377 |
eval "ac_cv_header_$ac_safe=yes" |
| 6378 |
else |
| 6379 |
echo "$ac_err" >&5 |
| 6380 |
echo "configure: failed program was:" >&5 |
| 6381 |
cat conftest.$ac_ext >&5 |
| 6382 |
rm -rf conftest* |
| 6383 |
eval "ac_cv_header_$ac_safe=no" |
| 6384 |
fi |
| 6385 |
rm -rf conftest* |
| 6386 |
fi |
| 6387 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 6388 |
echo "$ac_t""yes" 1>&6 |
| 6389 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 6390 |
cat >> confdefs.h <<EOF |
| 6391 |
#define $ac_tr_hdr 1 |
| 6392 |
EOF |
| 6393 |
|
| 6394 |
else |
| 6395 |
echo "$ac_t""no" 1>&6 |
| 6396 |
fi |
| 6397 |
done |
| 6398 |
|
| 6399 |
else |
| 6400 |
for ac_hdr in curses.h termios.h termio.h sgtty.h sys/ioctl.h |
| 6401 |
do |
| 6402 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 6403 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 6404 |
echo "configure:6405: checking for $ac_hdr" >&5 |
| 6405 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 6406 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6407 |
else |
| 6408 |
cat > conftest.$ac_ext <<EOF |
| 6409 |
#line 6410 "configure" |
| 6410 |
#include "confdefs.h" |
| 6411 |
#include <$ac_hdr> |
| 6412 |
EOF |
| 6413 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 6414 |
{ (eval echo configure:6415: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 6415 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 6416 |
if test -z "$ac_err"; then |
| 6417 |
rm -rf conftest* |
| 6418 |
eval "ac_cv_header_$ac_safe=yes" |
| 6419 |
else |
| 6420 |
echo "$ac_err" >&5 |
| 6421 |
echo "configure: failed program was:" >&5 |
| 6422 |
cat conftest.$ac_ext >&5 |
| 6423 |
rm -rf conftest* |
| 6424 |
eval "ac_cv_header_$ac_safe=no" |
| 6425 |
fi |
| 6426 |
rm -rf conftest* |
| 6427 |
fi |
| 6428 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 6429 |
echo "$ac_t""yes" 1>&6 |
| 6430 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 6431 |
cat >> confdefs.h <<EOF |
| 6432 |
#define $ac_tr_hdr 1 |
| 6433 |
EOF |
| 6434 |
|
| 6435 |
else |
| 6436 |
echo "$ac_t""no" 1>&6 |
| 6437 |
fi |
| 6438 |
done |
| 6439 |
|
| 6440 |
fi |
| 6441 |
if test "$ac_cv_header_curses_h" = no ; then |
| 6442 |
if test -f /usr/include/curses.h ; then |
| 6443 |
cat >> confdefs.h <<\EOF |
| 6444 |
#define HAVE_CURSES_H 1 |
| 6445 |
EOF |
| 6446 |
|
| 6447 |
ac_cv_header_curses_h=yes |
| 6448 |
fi |
| 6449 |
fi |
| 6450 |
|
| 6451 |
echo $ac_n "checking for curses library""... $ac_c" 1>&6 |
| 6452 |
echo "configure:6453: checking for curses library" >&5 |
| 6453 |
|
| 6454 |
wi_cv_lib_curses=no |
| 6455 |
wi_cv_lib_curses_result=no |
| 6456 |
ac_save_LIBS="$LIBS" |
| 6457 |
for LIBCURSES in "-lncursesw" "-lncurses" "-lcurses" "-lcurses -ltermcap" "-ltermcap -lcurses" |
| 6458 |
do |
| 6459 |
if test "x$LIBCURSES-$wi_cv_ncurses" = "x-lncurses-no" ; then |
| 6460 |
# This should never work |
| 6461 |
LIBCURSES="-lkdfjkdjfs" |
| 6462 |
fi |
| 6463 |
LIBS="$ac_save_LIBS $LIBCURSES" |
| 6464 |
cat > conftest.$ac_ext <<EOF |
| 6465 |
#line 6466 "configure" |
| 6466 |
#include "confdefs.h" |
| 6467 |
|
| 6468 |
/* includes */ |
| 6469 |
#include <stdio.h> |
| 6470 |
#ifdef HAVE_STDLIB_H |
| 6471 |
# include <stdlib.h> |
| 6472 |
#endif |
| 6473 |
|
| 6474 |
#ifdef HAVE_NCURSES_H |
| 6475 |
# define NCURSES_OPAQUE 0 |
| 6476 |
# include <ncurses.h> |
| 6477 |
#else |
| 6478 |
# include <curses.h> |
| 6479 |
#endif |
| 6480 |
|
| 6481 |
int main(void) { |
| 6482 |
|
| 6483 |
/* function body */ |
| 6484 |
if (strcmp("jimmy", "floyd") == 0) |
| 6485 |
initscr(); |
| 6486 |
exit(0); |
| 6487 |
|
| 6488 |
; return 0; } |
| 6489 |
EOF |
| 6490 |
if { (eval echo configure:6491: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6491 |
rm -rf conftest* |
| 6492 |
|
| 6493 |
linked_with_LIBCURSES=yes |
| 6494 |
|
| 6495 |
else |
| 6496 |
echo "configure: failed program was:" >&5 |
| 6497 |
cat conftest.$ac_ext >&5 |
| 6498 |
rm -rf conftest* |
| 6499 |
|
| 6500 |
linked_with_LIBCURSES=no |
| 6501 |
|
| 6502 |
fi |
| 6503 |
rm -rf conftest* |
| 6504 |
if test "x$linked_with_LIBCURSES" != "xyes" ; then continue ; fi |
| 6505 |
if test "$cross_compiling" = yes; then |
| 6506 |
|
| 6507 |
# action if cross compiling |
| 6508 |
wi_cv_lib_curses=yes |
| 6509 |
wi_cv_lib_curses_result="yes" |
| 6510 |
guess="(guessing) " |
| 6511 |
|
| 6512 |
else |
| 6513 |
cat > conftest.$ac_ext <<EOF |
| 6514 |
#line 6515 "configure" |
| 6515 |
#include "confdefs.h" |
| 6516 |
|
| 6517 |
/* program */ |
| 6518 |
#include <stdio.h> |
| 6519 |
#include <stdlib.h> |
| 6520 |
|
| 6521 |
#ifdef HAVE_NCURSES_H |
| 6522 |
# define NCURSES_OPAQUE 0 |
| 6523 |
# include <ncurses.h> |
| 6524 |
#else |
| 6525 |
# include <curses.h> |
| 6526 |
#endif |
| 6527 |
|
| 6528 |
|
| 6529 |
main(int argc, char **argv) |
| 6530 |
{ |
| 6531 |
/* Note: don't actually call curses, since it may block; |
| 6532 |
* We just want to see if it (dynamic) linked in okay. |
| 6533 |
*/ |
| 6534 |
if (argc == 0) |
| 6535 |
initscr(); |
| 6536 |
exit(0); |
| 6537 |
} |
| 6538 |
|
| 6539 |
EOF |
| 6540 |
if { (eval echo configure:6541: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 6541 |
then |
| 6542 |
|
| 6543 |
# action if true |
| 6544 |
wi_cv_lib_curses=yes |
| 6545 |
guess="" |
| 6546 |
wi_cv_lib_curses_result="yes" |
| 6547 |
|
| 6548 |
else |
| 6549 |
echo "configure: failed program was:" >&5 |
| 6550 |
cat conftest.$ac_ext >&5 |
| 6551 |
rm -fr conftest* |
| 6552 |
|
| 6553 |
# action if false |
| 6554 |
wi_cv_lib_curses=no |
| 6555 |
guess="" |
| 6556 |
|
| 6557 |
fi |
| 6558 |
rm -fr conftest* |
| 6559 |
fi |
| 6560 |
|
| 6561 |
|
| 6562 |
if test "$wi_cv_lib_curses" = yes ; then break ; fi |
| 6563 |
done |
| 6564 |
|
| 6565 |
# restore LIBS |
| 6566 |
LIBS="$ac_save_LIBS" |
| 6567 |
|
| 6568 |
if test "$wi_cv_lib_curses_result" != "no" ; then |
| 6569 |
case "$LIBCURSES" in |
| 6570 |
"-lncurses"*) |
| 6571 |
cat >> confdefs.h <<\EOF |
| 6572 |
#define HAVE_LIBNCURSES 1 |
| 6573 |
EOF |
| 6574 |
|
| 6575 |
;; |
| 6576 |
"-lcurses") |
| 6577 |
cat >> confdefs.h <<\EOF |
| 6578 |
#define HAVE_LIBCURSES 1 |
| 6579 |
EOF |
| 6580 |
|
| 6581 |
;; |
| 6582 |
"-lcurses -ltermcap") |
| 6583 |
cat >> confdefs.h <<\EOF |
| 6584 |
#define HAVE_LIBCURSES 1 |
| 6585 |
EOF |
| 6586 |
|
| 6587 |
;; |
| 6588 |
"-ltermcap -lcurses") |
| 6589 |
cat >> confdefs.h <<\EOF |
| 6590 |
#define HAVE_LIBCURSES 1 |
| 6591 |
EOF |
| 6592 |
|
| 6593 |
;; |
| 6594 |
esac |
| 6595 |
else |
| 6596 |
LIBCURSES='' |
| 6597 |
fi |
| 6598 |
|
| 6599 |
|
| 6600 |
echo "$ac_t""$wi_cv_lib_curses_result" 1>&6 |
| 6601 |
|
| 6602 |
fi |
| 6603 |
|
| 6604 |
# Check whether user wants DNSSEC local validation support |
| 6605 |
# Check whether --with-dnssec-local-validation or --without-dnssec-local-validation was given. |
| 6606 |
if test "${with_dnssec_local_validation+set}" = set; then |
| 6607 |
withval="$with_dnssec_local_validation" |
| 6608 |
want_dnssec=$withval |
| 6609 |
else |
| 6610 |
want_dnssec=no |
| 6611 |
fi |
| 6612 |
|
| 6613 |
if ! test "x-$want_dnssec" = "x-no" ; then |
| 6614 |
for ac_hdr in validator/validator.h |
| 6615 |
do |
| 6616 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 6617 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 6618 |
echo "configure:6619: checking for $ac_hdr" >&5 |
| 6619 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 6620 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6621 |
else |
| 6622 |
cat > conftest.$ac_ext <<EOF |
| 6623 |
#line 6624 "configure" |
| 6624 |
#include "confdefs.h" |
| 6625 |
#include <$ac_hdr> |
| 6626 |
EOF |
| 6627 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 6628 |
{ (eval echo configure:6629: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 6629 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 6630 |
if test -z "$ac_err"; then |
| 6631 |
rm -rf conftest* |
| 6632 |
eval "ac_cv_header_$ac_safe=yes" |
| 6633 |
else |
| 6634 |
echo "$ac_err" >&5 |
| 6635 |
echo "configure: failed program was:" >&5 |
| 6636 |
cat conftest.$ac_ext >&5 |
| 6637 |
rm -rf conftest* |
| 6638 |
eval "ac_cv_header_$ac_safe=no" |
| 6639 |
fi |
| 6640 |
rm -rf conftest* |
| 6641 |
fi |
| 6642 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 6643 |
echo "$ac_t""yes" 1>&6 |
| 6644 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 6645 |
cat >> confdefs.h <<EOF |
| 6646 |
#define $ac_tr_hdr 1 |
| 6647 |
EOF |
| 6648 |
|
| 6649 |
else |
| 6650 |
echo "$ac_t""no" 1>&6 |
| 6651 |
fi |
| 6652 |
done |
| 6653 |
|
| 6654 |
if test "$ac_cv_header_validator_validator_h" != yes; then |
| 6655 |
{ echo "configure: error: Can't find validator.h" 1>&2; exit 1; } |
| 6656 |
fi |
| 6657 |
echo $ac_n "checking for SHA1_Init in -lssl""... $ac_c" 1>&6 |
| 6658 |
echo "configure:6659: checking for SHA1_Init in -lssl" >&5 |
| 6659 |
ac_lib_var=`echo ssl'_'SHA1_Init | sed 'y%./+-%__p_%'` |
| 6660 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6661 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6662 |
else |
| 6663 |
ac_save_LIBS="$LIBS" |
| 6664 |
LIBS="-lssl $LIBS" |
| 6665 |
cat > conftest.$ac_ext <<EOF |
| 6666 |
#line 6667 "configure" |
| 6667 |
#include "confdefs.h" |
| 6668 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6669 |
/* We use char because int might match the return type of a gcc2 |
| 6670 |
builtin and then its argument prototype would still apply. */ |
| 6671 |
char SHA1_Init(); |
| 6672 |
|
| 6673 |
int main(void) { |
| 6674 |
SHA1_Init() |
| 6675 |
; return 0; } |
| 6676 |
EOF |
| 6677 |
if { (eval echo configure:6678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6678 |
rm -rf conftest* |
| 6679 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6680 |
else |
| 6681 |
echo "configure: failed program was:" >&5 |
| 6682 |
cat conftest.$ac_ext >&5 |
| 6683 |
rm -rf conftest* |
| 6684 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6685 |
fi |
| 6686 |
rm -rf conftest* |
| 6687 |
LIBS="$ac_save_LIBS" |
| 6688 |
|
| 6689 |
fi |
| 6690 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6691 |
echo "$ac_t""yes" 1>&6 |
| 6692 |
ac_tr_lib=HAVE_LIB`echo ssl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 6693 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 6694 |
cat >> confdefs.h <<EOF |
| 6695 |
#define $ac_tr_lib 1 |
| 6696 |
EOF |
| 6697 |
|
| 6698 |
LIBS="-lssl $LIBS" |
| 6699 |
|
| 6700 |
else |
| 6701 |
echo "$ac_t""no" 1>&6 |
| 6702 |
{ echo "configure: error: Can't find SSL library" 1>&2; exit 1; } |
| 6703 |
fi |
| 6704 |
|
| 6705 |
echo $ac_n "checking for query_send in -lsres""... $ac_c" 1>&6 |
| 6706 |
echo "configure:6707: checking for query_send in -lsres" >&5 |
| 6707 |
ac_lib_var=`echo sres'_'query_send | sed 'y%./+-%__p_%'` |
| 6708 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6709 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6710 |
else |
| 6711 |
ac_save_LIBS="$LIBS" |
| 6712 |
LIBS="-lsres $LIBS" |
| 6713 |
cat > conftest.$ac_ext <<EOF |
| 6714 |
#line 6715 "configure" |
| 6715 |
#include "confdefs.h" |
| 6716 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6717 |
/* We use char because int might match the return type of a gcc2 |
| 6718 |
builtin and then its argument prototype would still apply. */ |
| 6719 |
char query_send(); |
| 6720 |
|
| 6721 |
int main(void) { |
| 6722 |
query_send() |
| 6723 |
; return 0; } |
| 6724 |
EOF |
| 6725 |
if { (eval echo configure:6726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6726 |
rm -rf conftest* |
| 6727 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6728 |
else |
| 6729 |
echo "configure: failed program was:" >&5 |
| 6730 |
cat conftest.$ac_ext >&5 |
| 6731 |
rm -rf conftest* |
| 6732 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6733 |
fi |
| 6734 |
rm -rf conftest* |
| 6735 |
LIBS="$ac_save_LIBS" |
| 6736 |
|
| 6737 |
fi |
| 6738 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6739 |
echo "$ac_t""yes" 1>&6 |
| 6740 |
ac_tr_lib=HAVE_LIB`echo sres | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 6741 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 6742 |
cat >> confdefs.h <<EOF |
| 6743 |
#define $ac_tr_lib 1 |
| 6744 |
EOF |
| 6745 |
|
| 6746 |
LIBS="-lsres $LIBS" |
| 6747 |
|
| 6748 |
else |
| 6749 |
echo "$ac_t""no" 1>&6 |
| 6750 |
{ echo "configure: error: Can't find libsres" 1>&2; exit 1; } |
| 6751 |
fi |
| 6752 |
|
| 6753 |
echo $ac_n "checking for p_val_status in -lval""... $ac_c" 1>&6 |
| 6754 |
echo "configure:6755: checking for p_val_status in -lval" >&5 |
| 6755 |
ac_lib_var=`echo val'_'p_val_status | sed 'y%./+-%__p_%'` |
| 6756 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6757 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6758 |
else |
| 6759 |
ac_save_LIBS="$LIBS" |
| 6760 |
LIBS="-lval $LIBS" |
| 6761 |
cat > conftest.$ac_ext <<EOF |
| 6762 |
#line 6763 "configure" |
| 6763 |
#include "confdefs.h" |
| 6764 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6765 |
/* We use char because int might match the return type of a gcc2 |
| 6766 |
builtin and then its argument prototype would still apply. */ |
| 6767 |
char p_val_status(); |
| 6768 |
|
| 6769 |
int main(void) { |
| 6770 |
p_val_status() |
| 6771 |
; return 0; } |
| 6772 |
EOF |
| 6773 |
if { (eval echo configure:6774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6774 |
rm -rf conftest* |
| 6775 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6776 |
else |
| 6777 |
echo "configure: failed program was:" >&5 |
| 6778 |
cat conftest.$ac_ext >&5 |
| 6779 |
rm -rf conftest* |
| 6780 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6781 |
fi |
| 6782 |
rm -rf conftest* |
| 6783 |
LIBS="$ac_save_LIBS" |
| 6784 |
|
| 6785 |
fi |
| 6786 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6787 |
echo "$ac_t""yes" 1>&6 |
| 6788 |
LIBS="$LIBS -lval" |
| 6789 |
have_val_res_query=yes |
| 6790 |
else |
| 6791 |
echo "$ac_t""no" 1>&6 |
| 6792 |
echo $ac_n "checking for pthread_rwlock_init in -lpthread""... $ac_c" 1>&6 |
| 6793 |
echo "configure:6794: checking for pthread_rwlock_init in -lpthread" >&5 |
| 6794 |
ac_lib_var=`echo pthread'_'pthread_rwlock_init | sed 'y%./+-%__p_%'` |
| 6795 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6796 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6797 |
else |
| 6798 |
ac_save_LIBS="$LIBS" |
| 6799 |
LIBS="-lpthread $LIBS" |
| 6800 |
cat > conftest.$ac_ext <<EOF |
| 6801 |
#line 6802 "configure" |
| 6802 |
#include "confdefs.h" |
| 6803 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6804 |
/* We use char because int might match the return type of a gcc2 |
| 6805 |
builtin and then its argument prototype would still apply. */ |
| 6806 |
char pthread_rwlock_init(); |
| 6807 |
|
| 6808 |
int main(void) { |
| 6809 |
pthread_rwlock_init() |
| 6810 |
; return 0; } |
| 6811 |
EOF |
| 6812 |
if { (eval echo configure:6813: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6813 |
rm -rf conftest* |
| 6814 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6815 |
else |
| 6816 |
echo "configure: failed program was:" >&5 |
| 6817 |
cat conftest.$ac_ext >&5 |
| 6818 |
rm -rf conftest* |
| 6819 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6820 |
fi |
| 6821 |
rm -rf conftest* |
| 6822 |
LIBS="$ac_save_LIBS" |
| 6823 |
|
| 6824 |
fi |
| 6825 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6826 |
echo "$ac_t""yes" 1>&6 |
| 6827 |
ac_tr_lib=HAVE_LIB`echo pthread | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 6828 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 6829 |
cat >> confdefs.h <<EOF |
| 6830 |
#define $ac_tr_lib 1 |
| 6831 |
EOF |
| 6832 |
|
| 6833 |
LIBS="-lpthread $LIBS" |
| 6834 |
|
| 6835 |
else |
| 6836 |
echo "$ac_t""no" 1>&6 |
| 6837 |
fi |
| 6838 |
|
| 6839 |
echo $ac_n "checking for p_val_status in -lval-threads""... $ac_c" 1>&6 |
| 6840 |
echo "configure:6841: checking for p_val_status in -lval-threads" >&5 |
| 6841 |
ac_lib_var=`echo val-threads'_'p_val_status | sed 'y%./+-%__p_%'` |
| 6842 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 6843 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6844 |
else |
| 6845 |
ac_save_LIBS="$LIBS" |
| 6846 |
LIBS="-lval-threads $LIBS" |
| 6847 |
cat > conftest.$ac_ext <<EOF |
| 6848 |
#line 6849 "configure" |
| 6849 |
#include "confdefs.h" |
| 6850 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 6851 |
/* We use char because int might match the return type of a gcc2 |
| 6852 |
builtin and then its argument prototype would still apply. */ |
| 6853 |
char p_val_status(); |
| 6854 |
|
| 6855 |
int main(void) { |
| 6856 |
p_val_status() |
| 6857 |
; return 0; } |
| 6858 |
EOF |
| 6859 |
if { (eval echo configure:6860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 6860 |
rm -rf conftest* |
| 6861 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 6862 |
else |
| 6863 |
echo "configure: failed program was:" >&5 |
| 6864 |
cat conftest.$ac_ext >&5 |
| 6865 |
rm -rf conftest* |
| 6866 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 6867 |
fi |
| 6868 |
rm -rf conftest* |
| 6869 |
LIBS="$ac_save_LIBS" |
| 6870 |
|
| 6871 |
fi |
| 6872 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 6873 |
echo "$ac_t""yes" 1>&6 |
| 6874 |
have_val_res_query=yes |
| 6875 |
LIBS="-lval-threads $LIBS" |
| 6876 |
LIBVAL_SUFFIX="-threads" |
| 6877 |
else |
| 6878 |
echo "$ac_t""no" 1>&6 |
| 6879 |
{ echo "configure: error: Can't find libval or libval-threads" 1>&2; exit 1; } |
| 6880 |
fi |
| 6881 |
|
| 6882 |
|
| 6883 |
fi |
| 6884 |
|
| 6885 |
cat >> confdefs.h <<\EOF |
| 6886 |
#define DNSSEC_LOCAL_VALIDATION 1 |
| 6887 |
EOF |
| 6888 |
|
| 6889 |
fi |
| 6890 |
|
| 6891 |
|
| 6892 |
|
| 6893 |
echo $ac_n "checking for working const""... $ac_c" 1>&6 |
| 6894 |
echo "configure:6895: checking for working const" >&5 |
| 6895 |
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
| 6896 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6897 |
else |
| 6898 |
cat > conftest.$ac_ext <<EOF |
| 6899 |
#line 6900 "configure" |
| 6900 |
#include "confdefs.h" |
| 6901 |
|
| 6902 |
int main(void) { |
| 6903 |
|
| 6904 |
/* Ultrix mips cc rejects this. */ |
| 6905 |
typedef int charset[2]; const charset x; |
| 6906 |
/* SunOS 4.1.1 cc rejects this. */ |
| 6907 |
char const *const *ccp; |
| 6908 |
char **p; |
| 6909 |
/* NEC SVR4.0.2 mips cc rejects this. */ |
| 6910 |
struct point {int x, y;}; |
| 6911 |
static struct point const zero = {0,0}; |
| 6912 |
/* AIX XL C 1.02.0.0 rejects this. |
| 6913 |
It does not let you subtract one const X* pointer from another in an arm |
| 6914 |
of an if-expression whose if-part is not a constant expression */ |
| 6915 |
const char *g = "string"; |
| 6916 |
ccp = &g + (g ? g-g : 0); |
| 6917 |
/* HPUX 7.0 cc rejects these. */ |
| 6918 |
++ccp; |
| 6919 |
p = (char**) ccp; |
| 6920 |
ccp = (char const *const *) p; |
| 6921 |
{ /* SCO 3.2v4 cc rejects this. */ |
| 6922 |
char *t; |
| 6923 |
char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 6924 |
|
| 6925 |
*t++ = 0; |
| 6926 |
} |
| 6927 |
{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
| 6928 |
int x[] = {25, 17}; |
| 6929 |
const int *foo = &x[0]; |
| 6930 |
++foo; |
| 6931 |
} |
| 6932 |
{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 6933 |
typedef const int *iptr; |
| 6934 |
iptr p = 0; |
| 6935 |
++p; |
| 6936 |
} |
| 6937 |
{ /* AIX XL C 1.02.0.0 rejects this saying |
| 6938 |
"k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 6939 |
struct s { int j; const int *ap[3]; }; |
| 6940 |
struct s *b; b->j = 5; |
| 6941 |
} |
| 6942 |
{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 6943 |
const int foo = 10; |
| 6944 |
} |
| 6945 |
|
| 6946 |
; return 0; } |
| 6947 |
EOF |
| 6948 |
if { (eval echo configure:6949: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 6949 |
rm -rf conftest* |
| 6950 |
ac_cv_c_const=yes |
| 6951 |
else |
| 6952 |
echo "configure: failed program was:" >&5 |
| 6953 |
cat conftest.$ac_ext >&5 |
| 6954 |
rm -rf conftest* |
| 6955 |
ac_cv_c_const=no |
| 6956 |
fi |
| 6957 |
rm -rf conftest* |
| 6958 |
fi |
| 6959 |
|
| 6960 |
echo "$ac_t""$ac_cv_c_const" 1>&6 |
| 6961 |
if test $ac_cv_c_const = no; then |
| 6962 |
cat >> confdefs.h <<\EOF |
| 6963 |
#define const |
| 6964 |
EOF |
| 6965 |
|
| 6966 |
fi |
| 6967 |
|
| 6968 |
echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
| 6969 |
echo "configure:6970: checking for size_t" >&5 |
| 6970 |
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
| 6971 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 6972 |
else |
| 6973 |
cat > conftest.$ac_ext <<EOF |
| 6974 |
#line 6975 "configure" |
| 6975 |
#include "confdefs.h" |
| 6976 |
#include <sys/types.h> |
| 6977 |
#if STDC_HEADERS |
| 6978 |
# include <stdlib.h> |
| 6979 |
# include <stddef.h> |
| 6980 |
#endif |
| 6981 |
EOF |
| 6982 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 6983 |
egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 6984 |
rm -rf conftest* |
| 6985 |
ac_cv_type_size_t=yes |
| 6986 |
else |
| 6987 |
rm -rf conftest* |
| 6988 |
ac_cv_type_size_t=no |
| 6989 |
fi |
| 6990 |
rm -rf conftest* |
| 6991 |
|
| 6992 |
fi |
| 6993 |
echo "$ac_t""$ac_cv_type_size_t" 1>&6 |
| 6994 |
if test $ac_cv_type_size_t = no; then |
| 6995 |
cat >> confdefs.h <<\EOF |
| 6996 |
#define size_t unsigned |
| 6997 |
EOF |
| 6998 |
|
| 6999 |
fi |
| 7000 |
|
| 7001 |
echo $ac_n "checking for off_t""... $ac_c" 1>&6 |
| 7002 |
echo "configure:7003: checking for off_t" >&5 |
| 7003 |
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
| 7004 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7005 |
else |
| 7006 |
cat > conftest.$ac_ext <<EOF |
| 7007 |
#line 7008 "configure" |
| 7008 |
#include "confdefs.h" |
| 7009 |
#include <sys/types.h> |
| 7010 |
#if STDC_HEADERS |
| 7011 |
# include <stdlib.h> |
| 7012 |
# include <stddef.h> |
| 7013 |
#endif |
| 7014 |
EOF |
| 7015 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 7016 |
egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 7017 |
rm -rf conftest* |
| 7018 |
ac_cv_type_off_t=yes |
| 7019 |
else |
| 7020 |
rm -rf conftest* |
| 7021 |
ac_cv_type_off_t=no |
| 7022 |
fi |
| 7023 |
rm -rf conftest* |
| 7024 |
|
| 7025 |
fi |
| 7026 |
echo "$ac_t""$ac_cv_type_off_t" 1>&6 |
| 7027 |
if test $ac_cv_type_off_t = no; then |
| 7028 |
cat >> confdefs.h <<\EOF |
| 7029 |
#define off_t long |
| 7030 |
EOF |
| 7031 |
|
| 7032 |
fi |
| 7033 |
|
| 7034 |
echo $ac_n "checking for mode_t""... $ac_c" 1>&6 |
| 7035 |
echo "configure:7036: checking for mode_t" >&5 |
| 7036 |
if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then |
| 7037 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7038 |
else |
| 7039 |
cat > conftest.$ac_ext <<EOF |
| 7040 |
#line 7041 "configure" |
| 7041 |
#include "confdefs.h" |
| 7042 |
#include <sys/types.h> |
| 7043 |
#if STDC_HEADERS |
| 7044 |
# include <stdlib.h> |
| 7045 |
# include <stddef.h> |
| 7046 |
#endif |
| 7047 |
EOF |
| 7048 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 7049 |
egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 7050 |
rm -rf conftest* |
| 7051 |
ac_cv_type_mode_t=yes |
| 7052 |
else |
| 7053 |
rm -rf conftest* |
| 7054 |
ac_cv_type_mode_t=no |
| 7055 |
fi |
| 7056 |
rm -rf conftest* |
| 7057 |
|
| 7058 |
fi |
| 7059 |
echo "$ac_t""$ac_cv_type_mode_t" 1>&6 |
| 7060 |
if test $ac_cv_type_mode_t = no; then |
| 7061 |
cat >> confdefs.h <<\EOF |
| 7062 |
#define mode_t int |
| 7063 |
EOF |
| 7064 |
|
| 7065 |
fi |
| 7066 |
|
| 7067 |
echo $ac_n "checking for pid_t""... $ac_c" 1>&6 |
| 7068 |
echo "configure:7069: checking for pid_t" >&5 |
| 7069 |
if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then |
| 7070 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7071 |
else |
| 7072 |
cat > conftest.$ac_ext <<EOF |
| 7073 |
#line 7074 "configure" |
| 7074 |
#include "confdefs.h" |
| 7075 |
#include <sys/types.h> |
| 7076 |
#if STDC_HEADERS |
| 7077 |
# include <stdlib.h> |
| 7078 |
# include <stddef.h> |
| 7079 |
#endif |
| 7080 |
EOF |
| 7081 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 7082 |
egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 7083 |
rm -rf conftest* |
| 7084 |
ac_cv_type_pid_t=yes |
| 7085 |
else |
| 7086 |
rm -rf conftest* |
| 7087 |
ac_cv_type_pid_t=no |
| 7088 |
fi |
| 7089 |
rm -rf conftest* |
| 7090 |
|
| 7091 |
fi |
| 7092 |
echo "$ac_t""$ac_cv_type_pid_t" 1>&6 |
| 7093 |
if test $ac_cv_type_pid_t = no; then |
| 7094 |
cat >> confdefs.h <<\EOF |
| 7095 |
#define pid_t int |
| 7096 |
EOF |
| 7097 |
|
| 7098 |
fi |
| 7099 |
|
| 7100 |
echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 |
| 7101 |
echo "configure:7102: checking for uid_t in sys/types.h" >&5 |
| 7102 |
if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then |
| 7103 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7104 |
else |
| 7105 |
cat > conftest.$ac_ext <<EOF |
| 7106 |
#line 7107 "configure" |
| 7107 |
#include "confdefs.h" |
| 7108 |
#include <sys/types.h> |
| 7109 |
EOF |
| 7110 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 7111 |
egrep "uid_t" >/dev/null 2>&1; then |
| 7112 |
rm -rf conftest* |
| 7113 |
ac_cv_type_uid_t=yes |
| 7114 |
else |
| 7115 |
rm -rf conftest* |
| 7116 |
ac_cv_type_uid_t=no |
| 7117 |
fi |
| 7118 |
rm -rf conftest* |
| 7119 |
|
| 7120 |
fi |
| 7121 |
|
| 7122 |
echo "$ac_t""$ac_cv_type_uid_t" 1>&6 |
| 7123 |
if test $ac_cv_type_uid_t = no; then |
| 7124 |
cat >> confdefs.h <<\EOF |
| 7125 |
#define uid_t int |
| 7126 |
EOF |
| 7127 |
|
| 7128 |
cat >> confdefs.h <<\EOF |
| 7129 |
#define gid_t int |
| 7130 |
EOF |
| 7131 |
|
| 7132 |
fi |
| 7133 |
|
| 7134 |
|
| 7135 |
echo $ac_n "checking what type main() should return""... $ac_c" 1>&6 |
| 7136 |
echo "configure:7137: checking what type main() should return" >&5 |
| 7137 |
if eval "test \"`echo '$''{'wi_cv_main_void_return_t'+set}'`\" = set"; then |
| 7138 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7139 |
else |
| 7140 |
|
| 7141 |
wi_cv_main_void_return_t="int" |
| 7142 |
case "${GCC}_${SYS}" in |
| 7143 |
no_irix*|no_hpux) |
| 7144 |
wi_cv_main_void_return_t="void" |
| 7145 |
;; |
| 7146 |
esac |
| 7147 |
|
| 7148 |
fi |
| 7149 |
|
| 7150 |
echo "$ac_t""$wi_cv_main_void_return_t" 1>&6 |
| 7151 |
cat >> confdefs.h <<EOF |
| 7152 |
#define main_void_return_t $wi_cv_main_void_return_t |
| 7153 |
EOF |
| 7154 |
|
| 7155 |
|
| 7156 |
|
| 7157 |
|
| 7158 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 7159 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_USE_LONG_LONG." 1>&2; exit 1; } |
| 7160 |
fi |
| 7161 |
|
| 7162 |
echo $ac_n "checking for 64-bit integral type: long long""... $ac_c" 1>&6 |
| 7163 |
echo "configure:7164: checking for 64-bit integral type: long long" >&5 |
| 7164 |
LONGEST_INT="long" |
| 7165 |
if test "$cross_compiling" = yes; then |
| 7166 |
|
| 7167 |
# action if cross compiling |
| 7168 |
guess="(guessing) " |
| 7169 |
wi_cv_type_long_long=yes |
| 7170 |
LONGEST_INT="long long" |
| 7171 |
|
| 7172 |
else |
| 7173 |
cat > conftest.$ac_ext <<EOF |
| 7174 |
#line 7175 "configure" |
| 7175 |
#include "confdefs.h" |
| 7176 |
|
| 7177 |
/* program */ |
| 7178 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 7179 |
# define _ALL_SOURCE 1 |
| 7180 |
#endif |
| 7181 |
#ifdef HAVE_UNISTD_H |
| 7182 |
# include <unistd.h> |
| 7183 |
#endif |
| 7184 |
#include <sys/types.h> |
| 7185 |
#include <stdio.h> |
| 7186 |
#ifdef HAVE_STDLIB_H |
| 7187 |
# include <stdlib.h> |
| 7188 |
#endif |
| 7189 |
|
| 7190 |
long long hugeNumvar = 1; |
| 7191 |
|
| 7192 |
int main(void) |
| 7193 |
{ |
| 7194 |
long long hugeNumtoo = 2; |
| 7195 |
|
| 7196 |
if (hugeNumtoo > hugeNumvar) |
| 7197 |
hugeNumvar++; |
| 7198 |
if (sizeof(hugeNumvar) < 8) |
| 7199 |
exit(1); |
| 7200 |
exit(0); |
| 7201 |
} |
| 7202 |
|
| 7203 |
|
| 7204 |
EOF |
| 7205 |
if { (eval echo configure:7206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 7206 |
then |
| 7207 |
|
| 7208 |
# action if true |
| 7209 |
guess="" |
| 7210 |
wi_cv_type_long_long=yes |
| 7211 |
LONGEST_INT="long long" |
| 7212 |
|
| 7213 |
else |
| 7214 |
echo "configure: failed program was:" >&5 |
| 7215 |
cat conftest.$ac_ext >&5 |
| 7216 |
rm -fr conftest* |
| 7217 |
|
| 7218 |
# action if false |
| 7219 |
guess="" |
| 7220 |
wi_cv_type_long_long=no |
| 7221 |
|
| 7222 |
fi |
| 7223 |
rm -fr conftest* |
| 7224 |
fi |
| 7225 |
|
| 7226 |
echo "$ac_t""$guess$wi_cv_type_long_long" 1>&6 |
| 7227 |
|
| 7228 |
if test "$wi_cv_type_long_long" = yes ; then |
| 7229 |
|
| 7230 |
echo $ac_n "checking how to print a 64-bit integral type""... $ac_c" 1>&6 |
| 7231 |
echo "configure:7232: checking how to print a 64-bit integral type" >&5 |
| 7232 |
wi_cv_printf_long_long=fail |
| 7233 |
|
| 7234 |
if test "$cross_compiling" = yes; then |
| 7235 |
|
| 7236 |
# action if cross compiling |
| 7237 |
guess="(guessing) " |
| 7238 |
wi_cv_printf_long_long="%lld" |
| 7239 |
|
| 7240 |
else |
| 7241 |
cat > conftest.$ac_ext <<EOF |
| 7242 |
#line 7243 "configure" |
| 7243 |
#include "confdefs.h" |
| 7244 |
|
| 7245 |
/* program */ |
| 7246 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 7247 |
# define _ALL_SOURCE 1 |
| 7248 |
#endif |
| 7249 |
#ifdef HAVE_UNISTD_H |
| 7250 |
# include <unistd.h> |
| 7251 |
#endif |
| 7252 |
#include <sys/types.h> |
| 7253 |
#include <stdio.h> |
| 7254 |
#include <string.h> |
| 7255 |
#ifdef HAVE_STDLIB_H |
| 7256 |
# include <stdlib.h> |
| 7257 |
#endif |
| 7258 |
|
| 7259 |
int main(void) |
| 7260 |
{ |
| 7261 |
char s[80]; |
| 7262 |
long long hugeNum; |
| 7263 |
|
| 7264 |
hugeNum = (long long) 1000000000; |
| 7265 |
hugeNum = hugeNum * (long long) 99; |
| 7266 |
hugeNum = hugeNum + (long long) 1; |
| 7267 |
|
| 7268 |
(void) sprintf(s, "%lld", hugeNum); |
| 7269 |
exit((strcmp(s, "99000000001") == 0) ? 0 : 1); |
| 7270 |
} |
| 7271 |
|
| 7272 |
EOF |
| 7273 |
if { (eval echo configure:7274: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 7274 |
then |
| 7275 |
|
| 7276 |
# action if true |
| 7277 |
guess="" |
| 7278 |
wi_cv_printf_long_long="%lld" |
| 7279 |
|
| 7280 |
else |
| 7281 |
echo "configure: failed program was:" >&5 |
| 7282 |
cat conftest.$ac_ext >&5 |
| 7283 |
rm -fr conftest* |
| 7284 |
|
| 7285 |
# action if false |
| 7286 |
guess="" |
| 7287 |
|
| 7288 |
fi |
| 7289 |
rm -fr conftest* |
| 7290 |
fi |
| 7291 |
|
| 7292 |
|
| 7293 |
|
| 7294 |
if test "$wi_cv_printf_long_long" = fail ; then |
| 7295 |
|
| 7296 |
if test "$cross_compiling" = yes; then |
| 7297 |
|
| 7298 |
# action if cross compiling |
| 7299 |
: |
| 7300 |
|
| 7301 |
else |
| 7302 |
cat > conftest.$ac_ext <<EOF |
| 7303 |
#line 7304 "configure" |
| 7304 |
#include "confdefs.h" |
| 7305 |
|
| 7306 |
/* program */ |
| 7307 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 7308 |
# define _ALL_SOURCE 1 |
| 7309 |
#endif |
| 7310 |
#ifdef HAVE_UNISTD_H |
| 7311 |
# include <unistd.h> |
| 7312 |
#endif |
| 7313 |
#include <sys/types.h> |
| 7314 |
#include <stdio.h> |
| 7315 |
#include <string.h> |
| 7316 |
#ifdef HAVE_STDLIB_H |
| 7317 |
# include <stdlib.h> |
| 7318 |
#endif |
| 7319 |
|
| 7320 |
int main(void) |
| 7321 |
{ |
| 7322 |
char s[80]; |
| 7323 |
long long hugeNum; |
| 7324 |
|
| 7325 |
hugeNum = (long long) 1000000000; |
| 7326 |
hugeNum = hugeNum * (long long) 99; |
| 7327 |
hugeNum = hugeNum + (long long) 1; |
| 7328 |
|
| 7329 |
(void) sprintf(s, "%qd", hugeNum); |
| 7330 |
exit((strcmp(s, "99000000001") == 0) ? 0 : 1); |
| 7331 |
} |
| 7332 |
|
| 7333 |
EOF |
| 7334 |
if { (eval echo configure:7335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 7335 |
then |
| 7336 |
|
| 7337 |
# action if true |
| 7338 |
wi_cv_printf_long_long="%qd" |
| 7339 |
|
| 7340 |
else |
| 7341 |
echo "configure: failed program was:" >&5 |
| 7342 |
cat conftest.$ac_ext >&5 |
| 7343 |
rm -fr conftest* |
| 7344 |
|
| 7345 |
# action if false |
| 7346 |
: |
| 7347 |
|
| 7348 |
fi |
| 7349 |
rm -fr conftest* |
| 7350 |
fi |
| 7351 |
|
| 7352 |
fi |
| 7353 |
|
| 7354 |
if test "$wi_cv_printf_long_long" = fail ; then |
| 7355 |
wi_cv_printf_long_long_msg_result='cannot print' |
| 7356 |
else |
| 7357 |
wi_cv_printf_long_long_msg_result="$wi_cv_printf_long_long" |
| 7358 |
fi |
| 7359 |
|
| 7360 |
echo "$ac_t""$guess$wi_cv_printf_long_long_msg_result" 1>&6 |
| 7361 |
|
| 7362 |
|
| 7363 |
echo $ac_n "checking how to scan a 64-bit integral type""... $ac_c" 1>&6 |
| 7364 |
echo "configure:7365: checking how to scan a 64-bit integral type" >&5 |
| 7365 |
wi_cv_scanf_long_long=fail |
| 7366 |
|
| 7367 |
if test "$cross_compiling" = yes; then |
| 7368 |
|
| 7369 |
# action if cross compiling |
| 7370 |
guess="(guessing) " |
| 7371 |
wi_cv_scanf_long_long="%lld" |
| 7372 |
|
| 7373 |
else |
| 7374 |
cat > conftest.$ac_ext <<EOF |
| 7375 |
#line 7376 "configure" |
| 7376 |
#include "confdefs.h" |
| 7377 |
|
| 7378 |
/* program */ |
| 7379 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 7380 |
# define _ALL_SOURCE 1 |
| 7381 |
#endif |
| 7382 |
#ifdef HAVE_UNISTD_H |
| 7383 |
# include <unistd.h> |
| 7384 |
#endif |
| 7385 |
#include <sys/types.h> |
| 7386 |
#include <stdio.h> |
| 7387 |
#include <string.h> |
| 7388 |
#ifdef HAVE_STDLIB_H |
| 7389 |
# include <stdlib.h> |
| 7390 |
#endif |
| 7391 |
|
| 7392 |
int main(void) |
| 7393 |
{ |
| 7394 |
long long hugeNum, justAsHugeNum; |
| 7395 |
|
| 7396 |
hugeNum = (long long) 1000000000; |
| 7397 |
hugeNum = hugeNum * (long long) 99; |
| 7398 |
hugeNum = hugeNum + (long long) 1; |
| 7399 |
|
| 7400 |
justAsHugeNum = (long long) 0; |
| 7401 |
--justAsHugeNum; |
| 7402 |
sscanf("99000000001", "%lld", &justAsHugeNum); |
| 7403 |
if (memcmp(&hugeNum, &justAsHugeNum, sizeof(hugeNum)) == 0) |
| 7404 |
exit(0); |
| 7405 |
exit(1); |
| 7406 |
} |
| 7407 |
|
| 7408 |
EOF |
| 7409 |
if { (eval echo configure:7410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 7410 |
then |
| 7411 |
|
| 7412 |
# action if true |
| 7413 |
guess="" |
| 7414 |
wi_cv_scanf_long_long="%lld" |
| 7415 |
|
| 7416 |
else |
| 7417 |
echo "configure: failed program was:" >&5 |
| 7418 |
cat conftest.$ac_ext >&5 |
| 7419 |
rm -fr conftest* |
| 7420 |
|
| 7421 |
# action if false |
| 7422 |
guess="" |
| 7423 |
|
| 7424 |
fi |
| 7425 |
rm -fr conftest* |
| 7426 |
fi |
| 7427 |
|
| 7428 |
|
| 7429 |
|
| 7430 |
if test "$wi_cv_scanf_long_long" = fail ; then |
| 7431 |
|
| 7432 |
if test "$cross_compiling" = yes; then |
| 7433 |
|
| 7434 |
# action if cross compiling |
| 7435 |
: |
| 7436 |
|
| 7437 |
else |
| 7438 |
cat > conftest.$ac_ext <<EOF |
| 7439 |
#line 7440 "configure" |
| 7440 |
#include "confdefs.h" |
| 7441 |
|
| 7442 |
/* program */ |
| 7443 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 7444 |
# define _ALL_SOURCE 1 |
| 7445 |
#endif |
| 7446 |
#ifdef HAVE_UNISTD_H |
| 7447 |
# include <unistd.h> |
| 7448 |
#endif |
| 7449 |
#include <sys/types.h> |
| 7450 |
#include <stdio.h> |
| 7451 |
#include <string.h> |
| 7452 |
#ifdef HAVE_STDLIB_H |
| 7453 |
# include <stdlib.h> |
| 7454 |
#endif |
| 7455 |
|
| 7456 |
int main(void) |
| 7457 |
{ |
| 7458 |
long long hugeNum, justAsHugeNum; |
| 7459 |
|
| 7460 |
hugeNum = (long long) 1000000000; |
| 7461 |
hugeNum = hugeNum * (long long) 99; |
| 7462 |
hugeNum = hugeNum + (long long) 1; |
| 7463 |
|
| 7464 |
justAsHugeNum = (long long) 0; |
| 7465 |
--justAsHugeNum; |
| 7466 |
sscanf("99000000001", "%qd", &justAsHugeNum); |
| 7467 |
if (memcmp(&hugeNum, &justAsHugeNum, sizeof(hugeNum)) == 0) |
| 7468 |
exit(0); |
| 7469 |
exit(1); |
| 7470 |
} |
| 7471 |
|
| 7472 |
EOF |
| 7473 |
if { (eval echo configure:7474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 7474 |
then |
| 7475 |
|
| 7476 |
# action if true |
| 7477 |
wi_cv_scanf_long_long="%qd" |
| 7478 |
|
| 7479 |
else |
| 7480 |
echo "configure: failed program was:" >&5 |
| 7481 |
cat conftest.$ac_ext >&5 |
| 7482 |
rm -fr conftest* |
| 7483 |
|
| 7484 |
# action if false |
| 7485 |
: |
| 7486 |
|
| 7487 |
fi |
| 7488 |
rm -fr conftest* |
| 7489 |
fi |
| 7490 |
|
| 7491 |
fi |
| 7492 |
|
| 7493 |
if test "$wi_cv_scanf_long_long" = fail ; then |
| 7494 |
wi_cv_scanf_long_long_msg_result='cannot scan' |
| 7495 |
else |
| 7496 |
wi_cv_scanf_long_long_msg_result="$wi_cv_scanf_long_long" |
| 7497 |
fi |
| 7498 |
|
| 7499 |
echo "$ac_t""$guess$wi_cv_scanf_long_long_msg_result" 1>&6 |
| 7500 |
|
| 7501 |
fi |
| 7502 |
|
| 7503 |
echo $ac_n "checking if everything was available to use the 64-bit integral type""... $ac_c" 1>&6 |
| 7504 |
echo "configure:7505: checking if everything was available to use the 64-bit integral type" >&5 |
| 7505 |
|
| 7506 |
if test "$wi_cv_type_long_long" = no ; then |
| 7507 |
wi_cv_use_long_long_msg_result="no (long long type not available)" |
| 7508 |
wi_cv_use_long_long="no" |
| 7509 |
wi_cv_scanf_long_long="fail" |
| 7510 |
wi_cv_prihtf_long_long="fail" |
| 7511 |
LONGEST_INT="long" |
| 7512 |
elif test "$wi_cv_printf_long_long" = fail ; then |
| 7513 |
wi_cv_use_long_long_msg_result="no (libc printf() does not support them)" |
| 7514 |
wi_cv_use_long_long="no" |
| 7515 |
wi_cv_scanf_long_long="fail" |
| 7516 |
wi_cv_prihtf_long_long="fail" |
| 7517 |
LONGEST_INT="long" |
| 7518 |
elif test "$wi_cv_scanf_long_long" = fail ; then |
| 7519 |
wi_cv_use_long_long_msg_result="no (libc scanf() does not support them)" |
| 7520 |
wi_cv_use_long_long="no" |
| 7521 |
wi_cv_scanf_long_long="fail" |
| 7522 |
wi_cv_prihtf_long_long="fail" |
| 7523 |
LONGEST_INT="long" |
| 7524 |
else |
| 7525 |
cat >> confdefs.h <<\EOF |
| 7526 |
#define HAVE_LONG_LONG 1 |
| 7527 |
EOF |
| 7528 |
|
| 7529 |
if test "$wi_cv_printf_long_long$wi_cv_scanf_long_long" = "%lld%qd" ; then |
| 7530 |
# FreeBSD 3.2 has %lld and %qd, but we want to |
| 7531 |
# run on 3.1 and 3.0. |
| 7532 |
# |
| 7533 |
wi_cv_printf_long_long="%qd" |
| 7534 |
fi |
| 7535 |
wi_cv_printf_ulong_long=`echo "$wi_cv_printf_long_long" | sed 's/d$/u/;'` |
| 7536 |
wi_cv_scanf_ulong_long=`echo "$wi_cv_scanf_long_long" | sed 's/d$/u/;'` |
| 7537 |
cat >> confdefs.h <<EOF |
| 7538 |
#define PRINTF_LONG_LONG "$wi_cv_printf_long_long" |
| 7539 |
EOF |
| 7540 |
|
| 7541 |
cat >> confdefs.h <<EOF |
| 7542 |
#define SCANF_LONG_LONG "$wi_cv_scanf_long_long" |
| 7543 |
EOF |
| 7544 |
|
| 7545 |
cat >> confdefs.h <<EOF |
| 7546 |
#define PRINTF_ULONG_LONG "$wi_cv_printf_ulong_long" |
| 7547 |
EOF |
| 7548 |
|
| 7549 |
cat >> confdefs.h <<EOF |
| 7550 |
#define SCANF_ULONG_LONG "$wi_cv_scanf_ulong_long" |
| 7551 |
EOF |
| 7552 |
|
| 7553 |
if test "$wi_cv_printf_long_long" = "%qd" ; then |
| 7554 |
cat >> confdefs.h <<\EOF |
| 7555 |
#define PRINTF_LONG_LONG_QD 1 |
| 7556 |
EOF |
| 7557 |
|
| 7558 |
else |
| 7559 |
cat >> confdefs.h <<\EOF |
| 7560 |
#define PRINTF_LONG_LONG_LLD 1 |
| 7561 |
EOF |
| 7562 |
|
| 7563 |
fi |
| 7564 |
if test "$wi_cv_scanf_long_long" = "%qd" ; then |
| 7565 |
cat >> confdefs.h <<\EOF |
| 7566 |
#define SCANF_LONG_LONG_QD 1 |
| 7567 |
EOF |
| 7568 |
|
| 7569 |
else |
| 7570 |
cat >> confdefs.h <<\EOF |
| 7571 |
#define SCANF_LONG_LONG_LLD 1 |
| 7572 |
EOF |
| 7573 |
|
| 7574 |
fi |
| 7575 |
wi_cv_use_long_long="yes" |
| 7576 |
wi_cv_use_long_long_msg_result="yes" |
| 7577 |
fi |
| 7578 |
echo "$ac_t""$wi_cv_use_long_long_msg_result" 1>&6 |
| 7579 |
|
| 7580 |
|
| 7581 |
wi_struct_timeval_field_checks="cached" |
| 7582 |
echo $ac_n "checking what type the tv_sec field of struct timeval is""... $ac_c" 1>&6 |
| 7583 |
echo "configure:7584: checking what type the tv_sec field of struct timeval is" >&5 |
| 7584 |
if eval "test \"`echo '$''{'wi_cv_struct_timeval_tv_sec'+set}'`\" = set"; then |
| 7585 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7586 |
else |
| 7587 |
|
| 7588 |
wi_struct_timeval_field_checks="uncached" |
| 7589 |
|
| 7590 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 7591 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_STRUCT_TIMEVAL_FIELD_TYPES." 1>&2; exit 1; } |
| 7592 |
fi |
| 7593 |
|
| 7594 |
if test "$cross_compiling" = yes; then |
| 7595 |
|
| 7596 |
# action if cross compiling |
| 7597 |
guess="(guessing) " |
| 7598 |
guess2="$guess" |
| 7599 |
wi_cv_struct_timeval_tv_sec="long" |
| 7600 |
wi_cv_struct_timeval_tv_usec="long" |
| 7601 |
|
| 7602 |
else |
| 7603 |
cat > conftest.$ac_ext <<EOF |
| 7604 |
#line 7605 "configure" |
| 7605 |
#include "confdefs.h" |
| 7606 |
|
| 7607 |
/* program */ |
| 7608 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 7609 |
# define _ALL_SOURCE 1 |
| 7610 |
#endif |
| 7611 |
#ifdef HAVE_UNISTD_H |
| 7612 |
# include <unistd.h> |
| 7613 |
#endif |
| 7614 |
#include <sys/types.h> |
| 7615 |
#include <sys/time.h> |
| 7616 |
#include <stdio.h> |
| 7617 |
#include <stdlib.h> |
| 7618 |
#include <string.h> |
| 7619 |
|
| 7620 |
static void |
| 7621 |
neg(void *dst0, size_t siz) |
| 7622 |
{ |
| 7623 |
unsigned char *dst = (unsigned char *) dst0; |
| 7624 |
unsigned char *dlim; |
| 7625 |
|
| 7626 |
dlim = dst + siz; |
| 7627 |
while (dst < dlim) |
| 7628 |
*dst++ = (unsigned char) 0xEE; |
| 7629 |
} |
| 7630 |
|
| 7631 |
int |
| 7632 |
main(int argc, char **argv) |
| 7633 |
{ |
| 7634 |
FILE *fp; |
| 7635 |
const char *typ; |
| 7636 |
struct timeval tv; |
| 7637 |
#define x tv.tv_sec |
| 7638 |
|
| 7639 |
memset(&tv, 0, sizeof(tv)); |
| 7640 |
fp = stdout; |
| 7641 |
if (argc == 1) { |
| 7642 |
fp = fopen("conftest.out", "w"); |
| 7643 |
if (fp == NULL) { |
| 7644 |
perror("could not write to ./conftest.out"); |
| 7645 |
exit(1); |
| 7646 |
} |
| 7647 |
} |
| 7648 |
|
| 7649 |
neg(&x, sizeof(x)); |
| 7650 |
#ifdef HAVE_LONG_LONG |
| 7651 |
if (sizeof(x) == sizeof(long long)) { |
| 7652 |
typ = "long long"; |
| 7653 |
} else |
| 7654 |
#endif |
| 7655 |
if (sizeof(x) == sizeof(long)) { |
| 7656 |
typ = "long"; |
| 7657 |
} else { |
| 7658 |
typ = "int"; |
| 7659 |
} |
| 7660 |
(void) fprintf(fp, "%s%s\n", (x > 0) ? "unsigned " : "", typ); |
| 7661 |
#undef x |
| 7662 |
|
| 7663 |
#define x tv.tv_usec |
| 7664 |
neg(&x, sizeof(x)); |
| 7665 |
#ifdef HAVE_LONG_LONG |
| 7666 |
if (sizeof(x) == sizeof(long long)) { |
| 7667 |
typ = "long long"; |
| 7668 |
} else |
| 7669 |
#endif |
| 7670 |
if (sizeof(x) == sizeof(long)) { |
| 7671 |
typ = "long"; |
| 7672 |
} else { |
| 7673 |
typ = "int"; |
| 7674 |
} |
| 7675 |
(void) fprintf(fp, "%s%s\n", (x > 0) ? "unsigned " : "", typ); |
| 7676 |
#undef x |
| 7677 |
|
| 7678 |
if (fp != stdout) |
| 7679 |
(void) fclose(fp); |
| 7680 |
exit(0); |
| 7681 |
} |
| 7682 |
|
| 7683 |
EOF |
| 7684 |
if { (eval echo configure:7685: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 7685 |
then |
| 7686 |
|
| 7687 |
# action if true |
| 7688 |
guess="" |
| 7689 |
if test -f conftest.out ; then |
| 7690 |
wi_cv_struct_timeval_tv_sec="`sed -n '1,1p' conftest.out`" |
| 7691 |
wi_cv_struct_timeval_tv_usec="`sed -n '2,2p' conftest.out`" |
| 7692 |
fi |
| 7693 |
|
| 7694 |
else |
| 7695 |
echo "configure: failed program was:" >&5 |
| 7696 |
cat conftest.$ac_ext >&5 |
| 7697 |
rm -fr conftest* |
| 7698 |
|
| 7699 |
# action if false |
| 7700 |
guess="" |
| 7701 |
wi_cv_struct_timeval_tv_sec="long" |
| 7702 |
wi_cv_struct_timeval_tv_usec="long" |
| 7703 |
|
| 7704 |
fi |
| 7705 |
rm -fr conftest* |
| 7706 |
fi |
| 7707 |
|
| 7708 |
rm -f conftest.out |
| 7709 |
|
| 7710 |
fi |
| 7711 |
|
| 7712 |
echo "$ac_t""$guess$wi_cv_struct_timeval_tv_sec" 1>&6 |
| 7713 |
guess="" |
| 7714 |
|
| 7715 |
if test "$wi_struct_timeval_field_checks" = "uncached" ; then |
| 7716 |
guess="$guess2" |
| 7717 |
echo $ac_n "checking what type the tv_usec field of struct timeval is""... $ac_c" 1>&6 |
| 7718 |
echo "configure:7719: checking what type the tv_usec field of struct timeval is" >&5 |
| 7719 |
echo "$ac_t""$guess$wi_cv_struct_timeval_tv_usec" 1>&6 |
| 7720 |
else |
| 7721 |
guess="$guess2" |
| 7722 |
echo $ac_n "checking what type the tv_usec field of struct timeval is""... $ac_c" 1>&6 |
| 7723 |
echo "configure:7724: checking what type the tv_usec field of struct timeval is" >&5 |
| 7724 |
if eval "test \"`echo '$''{'wi_cv_struct_timeval_tv_usec'+set}'`\" = set"; then |
| 7725 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7726 |
else |
| 7727 |
: |
| 7728 |
fi |
| 7729 |
|
| 7730 |
echo "$ac_t""$guess$wi_cv_struct_timeval_tv_usec" 1>&6 |
| 7731 |
guess="" |
| 7732 |
|
| 7733 |
fi |
| 7734 |
cat >> confdefs.h <<EOF |
| 7735 |
#define tv_sec_t $wi_cv_struct_timeval_tv_sec |
| 7736 |
EOF |
| 7737 |
|
| 7738 |
cat >> confdefs.h <<EOF |
| 7739 |
#define tv_usec_t $wi_cv_struct_timeval_tv_usec |
| 7740 |
EOF |
| 7741 |
|
| 7742 |
|
| 7743 |
|
| 7744 |
# Extract the first word of ""perl"", so it can be a program name with args. |
| 7745 |
set dummy "perl"; ac_word=$2 |
| 7746 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 7747 |
echo "configure:7748: checking for $ac_word" >&5 |
| 7748 |
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then |
| 7749 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7750 |
else |
| 7751 |
case "$PERL" in |
| 7752 |
/*) |
| 7753 |
ac_cv_path_PERL="$PERL" # Let the user override the test with a path. |
| 7754 |
;; |
| 7755 |
?:/*) |
| 7756 |
ac_cv_path_PERL="$PERL" # Let the user override the test with a dos path. |
| 7757 |
;; |
| 7758 |
*) |
| 7759 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 7760 |
ac_dummy="$PATH" |
| 7761 |
for ac_dir in $ac_dummy; do |
| 7762 |
test -z "$ac_dir" && ac_dir=. |
| 7763 |
if test -f $ac_dir/$ac_word; then |
| 7764 |
ac_cv_path_PERL="$ac_dir/$ac_word" |
| 7765 |
break |
| 7766 |
fi |
| 7767 |
done |
| 7768 |
IFS="$ac_save_ifs" |
| 7769 |
test -z "$ac_cv_path_PERL" && ac_cv_path_PERL=""perl"" |
| 7770 |
;; |
| 7771 |
esac |
| 7772 |
fi |
| 7773 |
PERL="$ac_cv_path_PERL" |
| 7774 |
if test -n "$PERL"; then |
| 7775 |
echo "$ac_t""$PERL" 1>&6 |
| 7776 |
else |
| 7777 |
echo "$ac_t""no" 1>&6 |
| 7778 |
fi |
| 7779 |
|
| 7780 |
|
| 7781 |
|
| 7782 |
# Extract the first word of ""mktemp"", so it can be a program name with args. |
| 7783 |
set dummy "mktemp"; ac_word=$2 |
| 7784 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 7785 |
echo "configure:7786: checking for $ac_word" >&5 |
| 7786 |
if eval "test \"`echo '$''{'ac_cv_path_MKTEMP'+set}'`\" = set"; then |
| 7787 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7788 |
else |
| 7789 |
case "$MKTEMP" in |
| 7790 |
/*) |
| 7791 |
ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. |
| 7792 |
;; |
| 7793 |
?:/*) |
| 7794 |
ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a dos path. |
| 7795 |
;; |
| 7796 |
*) |
| 7797 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 7798 |
ac_dummy="$PATH" |
| 7799 |
for ac_dir in $ac_dummy; do |
| 7800 |
test -z "$ac_dir" && ac_dir=. |
| 7801 |
if test -f $ac_dir/$ac_word; then |
| 7802 |
ac_cv_path_MKTEMP="$ac_dir/$ac_word" |
| 7803 |
break |
| 7804 |
fi |
| 7805 |
done |
| 7806 |
IFS="$ac_save_ifs" |
| 7807 |
test -z "$ac_cv_path_MKTEMP" && ac_cv_path_MKTEMP="""" |
| 7808 |
;; |
| 7809 |
esac |
| 7810 |
fi |
| 7811 |
MKTEMP="$ac_cv_path_MKTEMP" |
| 7812 |
if test -n "$MKTEMP"; then |
| 7813 |
echo "$ac_t""$MKTEMP" 1>&6 |
| 7814 |
else |
| 7815 |
echo "$ac_t""no" 1>&6 |
| 7816 |
fi |
| 7817 |
|
| 7818 |
|
| 7819 |
|
| 7820 |
|
| 7821 |
|
| 7822 |
|
| 7823 |
|
| 7824 |
|
| 7825 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 7826 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_UNISTD_FUNC_PARAM_TYPES." 1>&2; exit 1; } |
| 7827 |
fi |
| 7828 |
|
| 7829 |
echo $ac_n "checking for return type from write""... $ac_c" 1>&6 |
| 7830 |
echo "configure:7831: checking for return type from write" >&5 |
| 7831 |
if eval "test \"`echo '$''{'wi_cv_write_return_t'+set}'`\" = set"; then |
| 7832 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 7833 |
else |
| 7834 |
|
| 7835 |
used_cache_for_wi_unistd_fpt="no" |
| 7836 |
|
| 7837 |
|
| 7838 |
wi_tmpdir="" |
| 7839 |
if [ "x$MKTEMP" != "x" ] ; then |
| 7840 |
# Ignore error from mktemp, since some old versions of Linux |
| 7841 |
# print an error about not supporting -d. |
| 7842 |
# |
| 7843 |
wi_tmpdir=`"$MKTEMP" -d /tmp/configure.XXXXXXXXXX 2>/dev/null` |
| 7844 |
if [ $? -ne 0 ] ; then |
| 7845 |
wi_tmpdir="" |
| 7846 |
fi |
| 7847 |
fi |
| 7848 |
if [ "x$wi_tmpdir" = "x" ] ; then |
| 7849 |
for wi_tmpdir in . $TMPDIR $TEMPDIR /tmp ABORT |
| 7850 |
do |
| 7851 |
if [ "$wi_tmpdir" = ABORT ] ; then |
| 7852 |
echo "Cannot create temporary directory." |
| 7853 |
exit 1 |
| 7854 |
fi |
| 7855 |
wi_tmpdir="$wi_tmpdir/config_tmp.$$" |
| 7856 |
if [ -d "$wi_tmpdir" ] || [ -f "$wi_tmpdir" ] ; then |
| 7857 |
echo "Will not create temporary directory." |
| 7858 |
exit 1 |
| 7859 |
fi |
| 7860 |
mkdir "$wi_tmpdir" |
| 7861 |
if [ $? -eq 0 ] && [ -d "$wi_tmpdir" ] ; then break ; fi |
| 7862 |
done |
| 7863 |
fi |
| 7864 |
|
| 7865 |
# Use the temporary directory here... |
| 7866 |
|
| 7867 |
|
| 7868 |
cat << 'EOF' > "$wi_tmpdir/prpp.pl" |
| 7869 |
#!/usr/bin/perl -w |
| 7870 |
# |
| 7871 |
# prpp.pl |
| 7872 |
# |
| 7873 |
# Feed the output of your CPP to this to print a list of function prototypes. |
| 7874 |
# |
| 7875 |
#use strict; |
| 7876 |
|
| 7877 |
my ($c) = ""; |
| 7878 |
my ($unputc) = ""; |
| 7879 |
my ($line) = ""; |
| 7880 |
my ($lines) = ""; |
| 7881 |
my ($cline) = ""; |
| 7882 |
my ($skipping) = 0; |
| 7883 |
my ($numclines) = 0; |
| 7884 |
|
| 7885 |
MAINLOOP: while (1) { |
| 7886 |
if ($unputc ne "") { |
| 7887 |
$c = $unputc; |
| 7888 |
$unputc = ""; |
| 7889 |
} else { |
| 7890 |
last unless (read(STDIN, $c, 1) == 1); |
| 7891 |
} |
| 7892 |
if ($c eq "{") { |
| 7893 |
$skipping++; |
| 7894 |
} elsif ($c eq "}") { |
| 7895 |
--$skipping; |
| 7896 |
$unputc = ";"; |
| 7897 |
} elsif ($skipping) { |
| 7898 |
next MAINLOOP; |
| 7899 |
} elsif ($c eq ";") { |
| 7900 |
if ($line =~ m/^\s*(\S.*\S)\s*$/s) { |
| 7901 |
$lines .= $1; |
| 7902 |
$line = ""; |
| 7903 |
} |
| 7904 |
if ($lines =~ m/^\s*(extern\s*)?(\S.*\S)\s*$/s) { |
| 7905 |
$cline = $2; |
| 7906 |
$cline =~ s/\s+/\ /g; |
| 7907 |
if ($cline =~ /^typedef/) { |
| 7908 |
$cline = ""; |
| 7909 |
} elsif ($cline =~ /\(.*\)$/) { |
| 7910 |
# found a proto |
| 7911 |
print $cline, ";\n"; |
| 7912 |
$numclines++; |
| 7913 |
} else { |
| 7914 |
$cline = ""; |
| 7915 |
} |
| 7916 |
} |
| 7917 |
$lines = ""; |
| 7918 |
$line = ""; |
| 7919 |
} elsif ($c eq "\n") { |
| 7920 |
if ($line =~ m/^\s*(\S.*\S)\s*$/s) { |
| 7921 |
$lines .= $1 . " "; |
| 7922 |
$line = ""; |
| 7923 |
} |
| 7924 |
} elsif (($c eq "#") && ($line eq "")) { |
| 7925 |
# Looks like a preprocessor line, kill it |
| 7926 |
{ |
| 7927 |
last MAINLOOP if (read(STDIN, $c, 1) != 1); |
| 7928 |
last if ($c eq "\n"); |
| 7929 |
redo; |
| 7930 |
} |
| 7931 |
} elsif ($c =~ /^\s$/) { |
| 7932 |
$line .= " " if ($line ne ""); |
| 7933 |
} elsif (! $skipping) { |
| 7934 |
$line .= $c; |
| 7935 |
} |
| 7936 |
} |
| 7937 |
exit(($numclines == 0) ? 1 : 0); |
| 7938 |
EOF |
| 7939 |
chmod 755 "$wi_tmpdir/prpp.pl" |
| 7940 |
|
| 7941 |
|
| 7942 |
cat << 'EOF' > "$wi_tmpdir/unistd.c" |
| 7943 |
#include <confdefs.h> |
| 7944 |
|
| 7945 |
#include <unistd.h> |
| 7946 |
#include <sys/types.h> |
| 7947 |
#include <sys/socket.h> |
| 7948 |
#include <netinet/in.h> |
| 7949 |
#include <arpa/inet.h> |
| 7950 |
#include <netdb.h> |
| 7951 |
#ifdef HAVE_STDLIB_H |
| 7952 |
# include <stdlib.h> |
| 7953 |
#endif |
| 7954 |
|
| 7955 |
int main(void) |
| 7956 |
{ |
| 7957 |
exit(0); |
| 7958 |
} |
| 7959 |
EOF |
| 7960 |
|
| 7961 |
cat << 'EOF' > "$wi_tmpdir/sed.sh" |
| 7962 |
#!/bin/sh |
| 7963 |
|
| 7964 |
if [ $# -eq 0 ] ; then exit 1 ; fi |
| 7965 |
x="$1" |
| 7966 |
|
| 7967 |
sed -n 's/extern//;s/static//; |
| 7968 |
/[\ \*]'"$x"'\ *(/{ |
| 7969 |
s/^.*'"$x"'\ *(/(/ |
| 7970 |
s/)\ *[;,].*$/)/ |
| 7971 |
/ssize_t/{ |
| 7972 |
c\ |
| 7973 |
ssize_t |
| 7974 |
} |
| 7975 |
/size_t/{ |
| 7976 |
c\ |
| 7977 |
size_t |
| 7978 |
} |
| 7979 |
/socklen_t/{ |
| 7980 |
c\ |
| 7981 |
socklen_t |
| 7982 |
} |
| 7983 |
/unsigned int/{ |
| 7984 |
c\ |
| 7985 |
unsigned int |
| 7986 |
} |
| 7987 |
/unsigned long/{ |
| 7988 |
c\ |
| 7989 |
unsigned long |
| 7990 |
} |
| 7991 |
/long/{ |
| 7992 |
c\ |
| 7993 |
long |
| 7994 |
} |
| 7995 |
q |
| 7996 |
}' | sed 's/int int/int/g' |
| 7997 |
EOF |
| 7998 |
chmod 755 "$wi_tmpdir/sed.sh" |
| 7999 |
|
| 8000 |
|
| 8001 |
cat << 'EOF' > "$wi_tmpdir/sed2.sh" |
| 8002 |
#!/bin/sh |
| 8003 |
|
| 8004 |
if [ $# -eq 0 ] ; then exit 1 ; fi |
| 8005 |
x="$1" |
| 8006 |
|
| 8007 |
sed -n 's/extern//;s/static//; |
| 8008 |
/[\ \*]'"$x"'\ *(/{ |
| 8009 |
s/^.*'"$x"'\ *(/(/ |
| 8010 |
s/)\ *[;,].*$/)/ |
| 8011 |
/const char/{ |
| 8012 |
c\ |
| 8013 |
const char * |
| 8014 |
} |
| 8015 |
/char/{ |
| 8016 |
c\ |
| 8017 |
char * |
| 8018 |
} |
| 8019 |
/const/{ |
| 8020 |
c\ |
| 8021 |
const void |
| 8022 |
} |
| 8023 |
q |
| 8024 |
}' |
| 8025 |
EOF |
| 8026 |
chmod 755 "$wi_tmpdir/sed2.sh" |
| 8027 |
|
| 8028 |
$CPP "-I${srcdir-.}" "$wi_tmpdir/unistd.c" > "$wi_tmpdir/unistd.i" |
| 8029 |
if [ -s "$wi_tmpdir/unistd.i" ] ; then |
| 8030 |
"$PERL" "$wi_tmpdir/prpp.pl" < "$wi_tmpdir/unistd.i" > "$wi_tmpdir/protos.h" |
| 8031 |
fi |
| 8032 |
if [ -f "$wi_tmpdir/protos.h" ] ; then |
| 8033 |
# |
| 8034 |
# Check the return type of write() |
| 8035 |
# |
| 8036 |
x="write" |
| 8037 |
wi_cv_write_return_t=`sed -n 's/extern//;s/static//; |
| 8038 |
s/__attribute__((__cdecl__))//; |
| 8039 |
/[\ \*]'"$x"'\ *(/{ |
| 8040 |
s/'"$x"'\ *(.*// |
| 8041 |
s/^\ *// |
| 8042 |
s/\ *$// |
| 8043 |
p;q |
| 8044 |
}' "$wi_tmpdir/protos.h"` |
| 8045 |
# |
| 8046 |
# Check what type write() expects for the size parameter |
| 8047 |
# |
| 8048 |
x="write" |
| 8049 |
wi_cv_write_size_t=`/bin/sh "$wi_tmpdir/sed.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 8050 |
# |
| 8051 |
# Check the return type of send() |
| 8052 |
# |
| 8053 |
x="send" |
| 8054 |
wi_cv_send_return_t=`sed -n 's/extern//;s/static//; |
| 8055 |
s/__attribute__((__cdecl__))//; |
| 8056 |
/[\ \*]'"$x"'\ *(/{ |
| 8057 |
s/'"$x"'\ *(.*// |
| 8058 |
s/^\ *// |
| 8059 |
s/\ *$// |
| 8060 |
p;q |
| 8061 |
}' "$wi_tmpdir/protos.h"` |
| 8062 |
# |
| 8063 |
# Check what type send() expects for the size parameter |
| 8064 |
# Tru64 is one example where send() differs from write() :-( |
| 8065 |
# |
| 8066 |
x="send" |
| 8067 |
wi_cv_send_size_t=`/bin/sh "$wi_tmpdir/sed.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 8068 |
# |
| 8069 |
# Check what type connect() expects for the size parameter |
| 8070 |
# |
| 8071 |
x="connect" |
| 8072 |
wi_cv_sockaddr_size_t=`/bin/sh "$wi_tmpdir/sed.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 8073 |
# |
| 8074 |
# Check what type setsockopt() expects for the size parameter |
| 8075 |
# |
| 8076 |
x="setsockopt" |
| 8077 |
wi_cv_sockopt_size_t=`/bin/sh "$wi_tmpdir/sed.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 8078 |
# |
| 8079 |
# Check what type listen() expects for the backlog parameter |
| 8080 |
# |
| 8081 |
x="listen" |
| 8082 |
wi_cv_listen_backlog_t=`/bin/sh "$wi_tmpdir/sed.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 8083 |
# |
| 8084 |
# Check what type alarm() expects for the seconds parameter |
| 8085 |
# |
| 8086 |
x="alarm" |
| 8087 |
wi_cv_alarm_time_t=`/bin/sh "$wi_tmpdir/sed.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 8088 |
# |
| 8089 |
# Check what type gethostbyaddr() expects for the addr parameter |
| 8090 |
# |
| 8091 |
x="gethostbyaddr" |
| 8092 |
wi_cv_gethost_addrptr_t=`/bin/sh "$wi_tmpdir/sed2.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 8093 |
# |
| 8094 |
# Check what type gethostname() expects for the size parameter |
| 8095 |
# |
| 8096 |
x="gethostname" |
| 8097 |
wi_cv_gethostname_size_t=`/bin/sh "$wi_tmpdir/sed.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 8098 |
fi |
| 8099 |
if [ "x$wi_cv_write_return_t" = "x" ] ; then |
| 8100 |
wi_cv_write_return_t="int" |
| 8101 |
fi |
| 8102 |
if [ "x$wi_cv_write_size_t" = "x" ] ; then |
| 8103 |
wi_cv_write_size_t="int" |
| 8104 |
fi |
| 8105 |
if [ "x$wi_cv_send_return_t" = "x" ] ; then |
| 8106 |
wi_cv_send_return_t="int" |
| 8107 |
fi |
| 8108 |
if [ "x$wi_cv_send_size_t" = "x" ] ; then |
| 8109 |
wi_cv_send_size_t="int" |
| 8110 |
fi |
| 8111 |
if [ "x$wi_cv_sockaddr_size_t" = "x" ] ; then |
| 8112 |
wi_cv_sockaddr_size_t="int" |
| 8113 |
fi |
| 8114 |
if [ "x$wi_cv_sockopt_size_t" = "x" ] ; then |
| 8115 |
wi_cv_sockopt_size_t="int" |
| 8116 |
fi |
| 8117 |
if [ "x$wi_cv_listen_backlog_t" = "x" ] ; then |
| 8118 |
wi_cv_listen_backlog_t="int" |
| 8119 |
fi |
| 8120 |
if [ "x$wi_cv_alarm_time_t" = "x" ] ; then |
| 8121 |
wi_cv_alarm_time_t="int" |
| 8122 |
fi |
| 8123 |
if [ "x$wi_cv_gethost_addrptr_t" = "x" ] ; then |
| 8124 |
wi_cv_gethost_addrptr_t="struct in_addr *" |
| 8125 |
fi |
| 8126 |
if [ "$wi_cv_gethost_addrptr_t" = "const void" ] ; then |
| 8127 |
wi_cv_gethost_addrptr_t="const struct in_addr *" |
| 8128 |
fi |
| 8129 |
if [ "x$wi_cv_gethostname_size_t" = "x" ] ; then |
| 8130 |
wi_cv_gethostname_size_t="int" |
| 8131 |
fi |
| 8132 |
|
| 8133 |
# Done using the temporary directory here. |
| 8134 |
|
| 8135 |
rm -r "$wi_tmpdir" |
| 8136 |
unset wi_tmpdir |
| 8137 |
|
| 8138 |
|
| 8139 |
fi |
| 8140 |
|
| 8141 |
echo "$ac_t""$wi_cv_write_return_t" 1>&6 |
| 8142 |
if test "x$used_cache_for_wi_unistd_fpt" = "xno" ; then |
| 8143 |
echo $ac_n "checking for size parameter to write""... $ac_c" 1>&6 |
| 8144 |
echo "configure:8145: checking for size parameter to write" >&5 |
| 8145 |
echo "$ac_t""$wi_cv_write_size_t" 1>&6 |
| 8146 |
echo $ac_n "checking for return type from send""... $ac_c" 1>&6 |
| 8147 |
echo "configure:8148: checking for return type from send" >&5 |
| 8148 |
echo "$ac_t""$wi_cv_send_return_t" 1>&6 |
| 8149 |
echo $ac_n "checking for size parameter to send""... $ac_c" 1>&6 |
| 8150 |
echo "configure:8151: checking for size parameter to send" >&5 |
| 8151 |
echo "$ac_t""$wi_cv_send_size_t" 1>&6 |
| 8152 |
echo $ac_n "checking for size parameter to connect""... $ac_c" 1>&6 |
| 8153 |
echo "configure:8154: checking for size parameter to connect" >&5 |
| 8154 |
echo "$ac_t""$wi_cv_sockaddr_size_t" 1>&6 |
| 8155 |
echo $ac_n "checking for size parameter to setsockopt""... $ac_c" 1>&6 |
| 8156 |
echo "configure:8157: checking for size parameter to setsockopt" >&5 |
| 8157 |
echo "$ac_t""$wi_cv_sockopt_size_t" 1>&6 |
| 8158 |
echo $ac_n "checking for backlog parameter to listen""... $ac_c" 1>&6 |
| 8159 |
echo "configure:8160: checking for backlog parameter to listen" >&5 |
| 8160 |
echo "$ac_t""$wi_cv_listen_backlog_t" 1>&6 |
| 8161 |
echo $ac_n "checking for seconds parameter to alarm""... $ac_c" 1>&6 |
| 8162 |
echo "configure:8163: checking for seconds parameter to alarm" >&5 |
| 8163 |
echo "$ac_t""$wi_cv_alarm_time_t" 1>&6 |
| 8164 |
echo $ac_n "checking for address parameter to gethostbyaddr""... $ac_c" 1>&6 |
| 8165 |
echo "configure:8166: checking for address parameter to gethostbyaddr" >&5 |
| 8166 |
echo "$ac_t""$wi_cv_gethost_addrptr_t" 1>&6 |
| 8167 |
echo $ac_n "checking for size parameter to gethostname""... $ac_c" 1>&6 |
| 8168 |
echo "configure:8169: checking for size parameter to gethostname" >&5 |
| 8169 |
echo "$ac_t""$wi_cv_gethostname_size_t" 1>&6 |
| 8170 |
else |
| 8171 |
echo $ac_n "checking for size parameter to write""... $ac_c" 1>&6 |
| 8172 |
echo "configure:8173: checking for size parameter to write" >&5 |
| 8173 |
if eval "test \"`echo '$''{'wi_cv_write_size_t'+set}'`\" = set"; then |
| 8174 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8175 |
else |
| 8176 |
: |
| 8177 |
fi |
| 8178 |
|
| 8179 |
echo "$ac_t""$wi_cv_write_size_t" 1>&6 |
| 8180 |
echo $ac_n "checking for return type from send""... $ac_c" 1>&6 |
| 8181 |
echo "configure:8182: checking for return type from send" >&5 |
| 8182 |
if eval "test \"`echo '$''{'wi_cv_send_return_t'+set}'`\" = set"; then |
| 8183 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8184 |
else |
| 8185 |
: |
| 8186 |
fi |
| 8187 |
|
| 8188 |
echo "$ac_t""$wi_cv_send_return_t" 1>&6 |
| 8189 |
echo $ac_n "checking for size parameter to send""... $ac_c" 1>&6 |
| 8190 |
echo "configure:8191: checking for size parameter to send" >&5 |
| 8191 |
if eval "test \"`echo '$''{'wi_cv_send_size_t'+set}'`\" = set"; then |
| 8192 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8193 |
else |
| 8194 |
: |
| 8195 |
fi |
| 8196 |
|
| 8197 |
echo "$ac_t""$wi_cv_send_size_t" 1>&6 |
| 8198 |
echo $ac_n "checking for size parameter to connect""... $ac_c" 1>&6 |
| 8199 |
echo "configure:8200: checking for size parameter to connect" >&5 |
| 8200 |
if eval "test \"`echo '$''{'wi_cv_sockaddr_size_t'+set}'`\" = set"; then |
| 8201 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8202 |
else |
| 8203 |
: |
| 8204 |
fi |
| 8205 |
|
| 8206 |
echo "$ac_t""$wi_cv_sockaddr_size_t" 1>&6 |
| 8207 |
echo $ac_n "checking for size parameter to setsockopt""... $ac_c" 1>&6 |
| 8208 |
echo "configure:8209: checking for size parameter to setsockopt" >&5 |
| 8209 |
if eval "test \"`echo '$''{'wi_cv_sockopt_size_t'+set}'`\" = set"; then |
| 8210 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8211 |
else |
| 8212 |
: |
| 8213 |
fi |
| 8214 |
|
| 8215 |
echo "$ac_t""$wi_cv_sockopt_size_t" 1>&6 |
| 8216 |
echo $ac_n "checking for backlog parameter to listen""... $ac_c" 1>&6 |
| 8217 |
echo "configure:8218: checking for backlog parameter to listen" >&5 |
| 8218 |
if eval "test \"`echo '$''{'wi_cv_listen_backlog_t'+set}'`\" = set"; then |
| 8219 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8220 |
else |
| 8221 |
: |
| 8222 |
fi |
| 8223 |
|
| 8224 |
echo "$ac_t""$wi_cv_listen_backlog_t" 1>&6 |
| 8225 |
echo $ac_n "checking for seconds parameter to alarm""... $ac_c" 1>&6 |
| 8226 |
echo "configure:8227: checking for seconds parameter to alarm" >&5 |
| 8227 |
if eval "test \"`echo '$''{'wi_cv_alarm_time_t'+set}'`\" = set"; then |
| 8228 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8229 |
else |
| 8230 |
: |
| 8231 |
fi |
| 8232 |
|
| 8233 |
echo "$ac_t""$wi_cv_alarm_time_t" 1>&6 |
| 8234 |
echo $ac_n "checking for address parameter to gethostbyaddr""... $ac_c" 1>&6 |
| 8235 |
echo "configure:8236: checking for address parameter to gethostbyaddr" >&5 |
| 8236 |
if eval "test \"`echo '$''{'wi_cv_gethost_addrptr_t'+set}'`\" = set"; then |
| 8237 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8238 |
else |
| 8239 |
: |
| 8240 |
fi |
| 8241 |
|
| 8242 |
echo "$ac_t""$wi_cv_gethost_addrptr_t" 1>&6 |
| 8243 |
echo $ac_n "checking for size parameter to gethostname""... $ac_c" 1>&6 |
| 8244 |
echo "configure:8245: checking for size parameter to gethostname" >&5 |
| 8245 |
if eval "test \"`echo '$''{'wi_cv_gethostname_size_t'+set}'`\" = set"; then |
| 8246 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8247 |
else |
| 8248 |
: |
| 8249 |
fi |
| 8250 |
|
| 8251 |
echo "$ac_t""$wi_cv_gethostname_size_t" 1>&6 |
| 8252 |
fi |
| 8253 |
unset used_cache_for_wi_unistd_fpt |
| 8254 |
cat >> confdefs.h <<EOF |
| 8255 |
#define write_return_t $wi_cv_write_return_t |
| 8256 |
EOF |
| 8257 |
|
| 8258 |
cat >> confdefs.h <<EOF |
| 8259 |
#define write_size_t $wi_cv_write_size_t |
| 8260 |
EOF |
| 8261 |
|
| 8262 |
cat >> confdefs.h <<EOF |
| 8263 |
#define read_return_t $wi_cv_write_return_t |
| 8264 |
EOF |
| 8265 |
|
| 8266 |
cat >> confdefs.h <<EOF |
| 8267 |
#define read_size_t $wi_cv_write_size_t |
| 8268 |
EOF |
| 8269 |
|
| 8270 |
cat >> confdefs.h <<EOF |
| 8271 |
#define send_return_t $wi_cv_send_return_t |
| 8272 |
EOF |
| 8273 |
|
| 8274 |
cat >> confdefs.h <<EOF |
| 8275 |
#define send_size_t $wi_cv_send_size_t |
| 8276 |
EOF |
| 8277 |
|
| 8278 |
cat >> confdefs.h <<EOF |
| 8279 |
#define recv_return_t $wi_cv_send_return_t |
| 8280 |
EOF |
| 8281 |
|
| 8282 |
cat >> confdefs.h <<EOF |
| 8283 |
#define recv_size_t $wi_cv_send_size_t |
| 8284 |
EOF |
| 8285 |
|
| 8286 |
cat >> confdefs.h <<EOF |
| 8287 |
#define sockaddr_size_t $wi_cv_sockaddr_size_t |
| 8288 |
EOF |
| 8289 |
|
| 8290 |
cat >> confdefs.h <<EOF |
| 8291 |
#define sockopt_size_t $wi_cv_sockopt_size_t |
| 8292 |
EOF |
| 8293 |
|
| 8294 |
cat >> confdefs.h <<EOF |
| 8295 |
#define listen_backlog_t $wi_cv_listen_backlog_t |
| 8296 |
EOF |
| 8297 |
|
| 8298 |
cat >> confdefs.h <<EOF |
| 8299 |
#define alarm_time_t $wi_cv_alarm_time_t |
| 8300 |
EOF |
| 8301 |
|
| 8302 |
cat >> confdefs.h <<EOF |
| 8303 |
#define gethost_addrptr_t $wi_cv_gethost_addrptr_t |
| 8304 |
EOF |
| 8305 |
|
| 8306 |
cat >> confdefs.h <<EOF |
| 8307 |
#define gethostname_size_t $wi_cv_gethostname_size_t |
| 8308 |
EOF |
| 8309 |
|
| 8310 |
|
| 8311 |
echo $ac_n "checking for negative_control_t""... $ac_c" 1>&6 |
| 8312 |
echo "configure:8313: checking for negative_control_t" >&5 |
| 8313 |
if eval "test \"`echo '$''{'ac_cv_type_negative_control_t'+set}'`\" = set"; then |
| 8314 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8315 |
else |
| 8316 |
cat > conftest.$ac_ext <<EOF |
| 8317 |
#line 8318 "configure" |
| 8318 |
#include "confdefs.h" |
| 8319 |
|
| 8320 |
#ifdef HAVE_UNISTD_H |
| 8321 |
#include <unistd.h> |
| 8322 |
#endif |
| 8323 |
#include <sys/types.h> |
| 8324 |
#if STDC_HEADERS |
| 8325 |
#include <stdlib.h> |
| 8326 |
#include <stddef.h> |
| 8327 |
#endif |
| 8328 |
|
| 8329 |
EOF |
| 8330 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 8331 |
egrep "(^|[^a-zA-Z_0-9])negative_control_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 8332 |
rm -rf conftest* |
| 8333 |
ac_cv_type_negative_control_t=yes |
| 8334 |
else |
| 8335 |
rm -rf conftest* |
| 8336 |
ac_cv_type_negative_control_t=no |
| 8337 |
fi |
| 8338 |
rm -rf conftest* |
| 8339 |
|
| 8340 |
fi |
| 8341 |
echo "$ac_t""$ac_cv_type_negative_control_t" 1>&6 |
| 8342 |
if test $ac_cv_type_negative_control_t = no; then |
| 8343 |
cat >> confdefs.h <<\EOF |
| 8344 |
#define negative_control_t long |
| 8345 |
EOF |
| 8346 |
|
| 8347 |
fi |
| 8348 |
|
| 8349 |
echo $ac_n "checking for ssize_t""... $ac_c" 1>&6 |
| 8350 |
echo "configure:8351: checking for ssize_t" >&5 |
| 8351 |
if eval "test \"`echo '$''{'ac_cv_type_ssize_t'+set}'`\" = set"; then |
| 8352 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8353 |
else |
| 8354 |
cat > conftest.$ac_ext <<EOF |
| 8355 |
#line 8356 "configure" |
| 8356 |
#include "confdefs.h" |
| 8357 |
|
| 8358 |
#ifdef HAVE_UNISTD_H |
| 8359 |
#include <unistd.h> |
| 8360 |
#endif |
| 8361 |
#include <sys/types.h> |
| 8362 |
#if STDC_HEADERS |
| 8363 |
#include <stdlib.h> |
| 8364 |
#include <stddef.h> |
| 8365 |
#endif |
| 8366 |
|
| 8367 |
EOF |
| 8368 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 8369 |
egrep "(^|[^a-zA-Z_0-9])ssize_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 8370 |
rm -rf conftest* |
| 8371 |
ac_cv_type_ssize_t=yes |
| 8372 |
else |
| 8373 |
rm -rf conftest* |
| 8374 |
ac_cv_type_ssize_t=no |
| 8375 |
fi |
| 8376 |
rm -rf conftest* |
| 8377 |
|
| 8378 |
fi |
| 8379 |
echo "$ac_t""$ac_cv_type_ssize_t" 1>&6 |
| 8380 |
if test $ac_cv_type_ssize_t = no; then |
| 8381 |
cat >> confdefs.h <<\EOF |
| 8382 |
#define ssize_t long |
| 8383 |
EOF |
| 8384 |
|
| 8385 |
fi |
| 8386 |
|
| 8387 |
echo $ac_n "checking for sa_family_t""... $ac_c" 1>&6 |
| 8388 |
echo "configure:8389: checking for sa_family_t" >&5 |
| 8389 |
if eval "test \"`echo '$''{'ac_cv_type_sa_family_t'+set}'`\" = set"; then |
| 8390 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8391 |
else |
| 8392 |
cat > conftest.$ac_ext <<EOF |
| 8393 |
#line 8394 "configure" |
| 8394 |
#include "confdefs.h" |
| 8395 |
|
| 8396 |
#ifdef HAVE_UNISTD_H |
| 8397 |
#include <unistd.h> |
| 8398 |
#endif |
| 8399 |
#include <sys/types.h> |
| 8400 |
#if STDC_HEADERS |
| 8401 |
#include <stdlib.h> |
| 8402 |
#include <stddef.h> |
| 8403 |
#endif |
| 8404 |
#include <sys/socket.h> |
| 8405 |
#include <netinet/in.h> |
| 8406 |
#include <arpa/inet.h> |
| 8407 |
#include <netdb.h> |
| 8408 |
|
| 8409 |
EOF |
| 8410 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 8411 |
egrep "(^|[^a-zA-Z_0-9])sa_family_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 8412 |
rm -rf conftest* |
| 8413 |
ac_cv_type_sa_family_t=yes |
| 8414 |
else |
| 8415 |
rm -rf conftest* |
| 8416 |
ac_cv_type_sa_family_t=no |
| 8417 |
fi |
| 8418 |
rm -rf conftest* |
| 8419 |
|
| 8420 |
fi |
| 8421 |
echo "$ac_t""$ac_cv_type_sa_family_t" 1>&6 |
| 8422 |
if test $ac_cv_type_sa_family_t = no; then |
| 8423 |
cat >> confdefs.h <<\EOF |
| 8424 |
#define sa_family_t unsigned short |
| 8425 |
EOF |
| 8426 |
|
| 8427 |
fi |
| 8428 |
|
| 8429 |
|
| 8430 |
|
| 8431 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 8432 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_FUNC_SELECT_ARGTYPES." 1>&2; exit 1; } |
| 8433 |
fi |
| 8434 |
|
| 8435 |
echo $ac_n "checking types of arguments for select()""... $ac_c" 1>&6 |
| 8436 |
echo "configure:8437: checking types of arguments for select()" >&5 |
| 8437 |
if eval "test \"`echo '$''{'ac_cv_func_select_arg234'+set}'`\" = set"; then |
| 8438 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8439 |
else |
| 8440 |
if eval "test \"`echo '$''{'ac_cv_func_select_arg1'+set}'`\" = set"; then |
| 8441 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8442 |
else |
| 8443 |
if eval "test \"`echo '$''{'ac_cv_func_select_arg5'+set}'`\" = set"; then |
| 8444 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8445 |
else |
| 8446 |
for ac_cv_func_select_arg234 in 'fd_set *' 'int *' 'void *'; do |
| 8447 |
for ac_cv_func_select_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do |
| 8448 |
for ac_cv_func_select_arg5 in 'struct timeval *' 'const struct timeval *'; do |
| 8449 |
cat > conftest.$ac_ext <<EOF |
| 8450 |
#line 8451 "configure" |
| 8451 |
#include "confdefs.h" |
| 8452 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) /* MG */ |
| 8453 |
# define _ALL_SOURCE 1 /* MG */ |
| 8454 |
#endif |
| 8455 |
#ifdef HAVE_UNISTD_H /* MG */ |
| 8456 |
#include <unistd.h> |
| 8457 |
#endif /* MG */ |
| 8458 |
#include <sys/types.h> /* MG: always incl */ |
| 8459 |
#include <sys/time.h> /* MG: always incl */ |
| 8460 |
#ifdef HAVE_SYS_SELECT_H |
| 8461 |
#include <sys/select.h> |
| 8462 |
#endif |
| 8463 |
#include <sys/socket.h> /* MG: always incl */ |
| 8464 |
extern select ($ac_cv_func_select_arg1,$ac_cv_func_select_arg234,$ac_cv_func_select_arg234,$ac_cv_func_select_arg234,$ac_cv_func_select_arg5); |
| 8465 |
int main(void) { |
| 8466 |
|
| 8467 |
; return 0; } |
| 8468 |
EOF |
| 8469 |
if { (eval echo configure:8470: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 8470 |
rm -rf conftest* |
| 8471 |
ac_not_found=no ; break 3 |
| 8472 |
else |
| 8473 |
echo "configure: failed program was:" >&5 |
| 8474 |
cat conftest.$ac_ext >&5 |
| 8475 |
rm -rf conftest* |
| 8476 |
ac_not_found=yes |
| 8477 |
fi |
| 8478 |
rm -rf conftest* |
| 8479 |
done |
| 8480 |
done |
| 8481 |
done |
| 8482 |
|
| 8483 |
fi |
| 8484 |
|
| 8485 |
fi |
| 8486 |
|
| 8487 |
fi |
| 8488 |
if test "$ac_not_found" = yes; then |
| 8489 |
ac_cv_func_select_arg1=int |
| 8490 |
ac_cv_func_select_arg234='int *' |
| 8491 |
ac_cv_func_select_arg5='struct timeval *' |
| 8492 |
fi |
| 8493 |
echo "$ac_t""$ac_cv_func_select_arg1,$ac_cv_func_select_arg234,$ac_cv_func_select_arg5" 1>&6 |
| 8494 |
cat >> confdefs.h <<EOF |
| 8495 |
#define SELECT_TYPE_ARG1 $ac_cv_func_select_arg1 |
| 8496 |
EOF |
| 8497 |
|
| 8498 |
cat >> confdefs.h <<EOF |
| 8499 |
#define SELECT_TYPE_ARG234 ($ac_cv_func_select_arg234) |
| 8500 |
EOF |
| 8501 |
|
| 8502 |
cat >> confdefs.h <<EOF |
| 8503 |
#define SELECT_TYPE_ARG5 ($ac_cv_func_select_arg5) |
| 8504 |
EOF |
| 8505 |
|
| 8506 |
|
| 8507 |
|
| 8508 |
if test "$wi_cv_lfs64" != "yes" ; then |
| 8509 |
echo $ac_n "checking for struct stat64""... $ac_c" 1>&6 |
| 8510 |
echo "configure:8511: checking for struct stat64" >&5 |
| 8511 |
echo "$ac_t""not needed" 1>&6 |
| 8512 |
wi_cv_struct_stat64=no |
| 8513 |
else |
| 8514 |
echo $ac_n "checking for struct stat64""... $ac_c" 1>&6 |
| 8515 |
echo "configure:8516: checking for struct stat64" >&5 |
| 8516 |
cat > conftest.$ac_ext <<EOF |
| 8517 |
#line 8518 "configure" |
| 8518 |
#include "confdefs.h" |
| 8519 |
|
| 8520 |
/* includes */ |
| 8521 |
#include <unistd.h> |
| 8522 |
#ifdef HAVE_STDLIB_H |
| 8523 |
# include <stdlib.h> |
| 8524 |
#endif |
| 8525 |
#include <sys/types.h> |
| 8526 |
#include <sys/stat.h> |
| 8527 |
|
| 8528 |
int main(void) { |
| 8529 |
|
| 8530 |
struct stat64 st; |
| 8531 |
|
| 8532 |
st.st_size = 0; |
| 8533 |
exit(((int) &st.st_size) & 0xff); /* bogus code, of course. */ |
| 8534 |
|
| 8535 |
; return 0; } |
| 8536 |
EOF |
| 8537 |
if { (eval echo configure:8538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 8538 |
rm -rf conftest* |
| 8539 |
|
| 8540 |
wi_cv_struct_stat64=yes |
| 8541 |
cat >> confdefs.h <<\EOF |
| 8542 |
#define HAVE_STRUCT_STAT64 1 |
| 8543 |
EOF |
| 8544 |
|
| 8545 |
|
| 8546 |
else |
| 8547 |
echo "configure: failed program was:" >&5 |
| 8548 |
cat conftest.$ac_ext >&5 |
| 8549 |
rm -rf conftest* |
| 8550 |
|
| 8551 |
wi_cv_struct_stat64=no |
| 8552 |
|
| 8553 |
fi |
| 8554 |
rm -rf conftest* |
| 8555 |
echo "$ac_t""$wi_cv_struct_stat64" 1>&6 |
| 8556 |
fi |
| 8557 |
|
| 8558 |
|
| 8559 |
|
| 8560 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 8561 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_TYPE_SIG_ATOMIC_T." 1>&2; exit 1; } |
| 8562 |
fi |
| 8563 |
|
| 8564 |
echo $ac_n "checking for sig_atomic_t""... $ac_c" 1>&6 |
| 8565 |
echo "configure:8566: checking for sig_atomic_t" >&5 |
| 8566 |
cat > conftest.$ac_ext <<EOF |
| 8567 |
#line 8568 "configure" |
| 8568 |
#include "confdefs.h" |
| 8569 |
|
| 8570 |
/* includes */ |
| 8571 |
#include <unistd.h> |
| 8572 |
#ifdef HAVE_STDLIB_H |
| 8573 |
# include <stdlib.h> |
| 8574 |
#endif |
| 8575 |
#include <sys/types.h> |
| 8576 |
#include <sys/signal.h> |
| 8577 |
#include <signal.h> /* MG: for IRIX */ |
| 8578 |
#if STDC_HEADERS |
| 8579 |
#include <stddef.h> |
| 8580 |
#endif |
| 8581 |
|
| 8582 |
int main(void) { |
| 8583 |
|
| 8584 |
/* function-body */ |
| 8585 |
sig_atomic_t sample; |
| 8586 |
|
| 8587 |
sample = (sig_atomic_t) getpid(); /* bogus code, of course */ |
| 8588 |
exit((sample > 0) ? 0 : 1); |
| 8589 |
|
| 8590 |
; return 0; } |
| 8591 |
EOF |
| 8592 |
if { (eval echo configure:8593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 8593 |
rm -rf conftest* |
| 8594 |
|
| 8595 |
ac_cv_type_sig_atomic_t=yes |
| 8596 |
|
| 8597 |
else |
| 8598 |
echo "configure: failed program was:" >&5 |
| 8599 |
cat conftest.$ac_ext >&5 |
| 8600 |
rm -rf conftest* |
| 8601 |
|
| 8602 |
ac_cv_type_sig_atomic_t=no |
| 8603 |
|
| 8604 |
fi |
| 8605 |
rm -rf conftest* |
| 8606 |
echo "$ac_t""$ac_cv_type_sig_atomic_t" 1>&6 |
| 8607 |
if test $ac_cv_type_sig_atomic_t = no ; then |
| 8608 |
cat >> confdefs.h <<\EOF |
| 8609 |
#define sig_atomic_t int |
| 8610 |
EOF |
| 8611 |
|
| 8612 |
fi |
| 8613 |
|
| 8614 |
|
| 8615 |
echo $ac_n "checking how to access getopt() global variables""... $ac_c" 1>&6 |
| 8616 |
echo "configure:8617: checking how to access getopt() global variables" >&5 |
| 8617 |
if eval "test \"`echo '$''{'wi_cv_getopt_decl'+set}'`\" = set"; then |
| 8618 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8619 |
else |
| 8620 |
|
| 8621 |
|
| 8622 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 8623 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_GETOPT." 1>&2; exit 1; } |
| 8624 |
fi |
| 8625 |
|
| 8626 |
cat > conftest.$ac_ext <<EOF |
| 8627 |
#line 8628 "configure" |
| 8628 |
#include "confdefs.h" |
| 8629 |
|
| 8630 |
/* includes */ |
| 8631 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 8632 |
# define _ALL_SOURCE 1 |
| 8633 |
#endif |
| 8634 |
#ifdef HAVE_UNISTD_H |
| 8635 |
# include <unistd.h> |
| 8636 |
#endif |
| 8637 |
#include <stdio.h> |
| 8638 |
#include <stdlib.h> |
| 8639 |
|
| 8640 |
int main(void) { |
| 8641 |
|
| 8642 |
optind = (optarg == 0) ? 66 : 99; |
| 8643 |
|
| 8644 |
; return 0; } |
| 8645 |
EOF |
| 8646 |
if { (eval echo configure:8647: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 8647 |
rm -rf conftest* |
| 8648 |
wi_cv_getopt_decl="automatic" |
| 8649 |
else |
| 8650 |
echo "configure: failed program was:" >&5 |
| 8651 |
cat conftest.$ac_ext >&5 |
| 8652 |
rm -rf conftest* |
| 8653 |
wi_cv_getopt_decl="unknown" |
| 8654 |
fi |
| 8655 |
rm -rf conftest* |
| 8656 |
|
| 8657 |
|
| 8658 |
|
| 8659 |
if test "$wi_cv_getopt_decl" = unknown ; then |
| 8660 |
cat > conftest.$ac_ext <<EOF |
| 8661 |
#line 8662 "configure" |
| 8662 |
#include "confdefs.h" |
| 8663 |
|
| 8664 |
/* includes */ |
| 8665 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 8666 |
# define _ALL_SOURCE 1 |
| 8667 |
#endif |
| 8668 |
#ifdef HAVE_UNISTD_H |
| 8669 |
# include <unistd.h> |
| 8670 |
#endif |
| 8671 |
#include <stdio.h> |
| 8672 |
#include <stdlib.h> |
| 8673 |
#include <getopt.h> |
| 8674 |
|
| 8675 |
int main(void) { |
| 8676 |
|
| 8677 |
optind = (optarg == 0) ? 66 : 99; |
| 8678 |
|
| 8679 |
; return 0; } |
| 8680 |
EOF |
| 8681 |
if { (eval echo configure:8682: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 8682 |
rm -rf conftest* |
| 8683 |
|
| 8684 |
# |
| 8685 |
# Looks like <getopt.h> declares the variables as extern. |
| 8686 |
# |
| 8687 |
wi_cv_getopt_decl="getopt.h" |
| 8688 |
else |
| 8689 |
echo "configure: failed program was:" >&5 |
| 8690 |
cat conftest.$ac_ext >&5 |
| 8691 |
rm -rf conftest* |
| 8692 |
|
| 8693 |
# |
| 8694 |
# You'll need to declare them yourself. |
| 8695 |
# |
| 8696 |
wi_cv_getopt_decl="manual" |
| 8697 |
|
| 8698 |
fi |
| 8699 |
rm -rf conftest* |
| 8700 |
fi |
| 8701 |
|
| 8702 |
fi |
| 8703 |
|
| 8704 |
echo "$ac_t""$wi_cv_getopt_decl" 1>&6 |
| 8705 |
if test "$wi_cv_getopt_decl" = "getopt.h" ; then |
| 8706 |
cat >> confdefs.h <<\EOF |
| 8707 |
#define NEED_GETOPT_H 1 |
| 8708 |
EOF |
| 8709 |
|
| 8710 |
elif test "$wi_cv_getopt_decl" = "manual" ; then |
| 8711 |
cat >> confdefs.h <<\EOF |
| 8712 |
#define NEED_GETOPT_EXTERN_DECLS 1 |
| 8713 |
EOF |
| 8714 |
|
| 8715 |
fi |
| 8716 |
|
| 8717 |
|
| 8718 |
echo $ac_n "checking for useable _res global variable""... $ac_c" 1>&6 |
| 8719 |
echo "configure:8720: checking for useable _res global variable" >&5 |
| 8720 |
cat > conftest.$ac_ext <<EOF |
| 8721 |
#line 8722 "configure" |
| 8722 |
#include "confdefs.h" |
| 8723 |
|
| 8724 |
/* includes */ |
| 8725 |
#include <unistd.h> |
| 8726 |
#ifdef HAVE_STDLIB_H |
| 8727 |
# include <stdlib.h> |
| 8728 |
#endif |
| 8729 |
#include <sys/types.h> |
| 8730 |
#include <sys/stat.h> |
| 8731 |
#include <sys/socket.h> |
| 8732 |
#include <arpa/inet.h> |
| 8733 |
#include <netinet/in.h> |
| 8734 |
#ifdef HAVE_ARPA_NAMESER_H |
| 8735 |
# include <arpa/nameser.h> |
| 8736 |
#endif |
| 8737 |
#ifdef HAVE_RESOLV_H |
| 8738 |
# include <resolv.h> |
| 8739 |
#endif |
| 8740 |
|
| 8741 |
int main(void) { |
| 8742 |
|
| 8743 |
/* function-body */ |
| 8744 |
int len; |
| 8745 |
|
| 8746 |
res_init(); |
| 8747 |
len = (int) strlen(_res.defdname); |
| 8748 |
|
| 8749 |
; return 0; } |
| 8750 |
EOF |
| 8751 |
if { (eval echo configure:8752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 8752 |
rm -rf conftest* |
| 8753 |
|
| 8754 |
wi_cv__res_defdname=yes |
| 8755 |
cat >> confdefs.h <<\EOF |
| 8756 |
#define HAVE__RES_DEFDNAME 1 |
| 8757 |
EOF |
| 8758 |
|
| 8759 |
|
| 8760 |
else |
| 8761 |
echo "configure: failed program was:" >&5 |
| 8762 |
cat conftest.$ac_ext >&5 |
| 8763 |
rm -rf conftest* |
| 8764 |
|
| 8765 |
wi_cv__res_defdname=no |
| 8766 |
|
| 8767 |
fi |
| 8768 |
rm -rf conftest* |
| 8769 |
echo "$ac_t""$wi_cv__res_defdname" 1>&6 |
| 8770 |
|
| 8771 |
echo $ac_n "checking for struct cmsghdr""... $ac_c" 1>&6 |
| 8772 |
echo "configure:8773: checking for struct cmsghdr" >&5 |
| 8773 |
if eval "test \"`echo '$''{'wi_cv_struct_cmsghdr'+set}'`\" = set"; then |
| 8774 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8775 |
else |
| 8776 |
|
| 8777 |
cat > conftest.$ac_ext <<EOF |
| 8778 |
#line 8779 "configure" |
| 8779 |
#include "confdefs.h" |
| 8780 |
|
| 8781 |
/* includes */ |
| 8782 |
#include <unistd.h> |
| 8783 |
#ifdef HAVE_STDLIB_H |
| 8784 |
# include <stdlib.h> |
| 8785 |
#endif |
| 8786 |
#include <sys/types.h> |
| 8787 |
#include <sys/uio.h> |
| 8788 |
#include <sys/socket.h> |
| 8789 |
#include <sys/un.h> |
| 8790 |
|
| 8791 |
int main(void) { |
| 8792 |
|
| 8793 |
struct cmsghdr cm; |
| 8794 |
|
| 8795 |
cm.cmsg_len = 0; |
| 8796 |
cm.cmsg_level = 0; |
| 8797 |
cm.cmsg_type = 0; |
| 8798 |
exit(((int) &cm.cmsg_type) & 0xff); /* bogus code, of course. */ |
| 8799 |
|
| 8800 |
; return 0; } |
| 8801 |
EOF |
| 8802 |
if { (eval echo configure:8803: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 8803 |
rm -rf conftest* |
| 8804 |
|
| 8805 |
wi_cv_struct_cmsghdr=yes |
| 8806 |
|
| 8807 |
else |
| 8808 |
echo "configure: failed program was:" >&5 |
| 8809 |
cat conftest.$ac_ext >&5 |
| 8810 |
rm -rf conftest* |
| 8811 |
|
| 8812 |
wi_cv_struct_cmsghdr=no |
| 8813 |
|
| 8814 |
fi |
| 8815 |
rm -rf conftest* |
| 8816 |
|
| 8817 |
fi |
| 8818 |
|
| 8819 |
echo "$ac_t""$wi_cv_struct_cmsghdr" 1>&6 |
| 8820 |
if test "$wi_cv_struct_cmsghdr" = yes ; then |
| 8821 |
cat >> confdefs.h <<\EOF |
| 8822 |
#define HAVE_STRUCT_CMSGDHR 1 |
| 8823 |
EOF |
| 8824 |
|
| 8825 |
fi |
| 8826 |
|
| 8827 |
echo $ac_n "checking for msg_control field in struct msghdr""... $ac_c" 1>&6 |
| 8828 |
echo "configure:8829: checking for msg_control field in struct msghdr" >&5 |
| 8829 |
if eval "test \"`echo '$''{'wi_cv_msghdr_control'+set}'`\" = set"; then |
| 8830 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8831 |
else |
| 8832 |
|
| 8833 |
cat > conftest.$ac_ext <<EOF |
| 8834 |
#line 8835 "configure" |
| 8835 |
#include "confdefs.h" |
| 8836 |
|
| 8837 |
/* includes */ |
| 8838 |
#include <unistd.h> |
| 8839 |
#ifdef HAVE_STDLIB_H |
| 8840 |
# include <stdlib.h> |
| 8841 |
#endif |
| 8842 |
#include <sys/types.h> |
| 8843 |
#include <sys/uio.h> |
| 8844 |
#include <sys/socket.h> |
| 8845 |
#include <sys/un.h> |
| 8846 |
|
| 8847 |
int main(void) { |
| 8848 |
|
| 8849 |
struct msghdr m; |
| 8850 |
|
| 8851 |
m.msg_control = &m; |
| 8852 |
m.msg_controllen = sizeof(m); |
| 8853 |
exit(((int) &m.msg_control) & 0xff); /* bogus code, of course. */ |
| 8854 |
|
| 8855 |
; return 0; } |
| 8856 |
EOF |
| 8857 |
if { (eval echo configure:8858: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 8858 |
rm -rf conftest* |
| 8859 |
|
| 8860 |
wi_cv_msghdr_control=yes |
| 8861 |
|
| 8862 |
else |
| 8863 |
echo "configure: failed program was:" >&5 |
| 8864 |
cat conftest.$ac_ext >&5 |
| 8865 |
rm -rf conftest* |
| 8866 |
|
| 8867 |
wi_cv_msghdr_control=no |
| 8868 |
|
| 8869 |
fi |
| 8870 |
rm -rf conftest* |
| 8871 |
|
| 8872 |
fi |
| 8873 |
|
| 8874 |
echo "$ac_t""$wi_cv_msghdr_control" 1>&6 |
| 8875 |
if test "$wi_cv_msghdr_control" = yes ; then |
| 8876 |
cat >> confdefs.h <<\EOF |
| 8877 |
#define HAVE_MSGHDR_CONTROL 1 |
| 8878 |
EOF |
| 8879 |
|
| 8880 |
fi |
| 8881 |
|
| 8882 |
echo $ac_n "checking for msg_accrights field in struct msghdr""... $ac_c" 1>&6 |
| 8883 |
echo "configure:8884: checking for msg_accrights field in struct msghdr" >&5 |
| 8884 |
if eval "test \"`echo '$''{'wi_cv_msghdr_accrights'+set}'`\" = set"; then |
| 8885 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8886 |
else |
| 8887 |
|
| 8888 |
cat > conftest.$ac_ext <<EOF |
| 8889 |
#line 8890 "configure" |
| 8890 |
#include "confdefs.h" |
| 8891 |
|
| 8892 |
/* includes */ |
| 8893 |
#include <unistd.h> |
| 8894 |
#ifdef HAVE_STDLIB_H |
| 8895 |
# include <stdlib.h> |
| 8896 |
#endif |
| 8897 |
#include <sys/types.h> |
| 8898 |
#include <sys/uio.h> |
| 8899 |
#include <sys/socket.h> |
| 8900 |
#include <sys/un.h> |
| 8901 |
|
| 8902 |
int main(void) { |
| 8903 |
|
| 8904 |
struct msghdr m; |
| 8905 |
|
| 8906 |
m.msg_accrights = &m; |
| 8907 |
m.msg_accrightslen = sizeof(m); |
| 8908 |
exit(((int) &m.msg_accrights) & 0xff); /* bogus code, of course. */ |
| 8909 |
|
| 8910 |
; return 0; } |
| 8911 |
EOF |
| 8912 |
if { (eval echo configure:8913: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 8913 |
rm -rf conftest* |
| 8914 |
|
| 8915 |
wi_cv_msghdr_accrights=yes |
| 8916 |
|
| 8917 |
else |
| 8918 |
echo "configure: failed program was:" >&5 |
| 8919 |
cat conftest.$ac_ext >&5 |
| 8920 |
rm -rf conftest* |
| 8921 |
|
| 8922 |
wi_cv_msghdr_accrights=no |
| 8923 |
|
| 8924 |
fi |
| 8925 |
rm -rf conftest* |
| 8926 |
|
| 8927 |
fi |
| 8928 |
|
| 8929 |
echo "$ac_t""$wi_cv_msghdr_accrights" 1>&6 |
| 8930 |
if test "$wi_cv_msghdr_accrights" = yes ; then |
| 8931 |
cat >> confdefs.h <<\EOF |
| 8932 |
#define HAVE_MSGHDR_ACCRIGHTS 1 |
| 8933 |
EOF |
| 8934 |
|
| 8935 |
fi |
| 8936 |
|
| 8937 |
|
| 8938 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 8939 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_HEADER_SYS_SELECT_H." 1>&2; exit 1; } |
| 8940 |
fi |
| 8941 |
|
| 8942 |
# See if <sys/select.h> is includable after <sys/time.h> |
| 8943 |
if test "$ac_cv_header_sys_time_h" = no ; then |
| 8944 |
wi_chk_headers="sys/time.h sys/select.h" |
| 8945 |
else |
| 8946 |
wi_chk_headers="sys/time.h" |
| 8947 |
fi |
| 8948 |
for ac_hdr in $wi_chk_headers |
| 8949 |
do |
| 8950 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 8951 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 8952 |
echo "configure:8953: checking for $ac_hdr" >&5 |
| 8953 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 8954 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 8955 |
else |
| 8956 |
cat > conftest.$ac_ext <<EOF |
| 8957 |
#line 8958 "configure" |
| 8958 |
#include "confdefs.h" |
| 8959 |
#include <$ac_hdr> |
| 8960 |
EOF |
| 8961 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 8962 |
{ (eval echo configure:8963: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 8963 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 8964 |
if test -z "$ac_err"; then |
| 8965 |
rm -rf conftest* |
| 8966 |
eval "ac_cv_header_$ac_safe=yes" |
| 8967 |
else |
| 8968 |
echo "$ac_err" >&5 |
| 8969 |
echo "configure: failed program was:" >&5 |
| 8970 |
cat conftest.$ac_ext >&5 |
| 8971 |
rm -rf conftest* |
| 8972 |
eval "ac_cv_header_$ac_safe=no" |
| 8973 |
fi |
| 8974 |
rm -rf conftest* |
| 8975 |
fi |
| 8976 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 8977 |
echo "$ac_t""yes" 1>&6 |
| 8978 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 8979 |
cat >> confdefs.h <<EOF |
| 8980 |
#define $ac_tr_hdr 1 |
| 8981 |
EOF |
| 8982 |
|
| 8983 |
else |
| 8984 |
echo "$ac_t""no" 1>&6 |
| 8985 |
fi |
| 8986 |
done |
| 8987 |
|
| 8988 |
if test "$ac_cv_header_sys_select_h" = yes ; then |
| 8989 |
echo $ac_n "checking if <sys/select.h> is compatible with <sys/time.h>""... $ac_c" 1>&6 |
| 8990 |
echo "configure:8991: checking if <sys/select.h> is compatible with <sys/time.h>" >&5 |
| 8991 |
selecth=yes |
| 8992 |
if test "$ac_cv_header_sys_time_h" = yes ; then |
| 8993 |
cat > conftest.$ac_ext <<EOF |
| 8994 |
#line 8995 "configure" |
| 8995 |
#include "confdefs.h" |
| 8996 |
|
| 8997 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 8998 |
# define _ALL_SOURCE 1 |
| 8999 |
#endif |
| 9000 |
#ifdef HAVE_UNISTD_H |
| 9001 |
# include <unistd.h> |
| 9002 |
#endif |
| 9003 |
#include <sys/types.h> |
| 9004 |
#include <sys/time.h> |
| 9005 |
#include <sys/select.h> |
| 9006 |
int main(void) { |
| 9007 |
|
| 9008 |
fd_set a; |
| 9009 |
struct timeval tmval; |
| 9010 |
|
| 9011 |
tmval.tv_sec = 0; |
| 9012 |
; return 0; } |
| 9013 |
EOF |
| 9014 |
if { (eval echo configure:9015: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 9015 |
rm -rf conftest* |
| 9016 |
selecth=yes |
| 9017 |
else |
| 9018 |
echo "configure: failed program was:" >&5 |
| 9019 |
cat conftest.$ac_ext >&5 |
| 9020 |
rm -rf conftest* |
| 9021 |
selecth=no |
| 9022 |
fi |
| 9023 |
rm -rf conftest* |
| 9024 |
fi |
| 9025 |
if test "$selecth" = yes ; then |
| 9026 |
cat >> confdefs.h <<\EOF |
| 9027 |
#define CAN_USE_SYS_SELECT_H 1 |
| 9028 |
EOF |
| 9029 |
|
| 9030 |
fi |
| 9031 |
echo "$ac_t""$selecth" 1>&6 |
| 9032 |
fi |
| 9033 |
|
| 9034 |
|
| 9035 |
|
| 9036 |
|
| 9037 |
if test "${SYS}" = sunos ; then |
| 9038 |
# Use getwd on SunOS -- getcwd does a "popen("/bin/pwd")" -- aaaccck. |
| 9039 |
# |
| 9040 |
for ac_func in getwd |
| 9041 |
do |
| 9042 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 9043 |
echo "configure:9044: checking for $ac_func" >&5 |
| 9044 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 9045 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9046 |
else |
| 9047 |
cat > conftest.$ac_ext <<EOF |
| 9048 |
#line 9049 "configure" |
| 9049 |
#include "confdefs.h" |
| 9050 |
/* System header to define __stub macros and hopefully few prototypes, |
| 9051 |
which can conflict with char $ac_func(); below. */ |
| 9052 |
#include <assert.h> |
| 9053 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9054 |
/* We use char because int might match the return type of a gcc2 |
| 9055 |
builtin and then its argument prototype would still apply. */ |
| 9056 |
char $ac_func(); |
| 9057 |
|
| 9058 |
int main(void) { |
| 9059 |
|
| 9060 |
/* The GNU C library defines this for functions which it implements |
| 9061 |
to always fail with ENOSYS. Some functions are actually named |
| 9062 |
something starting with __ and the normal name is an alias. */ |
| 9063 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 9064 |
choke me |
| 9065 |
#else |
| 9066 |
$ac_func(); |
| 9067 |
#endif |
| 9068 |
|
| 9069 |
; return 0; } |
| 9070 |
EOF |
| 9071 |
if { (eval echo configure:9072: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9072 |
rm -rf conftest* |
| 9073 |
eval "ac_cv_func_$ac_func=yes" |
| 9074 |
else |
| 9075 |
echo "configure: failed program was:" >&5 |
| 9076 |
cat conftest.$ac_ext >&5 |
| 9077 |
rm -rf conftest* |
| 9078 |
eval "ac_cv_func_$ac_func=no" |
| 9079 |
fi |
| 9080 |
rm -rf conftest* |
| 9081 |
fi |
| 9082 |
|
| 9083 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 9084 |
echo "$ac_t""yes" 1>&6 |
| 9085 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 9086 |
cat >> confdefs.h <<EOF |
| 9087 |
#define $ac_tr_func 1 |
| 9088 |
EOF |
| 9089 |
|
| 9090 |
else |
| 9091 |
echo "$ac_t""no" 1>&6 |
| 9092 |
fi |
| 9093 |
done |
| 9094 |
|
| 9095 |
else |
| 9096 |
for ac_func in getcwd getwd |
| 9097 |
do |
| 9098 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 9099 |
echo "configure:9100: checking for $ac_func" >&5 |
| 9100 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 9101 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9102 |
else |
| 9103 |
cat > conftest.$ac_ext <<EOF |
| 9104 |
#line 9105 "configure" |
| 9105 |
#include "confdefs.h" |
| 9106 |
/* System header to define __stub macros and hopefully few prototypes, |
| 9107 |
which can conflict with char $ac_func(); below. */ |
| 9108 |
#include <assert.h> |
| 9109 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9110 |
/* We use char because int might match the return type of a gcc2 |
| 9111 |
builtin and then its argument prototype would still apply. */ |
| 9112 |
char $ac_func(); |
| 9113 |
|
| 9114 |
int main(void) { |
| 9115 |
|
| 9116 |
/* The GNU C library defines this for functions which it implements |
| 9117 |
to always fail with ENOSYS. Some functions are actually named |
| 9118 |
something starting with __ and the normal name is an alias. */ |
| 9119 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 9120 |
choke me |
| 9121 |
#else |
| 9122 |
$ac_func(); |
| 9123 |
#endif |
| 9124 |
|
| 9125 |
; return 0; } |
| 9126 |
EOF |
| 9127 |
if { (eval echo configure:9128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9128 |
rm -rf conftest* |
| 9129 |
eval "ac_cv_func_$ac_func=yes" |
| 9130 |
else |
| 9131 |
echo "configure: failed program was:" >&5 |
| 9132 |
cat conftest.$ac_ext >&5 |
| 9133 |
rm -rf conftest* |
| 9134 |
eval "ac_cv_func_$ac_func=no" |
| 9135 |
fi |
| 9136 |
rm -rf conftest* |
| 9137 |
fi |
| 9138 |
|
| 9139 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 9140 |
echo "$ac_t""yes" 1>&6 |
| 9141 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 9142 |
cat >> confdefs.h <<EOF |
| 9143 |
#define $ac_tr_func 1 |
| 9144 |
EOF |
| 9145 |
|
| 9146 |
else |
| 9147 |
echo "$ac_t""no" 1>&6 |
| 9148 |
fi |
| 9149 |
done |
| 9150 |
|
| 9151 |
fi |
| 9152 |
if test "$ac_cv_func_getcwd" = no && test "$ac_cv_func_getwd" = no ; then |
| 9153 |
echo "configure: warning: This system does not have either getwd or getcwd?" 1>&2 |
| 9154 |
echo "configure: warning: I find that a little hard to believe." 1>&2 |
| 9155 |
echo "configure: warning: You may want to try -DHAVE_GETWD anyway." 1>&2 |
| 9156 |
echo "configure: warning: |
| 9157 |
This could also mean that your compiler isn't working" 1>&2 |
| 9158 |
echo "configure: warning: with this configure script. Check the ./config.log" 1>&2 |
| 9159 |
echo "configure: warning: and look for anomalies." 1>&2 |
| 9160 |
fi |
| 9161 |
|
| 9162 |
for ac_func in fstat64 getdomainname gethostname getpass getpassphrase gnu_get_libc_release gnu_get_libc_version inet_aton inet_ntop llseek lseek64 lstat64 memmove mktime open64 pathconf readlink recvfile res_init sendfile setlocale setpgid setpgrp setsid setvbuf sigaction sigsetjmp stat64 strcasecmp strcoll strdup strerror strncoll strstr strtoq symlink sysconf sysctl sysinfo syslog tcgetattr uname waitpid |
| 9163 |
do |
| 9164 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 9165 |
echo "configure:9166: checking for $ac_func" >&5 |
| 9166 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 9167 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9168 |
else |
| 9169 |
cat > conftest.$ac_ext <<EOF |
| 9170 |
#line 9171 "configure" |
| 9171 |
#include "confdefs.h" |
| 9172 |
/* System header to define __stub macros and hopefully few prototypes, |
| 9173 |
which can conflict with char $ac_func(); below. */ |
| 9174 |
#include <assert.h> |
| 9175 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9176 |
/* We use char because int might match the return type of a gcc2 |
| 9177 |
builtin and then its argument prototype would still apply. */ |
| 9178 |
char $ac_func(); |
| 9179 |
|
| 9180 |
int main(void) { |
| 9181 |
|
| 9182 |
/* The GNU C library defines this for functions which it implements |
| 9183 |
to always fail with ENOSYS. Some functions are actually named |
| 9184 |
something starting with __ and the normal name is an alias. */ |
| 9185 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 9186 |
choke me |
| 9187 |
#else |
| 9188 |
$ac_func(); |
| 9189 |
#endif |
| 9190 |
|
| 9191 |
; return 0; } |
| 9192 |
EOF |
| 9193 |
if { (eval echo configure:9194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9194 |
rm -rf conftest* |
| 9195 |
eval "ac_cv_func_$ac_func=yes" |
| 9196 |
else |
| 9197 |
echo "configure: failed program was:" >&5 |
| 9198 |
cat conftest.$ac_ext >&5 |
| 9199 |
rm -rf conftest* |
| 9200 |
eval "ac_cv_func_$ac_func=no" |
| 9201 |
fi |
| 9202 |
rm -rf conftest* |
| 9203 |
fi |
| 9204 |
|
| 9205 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 9206 |
echo "$ac_t""yes" 1>&6 |
| 9207 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 9208 |
cat >> confdefs.h <<EOF |
| 9209 |
#define $ac_tr_func 1 |
| 9210 |
EOF |
| 9211 |
|
| 9212 |
else |
| 9213 |
echo "$ac_t""no" 1>&6 |
| 9214 |
fi |
| 9215 |
done |
| 9216 |
|
| 9217 |
for ac_func in gethostbyaddr_r gethostbyname_r gethostbyname2_r getlogin_r getpwnam_r _posix_getpwnam_r getpwuid_r _posix_getpwuid_r getservbyname_r getservbyport_r gmtime_r localtime_r readdir_r |
| 9218 |
do |
| 9219 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 9220 |
echo "configure:9221: checking for $ac_func" >&5 |
| 9221 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 9222 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9223 |
else |
| 9224 |
cat > conftest.$ac_ext <<EOF |
| 9225 |
#line 9226 "configure" |
| 9226 |
#include "confdefs.h" |
| 9227 |
/* System header to define __stub macros and hopefully few prototypes, |
| 9228 |
which can conflict with char $ac_func(); below. */ |
| 9229 |
#include <assert.h> |
| 9230 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9231 |
/* We use char because int might match the return type of a gcc2 |
| 9232 |
builtin and then its argument prototype would still apply. */ |
| 9233 |
char $ac_func(); |
| 9234 |
|
| 9235 |
int main(void) { |
| 9236 |
|
| 9237 |
/* The GNU C library defines this for functions which it implements |
| 9238 |
to always fail with ENOSYS. Some functions are actually named |
| 9239 |
something starting with __ and the normal name is an alias. */ |
| 9240 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 9241 |
choke me |
| 9242 |
#else |
| 9243 |
$ac_func(); |
| 9244 |
#endif |
| 9245 |
|
| 9246 |
; return 0; } |
| 9247 |
EOF |
| 9248 |
if { (eval echo configure:9249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9249 |
rm -rf conftest* |
| 9250 |
eval "ac_cv_func_$ac_func=yes" |
| 9251 |
else |
| 9252 |
echo "configure: failed program was:" >&5 |
| 9253 |
cat conftest.$ac_ext >&5 |
| 9254 |
rm -rf conftest* |
| 9255 |
eval "ac_cv_func_$ac_func=no" |
| 9256 |
fi |
| 9257 |
rm -rf conftest* |
| 9258 |
fi |
| 9259 |
|
| 9260 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 9261 |
echo "$ac_t""yes" 1>&6 |
| 9262 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 9263 |
cat >> confdefs.h <<EOF |
| 9264 |
#define $ac_tr_func 1 |
| 9265 |
EOF |
| 9266 |
|
| 9267 |
else |
| 9268 |
echo "$ac_t""no" 1>&6 |
| 9269 |
fi |
| 9270 |
done |
| 9271 |
|
| 9272 |
|
| 9273 |
unset ac_cv_func_snprintf |
| 9274 |
unset ac_cv_func_vsnprintf |
| 9275 |
|
| 9276 |
for ac_func in snprintf vsnprintf |
| 9277 |
do |
| 9278 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 9279 |
echo "configure:9280: checking for $ac_func" >&5 |
| 9280 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 9281 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9282 |
else |
| 9283 |
cat > conftest.$ac_ext <<EOF |
| 9284 |
#line 9285 "configure" |
| 9285 |
#include "confdefs.h" |
| 9286 |
/* System header to define __stub macros and hopefully few prototypes, |
| 9287 |
which can conflict with char $ac_func(); below. */ |
| 9288 |
#include <assert.h> |
| 9289 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9290 |
/* We use char because int might match the return type of a gcc2 |
| 9291 |
builtin and then its argument prototype would still apply. */ |
| 9292 |
char $ac_func(); |
| 9293 |
|
| 9294 |
int main(void) { |
| 9295 |
|
| 9296 |
/* The GNU C library defines this for functions which it implements |
| 9297 |
to always fail with ENOSYS. Some functions are actually named |
| 9298 |
something starting with __ and the normal name is an alias. */ |
| 9299 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 9300 |
choke me |
| 9301 |
#else |
| 9302 |
$ac_func(); |
| 9303 |
#endif |
| 9304 |
|
| 9305 |
; return 0; } |
| 9306 |
EOF |
| 9307 |
if { (eval echo configure:9308: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9308 |
rm -rf conftest* |
| 9309 |
eval "ac_cv_func_$ac_func=yes" |
| 9310 |
else |
| 9311 |
echo "configure: failed program was:" >&5 |
| 9312 |
cat conftest.$ac_ext >&5 |
| 9313 |
rm -rf conftest* |
| 9314 |
eval "ac_cv_func_$ac_func=no" |
| 9315 |
fi |
| 9316 |
rm -rf conftest* |
| 9317 |
fi |
| 9318 |
|
| 9319 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 9320 |
echo "$ac_t""yes" 1>&6 |
| 9321 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 9322 |
cat >> confdefs.h <<EOF |
| 9323 |
#define $ac_tr_func 1 |
| 9324 |
EOF |
| 9325 |
|
| 9326 |
else |
| 9327 |
echo "$ac_t""no" 1>&6 |
| 9328 |
fi |
| 9329 |
done |
| 9330 |
|
| 9331 |
if test "$ac_cv_func_snprintf" = yes ; then |
| 9332 |
|
| 9333 |
if test "$ac_cv_func_snprintf" != "no" ; then |
| 9334 |
echo $ac_n "checking if snprintf works correctly""... $ac_c" 1>&6 |
| 9335 |
echo "configure:9336: checking if snprintf works correctly" >&5 |
| 9336 |
|
| 9337 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 9338 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SNPRINTF_TERMINATES." 1>&2; exit 1; } |
| 9339 |
fi |
| 9340 |
|
| 9341 |
if test "$cross_compiling" = yes; then |
| 9342 |
|
| 9343 |
# action if cross compiling |
| 9344 |
wi_cv_snprintf_terminates=yes |
| 9345 |
cat >> confdefs.h <<\EOF |
| 9346 |
#define SNPRINTF_TERMINATES 1 |
| 9347 |
EOF |
| 9348 |
|
| 9349 |
guess="(guessing) " |
| 9350 |
x="yes" |
| 9351 |
|
| 9352 |
else |
| 9353 |
cat > conftest.$ac_ext <<EOF |
| 9354 |
#line 9355 "configure" |
| 9355 |
#include "confdefs.h" |
| 9356 |
|
| 9357 |
/* program */ |
| 9358 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 9359 |
# define _ALL_SOURCE 1 |
| 9360 |
#endif |
| 9361 |
#ifdef HAVE_UNISTD_H |
| 9362 |
# include <unistd.h> |
| 9363 |
#endif |
| 9364 |
#include <stdio.h> |
| 9365 |
#include <string.h> |
| 9366 |
#ifdef HAVE_STRINGS_H |
| 9367 |
#include <strings.h> |
| 9368 |
#endif |
| 9369 |
#ifdef HAVE_STDLIB_H |
| 9370 |
# include <stdlib.h> |
| 9371 |
#endif |
| 9372 |
#ifdef HAVE_SNPRINTF_H |
| 9373 |
# include <snprintf.h> |
| 9374 |
#endif |
| 9375 |
|
| 9376 |
int main(void) |
| 9377 |
{ |
| 9378 |
char s[16]; |
| 9379 |
int i, result; |
| 9380 |
|
| 9381 |
for (i=0; i<(int)(sizeof(s)/sizeof(char)); i++) |
| 9382 |
s[i] = 'x'; |
| 9383 |
result = (int) snprintf(s + 1, 10, "%s %s!", "hello", "world"); |
| 9384 |
if (s[10] != '\0') |
| 9385 |
exit(1); /* did not force termination! */ |
| 9386 |
if (s[11] != 'x') |
| 9387 |
exit(2); /* overflow! */ |
| 9388 |
if (s[0] != 'x') |
| 9389 |
exit(3); /* underflow! */ |
| 9390 |
exit(0); |
| 9391 |
} |
| 9392 |
|
| 9393 |
EOF |
| 9394 |
if { (eval echo configure:9395: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 9395 |
then |
| 9396 |
|
| 9397 |
# action if true |
| 9398 |
wi_cv_snprintf_terminates=yes |
| 9399 |
cat >> confdefs.h <<\EOF |
| 9400 |
#define SNPRINTF_TERMINATES 1 |
| 9401 |
EOF |
| 9402 |
|
| 9403 |
guess="" |
| 9404 |
x="yes" |
| 9405 |
|
| 9406 |
else |
| 9407 |
echo "configure: failed program was:" >&5 |
| 9408 |
cat conftest.$ac_ext >&5 |
| 9409 |
rm -fr conftest* |
| 9410 |
|
| 9411 |
# action if false |
| 9412 |
wi_cv_snprintf_terminates=no |
| 9413 |
guess="" |
| 9414 |
x="no" |
| 9415 |
|
| 9416 |
fi |
| 9417 |
rm -fr conftest* |
| 9418 |
fi |
| 9419 |
|
| 9420 |
echo "$ac_t""$guess$x" 1>&6 |
| 9421 |
fi |
| 9422 |
|
| 9423 |
|
| 9424 |
echo $ac_n "checking what snprintf() returns""... $ac_c" 1>&6 |
| 9425 |
echo "configure:9426: checking what snprintf() returns" >&5 |
| 9426 |
if test "$cross_compiling" = yes; then |
| 9427 |
|
| 9428 |
# action if cross compiling |
| 9429 |
wi_cv_snprintf_returns_ptr=no |
| 9430 |
guess="(guessing) " |
| 9431 |
x="length of data written" |
| 9432 |
|
| 9433 |
else |
| 9434 |
cat > conftest.$ac_ext <<EOF |
| 9435 |
#line 9436 "configure" |
| 9436 |
#include "confdefs.h" |
| 9437 |
|
| 9438 |
/* program */ |
| 9439 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 9440 |
# define _ALL_SOURCE 1 |
| 9441 |
#endif |
| 9442 |
#ifdef HAVE_UNISTD_H |
| 9443 |
# include <unistd.h> |
| 9444 |
#endif |
| 9445 |
#include <stdio.h> |
| 9446 |
#include <string.h> |
| 9447 |
#ifdef HAVE_STRINGS_H |
| 9448 |
#include <strings.h> |
| 9449 |
#endif |
| 9450 |
#ifdef HAVE_STDLIB_H |
| 9451 |
# include <stdlib.h> |
| 9452 |
#endif |
| 9453 |
#ifdef HAVE_SNPRINTF_H |
| 9454 |
# include <snprintf.h> |
| 9455 |
#endif |
| 9456 |
|
| 9457 |
int main(void) |
| 9458 |
{ |
| 9459 |
int result; |
| 9460 |
char s[8]; |
| 9461 |
|
| 9462 |
result = (int) snprintf(s, sizeof(s) - 1, "%d", 22); |
| 9463 |
if (result == 2) |
| 9464 |
exit(0); |
| 9465 |
exit(1); |
| 9466 |
|
| 9467 |
} |
| 9468 |
|
| 9469 |
EOF |
| 9470 |
if { (eval echo configure:9471: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 9471 |
then |
| 9472 |
|
| 9473 |
# action if true |
| 9474 |
wi_cv_snprintf_returns_ptr=no |
| 9475 |
guess="" |
| 9476 |
x="length of data written" |
| 9477 |
|
| 9478 |
else |
| 9479 |
echo "configure: failed program was:" >&5 |
| 9480 |
cat conftest.$ac_ext >&5 |
| 9481 |
rm -fr conftest* |
| 9482 |
|
| 9483 |
# action if false |
| 9484 |
wi_cv_snprintf_returns_ptr=yes |
| 9485 |
cat >> confdefs.h <<\EOF |
| 9486 |
#define SNPRINTF_RETURNS_PTR 1 |
| 9487 |
EOF |
| 9488 |
|
| 9489 |
guess="" |
| 9490 |
x="pointer to data" |
| 9491 |
|
| 9492 |
fi |
| 9493 |
rm -fr conftest* |
| 9494 |
fi |
| 9495 |
|
| 9496 |
echo "$ac_t""$guess$x" 1>&6 |
| 9497 |
|
| 9498 |
|
| 9499 |
if [ "$ac_cv_func_snprintf" = "no" ] || [ "$wi_cv_snprintf_terminates" = "no" ] || [ "$wi_cv_snprintf_returns_ptr" = "yes" ] ; then |
| 9500 |
echo $ac_n "checking for snprintf in -lsnprintf""... $ac_c" 1>&6 |
| 9501 |
echo "configure:9502: checking for snprintf in -lsnprintf" >&5 |
| 9502 |
ac_lib_var=`echo snprintf'_'snprintf | sed 'y%./+-%__p_%'` |
| 9503 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 9504 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9505 |
else |
| 9506 |
ac_save_LIBS="$LIBS" |
| 9507 |
LIBS="-lsnprintf $LIBS" |
| 9508 |
cat > conftest.$ac_ext <<EOF |
| 9509 |
#line 9510 "configure" |
| 9510 |
#include "confdefs.h" |
| 9511 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9512 |
/* We use char because int might match the return type of a gcc2 |
| 9513 |
builtin and then its argument prototype would still apply. */ |
| 9514 |
char snprintf(); |
| 9515 |
|
| 9516 |
int main(void) { |
| 9517 |
snprintf() |
| 9518 |
; return 0; } |
| 9519 |
EOF |
| 9520 |
if { (eval echo configure:9521: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9521 |
rm -rf conftest* |
| 9522 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 9523 |
else |
| 9524 |
echo "configure: failed program was:" >&5 |
| 9525 |
cat conftest.$ac_ext >&5 |
| 9526 |
rm -rf conftest* |
| 9527 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 9528 |
fi |
| 9529 |
rm -rf conftest* |
| 9530 |
LIBS="$ac_save_LIBS" |
| 9531 |
|
| 9532 |
fi |
| 9533 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 9534 |
echo "$ac_t""yes" 1>&6 |
| 9535 |
ac_tr_lib=HAVE_LIB`echo snprintf | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 9536 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 9537 |
cat >> confdefs.h <<EOF |
| 9538 |
#define $ac_tr_lib 1 |
| 9539 |
EOF |
| 9540 |
|
| 9541 |
LIBS="-lsnprintf $LIBS" |
| 9542 |
|
| 9543 |
else |
| 9544 |
echo "$ac_t""no" 1>&6 |
| 9545 |
fi |
| 9546 |
|
| 9547 |
if test "$ac_cv_lib_snprintf_snprintf" = yes ; then |
| 9548 |
unset ac_cv_func_snprintf ac_cv_func_vsnprintf |
| 9549 |
for ac_hdr in snprintf.h |
| 9550 |
do |
| 9551 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 9552 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 9553 |
echo "configure:9554: checking for $ac_hdr" >&5 |
| 9554 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 9555 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9556 |
else |
| 9557 |
cat > conftest.$ac_ext <<EOF |
| 9558 |
#line 9559 "configure" |
| 9559 |
#include "confdefs.h" |
| 9560 |
#include <$ac_hdr> |
| 9561 |
EOF |
| 9562 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 9563 |
{ (eval echo configure:9564: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 9564 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 9565 |
if test -z "$ac_err"; then |
| 9566 |
rm -rf conftest* |
| 9567 |
eval "ac_cv_header_$ac_safe=yes" |
| 9568 |
else |
| 9569 |
echo "$ac_err" >&5 |
| 9570 |
echo "configure: failed program was:" >&5 |
| 9571 |
cat conftest.$ac_ext >&5 |
| 9572 |
rm -rf conftest* |
| 9573 |
eval "ac_cv_header_$ac_safe=no" |
| 9574 |
fi |
| 9575 |
rm -rf conftest* |
| 9576 |
fi |
| 9577 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 9578 |
echo "$ac_t""yes" 1>&6 |
| 9579 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 9580 |
cat >> confdefs.h <<EOF |
| 9581 |
#define $ac_tr_hdr 1 |
| 9582 |
EOF |
| 9583 |
|
| 9584 |
else |
| 9585 |
echo "$ac_t""no" 1>&6 |
| 9586 |
fi |
| 9587 |
done |
| 9588 |
|
| 9589 |
for ac_func in snprintf vsnprintf |
| 9590 |
do |
| 9591 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 9592 |
echo "configure:9593: checking for $ac_func" >&5 |
| 9593 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 9594 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9595 |
else |
| 9596 |
cat > conftest.$ac_ext <<EOF |
| 9597 |
#line 9598 "configure" |
| 9598 |
#include "confdefs.h" |
| 9599 |
/* System header to define __stub macros and hopefully few prototypes, |
| 9600 |
which can conflict with char $ac_func(); below. */ |
| 9601 |
#include <assert.h> |
| 9602 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9603 |
/* We use char because int might match the return type of a gcc2 |
| 9604 |
builtin and then its argument prototype would still apply. */ |
| 9605 |
char $ac_func(); |
| 9606 |
|
| 9607 |
int main(void) { |
| 9608 |
|
| 9609 |
/* The GNU C library defines this for functions which it implements |
| 9610 |
to always fail with ENOSYS. Some functions are actually named |
| 9611 |
something starting with __ and the normal name is an alias. */ |
| 9612 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 9613 |
choke me |
| 9614 |
#else |
| 9615 |
$ac_func(); |
| 9616 |
#endif |
| 9617 |
|
| 9618 |
; return 0; } |
| 9619 |
EOF |
| 9620 |
if { (eval echo configure:9621: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9621 |
rm -rf conftest* |
| 9622 |
eval "ac_cv_func_$ac_func=yes" |
| 9623 |
else |
| 9624 |
echo "configure: failed program was:" >&5 |
| 9625 |
cat conftest.$ac_ext >&5 |
| 9626 |
rm -rf conftest* |
| 9627 |
eval "ac_cv_func_$ac_func=no" |
| 9628 |
fi |
| 9629 |
rm -rf conftest* |
| 9630 |
fi |
| 9631 |
|
| 9632 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 9633 |
echo "$ac_t""yes" 1>&6 |
| 9634 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 9635 |
cat >> confdefs.h <<EOF |
| 9636 |
#define $ac_tr_func 1 |
| 9637 |
EOF |
| 9638 |
|
| 9639 |
else |
| 9640 |
echo "$ac_t""no" 1>&6 |
| 9641 |
fi |
| 9642 |
done |
| 9643 |
|
| 9644 |
fi |
| 9645 |
fi |
| 9646 |
|
| 9647 |
else |
| 9648 |
|
| 9649 |
if [ "$ac_cv_func_snprintf" = "no" ] || [ "$wi_cv_snprintf_terminates" = "no" ] || [ "$wi_cv_snprintf_returns_ptr" = "yes" ] ; then |
| 9650 |
echo $ac_n "checking for snprintf in -lsnprintf""... $ac_c" 1>&6 |
| 9651 |
echo "configure:9652: checking for snprintf in -lsnprintf" >&5 |
| 9652 |
ac_lib_var=`echo snprintf'_'snprintf | sed 'y%./+-%__p_%'` |
| 9653 |
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 9654 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9655 |
else |
| 9656 |
ac_save_LIBS="$LIBS" |
| 9657 |
LIBS="-lsnprintf $LIBS" |
| 9658 |
cat > conftest.$ac_ext <<EOF |
| 9659 |
#line 9660 "configure" |
| 9660 |
#include "confdefs.h" |
| 9661 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9662 |
/* We use char because int might match the return type of a gcc2 |
| 9663 |
builtin and then its argument prototype would still apply. */ |
| 9664 |
char snprintf(); |
| 9665 |
|
| 9666 |
int main(void) { |
| 9667 |
snprintf() |
| 9668 |
; return 0; } |
| 9669 |
EOF |
| 9670 |
if { (eval echo configure:9671: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9671 |
rm -rf conftest* |
| 9672 |
eval "ac_cv_lib_$ac_lib_var=yes" |
| 9673 |
else |
| 9674 |
echo "configure: failed program was:" >&5 |
| 9675 |
cat conftest.$ac_ext >&5 |
| 9676 |
rm -rf conftest* |
| 9677 |
eval "ac_cv_lib_$ac_lib_var=no" |
| 9678 |
fi |
| 9679 |
rm -rf conftest* |
| 9680 |
LIBS="$ac_save_LIBS" |
| 9681 |
|
| 9682 |
fi |
| 9683 |
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 9684 |
echo "$ac_t""yes" 1>&6 |
| 9685 |
ac_tr_lib=HAVE_LIB`echo snprintf | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 9686 |
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
| 9687 |
cat >> confdefs.h <<EOF |
| 9688 |
#define $ac_tr_lib 1 |
| 9689 |
EOF |
| 9690 |
|
| 9691 |
LIBS="-lsnprintf $LIBS" |
| 9692 |
|
| 9693 |
else |
| 9694 |
echo "$ac_t""no" 1>&6 |
| 9695 |
fi |
| 9696 |
|
| 9697 |
if test "$ac_cv_lib_snprintf_snprintf" = yes ; then |
| 9698 |
unset ac_cv_func_snprintf ac_cv_func_vsnprintf |
| 9699 |
for ac_hdr in snprintf.h |
| 9700 |
do |
| 9701 |
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
| 9702 |
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
| 9703 |
echo "configure:9704: checking for $ac_hdr" >&5 |
| 9704 |
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
| 9705 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9706 |
else |
| 9707 |
cat > conftest.$ac_ext <<EOF |
| 9708 |
#line 9709 "configure" |
| 9709 |
#include "confdefs.h" |
| 9710 |
#include <$ac_hdr> |
| 9711 |
EOF |
| 9712 |
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
| 9713 |
{ (eval echo configure:9714: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
| 9714 |
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 9715 |
if test -z "$ac_err"; then |
| 9716 |
rm -rf conftest* |
| 9717 |
eval "ac_cv_header_$ac_safe=yes" |
| 9718 |
else |
| 9719 |
echo "$ac_err" >&5 |
| 9720 |
echo "configure: failed program was:" >&5 |
| 9721 |
cat conftest.$ac_ext >&5 |
| 9722 |
rm -rf conftest* |
| 9723 |
eval "ac_cv_header_$ac_safe=no" |
| 9724 |
fi |
| 9725 |
rm -rf conftest* |
| 9726 |
fi |
| 9727 |
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 9728 |
echo "$ac_t""yes" 1>&6 |
| 9729 |
ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
| 9730 |
cat >> confdefs.h <<EOF |
| 9731 |
#define $ac_tr_hdr 1 |
| 9732 |
EOF |
| 9733 |
|
| 9734 |
else |
| 9735 |
echo "$ac_t""no" 1>&6 |
| 9736 |
fi |
| 9737 |
done |
| 9738 |
|
| 9739 |
for ac_func in snprintf vsnprintf |
| 9740 |
do |
| 9741 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 9742 |
echo "configure:9743: checking for $ac_func" >&5 |
| 9743 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 9744 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9745 |
else |
| 9746 |
cat > conftest.$ac_ext <<EOF |
| 9747 |
#line 9748 "configure" |
| 9748 |
#include "confdefs.h" |
| 9749 |
/* System header to define __stub macros and hopefully few prototypes, |
| 9750 |
which can conflict with char $ac_func(); below. */ |
| 9751 |
#include <assert.h> |
| 9752 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 9753 |
/* We use char because int might match the return type of a gcc2 |
| 9754 |
builtin and then its argument prototype would still apply. */ |
| 9755 |
char $ac_func(); |
| 9756 |
|
| 9757 |
int main(void) { |
| 9758 |
|
| 9759 |
/* The GNU C library defines this for functions which it implements |
| 9760 |
to always fail with ENOSYS. Some functions are actually named |
| 9761 |
something starting with __ and the normal name is an alias. */ |
| 9762 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 9763 |
choke me |
| 9764 |
#else |
| 9765 |
$ac_func(); |
| 9766 |
#endif |
| 9767 |
|
| 9768 |
; return 0; } |
| 9769 |
EOF |
| 9770 |
if { (eval echo configure:9771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 9771 |
rm -rf conftest* |
| 9772 |
eval "ac_cv_func_$ac_func=yes" |
| 9773 |
else |
| 9774 |
echo "configure: failed program was:" >&5 |
| 9775 |
cat conftest.$ac_ext >&5 |
| 9776 |
rm -rf conftest* |
| 9777 |
eval "ac_cv_func_$ac_func=no" |
| 9778 |
fi |
| 9779 |
rm -rf conftest* |
| 9780 |
fi |
| 9781 |
|
| 9782 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 9783 |
echo "$ac_t""yes" 1>&6 |
| 9784 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 9785 |
cat >> confdefs.h <<EOF |
| 9786 |
#define $ac_tr_func 1 |
| 9787 |
EOF |
| 9788 |
|
| 9789 |
else |
| 9790 |
echo "$ac_t""no" 1>&6 |
| 9791 |
fi |
| 9792 |
done |
| 9793 |
|
| 9794 |
fi |
| 9795 |
fi |
| 9796 |
|
| 9797 |
|
| 9798 |
if test "$ac_cv_func_snprintf" != "no" ; then |
| 9799 |
echo $ac_n "checking if snprintf works correctly""... $ac_c" 1>&6 |
| 9800 |
echo "configure:9801: checking if snprintf works correctly" >&5 |
| 9801 |
|
| 9802 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 9803 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_SNPRINTF_TERMINATES." 1>&2; exit 1; } |
| 9804 |
fi |
| 9805 |
|
| 9806 |
if test "$cross_compiling" = yes; then |
| 9807 |
|
| 9808 |
# action if cross compiling |
| 9809 |
wi_cv_snprintf_terminates=yes |
| 9810 |
cat >> confdefs.h <<\EOF |
| 9811 |
#define SNPRINTF_TERMINATES 1 |
| 9812 |
EOF |
| 9813 |
|
| 9814 |
guess="(guessing) " |
| 9815 |
x="yes" |
| 9816 |
|
| 9817 |
else |
| 9818 |
cat > conftest.$ac_ext <<EOF |
| 9819 |
#line 9820 "configure" |
| 9820 |
#include "confdefs.h" |
| 9821 |
|
| 9822 |
/* program */ |
| 9823 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 9824 |
# define _ALL_SOURCE 1 |
| 9825 |
#endif |
| 9826 |
#ifdef HAVE_UNISTD_H |
| 9827 |
# include <unistd.h> |
| 9828 |
#endif |
| 9829 |
#include <stdio.h> |
| 9830 |
#include <string.h> |
| 9831 |
#ifdef HAVE_STRINGS_H |
| 9832 |
#include <strings.h> |
| 9833 |
#endif |
| 9834 |
#ifdef HAVE_STDLIB_H |
| 9835 |
# include <stdlib.h> |
| 9836 |
#endif |
| 9837 |
#ifdef HAVE_SNPRINTF_H |
| 9838 |
# include <snprintf.h> |
| 9839 |
#endif |
| 9840 |
|
| 9841 |
int main(void) |
| 9842 |
{ |
| 9843 |
char s[16]; |
| 9844 |
int i, result; |
| 9845 |
|
| 9846 |
for (i=0; i<(int)(sizeof(s)/sizeof(char)); i++) |
| 9847 |
s[i] = 'x'; |
| 9848 |
result = (int) snprintf(s + 1, 10, "%s %s!", "hello", "world"); |
| 9849 |
if (s[10] != '\0') |
| 9850 |
exit(1); /* did not force termination! */ |
| 9851 |
if (s[11] != 'x') |
| 9852 |
exit(2); /* overflow! */ |
| 9853 |
if (s[0] != 'x') |
| 9854 |
exit(3); /* underflow! */ |
| 9855 |
exit(0); |
| 9856 |
} |
| 9857 |
|
| 9858 |
EOF |
| 9859 |
if { (eval echo configure:9860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 9860 |
then |
| 9861 |
|
| 9862 |
# action if true |
| 9863 |
wi_cv_snprintf_terminates=yes |
| 9864 |
cat >> confdefs.h <<\EOF |
| 9865 |
#define SNPRINTF_TERMINATES 1 |
| 9866 |
EOF |
| 9867 |
|
| 9868 |
guess="" |
| 9869 |
x="yes" |
| 9870 |
|
| 9871 |
else |
| 9872 |
echo "configure: failed program was:" >&5 |
| 9873 |
cat conftest.$ac_ext >&5 |
| 9874 |
rm -fr conftest* |
| 9875 |
|
| 9876 |
# action if false |
| 9877 |
wi_cv_snprintf_terminates=no |
| 9878 |
guess="" |
| 9879 |
x="no" |
| 9880 |
|
| 9881 |
fi |
| 9882 |
rm -fr conftest* |
| 9883 |
fi |
| 9884 |
|
| 9885 |
echo "$ac_t""$guess$x" 1>&6 |
| 9886 |
fi |
| 9887 |
|
| 9888 |
|
| 9889 |
echo $ac_n "checking what snprintf() returns""... $ac_c" 1>&6 |
| 9890 |
echo "configure:9891: checking what snprintf() returns" >&5 |
| 9891 |
if test "$cross_compiling" = yes; then |
| 9892 |
|
| 9893 |
# action if cross compiling |
| 9894 |
wi_cv_snprintf_returns_ptr=no |
| 9895 |
guess="(guessing) " |
| 9896 |
x="length of data written" |
| 9897 |
|
| 9898 |
else |
| 9899 |
cat > conftest.$ac_ext <<EOF |
| 9900 |
#line 9901 "configure" |
| 9901 |
#include "confdefs.h" |
| 9902 |
|
| 9903 |
/* program */ |
| 9904 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 9905 |
# define _ALL_SOURCE 1 |
| 9906 |
#endif |
| 9907 |
#ifdef HAVE_UNISTD_H |
| 9908 |
# include <unistd.h> |
| 9909 |
#endif |
| 9910 |
#include <stdio.h> |
| 9911 |
#include <string.h> |
| 9912 |
#ifdef HAVE_STRINGS_H |
| 9913 |
#include <strings.h> |
| 9914 |
#endif |
| 9915 |
#ifdef HAVE_STDLIB_H |
| 9916 |
# include <stdlib.h> |
| 9917 |
#endif |
| 9918 |
#ifdef HAVE_SNPRINTF_H |
| 9919 |
# include <snprintf.h> |
| 9920 |
#endif |
| 9921 |
|
| 9922 |
int main(void) |
| 9923 |
{ |
| 9924 |
int result; |
| 9925 |
char s[8]; |
| 9926 |
|
| 9927 |
result = (int) snprintf(s, sizeof(s) - 1, "%d", 22); |
| 9928 |
if (result == 2) |
| 9929 |
exit(0); |
| 9930 |
exit(1); |
| 9931 |
|
| 9932 |
} |
| 9933 |
|
| 9934 |
EOF |
| 9935 |
if { (eval echo configure:9936: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 9936 |
then |
| 9937 |
|
| 9938 |
# action if true |
| 9939 |
wi_cv_snprintf_returns_ptr=no |
| 9940 |
guess="" |
| 9941 |
x="length of data written" |
| 9942 |
|
| 9943 |
else |
| 9944 |
echo "configure: failed program was:" >&5 |
| 9945 |
cat conftest.$ac_ext >&5 |
| 9946 |
rm -fr conftest* |
| 9947 |
|
| 9948 |
# action if false |
| 9949 |
wi_cv_snprintf_returns_ptr=yes |
| 9950 |
cat >> confdefs.h <<\EOF |
| 9951 |
#define SNPRINTF_RETURNS_PTR 1 |
| 9952 |
EOF |
| 9953 |
|
| 9954 |
guess="" |
| 9955 |
x="pointer to data" |
| 9956 |
|
| 9957 |
fi |
| 9958 |
rm -fr conftest* |
| 9959 |
fi |
| 9960 |
|
| 9961 |
echo "$ac_t""$guess$x" 1>&6 |
| 9962 |
|
| 9963 |
fi |
| 9964 |
|
| 9965 |
|
| 9966 |
|
| 9967 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 9968 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_FUNC_SIGSETJMP." 1>&2; exit 1; } |
| 9969 |
fi |
| 9970 |
|
| 9971 |
echo $ac_n "checking for sigsetjmp and siglongjmp""... $ac_c" 1>&6 |
| 9972 |
echo "configure:9973: checking for sigsetjmp and siglongjmp" >&5 |
| 9973 |
if eval "test \"`echo '$''{'wi_cv_func_sigsetjmp'+set}'`\" = set"; then |
| 9974 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 9975 |
else |
| 9976 |
|
| 9977 |
|
| 9978 |
cat > conftest.$ac_ext <<EOF |
| 9979 |
#line 9980 "configure" |
| 9980 |
#include "confdefs.h" |
| 9981 |
|
| 9982 |
/* includes */ |
| 9983 |
#ifdef HAVE_UNISTD_H |
| 9984 |
# include <unistd.h> |
| 9985 |
#endif |
| 9986 |
#include <sys/types.h> |
| 9987 |
#include <stdio.h> |
| 9988 |
#ifdef HAVE_STDLIB_H |
| 9989 |
# include <stdlib.h> |
| 9990 |
#endif |
| 9991 |
#include <signal.h> |
| 9992 |
#include <setjmp.h> |
| 9993 |
|
| 9994 |
int main(void) { |
| 9995 |
|
| 9996 |
/* function-body */ |
| 9997 |
sigjmp_buf sjb; |
| 9998 |
|
| 9999 |
if (sigsetjmp(sjb, 1) != 0) |
| 10000 |
siglongjmp(sjb, 1); /* bogus code, of course. */ |
| 10001 |
exit(0); |
| 10002 |
|
| 10003 |
; return 0; } |
| 10004 |
EOF |
| 10005 |
if { (eval echo configure:10006: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10006 |
rm -rf conftest* |
| 10007 |
|
| 10008 |
wi_cv_func_sigsetjmp=yes |
| 10009 |
|
| 10010 |
else |
| 10011 |
echo "configure: failed program was:" >&5 |
| 10012 |
cat conftest.$ac_ext >&5 |
| 10013 |
rm -rf conftest* |
| 10014 |
|
| 10015 |
wi_cv_func_sigsetjmp=no |
| 10016 |
|
| 10017 |
fi |
| 10018 |
rm -rf conftest* |
| 10019 |
|
| 10020 |
fi |
| 10021 |
|
| 10022 |
echo "$ac_t""$wi_cv_func_sigsetjmp" 1>&6 |
| 10023 |
if test "$wi_cv_func_sigsetjmp" = yes ; then |
| 10024 |
cat >> confdefs.h <<\EOF |
| 10025 |
#define HAVE_SIGSETJMP 1 |
| 10026 |
EOF |
| 10027 |
|
| 10028 |
fi |
| 10029 |
|
| 10030 |
|
| 10031 |
if test "x$ac_cv_func_setpgid" = "x" ; then |
| 10032 |
for ac_func in setpgid setpgrp |
| 10033 |
do |
| 10034 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 10035 |
echo "configure:10036: checking for $ac_func" >&5 |
| 10036 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 10037 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10038 |
else |
| 10039 |
cat > conftest.$ac_ext <<EOF |
| 10040 |
#line 10041 "configure" |
| 10041 |
#include "confdefs.h" |
| 10042 |
/* System header to define __stub macros and hopefully few prototypes, |
| 10043 |
which can conflict with char $ac_func(); below. */ |
| 10044 |
#include <assert.h> |
| 10045 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 10046 |
/* We use char because int might match the return type of a gcc2 |
| 10047 |
builtin and then its argument prototype would still apply. */ |
| 10048 |
char $ac_func(); |
| 10049 |
|
| 10050 |
int main(void) { |
| 10051 |
|
| 10052 |
/* The GNU C library defines this for functions which it implements |
| 10053 |
to always fail with ENOSYS. Some functions are actually named |
| 10054 |
something starting with __ and the normal name is an alias. */ |
| 10055 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 10056 |
choke me |
| 10057 |
#else |
| 10058 |
$ac_func(); |
| 10059 |
#endif |
| 10060 |
|
| 10061 |
; return 0; } |
| 10062 |
EOF |
| 10063 |
if { (eval echo configure:10064: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10064 |
rm -rf conftest* |
| 10065 |
eval "ac_cv_func_$ac_func=yes" |
| 10066 |
else |
| 10067 |
echo "configure: failed program was:" >&5 |
| 10068 |
cat conftest.$ac_ext >&5 |
| 10069 |
rm -rf conftest* |
| 10070 |
eval "ac_cv_func_$ac_func=no" |
| 10071 |
fi |
| 10072 |
rm -rf conftest* |
| 10073 |
fi |
| 10074 |
|
| 10075 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 10076 |
echo "$ac_t""yes" 1>&6 |
| 10077 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 10078 |
cat >> confdefs.h <<EOF |
| 10079 |
#define $ac_tr_func 1 |
| 10080 |
EOF |
| 10081 |
|
| 10082 |
else |
| 10083 |
echo "$ac_t""no" 1>&6 |
| 10084 |
fi |
| 10085 |
done |
| 10086 |
|
| 10087 |
fi |
| 10088 |
echo $ac_n "checking if setpgrp behavior needs to be checked""... $ac_c" 1>&6 |
| 10089 |
echo "configure:10090: checking if setpgrp behavior needs to be checked" >&5 |
| 10090 |
if test "x$ac_cv_func_setpgid" = "xyes" ; then |
| 10091 |
# OK, we will be using setpgid instead of setpgrp then... |
| 10092 |
echo "$ac_t""no" 1>&6 |
| 10093 |
ac_cv_func_setpgrp_void=dontcare |
| 10094 |
elif test "x$cross_compiling" = "xyes" ; then |
| 10095 |
echo "$ac_t""yes" 1>&6 |
| 10096 |
echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6 |
| 10097 |
echo "configure:10098: checking whether setpgrp takes no argument" >&5 |
| 10098 |
case "`uname -a`" in |
| 10099 |
*BSD*|*bsd*) |
| 10100 |
ac_cv_func_setpgrp_void="no" |
| 10101 |
;; |
| 10102 |
*) |
| 10103 |
ac_cv_func_setpgrp_void="yes" |
| 10104 |
cat >> confdefs.h <<\EOF |
| 10105 |
#define SETPGRP_VOID 1 |
| 10106 |
EOF |
| 10107 |
|
| 10108 |
;; |
| 10109 |
esac |
| 10110 |
echo "$ac_t"""${ac_cv_func_setpgrp_void}?"" 1>&6 |
| 10111 |
else |
| 10112 |
# We're not cross compiling, so we can try this check |
| 10113 |
echo "$ac_t""yes" 1>&6 |
| 10114 |
echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6 |
| 10115 |
echo "configure:10116: checking whether setpgrp takes no argument" >&5 |
| 10116 |
if eval "test \"`echo '$''{'ac_cv_func_setpgrp_void'+set}'`\" = set"; then |
| 10117 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10118 |
else |
| 10119 |
if test "$cross_compiling" = yes; then |
| 10120 |
{ echo "configure: error: cannot check setpgrp if cross compiling" 1>&2; exit 1; } |
| 10121 |
else |
| 10122 |
cat > conftest.$ac_ext <<EOF |
| 10123 |
#line 10124 "configure" |
| 10124 |
#include "confdefs.h" |
| 10125 |
|
| 10126 |
#ifdef HAVE_UNISTD_H |
| 10127 |
#include <unistd.h> |
| 10128 |
#endif |
| 10129 |
|
| 10130 |
/* |
| 10131 |
* If this system has a BSD-style setpgrp, which takes arguments, exit |
| 10132 |
* successfully. |
| 10133 |
*/ |
| 10134 |
int main(void) |
| 10135 |
{ |
| 10136 |
if (setpgrp(1,1) == -1) |
| 10137 |
exit(0); |
| 10138 |
else |
| 10139 |
exit(1); |
| 10140 |
} |
| 10141 |
|
| 10142 |
EOF |
| 10143 |
if { (eval echo configure:10144: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 10144 |
then |
| 10145 |
ac_cv_func_setpgrp_void=no |
| 10146 |
else |
| 10147 |
echo "configure: failed program was:" >&5 |
| 10148 |
cat conftest.$ac_ext >&5 |
| 10149 |
rm -fr conftest* |
| 10150 |
ac_cv_func_setpgrp_void=yes |
| 10151 |
fi |
| 10152 |
rm -fr conftest* |
| 10153 |
fi |
| 10154 |
|
| 10155 |
|
| 10156 |
fi |
| 10157 |
|
| 10158 |
echo "$ac_t""$ac_cv_func_setpgrp_void" 1>&6 |
| 10159 |
if test $ac_cv_func_setpgrp_void = yes; then |
| 10160 |
cat >> confdefs.h <<\EOF |
| 10161 |
#define SETPGRP_VOID 1 |
| 10162 |
EOF |
| 10163 |
|
| 10164 |
fi |
| 10165 |
|
| 10166 |
fi |
| 10167 |
|
| 10168 |
|
| 10169 |
echo $ac_n "checking whether setvbuf behavior can be checked""... $ac_c" 1>&6 |
| 10170 |
echo "configure:10171: checking whether setvbuf behavior can be checked" >&5 |
| 10171 |
if test "x$cross_compiling" = "xyes" ; then |
| 10172 |
echo "$ac_t""no" 1>&6 |
| 10173 |
else |
| 10174 |
echo "$ac_t""yes" 1>&6 |
| 10175 |
echo $ac_n "checking whether setvbuf arguments are reversed""... $ac_c" 1>&6 |
| 10176 |
echo "configure:10177: checking whether setvbuf arguments are reversed" >&5 |
| 10177 |
if eval "test \"`echo '$''{'ac_cv_func_setvbuf_reversed'+set}'`\" = set"; then |
| 10178 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10179 |
else |
| 10180 |
if test "$cross_compiling" = yes; then |
| 10181 |
ac_cv_func_setvbuf_reversed=no |
| 10182 |
else |
| 10183 |
cat > conftest.$ac_ext <<EOF |
| 10184 |
#line 10185 "configure" |
| 10185 |
#include "confdefs.h" |
| 10186 |
#include <stdio.h> |
| 10187 |
/* If setvbuf has the reversed format, exit 0. */ |
| 10188 |
main () { |
| 10189 |
/* This call has the arguments reversed. |
| 10190 |
A reversed system may check and see that the address of main |
| 10191 |
is not _IOLBF, _IONBF, or _IOFBF, and return nonzero. */ |
| 10192 |
if (setvbuf(stdout, _IOLBF, (char *) main, BUFSIZ) != 0) |
| 10193 |
exit(1); |
| 10194 |
putc('\r', stdout); |
| 10195 |
exit(0); /* Non-reversed systems segv here. */ |
| 10196 |
} |
| 10197 |
EOF |
| 10198 |
if { (eval echo configure:10199: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 10199 |
then |
| 10200 |
ac_cv_func_setvbuf_reversed=yes |
| 10201 |
else |
| 10202 |
echo "configure: failed program was:" >&5 |
| 10203 |
cat conftest.$ac_ext >&5 |
| 10204 |
rm -fr conftest* |
| 10205 |
ac_cv_func_setvbuf_reversed=no |
| 10206 |
fi |
| 10207 |
rm -fr conftest* |
| 10208 |
fi |
| 10209 |
|
| 10210 |
rm -f core core.* *.core |
| 10211 |
fi |
| 10212 |
|
| 10213 |
echo "$ac_t""$ac_cv_func_setvbuf_reversed" 1>&6 |
| 10214 |
if test $ac_cv_func_setvbuf_reversed = yes; then |
| 10215 |
cat >> confdefs.h <<\EOF |
| 10216 |
#define SETVBUF_REVERSED 1 |
| 10217 |
EOF |
| 10218 |
|
| 10219 |
fi |
| 10220 |
fi |
| 10221 |
|
| 10222 |
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works |
| 10223 |
# for constant arguments. Useless! |
| 10224 |
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 |
| 10225 |
echo "configure:10226: checking for working alloca.h" >&5 |
| 10226 |
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then |
| 10227 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10228 |
else |
| 10229 |
cat > conftest.$ac_ext <<EOF |
| 10230 |
#line 10231 "configure" |
| 10231 |
#include "confdefs.h" |
| 10232 |
#include <alloca.h> |
| 10233 |
int main(void) { |
| 10234 |
char *p = alloca(2 * sizeof(int)); |
| 10235 |
; return 0; } |
| 10236 |
EOF |
| 10237 |
if { (eval echo configure:10238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10238 |
rm -rf conftest* |
| 10239 |
ac_cv_header_alloca_h=yes |
| 10240 |
else |
| 10241 |
echo "configure: failed program was:" >&5 |
| 10242 |
cat conftest.$ac_ext >&5 |
| 10243 |
rm -rf conftest* |
| 10244 |
ac_cv_header_alloca_h=no |
| 10245 |
fi |
| 10246 |
rm -rf conftest* |
| 10247 |
fi |
| 10248 |
|
| 10249 |
echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 |
| 10250 |
if test $ac_cv_header_alloca_h = yes; then |
| 10251 |
cat >> confdefs.h <<\EOF |
| 10252 |
#define HAVE_ALLOCA_H 1 |
| 10253 |
EOF |
| 10254 |
|
| 10255 |
fi |
| 10256 |
|
| 10257 |
echo $ac_n "checking for alloca""... $ac_c" 1>&6 |
| 10258 |
echo "configure:10259: checking for alloca" >&5 |
| 10259 |
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then |
| 10260 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10261 |
else |
| 10262 |
cat > conftest.$ac_ext <<EOF |
| 10263 |
#line 10264 "configure" |
| 10264 |
#include "confdefs.h" |
| 10265 |
|
| 10266 |
#ifdef __GNUC__ |
| 10267 |
# define alloca __builtin_alloca |
| 10268 |
#else |
| 10269 |
# ifdef _MSC_VER |
| 10270 |
# include <malloc.h> |
| 10271 |
# define alloca _alloca |
| 10272 |
# else |
| 10273 |
# if HAVE_ALLOCA_H |
| 10274 |
# include <alloca.h> |
| 10275 |
# else |
| 10276 |
# ifdef _AIX |
| 10277 |
#pragma alloca |
| 10278 |
# else |
| 10279 |
# ifndef alloca /* predefined by HP cc +Olibcalls */ |
| 10280 |
char *alloca (); |
| 10281 |
# endif |
| 10282 |
# endif |
| 10283 |
# endif |
| 10284 |
# endif |
| 10285 |
#endif |
| 10286 |
|
| 10287 |
int main(void) { |
| 10288 |
char *p = (char *) alloca(1); |
| 10289 |
; return 0; } |
| 10290 |
EOF |
| 10291 |
if { (eval echo configure:10292: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10292 |
rm -rf conftest* |
| 10293 |
ac_cv_func_alloca_works=yes |
| 10294 |
else |
| 10295 |
echo "configure: failed program was:" >&5 |
| 10296 |
cat conftest.$ac_ext >&5 |
| 10297 |
rm -rf conftest* |
| 10298 |
ac_cv_func_alloca_works=no |
| 10299 |
fi |
| 10300 |
rm -rf conftest* |
| 10301 |
fi |
| 10302 |
|
| 10303 |
echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 |
| 10304 |
if test $ac_cv_func_alloca_works = yes; then |
| 10305 |
cat >> confdefs.h <<\EOF |
| 10306 |
#define HAVE_ALLOCA 1 |
| 10307 |
EOF |
| 10308 |
|
| 10309 |
fi |
| 10310 |
|
| 10311 |
if test $ac_cv_func_alloca_works = no; then |
| 10312 |
# The SVR3 libPW and SVR4 libucb both contain incompatible functions |
| 10313 |
# that cause trouble. Some versions do not even contain alloca or |
| 10314 |
# contain a buggy version. If you still want to use their alloca, |
| 10315 |
# use ar to extract alloca.o from them instead of compiling alloca.c. |
| 10316 |
ALLOCA=alloca.${ac_objext} |
| 10317 |
cat >> confdefs.h <<\EOF |
| 10318 |
#define C_ALLOCA 1 |
| 10319 |
EOF |
| 10320 |
|
| 10321 |
|
| 10322 |
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 |
| 10323 |
echo "configure:10324: checking whether alloca needs Cray hooks" >&5 |
| 10324 |
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then |
| 10325 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10326 |
else |
| 10327 |
cat > conftest.$ac_ext <<EOF |
| 10328 |
#line 10329 "configure" |
| 10329 |
#include "confdefs.h" |
| 10330 |
#if defined(CRAY) && ! defined(CRAY2) |
| 10331 |
webecray |
| 10332 |
#else |
| 10333 |
wenotbecray |
| 10334 |
#endif |
| 10335 |
|
| 10336 |
EOF |
| 10337 |
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 10338 |
egrep "webecray" >/dev/null 2>&1; then |
| 10339 |
rm -rf conftest* |
| 10340 |
ac_cv_os_cray=yes |
| 10341 |
else |
| 10342 |
rm -rf conftest* |
| 10343 |
ac_cv_os_cray=no |
| 10344 |
fi |
| 10345 |
rm -rf conftest* |
| 10346 |
|
| 10347 |
fi |
| 10348 |
|
| 10349 |
echo "$ac_t""$ac_cv_os_cray" 1>&6 |
| 10350 |
if test $ac_cv_os_cray = yes; then |
| 10351 |
for ac_func in _getb67 GETB67 getb67; do |
| 10352 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 10353 |
echo "configure:10354: checking for $ac_func" >&5 |
| 10354 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 10355 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10356 |
else |
| 10357 |
cat > conftest.$ac_ext <<EOF |
| 10358 |
#line 10359 "configure" |
| 10359 |
#include "confdefs.h" |
| 10360 |
/* System header to define __stub macros and hopefully few prototypes, |
| 10361 |
which can conflict with char $ac_func(); below. */ |
| 10362 |
#include <assert.h> |
| 10363 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 10364 |
/* We use char because int might match the return type of a gcc2 |
| 10365 |
builtin and then its argument prototype would still apply. */ |
| 10366 |
char $ac_func(); |
| 10367 |
|
| 10368 |
int main(void) { |
| 10369 |
|
| 10370 |
/* The GNU C library defines this for functions which it implements |
| 10371 |
to always fail with ENOSYS. Some functions are actually named |
| 10372 |
something starting with __ and the normal name is an alias. */ |
| 10373 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 10374 |
choke me |
| 10375 |
#else |
| 10376 |
$ac_func(); |
| 10377 |
#endif |
| 10378 |
|
| 10379 |
; return 0; } |
| 10380 |
EOF |
| 10381 |
if { (eval echo configure:10382: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10382 |
rm -rf conftest* |
| 10383 |
eval "ac_cv_func_$ac_func=yes" |
| 10384 |
else |
| 10385 |
echo "configure: failed program was:" >&5 |
| 10386 |
cat conftest.$ac_ext >&5 |
| 10387 |
rm -rf conftest* |
| 10388 |
eval "ac_cv_func_$ac_func=no" |
| 10389 |
fi |
| 10390 |
rm -rf conftest* |
| 10391 |
fi |
| 10392 |
|
| 10393 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 10394 |
echo "$ac_t""yes" 1>&6 |
| 10395 |
cat >> confdefs.h <<EOF |
| 10396 |
#define CRAY_STACKSEG_END $ac_func |
| 10397 |
EOF |
| 10398 |
|
| 10399 |
break |
| 10400 |
else |
| 10401 |
echo "$ac_t""no" 1>&6 |
| 10402 |
fi |
| 10403 |
|
| 10404 |
done |
| 10405 |
fi |
| 10406 |
|
| 10407 |
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 |
| 10408 |
echo "configure:10409: checking stack direction for C alloca" >&5 |
| 10409 |
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then |
| 10410 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10411 |
else |
| 10412 |
if test "$cross_compiling" = yes; then |
| 10413 |
ac_cv_c_stack_direction=0 |
| 10414 |
else |
| 10415 |
cat > conftest.$ac_ext <<EOF |
| 10416 |
#line 10417 "configure" |
| 10417 |
#include "confdefs.h" |
| 10418 |
find_stack_direction () |
| 10419 |
{ |
| 10420 |
static char *addr = 0; |
| 10421 |
auto char dummy; |
| 10422 |
if (addr == 0) |
| 10423 |
{ |
| 10424 |
addr = &dummy; |
| 10425 |
return find_stack_direction (); |
| 10426 |
} |
| 10427 |
else |
| 10428 |
return (&dummy > addr) ? 1 : -1; |
| 10429 |
} |
| 10430 |
main () |
| 10431 |
{ |
| 10432 |
exit (find_stack_direction() < 0); |
| 10433 |
} |
| 10434 |
EOF |
| 10435 |
if { (eval echo configure:10436: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
| 10436 |
then |
| 10437 |
ac_cv_c_stack_direction=1 |
| 10438 |
else |
| 10439 |
echo "configure: failed program was:" >&5 |
| 10440 |
cat conftest.$ac_ext >&5 |
| 10441 |
rm -fr conftest* |
| 10442 |
ac_cv_c_stack_direction=-1 |
| 10443 |
fi |
| 10444 |
rm -fr conftest* |
| 10445 |
fi |
| 10446 |
|
| 10447 |
fi |
| 10448 |
|
| 10449 |
echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 |
| 10450 |
cat >> confdefs.h <<EOF |
| 10451 |
#define STACK_DIRECTION $ac_cv_c_stack_direction |
| 10452 |
EOF |
| 10453 |
|
| 10454 |
fi |
| 10455 |
|
| 10456 |
if test "$wi_cv_lib_curses" = "yes" ; then |
| 10457 |
|
| 10458 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 10459 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_CURSES_FEATURES." 1>&2; exit 1; } |
| 10460 |
fi |
| 10461 |
|
| 10462 |
# Then $LIBCURSES is a list of curses and support libraries. |
| 10463 |
ac_save_LIBS="$LIBS"; |
| 10464 |
LIBS="$LIBS $LIBCURSES"; |
| 10465 |
|
| 10466 |
|
| 10467 |
|
| 10468 |
|
| 10469 |
|
| 10470 |
|
| 10471 |
if test "x$ac_cv_header_unistd_h" = x ; then |
| 10472 |
{ echo "configure: error: Script needs to check for <unistd.h> before calling wi_CURSES_FUNC_PARAM_TYPES." 1>&2; exit 1; } |
| 10473 |
fi |
| 10474 |
|
| 10475 |
echo $ac_n "checking string parameter to waddstr""... $ac_c" 1>&6 |
| 10476 |
echo "configure:10477: checking string parameter to waddstr" >&5 |
| 10477 |
if eval "test \"`echo '$''{'wi_cv_waddstr_str_t'+set}'`\" = set"; then |
| 10478 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10479 |
else |
| 10480 |
|
| 10481 |
used_cache_for_wi_curses_fpt="no" |
| 10482 |
|
| 10483 |
|
| 10484 |
wi_tmpdir="" |
| 10485 |
if [ "x$MKTEMP" != "x" ] ; then |
| 10486 |
# Ignore error from mktemp, since some old versions of Linux |
| 10487 |
# print an error about not supporting -d. |
| 10488 |
# |
| 10489 |
wi_tmpdir=`"$MKTEMP" -d /tmp/configure.XXXXXXXXXX 2>/dev/null` |
| 10490 |
if [ $? -ne 0 ] ; then |
| 10491 |
wi_tmpdir="" |
| 10492 |
fi |
| 10493 |
fi |
| 10494 |
if [ "x$wi_tmpdir" = "x" ] ; then |
| 10495 |
for wi_tmpdir in . $TMPDIR $TEMPDIR /tmp ABORT |
| 10496 |
do |
| 10497 |
if [ "$wi_tmpdir" = ABORT ] ; then |
| 10498 |
echo "Cannot create temporary directory." |
| 10499 |
exit 1 |
| 10500 |
fi |
| 10501 |
wi_tmpdir="$wi_tmpdir/config_tmp.$$" |
| 10502 |
if [ -d "$wi_tmpdir" ] || [ -f "$wi_tmpdir" ] ; then |
| 10503 |
echo "Will not create temporary directory." |
| 10504 |
exit 1 |
| 10505 |
fi |
| 10506 |
mkdir "$wi_tmpdir" |
| 10507 |
if [ $? -eq 0 ] && [ -d "$wi_tmpdir" ] ; then break ; fi |
| 10508 |
done |
| 10509 |
fi |
| 10510 |
|
| 10511 |
# Use the temporary directory here... |
| 10512 |
|
| 10513 |
|
| 10514 |
cat << 'EOF' > "$wi_tmpdir/prpp.pl" |
| 10515 |
#!/usr/bin/perl -w |
| 10516 |
# |
| 10517 |
# prpp.pl |
| 10518 |
# |
| 10519 |
# Feed the output of your CPP to this to print a list of function prototypes. |
| 10520 |
# |
| 10521 |
#use strict; |
| 10522 |
|
| 10523 |
my ($c) = ""; |
| 10524 |
my ($unputc) = ""; |
| 10525 |
my ($line) = ""; |
| 10526 |
my ($lines) = ""; |
| 10527 |
my ($cline) = ""; |
| 10528 |
my ($skipping) = 0; |
| 10529 |
my ($numclines) = 0; |
| 10530 |
|
| 10531 |
MAINLOOP: while (1) { |
| 10532 |
if ($unputc ne "") { |
| 10533 |
$c = $unputc; |
| 10534 |
$unputc = ""; |
| 10535 |
} else { |
| 10536 |
last unless (read(STDIN, $c, 1) == 1); |
| 10537 |
} |
| 10538 |
if ($c eq "{") { |
| 10539 |
$skipping++; |
| 10540 |
} elsif ($c eq "}") { |
| 10541 |
--$skipping; |
| 10542 |
$unputc = ";"; |
| 10543 |
} elsif ($skipping) { |
| 10544 |
next MAINLOOP; |
| 10545 |
} elsif ($c eq ";") { |
| 10546 |
if ($line =~ m/^\s*(\S.*\S)\s*$/s) { |
| 10547 |
$lines .= $1; |
| 10548 |
$line = ""; |
| 10549 |
} |
| 10550 |
if ($lines =~ m/^\s*(extern\s*)?(\S.*\S)\s*$/s) { |
| 10551 |
$cline = $2; |
| 10552 |
$cline =~ s/\s+/\ /g; |
| 10553 |
if ($cline =~ /^typedef/) { |
| 10554 |
$cline = ""; |
| 10555 |
} elsif ($cline =~ /\(.*\)$/) { |
| 10556 |
# found a proto |
| 10557 |
print $cline, ";\n"; |
| 10558 |
$numclines++; |
| 10559 |
} else { |
| 10560 |
$cline = ""; |
| 10561 |
} |
| 10562 |
} |
| 10563 |
$lines = ""; |
| 10564 |
$line = ""; |
| 10565 |
} elsif ($c eq "\n") { |
| 10566 |
if ($line =~ m/^\s*(\S.*\S)\s*$/s) { |
| 10567 |
$lines .= $1 . " "; |
| 10568 |
$line = ""; |
| 10569 |
} |
| 10570 |
} elsif (($c eq "#") && ($line eq "")) { |
| 10571 |
# Looks like a preprocessor line, kill it |
| 10572 |
{ |
| 10573 |
last MAINLOOP if (read(STDIN, $c, 1) != 1); |
| 10574 |
last if ($c eq "\n"); |
| 10575 |
redo; |
| 10576 |
} |
| 10577 |
} elsif ($c =~ /^\s$/) { |
| 10578 |
$line .= " " if ($line ne ""); |
| 10579 |
} elsif (! $skipping) { |
| 10580 |
$line .= $c; |
| 10581 |
} |
| 10582 |
} |
| 10583 |
exit(($numclines == 0) ? 1 : 0); |
| 10584 |
EOF |
| 10585 |
chmod 755 "$wi_tmpdir/prpp.pl" |
| 10586 |
|
| 10587 |
|
| 10588 |
cat << 'EOF' > "$wi_tmpdir/curses.c" |
| 10589 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 10590 |
# define _ALL_SOURCE 1 |
| 10591 |
#endif |
| 10592 |
#include <confdefs.h> |
| 10593 |
#ifdef HAVE_UNISTD_H |
| 10594 |
# include <unistd.h> |
| 10595 |
#endif |
| 10596 |
#include <sys/types.h> |
| 10597 |
#include <stdio.h> |
| 10598 |
#include <string.h> |
| 10599 |
#ifdef HAVE_STDLIB_H |
| 10600 |
# include <stdlib.h> |
| 10601 |
#endif |
| 10602 |
|
| 10603 |
#ifdef HAVE_NCURSES_H |
| 10604 |
# define NCURSES_OPAQUE 0 |
| 10605 |
# include <ncurses.h> |
| 10606 |
#else |
| 10607 |
# include <curses.h> |
| 10608 |
#endif |
| 10609 |
|
| 10610 |
int main(void) |
| 10611 |
{ |
| 10612 |
exit(0); |
| 10613 |
} |
| 10614 |
EOF |
| 10615 |
|
| 10616 |
cat << 'EOF' > "$wi_tmpdir/sed2.sh" |
| 10617 |
#!/bin/sh |
| 10618 |
|
| 10619 |
if [ $# -eq 0 ] ; then exit 1 ; fi |
| 10620 |
x="$1" |
| 10621 |
|
| 10622 |
sed -n 's/extern//;s/static//; |
| 10623 |
/[\ \*]'"$x"'\ *(/{ |
| 10624 |
s/^.*'"$x"'\ *(/(/ |
| 10625 |
s/)\ *[;,].*$/)/ |
| 10626 |
/const char/{ |
| 10627 |
c\ |
| 10628 |
const char * |
| 10629 |
} |
| 10630 |
/char/{ |
| 10631 |
c\ |
| 10632 |
char * |
| 10633 |
} |
| 10634 |
/const/{ |
| 10635 |
c\ |
| 10636 |
const void |
| 10637 |
} |
| 10638 |
q |
| 10639 |
}' |
| 10640 |
EOF |
| 10641 |
chmod 755 "$wi_tmpdir/sed2.sh" |
| 10642 |
|
| 10643 |
$CPP "-I${srcdir-.}" "$wi_tmpdir/curses.c" > "$wi_tmpdir/curses.i" |
| 10644 |
if [ -s "$wi_tmpdir/curses.i" ] ; then |
| 10645 |
"$PERL" "$wi_tmpdir/prpp.pl" < "$wi_tmpdir/curses.i" > "$wi_tmpdir/protos.h" |
| 10646 |
fi |
| 10647 |
if [ -f "$wi_tmpdir/protos.h" ] ; then |
| 10648 |
# |
| 10649 |
# Check what type waddstr() expects for the string parameter |
| 10650 |
# |
| 10651 |
x="waddstr" |
| 10652 |
wi_cv_waddstr_str_t=`/bin/sh "$wi_tmpdir/sed2.sh" "$x" < "$wi_tmpdir/protos.h"` |
| 10653 |
fi |
| 10654 |
if [ "x$wi_cv_waddstr_str_t" = "x" ] ; then |
| 10655 |
wi_cv_waddstr_str_t="const char *" |
| 10656 |
fi |
| 10657 |
|
| 10658 |
# Done using the temporary directory here. |
| 10659 |
|
| 10660 |
rm -r "$wi_tmpdir" |
| 10661 |
unset wi_tmpdir |
| 10662 |
|
| 10663 |
|
| 10664 |
fi |
| 10665 |
|
| 10666 |
echo "$ac_t""$wi_cv_waddstr_str_t" 1>&6 |
| 10667 |
unset used_cache_for_wi_curses_fpt |
| 10668 |
cat >> confdefs.h <<EOF |
| 10669 |
#define waddstr_str_t $wi_cv_waddstr_str_t |
| 10670 |
EOF |
| 10671 |
|
| 10672 |
if test "$wi_cv_waddstr_str_t" = "const char *" ; then |
| 10673 |
cat >> confdefs.h <<\EOF |
| 10674 |
#define WADDSTR_TYPE_ARG1_CONST 1 |
| 10675 |
EOF |
| 10676 |
|
| 10677 |
fi |
| 10678 |
|
| 10679 |
|
| 10680 |
# maxx or _maxx |
| 10681 |
echo $ac_n "checking whether curses structure has maxx or _maxx field""... $ac_c" 1>&6 |
| 10682 |
echo "configure:10683: checking whether curses structure has maxx or _maxx field" >&5 |
| 10683 |
cat > conftest.$ac_ext <<EOF |
| 10684 |
#line 10685 "configure" |
| 10685 |
#include "confdefs.h" |
| 10686 |
|
| 10687 |
/* includes */ |
| 10688 |
#if defined(AIX) || defined(_AIX) || defined(__HOS_AIX__) |
| 10689 |
# define _ALL_SOURCE 1 |
| 10690 |
#endif |
| 10691 |
#ifdef HAVE_UNISTD_H |
| 10692 |
# include <unistd.h> |
| 10693 |
#endif |
| 10694 |
#include <sys/types.h> |
| 10695 |
#include <stdio.h> |
| 10696 |
#include <string.h> |
| 10697 |
#include <stdlib.h> |
| 10698 |
|
| 10699 |
#ifdef HAVE_NCURSES_H |
| 10700 |
# define NCURSES_OPAQUE 0 |
| 10701 |
# include <ncurses.h> |
| 10702 |
#else |
| 10703 |
# include <curses.h> |
| 10704 |
#endif |
| 10705 |
|
| 10706 |
int main(void) { |
| 10707 |
|
| 10708 |
WINDOW *w; |
| 10709 |
|
| 10710 |
w = newwin(10, 10, 1, 1); |
| 10711 |
w->maxx = 0; |
| 10712 |
|
| 10713 |
; return 0; } |
| 10714 |
EOF |
| 10715 |
if { (eval echo configure:10716: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
| 10716 |
rm -rf conftest* |
| 10717 |
|
| 10718 |
echo "$ac_t""maxx" 1>&6 |
| 10719 |
|
| 10720 |
else |
| 10721 |
echo "configure: failed program was:" >&5 |
| 10722 |
cat conftest.$ac_ext >&5 |
| 10723 |
rm -rf conftest* |
| 10724 |
|
| 10725 |
cat >> confdefs.h <<\EOF |
| 10726 |
#define HAVE__MAXX 1 |
| 10727 |
EOF |
| 10728 |
|
| 10729 |
echo "$ac_t""_maxx" 1>&6 |
| 10730 |
|
| 10731 |
fi |
| 10732 |
rm -rf conftest* |
| 10733 |
|
| 10734 |
if test "${SYS-hpux}" = hpux ; then |
| 10735 |
for ac_func in __getcurx __getcury __getmaxx __getmaxy __getbegx __getbegy |
| 10736 |
do |
| 10737 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 10738 |
echo "configure:10739: checking for $ac_func" >&5 |
| 10739 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 10740 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 10741 |
else |
| 10742 |
cat > conftest.$ac_ext <<EOF |
| 10743 |
#line 10744 "configure" |
| 10744 |
#include "confdefs.h" |
| 10745 |
/* System header to define __stub macros and hopefully few prototypes, |
| 10746 |
which can conflict with char $ac_func(); below. */ |
| 10747 |
#include <assert.h> |
| 10748 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 10749 |
/* We use char because int might match the return type of a gcc2 |
| 10750 |
builtin and then its argument prototype would still apply. */ |
| 10751 |
char $ac_func(); |
| 10752 |
|
| 10753 |
int main(void) { |
| 10754 |
|
| 10755 |
/* The GNU C library defines this for functions which it implements |
| 10756 |
to always fail with ENOSYS. Some functions are actually named |
| 10757 |
something starting with __ and the normal name is an alias. */ |
| 10758 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 10759 |
choke me |
| 10760 |
#else |
| 10761 |
$ac_func(); |
| 10762 |
#endif |
| 10763 |
|
| 10764 |
; return 0; } |
| 10765 |
EOF |
| 10766 |
if { (eval echo configure:10767: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10767 |
rm -rf conftest* |
| 10768 |
eval "ac_cv_func_$ac_func=yes" |
| 10769 |
else |
| 10770 |
echo "configure: failed program was:" >&5 |
| 10771 |
cat conftest.$ac_ext >&5 |
| 10772 |
rm -rf conftest* |
| 10773 |
eval "ac_cv_func_$ac_func=no" |
| 10774 |
fi |
| 10775 |
rm -rf conftest* |
| 10776 |
fi |
| 10777 |
|
| 10778 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 10779 |
echo "$ac_t""yes" 1>&6 |
| 10780 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 10781 |
cat >> confdefs.h <<EOF |
| 10782 |
#define $ac_tr_func 1 |
| 10783 |
EOF |
| 10784 |
|
| 10785 |
else |
| 10786 |
echo "$ac_t""no" 1>&6 |
| 10787 |
fi |
| 10788 |
done |
| 10789 |
|
| 10790 |
fi |
| 10791 |
|
| 10792 |
# getcurx |
| 10793 |
echo $ac_n "checking for getcurx() functionality in curses library""... $ac_c" 1>&6 |
| 10794 |
echo "configure:10795: checking for getcurx() functionality in curses library" >&5 |
| 10795 |
cat > conftest.$ac_ext <<EOF |
| 10796 |
#line 10797 "configure" |
| 10797 |
#include "confdefs.h" |
| 10798 |
|
| 10799 |
/* includes */ |
| 10800 |
#ifdef HAVE_UNISTD_H |
| 10801 |
# include <unistd.h> |
| 10802 |
#endif |
| 10803 |
#include <sys/types.h> |
| 10804 |
#include <stdio.h> |
| 10805 |
#include <string.h> |
| 10806 |
#ifdef HAVE_STDLIB_H |
| 10807 |
# include <stdlib.h> |
| 10808 |
#endif |
| 10809 |
|
| 10810 |
#ifdef HAVE_NCURSES_H |
| 10811 |
# define NCURSES_OPAQUE 0 |
| 10812 |
# include <ncurses.h> |
| 10813 |
#else |
| 10814 |
# include <curses.h> |
| 10815 |
#endif |
| 10816 |
|
| 10817 |
|
| 10818 |
int main(void) { |
| 10819 |
|
| 10820 |
/* function-body */ |
| 10821 |
WINDOW *junk = 0; |
| 10822 |
int mx = 0; |
| 10823 |
|
| 10824 |
mx = getcurx(junk); |
| 10825 |
exit(0); |
| 10826 |
|
| 10827 |
; return 0; } |
| 10828 |
EOF |
| 10829 |
if { (eval echo configure:10830: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10830 |
rm -rf conftest* |
| 10831 |
|
| 10832 |
cat >> confdefs.h <<\EOF |
| 10833 |
#define HAVE_GETCURX 1 |
| 10834 |
EOF |
| 10835 |
|
| 10836 |
echo "$ac_t""yes" 1>&6 |
| 10837 |
|
| 10838 |
else |
| 10839 |
echo "configure: failed program was:" >&5 |
| 10840 |
cat conftest.$ac_ext >&5 |
| 10841 |
rm -rf conftest* |
| 10842 |
|
| 10843 |
echo "$ac_t""no" 1>&6 |
| 10844 |
|
| 10845 |
fi |
| 10846 |
rm -rf conftest* |
| 10847 |
|
| 10848 |
# getyx |
| 10849 |
echo $ac_n "checking for getyx() functionality in curses library""... $ac_c" 1>&6 |
| 10850 |
echo "configure:10851: checking for getyx() functionality in curses library" >&5 |
| 10851 |
cat > conftest.$ac_ext <<EOF |
| 10852 |
#line 10853 "configure" |
| 10853 |
#include "confdefs.h" |
| 10854 |
|
| 10855 |
/* includes */ |
| 10856 |
#ifdef HAVE_UNISTD_H |
| 10857 |
# include <unistd.h> |
| 10858 |
#endif |
| 10859 |
#include <sys/types.h> |
| 10860 |
#include <stdio.h> |
| 10861 |
#include <string.h> |
| 10862 |
#ifdef HAVE_STDLIB_H |
| 10863 |
# include <stdlib.h> |
| 10864 |
#endif |
| 10865 |
|
| 10866 |
#ifdef HAVE_NCURSES_H |
| 10867 |
# define NCURSES_OPAQUE 0 |
| 10868 |
# include <ncurses.h> |
| 10869 |
#else |
| 10870 |
# include <curses.h> |
| 10871 |
#endif |
| 10872 |
|
| 10873 |
|
| 10874 |
int main(void) { |
| 10875 |
|
| 10876 |
/* function-body */ |
| 10877 |
WINDOW *junk = 0; |
| 10878 |
int mx = 0, my = 0; |
| 10879 |
|
| 10880 |
getyx(junk, my, mx); |
| 10881 |
exit(0); |
| 10882 |
|
| 10883 |
; return 0; } |
| 10884 |
EOF |
| 10885 |
if { (eval echo configure:10886: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10886 |
rm -rf conftest* |
| 10887 |
|
| 10888 |
cat >> confdefs.h <<\EOF |
| 10889 |
#define HAVE_GETYX 1 |
| 10890 |
EOF |
| 10891 |
|
| 10892 |
echo "$ac_t""yes" 1>&6 |
| 10893 |
|
| 10894 |
else |
| 10895 |
echo "configure: failed program was:" >&5 |
| 10896 |
cat conftest.$ac_ext >&5 |
| 10897 |
rm -rf conftest* |
| 10898 |
|
| 10899 |
echo "$ac_t""no" 1>&6 |
| 10900 |
|
| 10901 |
fi |
| 10902 |
rm -rf conftest* |
| 10903 |
|
| 10904 |
# getmaxx |
| 10905 |
echo $ac_n "checking for getmaxx() functionality in curses library""... $ac_c" 1>&6 |
| 10906 |
echo "configure:10907: checking for getmaxx() functionality in curses library" >&5 |
| 10907 |
cat > conftest.$ac_ext <<EOF |
| 10908 |
#line 10909 "configure" |
| 10909 |
#include "confdefs.h" |
| 10910 |
|
| 10911 |
/* includes */ |
| 10912 |
#ifdef HAVE_UNISTD_H |
| 10913 |
# include <unistd.h> |
| 10914 |
#endif |
| 10915 |
#include <sys/types.h> |
| 10916 |
#include <stdio.h> |
| 10917 |
#include <string.h> |
| 10918 |
#ifdef HAVE_STDLIB_H |
| 10919 |
# include <stdlib.h> |
| 10920 |
#endif |
| 10921 |
|
| 10922 |
#ifdef HAVE_NCURSES_H |
| 10923 |
# define NCURSES_OPAQUE 0 |
| 10924 |
# include <ncurses.h> |
| 10925 |
#else |
| 10926 |
# include <curses.h> |
| 10927 |
#endif |
| 10928 |
|
| 10929 |
int main(void) { |
| 10930 |
|
| 10931 |
/* function-body */ |
| 10932 |
WINDOW *junk = 0; |
| 10933 |
int mx = 0; |
| 10934 |
|
| 10935 |
mx = getmaxx(junk); |
| 10936 |
exit(0); |
| 10937 |
|
| 10938 |
; return 0; } |
| 10939 |
EOF |
| 10940 |
if { (eval echo configure:10941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10941 |
rm -rf conftest* |
| 10942 |
|
| 10943 |
cat >> confdefs.h <<\EOF |
| 10944 |
#define HAVE_GETMAXX 1 |
| 10945 |
EOF |
| 10946 |
|
| 10947 |
echo "$ac_t""yes" 1>&6 |
| 10948 |
|
| 10949 |
else |
| 10950 |
echo "configure: failed program was:" >&5 |
| 10951 |
cat conftest.$ac_ext >&5 |
| 10952 |
rm -rf conftest* |
| 10953 |
|
| 10954 |
echo "$ac_t""no" 1>&6 |
| 10955 |
|
| 10956 |
fi |
| 10957 |
rm -rf conftest* |
| 10958 |
|
| 10959 |
# getmaxyx |
| 10960 |
echo $ac_n "checking for getmaxyx() functionality in curses library""... $ac_c" 1>&6 |
| 10961 |
echo "configure:10962: checking for getmaxyx() functionality in curses library" >&5 |
| 10962 |
cat > conftest.$ac_ext <<EOF |
| 10963 |
#line 10964 "configure" |
| 10964 |
#include "confdefs.h" |
| 10965 |
|
| 10966 |
/* includes */ |
| 10967 |
#ifdef HAVE_UNISTD_H |
| 10968 |
# include <unistd.h> |
| 10969 |
#endif |
| 10970 |
#include <sys/types.h> |
| 10971 |
#include <stdio.h> |
| 10972 |
#include <string.h> |
| 10973 |
#ifdef HAVE_STDLIB_H |
| 10974 |
# include <stdlib.h> |
| 10975 |
#endif |
| 10976 |
|
| 10977 |
#ifdef HAVE_NCURSES_H |
| 10978 |
# define NCURSES_OPAQUE 0 |
| 10979 |
# include <ncurses.h> |
| 10980 |
#else |
| 10981 |
# include <curses.h> |
| 10982 |
#endif |
| 10983 |
|
| 10984 |
int main(void) { |
| 10985 |
|
| 10986 |
/* function-body */ |
| 10987 |
WINDOW *junk = 0; |
| 10988 |
int mx = 0, my = 0; |
| 10989 |
|
| 10990 |
getmaxyx(junk, my, mx); |
| 10991 |
exit(my < 0 ? my : 0); |
| 10992 |
|
| 10993 |
; return 0; } |
| 10994 |
EOF |
| 10995 |
if { (eval echo configure:10996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 10996 |
rm -rf conftest* |
| 10997 |
|
| 10998 |
cat >> confdefs.h <<\EOF |
| 10999 |
#define HAVE_GETMAXYX 1 |
| 11000 |
EOF |
| 11001 |
|
| 11002 |
echo "$ac_t""yes" 1>&6 |
| 11003 |
|
| 11004 |
else |
| 11005 |
echo "configure: failed program was:" >&5 |
| 11006 |
cat conftest.$ac_ext >&5 |
| 11007 |
rm -rf conftest* |
| 11008 |
|
| 11009 |
echo "$ac_t""no" 1>&6 |
| 11010 |
|
| 11011 |
fi |
| 11012 |
rm -rf conftest* |
| 11013 |
|
| 11014 |
# getbegx |
| 11015 |
echo $ac_n "checking for getbegx() functionality in curses library""... $ac_c" 1>&6 |
| 11016 |
echo "configure:11017: checking for getbegx() functionality in curses library" >&5 |
| 11017 |
cat > conftest.$ac_ext <<EOF |
| 11018 |
#line 11019 "configure" |
| 11019 |
#include "confdefs.h" |
| 11020 |
|
| 11021 |
/* includes */ |
| 11022 |
#ifdef HAVE_UNISTD_H |
| 11023 |
# include <unistd.h> |
| 11024 |
#endif |
| 11025 |
#include <sys/types.h> |
| 11026 |
#include <stdio.h> |
| 11027 |
#include <string.h> |
| 11028 |
#ifdef HAVE_STDLIB_H |
| 11029 |
# include <stdlib.h> |
| 11030 |
#endif |
| 11031 |
|
| 11032 |
#ifdef HAVE_NCURSES_H |
| 11033 |
# define NCURSES_OPAQUE 0 |
| 11034 |
# include <ncurses.h> |
| 11035 |
#else |
| 11036 |
# include <curses.h> |
| 11037 |
#endif |
| 11038 |
|
| 11039 |
|
| 11040 |
int main(void) { |
| 11041 |
|
| 11042 |
/* function-body */ |
| 11043 |
WINDOW *junk = 0; |
| 11044 |
int mx = 0; |
| 11045 |
|
| 11046 |
mx = getbegx(junk); |
| 11047 |
exit(0); |
| 11048 |
|
| 11049 |
; return 0; } |
| 11050 |
EOF |
| 11051 |
if { (eval echo configure:11052: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 11052 |
rm -rf conftest* |
| 11053 |
|
| 11054 |
cat >> confdefs.h <<\EOF |
| 11055 |
#define HAVE_GETBEGX 1 |
| 11056 |
EOF |
| 11057 |
|
| 11058 |
echo "$ac_t""yes" 1>&6 |
| 11059 |
|
| 11060 |
else |
| 11061 |
echo "configure: failed program was:" >&5 |
| 11062 |
cat conftest.$ac_ext >&5 |
| 11063 |
rm -rf conftest* |
| 11064 |
|
| 11065 |
echo "$ac_t""no" 1>&6 |
| 11066 |
|
| 11067 |
fi |
| 11068 |
rm -rf conftest* |
| 11069 |
|
| 11070 |
# getbegyx |
| 11071 |
echo $ac_n "checking for getbegyx() functionality in curses library""... $ac_c" 1>&6 |
| 11072 |
echo "configure:11073: checking for getbegyx() functionality in curses library" >&5 |
| 11073 |
cat > conftest.$ac_ext <<EOF |
| 11074 |
#line 11075 "configure" |
| 11075 |
#include "confdefs.h" |
| 11076 |
|
| 11077 |
/* includes */ |
| 11078 |
#ifdef HAVE_UNISTD_H |
| 11079 |
# include <unistd.h> |
| 11080 |
#endif |
| 11081 |
#include <sys/types.h> |
| 11082 |
#include <stdio.h> |
| 11083 |
#include <string.h> |
| 11084 |
#ifdef HAVE_STDLIB_H |
| 11085 |
# include <stdlib.h> |
| 11086 |
#endif |
| 11087 |
|
| 11088 |
#ifdef HAVE_NCURSES_H |
| 11089 |
# define NCURSES_OPAQUE 0 |
| 11090 |
# include <ncurses.h> |
| 11091 |
#else |
| 11092 |
# include <curses.h> |
| 11093 |
#endif |
| 11094 |
|
| 11095 |
int main(void) { |
| 11096 |
|
| 11097 |
/* function-body */ |
| 11098 |
WINDOW *junk = 0; |
| 11099 |
int mx = 0, my = 0; |
| 11100 |
|
| 11101 |
getbegyx(junk, my, mx); |
| 11102 |
exit(my < 0 ? my : 0); |
| 11103 |
|
| 11104 |
; return 0; } |
| 11105 |
EOF |
| 11106 |
if { (eval echo configure:11107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 11107 |
rm -rf conftest* |
| 11108 |
|
| 11109 |
cat >> confdefs.h <<\EOF |
| 11110 |
#define HAVE_GETBEGYX 1 |
| 11111 |
EOF |
| 11112 |
|
| 11113 |
echo "$ac_t""yes" 1>&6 |
| 11114 |
|
| 11115 |
else |
| 11116 |
echo "configure: failed program was:" >&5 |
| 11117 |
cat conftest.$ac_ext >&5 |
| 11118 |
rm -rf conftest* |
| 11119 |
|
| 11120 |
echo "$ac_t""no" 1>&6 |
| 11121 |
|
| 11122 |
fi |
| 11123 |
rm -rf conftest* |
| 11124 |
|
| 11125 |
# touchwin |
| 11126 |
echo $ac_n "checking for touchwin() functionality in curses library""... $ac_c" 1>&6 |
| 11127 |
echo "configure:11128: checking for touchwin() functionality in curses library" >&5 |
| 11128 |
cat > conftest.$ac_ext <<EOF |
| 11129 |
#line 11130 "configure" |
| 11130 |
#include "confdefs.h" |
| 11131 |
|
| 11132 |
/* includes */ |
| 11133 |
#ifdef HAVE_UNISTD_H |
| 11134 |
# include <unistd.h> |
| 11135 |
#endif |
| 11136 |
#include <sys/types.h> |
| 11137 |
#include <stdio.h> |
| 11138 |
#include <string.h> |
| 11139 |
#ifdef HAVE_STDLIB_H |
| 11140 |
# include <stdlib.h> |
| 11141 |
#endif |
| 11142 |
|
| 11143 |
#ifdef HAVE_NCURSES_H |
| 11144 |
# define NCURSES_OPAQUE 0 |
| 11145 |
# include <ncurses.h> |
| 11146 |
#else |
| 11147 |
# include <curses.h> |
| 11148 |
#endif |
| 11149 |
|
| 11150 |
int main(void) { |
| 11151 |
|
| 11152 |
/* function-body */ |
| 11153 |
WINDOW *junk = 0; |
| 11154 |
touchwin(junk); |
| 11155 |
exit(0); |
| 11156 |
|
| 11157 |
; return 0; } |
| 11158 |
EOF |
| 11159 |
if { (eval echo configure:11160: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 11160 |
rm -rf conftest* |
| 11161 |
|
| 11162 |
cat >> confdefs.h <<\EOF |
| 11163 |
#define HAVE_TOUCHWIN 1 |
| 11164 |
EOF |
| 11165 |
|
| 11166 |
echo "$ac_t""yes" 1>&6 |
| 11167 |
|
| 11168 |
else |
| 11169 |
echo "configure: failed program was:" >&5 |
| 11170 |
cat conftest.$ac_ext >&5 |
| 11171 |
rm -rf conftest* |
| 11172 |
|
| 11173 |
echo "$ac_t""no" 1>&6 |
| 11174 |
|
| 11175 |
fi |
| 11176 |
rm -rf conftest* |
| 11177 |
|
| 11178 |
# beep |
| 11179 |
echo $ac_n "checking for beep() functionality in curses library""... $ac_c" 1>&6 |
| 11180 |
echo "configure:11181: checking for beep() functionality in curses library" >&5 |
| 11181 |
cat > conftest.$ac_ext <<EOF |
| 11182 |
#line 11183 "configure" |
| 11183 |
#include "confdefs.h" |
| 11184 |
|
| 11185 |
/* includes */ |
| 11186 |
#ifdef HAVE_UNISTD_H |
| 11187 |
# include <unistd.h> |
| 11188 |
#endif |
| 11189 |
#include <sys/types.h> |
| 11190 |
#include <stdio.h> |
| 11191 |
#include <string.h> |
| 11192 |
#ifdef HAVE_STDLIB_H |
| 11193 |
# include <stdlib.h> |
| 11194 |
#endif |
| 11195 |
|
| 11196 |
#ifdef HAVE_NCURSES_H |
| 11197 |
# define NCURSES_OPAQUE 0 |
| 11198 |
# include <ncurses.h> |
| 11199 |
#else |
| 11200 |
# include <curses.h> |
| 11201 |
#endif |
| 11202 |
|
| 11203 |
int main(void) { |
| 11204 |
|
| 11205 |
/* function-body */ |
| 11206 |
beep(); |
| 11207 |
exit(getpid() & 1); |
| 11208 |
|
| 11209 |
; return 0; } |
| 11210 |
EOF |
| 11211 |
if { (eval echo configure:11212: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 11212 |
rm -rf conftest* |
| 11213 |
|
| 11214 |
cat >> confdefs.h <<\EOF |
| 11215 |
#define HAVE_BEEP 1 |
| 11216 |
EOF |
| 11217 |
|
| 11218 |
echo "$ac_t""yes" 1>&6 |
| 11219 |
|
| 11220 |
else |
| 11221 |
echo "configure: failed program was:" >&5 |
| 11222 |
cat conftest.$ac_ext >&5 |
| 11223 |
rm -rf conftest* |
| 11224 |
|
| 11225 |
echo "$ac_t""no" 1>&6 |
| 11226 |
|
| 11227 |
fi |
| 11228 |
rm -rf conftest* |
| 11229 |
|
| 11230 |
for ac_func in keypad nodelay curs_set doupdate wnoutrefresh |
| 11231 |
do |
| 11232 |
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
| 11233 |
echo "configure:11234: checking for $ac_func" >&5 |
| 11234 |
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 11235 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11236 |
else |
| 11237 |
cat > conftest.$ac_ext <<EOF |
| 11238 |
#line 11239 "configure" |
| 11239 |
#include "confdefs.h" |
| 11240 |
/* System header to define __stub macros and hopefully few prototypes, |
| 11241 |
which can conflict with char $ac_func(); below. */ |
| 11242 |
#include <assert.h> |
| 11243 |
/* Override any gcc2 internal prototype to avoid an error. */ |
| 11244 |
/* We use char because int might match the return type of a gcc2 |
| 11245 |
builtin and then its argument prototype would still apply. */ |
| 11246 |
char $ac_func(); |
| 11247 |
|
| 11248 |
int main(void) { |
| 11249 |
|
| 11250 |
/* The GNU C library defines this for functions which it implements |
| 11251 |
to always fail with ENOSYS. Some functions are actually named |
| 11252 |
something starting with __ and the normal name is an alias. */ |
| 11253 |
#if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 11254 |
choke me |
| 11255 |
#else |
| 11256 |
$ac_func(); |
| 11257 |
#endif |
| 11258 |
|
| 11259 |
; return 0; } |
| 11260 |
EOF |
| 11261 |
if { (eval echo configure:11262: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
| 11262 |
rm -rf conftest* |
| 11263 |
eval "ac_cv_func_$ac_func=yes" |
| 11264 |
else |
| 11265 |
echo "configure: failed program was:" >&5 |
| 11266 |
cat conftest.$ac_ext >&5 |
| 11267 |
rm -rf conftest* |
| 11268 |
eval "ac_cv_func_$ac_func=no" |
| 11269 |
fi |
| 11270 |
rm -rf conftest* |
| 11271 |
fi |
| 11272 |
|
| 11273 |
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 11274 |
echo "$ac_t""yes" 1>&6 |
| 11275 |
ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 11276 |
cat >> confdefs.h <<EOF |
| 11277 |
#define $ac_tr_func 1 |
| 11278 |
EOF |
| 11279 |
|
| 11280 |
else |
| 11281 |
echo "$ac_t""no" 1>&6 |
| 11282 |
fi |
| 11283 |
done |
| 11284 |
|
| 11285 |
|
| 11286 |
LIBS="$ac_save_LIBS"; |
| 11287 |
fi |
| 11288 |
|
| 11289 |
if test "x$LIBCURSES" = "x" ; then |
| 11290 |
VIS_DPROGS="# ../bin/ncftpbookmarks${EXEEXT}" |
| 11291 |
else |
| 11292 |
VIS_DPROGS="../bin/ncftpbookmarks${EXEEXT}" |
| 11293 |
fi |
| 11294 |
|
| 11295 |
|
| 11296 |
|
| 11297 |
echo $ac_n "checking for long file names""... $ac_c" 1>&6 |
| 11298 |
echo "configure:11299: checking for long file names" >&5 |
| 11299 |
if eval "test \"`echo '$''{'ac_cv_sys_long_file_names'+set}'`\" = set"; then |
| 11300 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11301 |
else |
| 11302 |
ac_cv_sys_long_file_names=yes |
| 11303 |
# Test for long file names in all the places we know might matter: |
| 11304 |
# . the current directory, where building will happen |
| 11305 |
# $prefix/lib where we will be installing things |
| 11306 |
# $exec_prefix/lib likewise |
| 11307 |
# eval it to expand exec_prefix. |
| 11308 |
# $TMPDIR if set, where it might want to write temporary files |
| 11309 |
# if $TMPDIR is not set: |
| 11310 |
# /tmp where it might want to write temporary files |
| 11311 |
# /var/tmp likewise |
| 11312 |
# /usr/tmp likewise |
| 11313 |
if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then |
| 11314 |
ac_tmpdirs="$TMPDIR" |
| 11315 |
else |
| 11316 |
ac_tmpdirs='/tmp /var/tmp /usr/tmp' |
| 11317 |
fi |
| 11318 |
for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do |
| 11319 |
test -d $ac_dir || continue |
| 11320 |
test -w $ac_dir || continue # It is less confusing to not echo anything here. |
| 11321 |
(echo 1 > $ac_dir/conftest9012345) 2>/dev/null |
| 11322 |
(echo 2 > $ac_dir/conftest9012346) 2>/dev/null |
| 11323 |
val=`cat $ac_dir/conftest9012345 2>/dev/null` |
| 11324 |
if test ! -f $ac_dir/conftest9012345 || test "$val" != 1; then |
| 11325 |
ac_cv_sys_long_file_names=no |
| 11326 |
rm -f $ac_dir/conftest9012345 $ac_dir/conftest9012346 2>/dev/null |
| 11327 |
break |
| 11328 |
fi |
| 11329 |
rm -f $ac_dir/conftest9012345 $ac_dir/conftest9012346 2>/dev/null |
| 11330 |
done |
| 11331 |
fi |
| 11332 |
|
| 11333 |
echo "$ac_t""$ac_cv_sys_long_file_names" 1>&6 |
| 11334 |
if test $ac_cv_sys_long_file_names = yes; then |
| 11335 |
cat >> confdefs.h <<\EOF |
| 11336 |
#define HAVE_LONG_FILE_NAMES 1 |
| 11337 |
EOF |
| 11338 |
|
| 11339 |
fi |
| 11340 |
|
| 11341 |
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 |
| 11342 |
echo "configure:11343: checking whether ${MAKE-make} sets \${MAKE}" >&5 |
| 11343 |
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` |
| 11344 |
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then |
| 11345 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11346 |
else |
| 11347 |
cat > conftestmake <<\EOF |
| 11348 |
all: |
| 11349 |
@echo 'ac_maketemp="${MAKE}"' |
| 11350 |
EOF |
| 11351 |
# GNU make sometimes prints "make[1]: Entering...", which would confuse us. |
| 11352 |
eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` |
| 11353 |
if test -n "$ac_maketemp"; then |
| 11354 |
eval ac_cv_prog_make_${ac_make}_set=yes |
| 11355 |
else |
| 11356 |
eval ac_cv_prog_make_${ac_make}_set=no |
| 11357 |
fi |
| 11358 |
rm -f conftestmake |
| 11359 |
fi |
| 11360 |
if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then |
| 11361 |
echo "$ac_t""yes" 1>&6 |
| 11362 |
SET_MAKE= |
| 11363 |
else |
| 11364 |
echo "$ac_t""no" 1>&6 |
| 11365 |
SET_MAKE="MAKE=${MAKE-make}" |
| 11366 |
fi |
| 11367 |
|
| 11368 |
|
| 11369 |
# Extract the first word of ""gtar"", so it can be a program name with args. |
| 11370 |
set dummy "gtar"; ac_word=$2 |
| 11371 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 11372 |
echo "configure:11373: checking for $ac_word" >&5 |
| 11373 |
if eval "test \"`echo '$''{'ac_cv_path_TAR'+set}'`\" = set"; then |
| 11374 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11375 |
else |
| 11376 |
case "$TAR" in |
| 11377 |
/*) |
| 11378 |
ac_cv_path_TAR="$TAR" # Let the user override the test with a path. |
| 11379 |
;; |
| 11380 |
?:/*) |
| 11381 |
ac_cv_path_TAR="$TAR" # Let the user override the test with a dos path. |
| 11382 |
;; |
| 11383 |
*) |
| 11384 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 11385 |
ac_dummy="$PATH" |
| 11386 |
for ac_dir in $ac_dummy; do |
| 11387 |
test -z "$ac_dir" && ac_dir=. |
| 11388 |
if test -f $ac_dir/$ac_word; then |
| 11389 |
ac_cv_path_TAR="$ac_dir/$ac_word" |
| 11390 |
break |
| 11391 |
fi |
| 11392 |
done |
| 11393 |
IFS="$ac_save_ifs" |
| 11394 |
test -z "$ac_cv_path_TAR" && ac_cv_path_TAR="""" |
| 11395 |
;; |
| 11396 |
esac |
| 11397 |
fi |
| 11398 |
TAR="$ac_cv_path_TAR" |
| 11399 |
if test -n "$TAR"; then |
| 11400 |
echo "$ac_t""$TAR" 1>&6 |
| 11401 |
else |
| 11402 |
echo "$ac_t""no" 1>&6 |
| 11403 |
fi |
| 11404 |
|
| 11405 |
if test "x$TAR" = "x" ; then |
| 11406 |
unset TAR |
| 11407 |
unset ac_cv_path_TAR |
| 11408 |
# Extract the first word of ""tar"", so it can be a program name with args. |
| 11409 |
set dummy "tar"; ac_word=$2 |
| 11410 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 11411 |
echo "configure:11412: checking for $ac_word" >&5 |
| 11412 |
if eval "test \"`echo '$''{'ac_cv_path_TAR'+set}'`\" = set"; then |
| 11413 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11414 |
else |
| 11415 |
case "$TAR" in |
| 11416 |
/*) |
| 11417 |
ac_cv_path_TAR="$TAR" # Let the user override the test with a path. |
| 11418 |
;; |
| 11419 |
?:/*) |
| 11420 |
ac_cv_path_TAR="$TAR" # Let the user override the test with a dos path. |
| 11421 |
;; |
| 11422 |
*) |
| 11423 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 11424 |
ac_dummy="$PATH" |
| 11425 |
for ac_dir in $ac_dummy; do |
| 11426 |
test -z "$ac_dir" && ac_dir=. |
| 11427 |
if test -f $ac_dir/$ac_word; then |
| 11428 |
ac_cv_path_TAR="$ac_dir/$ac_word" |
| 11429 |
break |
| 11430 |
fi |
| 11431 |
done |
| 11432 |
IFS="$ac_save_ifs" |
| 11433 |
test -z "$ac_cv_path_TAR" && ac_cv_path_TAR="""" |
| 11434 |
;; |
| 11435 |
esac |
| 11436 |
fi |
| 11437 |
TAR="$ac_cv_path_TAR" |
| 11438 |
if test -n "$TAR"; then |
| 11439 |
echo "$ac_t""$TAR" 1>&6 |
| 11440 |
else |
| 11441 |
echo "$ac_t""no" 1>&6 |
| 11442 |
fi |
| 11443 |
|
| 11444 |
fi |
| 11445 |
|
| 11446 |
|
| 11447 |
|
| 11448 |
if test "x$TAR" != "x" ; then |
| 11449 |
cat >> confdefs.h <<EOF |
| 11450 |
#define TAR "$TAR" |
| 11451 |
EOF |
| 11452 |
|
| 11453 |
fi |
| 11454 |
|
| 11455 |
|
| 11456 |
|
| 11457 |
|
| 11458 |
echo $ac_n "checking how to create TAR files""... $ac_c" 1>&6 |
| 11459 |
echo "configure:11460: checking how to create TAR files" >&5 |
| 11460 |
x="" |
| 11461 |
if [ -x /usr/bin/what ] ; then |
| 11462 |
x=`/usr/bin/what "$TAR" 2>&1 | sed -n 's/.*pax.*/pax/g;/pax/p'` |
| 11463 |
elif [ -x /bin/what ] ; then |
| 11464 |
x=`/bin/what "$TAR" 2>&1 | sed -n 's/.*pax.*/pax/g;/pax/p'` |
| 11465 |
fi |
| 11466 |
if [ "x$x" != "xpax" ] ; then |
| 11467 |
# The junk above is because Mac OS X Server's tar freaks out |
| 11468 |
# and does not exit if you do "tar --help". |
| 11469 |
# |
| 11470 |
x=`"$TAR" --help 2>&1 | sed -n 's/.*owner=NAME.*/owner=NAME/g;/owner=NAME/p'` |
| 11471 |
fi |
| 11472 |
TARFLAGS="cvf" |
| 11473 |
case "$x" in |
| 11474 |
*owner=NAME*) |
| 11475 |
case "$OS" in |
| 11476 |
cygwin*) |
| 11477 |
;; |
| 11478 |
macosx*) |
| 11479 |
TARFLAGS="-c --owner=root --group=wheel --verbose -f" |
| 11480 |
;; |
| 11481 |
*) |
| 11482 |
if grep '^root:' /etc/group >/dev/null 2>&1 ; then |
| 11483 |
TARFLAGS="-c --owner=root --group=root --verbose -f" |
| 11484 |
elif grep '^wheel:' /etc/group >/dev/null 2>&1 ; then |
| 11485 |
TARFLAGS="-c --owner=root --group=wheel --verbose -f" |
| 11486 |
fi |
| 11487 |
;; |
| 11488 |
esac |
| 11489 |
;; |
| 11490 |
esac |
| 11491 |
|
| 11492 |
echo "$ac_t""$TAR $TARFLAGS" 1>&6 |
| 11493 |
|
| 11494 |
|
| 11495 |
if test "x$cross_compiling" = "xyes" ; then |
| 11496 |
# Help out if the cross ranlib isn't in your path, |
| 11497 |
# for example, maybe you set CC=/path/to/cross-gcc |
| 11498 |
# rather than put PATH=/path/to/crosstools:$PATH |
| 11499 |
# and let cc be found in your PATH. |
| 11500 |
# |
| 11501 |
machine=`${CC-gcc} -dumpmachine 2>/dev/null` |
| 11502 |
case "$CC" in |
| 11503 |
*${machine}*) |
| 11504 |
f=`echo "$CC" | sed 's|/[^/]*$||'` |
| 11505 |
if [ -x "$f/${machine}-ranlib" ] ; then |
| 11506 |
RANLIB="$f/${machine}-ranlib" |
| 11507 |
elif [ -x "$f/ranlib" ] ; then |
| 11508 |
RANLIB="$f/ranlib" |
| 11509 |
fi |
| 11510 |
;; |
| 11511 |
esac |
| 11512 |
unset machine f |
| 11513 |
fi |
| 11514 |
# Extract the first word of "ranlib", so it can be a program name with args. |
| 11515 |
set dummy ranlib; ac_word=$2 |
| 11516 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 11517 |
echo "configure:11518: checking for $ac_word" >&5 |
| 11518 |
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
| 11519 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11520 |
else |
| 11521 |
if test -n "$RANLIB"; then |
| 11522 |
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 11523 |
else |
| 11524 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 11525 |
ac_dummy="$PATH" |
| 11526 |
for ac_dir in $ac_dummy; do |
| 11527 |
test -z "$ac_dir" && ac_dir=. |
| 11528 |
if test -f $ac_dir/$ac_word; then |
| 11529 |
ac_cv_prog_RANLIB="ranlib" |
| 11530 |
break |
| 11531 |
fi |
| 11532 |
done |
| 11533 |
IFS="$ac_save_ifs" |
| 11534 |
test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" |
| 11535 |
fi |
| 11536 |
fi |
| 11537 |
RANLIB="$ac_cv_prog_RANLIB" |
| 11538 |
if test -n "$RANLIB"; then |
| 11539 |
echo "$ac_t""$RANLIB" 1>&6 |
| 11540 |
else |
| 11541 |
echo "$ac_t""no" 1>&6 |
| 11542 |
fi |
| 11543 |
|
| 11544 |
|
| 11545 |
|
| 11546 |
echo $ac_n "checking for ar""... $ac_c" 1>&6 |
| 11547 |
echo "configure:11548: checking for ar" >&5 |
| 11548 |
AR="ar" |
| 11549 |
if [ "x$cross_compiling" = "xyes" ] ; then |
| 11550 |
machine=`${CC-gcc} -dumpmachine 2>/dev/null` |
| 11551 |
case "$CC" in |
| 11552 |
*${machine}*) |
| 11553 |
f=`echo "$CC" | sed 's|/[^/]*$||'` |
| 11554 |
if [ -x "$f/${machine}-ar" ] ; then |
| 11555 |
AR="$f/${machine}-ar" |
| 11556 |
elif [ -x "$f/ar" ] ; then |
| 11557 |
AR="$f/ar" |
| 11558 |
fi |
| 11559 |
;; |
| 11560 |
esac |
| 11561 |
unset machine f |
| 11562 |
fi |
| 11563 |
echo "$ac_t""$AR" 1>&6 |
| 11564 |
|
| 11565 |
|
| 11566 |
# Find a good install program. We prefer a C program (faster), |
| 11567 |
# so one script is as good as another. But avoid the broken or |
| 11568 |
# incompatible versions: |
| 11569 |
# SysV /etc/install, /usr/sbin/install |
| 11570 |
# SunOS /usr/etc/install |
| 11571 |
# IRIX /sbin/install |
| 11572 |
# AIX /bin/install |
| 11573 |
# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 11574 |
# AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 11575 |
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 11576 |
# ./install, which can be erroneously created by make from ./install.sh. |
| 11577 |
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 |
| 11578 |
echo "configure:11579: checking for a BSD compatible install" >&5 |
| 11579 |
if test -z "$INSTALL"; then |
| 11580 |
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then |
| 11581 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11582 |
else |
| 11583 |
IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" |
| 11584 |
for ac_dir in $PATH; do |
| 11585 |
# Account for people who put trailing slashes in PATH elements. |
| 11586 |
case "$ac_dir/" in |
| 11587 |
/|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; |
| 11588 |
*) |
| 11589 |
# OSF1 and SCO ODT 3.0 have their own names for install. |
| 11590 |
# Don't use installbsd from OSF since it installs stuff as root |
| 11591 |
# by default. |
| 11592 |
for ac_prog in ginstall scoinst install; do |
| 11593 |
if test -f $ac_dir/$ac_prog; then |
| 11594 |
if test $ac_prog = install && |
| 11595 |
grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then |
| 11596 |
# AIX install. It has an incompatible calling convention. |
| 11597 |
: |
| 11598 |
else |
| 11599 |
ac_cv_path_install="$ac_dir/$ac_prog -c" |
| 11600 |
break 2 |
| 11601 |
fi |
| 11602 |
fi |
| 11603 |
done |
| 11604 |
;; |
| 11605 |
esac |
| 11606 |
done |
| 11607 |
IFS="$ac_save_IFS" |
| 11608 |
|
| 11609 |
fi |
| 11610 |
if test "${ac_cv_path_install+set}" = set; then |
| 11611 |
INSTALL="$ac_cv_path_install" |
| 11612 |
else |
| 11613 |
# As a last resort, use the slow shell script. We don't cache a |
| 11614 |
# path for INSTALL within a source directory, because that will |
| 11615 |
# break other packages using the cache if that directory is |
| 11616 |
# removed, or if the path is relative. |
| 11617 |
INSTALL="$ac_install_sh" |
| 11618 |
fi |
| 11619 |
fi |
| 11620 |
echo "$ac_t""$INSTALL" 1>&6 |
| 11621 |
|
| 11622 |
# Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 11623 |
# It thinks the first close brace ends the variable substitution. |
| 11624 |
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 11625 |
|
| 11626 |
test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' |
| 11627 |
|
| 11628 |
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 11629 |
|
| 11630 |
|
| 11631 |
# Extract the first word of ""pwd"", so it can be a program name with args. |
| 11632 |
set dummy "pwd"; ac_word=$2 |
| 11633 |
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
| 11634 |
echo "configure:11635: checking for $ac_word" >&5 |
| 11635 |
if eval "test \"`echo '$''{'ac_cv_path_wi_PWD'+set}'`\" = set"; then |
| 11636 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11637 |
else |
| 11638 |
case "$wi_PWD" in |
| 11639 |
/*) |
| 11640 |
ac_cv_path_wi_PWD="$wi_PWD" # Let the user override the test with a path. |
| 11641 |
;; |
| 11642 |
?:/*) |
| 11643 |
ac_cv_path_wi_PWD="$wi_PWD" # Let the user override the test with a dos path. |
| 11644 |
;; |
| 11645 |
*) |
| 11646 |
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 11647 |
ac_dummy="$PATH" |
| 11648 |
for ac_dir in $ac_dummy; do |
| 11649 |
test -z "$ac_dir" && ac_dir=. |
| 11650 |
if test -f $ac_dir/$ac_word; then |
| 11651 |
ac_cv_path_wi_PWD="$ac_dir/$ac_word" |
| 11652 |
break |
| 11653 |
fi |
| 11654 |
done |
| 11655 |
IFS="$ac_save_ifs" |
| 11656 |
test -z "$ac_cv_path_wi_PWD" && ac_cv_path_wi_PWD=""pwd"" |
| 11657 |
;; |
| 11658 |
esac |
| 11659 |
fi |
| 11660 |
wi_PWD="$ac_cv_path_wi_PWD" |
| 11661 |
if test -n "$wi_PWD"; then |
| 11662 |
echo "$ac_t""$wi_PWD" 1>&6 |
| 11663 |
else |
| 11664 |
echo "$ac_t""no" 1>&6 |
| 11665 |
fi |
| 11666 |
|
| 11667 |
|
| 11668 |
|
| 11669 |
if test "x$use_ccdv" = "xno" ; then |
| 11670 |
echo $ac_n "checking for ccdv""... $ac_c" 1>&6 |
| 11671 |
echo "configure:11672: checking for ccdv" >&5 |
| 11672 |
echo "$ac_t""(disabled)" 1>&6 |
| 11673 |
else |
| 11674 |
unset wi_cv_path_ccdv # can't use cache if it was a temp prog last time |
| 11675 |
wi_used_cache_path_ccdv="yes" |
| 11676 |
echo $ac_n "checking for ccdv""... $ac_c" 1>&6 |
| 11677 |
echo "configure:11678: checking for ccdv" >&5 |
| 11678 |
if eval "test \"`echo '$''{'wi_cv_path_ccdv'+set}'`\" = set"; then |
| 11679 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 11680 |
else |
| 11681 |
|
| 11682 |
wi_used_cache_path_ccdv="no" |
| 11683 |
for CCDV in /usr/bin/ccdv /usr/local/bin/ccdv /usr/ccs/bin/ccdv NONE |
| 11684 |
do |
| 11685 |
if test "$CCDV" = NONE ; then CCDV="" ; break ; fi |
| 11686 |
$CCDV >/dev/null 2>&1 |
| 11687 |
if test $? -eq 96 ; then |
| 11688 |
break |
| 11689 |
fi |
| 11690 |
done |
| 11691 |
if test "x$CCDV" = "x" ; then |
| 11692 |
cat > ccdv.c << 'EOF' |
| 11693 |
/* ccdv.c |
| 11694 |
* |
| 11695 |
* Copyright (C) 2002-2003, by Mike Gleason, NcFTP Software. |
| 11696 |
* All Rights Reserved. |
| 11697 |
* |
| 11698 |
* Licensed under the GNU Public License. |
| 11699 |
*/ |
| 11700 |
#include <unistd.h> |
| 11701 |
#include <sys/types.h> |
| 11702 |
#include <sys/time.h> |
| 11703 |
#include <sys/wait.h> |
| 11704 |
#include <fcntl.h> |
| 11705 |
#include <stdio.h> |
| 11706 |
#include <string.h> |
| 11707 |
#include <stdlib.h> |
| 11708 |
#include <errno.h> |
| 11709 |
|
| 11710 |
#define SETCOLOR_SUCCESS (gANSIEscapes ? "\033\1331;32m" : "") |
| 11711 |
#define SETCOLOR_FAILURE (gANSIEscapes ? "\033\1331;31m" : "") |
| 11712 |
#define SETCOLOR_WARNING (gANSIEscapes ? "\033\1331;33m" : "") |
| 11713 |
#define SETCOLOR_NORMAL (gANSIEscapes ? "\033\1330;39m" : "") |
| 11714 |
|
| 11715 |
#define TEXT_BLOCK_SIZE 8192 |
| 11716 |
#define INDENT 2 |
| 11717 |
|
| 11718 |
#define TERMS "vt100:vt102:vt220:vt320:xterm:xterm-color:xterm-256color:ansi:linux:scoterm:scoansi:dtterm:cons25:cygwin:screen" |
| 11719 |
|
| 11720 |
size_t gNBufUsed = 0, gNBufAllocated = 0; |
| 11721 |
char *gBuf = NULL; |
| 11722 |
int gCCPID; |
| 11723 |
char gAction[64] = ""; |
| 11724 |
char gTarget[64] = ""; |
| 11725 |
char gAr[32] = ""; |
| 11726 |
char gArLibraryTarget[64] = ""; |
| 11727 |
int gDumpCmdArgs = 0; |
| 11728 |
char gArgsStr[800]; |
| 11729 |
int gColumns = 80; |
| 11730 |
int gANSIEscapes = 0; |
| 11731 |
int gExitStatus = 95; |
| 11732 |
|
| 11733 |
static void |
| 11734 |
DumpFormattedOutput(void) |
| 11735 |
{ |
| 11736 |
char *cp; |
| 11737 |
char spaces[8 + 1] = " "; |
| 11738 |
char *saved; |
| 11739 |
int curcol; |
| 11740 |
int i; |
| 11741 |
|
| 11742 |
curcol = 0; |
| 11743 |
saved = NULL; |
| 11744 |
for (cp = gBuf + ((gDumpCmdArgs == 0) ? strlen(gArgsStr) : 0); ; cp++) { |
| 11745 |
if (*cp == '\0') { |
| 11746 |
if (saved != NULL) { |
| 11747 |
cp = saved; |
| 11748 |
saved = NULL; |
| 11749 |
} else break; |
| 11750 |
} |
| 11751 |
if (*cp == '\r') |
| 11752 |
continue; |
| 11753 |
if (*cp == '\t') { |
| 11754 |
saved = cp + 1; |
| 11755 |
cp = spaces + 8 - (8 - ((curcol - INDENT - 1) % 8)); |
| 11756 |
} |
| 11757 |
if (curcol == 0) { |
| 11758 |
for (i = INDENT; --i >= 0; ) |
| 11759 |
putchar(' '); |
| 11760 |
curcol = INDENT; |
| 11761 |
} |
| 11762 |
putchar(*cp); |
| 11763 |
if (++curcol == (gColumns - 1)) { |
| 11764 |
putchar('\n'); |
| 11765 |
curcol = 0; |
| 11766 |
} else if (*cp == '\n') |
| 11767 |
curcol = 0; |
| 11768 |
} |
| 11769 |
free(gBuf); |
| 11770 |
} /* DumpFormattedOutput */ |
| 11771 |
|
| 11772 |
|
| 11773 |
|
| 11774 |
/* Difftime(), only for timeval structures. */ |
| 11775 |
static void TimeValSubtract(struct timeval *tdiff, struct timeval *t1, struct timeval *t0) |
| 11776 |
{ |
| 11777 |
tdiff->tv_sec = t1->tv_sec - t0->tv_sec; |
| 11778 |
tdiff->tv_usec = t1->tv_usec - t0->tv_usec; |
| 11779 |
if (tdiff->tv_usec < 0) { |
| 11780 |
tdiff->tv_sec--; |
| 11781 |
tdiff->tv_usec += 1000000; |
| 11782 |
} |
| 11783 |
} /* TimeValSubtract */ |
| 11784 |
|
| 11785 |
|
| 11786 |
|
| 11787 |
static void |
| 11788 |
Wait(void) |
| 11789 |
{ |
| 11790 |
int pid2, status; |
| 11791 |
|
| 11792 |
do { |
| 11793 |
status = 0; |
| 11794 |
pid2 = (int) waitpid(gCCPID, &status, 0); |
| 11795 |
} while (((pid2 >= 0) && (! WIFEXITED(status))) || ((pid2 < 0) && (errno == EINTR))); |
| 11796 |
if (WIFEXITED(status)) |
| 11797 |
gExitStatus = WEXITSTATUS(status); |
| 11798 |
} /* Wait */ |
| 11799 |
|
| 11800 |
|
| 11801 |
|
| 11802 |
static int |
| 11803 |
SlurpProgress(int fd) |
| 11804 |
{ |
| 11805 |
char s1[71]; |
| 11806 |
char *newbuf; |
| 11807 |
int nready; |
| 11808 |
size_t ntoread; |
| 11809 |
ssize_t nread; |
| 11810 |
struct timeval now, tnext, tleft; |
| 11811 |
fd_set ss; |
| 11812 |
fd_set ss2; |
| 11813 |
const char *trail = "/-\\|", *trailcp; |
| 11814 |
|
| 11815 |
trailcp = trail; |
| 11816 |
snprintf(s1, sizeof(s1), "%s%s%s... ", gAction, gTarget[0] ? " " : "", gTarget); |
| 11817 |
printf("\r%-70s%-9s", s1, ""); |
| 11818 |
fflush(stdout); |
| 11819 |
|
| 11820 |
gettimeofday(&now, NULL); |
| 11821 |
tnext = now; |
| 11822 |
tnext.tv_sec++; |
| 11823 |
tleft.tv_sec = 1; |
| 11824 |
tleft.tv_usec = 0; |
| 11825 |
FD_ZERO(&ss2); |
| 11826 |
FD_SET(fd, &ss2); |
| 11827 |
for(;;) { |
| 11828 |
if (gNBufUsed == (gNBufAllocated - 1)) { |
| 11829 |
if ((newbuf = (char *) realloc(gBuf, gNBufAllocated + TEXT_BLOCK_SIZE)) == NULL) { |
| 11830 |
perror("ccdv: realloc"); |
| 11831 |
return (-1); |
| 11832 |
} |
| 11833 |
gNBufAllocated += TEXT_BLOCK_SIZE; |
| 11834 |
gBuf = newbuf; |
| 11835 |
} |
| 11836 |
for (;;) { |
| 11837 |
ss = ss2; |
| 11838 |
nready = select(fd + 1, &ss, NULL, NULL, &tleft); |
| 11839 |
if (nready == 1) |
| 11840 |
break; |
| 11841 |
if (nready < 0) { |
| 11842 |
if (errno != EINTR) { |
| 11843 |
perror("ccdv: select"); |
| 11844 |
return (-1); |
| 11845 |
} |
| 11846 |
continue; |
| 11847 |
} |
| 11848 |
gettimeofday(&now, NULL); |
| 11849 |
if ((now.tv_sec > tnext.tv_sec) || ((now.tv_sec == tnext.tv_sec) && (now.tv_usec >= tnext.tv_usec))) { |
| 11850 |
tnext = now; |
| 11851 |
tnext.tv_sec++; |
| 11852 |
tleft.tv_sec = 1; |
| 11853 |
tleft.tv_usec = 0; |
| 11854 |
printf("\r%-71s%c%-7s", s1, *trailcp, ""); |
| 11855 |
fflush(stdout); |
| 11856 |
if (*++trailcp == '\0') |
| 11857 |
trailcp = trail; |
| 11858 |
} else { |
| 11859 |
TimeValSubtract(&tleft, &tnext, &now); |
| 11860 |
} |
| 11861 |
} |
| 11862 |
ntoread = (gNBufAllocated - gNBufUsed - 1); |
| 11863 |
nread = read(fd, gBuf + gNBufUsed, ntoread); |
| 11864 |
if (nread < 0) { |
| 11865 |
if (errno == EINTR) |
| 11866 |
continue; |
| 11867 |
perror("ccdv: read"); |
| 11868 |
return (-1); |
| 11869 |
} else if (nread == 0) { |
| 11870 |
break; |
| 11871 |
} |
| 11872 |
gNBufUsed += nread; |
| 11873 |
gBuf[gNBufUsed] = '\0'; |
| 11874 |
} |
| 11875 |
snprintf(s1, sizeof(s1), "%s%s%s: ", gAction, gTarget[0] ? " " : "", gTarget); |
| 11876 |
Wait(); |
| 11877 |
if (gExitStatus == 0) { |
| 11878 |
printf("\r%-70s", s1); |
| 11879 |
printf("[%s%s%s]", ((gNBufUsed - strlen(gArgsStr)) < 4) ? SETCOLOR_SUCCESS : SETCOLOR_WARNING, "OK", SETCOLOR_NORMAL); |
| 11880 |
printf("%-5s\n", " "); |
| 11881 |
} else { |
| 11882 |
printf("\r%-70s", s1); |
| 11883 |
printf("[%s%s%s]", SETCOLOR_FAILURE, "ERROR", SETCOLOR_NORMAL); |
| 11884 |
printf("%-2s\n", " "); |
| 11885 |
gDumpCmdArgs = 1; /* print cmd when there are errors */ |
| 11886 |
} |
| 11887 |
fflush(stdout); |
| 11888 |
return (0); |
| 11889 |
} /* SlurpProgress */ |
| 11890 |
|
| 11891 |
|
| 11892 |
|
| 11893 |
static int |
| 11894 |
SlurpAll(int fd) |
| 11895 |
{ |
| 11896 |
char *newbuf; |
| 11897 |
size_t ntoread; |
| 11898 |
ssize_t nread; |
| 11899 |
|
| 11900 |
printf("%s%s%s.\n", gAction, gTarget[0] ? " " : "", gTarget); |
| 11901 |
fflush(stdout); |
| 11902 |
|
| 11903 |
for(;;) { |
| 11904 |
if (gNBufUsed == (gNBufAllocated - 1)) { |
| 11905 |
if ((newbuf = (char *) realloc(gBuf, gNBufAllocated + TEXT_BLOCK_SIZE)) == NULL) { |
| 11906 |
perror("ccdv: realloc"); |
| 11907 |
return (-1); |
| 11908 |
} |
| 11909 |
gNBufAllocated += TEXT_BLOCK_SIZE; |
| 11910 |
gBuf = newbuf; |
| 11911 |
} |
| 11912 |
ntoread = (gNBufAllocated - gNBufUsed - 1); |
| 11913 |
nread = read(fd, gBuf + gNBufUsed, ntoread); |
| 11914 |
if (nread < 0) { |
| 11915 |
if (errno == EINTR) |
| 11916 |
continue; |
| 11917 |
perror("ccdv: read"); |
| 11918 |
return (-1); |
| 11919 |
} else if (nread == 0) { |
| 11920 |
break; |
| 11921 |
} |
| 11922 |
gNBufUsed += nread; |
| 11923 |
gBuf[gNBufUsed] = '\0'; |
| 11924 |
} |
| 11925 |
Wait(); |
| 11926 |
gDumpCmdArgs = (gExitStatus != 0); /* print cmd when there are errors */ |
| 11927 |
return (0); |
| 11928 |
} /* SlurpAll */ |
| 11929 |
|
| 11930 |
|
| 11931 |
|
| 11932 |
static const char * |
| 11933 |
Basename(const char *path) |
| 11934 |
{ |
| 11935 |
const char *cp; |
| 11936 |
cp = strrchr(path, '/'); |
| 11937 |
if (cp == NULL) |
| 11938 |
return (path); |
| 11939 |
return (cp + 1); |
| 11940 |
} /* Basename */ |
| 11941 |
|
| 11942 |
|
| 11943 |
|
| 11944 |
static const char * |
| 11945 |
Extension(const char *path) |
| 11946 |
{ |
| 11947 |
const char *cp = path; |
| 11948 |
cp = strrchr(path, '.'); |
| 11949 |
if (cp == NULL) |
| 11950 |
return (""); |
| 11951 |
return (cp); |
| 11952 |
} /* Extension */ |
| 11953 |
|
| 11954 |
|
| 11955 |
|
| 11956 |
static void |
| 11957 |
Usage(void) |
| 11958 |
{ |
| 11959 |
fprintf(stderr, "Usage: ccdv /path/to/cc CFLAGS...\n\n"); |
| 11960 |
fprintf(stderr, "I wrote this to reduce the deluge Make output to make finding actual problems\n"); |
| 11961 |
fprintf(stderr, "easier. It is intended to be invoked from Makefiles, like this. Instead of:\n\n"); |
| 11962 |
fprintf(stderr, "\t.c.o:\n"); |
| 11963 |
fprintf(stderr, "\t\t$(CC) $(CFLAGS) $(DEFS) $(CPPFLAGS) $< -c\n"); |
| 11964 |
fprintf(stderr, "\nRewrite your rule so it looks like:\n\n"); |
| 11965 |
fprintf(stderr, "\t.c.o:\n"); |
| 11966 |
fprintf(stderr, "\t\t@ccdv $(CC) $(CFLAGS) $(DEFS) $(CPPFLAGS) $< -c\n\n"); |
| 11967 |
fprintf(stderr, "ccdv 1.1.0 is Free under the GNU Public License. Enjoy!\n"); |
| 11968 |
fprintf(stderr, " -- Mike Gleason, NcFTP Software <http://www.ncftp.com>\n"); |
| 11969 |
exit(96); |
| 11970 |
} /* Usage */ |
| 11971 |
|
| 11972 |
|
| 11973 |
|
| 11974 |
int |
| 11975 |
main(int argc, char **argv) |
| 11976 |
{ |
| 11977 |
int pipe1[2]; |
| 11978 |
int devnull; |
| 11979 |
char emerg[256]; |
| 11980 |
int fd; |
| 11981 |
int nread; |
| 11982 |
int i; |
| 11983 |
int cc = 0, pch = 0; |
| 11984 |
const char *quote; |
| 11985 |
|
| 11986 |
if (argc < 2) |
| 11987 |
Usage(); |
| 11988 |
|
| 11989 |
snprintf(gAction, sizeof(gAction), "Running %s", Basename(argv[1])); |
| 11990 |
memset(gArgsStr, 0, sizeof(gArgsStr)); |
| 11991 |
for (i = 1; i < argc; i++) { |
| 11992 |
quote = (strchr(argv[i], ' ') != NULL) ? "\"" : ""; |
| 11993 |
snprintf(gArgsStr + strlen(gArgsStr), sizeof(gArgsStr) - strlen(gArgsStr), "%s%s%s%s%s", (i == 1) ? "" : " ", quote, argv[i], quote, (i == (argc - 1)) ? "\n" : ""); |
| 11994 |
if ((strcmp(argv[i], "-o") == 0) && ((i + 1) < argc)) { |
| 11995 |
if (strcasecmp(Extension(argv[i + 1]), ".o") != 0) { |
| 11996 |
strcpy(gAction, "Linking"); |
| 11997 |
snprintf(gTarget, sizeof(gTarget), "%s", Basename(argv[i + 1])); |
| 11998 |
} |
| 11999 |
} else if (strchr("-+/", (int) argv[i][0]) != NULL) { |
| 12000 |
continue; |
| 12001 |
} else if (strncasecmp(Extension(argv[i]), ".c", 2) == 0) { |
| 12002 |
cc++; |
| 12003 |
snprintf(gTarget, sizeof(gTarget), "%s", Basename(argv[i])); |
| 12004 |
} else if ((strncasecmp(Extension(argv[i]), ".h", 2) == 0) && (cc == 0)) { |
| 12005 |
pch++; |
| 12006 |
snprintf(gTarget, sizeof(gTarget), "%s", Basename(argv[i])); |
| 12007 |
} else if ((i == 1) && (strcmp(Basename(argv[i]), "ar") == 0)) { |
| 12008 |
snprintf(gAr, sizeof(gAr), "%s", Basename(argv[i])); |
| 12009 |
} else if ((gArLibraryTarget[0] == '\0') && (strcasecmp(Extension(argv[i]), ".a") == 0)) { |
| 12010 |
snprintf(gArLibraryTarget, sizeof(gArLibraryTarget), "%s", Basename(argv[i])); |
| 12011 |
} |
| 12012 |
} |
| 12013 |
if ((gAr[0] != '\0') && (gArLibraryTarget[0] != '\0')) { |
| 12014 |
strcpy(gAction, "Creating library"); |
| 12015 |
snprintf(gTarget, sizeof(gTarget), "%s", gArLibraryTarget); |
| 12016 |
} else if (pch > 0) { |
| 12017 |
strcpy(gAction, "Precompiling"); |
| 12018 |
} else if (cc > 0) { |
| 12019 |
strcpy(gAction, "Compiling"); |
| 12020 |
} |
| 12021 |
|
| 12022 |
if (pipe(pipe1) < 0) { |
| 12023 |
perror("ccdv: pipe"); |
| 12024 |
exit(97); |
| 12025 |
} |
| 12026 |
|
| 12027 |
(void) close(0); |
| 12028 |
devnull = open("/dev/null", O_RDWR, 00666); |
| 12029 |
if ((devnull != 0) && (dup2(devnull, 0) == 0)) |
| 12030 |
close(devnull); |
| 12031 |
|
| 12032 |
gCCPID = (int) fork(); |
| 12033 |
if (gCCPID < 0) { |
| 12034 |
(void) close(pipe1[0]); |
| 12035 |
(void) close(pipe1[1]); |
| 12036 |
perror("ccdv: fork"); |
| 12037 |
exit(98); |
| 12038 |
} else if (gCCPID == 0) { |
| 12039 |
/* Child */ |
| 12040 |
(void) close(pipe1[0]); /* close read end */ |
| 12041 |
if (pipe1[1] != 1) { /* use write end on stdout */ |
| 12042 |
(void) dup2(pipe1[1], 1); |
| 12043 |
(void) close(pipe1[1]); |
| 12044 |
} |
| 12045 |
(void) dup2(1, 2); /* use write end on stderr */ |
| 12046 |
execvp(argv[1], argv + 1); |
| 12047 |
perror(argv[1]); |
| 12048 |
exit(99); |
| 12049 |
} |
| 12050 |
|
| 12051 |
/* parent */ |
| 12052 |
(void) close(pipe1[1]); /* close write end */ |
| 12053 |
fd = pipe1[0]; /* use read end */ |
| 12054 |
|
| 12055 |
gColumns = (getenv("COLUMNS") != NULL) ? atoi(getenv("COLUMNS")) : 80; |
| 12056 |
gANSIEscapes = (getenv("TERM") != NULL) && (strstr(TERMS, getenv("TERM")) != NULL); |
| 12057 |
gBuf = (char *) malloc(TEXT_BLOCK_SIZE); |
| 12058 |
if (gBuf == NULL) |
| 12059 |
goto panic; |
| 12060 |
gNBufUsed = 0; |
| 12061 |
gNBufAllocated = TEXT_BLOCK_SIZE; |
| 12062 |
if (strlen(gArgsStr) < (gNBufAllocated - 1)) { |
| 12063 |
strcpy(gBuf, gArgsStr); |
| 12064 |
gNBufUsed = strlen(gArgsStr); |
| 12065 |
} |
| 12066 |
|
| 12067 |
if (isatty(1)) { |
| 12068 |
if (SlurpProgress(fd) < 0) |
| 12069 |
goto panic; |
| 12070 |
} else { |
| 12071 |
if (SlurpAll(fd) < 0) |
| 12072 |
goto panic; |
| 12073 |
} |
| 12074 |
DumpFormattedOutput(); |
| 12075 |
exit(gExitStatus); |
| 12076 |
|
| 12077 |
panic: |
| 12078 |
gDumpCmdArgs = 1; /* print cmd when there are errors */ |
| 12079 |
DumpFormattedOutput(); |
| 12080 |
while ((nread = read(fd, emerg, (size_t) sizeof(emerg))) > 0) |
| 12081 |
(void) write(2, emerg, (size_t) nread); |
| 12082 |
Wait(); |
| 12083 |
exit(gExitStatus); |
| 12084 |
} /* main */ |
| 12085 |
/* eof ccdv.c */ |
| 12086 |
EOF |
| 12087 |
${CC-cc} $DEFS $CPPFLAGS $CFLAGS "ccdv.c" -o "ccdv" >/dev/null 2>&1 |
| 12088 |
rm -f ccdv.c ccdv.o ccdv.c.gz.uu ccdv.c.gz |
| 12089 |
strip ./ccdv >/dev/null 2>&1 |
| 12090 |
./ccdv >/dev/null 2>&1 |
| 12091 |
if test $? -eq 96 ; then |
| 12092 |
CCDV="./ccdv" |
| 12093 |
else |
| 12094 |
rm -f ccdv |
| 12095 |
fi |
| 12096 |
fi |
| 12097 |
if test "x$CCDV" != x ; then |
| 12098 |
|
| 12099 |
|
| 12100 |
wi_path="$CCDV" |
| 12101 |
if test -d "$wi_path" ; then |
| 12102 |
wi_resolved_path=`cd "$wi_path" ; $wi_PWD 2>/dev/null` |
| 12103 |
elif test ! -f "$wi_path" ; then |
| 12104 |
wi_resolved_path="$wi_path" |
| 12105 |
else |
| 12106 |
wi_parent_dir="$wi_path" |
| 12107 |
wi_file_name="$wi_path" |
| 12108 |
|
| 12109 |
wi_parent_dir=`echo "$wi_parent_dir" | sed -n ' |
| 12110 |
s-//*-/-g |
| 12111 |
s-/*$-- |
| 12112 |
/^\/\/*[^/]*$/{ |
| 12113 |
c\\ |
| 12114 |
/ |
| 12115 |
p |
| 12116 |
q |
| 12117 |
} |
| 12118 |
/^[^/]*$/{ |
| 12119 |
c\\ |
| 12120 |
. |
| 12121 |
p |
| 12122 |
q |
| 12123 |
} |
| 12124 |
/./{ |
| 12125 |
s-/[^/]*$-- |
| 12126 |
p |
| 12127 |
q |
| 12128 |
}'` |
| 12129 |
|
| 12130 |
wi_file_name=`echo "$wi_file_name" | sed -n ' |
| 12131 |
s-//*-/-g |
| 12132 |
s-/*$-- |
| 12133 |
s-^/$-- |
| 12134 |
s-^.*/-- |
| 12135 |
p |
| 12136 |
q'` |
| 12137 |
wi_resolved_path=`cd "$wi_parent_dir" ; $wi_PWD 2>/dev/null` |
| 12138 |
if test "x$wi_resolved_path" != x ; then |
| 12139 |
wi_resolved_path="$wi_resolved_path/$wi_file_name" |
| 12140 |
fi |
| 12141 |
unset wi_parent_dir wi_file_name |
| 12142 |
fi |
| 12143 |
if test "x$wi_resolved_path" = x ; then |
| 12144 |
CCDV="$$CCDV" |
| 12145 |
else |
| 12146 |
CCDV="$wi_resolved_path" |
| 12147 |
fi |
| 12148 |
unset wi_resolved_path wi_path |
| 12149 |
|
| 12150 |
wi_cv_path_ccdv="$CCDV" |
| 12151 |
CCDV="@$CCDV " # trailing space needed |
| 12152 |
else |
| 12153 |
wi_cv_path_ccdv="" |
| 12154 |
fi |
| 12155 |
|
| 12156 |
fi |
| 12157 |
|
| 12158 |
echo "$ac_t""$wi_cv_path_ccdv" 1>&6 |
| 12159 |
if test "$wi_used_cache_path_ccdv" = yes ; then |
| 12160 |
CCDV="$wi_cv_path_ccdv" |
| 12161 |
if test "x$CCDV" != x ; then |
| 12162 |
CCDV="@$CCDV " # trailing space needed |
| 12163 |
fi |
| 12164 |
fi |
| 12165 |
|
| 12166 |
fi |
| 12167 |
|
| 12168 |
|
| 12169 |
if test "x$mandir" = 'x${prefix}/man' ; then |
| 12170 |
# Mandir is at default value -- try to see |
| 12171 |
# if $prefix/share/man would be better. |
| 12172 |
# |
| 12173 |
|
| 12174 |
# $prefix is probably set to NONE. |
| 12175 |
# |
| 12176 |
p=`cd / ; cd $prefix 2>/dev/null ; pwd` |
| 12177 |
if test "x$p" = "x/" ; then |
| 12178 |
p="/usr/local" |
| 12179 |
fi |
| 12180 |
if test -d "$p/share/man" ; then |
| 12181 |
mandir="$p/share/man" |
| 12182 |
fi |
| 12183 |
fi |
| 12184 |
|
| 12185 |
|
| 12186 |
echo $ac_n "checking if shell can test for symlinks""... $ac_c" 1>&6 |
| 12187 |
echo "configure:12188: checking if shell can test for symlinks" >&5 |
| 12188 |
if eval "test \"`echo '$''{'wi_cv_shell_test_symlinks'+set}'`\" = set"; then |
| 12189 |
echo $ac_n "(cached) $ac_c" 1>&6 |
| 12190 |
else |
| 12191 |
|
| 12192 |
wi_cv_shell_test_symlinks="no" |
| 12193 |
wi_cv_test_L="false" |
| 12194 |
wi_cv_test_not_L=":" |
| 12195 |
rm -f config.lnk |
| 12196 |
if test ! -f "config.lnk" ; then |
| 12197 |
ln -s /bin/sh${ac_exeext} config.lnk |
| 12198 |
if test -f "config.lnk" ; then |
| 12199 |
( if test -L config.lnk ; then rm -f config.lnk ; fi ) 2>/dev/null |
| 12200 |
if test ! -f "config.lnk" ; then |
| 12201 |
wi_cv_shell_test_symlinks="yes" |
| 12202 |
wi_cv_test_L='test -L' |
| 12203 |
wi_cv_test_not_L='test ! -L' |
| 12204 |
else |
| 12205 |
( if test -h config.lnk ; then rm -f config.lnk ; fi ) 2>/dev/null |
| 12206 |
if test ! -f "config.lnk" ; then |
| 12207 |
wi_cv_shell_test_symlinks="yes" |
| 12208 |
wi_cv_test_L='test -h' |
| 12209 |
wi_cv_test_not_L='test ! -h' |
| 12210 |
fi |
| 12211 |
fi |
| 12212 |
fi |
| 12213 |
rm -f config.lnk |
| 12214 |
fi |
| 12215 |
|
| 12216 |
fi |
| 12217 |
|
| 12218 |
echo "$ac_t""$wi_cv_shell_test_symlinks" 1>&6 |
| 12219 |
test_L="$wi_cv_test_L" |
| 12220 |
test_not_L="$wi_cv_test_not_L" |
| 12221 |
|
| 12222 |
|
| 12223 |
|
| 12224 |
h_file="libncftp/ncftp.h" |
| 12225 |
if test -f "$h_file" && $test_not_L "$h_file" ; then |
| 12226 |
h_tmp=`echo "$h_file" | sed 's/\.h/.tmp/;'` |
| 12227 |
longest_int_subst="${LONGEST_INT-long}" |
| 12228 |
if sed 's!\ */\*\ set\ by\ configure\ at\ .*\*/!!' "$h_file" > "$h_tmp" ; then |
| 12229 |
touch -r "$h_file" "$h_tmp" |
| 12230 |
if cmp -s "$h_file" "$h_tmp" ; then |
| 12231 |
: |
| 12232 |
else |
| 12233 |
/bin/mv "$h_tmp" "$h_file" |
| 12234 |
chmod a+r "$h_file" |
| 12235 |
fi |
| 12236 |
fi |
| 12237 |
if sed 's/^#define longest_int.*/#define longest_int '"$longest_int_subst"'/;s/^#define longest_uint.*/#define longest_uint unsigned '"$longest_int_subst"'/;' "$h_file" > "$h_tmp" ; then |
| 12238 |
if cmp -s "$h_file" "$h_tmp" ; then |
| 12239 |
datestr=`date '+%Y-%m-%d %H:%M:%S'` |
| 12240 |
sed '/^#define longest_u?int/{s!$! /* set by configure at '"${datestr}"' */!;}' "$h_tmp" > "$h_file" |
| 12241 |
unset datestr |
| 12242 |
/bin/rm -f "$h_tmp" |
| 12243 |
chmod a+r "$h_file" |
| 12244 |
fi |
| 12245 |
fi |
| 12246 |
/bin/rm -f "$h_tmp" |
| 12247 |
unset h_tmp longest_int_subst |
| 12248 |
fi |
| 12249 |
unset h_file |
| 12250 |
|
| 12251 |
|
| 12252 |
|
| 12253 |
h_file="libncftp/ncftp.h" |
| 12254 |
if test -f "$h_file" && $test_not_L "$h_file" ; then |
| 12255 |
h_tmp=`echo "$h_file" | sed 's/\.h/.tmp/;'` |
| 12256 |
if sed 's!\ */\*\ set\ by\ configure\ at\ .*\*/!!' "$h_file" > "$h_tmp" ; then |
| 12257 |
touch -r "$h_file" "$h_tmp" |
| 12258 |
if cmp -s "$h_file" "$h_tmp" ; then |
| 12259 |
: |
| 12260 |
else |
| 12261 |
/bin/mv "$h_tmp" "$h_file" |
| 12262 |
chmod a+r "$h_file" |
| 12263 |
fi |
| 12264 |
fi |
| 12265 |
if test "x$wi_cv_struct_stat64" = xyes ; then |
| 12266 |
if sed 's/^#define Stat .*/#define Stat stat64/;s/^#define Lstat .*/#define Lstat lstat64/;s/^#define Fstat .*/#define Fstat fstat64/;' "$h_file" > "$h_tmp" ; then |
| 12267 |
if cmp -s "$h_file" "$h_tmp" ; then |
| 12268 |
: |
| 12269 |
else |
| 12270 |
datestr=`date '+%Y-%m-%d %H:%M:%S'` |
| 12271 |
sed '/^#define [SLFs]*tat /{s!$! /* set by configure at '"${datestr}"' */!;}' "$h_tmp" > "$h_file" |
| 12272 |
unset datestr |
| 12273 |
/bin/rm -f "$h_tmp" |
| 12274 |
chmod a+r "$h_file" |
| 12275 |
fi |
| 12276 |
fi |
| 12277 |
else |
| 12278 |
if sed 's/^#define Stat .*/#define Stat stat/;s/^#define Lstat .*/#define Lstat lstat/;s/^#define Fstat .*/#define Fstat fstat/;' "$h_file" > "$h_tmp" ; then |
| 12279 |
if cmp -s "$h_file" "$h_tmp" ; then |
| 12280 |
: |
| 12281 |
else |
| 12282 |
datestr=`date '+%Y-%m-%d %H:%M:%S'` |
| 12283 |
sed '/^#define [SLFs]*tat /{s!$! /* set by configure at '"${datestr}"' */!;}' "$h_tmp" > "$h_file" |
| 12284 |
unset datestr |
| 12285 |
/bin/rm -f "$h_tmp" |
| 12286 |
chmod a+r "$h_file" |
| 12287 |
fi |
| 12288 |
fi |
| 12289 |
fi |
| 12290 |
/bin/rm -f "$h_tmp" |
| 12291 |
unset h_tmp longest_int_subst |
| 12292 |
fi |
| 12293 |
unset h_file |
| 12294 |
|
| 12295 |
|
| 12296 |
|
| 12297 |
h_file="libncftp/ncftp.h" |
| 12298 |
if test -f "$h_file" && $test_not_L "$h_file" ; then |
| 12299 |
h_tmp=`echo "$h_file" | sed 's/\.h/.tmp/;'` |
| 12300 |
|
| 12301 |
remove_cpp_warning=yes |
| 12302 |
if [ "$SYS" = linux ] ; then |
| 12303 |
# |
| 12304 |
# We need to retain #warning on Linux |
| 12305 |
# |
| 12306 |
remove_cpp_warning=no |
| 12307 |
fi |
| 12308 |
if [ "$GCC" = yes ] ; then |
| 12309 |
# |
| 12310 |
# GCC accepts #warning |
| 12311 |
# |
| 12312 |
remove_cpp_warning=no |
| 12313 |
fi |
| 12314 |
|
| 12315 |
if [ "$remove_cpp_warning" = yes ] ; then |
| 12316 |
# |
| 12317 |
# Remove "#warning", since compiler will complain about it |
| 12318 |
# not being recognized. |
| 12319 |
# |
| 12320 |
sed 's/^\([\ \ ]*#[\ \ ]*warning.*\)/\/* \1 *\//;' "$h_file" > "$h_tmp" |
| 12321 |
cmp -s "$h_file" "$h_tmp" |
| 12322 |
if test $? -ne 0 ; then |
| 12323 |
mv "$h_tmp" "$h_file" |
| 12324 |
chmod a+r "$h_file" |
| 12325 |
fi |
| 12326 |
rm -f "$h_tmp" |
| 12327 |
unset h_tmp longest_int_subst |
| 12328 |
fi |
| 12329 |
fi |
| 12330 |
unset h_file remove_cpp_warning |
| 12331 |
|
| 12332 |
LIBSET='$(LIB)' |
| 12333 |
Z30='#' |
| 12334 |
case "$HOME" in |
| 12335 |
*lcompile*) |
| 12336 |
;; |
| 12337 |
*) |
| 12338 |
if test -x /usr/local/bin/incrementor ; then |
| 12339 |
Z30=' -@/usr/local/bin/incrementor -b -f version.c -f version.o' |
| 12340 |
fi |
| 12341 |
;; |
| 12342 |
esac |
| 12343 |
|
| 12344 |
|
| 12345 |
wi_path="$srcdir" |
| 12346 |
if test -d "$wi_path" ; then |
| 12347 |
wi_resolved_path=`cd "$wi_path" ; $wi_PWD 2>/dev/null` |
| 12348 |
elif test ! -f "$wi_path" ; then |
| 12349 |
wi_resolved_path="$wi_path" |
| 12350 |
else |
| 12351 |
wi_parent_dir="$wi_path" |
| 12352 |
wi_file_name="$wi_path" |
| 12353 |
|
| 12354 |
wi_parent_dir=`echo "$wi_parent_dir" | sed -n ' |
| 12355 |
s-//*-/-g |
| 12356 |
s-/*$-- |
| 12357 |
/^\/\/*[^/]*$/{ |
| 12358 |
c\\ |
| 12359 |
/ |
| 12360 |
p |
| 12361 |
q |
| 12362 |
} |
| 12363 |
/^[^/]*$/{ |
| 12364 |
c\\ |
| 12365 |
. |
| 12366 |
p |
| 12367 |
q |
| 12368 |
} |
| 12369 |
/./{ |
| 12370 |
s-/[^/]*$-- |
| 12371 |
p |
| 12372 |
q |
| 12373 |
}'` |
| 12374 |
|
| 12375 |
wi_file_name=`echo "$wi_file_name" | sed -n ' |
| 12376 |
s-//*-/-g |
| 12377 |
s-/*$-- |
| 12378 |
s-^/$-- |
| 12379 |
s-^.*/-- |
| 12380 |
p |
| 12381 |
q'` |
| 12382 |
wi_resolved_path=`cd "$wi_parent_dir" ; $wi_PWD 2>/dev/null` |
| 12383 |
if test "x$wi_resolved_path" != x ; then |
| 12384 |
wi_resolved_path="$wi_resolved_path/$wi_file_name" |
| 12385 |
fi |
| 12386 |
unset wi_parent_dir wi_file_name |
| 12387 |
fi |
| 12388 |
if test "x$wi_resolved_path" = x ; then |
| 12389 |
MAINDIR="$$srcdir" |
| 12390 |
else |
| 12391 |
MAINDIR="$wi_resolved_path" |
| 12392 |
fi |
| 12393 |
unset wi_resolved_path wi_path |
| 12394 |
|
| 12395 |
|
| 12396 |
|
| 12397 |
wi_path="$MAINDIR/libncftp/ncftp.h" |
| 12398 |
if test -d "$wi_path" ; then |
| 12399 |
wi_resolved_path=`cd "$wi_path" ; $wi_PWD 2>/dev/null` |
| 12400 |
elif test ! -f "$wi_path" ; then |
| 12401 |
wi_resolved_path="$wi_path" |
| 12402 |
else |
| 12403 |
wi_parent_dir="$wi_path" |
| 12404 |
wi_file_name="$wi_path" |
| 12405 |
|
| 12406 |
wi_parent_dir=`echo "$wi_parent_dir" | sed -n ' |
| 12407 |
s-//*-/-g |
| 12408 |
s-/*$-- |
| 12409 |
/^\/\/*[^/]*$/{ |
| 12410 |
c\\ |
| 12411 |
/ |
| 12412 |
p |
| 12413 |
q |
| 12414 |
} |
| 12415 |
/^[^/]*$/{ |
| 12416 |
c\\ |
| 12417 |
. |
| 12418 |
p |
| 12419 |
q |
| 12420 |
} |
| 12421 |
/./{ |
| 12422 |
s-/[^/]*$-- |
| 12423 |
p |
| 12424 |
q |
| 12425 |
}'` |
| 12426 |
|
| 12427 |
wi_file_name=`echo "$wi_file_name" | sed -n ' |
| 12428 |
s-//*-/-g |
| 12429 |
s-/*$-- |
| 12430 |
s-^/$-- |
| 12431 |
s-^.*/-- |
| 12432 |
p |
| 12433 |
q'` |
| 12434 |
wi_resolved_path=`cd "$wi_parent_dir" ; $wi_PWD 2>/dev/null` |
| 12435 |
if test "x$wi_resolved_path" != x ; then |
| 12436 |
wi_resolved_path="$wi_resolved_path/$wi_file_name" |
| 12437 |
fi |
| 12438 |
unset wi_parent_dir wi_file_name |
| 12439 |
fi |
| 12440 |
if test "x$wi_resolved_path" = x ; then |
| 12441 |
libncftp_h="$$MAINDIR/libncftp/ncftp.h" |
| 12442 |
else |
| 12443 |
libncftp_h="$wi_resolved_path" |
| 12444 |
fi |
| 12445 |
unset wi_resolved_path wi_path |
| 12446 |
|
| 12447 |
|
| 12448 |
libncftp_h=`echo "$libncftp_h" | sed -n ' |
| 12449 |
s-//*-/-g |
| 12450 |
s-/*$-- |
| 12451 |
/^\/\/*[^/]*$/{ |
| 12452 |
c\\ |
| 12453 |
/ |
| 12454 |
p |
| 12455 |
q |
| 12456 |
} |
| 12457 |
/^[^/]*$/{ |
| 12458 |
c\\ |
| 12459 |
. |
| 12460 |
p |
| 12461 |
q |
| 12462 |
} |
| 12463 |
/./{ |
| 12464 |
s-/[^/]*$-- |
| 12465 |
p |
| 12466 |
q |
| 12467 |
}'` |
| 12468 |
|
| 12469 |
|
| 12470 |
wi_path="$MAINDIR/sio/sio.h" |
| 12471 |
if test -d "$wi_path" ; then |
| 12472 |
wi_resolved_path=`cd "$wi_path" ; $wi_PWD 2>/dev/null` |
| 12473 |
elif test ! -f "$wi_path" ; then |
| 12474 |
wi_resolved_path="$wi_path" |
| 12475 |
else |
| 12476 |
wi_parent_dir="$wi_path" |
| 12477 |
wi_file_name="$wi_path" |
| 12478 |
|
| 12479 |
wi_parent_dir=`echo "$wi_parent_dir" | sed -n ' |
| 12480 |
s-//*-/-g |
| 12481 |
s-/*$-- |
| 12482 |
/^\/\/*[^/]*$/{ |
| 12483 |
c\\ |
| 12484 |
/ |
| 12485 |
p |
| 12486 |
q |
| 12487 |
} |
| 12488 |
/^[^/]*$/{ |
| 12489 |
c\\ |
| 12490 |
. |
| 12491 |
p |
| 12492 |
q |
| 12493 |
} |
| 12494 |
/./{ |
| 12495 |
s-/[^/]*$-- |
| 12496 |
p |
| 12497 |
q |
| 12498 |
}'` |
| 12499 |
|
| 12500 |
wi_file_name=`echo "$wi_file_name" | sed -n ' |
| 12501 |
s-//*-/-g |
| 12502 |
s-/*$-- |
| 12503 |
s-^/$-- |
| 12504 |
s-^.*/-- |
| 12505 |
p |
| 12506 |
q'` |
| 12507 |
wi_resolved_path=`cd "$wi_parent_dir" ; $wi_PWD 2>/dev/null` |
| 12508 |
if test "x$wi_resolved_path" != x ; then |
| 12509 |
wi_resolved_path="$wi_resolved_path/$wi_file_name" |
| 12510 |
fi |
| 12511 |
unset wi_parent_dir wi_file_name |
| 12512 |
fi |
| 12513 |
if test "x$wi_resolved_path" = x ; then |
| 12514 |
sio_h="$$MAINDIR/sio/sio.h" |
| 12515 |
else |
| 12516 |
sio_h="$wi_resolved_path" |
| 12517 |
fi |
| 12518 |
unset wi_resolved_path wi_path |
| 12519 |
|
| 12520 |
|
| 12521 |
sio_h=`echo "$sio_h" | sed -n ' |
| 12522 |
s-//*-/-g |
| 12523 |
s-/*$-- |
| 12524 |
/^\/\/*[^/]*$/{ |
| 12525 |
c\\ |
| 12526 |
/ |
| 12527 |
p |
| 12528 |
q |
| 12529 |
} |
| 12530 |
/^[^/]*$/{ |
| 12531 |
c\\ |
| 12532 |
. |
| 12533 |
p |
| 12534 |
q |
| 12535 |
} |
| 12536 |
/./{ |
| 12537 |
s-/[^/]*$-- |
| 12538 |
p |
| 12539 |
q |
| 12540 |
}'` |
| 12541 |
|
| 12542 |
|
| 12543 |
wi_path="$MAINDIR/Strn/Strn.h" |
| 12544 |
if test -d "$wi_path" ; then |
| 12545 |
wi_resolved_path=`cd "$wi_path" ; $wi_PWD 2>/dev/null` |
| 12546 |
elif test ! -f "$wi_path" ; then |
| 12547 |
wi_resolved_path="$wi_path" |
| 12548 |
else |
| 12549 |
wi_parent_dir="$wi_path" |
| 12550 |
wi_file_name="$wi_path" |
| 12551 |
|
| 12552 |
wi_parent_dir=`echo "$wi_parent_dir" | sed -n ' |
| 12553 |
s-//*-/-g |
| 12554 |
s-/*$-- |
| 12555 |
/^\/\/*[^/]*$/{ |
| 12556 |
c\\ |
| 12557 |
/ |
| 12558 |
p |
| 12559 |
q |
| 12560 |
} |
| 12561 |
/^[^/]*$/{ |
| 12562 |
c\\ |
| 12563 |
. |
| 12564 |
p |
| 12565 |
q |
| 12566 |
} |
| 12567 |
/./{ |
| 12568 |
s-/[^/]*$-- |
| 12569 |
p |
| 12570 |
q |
| 12571 |
}'` |
| 12572 |
|
| 12573 |
wi_file_name=`echo "$wi_file_name" | sed -n ' |
| 12574 |
s-//*-/-g |
| 12575 |
s-/*$-- |
| 12576 |
s-^/$-- |
| 12577 |
s-^.*/-- |
| 12578 |
p |
| 12579 |
q'` |
| 12580 |
wi_resolved_path=`cd "$wi_parent_dir" ; $wi_PWD 2>/dev/null` |
| 12581 |
if test "x$wi_resolved_path" != x ; then |
| 12582 |
wi_resolved_path="$wi_resolved_path/$wi_file_name" |
| 12583 |
fi |
| 12584 |
unset wi_parent_dir wi_file_name |
| 12585 |
fi |
| 12586 |
if test "x$wi_resolved_path" = x ; then |
| 12587 |
strn_h="$$MAINDIR/Strn/Strn.h" |
| 12588 |
else |
| 12589 |
strn_h="$wi_resolved_path" |
| 12590 |
fi |
| 12591 |
unset wi_resolved_path wi_path |
| 12592 |
|
| 12593 |
|
| 12594 |
strn_h=`echo "$strn_h" | sed -n ' |
| 12595 |
s-//*-/-g |
| 12596 |
s-/*$-- |
| 12597 |
/^\/\/*[^/]*$/{ |
| 12598 |
c\\ |
| 12599 |
/ |
| 12600 |
p |
| 12601 |
q |
| 12602 |
} |
| 12603 |
/^[^/]*$/{ |
| 12604 |
c\\ |
| 12605 |
. |
| 12606 |
p |
| 12607 |
q |
| 12608 |
} |
| 12609 |
/./{ |
| 12610 |
s-/[^/]*$-- |
| 12611 |
p |
| 12612 |
q |
| 12613 |
}'` |
| 12614 |
CPPFLAGS="-I${MAINDIR} -I${libncftp_h} -I${sio_h} -I${strn_h} $CPPFLAGS" |
| 12615 |
LDFLAGS="-L${libncftp_h} -L${sio_h} -L${strn_h} $LDFLAGS" |
| 12616 |
|
| 12617 |
LIBS=`echo "$LIBS" | sed 's/^ *//;s/ *$//;s/ */ /g'` |
| 12618 |
LDFLAGS=`echo "$LDFLAGS" | sed 's/^ *//;s/ *$//;s/ */ /g'` |
| 12619 |
CPPFLAGS=`echo "$CPPFLAGS" | sed 's/^ *//;s/ *$//;s/ */ /g'` |
| 12620 |
CFLAGS=`echo "$CFLAGS $wi_CFLAGS_TO_ADD_LATER" | sed 's/^ *//;s/ *$//;s/ */ /g'` |
| 12621 |
DEFS=`echo "$DEFS" | sed 's/^ *//;s/ *$//;s/ */ /g'` |
| 12622 |
|
| 12623 |
|
| 12624 |
|
| 12625 |
|
| 12626 |
LIBNCFTP_PRECOMP="libncftp/pch.mk.none" |
| 12627 |
SIO_PRECOMP="sio/pch.mk.none" |
| 12628 |
if test "${wi_cv_cc_precomp}_${wi_cv_cc_precomp_type}" = "yes_gcc_gch_files" ; then |
| 12629 |
LIBNCFTP_PRECOMP="libncftp/pch.mk.gcc-gch" |
| 12630 |
SIO_PRECOMP="sio/pch.mk.gcc-gch" |
| 12631 |
elif test "${wi_cv_cc_precomp}_${SYS}" = "yes_macosx" ; then |
| 12632 |
LIBNCFTP_PRECOMP="libncftp/pch.mk.$SYS" |
| 12633 |
SIO_PRECOMP="sio/pch.mk.$SYS" |
| 12634 |
fi |
| 12635 |
|
| 12636 |
|
| 12637 |
|
| 12638 |
|
| 12639 |
|
| 12640 |
LIBNCFTP_VERSION=`sed -n '/kLibraryVersion/{ |
| 12641 |
s/^[^0-9]*// |
| 12642 |
s/\ .*$// |
| 12643 |
p |
| 12644 |
q |
| 12645 |
}' libncftp/ncftp.h` |
| 12646 |
|
| 12647 |
NCFTP_VERSION=`sed -n '/gVersion\[\]/{ |
| 12648 |
s/^[^0-9]*// |
| 12649 |
s/\/.*$// |
| 12650 |
p |
| 12651 |
q |
| 12652 |
}' ncftp/version.c` |
| 12653 |
|
| 12654 |
SIO_VERSION=`sed -n '/kSioVersion/{ |
| 12655 |
s/^[^0-9]*// |
| 12656 |
s/\ .*$// |
| 12657 |
p |
| 12658 |
q |
| 12659 |
}' sio/sio.h` |
| 12660 |
|
| 12661 |
STRN_VERSION=`sed -n '/gStrnLibVersion\[\]/{ |
| 12662 |
s/^[^0-9]*// |
| 12663 |
s/\".*$// |
| 12664 |
p |
| 12665 |
q |
| 12666 |
}' Strn/Strncpy.c` |
| 12667 |
|
| 12668 |
|
| 12669 |
echo $ac_n "checking CC""... $ac_c" 1>&6 |
| 12670 |
echo "configure:12671: checking CC" >&5 |
| 12671 |
echo "$ac_t""$CC" 1>&6 |
| 12672 |
echo $ac_n "checking CFLAGS""... $ac_c" 1>&6 |
| 12673 |
echo "configure:12674: checking CFLAGS" >&5 |
| 12674 |
echo "$ac_t""$CFLAGS" 1>&6 |
| 12675 |
echo $ac_n "checking CPPFLAGS""... $ac_c" 1>&6 |
| 12676 |
echo "configure:12677: checking CPPFLAGS" >&5 |
| 12677 |
echo "$ac_t""$CPPFLAGS" 1>&6 |
| 12678 |
echo $ac_n "checking DEFS""... $ac_c" 1>&6 |
| 12679 |
echo "configure:12680: checking DEFS" >&5 |
| 12680 |
echo "$ac_t""$DEFS" 1>&6 |
| 12681 |
echo $ac_n "checking NDEFS""... $ac_c" 1>&6 |
| 12682 |
echo "configure:12683: checking NDEFS" >&5 |
| 12683 |
echo "$ac_t""$NDEFS" 1>&6 |
| 12684 |
echo $ac_n "checking LDFLAGS""... $ac_c" 1>&6 |
| 12685 |
echo "configure:12686: checking LDFLAGS" >&5 |
| 12686 |
echo "$ac_t""$LDFLAGS" 1>&6 |
| 12687 |
echo $ac_n "checking LIBS""... $ac_c" 1>&6 |
| 12688 |
echo "configure:12689: checking LIBS" >&5 |
| 12689 |
echo "$ac_t""$LIBS" 1>&6 |
| 12690 |
# |
| 12691 |
# Also take the opportunity to do some post-configure clean-up |
| 12692 |
# |
| 12693 |
/bin/rm -rf "conftest.dSYM" "a.out" |
| 12694 |
|
| 12695 |
|
| 12696 |
|
| 12697 |
|
| 12698 |
|
| 12699 |
|
| 12700 |
|
| 12701 |
|
| 12702 |
|
| 12703 |
|
| 12704 |
|
| 12705 |
|
| 12706 |
|
| 12707 |
|
| 12708 |
|
| 12709 |
|
| 12710 |
|
| 12711 |
|
| 12712 |
|
| 12713 |
|
| 12714 |
trap '' 1 2 15 |
| 12715 |
cat > confcache <<\EOF |
| 12716 |
# This file is a shell script that caches the results of configure |
| 12717 |
# tests run on this system so they can be shared between configure |
| 12718 |
# scripts and configure runs. It is not useful on other systems. |
| 12719 |
# If it contains results you don't want to keep, you may remove or edit it. |
| 12720 |
# |
| 12721 |
# By default, configure uses ./config.cache as the cache file, |
| 12722 |
# creating it if it does not exist already. You can give configure |
| 12723 |
# the --cache-file=FILE option to use a different cache file; that is |
| 12724 |
# what configure does when it calls configure scripts in |
| 12725 |
# subdirectories, so they share the cache. |
| 12726 |
# Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 12727 |
# config.status only pays attention to the cache file if you give it the |
| 12728 |
# --recheck option to rerun configure. |
| 12729 |
# |
| 12730 |
EOF |
| 12731 |
# The following way of writing the cache mishandles newlines in values, |
| 12732 |
# but we know of no workaround that is simple, portable, and efficient. |
| 12733 |
# So, don't put newlines in cache variables' values. |
| 12734 |
# Ultrix sh set writes to stderr and can't be redirected directly, |
| 12735 |
# and sets the high bit in the cache file unless we assign to the vars. |
| 12736 |
(set) 2>&1 | |
| 12737 |
case `(ac_space=' '; set | grep ac_space) 2>&1` in |
| 12738 |
*ac_space=\ *) |
| 12739 |
# `set' does not quote correctly, so add quotes (double-quote substitution |
| 12740 |
# turns \\\\ into \\, and sed turns \\ into \). |
| 12741 |
sed -n \ |
| 12742 |
-e "s/'/'\\\\''/g" \ |
| 12743 |
-e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" |
| 12744 |
;; |
| 12745 |
*) |
| 12746 |
# `set' quotes correctly as required by POSIX, so do not add quotes. |
| 12747 |
sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' |
| 12748 |
;; |
| 12749 |
esac >> confcache |
| 12750 |
if cmp -s $cache_file confcache; then |
| 12751 |
: |
| 12752 |
else |
| 12753 |
if test -w $cache_file; then |
| 12754 |
echo "updating cache $cache_file" |
| 12755 |
cat confcache > $cache_file |
| 12756 |
else |
| 12757 |
echo "not updating unwritable cache $cache_file" |
| 12758 |
fi |
| 12759 |
fi |
| 12760 |
rm -f confcache |
| 12761 |
|
| 12762 |
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
| 12763 |
|
| 12764 |
test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 12765 |
# Let make expand exec_prefix. |
| 12766 |
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
| 12767 |
|
| 12768 |
# Any assignment to VPATH causes Sun make to only execute |
| 12769 |
# the first set of double-colon rules, so remove it if not needed. |
| 12770 |
# If there is a colon in the path, we need to keep it. |
| 12771 |
if test "x$srcdir" = x.; then |
| 12772 |
ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 12773 |
fi |
| 12774 |
|
| 12775 |
trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
| 12776 |
|
| 12777 |
DEFS=-DHAVE_CONFIG_H |
| 12778 |
|
| 12779 |
# Without the "./", some shells look in PATH for config.status. |
| 12780 |
: ${CONFIG_STATUS=./config.status} |
| 12781 |
|
| 12782 |
echo creating $CONFIG_STATUS |
| 12783 |
rm -f $CONFIG_STATUS |
| 12784 |
cat > $CONFIG_STATUS <<EOF |
| 12785 |
#! /bin/sh |
| 12786 |
# Generated automatically by configure. |
| 12787 |
# Run this file to recreate the current configuration. |
| 12788 |
# This directory was configured as follows, |
| 12789 |
# on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 12790 |
# |
| 12791 |
# $0 $ac_configure_args |
| 12792 |
# |
| 12793 |
# Compiler output produced by configure, useful for debugging |
| 12794 |
# configure, is in ./config.log if it exists. |
| 12795 |
|
| 12796 |
ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
| 12797 |
for ac_option |
| 12798 |
do |
| 12799 |
case "\$ac_option" in |
| 12800 |
-recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 12801 |
echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 12802 |
exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; |
| 12803 |
-version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
| 12804 |
echo "$CONFIG_STATUS generated by autoconf version 2.13" |
| 12805 |
exit 0 ;; |
| 12806 |
-help | --help | --hel | --he | --h) |
| 12807 |
echo "\$ac_cs_usage"; exit 0 ;; |
| 12808 |
*) echo "\$ac_cs_usage"; exit 1 ;; |
| 12809 |
esac |
| 12810 |
done |
| 12811 |
|
| 12812 |
ac_given_srcdir=$srcdir |
| 12813 |
ac_given_INSTALL="$INSTALL" |
| 12814 |
|
| 12815 |
trap 'rm -fr `echo "Makefile Makefile.bin ncftp/Makefile libncftp/Makefile Strn/Makefile sio/Makefile sh_util/Makefile vis/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
| 12816 |
EOF |
| 12817 |
cat >> $CONFIG_STATUS <<EOF |
| 12818 |
|
| 12819 |
# Protect against being on the right side of a sed subst in config.status. |
| 12820 |
sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
| 12821 |
s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
| 12822 |
$ac_vpsub |
| 12823 |
$extrasub |
| 12824 |
s%@SHELL@%$SHELL%g |
| 12825 |
s%@CFLAGS@%$CFLAGS%g |
| 12826 |
s%@CPPFLAGS@%$CPPFLAGS%g |
| 12827 |
s%@CXXFLAGS@%$CXXFLAGS%g |
| 12828 |
s%@FFLAGS@%$FFLAGS%g |
| 12829 |
s%@DEFS@%$DEFS%g |
| 12830 |
s%@LDFLAGS@%$LDFLAGS%g |
| 12831 |
s%@LIBS@%$LIBS%g |
| 12832 |
s%@exec_prefix@%$exec_prefix%g |
| 12833 |
s%@prefix@%$prefix%g |
| 12834 |
s%@program_transform_name@%$program_transform_name%g |
| 12835 |
s%@bindir@%$bindir%g |
| 12836 |
s%@sbindir@%$sbindir%g |
| 12837 |
s%@libexecdir@%$libexecdir%g |
| 12838 |
s%@datadir@%$datadir%g |
| 12839 |
s%@sysconfdir@%$sysconfdir%g |
| 12840 |
s%@sharedstatedir@%$sharedstatedir%g |
| 12841 |
s%@localstatedir@%$localstatedir%g |
| 12842 |
s%@libdir@%$libdir%g |
| 12843 |
s%@includedir@%$includedir%g |
| 12844 |
s%@oldincludedir@%$oldincludedir%g |
| 12845 |
s%@infodir@%$infodir%g |
| 12846 |
s%@mandir@%$mandir%g |
| 12847 |
s%@CC@%$CC%g |
| 12848 |
s%@NDEFS@%$NDEFS%g |
| 12849 |
s%@OS@%$OS%g |
| 12850 |
s%@host@%$host%g |
| 12851 |
s%@SYS@%$SYS%g |
| 12852 |
s%@HOME_OS@%$HOME_OS%g |
| 12853 |
s%@CPP@%$CPP%g |
| 12854 |
s%@STRIP@%$STRIP%g |
| 12855 |
s%@OBJEXT@%$OBJEXT%g |
| 12856 |
s%@EXEEXT@%$EXEEXT%g |
| 12857 |
s%@SIO_OBJS_U@%$SIO_OBJS_U%g |
| 12858 |
s%@SIO_SOBJS_U@%$SIO_SOBJS_U%g |
| 12859 |
s%@SOCKS_LIBS@%$SOCKS_LIBS%g |
| 12860 |
s%@LIBCURSES@%$LIBCURSES%g |
| 12861 |
s%@PERL@%$PERL%g |
| 12862 |
s%@MKTEMP@%$MKTEMP%g |
| 12863 |
s%@ALLOCA@%$ALLOCA%g |
| 12864 |
s%@SET_MAKE@%$SET_MAKE%g |
| 12865 |
s%@TAR@%$TAR%g |
| 12866 |
s%@TARFLAGS@%$TARFLAGS%g |
| 12867 |
s%@RANLIB@%$RANLIB%g |
| 12868 |
s%@AR@%$AR%g |
| 12869 |
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
| 12870 |
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g |
| 12871 |
s%@INSTALL_DATA@%$INSTALL_DATA%g |
| 12872 |
s%@wi_PWD@%$wi_PWD%g |
| 12873 |
s%@CCDV@%$CCDV%g |
| 12874 |
/@LIBNCFTP_PRECOMP@/r $LIBNCFTP_PRECOMP |
| 12875 |
s%@LIBNCFTP_PRECOMP@%%g |
| 12876 |
/@SIO_PRECOMP@/r $SIO_PRECOMP |
| 12877 |
s%@SIO_PRECOMP@%%g |
| 12878 |
s%@SFLAG@%$SFLAG%g |
| 12879 |
s%@MAKE@%$MAKE%g |
| 12880 |
s%@Z30@%$Z30%g |
| 12881 |
s%@LIBSET@%$LIBSET%g |
| 12882 |
s%@MAINDIR@%$MAINDIR%g |
| 12883 |
s%@NCFTP_VERSION@%$NCFTP_VERSION%g |
| 12884 |
s%@LIBNCFTP_VERSION@%$LIBNCFTP_VERSION%g |
| 12885 |
s%@SIO_VERSION@%$SIO_VERSION%g |
| 12886 |
s%@STRN_VERSION@%$STRN_VERSION%g |
| 12887 |
s%@VIS_DPROGS@%$VIS_DPROGS%g |
| 12888 |
s%@SIZEOF_OFF_T@%$SIZEOF_OFF_T%g |
| 12889 |
s%@SIZEOF_ST_SIZE@%$SIZEOF_ST_SIZE%g |
| 12890 |
|
| 12891 |
CEOF |
| 12892 |
EOF |
| 12893 |
|
| 12894 |
cat >> $CONFIG_STATUS <<\EOF |
| 12895 |
|
| 12896 |
# Split the substitutions into bite-sized pieces for seds with |
| 12897 |
# small command number limits, like on Digital OSF/1 and HP-UX. |
| 12898 |
ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
| 12899 |
ac_file=1 # Number of current file. |
| 12900 |
ac_beg=1 # First line for current file. |
| 12901 |
ac_end=$ac_max_sed_cmds # Line after last line for current file. |
| 12902 |
ac_more_lines=: |
| 12903 |
ac_sed_cmds="" |
| 12904 |
while $ac_more_lines; do |
| 12905 |
if test $ac_beg -gt 1; then |
| 12906 |
sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file |
| 12907 |
else |
| 12908 |
sed "${ac_end}q" conftest.subs > conftest.s$ac_file |
| 12909 |
fi |
| 12910 |
if test ! -s conftest.s$ac_file; then |
| 12911 |
ac_more_lines=false |
| 12912 |
rm -f conftest.s$ac_file |
| 12913 |
else |
| 12914 |
if test -z "$ac_sed_cmds"; then |
| 12915 |
ac_sed_cmds="sed -f conftest.s$ac_file" |
| 12916 |
else |
| 12917 |
ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
| 12918 |
fi |
| 12919 |
ac_file=`expr $ac_file + 1` |
| 12920 |
ac_beg=$ac_end |
| 12921 |
ac_end=`expr $ac_end + $ac_max_sed_cmds` |
| 12922 |
fi |
| 12923 |
done |
| 12924 |
if test -z "$ac_sed_cmds"; then |
| 12925 |
ac_sed_cmds=cat |
| 12926 |
fi |
| 12927 |
EOF |
| 12928 |
|
| 12929 |
cat >> $CONFIG_STATUS <<EOF |
| 12930 |
|
| 12931 |
CONFIG_FILES=\${CONFIG_FILES-"Makefile Makefile.bin ncftp/Makefile libncftp/Makefile Strn/Makefile sio/Makefile sh_util/Makefile vis/Makefile"} |
| 12932 |
EOF |
| 12933 |
cat >> $CONFIG_STATUS <<\EOF |
| 12934 |
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then |
| 12935 |
# Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
| 12936 |
case "$ac_file" in |
| 12937 |
*:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
| 12938 |
ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 12939 |
*) ac_file_in="${ac_file}.in" ;; |
| 12940 |
esac |
| 12941 |
|
| 12942 |
# Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
| 12943 |
|
| 12944 |
# Remove last slash and all that follows it. Not all systems have dirname. |
| 12945 |
ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 12946 |
if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 12947 |
# The file is in a subdirectory. |
| 12948 |
test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 12949 |
ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
| 12950 |
# A "../" for each directory in $ac_dir_suffix. |
| 12951 |
ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 12952 |
else |
| 12953 |
ac_dir_suffix= ac_dots= |
| 12954 |
fi |
| 12955 |
|
| 12956 |
case "$ac_given_srcdir" in |
| 12957 |
.) srcdir=. |
| 12958 |
if test -z "$ac_dots"; then top_srcdir=. |
| 12959 |
else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 12960 |
/*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 12961 |
*) # Relative path. |
| 12962 |
srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 12963 |
top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 12964 |
esac |
| 12965 |
|
| 12966 |
case "$ac_given_INSTALL" in |
| 12967 |
[/$]*) INSTALL="$ac_given_INSTALL" ;; |
| 12968 |
*) INSTALL="$ac_dots$ac_given_INSTALL" ;; |
| 12969 |
esac |
| 12970 |
|
| 12971 |
echo creating "$ac_file" |
| 12972 |
rm -f "$ac_file" |
| 12973 |
configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 12974 |
case "$ac_file" in |
| 12975 |
*Makefile*) ac_comsub="1i\\ |
| 12976 |
# $configure_input" ;; |
| 12977 |
*) ac_comsub= ;; |
| 12978 |
esac |
| 12979 |
|
| 12980 |
ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
| 12981 |
sed -e "$ac_comsub |
| 12982 |
s%@configure_input@%$configure_input%g |
| 12983 |
s%@srcdir@%$srcdir%g |
| 12984 |
s%@top_srcdir@%$top_srcdir%g |
| 12985 |
s%@INSTALL@%$INSTALL%g |
| 12986 |
" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
| 12987 |
fi; done |
| 12988 |
rm -f conftest.s* |
| 12989 |
|
| 12990 |
# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 12991 |
# NAME is the cpp macro being defined and VALUE is the value it is being given. |
| 12992 |
# |
| 12993 |
# ac_d sets the value in "#define NAME VALUE" lines. |
| 12994 |
ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 12995 |
ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
| 12996 |
ac_dC='\3' |
| 12997 |
ac_dD='%g' |
| 12998 |
# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". |
| 12999 |
ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 13000 |
ac_uB='\([ ]\)%\1#\2define\3' |
| 13001 |
ac_uC=' ' |
| 13002 |
ac_uD='\4%g' |
| 13003 |
# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". |
| 13004 |
ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 13005 |
ac_eB='$%\1#\2define\3' |
| 13006 |
ac_eC=' ' |
| 13007 |
ac_eD='%g' |
| 13008 |
|
| 13009 |
if test "${CONFIG_HEADERS+set}" != set; then |
| 13010 |
EOF |
| 13011 |
cat >> $CONFIG_STATUS <<EOF |
| 13012 |
CONFIG_HEADERS="config.h" |
| 13013 |
EOF |
| 13014 |
cat >> $CONFIG_STATUS <<\EOF |
| 13015 |
fi |
| 13016 |
for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then |
| 13017 |
# Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
| 13018 |
case "$ac_file" in |
| 13019 |
*:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
| 13020 |
ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 13021 |
*) ac_file_in="${ac_file}.in" ;; |
| 13022 |
esac |
| 13023 |
|
| 13024 |
echo creating $ac_file |
| 13025 |
|
| 13026 |
rm -f conftest.frag conftest.in conftest.out |
| 13027 |
ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
| 13028 |
cat $ac_file_inputs > conftest.in |
| 13029 |
|
| 13030 |
EOF |
| 13031 |
|
| 13032 |
# Transform confdefs.h into a sed script conftest.vals that substitutes |
| 13033 |
# the proper values into config.h.in to produce config.h. And first: |
| 13034 |
# Protect against being on the right side of a sed subst in config.status. |
| 13035 |
# Protect against being in an unquoted here document in config.status. |
| 13036 |
rm -f conftest.vals |
| 13037 |
cat > conftest.hdr <<\EOF |
| 13038 |
s/[\\&%]/\\&/g |
| 13039 |
s%[\\$`]%\\&%g |
| 13040 |
s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp |
| 13041 |
s%ac_d%ac_u%gp |
| 13042 |
s%ac_u%ac_e%gp |
| 13043 |
EOF |
| 13044 |
sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 13045 |
rm -f conftest.hdr |
| 13046 |
|
| 13047 |
# This sed command replaces #undef with comments. This is necessary, for |
| 13048 |
# example, in the case of _POSIX_SOURCE, which is predefined and required |
| 13049 |
# on some systems where configure will not decide to define it. |
| 13050 |
cat >> conftest.vals <<\EOF |
| 13051 |
s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 13052 |
EOF |
| 13053 |
|
| 13054 |
# Break up conftest.vals because some shells have a limit on |
| 13055 |
# the size of here documents, and old seds have small limits too. |
| 13056 |
|
| 13057 |
rm -f conftest.tail |
| 13058 |
while : |
| 13059 |
do |
| 13060 |
ac_lines=`grep -c . conftest.vals` |
| 13061 |
# grep -c gives empty output for an empty file on some AIX systems. |
| 13062 |
if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 13063 |
# Write a limited-size here document to conftest.frag. |
| 13064 |
echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 13065 |
sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 13066 |
echo 'CEOF |
| 13067 |
sed -f conftest.frag conftest.in > conftest.out |
| 13068 |
rm -f conftest.in |
| 13069 |
mv conftest.out conftest.in |
| 13070 |
' >> $CONFIG_STATUS |
| 13071 |
sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 13072 |
rm -f conftest.vals |
| 13073 |
mv conftest.tail conftest.vals |
| 13074 |
done |
| 13075 |
rm -f conftest.vals |
| 13076 |
|
| 13077 |
cat >> $CONFIG_STATUS <<\EOF |
| 13078 |
rm -f conftest.frag conftest.h |
| 13079 |
echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
| 13080 |
cat conftest.in >> conftest.h |
| 13081 |
rm -f conftest.in |
| 13082 |
if cmp -s $ac_file conftest.h 2>/dev/null; then |
| 13083 |
echo "$ac_file is unchanged" |
| 13084 |
rm -f conftest.h |
| 13085 |
else |
| 13086 |
# Remove last slash and all that follows it. Not all systems have dirname. |
| 13087 |
ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 13088 |
if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 13089 |
# The file is in a subdirectory. |
| 13090 |
test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 13091 |
fi |
| 13092 |
rm -f $ac_file |
| 13093 |
mv conftest.h $ac_file |
| 13094 |
fi |
| 13095 |
fi; done |
| 13096 |
|
| 13097 |
EOF |
| 13098 |
cat >> $CONFIG_STATUS <<EOF |
| 13099 |
|
| 13100 |
|
| 13101 |
EOF |
| 13102 |
cat >> $CONFIG_STATUS <<\EOF |
| 13103 |
/bin/rm -f ./ncftp/readln.o |
| 13104 |
|
| 13105 |
exit 0 |
| 13106 |
EOF |
| 13107 |
chmod +x $CONFIG_STATUS |
| 13108 |
rm -fr confdefs* $ac_clean_files |
| 13109 |
test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 |
| 13110 |
|