Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1 | #! /bin/sh |
| 2 | # Guess values for system-dependent variables and create Makefiles. |
| 3 | # Generated by Autoconf 2.52.20141204. |
| 4 | # |
| 5 | # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001 |
| 6 | # Free Software Foundation, Inc. |
| 7 | # This configure script is free software; the Free Software Foundation |
| 8 | # gives unlimited permission to copy, distribute and modify it. |
| 9 | |
| 10 | # Avoid depending upon Character Ranges. |
| 11 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 12 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 13 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 14 | as_cr_digits='0123456789' |
| 15 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
| 16 | |
| 17 | # Sed expression to map a string onto a valid variable name. |
| 18 | as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g" |
| 19 | |
| 20 | # Sed expression to map a string onto a valid CPP name. |
| 21 | as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g" |
| 22 | |
| 23 | # Be Bourne compatible |
| 24 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then |
| 25 | emulate sh |
| 26 | NULLCMD=: |
| 27 | elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then |
| 28 | set -o posix |
| 29 | fi |
| 30 | |
| 31 | # Name of the executable. |
| 32 | as_me=`echo "$0" |sed 's,.*[\\/],,'` |
| 33 | |
| 34 | if expr a : '\(a\)' >/dev/null 2>&1; then |
| 35 | as_expr=expr |
| 36 | else |
| 37 | as_expr=false |
| 38 | fi |
| 39 | |
| 40 | rm -f conf$$ conf$$.exe conf$$.file |
| 41 | echo >conf$$.file |
| 42 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 43 | # We could just check for DJGPP; but this test a) works b) is more generic |
| 44 | # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). |
| 45 | if test -f conf$$.exe; then |
| 46 | # Don't use ln at all; we don't have any links |
| 47 | as_ln_s='cp -p' |
| 48 | else |
| 49 | as_ln_s='ln -s' |
| 50 | fi |
| 51 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 52 | as_ln_s=ln |
| 53 | else |
| 54 | as_ln_s='cp -p' |
| 55 | fi |
| 56 | rm -f conf$$ conf$$.exe conf$$.file |
| 57 | |
| 58 | as_executable_p="test -f" |
| 59 | |
| 60 | # Support unset when possible. |
| 61 | if (FOO=FOO; unset FOO) >/dev/null 2>&1; then |
| 62 | as_unset=unset |
| 63 | else |
| 64 | as_unset=false |
| 65 | fi |
| 66 | |
| 67 | # NLS nuisances. |
| 68 | $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; } |
| 69 | $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; } |
| 70 | $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; } |
| 71 | $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; } |
| 72 | $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; } |
| 73 | $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; } |
| 74 | $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; } |
| 75 | $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; } |
| 76 | |
| 77 | # IFS |
| 78 | # We need space, tab and new line, in precisely that order. |
| 79 | as_nl=' |
| 80 | ' |
| 81 | IFS=" $as_nl" |
| 82 | |
| 83 | # CDPATH. |
| 84 | $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; } |
| 85 | |
| 86 | # Name of the host. |
| 87 | # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, |
| 88 | # so uname gets run too. |
| 89 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` |
| 90 | |
| 91 | exec 6>&1 |
| 92 | |
| 93 | # |
| 94 | # Initializations. |
| 95 | # |
| 96 | ac_default_prefix=/usr/local |
| 97 | cross_compiling=no |
| 98 | subdirs= |
| 99 | MFLAGS= MAKEFLAGS= |
| 100 | SHELL=${CONFIG_SHELL-/bin/sh} |
| 101 | |
| 102 | # Maximum number of lines to put in a shell here document. |
| 103 | # This variable seems obsolete. It should probably be removed, and |
| 104 | # only ac_max_sed_lines should be used. |
| 105 | : ${ac_max_here_lines=38} |
| 106 | |
| 107 | ac_unique_file="ncurses.c" |
| 108 | |
| 109 | # Initialize some variables set by options. |
| 110 | ac_init_help= |
| 111 | ac_init_version=false |
| 112 | # The variables have the same names as the options, with |
| 113 | # dashes changed to underlines. |
| 114 | cache_file=/dev/null |
| 115 | exec_prefix=NONE |
| 116 | no_create= |
| 117 | no_recursion= |
| 118 | prefix=NONE |
| 119 | program_prefix=NONE |
| 120 | program_suffix=NONE |
| 121 | program_transform_name=s,x,x, |
| 122 | silent= |
| 123 | site= |
| 124 | srcdir= |
| 125 | verbose= |
| 126 | x_includes=NONE |
| 127 | x_libraries=NONE |
| 128 | |
| 129 | # Installation directory options. |
| 130 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 131 | # and all the variables that are supposed to be based on exec_prefix |
| 132 | # by default will actually change. |
| 133 | # Use braces instead of parens because sh, perl, etc. also accept them. |
| 134 | bindir='${exec_prefix}/bin' |
| 135 | sbindir='${exec_prefix}/sbin' |
| 136 | libexecdir='${exec_prefix}/libexec' |
| 137 | datarootdir='${prefix}/share' |
| 138 | datadir='${datarootdir}' |
| 139 | sysconfdir='${prefix}/etc' |
| 140 | sharedstatedir='${prefix}/com' |
| 141 | localstatedir='${prefix}/var' |
| 142 | libdir='${exec_prefix}/lib' |
| 143 | includedir='${prefix}/include' |
| 144 | oldincludedir='/usr/include' |
| 145 | infodir='${datarootdir}/info' |
| 146 | mandir='${datarootdir}/man' |
| 147 | |
| 148 | # Identity of this package. |
| 149 | PACKAGE_NAME= |
| 150 | PACKAGE_TARNAME= |
| 151 | PACKAGE_VERSION= |
| 152 | PACKAGE_STRING= |
| 153 | PACKAGE_BUGREPORT= |
| 154 | |
| 155 | ac_prev= |
| 156 | for ac_option |
| 157 | do |
| 158 | # If the previous option needs an argument, assign it. |
| 159 | if test -n "$ac_prev"; then |
| 160 | eval "$ac_prev=\$ac_option" |
| 161 | ac_prev= |
| 162 | continue |
| 163 | fi |
| 164 | |
| 165 | ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'` |
| 166 | |
| 167 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 168 | |
| 169 | case $ac_option in |
| 170 | |
| 171 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 172 | ac_prev=bindir ;; |
| 173 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 174 | bindir=$ac_optarg ;; |
| 175 | |
| 176 | -build | --build | --buil | --bui | --bu) |
| 177 | ac_prev=build_alias ;; |
| 178 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
| 179 | build_alias=$ac_optarg ;; |
| 180 | |
| 181 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 182 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 183 | ac_prev=cache_file ;; |
| 184 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 185 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 186 | cache_file=$ac_optarg ;; |
| 187 | |
| 188 | --config-cache | -C) |
| 189 | cache_file=config.cache ;; |
| 190 | |
| 191 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 192 | ac_prev=datadir ;; |
| 193 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 194 | | --da=*) |
| 195 | datadir=$ac_optarg ;; |
| 196 | |
| 197 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 198 | | --dataroo | --dataro | --datar) |
| 199 | ac_prev=datarootdir ;; |
| 200 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 201 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 202 | datarootdir=$ac_optarg ;; |
| 203 | |
| 204 | -disable-* | --disable-*) |
| 205 | ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
| 206 | # Reject names that are not valid shell variable names. |
| 207 | expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && |
| 208 | { echo "$as_me: error: invalid feature name: $ac_feature" >&2 |
| 209 | { (exit 1); exit 1; }; } |
| 210 | ac_feature=`echo $ac_feature | sed 's/-/_/g'` |
| 211 | eval "enable_$ac_feature=no" ;; |
| 212 | |
| 213 | -enable-* | --enable-*) |
| 214 | ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
| 215 | # Reject names that are not valid shell variable names. |
| 216 | expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && |
| 217 | { echo "$as_me: error: invalid feature name: $ac_feature" >&2 |
| 218 | { (exit 1); exit 1; }; } |
| 219 | ac_feature=`echo $ac_feature | sed 's/-/_/g'` |
| 220 | case $ac_option in |
| 221 | *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; |
| 222 | *) ac_optarg=yes ;; |
| 223 | esac |
| 224 | eval "enable_$ac_feature='$ac_optarg'" ;; |
| 225 | |
| 226 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 227 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 228 | | --exec | --exe | --ex) |
| 229 | ac_prev=exec_prefix ;; |
| 230 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 231 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 232 | | --exec=* | --exe=* | --ex=*) |
| 233 | exec_prefix=$ac_optarg ;; |
| 234 | |
| 235 | -gas | --gas | --ga | --g) |
| 236 | # Obsolete; use --with-gas. |
| 237 | with_gas=yes ;; |
| 238 | |
| 239 | -help | --help | --hel | --he | -h) |
| 240 | ac_init_help=long ;; |
| 241 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 242 | ac_init_help=recursive ;; |
| 243 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 244 | ac_init_help=short ;; |
| 245 | |
| 246 | -host | --host | --hos | --ho) |
| 247 | ac_prev=host_alias ;; |
| 248 | -host=* | --host=* | --hos=* | --ho=*) |
| 249 | host_alias=$ac_optarg ;; |
| 250 | |
| 251 | -includedir | --includedir | --includedi | --included | --include \ |
| 252 | | --includ | --inclu | --incl | --inc) |
| 253 | ac_prev=includedir ;; |
| 254 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 255 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 256 | includedir=$ac_optarg ;; |
| 257 | |
| 258 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 259 | ac_prev=infodir ;; |
| 260 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 261 | infodir=$ac_optarg ;; |
| 262 | |
| 263 | -libdir | --libdir | --libdi | --libd) |
| 264 | ac_prev=libdir ;; |
| 265 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 266 | libdir=$ac_optarg ;; |
| 267 | |
| 268 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 269 | | --libexe | --libex | --libe) |
| 270 | ac_prev=libexecdir ;; |
| 271 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 272 | | --libexe=* | --libex=* | --libe=*) |
| 273 | libexecdir=$ac_optarg ;; |
| 274 | |
| 275 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 276 | | --localstate | --localstat | --localsta | --localst \ |
| 277 | | --locals | --local | --loca | --loc | --lo) |
| 278 | ac_prev=localstatedir ;; |
| 279 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 280 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 281 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 282 | localstatedir=$ac_optarg ;; |
| 283 | |
| 284 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 285 | ac_prev=mandir ;; |
| 286 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 287 | mandir=$ac_optarg ;; |
| 288 | |
| 289 | -nfp | --nfp | --nf) |
| 290 | # Obsolete; use --without-fp. |
| 291 | with_fp=no ;; |
| 292 | |
| 293 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 294 | | --no-cr | --no-c) |
| 295 | no_create=yes ;; |
| 296 | |
| 297 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 298 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 299 | no_recursion=yes ;; |
| 300 | |
| 301 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 302 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 303 | | --oldin | --oldi | --old | --ol | --o) |
| 304 | ac_prev=oldincludedir ;; |
| 305 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 306 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 307 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 308 | oldincludedir=$ac_optarg ;; |
| 309 | |
| 310 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 311 | ac_prev=prefix ;; |
| 312 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 313 | prefix=$ac_optarg ;; |
| 314 | |
| 315 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 316 | | --program-pre | --program-pr | --program-p) |
| 317 | ac_prev=program_prefix ;; |
| 318 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 319 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 320 | program_prefix=$ac_optarg ;; |
| 321 | |
| 322 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 323 | | --program-suf | --program-su | --program-s) |
| 324 | ac_prev=program_suffix ;; |
| 325 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 326 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 327 | program_suffix=$ac_optarg ;; |
| 328 | |
| 329 | -program-transform-name | --program-transform-name \ |
| 330 | | --program-transform-nam | --program-transform-na \ |
| 331 | | --program-transform-n | --program-transform- \ |
| 332 | | --program-transform | --program-transfor \ |
| 333 | | --program-transfo | --program-transf \ |
| 334 | | --program-trans | --program-tran \ |
| 335 | | --progr-tra | --program-tr | --program-t) |
| 336 | ac_prev=program_transform_name ;; |
| 337 | -program-transform-name=* | --program-transform-name=* \ |
| 338 | | --program-transform-nam=* | --program-transform-na=* \ |
| 339 | | --program-transform-n=* | --program-transform-=* \ |
| 340 | | --program-transform=* | --program-transfor=* \ |
| 341 | | --program-transfo=* | --program-transf=* \ |
| 342 | | --program-trans=* | --program-tran=* \ |
| 343 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 344 | program_transform_name=$ac_optarg ;; |
| 345 | |
| 346 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 347 | | -silent | --silent | --silen | --sile | --sil) |
| 348 | silent=yes ;; |
| 349 | |
| 350 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 351 | ac_prev=sbindir ;; |
| 352 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 353 | | --sbi=* | --sb=*) |
| 354 | sbindir=$ac_optarg ;; |
| 355 | |
| 356 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 357 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 358 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 359 | | --sha | --sh) |
| 360 | ac_prev=sharedstatedir ;; |
| 361 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 362 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 363 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 364 | | --sha=* | --sh=*) |
| 365 | sharedstatedir=$ac_optarg ;; |
| 366 | |
| 367 | -site | --site | --sit) |
| 368 | ac_prev=site ;; |
| 369 | -site=* | --site=* | --sit=*) |
| 370 | site=$ac_optarg ;; |
| 371 | |
| 372 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 373 | ac_prev=srcdir ;; |
| 374 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 375 | srcdir=$ac_optarg ;; |
| 376 | |
| 377 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 378 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 379 | ac_prev=sysconfdir ;; |
| 380 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 381 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 382 | sysconfdir=$ac_optarg ;; |
| 383 | |
| 384 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 385 | ac_prev=target_alias ;; |
| 386 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 387 | target_alias=$ac_optarg ;; |
| 388 | |
| 389 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 390 | verbose=yes ;; |
| 391 | |
| 392 | -version | --version | --versio | --versi | --vers | -V) |
| 393 | ac_init_version=: ;; |
| 394 | |
| 395 | -with-* | --with-*) |
| 396 | ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
| 397 | # Reject names that are not valid shell variable names. |
| 398 | expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && |
| 399 | { echo "$as_me: error: invalid package name: $ac_package" >&2 |
| 400 | { (exit 1); exit 1; }; } |
| 401 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 402 | case $ac_option in |
| 403 | *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; |
| 404 | *) ac_optarg=yes ;; |
| 405 | esac |
| 406 | eval "with_$ac_package='$ac_optarg'" ;; |
| 407 | |
| 408 | -without-* | --without-*) |
| 409 | ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
| 410 | # Reject names that are not valid shell variable names. |
| 411 | expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && |
| 412 | { echo "$as_me: error: invalid package name: $ac_package" >&2 |
| 413 | { (exit 1); exit 1; }; } |
| 414 | ac_package=`echo $ac_package | sed 's/-/_/g'` |
| 415 | eval "with_$ac_package=no" ;; |
| 416 | |
| 417 | --x) |
| 418 | # Obsolete; use --with-x. |
| 419 | with_x=yes ;; |
| 420 | |
| 421 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 422 | | --x-incl | --x-inc | --x-in | --x-i) |
| 423 | ac_prev=x_includes ;; |
| 424 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 425 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 426 | x_includes=$ac_optarg ;; |
| 427 | |
| 428 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 429 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 430 | ac_prev=x_libraries ;; |
| 431 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 432 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 433 | x_libraries=$ac_optarg ;; |
| 434 | |
| 435 | -*) { echo "$as_me: error: unrecognized option: $ac_option |
| 436 | Try \`$0 --help' for more information." >&2 |
| 437 | { (exit 1); exit 1; }; } |
| 438 | ;; |
| 439 | |
| 440 | *=*) |
| 441 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 442 | # Reject names that are not valid shell variable names. |
| 443 | expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && |
| 444 | { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 |
| 445 | { (exit 1); exit 1; }; } |
| 446 | ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` |
| 447 | eval "$ac_envvar='$ac_optarg'" |
| 448 | export $ac_envvar ;; |
| 449 | |
| 450 | *) |
| 451 | # FIXME: should be removed in autoconf 3.0. |
| 452 | echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
| 453 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
| 454 | echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
| 455 | : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} |
| 456 | ;; |
| 457 | |
| 458 | esac |
| 459 | done |
| 460 | |
| 461 | if test -n "$ac_prev"; then |
| 462 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
| 463 | { echo "$as_me: error: missing argument to $ac_option" >&2 |
| 464 | { (exit 1); exit 1; }; } |
| 465 | fi |
| 466 | |
| 467 | # Be sure to have absolute paths. |
| 468 | for ac_var in exec_prefix prefix |
| 469 | do |
| 470 | eval ac_val=$`echo $ac_var` |
| 471 | case $ac_val in |
| 472 | [\\/$]* | ?:[\\/]* | NONE | '' ) ;; |
| 473 | *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2 |
| 474 | { (exit 1); exit 1; }; };; |
| 475 | esac |
| 476 | done |
| 477 | |
| 478 | # Be sure to have absolute paths. |
| 479 | for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \ |
| 480 | localstatedir libdir includedir oldincludedir infodir mandir |
| 481 | do |
| 482 | eval ac_val=$`echo $ac_var` |
| 483 | case $ac_val in |
| 484 | [\\/$]* | ?:[\\/]* ) ;; |
| 485 | *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2 |
| 486 | { (exit 1); exit 1; }; };; |
| 487 | esac |
| 488 | done |
| 489 | |
| 490 | # There might be people who depend on the old broken behavior: `$host' |
| 491 | # used to hold the argument of --host etc. |
| 492 | build=$build_alias |
| 493 | host=$host_alias |
| 494 | target=$target_alias |
| 495 | |
| 496 | # FIXME: should be removed in autoconf 3.0. |
| 497 | if test "x$host_alias" != x; then |
| 498 | if test "x$build_alias" = x; then |
| 499 | cross_compiling=maybe |
| 500 | echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. |
| 501 | If a cross compiler is detected then cross compile mode will be used." >&2 |
| 502 | elif test "x$build_alias" != "x$host_alias"; then |
| 503 | cross_compiling=yes |
| 504 | fi |
| 505 | fi |
| 506 | |
| 507 | ac_tool_prefix= |
| 508 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 509 | |
| 510 | test "$silent" = yes && exec 6>/dev/null |
| 511 | |
| 512 | # Find the source files, if location was not specified. |
| 513 | if test -z "$srcdir"; then |
| 514 | ac_srcdir_defaulted=yes |
| 515 | # Try the directory containing this script, then its parent. |
| 516 | ac_prog=$0 |
| 517 | ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'` |
| 518 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 519 | srcdir=$ac_confdir |
| 520 | if test ! -r $srcdir/$ac_unique_file; then |
| 521 | srcdir=.. |
| 522 | fi |
| 523 | else |
| 524 | ac_srcdir_defaulted=no |
| 525 | fi |
| 526 | if test ! -r $srcdir/$ac_unique_file; then |
| 527 | if test "$ac_srcdir_defaulted" = yes; then |
| 528 | { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2 |
| 529 | { (exit 1); exit 1; }; } |
| 530 | else |
| 531 | { echo "$as_me: error: cannot find sources in $srcdir" >&2 |
| 532 | { (exit 1); exit 1; }; } |
| 533 | fi |
| 534 | fi |
| 535 | srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'` |
| 536 | ac_env_build_alias_set=${build_alias+set} |
| 537 | ac_env_build_alias_value=$build_alias |
| 538 | ac_cv_env_build_alias_set=${build_alias+set} |
| 539 | ac_cv_env_build_alias_value=$build_alias |
| 540 | ac_env_host_alias_set=${host_alias+set} |
| 541 | ac_env_host_alias_value=$host_alias |
| 542 | ac_cv_env_host_alias_set=${host_alias+set} |
| 543 | ac_cv_env_host_alias_value=$host_alias |
| 544 | ac_env_target_alias_set=${target_alias+set} |
| 545 | ac_env_target_alias_value=$target_alias |
| 546 | ac_cv_env_target_alias_set=${target_alias+set} |
| 547 | ac_cv_env_target_alias_value=$target_alias |
| 548 | ac_env_CC_set=${CC+set} |
| 549 | ac_env_CC_value=$CC |
| 550 | ac_cv_env_CC_set=${CC+set} |
| 551 | ac_cv_env_CC_value=$CC |
| 552 | ac_env_CFLAGS_set=${CFLAGS+set} |
| 553 | ac_env_CFLAGS_value=$CFLAGS |
| 554 | ac_cv_env_CFLAGS_set=${CFLAGS+set} |
| 555 | ac_cv_env_CFLAGS_value=$CFLAGS |
| 556 | ac_env_LDFLAGS_set=${LDFLAGS+set} |
| 557 | ac_env_LDFLAGS_value=$LDFLAGS |
| 558 | ac_cv_env_LDFLAGS_set=${LDFLAGS+set} |
| 559 | ac_cv_env_LDFLAGS_value=$LDFLAGS |
| 560 | ac_env_CPPFLAGS_set=${CPPFLAGS+set} |
| 561 | ac_env_CPPFLAGS_value=$CPPFLAGS |
| 562 | ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set} |
| 563 | ac_cv_env_CPPFLAGS_value=$CPPFLAGS |
| 564 | ac_env_CPP_set=${CPP+set} |
| 565 | ac_env_CPP_value=$CPP |
| 566 | ac_cv_env_CPP_set=${CPP+set} |
| 567 | ac_cv_env_CPP_value=$CPP |
| 568 | |
| 569 | # |
| 570 | # Report the --help message. |
| 571 | # |
| 572 | if test "$ac_init_help" = "long"; then |
| 573 | # Omit some internal or obsolete options to make the list less imposing. |
| 574 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 575 | cat <<EOF |
| 576 | \`configure' configures this package to adapt to many kinds of systems. |
| 577 | |
| 578 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 579 | |
| 580 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 581 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 582 | |
| 583 | Defaults for the options are specified in brackets. |
| 584 | |
| 585 | Configuration: |
| 586 | -h, --help display this help and exit |
| 587 | --help=short display options specific to this package |
| 588 | --help=recursive display the short help of all the included packages |
| 589 | -V, --version display version information and exit |
| 590 | -q, --quiet, --silent do not print \`checking...' messages |
| 591 | --cache-file=FILE cache test results in FILE [disabled] |
| 592 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 593 | -n, --no-create do not create output files |
| 594 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 595 | |
| 596 | EOF |
| 597 | |
| 598 | cat <<EOF |
| 599 | Installation directories: |
| 600 | --prefix=PREFIX install architecture-independent files in PREFIX |
| 601 | [$ac_default_prefix] |
| 602 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
| 603 | [PREFIX] |
| 604 | |
| 605 | By default, \`make install' will install all the files in |
| 606 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 607 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 608 | for instance \`--prefix=\$HOME'. |
| 609 | |
| 610 | For better control, use the options below. |
| 611 | |
| 612 | Fine tuning of the installation directories: |
| 613 | --bindir=DIR user executables [EPREFIX/bin] |
| 614 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 615 | --libexecdir=DIR program executables [EPREFIX/libexec] |
| 616 | --datarootdir=DIR read-only architecture-independent data [PREFIX/share] |
| 617 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
| 618 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 619 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 620 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 621 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 622 | --includedir=DIR C header files [PREFIX/include] |
| 623 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
| 624 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 625 | --mandir=DIR man documentation [DATAROOTDIR/man] |
| 626 | EOF |
| 627 | |
| 628 | cat <<\EOF |
| 629 | |
| 630 | Program names: |
| 631 | --program-prefix=PREFIX prepend PREFIX to installed program names |
| 632 | --program-suffix=SUFFIX append SUFFIX to installed program names |
| 633 | --program-transform-name=PROGRAM run sed PROGRAM on installed program names |
| 634 | |
| 635 | X features: |
| 636 | --x-includes=DIR X include files are in DIR |
| 637 | --x-libraries=DIR X library files are in DIR |
| 638 | |
| 639 | System types: |
| 640 | --build=BUILD configure for building on BUILD [guessed] |
| 641 | --host=HOST build programs to run on HOST [BUILD] |
| 642 | EOF |
| 643 | fi |
| 644 | |
| 645 | if test -n "$ac_init_help"; then |
| 646 | |
| 647 | cat <<\EOF |
| 648 | |
| 649 | Optional Packages: |
| 650 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 651 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 652 | |
| 653 | Optional Features: |
| 654 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 655 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 656 | |
| 657 | General Options: |
| 658 | --with-pkg-config{=path} enable/disable use of pkg-config |
| 659 | --disable-echo do not display "compiling" commands |
| 660 | Curses Version-dependent Options: |
| 661 | --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables |
| 662 | --disable-widec disable checks for wide-character functions |
| 663 | --with-curses-dir=DIR directory in which (n)curses is installed |
| 664 | --with-screen=XXX use specified curses-libraries |
| 665 | --with-ncursesw use wide ncurses-libraries |
| 666 | --with-ncurses use ncurses-libraries |
| 667 | --with-pdcurses compile/link with pdcurses X11 library |
| 668 | --with-curses-colr compile/link with HPUX 10.x color-curses |
| 669 | --with-curses-5lib compile/link with SunOS 5lib curses |
| 670 | --with-Xaw3d link with Xaw 3d library |
| 671 | --with-Xaw3dxft link with Xaw 3d xft library |
| 672 | --with-neXtaw link with neXT Athena library |
| 673 | --with-XawPlus link with Athena-Plus library |
| 674 | --with-x use the X Window System |
| 675 | Testing/development Options: |
| 676 | --enable-warnings test: turn on gcc compiler warnings |
| 677 | --with-dmalloc test: use Gray Watson's dmalloc library |
| 678 | --with-dbmalloc test: use Conor Cahill's dbmalloc library |
| 679 | --with-valgrind test: use valgrind |
| 680 | --disable-leaks test: free permanent memory, analyze leaks |
| 681 | --disable-rpath-hack don't add rpath options for additional libraries |
| 682 | |
| 683 | Some influential environment variables: |
| 684 | CC C compiler command |
| 685 | CFLAGS C compiler flags |
| 686 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 687 | nonstandard directory <lib dir> |
| 688 | CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have |
| 689 | headers in a nonstandard directory <include dir> |
| 690 | CPP C preprocessor |
| 691 | |
| 692 | Use these variables to override the choices made by `configure' or to help |
| 693 | it to find libraries and programs with nonstandard names/locations. |
| 694 | |
| 695 | EOF |
| 696 | fi |
| 697 | |
| 698 | if test "$ac_init_help" = "recursive"; then |
| 699 | # If there are subdirs, report their specific --help. |
| 700 | ac_popdir=`pwd` |
| 701 | for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue |
| 702 | cd $ac_subdir |
| 703 | # A "../" for each directory in /$ac_subdir. |
| 704 | ac_dots=`echo $ac_subdir | |
| 705 | sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'` |
| 706 | |
| 707 | case $srcdir in |
| 708 | .) # No --srcdir option. We are building in place. |
| 709 | ac_sub_srcdir=$srcdir ;; |
| 710 | [\\/]* | ?:[\\/]* ) # Absolute path. |
| 711 | ac_sub_srcdir=$srcdir/$ac_subdir ;; |
| 712 | *) # Relative path. |
| 713 | ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;; |
| 714 | esac |
| 715 | |
| 716 | # Check for guested configure; otherwise get Cygnus style configure. |
| 717 | if test -f $ac_sub_srcdir/configure.gnu; then |
| 718 | echo |
| 719 | $SHELL $ac_sub_srcdir/configure.gnu --help=recursive |
| 720 | elif test -f $ac_sub_srcdir/configure; then |
| 721 | echo |
| 722 | $SHELL $ac_sub_srcdir/configure --help=recursive |
| 723 | elif test -f $ac_sub_srcdir/configure.ac || |
| 724 | test -f $ac_sub_srcdir/configure.in; then |
| 725 | echo |
| 726 | $ac_configure --help |
| 727 | else |
| 728 | echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2 |
| 729 | fi |
| 730 | cd $ac_popdir |
| 731 | done |
| 732 | fi |
| 733 | |
| 734 | test -n "$ac_init_help" && exit 0 |
| 735 | if $ac_init_version; then |
| 736 | cat <<\EOF |
| 737 | |
| 738 | Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001 |
| 739 | Free Software Foundation, Inc. |
| 740 | This configure script is free software; the Free Software Foundation |
| 741 | gives unlimited permission to copy, distribute and modify it. |
| 742 | EOF |
| 743 | exit 0 |
| 744 | fi |
| 745 | exec 5>config.log |
| 746 | cat >&5 <<EOF |
| 747 | This file contains any messages produced by compilers while |
| 748 | running configure, to aid debugging if configure makes a mistake. |
| 749 | |
| 750 | It was created by $as_me, which was |
| 751 | generated by GNU Autoconf 2.52.20141204. Invocation command line was |
| 752 | |
| 753 | $ $0 $@ |
| 754 | |
| 755 | EOF |
| 756 | { |
| 757 | cat <<_ASUNAME |
| 758 | ## ---------- ## |
| 759 | ## Platform. ## |
| 760 | ## ---------- ## |
| 761 | |
| 762 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 763 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 764 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 765 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 766 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 767 | |
| 768 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 769 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 770 | |
| 771 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 772 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 773 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` |
| 774 | hostinfo = `(hostinfo) 2>/dev/null || echo unknown` |
| 775 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 776 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 777 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 778 | |
| 779 | PATH = $PATH |
| 780 | |
| 781 | _ASUNAME |
| 782 | } >&5 |
| 783 | |
| 784 | cat >&5 <<EOF |
| 785 | ## ------------ ## |
| 786 | ## Core tests. ## |
| 787 | ## ------------ ## |
| 788 | |
| 789 | EOF |
| 790 | |
| 791 | # Keep a trace of the command line. |
| 792 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 793 | # Also quote any args containing shell meta-characters. |
| 794 | ac_configure_args= |
| 795 | ac_sep= |
| 796 | for ac_arg |
| 797 | do |
| 798 | case $ac_arg in |
| 799 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 800 | | --no-cr | --no-c) ;; |
| 801 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 802 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 803 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) |
| 804 | ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` |
| 805 | ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'" |
| 806 | ac_sep=" " ;; |
| 807 | *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg" |
| 808 | ac_sep=" " ;; |
| 809 | esac |
| 810 | # Get rid of the leading space. |
| 811 | done |
| 812 | |
| 813 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 814 | # config.log. We remove comments because anyway the quotes in there |
| 815 | # would cause problems or look ugly. |
| 816 | trap 'exit_status=$? |
| 817 | # Save into config.log some information that might help in debugging. |
| 818 | echo >&5 |
| 819 | echo "## ----------------- ##" >&5 |
| 820 | echo "## Cache variables. ##" >&5 |
| 821 | echo "## ----------------- ##" >&5 |
| 822 | echo >&5 |
| 823 | # The following way of writing the cache mishandles newlines in values, |
| 824 | { |
| 825 | (set) 2>&1 | |
| 826 | case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in |
| 827 | *ac_space=\ *) |
| 828 | sed -n \ |
| 829 | "s/'"'"'/'"'"'\\\\'"'"''"'"'/g; |
| 830 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p" |
| 831 | ;; |
| 832 | *) |
| 833 | sed -n \ |
| 834 | "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" |
| 835 | ;; |
| 836 | esac; |
| 837 | } >&5 |
| 838 | sed "/^$/d" confdefs.h >conftest.log |
| 839 | if test -s conftest.log; then |
| 840 | echo >&5 |
| 841 | echo "## ------------ ##" >&5 |
| 842 | echo "## confdefs.h. ##" >&5 |
| 843 | echo "## ------------ ##" >&5 |
| 844 | echo >&5 |
| 845 | cat conftest.log >&5 |
| 846 | fi |
| 847 | (echo; echo) >&5 |
| 848 | test "$ac_signal" != 0 && |
| 849 | echo "$as_me: caught signal $ac_signal" >&5 |
| 850 | echo "$as_me: exit $exit_status" >&5 |
| 851 | rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files && |
| 852 | exit $exit_status |
| 853 | ' 0 |
| 854 | for ac_signal in 1 2 13 15; do |
| 855 | trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal |
| 856 | done |
| 857 | ac_signal=0 |
| 858 | |
| 859 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 860 | rm -rf conftest* confdefs.h |
| 861 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 862 | echo >confdefs.h |
| 863 | |
| 864 | # Let the site file select an alternate cache file if it wants to. |
| 865 | # Prefer explicitly selected file to automatically selected ones. |
| 866 | if test -z "$CONFIG_SITE"; then |
| 867 | if test "x$prefix" != xNONE; then |
| 868 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 869 | else |
| 870 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 871 | fi |
| 872 | fi |
| 873 | for ac_site_file in $CONFIG_SITE; do |
| 874 | if test -r "$ac_site_file"; then |
| 875 | { echo "$as_me:875: loading site script $ac_site_file" >&5 |
| 876 | echo "$as_me: loading site script $ac_site_file" >&6;} |
| 877 | cat "$ac_site_file" >&5 |
| 878 | . "$ac_site_file" |
| 879 | fi |
| 880 | done |
| 881 | |
| 882 | if test -r "$cache_file"; then |
| 883 | # Some versions of bash will fail to source /dev/null (special |
| 884 | # files actually), so we avoid doing that. |
| 885 | if test -f "$cache_file"; then |
| 886 | { echo "$as_me:886: loading cache $cache_file" >&5 |
| 887 | echo "$as_me: loading cache $cache_file" >&6;} |
| 888 | case $cache_file in |
| 889 | [\\/]* | ?:[\\/]* ) . $cache_file;; |
| 890 | *) . ./$cache_file;; |
| 891 | esac |
| 892 | fi |
| 893 | else |
| 894 | { echo "$as_me:894: creating cache $cache_file" >&5 |
| 895 | echo "$as_me: creating cache $cache_file" >&6;} |
| 896 | >$cache_file |
| 897 | fi |
| 898 | |
| 899 | # Check that the precious variables saved in the cache have kept the same |
| 900 | # value. |
| 901 | ac_cache_corrupted=false |
| 902 | for ac_var in `(set) 2>&1 | |
| 903 | sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do |
| 904 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 905 | eval ac_new_set=\$ac_env_${ac_var}_set |
| 906 | eval ac_old_val="\$ac_cv_env_${ac_var}_value" |
| 907 | eval ac_new_val="\$ac_env_${ac_var}_value" |
| 908 | case $ac_old_set,$ac_new_set in |
| 909 | set,) |
| 910 | { echo "$as_me:910: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
| 911 | echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} |
| 912 | ac_cache_corrupted=: ;; |
| 913 | ,set) |
| 914 | { echo "$as_me:914: error: \`$ac_var' was not set in the previous run" >&5 |
| 915 | echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} |
| 916 | ac_cache_corrupted=: ;; |
| 917 | ,);; |
| 918 | *) |
| 919 | if test "x$ac_old_val" != "x$ac_new_val"; then |
| 920 | { echo "$as_me:920: error: \`$ac_var' has changed since the previous run:" >&5 |
| 921 | echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
| 922 | { echo "$as_me:922: former value: $ac_old_val" >&5 |
| 923 | echo "$as_me: former value: $ac_old_val" >&2;} |
| 924 | { echo "$as_me:924: current value: $ac_new_val" >&5 |
| 925 | echo "$as_me: current value: $ac_new_val" >&2;} |
| 926 | ac_cache_corrupted=: |
| 927 | fi;; |
| 928 | esac |
| 929 | # Pass precious variables to config.status. It doesn't matter if |
| 930 | # we pass some twice (in addition to the command line arguments). |
| 931 | if test "$ac_new_set" = set; then |
| 932 | case $ac_new_val in |
| 933 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) |
| 934 | ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` |
| 935 | ac_configure_args="$ac_configure_args '$ac_arg'" |
| 936 | ;; |
| 937 | *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val" |
| 938 | ;; |
| 939 | esac |
| 940 | fi |
| 941 | done |
| 942 | if $ac_cache_corrupted; then |
| 943 | { echo "$as_me:943: error: changes in the environment can compromise the build" >&5 |
| 944 | echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
| 945 | { { echo "$as_me:945: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 |
| 946 | echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} |
| 947 | { (exit 1); exit 1; }; } |
| 948 | fi |
| 949 | |
| 950 | ac_ext=c |
| 951 | ac_cpp='$CPP $CPPFLAGS' |
| 952 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 953 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 954 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 955 | ac_main_return=return |
| 956 | |
| 957 | case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in |
| 958 | *c*,-n*) ECHO_N= ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway |
| 959 | ECHO_T=' ' ;; |
| 960 | *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;; |
| 961 | *) ECHO_N= ECHO_C='\c' ECHO_T= ;; |
| 962 | esac |
| 963 | echo "#! $SHELL" >conftest.sh |
| 964 | echo "exit 0" >>conftest.sh |
| 965 | chmod +x conftest.sh |
| 966 | if { (echo "$as_me:966: PATH=\".;.\"; conftest.sh") >&5 |
| 967 | (PATH=".;."; conftest.sh) 2>&5 |
| 968 | ac_status=$? |
| 969 | echo "$as_me:969: \$? = $ac_status" >&5 |
| 970 | (exit $ac_status); }; then |
| 971 | ac_path_separator=';' |
| 972 | else |
| 973 | ac_path_separator=: |
| 974 | fi |
| 975 | PATH_SEPARATOR="$ac_path_separator" |
| 976 | rm -f conftest.sh |
| 977 | |
| 978 | ac_config_headers="$ac_config_headers ncurses_cfg.h:ncurses_tst.hin" |
| 979 | |
| 980 | test -f config.guess || ( test -f ../config.guess && cp ../config.guess ./ ) |
| 981 | |
| 982 | test -f config.sub || ( test -f ../config.sub && cp ../config.sub ./ ) |
| 983 | |
| 984 | ac_aux_dir= |
| 985 | for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do |
| 986 | if test -f $ac_dir/install-sh; then |
| 987 | ac_aux_dir=$ac_dir |
| 988 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 989 | break |
| 990 | elif test -f $ac_dir/install.sh; then |
| 991 | ac_aux_dir=$ac_dir |
| 992 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 993 | break |
| 994 | elif test -f $ac_dir/shtool; then |
| 995 | ac_aux_dir=$ac_dir |
| 996 | ac_install_sh="$ac_aux_dir/shtool install -c" |
| 997 | break |
| 998 | fi |
| 999 | done |
| 1000 | if test -z "$ac_aux_dir"; then |
| 1001 | { { echo "$as_me:1001: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5 |
| 1002 | echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;} |
| 1003 | { (exit 1); exit 1; }; } |
| 1004 | fi |
| 1005 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" |
| 1006 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" |
| 1007 | ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure. |
| 1008 | |
| 1009 | # Make sure we can run config.sub. |
| 1010 | $ac_config_sub sun4 >/dev/null 2>&1 || |
| 1011 | { { echo "$as_me:1011: error: cannot run $ac_config_sub" >&5 |
| 1012 | echo "$as_me: error: cannot run $ac_config_sub" >&2;} |
| 1013 | { (exit 1); exit 1; }; } |
| 1014 | |
| 1015 | echo "$as_me:1015: checking build system type" >&5 |
| 1016 | echo $ECHO_N "checking build system type... $ECHO_C" >&6 |
| 1017 | if test "${ac_cv_build+set}" = set; then |
| 1018 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1019 | else |
| 1020 | ac_cv_build_alias=$build_alias |
| 1021 | test -z "$ac_cv_build_alias" && |
| 1022 | ac_cv_build_alias=`$ac_config_guess` |
| 1023 | test -z "$ac_cv_build_alias" && |
| 1024 | { { echo "$as_me:1024: error: cannot guess build type; you must specify one" >&5 |
| 1025 | echo "$as_me: error: cannot guess build type; you must specify one" >&2;} |
| 1026 | { (exit 1); exit 1; }; } |
| 1027 | ac_cv_build=`$ac_config_sub $ac_cv_build_alias` || |
| 1028 | { { echo "$as_me:1028: error: $ac_config_sub $ac_cv_build_alias failed." >&5 |
| 1029 | echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;} |
| 1030 | { (exit 1); exit 1; }; } |
| 1031 | |
| 1032 | fi |
| 1033 | echo "$as_me:1033: result: $ac_cv_build" >&5 |
| 1034 | echo "${ECHO_T}$ac_cv_build" >&6 |
| 1035 | build=$ac_cv_build |
| 1036 | build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
| 1037 | build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` |
| 1038 | build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` |
| 1039 | |
| 1040 | if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then |
| 1041 | echo "$as_me:1041: checking host system type" >&5 |
| 1042 | echo $ECHO_N "checking host system type... $ECHO_C" >&6 |
| 1043 | if test "${ac_cv_host+set}" = set; then |
| 1044 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1045 | else |
| 1046 | ac_cv_host_alias=$host_alias |
| 1047 | test -z "$ac_cv_host_alias" && |
| 1048 | ac_cv_host_alias=$ac_cv_build_alias |
| 1049 | ac_cv_host=`$ac_config_sub $ac_cv_host_alias` || |
| 1050 | { { echo "$as_me:1050: error: $ac_config_sub $ac_cv_host_alias failed" >&5 |
| 1051 | echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;} |
| 1052 | { (exit 1); exit 1; }; } |
| 1053 | |
| 1054 | fi |
| 1055 | echo "$as_me:1055: result: $ac_cv_host" >&5 |
| 1056 | echo "${ECHO_T}$ac_cv_host" >&6 |
| 1057 | host=$ac_cv_host |
| 1058 | host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
| 1059 | host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` |
| 1060 | host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` |
| 1061 | |
| 1062 | system_name="$host_os" |
| 1063 | else |
| 1064 | system_name="`(uname -s -r) 2>/dev/null`" |
| 1065 | if test -z "$system_name" ; then |
| 1066 | system_name="`(hostname) 2>/dev/null`" |
| 1067 | fi |
| 1068 | fi |
| 1069 | test -n "$system_name" && |
| 1070 | cat >>confdefs.h <<EOF |
| 1071 | #define SYSTEM_NAME "$system_name" |
| 1072 | EOF |
| 1073 | |
| 1074 | if test "${cf_cv_system_name+set}" = set; then |
| 1075 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1076 | else |
| 1077 | cf_cv_system_name="$system_name" |
| 1078 | fi |
| 1079 | |
| 1080 | test -z "$system_name" && system_name="$cf_cv_system_name" |
| 1081 | test -n "$cf_cv_system_name" && echo "$as_me:1081: result: Configuring for $cf_cv_system_name" >&5 |
| 1082 | echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6 |
| 1083 | |
| 1084 | if test ".$system_name" != ".$cf_cv_system_name" ; then |
| 1085 | echo "$as_me:1085: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5 |
| 1086 | echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6 |
| 1087 | { { echo "$as_me:1087: error: \"Please remove config.cache and try again.\"" >&5 |
| 1088 | echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;} |
| 1089 | { (exit 1); exit 1; }; } |
| 1090 | fi |
| 1091 | |
| 1092 | test "$program_prefix" != NONE && |
| 1093 | program_transform_name="s,^,$program_prefix,;$program_transform_name" |
| 1094 | # Use a double $ so make ignores it. |
| 1095 | test "$program_suffix" != NONE && |
| 1096 | program_transform_name="s,\$,$program_suffix,;$program_transform_name" |
| 1097 | # Double any \ or $. echo might interpret backslashes. |
| 1098 | # By default was `s,x,x', remove it if useless. |
| 1099 | cat <<\_ACEOF >conftest.sed |
| 1100 | s/[\\$]/&&/g;s/;s,x,x,$// |
| 1101 | _ACEOF |
| 1102 | program_transform_name=`echo $program_transform_name | sed -f conftest.sed` |
| 1103 | rm conftest.sed |
| 1104 | |
| 1105 | echo "$as_me:1105: checking whether ${MAKE-make} sets \${MAKE}" >&5 |
| 1106 | echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6 |
| 1107 | set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'` |
| 1108 | if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then |
| 1109 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1110 | else |
| 1111 | cat >conftest.make <<\EOF |
| 1112 | all: |
| 1113 | @echo 'ac_maketemp="${MAKE}"' |
| 1114 | EOF |
| 1115 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. |
| 1116 | eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=` |
| 1117 | if test -n "$ac_maketemp"; then |
| 1118 | eval ac_cv_prog_make_${ac_make}_set=yes |
| 1119 | else |
| 1120 | eval ac_cv_prog_make_${ac_make}_set=no |
| 1121 | fi |
| 1122 | rm -f conftest.make |
| 1123 | fi |
| 1124 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then |
| 1125 | echo "$as_me:1125: result: yes" >&5 |
| 1126 | echo "${ECHO_T}yes" >&6 |
| 1127 | SET_MAKE= |
| 1128 | else |
| 1129 | echo "$as_me:1129: result: no" >&5 |
| 1130 | echo "${ECHO_T}no" >&6 |
| 1131 | SET_MAKE="MAKE=${MAKE-make}" |
| 1132 | fi |
| 1133 | |
| 1134 | ac_ext=c |
| 1135 | ac_cpp='$CPP $CPPFLAGS' |
| 1136 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 1137 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 1138 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 1139 | ac_main_return=return |
| 1140 | if test -n "$ac_tool_prefix"; then |
| 1141 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
| 1142 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
| 1143 | echo "$as_me:1143: checking for $ac_word" >&5 |
| 1144 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1145 | if test "${ac_cv_prog_CC+set}" = set; then |
| 1146 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1147 | else |
| 1148 | if test -n "$CC"; then |
| 1149 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 1150 | else |
| 1151 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1152 | ac_dummy="$PATH" |
| 1153 | for ac_dir in $ac_dummy; do |
| 1154 | IFS=$ac_save_IFS |
| 1155 | test -z "$ac_dir" && ac_dir=. |
| 1156 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1157 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
| 1158 | echo "$as_me:1158: found $ac_dir/$ac_word" >&5 |
| 1159 | break |
| 1160 | done |
| 1161 | |
| 1162 | fi |
| 1163 | fi |
| 1164 | CC=$ac_cv_prog_CC |
| 1165 | if test -n "$CC"; then |
| 1166 | echo "$as_me:1166: result: $CC" >&5 |
| 1167 | echo "${ECHO_T}$CC" >&6 |
| 1168 | else |
| 1169 | echo "$as_me:1169: result: no" >&5 |
| 1170 | echo "${ECHO_T}no" >&6 |
| 1171 | fi |
| 1172 | |
| 1173 | fi |
| 1174 | if test -z "$ac_cv_prog_CC"; then |
| 1175 | ac_ct_CC=$CC |
| 1176 | # Extract the first word of "gcc", so it can be a program name with args. |
| 1177 | set dummy gcc; ac_word=$2 |
| 1178 | echo "$as_me:1178: checking for $ac_word" >&5 |
| 1179 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1180 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then |
| 1181 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1182 | else |
| 1183 | if test -n "$ac_ct_CC"; then |
| 1184 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 1185 | else |
| 1186 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1187 | ac_dummy="$PATH" |
| 1188 | for ac_dir in $ac_dummy; do |
| 1189 | IFS=$ac_save_IFS |
| 1190 | test -z "$ac_dir" && ac_dir=. |
| 1191 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1192 | ac_cv_prog_ac_ct_CC="gcc" |
| 1193 | echo "$as_me:1193: found $ac_dir/$ac_word" >&5 |
| 1194 | break |
| 1195 | done |
| 1196 | |
| 1197 | fi |
| 1198 | fi |
| 1199 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 1200 | if test -n "$ac_ct_CC"; then |
| 1201 | echo "$as_me:1201: result: $ac_ct_CC" >&5 |
| 1202 | echo "${ECHO_T}$ac_ct_CC" >&6 |
| 1203 | else |
| 1204 | echo "$as_me:1204: result: no" >&5 |
| 1205 | echo "${ECHO_T}no" >&6 |
| 1206 | fi |
| 1207 | |
| 1208 | CC=$ac_ct_CC |
| 1209 | else |
| 1210 | CC="$ac_cv_prog_CC" |
| 1211 | fi |
| 1212 | |
| 1213 | if test -z "$CC"; then |
| 1214 | if test -n "$ac_tool_prefix"; then |
| 1215 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. |
| 1216 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
| 1217 | echo "$as_me:1217: checking for $ac_word" >&5 |
| 1218 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1219 | if test "${ac_cv_prog_CC+set}" = set; then |
| 1220 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1221 | else |
| 1222 | if test -n "$CC"; then |
| 1223 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 1224 | else |
| 1225 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1226 | ac_dummy="$PATH" |
| 1227 | for ac_dir in $ac_dummy; do |
| 1228 | IFS=$ac_save_IFS |
| 1229 | test -z "$ac_dir" && ac_dir=. |
| 1230 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1231 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
| 1232 | echo "$as_me:1232: found $ac_dir/$ac_word" >&5 |
| 1233 | break |
| 1234 | done |
| 1235 | |
| 1236 | fi |
| 1237 | fi |
| 1238 | CC=$ac_cv_prog_CC |
| 1239 | if test -n "$CC"; then |
| 1240 | echo "$as_me:1240: result: $CC" >&5 |
| 1241 | echo "${ECHO_T}$CC" >&6 |
| 1242 | else |
| 1243 | echo "$as_me:1243: result: no" >&5 |
| 1244 | echo "${ECHO_T}no" >&6 |
| 1245 | fi |
| 1246 | |
| 1247 | fi |
| 1248 | if test -z "$ac_cv_prog_CC"; then |
| 1249 | ac_ct_CC=$CC |
| 1250 | # Extract the first word of "cc", so it can be a program name with args. |
| 1251 | set dummy cc; ac_word=$2 |
| 1252 | echo "$as_me:1252: checking for $ac_word" >&5 |
| 1253 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1254 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then |
| 1255 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1256 | else |
| 1257 | if test -n "$ac_ct_CC"; then |
| 1258 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 1259 | else |
| 1260 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1261 | ac_dummy="$PATH" |
| 1262 | for ac_dir in $ac_dummy; do |
| 1263 | IFS=$ac_save_IFS |
| 1264 | test -z "$ac_dir" && ac_dir=. |
| 1265 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1266 | ac_cv_prog_ac_ct_CC="cc" |
| 1267 | echo "$as_me:1267: found $ac_dir/$ac_word" >&5 |
| 1268 | break |
| 1269 | done |
| 1270 | |
| 1271 | fi |
| 1272 | fi |
| 1273 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 1274 | if test -n "$ac_ct_CC"; then |
| 1275 | echo "$as_me:1275: result: $ac_ct_CC" >&5 |
| 1276 | echo "${ECHO_T}$ac_ct_CC" >&6 |
| 1277 | else |
| 1278 | echo "$as_me:1278: result: no" >&5 |
| 1279 | echo "${ECHO_T}no" >&6 |
| 1280 | fi |
| 1281 | |
| 1282 | CC=$ac_ct_CC |
| 1283 | else |
| 1284 | CC="$ac_cv_prog_CC" |
| 1285 | fi |
| 1286 | |
| 1287 | fi |
| 1288 | if test -z "$CC"; then |
| 1289 | # Extract the first word of "cc", so it can be a program name with args. |
| 1290 | set dummy cc; ac_word=$2 |
| 1291 | echo "$as_me:1291: checking for $ac_word" >&5 |
| 1292 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1293 | if test "${ac_cv_prog_CC+set}" = set; then |
| 1294 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1295 | else |
| 1296 | if test -n "$CC"; then |
| 1297 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 1298 | else |
| 1299 | ac_prog_rejected=no |
| 1300 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1301 | ac_dummy="$PATH" |
| 1302 | for ac_dir in $ac_dummy; do |
| 1303 | IFS=$ac_save_IFS |
| 1304 | test -z "$ac_dir" && ac_dir=. |
| 1305 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1306 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
| 1307 | ac_prog_rejected=yes |
| 1308 | continue |
| 1309 | fi |
| 1310 | ac_cv_prog_CC="cc" |
| 1311 | echo "$as_me:1311: found $ac_dir/$ac_word" >&5 |
| 1312 | break |
| 1313 | done |
| 1314 | |
| 1315 | if test $ac_prog_rejected = yes; then |
| 1316 | # We found a bogon in the path, so make sure we never use it. |
| 1317 | set dummy $ac_cv_prog_CC |
| 1318 | shift |
| 1319 | if test $# != 0; then |
| 1320 | # We chose a different compiler from the bogus one. |
| 1321 | # However, it has the same basename, so the bogon will be chosen |
| 1322 | # first if we set CC to just the basename; use the full file name. |
| 1323 | shift |
| 1324 | set dummy "$ac_dir/$ac_word" ${1+"$@"} |
| 1325 | shift |
| 1326 | ac_cv_prog_CC="$@" |
| 1327 | fi |
| 1328 | fi |
| 1329 | fi |
| 1330 | fi |
| 1331 | CC=$ac_cv_prog_CC |
| 1332 | if test -n "$CC"; then |
| 1333 | echo "$as_me:1333: result: $CC" >&5 |
| 1334 | echo "${ECHO_T}$CC" >&6 |
| 1335 | else |
| 1336 | echo "$as_me:1336: result: no" >&5 |
| 1337 | echo "${ECHO_T}no" >&6 |
| 1338 | fi |
| 1339 | |
| 1340 | fi |
| 1341 | if test -z "$CC"; then |
| 1342 | if test -n "$ac_tool_prefix"; then |
| 1343 | for ac_prog in cl |
| 1344 | do |
| 1345 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 1346 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
| 1347 | echo "$as_me:1347: checking for $ac_word" >&5 |
| 1348 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1349 | if test "${ac_cv_prog_CC+set}" = set; then |
| 1350 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1351 | else |
| 1352 | if test -n "$CC"; then |
| 1353 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 1354 | else |
| 1355 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1356 | ac_dummy="$PATH" |
| 1357 | for ac_dir in $ac_dummy; do |
| 1358 | IFS=$ac_save_IFS |
| 1359 | test -z "$ac_dir" && ac_dir=. |
| 1360 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1361 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
| 1362 | echo "$as_me:1362: found $ac_dir/$ac_word" >&5 |
| 1363 | break |
| 1364 | done |
| 1365 | |
| 1366 | fi |
| 1367 | fi |
| 1368 | CC=$ac_cv_prog_CC |
| 1369 | if test -n "$CC"; then |
| 1370 | echo "$as_me:1370: result: $CC" >&5 |
| 1371 | echo "${ECHO_T}$CC" >&6 |
| 1372 | else |
| 1373 | echo "$as_me:1373: result: no" >&5 |
| 1374 | echo "${ECHO_T}no" >&6 |
| 1375 | fi |
| 1376 | |
| 1377 | test -n "$CC" && break |
| 1378 | done |
| 1379 | fi |
| 1380 | if test -z "$CC"; then |
| 1381 | ac_ct_CC=$CC |
| 1382 | for ac_prog in cl |
| 1383 | do |
| 1384 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 1385 | set dummy $ac_prog; ac_word=$2 |
| 1386 | echo "$as_me:1386: checking for $ac_word" >&5 |
| 1387 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1388 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then |
| 1389 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1390 | else |
| 1391 | if test -n "$ac_ct_CC"; then |
| 1392 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 1393 | else |
| 1394 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1395 | ac_dummy="$PATH" |
| 1396 | for ac_dir in $ac_dummy; do |
| 1397 | IFS=$ac_save_IFS |
| 1398 | test -z "$ac_dir" && ac_dir=. |
| 1399 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1400 | ac_cv_prog_ac_ct_CC="$ac_prog" |
| 1401 | echo "$as_me:1401: found $ac_dir/$ac_word" >&5 |
| 1402 | break |
| 1403 | done |
| 1404 | |
| 1405 | fi |
| 1406 | fi |
| 1407 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 1408 | if test -n "$ac_ct_CC"; then |
| 1409 | echo "$as_me:1409: result: $ac_ct_CC" >&5 |
| 1410 | echo "${ECHO_T}$ac_ct_CC" >&6 |
| 1411 | else |
| 1412 | echo "$as_me:1412: result: no" >&5 |
| 1413 | echo "${ECHO_T}no" >&6 |
| 1414 | fi |
| 1415 | |
| 1416 | test -n "$ac_ct_CC" && break |
| 1417 | done |
| 1418 | |
| 1419 | CC=$ac_ct_CC |
| 1420 | fi |
| 1421 | |
| 1422 | fi |
| 1423 | |
| 1424 | test -z "$CC" && { { echo "$as_me:1424: error: no acceptable cc found in \$PATH" >&5 |
| 1425 | echo "$as_me: error: no acceptable cc found in \$PATH" >&2;} |
| 1426 | { (exit 1); exit 1; }; } |
| 1427 | |
| 1428 | # Provide some information about the compiler. |
| 1429 | echo "$as_me:1429:" \ |
| 1430 | "checking for C compiler version" >&5 |
| 1431 | ac_compiler=`set X $ac_compile; echo $2` |
| 1432 | { (eval echo "$as_me:1432: \"$ac_compiler --version </dev/null >&5\"") >&5 |
| 1433 | (eval $ac_compiler --version </dev/null >&5) 2>&5 |
| 1434 | ac_status=$? |
| 1435 | echo "$as_me:1435: \$? = $ac_status" >&5 |
| 1436 | (exit $ac_status); } |
| 1437 | { (eval echo "$as_me:1437: \"$ac_compiler -v </dev/null >&5\"") >&5 |
| 1438 | (eval $ac_compiler -v </dev/null >&5) 2>&5 |
| 1439 | ac_status=$? |
| 1440 | echo "$as_me:1440: \$? = $ac_status" >&5 |
| 1441 | (exit $ac_status); } |
| 1442 | { (eval echo "$as_me:1442: \"$ac_compiler -V </dev/null >&5\"") >&5 |
| 1443 | (eval $ac_compiler -V </dev/null >&5) 2>&5 |
| 1444 | ac_status=$? |
| 1445 | echo "$as_me:1445: \$? = $ac_status" >&5 |
| 1446 | (exit $ac_status); } |
| 1447 | |
| 1448 | cat >conftest.$ac_ext <<_ACEOF |
| 1449 | #line 1449 "configure" |
| 1450 | #include "confdefs.h" |
| 1451 | |
| 1452 | int |
| 1453 | main () |
| 1454 | { |
| 1455 | |
| 1456 | ; |
| 1457 | return 0; |
| 1458 | } |
| 1459 | _ACEOF |
| 1460 | ac_clean_files_save=$ac_clean_files |
| 1461 | ac_clean_files="$ac_clean_files a.out a.exe" |
| 1462 | # Try to create an executable without -o first, disregard a.out. |
| 1463 | # It will help us diagnose broken compilers, and finding out an intuition |
| 1464 | # of exeext. |
| 1465 | echo "$as_me:1465: checking for C compiler default output" >&5 |
| 1466 | echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6 |
| 1467 | ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
| 1468 | if { (eval echo "$as_me:1468: \"$ac_link_default\"") >&5 |
| 1469 | (eval $ac_link_default) 2>&5 |
| 1470 | ac_status=$? |
| 1471 | echo "$as_me:1471: \$? = $ac_status" >&5 |
| 1472 | (exit $ac_status); }; then |
| 1473 | # Find the output, starting from the most likely. This scheme is |
| 1474 | # not robust to junk in `.', hence go to wildcards (a.*) only as a last |
| 1475 | # resort. |
| 1476 | for ac_file in `ls a.exe conftest.exe 2>/dev/null; |
| 1477 | ls a.out conftest 2>/dev/null; |
| 1478 | ls a.* conftest.* 2>/dev/null`; do |
| 1479 | case $ac_file in |
| 1480 | *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; |
| 1481 | a.out ) # We found the default executable, but exeext='' is most |
| 1482 | # certainly right. |
| 1483 | break;; |
| 1484 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 1485 | # FIXME: I believe we export ac_cv_exeext for Libtool --akim. |
| 1486 | export ac_cv_exeext |
| 1487 | break;; |
| 1488 | * ) break;; |
| 1489 | esac |
| 1490 | done |
| 1491 | else |
| 1492 | echo "$as_me: failed program was:" >&5 |
| 1493 | cat conftest.$ac_ext >&5 |
| 1494 | { { echo "$as_me:1494: error: C compiler cannot create executables" >&5 |
| 1495 | echo "$as_me: error: C compiler cannot create executables" >&2;} |
| 1496 | { (exit 77); exit 77; }; } |
| 1497 | fi |
| 1498 | |
| 1499 | ac_exeext=$ac_cv_exeext |
| 1500 | echo "$as_me:1500: result: $ac_file" >&5 |
| 1501 | echo "${ECHO_T}$ac_file" >&6 |
| 1502 | |
| 1503 | # Check the compiler produces executables we can run. If not, either |
| 1504 | # the compiler is broken, or we cross compile. |
| 1505 | echo "$as_me:1505: checking whether the C compiler works" >&5 |
| 1506 | echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6 |
| 1507 | # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 |
| 1508 | # If not cross compiling, check that we can run a simple program. |
| 1509 | if test "$cross_compiling" != yes; then |
| 1510 | if { ac_try='./$ac_file' |
| 1511 | { (eval echo "$as_me:1511: \"$ac_try\"") >&5 |
| 1512 | (eval $ac_try) 2>&5 |
| 1513 | ac_status=$? |
| 1514 | echo "$as_me:1514: \$? = $ac_status" >&5 |
| 1515 | (exit $ac_status); }; }; then |
| 1516 | cross_compiling=no |
| 1517 | else |
| 1518 | if test "$cross_compiling" = maybe; then |
| 1519 | cross_compiling=yes |
| 1520 | else |
| 1521 | { { echo "$as_me:1521: error: cannot run C compiled programs. |
| 1522 | If you meant to cross compile, use \`--host'." >&5 |
| 1523 | echo "$as_me: error: cannot run C compiled programs. |
| 1524 | If you meant to cross compile, use \`--host'." >&2;} |
| 1525 | { (exit 1); exit 1; }; } |
| 1526 | fi |
| 1527 | fi |
| 1528 | fi |
| 1529 | echo "$as_me:1529: result: yes" >&5 |
| 1530 | echo "${ECHO_T}yes" >&6 |
| 1531 | |
| 1532 | rm -f a.out a.exe conftest$ac_cv_exeext |
| 1533 | ac_clean_files=$ac_clean_files_save |
| 1534 | # Check the compiler produces executables we can run. If not, either |
| 1535 | # the compiler is broken, or we cross compile. |
| 1536 | echo "$as_me:1536: checking whether we are cross compiling" >&5 |
| 1537 | echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6 |
| 1538 | echo "$as_me:1538: result: $cross_compiling" >&5 |
| 1539 | echo "${ECHO_T}$cross_compiling" >&6 |
| 1540 | |
| 1541 | echo "$as_me:1541: checking for executable suffix" >&5 |
| 1542 | echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6 |
| 1543 | if { (eval echo "$as_me:1543: \"$ac_link\"") >&5 |
| 1544 | (eval $ac_link) 2>&5 |
| 1545 | ac_status=$? |
| 1546 | echo "$as_me:1546: \$? = $ac_status" >&5 |
| 1547 | (exit $ac_status); }; then |
| 1548 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 1549 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 1550 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 1551 | # `rm'. |
| 1552 | for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do |
| 1553 | case $ac_file in |
| 1554 | *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; |
| 1555 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 1556 | export ac_cv_exeext |
| 1557 | break;; |
| 1558 | * ) break;; |
| 1559 | esac |
| 1560 | done |
| 1561 | else |
| 1562 | { { echo "$as_me:1562: error: cannot compute EXEEXT: cannot compile and link" >&5 |
| 1563 | echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;} |
| 1564 | { (exit 1); exit 1; }; } |
| 1565 | fi |
| 1566 | |
| 1567 | rm -f conftest$ac_cv_exeext |
| 1568 | echo "$as_me:1568: result: $ac_cv_exeext" >&5 |
| 1569 | echo "${ECHO_T}$ac_cv_exeext" >&6 |
| 1570 | |
| 1571 | rm -f conftest.$ac_ext |
| 1572 | EXEEXT=$ac_cv_exeext |
| 1573 | ac_exeext=$EXEEXT |
| 1574 | echo "$as_me:1574: checking for object suffix" >&5 |
| 1575 | echo $ECHO_N "checking for object suffix... $ECHO_C" >&6 |
| 1576 | if test "${ac_cv_objext+set}" = set; then |
| 1577 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1578 | else |
| 1579 | cat >conftest.$ac_ext <<_ACEOF |
| 1580 | #line 1580 "configure" |
| 1581 | #include "confdefs.h" |
| 1582 | |
| 1583 | int |
| 1584 | main () |
| 1585 | { |
| 1586 | |
| 1587 | ; |
| 1588 | return 0; |
| 1589 | } |
| 1590 | _ACEOF |
| 1591 | rm -f conftest.o conftest.obj |
| 1592 | if { (eval echo "$as_me:1592: \"$ac_compile\"") >&5 |
| 1593 | (eval $ac_compile) 2>&5 |
| 1594 | ac_status=$? |
| 1595 | echo "$as_me:1595: \$? = $ac_status" >&5 |
| 1596 | (exit $ac_status); }; then |
| 1597 | for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do |
| 1598 | case $ac_file in |
| 1599 | *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;; |
| 1600 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 1601 | break;; |
| 1602 | esac |
| 1603 | done |
| 1604 | else |
| 1605 | echo "$as_me: failed program was:" >&5 |
| 1606 | cat conftest.$ac_ext >&5 |
| 1607 | { { echo "$as_me:1607: error: cannot compute OBJEXT: cannot compile" >&5 |
| 1608 | echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;} |
| 1609 | { (exit 1); exit 1; }; } |
| 1610 | fi |
| 1611 | |
| 1612 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
| 1613 | fi |
| 1614 | echo "$as_me:1614: result: $ac_cv_objext" >&5 |
| 1615 | echo "${ECHO_T}$ac_cv_objext" >&6 |
| 1616 | OBJEXT=$ac_cv_objext |
| 1617 | ac_objext=$OBJEXT |
| 1618 | echo "$as_me:1618: checking whether we are using the GNU C compiler" >&5 |
| 1619 | echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6 |
| 1620 | if test "${ac_cv_c_compiler_gnu+set}" = set; then |
| 1621 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1622 | else |
| 1623 | cat >conftest.$ac_ext <<_ACEOF |
| 1624 | #line 1624 "configure" |
| 1625 | #include "confdefs.h" |
| 1626 | |
| 1627 | int |
| 1628 | main () |
| 1629 | { |
| 1630 | #ifndef __GNUC__ |
| 1631 | choke me |
| 1632 | #endif |
| 1633 | |
| 1634 | ; |
| 1635 | return 0; |
| 1636 | } |
| 1637 | _ACEOF |
| 1638 | rm -f conftest.$ac_objext |
| 1639 | if { (eval echo "$as_me:1639: \"$ac_compile\"") >&5 |
| 1640 | (eval $ac_compile) 2>&5 |
| 1641 | ac_status=$? |
| 1642 | echo "$as_me:1642: \$? = $ac_status" >&5 |
| 1643 | (exit $ac_status); } && |
| 1644 | { ac_try='test -s conftest.$ac_objext' |
| 1645 | { (eval echo "$as_me:1645: \"$ac_try\"") >&5 |
| 1646 | (eval $ac_try) 2>&5 |
| 1647 | ac_status=$? |
| 1648 | echo "$as_me:1648: \$? = $ac_status" >&5 |
| 1649 | (exit $ac_status); }; }; then |
| 1650 | ac_compiler_gnu=yes |
| 1651 | else |
| 1652 | echo "$as_me: failed program was:" >&5 |
| 1653 | cat conftest.$ac_ext >&5 |
| 1654 | ac_compiler_gnu=no |
| 1655 | fi |
| 1656 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 1657 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 1658 | |
| 1659 | fi |
| 1660 | echo "$as_me:1660: result: $ac_cv_c_compiler_gnu" >&5 |
| 1661 | echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6 |
| 1662 | GCC=`test $ac_compiler_gnu = yes && echo yes` |
| 1663 | ac_test_CFLAGS=${CFLAGS+set} |
| 1664 | ac_save_CFLAGS=$CFLAGS |
| 1665 | CFLAGS="-g" |
| 1666 | echo "$as_me:1666: checking whether $CC accepts -g" >&5 |
| 1667 | echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6 |
| 1668 | if test "${ac_cv_prog_cc_g+set}" = set; then |
| 1669 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1670 | else |
| 1671 | cat >conftest.$ac_ext <<_ACEOF |
| 1672 | #line 1672 "configure" |
| 1673 | #include "confdefs.h" |
| 1674 | |
| 1675 | int |
| 1676 | main () |
| 1677 | { |
| 1678 | |
| 1679 | ; |
| 1680 | return 0; |
| 1681 | } |
| 1682 | _ACEOF |
| 1683 | rm -f conftest.$ac_objext |
| 1684 | if { (eval echo "$as_me:1684: \"$ac_compile\"") >&5 |
| 1685 | (eval $ac_compile) 2>&5 |
| 1686 | ac_status=$? |
| 1687 | echo "$as_me:1687: \$? = $ac_status" >&5 |
| 1688 | (exit $ac_status); } && |
| 1689 | { ac_try='test -s conftest.$ac_objext' |
| 1690 | { (eval echo "$as_me:1690: \"$ac_try\"") >&5 |
| 1691 | (eval $ac_try) 2>&5 |
| 1692 | ac_status=$? |
| 1693 | echo "$as_me:1693: \$? = $ac_status" >&5 |
| 1694 | (exit $ac_status); }; }; then |
| 1695 | ac_cv_prog_cc_g=yes |
| 1696 | else |
| 1697 | echo "$as_me: failed program was:" >&5 |
| 1698 | cat conftest.$ac_ext >&5 |
| 1699 | ac_cv_prog_cc_g=no |
| 1700 | fi |
| 1701 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 1702 | fi |
| 1703 | echo "$as_me:1703: result: $ac_cv_prog_cc_g" >&5 |
| 1704 | echo "${ECHO_T}$ac_cv_prog_cc_g" >&6 |
| 1705 | if test "$ac_test_CFLAGS" = set; then |
| 1706 | CFLAGS=$ac_save_CFLAGS |
| 1707 | elif test $ac_cv_prog_cc_g = yes; then |
| 1708 | if test "$GCC" = yes; then |
| 1709 | CFLAGS="-g -O2" |
| 1710 | else |
| 1711 | CFLAGS="-g" |
| 1712 | fi |
| 1713 | else |
| 1714 | if test "$GCC" = yes; then |
| 1715 | CFLAGS="-O2" |
| 1716 | else |
| 1717 | CFLAGS= |
| 1718 | fi |
| 1719 | fi |
| 1720 | # Some people use a C++ compiler to compile C. Since we use `exit', |
| 1721 | # in C++ we need to declare it. In case someone uses the same compiler |
| 1722 | # for both compiling C and C++ we need to have the C++ compiler decide |
| 1723 | # the declaration of exit, since it's the most demanding environment. |
| 1724 | cat >conftest.$ac_ext <<_ACEOF |
| 1725 | #ifndef __cplusplus |
| 1726 | choke me |
| 1727 | #endif |
| 1728 | _ACEOF |
| 1729 | rm -f conftest.$ac_objext |
| 1730 | if { (eval echo "$as_me:1730: \"$ac_compile\"") >&5 |
| 1731 | (eval $ac_compile) 2>&5 |
| 1732 | ac_status=$? |
| 1733 | echo "$as_me:1733: \$? = $ac_status" >&5 |
| 1734 | (exit $ac_status); } && |
| 1735 | { ac_try='test -s conftest.$ac_objext' |
| 1736 | { (eval echo "$as_me:1736: \"$ac_try\"") >&5 |
| 1737 | (eval $ac_try) 2>&5 |
| 1738 | ac_status=$? |
| 1739 | echo "$as_me:1739: \$? = $ac_status" >&5 |
| 1740 | (exit $ac_status); }; }; then |
| 1741 | for ac_declaration in \ |
| 1742 | ''\ |
| 1743 | '#include <stdlib.h>' \ |
| 1744 | 'extern "C" void std::exit (int) throw (); using std::exit;' \ |
| 1745 | 'extern "C" void std::exit (int); using std::exit;' \ |
| 1746 | 'extern "C" void exit (int) throw ();' \ |
| 1747 | 'extern "C" void exit (int);' \ |
| 1748 | 'void exit (int);' |
| 1749 | do |
| 1750 | cat >conftest.$ac_ext <<_ACEOF |
| 1751 | #line 1751 "configure" |
| 1752 | #include "confdefs.h" |
| 1753 | #include <stdlib.h> |
| 1754 | $ac_declaration |
| 1755 | int |
| 1756 | main () |
| 1757 | { |
| 1758 | exit (42); |
| 1759 | ; |
| 1760 | return 0; |
| 1761 | } |
| 1762 | _ACEOF |
| 1763 | rm -f conftest.$ac_objext |
| 1764 | if { (eval echo "$as_me:1764: \"$ac_compile\"") >&5 |
| 1765 | (eval $ac_compile) 2>&5 |
| 1766 | ac_status=$? |
| 1767 | echo "$as_me:1767: \$? = $ac_status" >&5 |
| 1768 | (exit $ac_status); } && |
| 1769 | { ac_try='test -s conftest.$ac_objext' |
| 1770 | { (eval echo "$as_me:1770: \"$ac_try\"") >&5 |
| 1771 | (eval $ac_try) 2>&5 |
| 1772 | ac_status=$? |
| 1773 | echo "$as_me:1773: \$? = $ac_status" >&5 |
| 1774 | (exit $ac_status); }; }; then |
| 1775 | : |
| 1776 | else |
| 1777 | echo "$as_me: failed program was:" >&5 |
| 1778 | cat conftest.$ac_ext >&5 |
| 1779 | continue |
| 1780 | fi |
| 1781 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 1782 | cat >conftest.$ac_ext <<_ACEOF |
| 1783 | #line 1783 "configure" |
| 1784 | #include "confdefs.h" |
| 1785 | $ac_declaration |
| 1786 | int |
| 1787 | main () |
| 1788 | { |
| 1789 | exit (42); |
| 1790 | ; |
| 1791 | return 0; |
| 1792 | } |
| 1793 | _ACEOF |
| 1794 | rm -f conftest.$ac_objext |
| 1795 | if { (eval echo "$as_me:1795: \"$ac_compile\"") >&5 |
| 1796 | (eval $ac_compile) 2>&5 |
| 1797 | ac_status=$? |
| 1798 | echo "$as_me:1798: \$? = $ac_status" >&5 |
| 1799 | (exit $ac_status); } && |
| 1800 | { ac_try='test -s conftest.$ac_objext' |
| 1801 | { (eval echo "$as_me:1801: \"$ac_try\"") >&5 |
| 1802 | (eval $ac_try) 2>&5 |
| 1803 | ac_status=$? |
| 1804 | echo "$as_me:1804: \$? = $ac_status" >&5 |
| 1805 | (exit $ac_status); }; }; then |
| 1806 | break |
| 1807 | else |
| 1808 | echo "$as_me: failed program was:" >&5 |
| 1809 | cat conftest.$ac_ext >&5 |
| 1810 | fi |
| 1811 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 1812 | done |
| 1813 | rm -rf conftest* |
| 1814 | if test -n "$ac_declaration"; then |
| 1815 | echo '#ifdef __cplusplus' >>confdefs.h |
| 1816 | echo $ac_declaration >>confdefs.h |
| 1817 | echo '#endif' >>confdefs.h |
| 1818 | fi |
| 1819 | |
| 1820 | else |
| 1821 | echo "$as_me: failed program was:" >&5 |
| 1822 | cat conftest.$ac_ext >&5 |
| 1823 | fi |
| 1824 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 1825 | ac_ext=c |
| 1826 | ac_cpp='$CPP $CPPFLAGS' |
| 1827 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 1828 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 1829 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 1830 | ac_main_return=return |
| 1831 | |
| 1832 | GCC_VERSION=none |
| 1833 | if test "$GCC" = yes ; then |
| 1834 | echo "$as_me:1834: checking version of $CC" >&5 |
| 1835 | echo $ECHO_N "checking version of $CC... $ECHO_C" >&6 |
| 1836 | GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`" |
| 1837 | test -z "$GCC_VERSION" && GCC_VERSION=unknown |
| 1838 | echo "$as_me:1838: result: $GCC_VERSION" >&5 |
| 1839 | echo "${ECHO_T}$GCC_VERSION" >&6 |
| 1840 | fi |
| 1841 | |
| 1842 | echo "$as_me:1842: checking for $CC option to accept ANSI C" >&5 |
| 1843 | echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6 |
| 1844 | if test "${ac_cv_prog_cc_stdc+set}" = set; then |
| 1845 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1846 | else |
| 1847 | ac_cv_prog_cc_stdc=no |
| 1848 | ac_save_CC=$CC |
| 1849 | cat >conftest.$ac_ext <<_ACEOF |
| 1850 | #line 1850 "configure" |
| 1851 | #include "confdefs.h" |
| 1852 | #include <stdarg.h> |
| 1853 | #include <stdio.h> |
| 1854 | #include <sys/types.h> |
| 1855 | #include <sys/stat.h> |
| 1856 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 1857 | struct buf { int x; }; |
| 1858 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 1859 | static char *e (p, i) |
| 1860 | char **p; |
| 1861 | int i; |
| 1862 | { |
| 1863 | return p[i]; |
| 1864 | } |
| 1865 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 1866 | { |
| 1867 | char *s; |
| 1868 | va_list v; |
| 1869 | va_start (v,p); |
| 1870 | s = g (p, va_arg (v,int)); |
| 1871 | va_end (v); |
| 1872 | return s; |
| 1873 | } |
| 1874 | int test (int i, double x); |
| 1875 | struct s1 {int (*f) (int a);}; |
| 1876 | struct s2 {int (*f) (double a);}; |
| 1877 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 1878 | int argc; |
| 1879 | char **argv; |
| 1880 | int |
| 1881 | main () |
| 1882 | { |
| 1883 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 1884 | ; |
| 1885 | return 0; |
| 1886 | } |
| 1887 | _ACEOF |
| 1888 | # Don't try gcc -ansi; that turns off useful extensions and |
| 1889 | # breaks some systems' header files. |
| 1890 | # AIX -qlanglvl=ansi |
| 1891 | # Ultrix and OSF/1 -std1 |
| 1892 | # HP-UX 10.20 and later -Ae |
| 1893 | # HP-UX older versions -Aa -D_HPUX_SOURCE |
| 1894 | # SVR4 -Xc -D__EXTENSIONS__ |
| 1895 | for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
| 1896 | do |
| 1897 | CC="$ac_save_CC $ac_arg" |
| 1898 | rm -f conftest.$ac_objext |
| 1899 | if { (eval echo "$as_me:1899: \"$ac_compile\"") >&5 |
| 1900 | (eval $ac_compile) 2>&5 |
| 1901 | ac_status=$? |
| 1902 | echo "$as_me:1902: \$? = $ac_status" >&5 |
| 1903 | (exit $ac_status); } && |
| 1904 | { ac_try='test -s conftest.$ac_objext' |
| 1905 | { (eval echo "$as_me:1905: \"$ac_try\"") >&5 |
| 1906 | (eval $ac_try) 2>&5 |
| 1907 | ac_status=$? |
| 1908 | echo "$as_me:1908: \$? = $ac_status" >&5 |
| 1909 | (exit $ac_status); }; }; then |
| 1910 | ac_cv_prog_cc_stdc=$ac_arg |
| 1911 | break |
| 1912 | else |
| 1913 | echo "$as_me: failed program was:" >&5 |
| 1914 | cat conftest.$ac_ext >&5 |
| 1915 | fi |
| 1916 | rm -f conftest.$ac_objext |
| 1917 | done |
| 1918 | rm -f conftest.$ac_ext conftest.$ac_objext |
| 1919 | CC=$ac_save_CC |
| 1920 | |
| 1921 | fi |
| 1922 | |
| 1923 | case "x$ac_cv_prog_cc_stdc" in |
| 1924 | x|xno) |
| 1925 | echo "$as_me:1925: result: none needed" >&5 |
| 1926 | echo "${ECHO_T}none needed" >&6 ;; |
| 1927 | *) |
| 1928 | echo "$as_me:1928: result: $ac_cv_prog_cc_stdc" >&5 |
| 1929 | echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6 |
| 1930 | CC="$CC $ac_cv_prog_cc_stdc" ;; |
| 1931 | esac |
| 1932 | |
| 1933 | # This should have been defined by AC_PROG_CC |
| 1934 | : ${CC:=cc} |
| 1935 | |
| 1936 | echo "$as_me:1936: checking \$CC variable" >&5 |
| 1937 | echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6 |
| 1938 | case "$CC" in |
| 1939 | (*[\ \ ]-[IUD]*) |
| 1940 | echo "$as_me:1940: result: broken" >&5 |
| 1941 | echo "${ECHO_T}broken" >&6 |
| 1942 | { echo "$as_me:1942: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5 |
| 1943 | echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;} |
| 1944 | # humor him... |
| 1945 | cf_flags=`echo "$CC" | sed -e 's/^[^ ]*[ ]//'` |
| 1946 | CC=`echo "$CC" | sed -e 's/[ ].*//'` |
| 1947 | |
| 1948 | cf_fix_cppflags=no |
| 1949 | cf_new_cflags= |
| 1950 | cf_new_cppflags= |
| 1951 | cf_new_extra_cppflags= |
| 1952 | |
| 1953 | for cf_add_cflags in $cf_flags |
| 1954 | do |
| 1955 | case $cf_fix_cppflags in |
| 1956 | (no) |
| 1957 | case $cf_add_cflags in |
| 1958 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 1959 | case $cf_add_cflags in |
| 1960 | (-D*) |
| 1961 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 1962 | |
| 1963 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 1964 | && test -z "${cf_tst_cflags}" \ |
| 1965 | && cf_fix_cppflags=yes |
| 1966 | |
| 1967 | if test $cf_fix_cppflags = yes ; then |
| 1968 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 1969 | continue |
| 1970 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 1971 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 1972 | continue |
| 1973 | fi |
| 1974 | ;; |
| 1975 | esac |
| 1976 | case "$CPPFLAGS" in |
| 1977 | (*$cf_add_cflags) |
| 1978 | ;; |
| 1979 | (*) |
| 1980 | case $cf_add_cflags in |
| 1981 | (-D*) |
| 1982 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 1983 | |
| 1984 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 1985 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 1986 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 1987 | |
| 1988 | ;; |
| 1989 | esac |
| 1990 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 1991 | ;; |
| 1992 | esac |
| 1993 | ;; |
| 1994 | (*) |
| 1995 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 1996 | ;; |
| 1997 | esac |
| 1998 | ;; |
| 1999 | (yes) |
| 2000 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 2001 | |
| 2002 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 2003 | |
| 2004 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 2005 | && test -z "${cf_tst_cflags}" \ |
| 2006 | && cf_fix_cppflags=no |
| 2007 | ;; |
| 2008 | esac |
| 2009 | done |
| 2010 | |
| 2011 | if test -n "$cf_new_cflags" ; then |
| 2012 | |
| 2013 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 2014 | fi |
| 2015 | |
| 2016 | if test -n "$cf_new_cppflags" ; then |
| 2017 | |
| 2018 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 2019 | fi |
| 2020 | |
| 2021 | if test -n "$cf_new_extra_cppflags" ; then |
| 2022 | |
| 2023 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 2024 | fi |
| 2025 | |
| 2026 | ;; |
| 2027 | (*) |
| 2028 | echo "$as_me:2028: result: ok" >&5 |
| 2029 | echo "${ECHO_T}ok" >&6 |
| 2030 | ;; |
| 2031 | esac |
| 2032 | |
| 2033 | ac_ext=c |
| 2034 | ac_cpp='$CPP $CPPFLAGS' |
| 2035 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2036 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2037 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2038 | ac_main_return=return |
| 2039 | echo "$as_me:2039: checking how to run the C preprocessor" >&5 |
| 2040 | echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6 |
| 2041 | # On Suns, sometimes $CPP names a directory. |
| 2042 | if test -n "$CPP" && test -d "$CPP"; then |
| 2043 | CPP= |
| 2044 | fi |
| 2045 | if test -z "$CPP"; then |
| 2046 | if test "${ac_cv_prog_CPP+set}" = set; then |
| 2047 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2048 | else |
| 2049 | # Double quotes because CPP needs to be expanded |
| 2050 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 2051 | do |
| 2052 | ac_preproc_ok=false |
| 2053 | for ac_c_preproc_warn_flag in '' yes |
| 2054 | do |
| 2055 | # Use a header file that comes with gcc, so configuring glibc |
| 2056 | # with a fresh cross-compiler works. |
| 2057 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 2058 | # not just through cpp. "Syntax error" is here to catch this case. |
| 2059 | cat >conftest.$ac_ext <<_ACEOF |
| 2060 | #line 2060 "configure" |
| 2061 | #include "confdefs.h" |
| 2062 | #include <assert.h> |
| 2063 | Syntax error |
| 2064 | _ACEOF |
| 2065 | if { (eval echo "$as_me:2065: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 2066 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 2067 | ac_status=$? |
| 2068 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 2069 | rm -f conftest.er1 |
| 2070 | cat conftest.err >&5 |
| 2071 | echo "$as_me:2071: \$? = $ac_status" >&5 |
| 2072 | (exit $ac_status); } >/dev/null; then |
| 2073 | if test -s conftest.err; then |
| 2074 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 2075 | else |
| 2076 | ac_cpp_err= |
| 2077 | fi |
| 2078 | else |
| 2079 | ac_cpp_err=yes |
| 2080 | fi |
| 2081 | if test -z "$ac_cpp_err"; then |
| 2082 | : |
| 2083 | else |
| 2084 | echo "$as_me: failed program was:" >&5 |
| 2085 | cat conftest.$ac_ext >&5 |
| 2086 | # Broken: fails on valid input. |
| 2087 | continue |
| 2088 | fi |
| 2089 | rm -f conftest.err conftest.$ac_ext |
| 2090 | |
| 2091 | # OK, works on sane cases. Now check whether non-existent headers |
| 2092 | # can be detected and how. |
| 2093 | cat >conftest.$ac_ext <<_ACEOF |
| 2094 | #line 2094 "configure" |
| 2095 | #include "confdefs.h" |
| 2096 | #include <ac_nonexistent.h> |
| 2097 | _ACEOF |
| 2098 | if { (eval echo "$as_me:2098: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 2099 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 2100 | ac_status=$? |
| 2101 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 2102 | rm -f conftest.er1 |
| 2103 | cat conftest.err >&5 |
| 2104 | echo "$as_me:2104: \$? = $ac_status" >&5 |
| 2105 | (exit $ac_status); } >/dev/null; then |
| 2106 | if test -s conftest.err; then |
| 2107 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 2108 | else |
| 2109 | ac_cpp_err= |
| 2110 | fi |
| 2111 | else |
| 2112 | ac_cpp_err=yes |
| 2113 | fi |
| 2114 | if test -z "$ac_cpp_err"; then |
| 2115 | # Broken: success on invalid input. |
| 2116 | continue |
| 2117 | else |
| 2118 | echo "$as_me: failed program was:" >&5 |
| 2119 | cat conftest.$ac_ext >&5 |
| 2120 | # Passes both tests. |
| 2121 | ac_preproc_ok=: |
| 2122 | break |
| 2123 | fi |
| 2124 | rm -f conftest.err conftest.$ac_ext |
| 2125 | |
| 2126 | done |
| 2127 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
| 2128 | rm -f conftest.err conftest.$ac_ext |
| 2129 | if $ac_preproc_ok; then |
| 2130 | break |
| 2131 | fi |
| 2132 | |
| 2133 | done |
| 2134 | ac_cv_prog_CPP=$CPP |
| 2135 | |
| 2136 | fi |
| 2137 | CPP=$ac_cv_prog_CPP |
| 2138 | else |
| 2139 | ac_cv_prog_CPP=$CPP |
| 2140 | fi |
| 2141 | echo "$as_me:2141: result: $CPP" >&5 |
| 2142 | echo "${ECHO_T}$CPP" >&6 |
| 2143 | ac_preproc_ok=false |
| 2144 | for ac_c_preproc_warn_flag in '' yes |
| 2145 | do |
| 2146 | # Use a header file that comes with gcc, so configuring glibc |
| 2147 | # with a fresh cross-compiler works. |
| 2148 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 2149 | # not just through cpp. "Syntax error" is here to catch this case. |
| 2150 | cat >conftest.$ac_ext <<_ACEOF |
| 2151 | #line 2151 "configure" |
| 2152 | #include "confdefs.h" |
| 2153 | #include <assert.h> |
| 2154 | Syntax error |
| 2155 | _ACEOF |
| 2156 | if { (eval echo "$as_me:2156: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 2157 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 2158 | ac_status=$? |
| 2159 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 2160 | rm -f conftest.er1 |
| 2161 | cat conftest.err >&5 |
| 2162 | echo "$as_me:2162: \$? = $ac_status" >&5 |
| 2163 | (exit $ac_status); } >/dev/null; then |
| 2164 | if test -s conftest.err; then |
| 2165 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 2166 | else |
| 2167 | ac_cpp_err= |
| 2168 | fi |
| 2169 | else |
| 2170 | ac_cpp_err=yes |
| 2171 | fi |
| 2172 | if test -z "$ac_cpp_err"; then |
| 2173 | : |
| 2174 | else |
| 2175 | echo "$as_me: failed program was:" >&5 |
| 2176 | cat conftest.$ac_ext >&5 |
| 2177 | # Broken: fails on valid input. |
| 2178 | continue |
| 2179 | fi |
| 2180 | rm -f conftest.err conftest.$ac_ext |
| 2181 | |
| 2182 | # OK, works on sane cases. Now check whether non-existent headers |
| 2183 | # can be detected and how. |
| 2184 | cat >conftest.$ac_ext <<_ACEOF |
| 2185 | #line 2185 "configure" |
| 2186 | #include "confdefs.h" |
| 2187 | #include <ac_nonexistent.h> |
| 2188 | _ACEOF |
| 2189 | if { (eval echo "$as_me:2189: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 2190 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 2191 | ac_status=$? |
| 2192 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 2193 | rm -f conftest.er1 |
| 2194 | cat conftest.err >&5 |
| 2195 | echo "$as_me:2195: \$? = $ac_status" >&5 |
| 2196 | (exit $ac_status); } >/dev/null; then |
| 2197 | if test -s conftest.err; then |
| 2198 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 2199 | else |
| 2200 | ac_cpp_err= |
| 2201 | fi |
| 2202 | else |
| 2203 | ac_cpp_err=yes |
| 2204 | fi |
| 2205 | if test -z "$ac_cpp_err"; then |
| 2206 | # Broken: success on invalid input. |
| 2207 | continue |
| 2208 | else |
| 2209 | echo "$as_me: failed program was:" >&5 |
| 2210 | cat conftest.$ac_ext >&5 |
| 2211 | # Passes both tests. |
| 2212 | ac_preproc_ok=: |
| 2213 | break |
| 2214 | fi |
| 2215 | rm -f conftest.err conftest.$ac_ext |
| 2216 | |
| 2217 | done |
| 2218 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
| 2219 | rm -f conftest.err conftest.$ac_ext |
| 2220 | if $ac_preproc_ok; then |
| 2221 | : |
| 2222 | else |
| 2223 | { { echo "$as_me:2223: error: C preprocessor \"$CPP\" fails sanity check" >&5 |
| 2224 | echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;} |
| 2225 | { (exit 1); exit 1; }; } |
| 2226 | fi |
| 2227 | |
| 2228 | ac_ext=c |
| 2229 | ac_cpp='$CPP $CPPFLAGS' |
| 2230 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2231 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2232 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2233 | ac_main_return=return |
| 2234 | |
| 2235 | for ac_prog in mawk gawk nawk awk |
| 2236 | do |
| 2237 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 2238 | set dummy $ac_prog; ac_word=$2 |
| 2239 | echo "$as_me:2239: checking for $ac_word" >&5 |
| 2240 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2241 | if test "${ac_cv_prog_AWK+set}" = set; then |
| 2242 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2243 | else |
| 2244 | if test -n "$AWK"; then |
| 2245 | ac_cv_prog_AWK="$AWK" # Let the user override the test. |
| 2246 | else |
| 2247 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2248 | ac_dummy="$PATH" |
| 2249 | for ac_dir in $ac_dummy; do |
| 2250 | IFS=$ac_save_IFS |
| 2251 | test -z "$ac_dir" && ac_dir=. |
| 2252 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 2253 | ac_cv_prog_AWK="$ac_prog" |
| 2254 | echo "$as_me:2254: found $ac_dir/$ac_word" >&5 |
| 2255 | break |
| 2256 | done |
| 2257 | |
| 2258 | fi |
| 2259 | fi |
| 2260 | AWK=$ac_cv_prog_AWK |
| 2261 | if test -n "$AWK"; then |
| 2262 | echo "$as_me:2262: result: $AWK" >&5 |
| 2263 | echo "${ECHO_T}$AWK" >&6 |
| 2264 | else |
| 2265 | echo "$as_me:2265: result: no" >&5 |
| 2266 | echo "${ECHO_T}no" >&6 |
| 2267 | fi |
| 2268 | |
| 2269 | test -n "$AWK" && break |
| 2270 | done |
| 2271 | |
| 2272 | # Find a good install program. We prefer a C program (faster), |
| 2273 | # so one script is as good as another. But avoid the broken or |
| 2274 | # incompatible versions: |
| 2275 | # SysV /etc/install, /usr/sbin/install |
| 2276 | # SunOS /usr/etc/install |
| 2277 | # IRIX /sbin/install |
| 2278 | # AIX /bin/install |
| 2279 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 2280 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 2281 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 2282 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 2283 | # ./install, which can be erroneously created by make from ./install.sh. |
| 2284 | echo "$as_me:2284: checking for a BSD compatible install" >&5 |
| 2285 | echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6 |
| 2286 | if test -z "$INSTALL"; then |
| 2287 | if test "${ac_cv_path_install+set}" = set; then |
| 2288 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2289 | else |
| 2290 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2291 | for ac_dir in $PATH; do |
| 2292 | IFS=$ac_save_IFS |
| 2293 | # Account for people who put trailing slashes in PATH elements. |
| 2294 | case $ac_dir/ in |
| 2295 | / | ./ | .// | /cC/* \ |
| 2296 | | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \ |
| 2297 | | /usr/ucb/* ) ;; |
| 2298 | *) |
| 2299 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 2300 | # Don't use installbsd from OSF since it installs stuff as root |
| 2301 | # by default. |
| 2302 | for ac_prog in ginstall scoinst install; do |
| 2303 | if $as_executable_p "$ac_dir/$ac_prog"; then |
| 2304 | if test $ac_prog = install && |
| 2305 | grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then |
| 2306 | # AIX install. It has an incompatible calling convention. |
| 2307 | : |
| 2308 | elif test $ac_prog = install && |
| 2309 | grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then |
| 2310 | # program-specific install script used by HP pwplus--don't use. |
| 2311 | : |
| 2312 | else |
| 2313 | ac_cv_path_install="$ac_dir/$ac_prog -c" |
| 2314 | break 2 |
| 2315 | fi |
| 2316 | fi |
| 2317 | done |
| 2318 | ;; |
| 2319 | esac |
| 2320 | done |
| 2321 | |
| 2322 | fi |
| 2323 | if test "${ac_cv_path_install+set}" = set; then |
| 2324 | INSTALL=$ac_cv_path_install |
| 2325 | else |
| 2326 | # As a last resort, use the slow shell script. We don't cache a |
| 2327 | # path for INSTALL within a source directory, because that will |
| 2328 | # break other packages using the cache if that directory is |
| 2329 | # removed, or if the path is relative. |
| 2330 | INSTALL=$ac_install_sh |
| 2331 | fi |
| 2332 | fi |
| 2333 | echo "$as_me:2333: result: $INSTALL" >&5 |
| 2334 | echo "${ECHO_T}$INSTALL" >&6 |
| 2335 | |
| 2336 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 2337 | # It thinks the first close brace ends the variable substitution. |
| 2338 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 2339 | |
| 2340 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 2341 | |
| 2342 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 2343 | |
| 2344 | case $INSTALL in |
| 2345 | (/*) |
| 2346 | ;; |
| 2347 | (*) |
| 2348 | cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'` |
| 2349 | test -z "$cf_dir" && cf_dir=. |
| 2350 | INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'` |
| 2351 | ;; |
| 2352 | esac |
| 2353 | |
| 2354 | for ac_prog in tdlint lint alint splint lclint |
| 2355 | do |
| 2356 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 2357 | set dummy $ac_prog; ac_word=$2 |
| 2358 | echo "$as_me:2358: checking for $ac_word" >&5 |
| 2359 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2360 | if test "${ac_cv_prog_LINT+set}" = set; then |
| 2361 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2362 | else |
| 2363 | if test -n "$LINT"; then |
| 2364 | ac_cv_prog_LINT="$LINT" # Let the user override the test. |
| 2365 | else |
| 2366 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2367 | ac_dummy="$PATH" |
| 2368 | for ac_dir in $ac_dummy; do |
| 2369 | IFS=$ac_save_IFS |
| 2370 | test -z "$ac_dir" && ac_dir=. |
| 2371 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 2372 | ac_cv_prog_LINT="$ac_prog" |
| 2373 | echo "$as_me:2373: found $ac_dir/$ac_word" >&5 |
| 2374 | break |
| 2375 | done |
| 2376 | |
| 2377 | fi |
| 2378 | fi |
| 2379 | LINT=$ac_cv_prog_LINT |
| 2380 | if test -n "$LINT"; then |
| 2381 | echo "$as_me:2381: result: $LINT" >&5 |
| 2382 | echo "${ECHO_T}$LINT" >&6 |
| 2383 | else |
| 2384 | echo "$as_me:2384: result: no" >&5 |
| 2385 | echo "${ECHO_T}no" >&6 |
| 2386 | fi |
| 2387 | |
| 2388 | test -n "$LINT" && break |
| 2389 | done |
| 2390 | |
| 2391 | echo "$as_me:2391: checking if filesystem supports mixed-case filenames" >&5 |
| 2392 | echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6 |
| 2393 | if test "${cf_cv_mixedcase+set}" = set; then |
| 2394 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2395 | else |
| 2396 | |
| 2397 | if test "$cross_compiling" = yes ; then |
| 2398 | case $target_alias in |
| 2399 | (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*) |
| 2400 | cf_cv_mixedcase=no |
| 2401 | ;; |
| 2402 | (*) |
| 2403 | cf_cv_mixedcase=yes |
| 2404 | ;; |
| 2405 | esac |
| 2406 | else |
| 2407 | rm -f conftest CONFTEST |
| 2408 | echo test >conftest |
| 2409 | if test -f CONFTEST ; then |
| 2410 | cf_cv_mixedcase=no |
| 2411 | else |
| 2412 | cf_cv_mixedcase=yes |
| 2413 | fi |
| 2414 | rm -f conftest CONFTEST |
| 2415 | fi |
| 2416 | |
| 2417 | fi |
| 2418 | echo "$as_me:2418: result: $cf_cv_mixedcase" >&5 |
| 2419 | echo "${ECHO_T}$cf_cv_mixedcase" >&6 |
| 2420 | test "$cf_cv_mixedcase" = yes && |
| 2421 | cat >>confdefs.h <<\EOF |
| 2422 | #define MIXEDCASE_FILENAMES 1 |
| 2423 | EOF |
| 2424 | |
| 2425 | for ac_prog in exctags ctags |
| 2426 | do |
| 2427 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 2428 | set dummy $ac_prog; ac_word=$2 |
| 2429 | echo "$as_me:2429: checking for $ac_word" >&5 |
| 2430 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2431 | if test "${ac_cv_prog_CTAGS+set}" = set; then |
| 2432 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2433 | else |
| 2434 | if test -n "$CTAGS"; then |
| 2435 | ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test. |
| 2436 | else |
| 2437 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2438 | ac_dummy="$PATH" |
| 2439 | for ac_dir in $ac_dummy; do |
| 2440 | IFS=$ac_save_IFS |
| 2441 | test -z "$ac_dir" && ac_dir=. |
| 2442 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 2443 | ac_cv_prog_CTAGS="$ac_prog" |
| 2444 | echo "$as_me:2444: found $ac_dir/$ac_word" >&5 |
| 2445 | break |
| 2446 | done |
| 2447 | |
| 2448 | fi |
| 2449 | fi |
| 2450 | CTAGS=$ac_cv_prog_CTAGS |
| 2451 | if test -n "$CTAGS"; then |
| 2452 | echo "$as_me:2452: result: $CTAGS" >&5 |
| 2453 | echo "${ECHO_T}$CTAGS" >&6 |
| 2454 | else |
| 2455 | echo "$as_me:2455: result: no" >&5 |
| 2456 | echo "${ECHO_T}no" >&6 |
| 2457 | fi |
| 2458 | |
| 2459 | test -n "$CTAGS" && break |
| 2460 | done |
| 2461 | |
| 2462 | for ac_prog in exetags etags |
| 2463 | do |
| 2464 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 2465 | set dummy $ac_prog; ac_word=$2 |
| 2466 | echo "$as_me:2466: checking for $ac_word" >&5 |
| 2467 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2468 | if test "${ac_cv_prog_ETAGS+set}" = set; then |
| 2469 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2470 | else |
| 2471 | if test -n "$ETAGS"; then |
| 2472 | ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test. |
| 2473 | else |
| 2474 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2475 | ac_dummy="$PATH" |
| 2476 | for ac_dir in $ac_dummy; do |
| 2477 | IFS=$ac_save_IFS |
| 2478 | test -z "$ac_dir" && ac_dir=. |
| 2479 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 2480 | ac_cv_prog_ETAGS="$ac_prog" |
| 2481 | echo "$as_me:2481: found $ac_dir/$ac_word" >&5 |
| 2482 | break |
| 2483 | done |
| 2484 | |
| 2485 | fi |
| 2486 | fi |
| 2487 | ETAGS=$ac_cv_prog_ETAGS |
| 2488 | if test -n "$ETAGS"; then |
| 2489 | echo "$as_me:2489: result: $ETAGS" >&5 |
| 2490 | echo "${ECHO_T}$ETAGS" >&6 |
| 2491 | else |
| 2492 | echo "$as_me:2492: result: no" >&5 |
| 2493 | echo "${ECHO_T}no" >&6 |
| 2494 | fi |
| 2495 | |
| 2496 | test -n "$ETAGS" && break |
| 2497 | done |
| 2498 | |
| 2499 | # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args. |
| 2500 | set dummy ${CTAGS:-ctags}; ac_word=$2 |
| 2501 | echo "$as_me:2501: checking for $ac_word" >&5 |
| 2502 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2503 | if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then |
| 2504 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2505 | else |
| 2506 | if test -n "$MAKE_LOWER_TAGS"; then |
| 2507 | ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test. |
| 2508 | else |
| 2509 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2510 | ac_dummy="$PATH" |
| 2511 | for ac_dir in $ac_dummy; do |
| 2512 | IFS=$ac_save_IFS |
| 2513 | test -z "$ac_dir" && ac_dir=. |
| 2514 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 2515 | ac_cv_prog_MAKE_LOWER_TAGS="yes" |
| 2516 | echo "$as_me:2516: found $ac_dir/$ac_word" >&5 |
| 2517 | break |
| 2518 | done |
| 2519 | |
| 2520 | test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no" |
| 2521 | fi |
| 2522 | fi |
| 2523 | MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS |
| 2524 | if test -n "$MAKE_LOWER_TAGS"; then |
| 2525 | echo "$as_me:2525: result: $MAKE_LOWER_TAGS" >&5 |
| 2526 | echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6 |
| 2527 | else |
| 2528 | echo "$as_me:2528: result: no" >&5 |
| 2529 | echo "${ECHO_T}no" >&6 |
| 2530 | fi |
| 2531 | |
| 2532 | if test "$cf_cv_mixedcase" = yes ; then |
| 2533 | # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args. |
| 2534 | set dummy ${ETAGS:-etags}; ac_word=$2 |
| 2535 | echo "$as_me:2535: checking for $ac_word" >&5 |
| 2536 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2537 | if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then |
| 2538 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2539 | else |
| 2540 | if test -n "$MAKE_UPPER_TAGS"; then |
| 2541 | ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test. |
| 2542 | else |
| 2543 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2544 | ac_dummy="$PATH" |
| 2545 | for ac_dir in $ac_dummy; do |
| 2546 | IFS=$ac_save_IFS |
| 2547 | test -z "$ac_dir" && ac_dir=. |
| 2548 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 2549 | ac_cv_prog_MAKE_UPPER_TAGS="yes" |
| 2550 | echo "$as_me:2550: found $ac_dir/$ac_word" >&5 |
| 2551 | break |
| 2552 | done |
| 2553 | |
| 2554 | test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no" |
| 2555 | fi |
| 2556 | fi |
| 2557 | MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS |
| 2558 | if test -n "$MAKE_UPPER_TAGS"; then |
| 2559 | echo "$as_me:2559: result: $MAKE_UPPER_TAGS" >&5 |
| 2560 | echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6 |
| 2561 | else |
| 2562 | echo "$as_me:2562: result: no" >&5 |
| 2563 | echo "${ECHO_T}no" >&6 |
| 2564 | fi |
| 2565 | |
| 2566 | else |
| 2567 | MAKE_UPPER_TAGS=no |
| 2568 | fi |
| 2569 | |
| 2570 | if test "$MAKE_UPPER_TAGS" = yes ; then |
| 2571 | MAKE_UPPER_TAGS= |
| 2572 | else |
| 2573 | MAKE_UPPER_TAGS="#" |
| 2574 | fi |
| 2575 | |
| 2576 | if test "$MAKE_LOWER_TAGS" = yes ; then |
| 2577 | MAKE_LOWER_TAGS= |
| 2578 | else |
| 2579 | MAKE_LOWER_TAGS="#" |
| 2580 | fi |
| 2581 | |
| 2582 | echo "$as_me:2582: checking if -lm needed for math functions" >&5 |
| 2583 | echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6 |
| 2584 | if test "${cf_cv_need_libm+set}" = set; then |
| 2585 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2586 | else |
| 2587 | |
| 2588 | cat >conftest.$ac_ext <<_ACEOF |
| 2589 | #line 2589 "configure" |
| 2590 | #include "confdefs.h" |
| 2591 | |
| 2592 | #include <stdio.h> |
| 2593 | #include <math.h> |
| 2594 | |
| 2595 | int |
| 2596 | main () |
| 2597 | { |
| 2598 | double x = rand(); printf("result = %g\n", pow(sin(x),x)) |
| 2599 | ; |
| 2600 | return 0; |
| 2601 | } |
| 2602 | _ACEOF |
| 2603 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 2604 | if { (eval echo "$as_me:2604: \"$ac_link\"") >&5 |
| 2605 | (eval $ac_link) 2>&5 |
| 2606 | ac_status=$? |
| 2607 | echo "$as_me:2607: \$? = $ac_status" >&5 |
| 2608 | (exit $ac_status); } && |
| 2609 | { ac_try='test -s conftest$ac_exeext' |
| 2610 | { (eval echo "$as_me:2610: \"$ac_try\"") >&5 |
| 2611 | (eval $ac_try) 2>&5 |
| 2612 | ac_status=$? |
| 2613 | echo "$as_me:2613: \$? = $ac_status" >&5 |
| 2614 | (exit $ac_status); }; }; then |
| 2615 | cf_cv_need_libm=no |
| 2616 | else |
| 2617 | echo "$as_me: failed program was:" >&5 |
| 2618 | cat conftest.$ac_ext >&5 |
| 2619 | cf_cv_need_libm=yes |
| 2620 | fi |
| 2621 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 2622 | fi |
| 2623 | echo "$as_me:2623: result: $cf_cv_need_libm" >&5 |
| 2624 | echo "${ECHO_T}$cf_cv_need_libm" >&6 |
| 2625 | if test "$cf_cv_need_libm" = yes |
| 2626 | then |
| 2627 | MATH_LIB=-lm |
| 2628 | fi |
| 2629 | |
| 2630 | top_builddir=`pwd` |
| 2631 | |
| 2632 | CC_G_OPT="-g" |
| 2633 | CC_SHARED_OPTS=unknown |
| 2634 | CPPFLAGS="$CPPFLAGS" |
| 2635 | DFT_DEP_SUFFIX="" |
| 2636 | DFT_OBJ_SUBDIR=`pwd|sed -e's:.*/::'` |
| 2637 | DFT_UPR_MODEL="NORMAL" |
| 2638 | LD="ld" |
| 2639 | LDFLAGS_SHARED="" |
| 2640 | LDFLAGS_STATIC="" |
| 2641 | LD_MODEL="" |
| 2642 | LD_SHARED_OPTS="" |
| 2643 | LIBTOOL="" |
| 2644 | LIBTOOL_OPTS="" |
| 2645 | LIB_CLEAN="" |
| 2646 | LIB_COMPILE="" |
| 2647 | LIB_LINK='${CC}' |
| 2648 | LINK_TESTS="" |
| 2649 | LOCAL_LDFLAGS="" |
| 2650 | PACKAGE="ncurses-examples" |
| 2651 | PTHREAD="-lm" |
| 2652 | TEST_ARGS="" |
| 2653 | TEST_DEPS="" |
| 2654 | TEST_LIBS="" |
| 2655 | TINFO_LDFLAGS='' |
| 2656 | TINFO_LIBS='$(LIBS_CURSES)' |
| 2657 | cf_cv_abi_version="" |
| 2658 | cf_cv_rel_version="" |
| 2659 | includesubdir="" |
| 2660 | |
| 2661 | cf_cv_screen=curses |
| 2662 | cf_cv_libtype= |
| 2663 | |
| 2664 | if test "$GCC" = yes |
| 2665 | then |
| 2666 | cat > conftest.i <<EOF |
| 2667 | #ifndef GCC_PRINTF |
| 2668 | #define GCC_PRINTF 0 |
| 2669 | #endif |
| 2670 | #ifndef GCC_SCANF |
| 2671 | #define GCC_SCANF 0 |
| 2672 | #endif |
| 2673 | #ifndef GCC_NORETURN |
| 2674 | #define GCC_NORETURN /* nothing */ |
| 2675 | #endif |
| 2676 | #ifndef GCC_UNUSED |
| 2677 | #define GCC_UNUSED /* nothing */ |
| 2678 | #endif |
| 2679 | EOF |
| 2680 | if test "$GCC" = yes |
| 2681 | then |
| 2682 | { echo "$as_me:2682: checking for $CC __attribute__ directives..." >&5 |
| 2683 | echo "$as_me: checking for $CC __attribute__ directives..." >&6;} |
| 2684 | cat > conftest.$ac_ext <<EOF |
| 2685 | #line 2685 "${as_me:-configure}" |
| 2686 | #include "confdefs.h" |
| 2687 | #include "conftest.h" |
| 2688 | #include "conftest.i" |
| 2689 | #if GCC_PRINTF |
| 2690 | #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var))) |
| 2691 | #else |
| 2692 | #define GCC_PRINTFLIKE(fmt,var) /*nothing*/ |
| 2693 | #endif |
| 2694 | #if GCC_SCANF |
| 2695 | #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var))) |
| 2696 | #else |
| 2697 | #define GCC_SCANFLIKE(fmt,var) /*nothing*/ |
| 2698 | #endif |
| 2699 | extern void wow(char *,...) GCC_SCANFLIKE(1,2); |
| 2700 | extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN; |
| 2701 | extern void foo(void) GCC_NORETURN; |
| 2702 | int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; } |
| 2703 | EOF |
| 2704 | cf_printf_attribute=no |
| 2705 | cf_scanf_attribute=no |
| 2706 | for cf_attribute in scanf printf unused noreturn |
| 2707 | do |
| 2708 | |
| 2709 | cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 2710 | |
| 2711 | cf_directive="__attribute__(($cf_attribute))" |
| 2712 | echo "checking for $CC $cf_directive" 1>&5 |
| 2713 | |
| 2714 | case $cf_attribute in |
| 2715 | (printf) |
| 2716 | cf_printf_attribute=yes |
| 2717 | cat >conftest.h <<EOF |
| 2718 | #define GCC_$cf_ATTRIBUTE 1 |
| 2719 | EOF |
| 2720 | ;; |
| 2721 | (scanf) |
| 2722 | cf_scanf_attribute=yes |
| 2723 | cat >conftest.h <<EOF |
| 2724 | #define GCC_$cf_ATTRIBUTE 1 |
| 2725 | EOF |
| 2726 | ;; |
| 2727 | (*) |
| 2728 | cat >conftest.h <<EOF |
| 2729 | #define GCC_$cf_ATTRIBUTE $cf_directive |
| 2730 | EOF |
| 2731 | ;; |
| 2732 | esac |
| 2733 | |
| 2734 | if { (eval echo "$as_me:2734: \"$ac_compile\"") >&5 |
| 2735 | (eval $ac_compile) 2>&5 |
| 2736 | ac_status=$? |
| 2737 | echo "$as_me:2737: \$? = $ac_status" >&5 |
| 2738 | (exit $ac_status); }; then |
| 2739 | test -n "$verbose" && echo "$as_me:2739: result: ... $cf_attribute" >&5 |
| 2740 | echo "${ECHO_T}... $cf_attribute" >&6 |
| 2741 | cat conftest.h >>confdefs.h |
| 2742 | case $cf_attribute in |
| 2743 | (noreturn) |
| 2744 | |
| 2745 | cat >>confdefs.h <<EOF |
| 2746 | #define GCC_NORETURN $cf_directive |
| 2747 | EOF |
| 2748 | |
| 2749 | ;; |
| 2750 | (printf) |
| 2751 | cf_value='/* nothing */' |
| 2752 | if test "$cf_printf_attribute" != no ; then |
| 2753 | cf_value='__attribute__((format(printf,fmt,var)))' |
| 2754 | |
| 2755 | cat >>confdefs.h <<\EOF |
| 2756 | #define GCC_PRINTF 1 |
| 2757 | EOF |
| 2758 | |
| 2759 | fi |
| 2760 | |
| 2761 | cat >>confdefs.h <<EOF |
| 2762 | #define GCC_PRINTFLIKE(fmt,var) $cf_value |
| 2763 | EOF |
| 2764 | |
| 2765 | ;; |
| 2766 | (scanf) |
| 2767 | cf_value='/* nothing */' |
| 2768 | if test "$cf_scanf_attribute" != no ; then |
| 2769 | cf_value='__attribute__((format(scanf,fmt,var)))' |
| 2770 | |
| 2771 | cat >>confdefs.h <<\EOF |
| 2772 | #define GCC_SCANF 1 |
| 2773 | EOF |
| 2774 | |
| 2775 | fi |
| 2776 | |
| 2777 | cat >>confdefs.h <<EOF |
| 2778 | #define GCC_SCANFLIKE(fmt,var) $cf_value |
| 2779 | EOF |
| 2780 | |
| 2781 | ;; |
| 2782 | (unused) |
| 2783 | |
| 2784 | cat >>confdefs.h <<EOF |
| 2785 | #define GCC_UNUSED $cf_directive |
| 2786 | EOF |
| 2787 | |
| 2788 | ;; |
| 2789 | esac |
| 2790 | fi |
| 2791 | done |
| 2792 | else |
| 2793 | fgrep define conftest.i >>confdefs.h |
| 2794 | fi |
| 2795 | rm -rf conftest* |
| 2796 | fi |
| 2797 | |
| 2798 | cf_XOPEN_SOURCE=500 |
| 2799 | cf_POSIX_C_SOURCE=199506L |
| 2800 | cf_xopen_source= |
| 2801 | |
| 2802 | case $host_os in |
| 2803 | (aix[4-7]*) |
| 2804 | cf_xopen_source="-D_ALL_SOURCE" |
| 2805 | ;; |
| 2806 | (cygwin|msys) |
| 2807 | cf_XOPEN_SOURCE=600 |
| 2808 | ;; |
| 2809 | (darwin[0-8].*) |
| 2810 | cf_xopen_source="-D_APPLE_C_SOURCE" |
| 2811 | ;; |
| 2812 | (darwin*) |
| 2813 | cf_xopen_source="-D_DARWIN_C_SOURCE" |
| 2814 | cf_XOPEN_SOURCE= |
| 2815 | ;; |
| 2816 | (freebsd*|dragonfly*) |
| 2817 | # 5.x headers associate |
| 2818 | # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L |
| 2819 | # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L |
| 2820 | cf_POSIX_C_SOURCE=200112L |
| 2821 | cf_XOPEN_SOURCE=600 |
| 2822 | cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" |
| 2823 | ;; |
| 2824 | (hpux11*) |
| 2825 | cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500" |
| 2826 | ;; |
| 2827 | (hpux*) |
| 2828 | cf_xopen_source="-D_HPUX_SOURCE" |
| 2829 | ;; |
| 2830 | (irix[56].*) |
| 2831 | cf_xopen_source="-D_SGI_SOURCE" |
| 2832 | cf_XOPEN_SOURCE= |
| 2833 | ;; |
| 2834 | (linux*|gnu*|mint*|k*bsd*-gnu) |
| 2835 | |
| 2836 | echo "$as_me:2836: checking if we must define _GNU_SOURCE" >&5 |
| 2837 | echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6 |
| 2838 | if test "${cf_cv_gnu_source+set}" = set; then |
| 2839 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2840 | else |
| 2841 | |
| 2842 | cat >conftest.$ac_ext <<_ACEOF |
| 2843 | #line 2843 "configure" |
| 2844 | #include "confdefs.h" |
| 2845 | #include <sys/types.h> |
| 2846 | int |
| 2847 | main () |
| 2848 | { |
| 2849 | |
| 2850 | #ifndef _XOPEN_SOURCE |
| 2851 | make an error |
| 2852 | #endif |
| 2853 | ; |
| 2854 | return 0; |
| 2855 | } |
| 2856 | _ACEOF |
| 2857 | rm -f conftest.$ac_objext |
| 2858 | if { (eval echo "$as_me:2858: \"$ac_compile\"") >&5 |
| 2859 | (eval $ac_compile) 2>&5 |
| 2860 | ac_status=$? |
| 2861 | echo "$as_me:2861: \$? = $ac_status" >&5 |
| 2862 | (exit $ac_status); } && |
| 2863 | { ac_try='test -s conftest.$ac_objext' |
| 2864 | { (eval echo "$as_me:2864: \"$ac_try\"") >&5 |
| 2865 | (eval $ac_try) 2>&5 |
| 2866 | ac_status=$? |
| 2867 | echo "$as_me:2867: \$? = $ac_status" >&5 |
| 2868 | (exit $ac_status); }; }; then |
| 2869 | cf_cv_gnu_source=no |
| 2870 | else |
| 2871 | echo "$as_me: failed program was:" >&5 |
| 2872 | cat conftest.$ac_ext >&5 |
| 2873 | cf_save="$CPPFLAGS" |
| 2874 | CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" |
| 2875 | cat >conftest.$ac_ext <<_ACEOF |
| 2876 | #line 2876 "configure" |
| 2877 | #include "confdefs.h" |
| 2878 | #include <sys/types.h> |
| 2879 | int |
| 2880 | main () |
| 2881 | { |
| 2882 | |
| 2883 | #ifdef _XOPEN_SOURCE |
| 2884 | make an error |
| 2885 | #endif |
| 2886 | ; |
| 2887 | return 0; |
| 2888 | } |
| 2889 | _ACEOF |
| 2890 | rm -f conftest.$ac_objext |
| 2891 | if { (eval echo "$as_me:2891: \"$ac_compile\"") >&5 |
| 2892 | (eval $ac_compile) 2>&5 |
| 2893 | ac_status=$? |
| 2894 | echo "$as_me:2894: \$? = $ac_status" >&5 |
| 2895 | (exit $ac_status); } && |
| 2896 | { ac_try='test -s conftest.$ac_objext' |
| 2897 | { (eval echo "$as_me:2897: \"$ac_try\"") >&5 |
| 2898 | (eval $ac_try) 2>&5 |
| 2899 | ac_status=$? |
| 2900 | echo "$as_me:2900: \$? = $ac_status" >&5 |
| 2901 | (exit $ac_status); }; }; then |
| 2902 | cf_cv_gnu_source=no |
| 2903 | else |
| 2904 | echo "$as_me: failed program was:" >&5 |
| 2905 | cat conftest.$ac_ext >&5 |
| 2906 | cf_cv_gnu_source=yes |
| 2907 | fi |
| 2908 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2909 | CPPFLAGS="$cf_save" |
| 2910 | |
| 2911 | fi |
| 2912 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2913 | |
| 2914 | fi |
| 2915 | echo "$as_me:2915: result: $cf_cv_gnu_source" >&5 |
| 2916 | echo "${ECHO_T}$cf_cv_gnu_source" >&6 |
| 2917 | test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" |
| 2918 | |
| 2919 | ;; |
| 2920 | (minix*) |
| 2921 | cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this... |
| 2922 | ;; |
| 2923 | (mirbsd*) |
| 2924 | # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types |
| 2925 | cf_XOPEN_SOURCE= |
| 2926 | |
| 2927 | cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE |
| 2928 | |
| 2929 | cf_save_CFLAGS="$CFLAGS" |
| 2930 | cf_save_CPPFLAGS="$CPPFLAGS" |
| 2931 | |
| 2932 | cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \ |
| 2933 | sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 2934 | -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 2935 | |
| 2936 | cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \ |
| 2937 | sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 2938 | -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 2939 | |
| 2940 | echo "$as_me:2940: checking if we should define _POSIX_C_SOURCE" >&5 |
| 2941 | echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6 |
| 2942 | if test "${cf_cv_posix_c_source+set}" = set; then |
| 2943 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2944 | else |
| 2945 | |
| 2946 | echo "${as_me:-configure}:2946: testing if the symbol is already defined go no further ..." 1>&5 |
| 2947 | |
| 2948 | cat >conftest.$ac_ext <<_ACEOF |
| 2949 | #line 2949 "configure" |
| 2950 | #include "confdefs.h" |
| 2951 | #include <sys/types.h> |
| 2952 | int |
| 2953 | main () |
| 2954 | { |
| 2955 | |
| 2956 | #ifndef _POSIX_C_SOURCE |
| 2957 | make an error |
| 2958 | #endif |
| 2959 | ; |
| 2960 | return 0; |
| 2961 | } |
| 2962 | _ACEOF |
| 2963 | rm -f conftest.$ac_objext |
| 2964 | if { (eval echo "$as_me:2964: \"$ac_compile\"") >&5 |
| 2965 | (eval $ac_compile) 2>&5 |
| 2966 | ac_status=$? |
| 2967 | echo "$as_me:2967: \$? = $ac_status" >&5 |
| 2968 | (exit $ac_status); } && |
| 2969 | { ac_try='test -s conftest.$ac_objext' |
| 2970 | { (eval echo "$as_me:2970: \"$ac_try\"") >&5 |
| 2971 | (eval $ac_try) 2>&5 |
| 2972 | ac_status=$? |
| 2973 | echo "$as_me:2973: \$? = $ac_status" >&5 |
| 2974 | (exit $ac_status); }; }; then |
| 2975 | cf_cv_posix_c_source=no |
| 2976 | else |
| 2977 | echo "$as_me: failed program was:" >&5 |
| 2978 | cat conftest.$ac_ext >&5 |
| 2979 | cf_want_posix_source=no |
| 2980 | case .$cf_POSIX_C_SOURCE in |
| 2981 | (.[12]??*) |
| 2982 | cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" |
| 2983 | ;; |
| 2984 | (.2) |
| 2985 | cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" |
| 2986 | cf_want_posix_source=yes |
| 2987 | ;; |
| 2988 | (.*) |
| 2989 | cf_want_posix_source=yes |
| 2990 | ;; |
| 2991 | esac |
| 2992 | if test "$cf_want_posix_source" = yes ; then |
| 2993 | cat >conftest.$ac_ext <<_ACEOF |
| 2994 | #line 2994 "configure" |
| 2995 | #include "confdefs.h" |
| 2996 | #include <sys/types.h> |
| 2997 | int |
| 2998 | main () |
| 2999 | { |
| 3000 | |
| 3001 | #ifdef _POSIX_SOURCE |
| 3002 | make an error |
| 3003 | #endif |
| 3004 | ; |
| 3005 | return 0; |
| 3006 | } |
| 3007 | _ACEOF |
| 3008 | rm -f conftest.$ac_objext |
| 3009 | if { (eval echo "$as_me:3009: \"$ac_compile\"") >&5 |
| 3010 | (eval $ac_compile) 2>&5 |
| 3011 | ac_status=$? |
| 3012 | echo "$as_me:3012: \$? = $ac_status" >&5 |
| 3013 | (exit $ac_status); } && |
| 3014 | { ac_try='test -s conftest.$ac_objext' |
| 3015 | { (eval echo "$as_me:3015: \"$ac_try\"") >&5 |
| 3016 | (eval $ac_try) 2>&5 |
| 3017 | ac_status=$? |
| 3018 | echo "$as_me:3018: \$? = $ac_status" >&5 |
| 3019 | (exit $ac_status); }; }; then |
| 3020 | : |
| 3021 | else |
| 3022 | echo "$as_me: failed program was:" >&5 |
| 3023 | cat conftest.$ac_ext >&5 |
| 3024 | cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE" |
| 3025 | fi |
| 3026 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3027 | fi |
| 3028 | |
| 3029 | echo "${as_me:-configure}:3029: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5 |
| 3030 | |
| 3031 | CFLAGS="$cf_trim_CFLAGS" |
| 3032 | CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source" |
| 3033 | |
| 3034 | echo "${as_me:-configure}:3034: testing if the second compile does not leave our definition intact error ..." 1>&5 |
| 3035 | |
| 3036 | cat >conftest.$ac_ext <<_ACEOF |
| 3037 | #line 3037 "configure" |
| 3038 | #include "confdefs.h" |
| 3039 | #include <sys/types.h> |
| 3040 | int |
| 3041 | main () |
| 3042 | { |
| 3043 | |
| 3044 | #ifndef _POSIX_C_SOURCE |
| 3045 | make an error |
| 3046 | #endif |
| 3047 | ; |
| 3048 | return 0; |
| 3049 | } |
| 3050 | _ACEOF |
| 3051 | rm -f conftest.$ac_objext |
| 3052 | if { (eval echo "$as_me:3052: \"$ac_compile\"") >&5 |
| 3053 | (eval $ac_compile) 2>&5 |
| 3054 | ac_status=$? |
| 3055 | echo "$as_me:3055: \$? = $ac_status" >&5 |
| 3056 | (exit $ac_status); } && |
| 3057 | { ac_try='test -s conftest.$ac_objext' |
| 3058 | { (eval echo "$as_me:3058: \"$ac_try\"") >&5 |
| 3059 | (eval $ac_try) 2>&5 |
| 3060 | ac_status=$? |
| 3061 | echo "$as_me:3061: \$? = $ac_status" >&5 |
| 3062 | (exit $ac_status); }; }; then |
| 3063 | : |
| 3064 | else |
| 3065 | echo "$as_me: failed program was:" >&5 |
| 3066 | cat conftest.$ac_ext >&5 |
| 3067 | cf_cv_posix_c_source=no |
| 3068 | fi |
| 3069 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3070 | CFLAGS="$cf_save_CFLAGS" |
| 3071 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 3072 | |
| 3073 | fi |
| 3074 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3075 | |
| 3076 | fi |
| 3077 | echo "$as_me:3077: result: $cf_cv_posix_c_source" >&5 |
| 3078 | echo "${ECHO_T}$cf_cv_posix_c_source" >&6 |
| 3079 | |
| 3080 | if test "$cf_cv_posix_c_source" != no ; then |
| 3081 | CFLAGS="$cf_trim_CFLAGS" |
| 3082 | CPPFLAGS="$cf_trim_CPPFLAGS" |
| 3083 | |
| 3084 | cf_fix_cppflags=no |
| 3085 | cf_new_cflags= |
| 3086 | cf_new_cppflags= |
| 3087 | cf_new_extra_cppflags= |
| 3088 | |
| 3089 | for cf_add_cflags in $cf_cv_posix_c_source |
| 3090 | do |
| 3091 | case $cf_fix_cppflags in |
| 3092 | (no) |
| 3093 | case $cf_add_cflags in |
| 3094 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 3095 | case $cf_add_cflags in |
| 3096 | (-D*) |
| 3097 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 3098 | |
| 3099 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3100 | && test -z "${cf_tst_cflags}" \ |
| 3101 | && cf_fix_cppflags=yes |
| 3102 | |
| 3103 | if test $cf_fix_cppflags = yes ; then |
| 3104 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3105 | continue |
| 3106 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 3107 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3108 | continue |
| 3109 | fi |
| 3110 | ;; |
| 3111 | esac |
| 3112 | case "$CPPFLAGS" in |
| 3113 | (*$cf_add_cflags) |
| 3114 | ;; |
| 3115 | (*) |
| 3116 | case $cf_add_cflags in |
| 3117 | (-D*) |
| 3118 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 3119 | |
| 3120 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 3121 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3122 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 3123 | |
| 3124 | ;; |
| 3125 | esac |
| 3126 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 3127 | ;; |
| 3128 | esac |
| 3129 | ;; |
| 3130 | (*) |
| 3131 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 3132 | ;; |
| 3133 | esac |
| 3134 | ;; |
| 3135 | (yes) |
| 3136 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3137 | |
| 3138 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 3139 | |
| 3140 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3141 | && test -z "${cf_tst_cflags}" \ |
| 3142 | && cf_fix_cppflags=no |
| 3143 | ;; |
| 3144 | esac |
| 3145 | done |
| 3146 | |
| 3147 | if test -n "$cf_new_cflags" ; then |
| 3148 | |
| 3149 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 3150 | fi |
| 3151 | |
| 3152 | if test -n "$cf_new_cppflags" ; then |
| 3153 | |
| 3154 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 3155 | fi |
| 3156 | |
| 3157 | if test -n "$cf_new_extra_cppflags" ; then |
| 3158 | |
| 3159 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 3160 | fi |
| 3161 | |
| 3162 | fi |
| 3163 | |
| 3164 | ;; |
| 3165 | (netbsd*) |
| 3166 | cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw |
| 3167 | ;; |
| 3168 | (openbsd[4-9]*) |
| 3169 | # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw |
| 3170 | cf_xopen_source="-D_BSD_SOURCE" |
| 3171 | cf_XOPEN_SOURCE=600 |
| 3172 | ;; |
| 3173 | (openbsd*) |
| 3174 | # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw |
| 3175 | ;; |
| 3176 | (osf[45]*) |
| 3177 | cf_xopen_source="-D_OSF_SOURCE" |
| 3178 | ;; |
| 3179 | (nto-qnx*) |
| 3180 | cf_xopen_source="-D_QNX_SOURCE" |
| 3181 | ;; |
| 3182 | (sco*) |
| 3183 | # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer |
| 3184 | ;; |
| 3185 | (solaris2.*) |
| 3186 | cf_xopen_source="-D__EXTENSIONS__" |
| 3187 | cf_cv_xopen_source=broken |
| 3188 | ;; |
| 3189 | (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2) |
| 3190 | cf_XOPEN_SOURCE= |
| 3191 | cf_POSIX_C_SOURCE= |
| 3192 | ;; |
| 3193 | (*) |
| 3194 | |
| 3195 | echo "$as_me:3195: checking if we should define _XOPEN_SOURCE" >&5 |
| 3196 | echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6 |
| 3197 | if test "${cf_cv_xopen_source+set}" = set; then |
| 3198 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3199 | else |
| 3200 | |
| 3201 | cat >conftest.$ac_ext <<_ACEOF |
| 3202 | #line 3202 "configure" |
| 3203 | #include "confdefs.h" |
| 3204 | |
| 3205 | #include <stdlib.h> |
| 3206 | #include <string.h> |
| 3207 | #include <sys/types.h> |
| 3208 | |
| 3209 | int |
| 3210 | main () |
| 3211 | { |
| 3212 | |
| 3213 | #ifndef _XOPEN_SOURCE |
| 3214 | make an error |
| 3215 | #endif |
| 3216 | ; |
| 3217 | return 0; |
| 3218 | } |
| 3219 | _ACEOF |
| 3220 | rm -f conftest.$ac_objext |
| 3221 | if { (eval echo "$as_me:3221: \"$ac_compile\"") >&5 |
| 3222 | (eval $ac_compile) 2>&5 |
| 3223 | ac_status=$? |
| 3224 | echo "$as_me:3224: \$? = $ac_status" >&5 |
| 3225 | (exit $ac_status); } && |
| 3226 | { ac_try='test -s conftest.$ac_objext' |
| 3227 | { (eval echo "$as_me:3227: \"$ac_try\"") >&5 |
| 3228 | (eval $ac_try) 2>&5 |
| 3229 | ac_status=$? |
| 3230 | echo "$as_me:3230: \$? = $ac_status" >&5 |
| 3231 | (exit $ac_status); }; }; then |
| 3232 | cf_cv_xopen_source=no |
| 3233 | else |
| 3234 | echo "$as_me: failed program was:" >&5 |
| 3235 | cat conftest.$ac_ext >&5 |
| 3236 | cf_save="$CPPFLAGS" |
| 3237 | CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" |
| 3238 | cat >conftest.$ac_ext <<_ACEOF |
| 3239 | #line 3239 "configure" |
| 3240 | #include "confdefs.h" |
| 3241 | |
| 3242 | #include <stdlib.h> |
| 3243 | #include <string.h> |
| 3244 | #include <sys/types.h> |
| 3245 | |
| 3246 | int |
| 3247 | main () |
| 3248 | { |
| 3249 | |
| 3250 | #ifdef _XOPEN_SOURCE |
| 3251 | make an error |
| 3252 | #endif |
| 3253 | ; |
| 3254 | return 0; |
| 3255 | } |
| 3256 | _ACEOF |
| 3257 | rm -f conftest.$ac_objext |
| 3258 | if { (eval echo "$as_me:3258: \"$ac_compile\"") >&5 |
| 3259 | (eval $ac_compile) 2>&5 |
| 3260 | ac_status=$? |
| 3261 | echo "$as_me:3261: \$? = $ac_status" >&5 |
| 3262 | (exit $ac_status); } && |
| 3263 | { ac_try='test -s conftest.$ac_objext' |
| 3264 | { (eval echo "$as_me:3264: \"$ac_try\"") >&5 |
| 3265 | (eval $ac_try) 2>&5 |
| 3266 | ac_status=$? |
| 3267 | echo "$as_me:3267: \$? = $ac_status" >&5 |
| 3268 | (exit $ac_status); }; }; then |
| 3269 | cf_cv_xopen_source=no |
| 3270 | else |
| 3271 | echo "$as_me: failed program was:" >&5 |
| 3272 | cat conftest.$ac_ext >&5 |
| 3273 | cf_cv_xopen_source=$cf_XOPEN_SOURCE |
| 3274 | fi |
| 3275 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3276 | CPPFLAGS="$cf_save" |
| 3277 | |
| 3278 | fi |
| 3279 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3280 | |
| 3281 | fi |
| 3282 | echo "$as_me:3282: result: $cf_cv_xopen_source" >&5 |
| 3283 | echo "${ECHO_T}$cf_cv_xopen_source" >&6 |
| 3284 | |
| 3285 | if test "$cf_cv_xopen_source" != no ; then |
| 3286 | |
| 3287 | CFLAGS=`echo "$CFLAGS" | \ |
| 3288 | sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3289 | -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 3290 | |
| 3291 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 3292 | sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3293 | -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 3294 | |
| 3295 | cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source" |
| 3296 | |
| 3297 | cf_fix_cppflags=no |
| 3298 | cf_new_cflags= |
| 3299 | cf_new_cppflags= |
| 3300 | cf_new_extra_cppflags= |
| 3301 | |
| 3302 | for cf_add_cflags in $cf_temp_xopen_source |
| 3303 | do |
| 3304 | case $cf_fix_cppflags in |
| 3305 | (no) |
| 3306 | case $cf_add_cflags in |
| 3307 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 3308 | case $cf_add_cflags in |
| 3309 | (-D*) |
| 3310 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 3311 | |
| 3312 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3313 | && test -z "${cf_tst_cflags}" \ |
| 3314 | && cf_fix_cppflags=yes |
| 3315 | |
| 3316 | if test $cf_fix_cppflags = yes ; then |
| 3317 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3318 | continue |
| 3319 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 3320 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3321 | continue |
| 3322 | fi |
| 3323 | ;; |
| 3324 | esac |
| 3325 | case "$CPPFLAGS" in |
| 3326 | (*$cf_add_cflags) |
| 3327 | ;; |
| 3328 | (*) |
| 3329 | case $cf_add_cflags in |
| 3330 | (-D*) |
| 3331 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 3332 | |
| 3333 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 3334 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3335 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 3336 | |
| 3337 | ;; |
| 3338 | esac |
| 3339 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 3340 | ;; |
| 3341 | esac |
| 3342 | ;; |
| 3343 | (*) |
| 3344 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 3345 | ;; |
| 3346 | esac |
| 3347 | ;; |
| 3348 | (yes) |
| 3349 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3350 | |
| 3351 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 3352 | |
| 3353 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3354 | && test -z "${cf_tst_cflags}" \ |
| 3355 | && cf_fix_cppflags=no |
| 3356 | ;; |
| 3357 | esac |
| 3358 | done |
| 3359 | |
| 3360 | if test -n "$cf_new_cflags" ; then |
| 3361 | |
| 3362 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 3363 | fi |
| 3364 | |
| 3365 | if test -n "$cf_new_cppflags" ; then |
| 3366 | |
| 3367 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 3368 | fi |
| 3369 | |
| 3370 | if test -n "$cf_new_extra_cppflags" ; then |
| 3371 | |
| 3372 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 3373 | fi |
| 3374 | |
| 3375 | fi |
| 3376 | |
| 3377 | cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE |
| 3378 | |
| 3379 | cf_save_CFLAGS="$CFLAGS" |
| 3380 | cf_save_CPPFLAGS="$CPPFLAGS" |
| 3381 | |
| 3382 | cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \ |
| 3383 | sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3384 | -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 3385 | |
| 3386 | cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \ |
| 3387 | sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3388 | -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 3389 | |
| 3390 | echo "$as_me:3390: checking if we should define _POSIX_C_SOURCE" >&5 |
| 3391 | echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6 |
| 3392 | if test "${cf_cv_posix_c_source+set}" = set; then |
| 3393 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3394 | else |
| 3395 | |
| 3396 | echo "${as_me:-configure}:3396: testing if the symbol is already defined go no further ..." 1>&5 |
| 3397 | |
| 3398 | cat >conftest.$ac_ext <<_ACEOF |
| 3399 | #line 3399 "configure" |
| 3400 | #include "confdefs.h" |
| 3401 | #include <sys/types.h> |
| 3402 | int |
| 3403 | main () |
| 3404 | { |
| 3405 | |
| 3406 | #ifndef _POSIX_C_SOURCE |
| 3407 | make an error |
| 3408 | #endif |
| 3409 | ; |
| 3410 | return 0; |
| 3411 | } |
| 3412 | _ACEOF |
| 3413 | rm -f conftest.$ac_objext |
| 3414 | if { (eval echo "$as_me:3414: \"$ac_compile\"") >&5 |
| 3415 | (eval $ac_compile) 2>&5 |
| 3416 | ac_status=$? |
| 3417 | echo "$as_me:3417: \$? = $ac_status" >&5 |
| 3418 | (exit $ac_status); } && |
| 3419 | { ac_try='test -s conftest.$ac_objext' |
| 3420 | { (eval echo "$as_me:3420: \"$ac_try\"") >&5 |
| 3421 | (eval $ac_try) 2>&5 |
| 3422 | ac_status=$? |
| 3423 | echo "$as_me:3423: \$? = $ac_status" >&5 |
| 3424 | (exit $ac_status); }; }; then |
| 3425 | cf_cv_posix_c_source=no |
| 3426 | else |
| 3427 | echo "$as_me: failed program was:" >&5 |
| 3428 | cat conftest.$ac_ext >&5 |
| 3429 | cf_want_posix_source=no |
| 3430 | case .$cf_POSIX_C_SOURCE in |
| 3431 | (.[12]??*) |
| 3432 | cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" |
| 3433 | ;; |
| 3434 | (.2) |
| 3435 | cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" |
| 3436 | cf_want_posix_source=yes |
| 3437 | ;; |
| 3438 | (.*) |
| 3439 | cf_want_posix_source=yes |
| 3440 | ;; |
| 3441 | esac |
| 3442 | if test "$cf_want_posix_source" = yes ; then |
| 3443 | cat >conftest.$ac_ext <<_ACEOF |
| 3444 | #line 3444 "configure" |
| 3445 | #include "confdefs.h" |
| 3446 | #include <sys/types.h> |
| 3447 | int |
| 3448 | main () |
| 3449 | { |
| 3450 | |
| 3451 | #ifdef _POSIX_SOURCE |
| 3452 | make an error |
| 3453 | #endif |
| 3454 | ; |
| 3455 | return 0; |
| 3456 | } |
| 3457 | _ACEOF |
| 3458 | rm -f conftest.$ac_objext |
| 3459 | if { (eval echo "$as_me:3459: \"$ac_compile\"") >&5 |
| 3460 | (eval $ac_compile) 2>&5 |
| 3461 | ac_status=$? |
| 3462 | echo "$as_me:3462: \$? = $ac_status" >&5 |
| 3463 | (exit $ac_status); } && |
| 3464 | { ac_try='test -s conftest.$ac_objext' |
| 3465 | { (eval echo "$as_me:3465: \"$ac_try\"") >&5 |
| 3466 | (eval $ac_try) 2>&5 |
| 3467 | ac_status=$? |
| 3468 | echo "$as_me:3468: \$? = $ac_status" >&5 |
| 3469 | (exit $ac_status); }; }; then |
| 3470 | : |
| 3471 | else |
| 3472 | echo "$as_me: failed program was:" >&5 |
| 3473 | cat conftest.$ac_ext >&5 |
| 3474 | cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE" |
| 3475 | fi |
| 3476 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3477 | fi |
| 3478 | |
| 3479 | echo "${as_me:-configure}:3479: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5 |
| 3480 | |
| 3481 | CFLAGS="$cf_trim_CFLAGS" |
| 3482 | CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source" |
| 3483 | |
| 3484 | echo "${as_me:-configure}:3484: testing if the second compile does not leave our definition intact error ..." 1>&5 |
| 3485 | |
| 3486 | cat >conftest.$ac_ext <<_ACEOF |
| 3487 | #line 3487 "configure" |
| 3488 | #include "confdefs.h" |
| 3489 | #include <sys/types.h> |
| 3490 | int |
| 3491 | main () |
| 3492 | { |
| 3493 | |
| 3494 | #ifndef _POSIX_C_SOURCE |
| 3495 | make an error |
| 3496 | #endif |
| 3497 | ; |
| 3498 | return 0; |
| 3499 | } |
| 3500 | _ACEOF |
| 3501 | rm -f conftest.$ac_objext |
| 3502 | if { (eval echo "$as_me:3502: \"$ac_compile\"") >&5 |
| 3503 | (eval $ac_compile) 2>&5 |
| 3504 | ac_status=$? |
| 3505 | echo "$as_me:3505: \$? = $ac_status" >&5 |
| 3506 | (exit $ac_status); } && |
| 3507 | { ac_try='test -s conftest.$ac_objext' |
| 3508 | { (eval echo "$as_me:3508: \"$ac_try\"") >&5 |
| 3509 | (eval $ac_try) 2>&5 |
| 3510 | ac_status=$? |
| 3511 | echo "$as_me:3511: \$? = $ac_status" >&5 |
| 3512 | (exit $ac_status); }; }; then |
| 3513 | : |
| 3514 | else |
| 3515 | echo "$as_me: failed program was:" >&5 |
| 3516 | cat conftest.$ac_ext >&5 |
| 3517 | cf_cv_posix_c_source=no |
| 3518 | fi |
| 3519 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3520 | CFLAGS="$cf_save_CFLAGS" |
| 3521 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 3522 | |
| 3523 | fi |
| 3524 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3525 | |
| 3526 | fi |
| 3527 | echo "$as_me:3527: result: $cf_cv_posix_c_source" >&5 |
| 3528 | echo "${ECHO_T}$cf_cv_posix_c_source" >&6 |
| 3529 | |
| 3530 | if test "$cf_cv_posix_c_source" != no ; then |
| 3531 | CFLAGS="$cf_trim_CFLAGS" |
| 3532 | CPPFLAGS="$cf_trim_CPPFLAGS" |
| 3533 | |
| 3534 | cf_fix_cppflags=no |
| 3535 | cf_new_cflags= |
| 3536 | cf_new_cppflags= |
| 3537 | cf_new_extra_cppflags= |
| 3538 | |
| 3539 | for cf_add_cflags in $cf_cv_posix_c_source |
| 3540 | do |
| 3541 | case $cf_fix_cppflags in |
| 3542 | (no) |
| 3543 | case $cf_add_cflags in |
| 3544 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 3545 | case $cf_add_cflags in |
| 3546 | (-D*) |
| 3547 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 3548 | |
| 3549 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3550 | && test -z "${cf_tst_cflags}" \ |
| 3551 | && cf_fix_cppflags=yes |
| 3552 | |
| 3553 | if test $cf_fix_cppflags = yes ; then |
| 3554 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3555 | continue |
| 3556 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 3557 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3558 | continue |
| 3559 | fi |
| 3560 | ;; |
| 3561 | esac |
| 3562 | case "$CPPFLAGS" in |
| 3563 | (*$cf_add_cflags) |
| 3564 | ;; |
| 3565 | (*) |
| 3566 | case $cf_add_cflags in |
| 3567 | (-D*) |
| 3568 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 3569 | |
| 3570 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 3571 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3572 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 3573 | |
| 3574 | ;; |
| 3575 | esac |
| 3576 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 3577 | ;; |
| 3578 | esac |
| 3579 | ;; |
| 3580 | (*) |
| 3581 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 3582 | ;; |
| 3583 | esac |
| 3584 | ;; |
| 3585 | (yes) |
| 3586 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3587 | |
| 3588 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 3589 | |
| 3590 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3591 | && test -z "${cf_tst_cflags}" \ |
| 3592 | && cf_fix_cppflags=no |
| 3593 | ;; |
| 3594 | esac |
| 3595 | done |
| 3596 | |
| 3597 | if test -n "$cf_new_cflags" ; then |
| 3598 | |
| 3599 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 3600 | fi |
| 3601 | |
| 3602 | if test -n "$cf_new_cppflags" ; then |
| 3603 | |
| 3604 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 3605 | fi |
| 3606 | |
| 3607 | if test -n "$cf_new_extra_cppflags" ; then |
| 3608 | |
| 3609 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 3610 | fi |
| 3611 | |
| 3612 | fi |
| 3613 | |
| 3614 | ;; |
| 3615 | esac |
| 3616 | |
| 3617 | if test -n "$cf_xopen_source" ; then |
| 3618 | |
| 3619 | cf_fix_cppflags=no |
| 3620 | cf_new_cflags= |
| 3621 | cf_new_cppflags= |
| 3622 | cf_new_extra_cppflags= |
| 3623 | |
| 3624 | for cf_add_cflags in $cf_xopen_source |
| 3625 | do |
| 3626 | case $cf_fix_cppflags in |
| 3627 | (no) |
| 3628 | case $cf_add_cflags in |
| 3629 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 3630 | case $cf_add_cflags in |
| 3631 | (-D*) |
| 3632 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 3633 | |
| 3634 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3635 | && test -z "${cf_tst_cflags}" \ |
| 3636 | && cf_fix_cppflags=yes |
| 3637 | |
| 3638 | if test $cf_fix_cppflags = yes ; then |
| 3639 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3640 | continue |
| 3641 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 3642 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3643 | continue |
| 3644 | fi |
| 3645 | ;; |
| 3646 | esac |
| 3647 | case "$CPPFLAGS" in |
| 3648 | (*$cf_add_cflags) |
| 3649 | ;; |
| 3650 | (*) |
| 3651 | case $cf_add_cflags in |
| 3652 | (-D*) |
| 3653 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 3654 | |
| 3655 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 3656 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3657 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 3658 | |
| 3659 | ;; |
| 3660 | esac |
| 3661 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 3662 | ;; |
| 3663 | esac |
| 3664 | ;; |
| 3665 | (*) |
| 3666 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 3667 | ;; |
| 3668 | esac |
| 3669 | ;; |
| 3670 | (yes) |
| 3671 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3672 | |
| 3673 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 3674 | |
| 3675 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3676 | && test -z "${cf_tst_cflags}" \ |
| 3677 | && cf_fix_cppflags=no |
| 3678 | ;; |
| 3679 | esac |
| 3680 | done |
| 3681 | |
| 3682 | if test -n "$cf_new_cflags" ; then |
| 3683 | test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6 |
| 3684 | |
| 3685 | echo "${as_me:-configure}:3685: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5 |
| 3686 | |
| 3687 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 3688 | fi |
| 3689 | |
| 3690 | if test -n "$cf_new_cppflags" ; then |
| 3691 | test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6 |
| 3692 | |
| 3693 | echo "${as_me:-configure}:3693: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5 |
| 3694 | |
| 3695 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 3696 | fi |
| 3697 | |
| 3698 | if test -n "$cf_new_extra_cppflags" ; then |
| 3699 | test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6 |
| 3700 | |
| 3701 | echo "${as_me:-configure}:3701: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5 |
| 3702 | |
| 3703 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 3704 | fi |
| 3705 | |
| 3706 | fi |
| 3707 | |
| 3708 | if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then |
| 3709 | echo "$as_me:3709: checking if _XOPEN_SOURCE really is set" >&5 |
| 3710 | echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6 |
| 3711 | cat >conftest.$ac_ext <<_ACEOF |
| 3712 | #line 3712 "configure" |
| 3713 | #include "confdefs.h" |
| 3714 | #include <stdlib.h> |
| 3715 | int |
| 3716 | main () |
| 3717 | { |
| 3718 | |
| 3719 | #ifndef _XOPEN_SOURCE |
| 3720 | make an error |
| 3721 | #endif |
| 3722 | ; |
| 3723 | return 0; |
| 3724 | } |
| 3725 | _ACEOF |
| 3726 | rm -f conftest.$ac_objext |
| 3727 | if { (eval echo "$as_me:3727: \"$ac_compile\"") >&5 |
| 3728 | (eval $ac_compile) 2>&5 |
| 3729 | ac_status=$? |
| 3730 | echo "$as_me:3730: \$? = $ac_status" >&5 |
| 3731 | (exit $ac_status); } && |
| 3732 | { ac_try='test -s conftest.$ac_objext' |
| 3733 | { (eval echo "$as_me:3733: \"$ac_try\"") >&5 |
| 3734 | (eval $ac_try) 2>&5 |
| 3735 | ac_status=$? |
| 3736 | echo "$as_me:3736: \$? = $ac_status" >&5 |
| 3737 | (exit $ac_status); }; }; then |
| 3738 | cf_XOPEN_SOURCE_set=yes |
| 3739 | else |
| 3740 | echo "$as_me: failed program was:" >&5 |
| 3741 | cat conftest.$ac_ext >&5 |
| 3742 | cf_XOPEN_SOURCE_set=no |
| 3743 | fi |
| 3744 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3745 | echo "$as_me:3745: result: $cf_XOPEN_SOURCE_set" >&5 |
| 3746 | echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6 |
| 3747 | if test $cf_XOPEN_SOURCE_set = yes |
| 3748 | then |
| 3749 | cat >conftest.$ac_ext <<_ACEOF |
| 3750 | #line 3750 "configure" |
| 3751 | #include "confdefs.h" |
| 3752 | #include <stdlib.h> |
| 3753 | int |
| 3754 | main () |
| 3755 | { |
| 3756 | |
| 3757 | #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE |
| 3758 | make an error |
| 3759 | #endif |
| 3760 | ; |
| 3761 | return 0; |
| 3762 | } |
| 3763 | _ACEOF |
| 3764 | rm -f conftest.$ac_objext |
| 3765 | if { (eval echo "$as_me:3765: \"$ac_compile\"") >&5 |
| 3766 | (eval $ac_compile) 2>&5 |
| 3767 | ac_status=$? |
| 3768 | echo "$as_me:3768: \$? = $ac_status" >&5 |
| 3769 | (exit $ac_status); } && |
| 3770 | { ac_try='test -s conftest.$ac_objext' |
| 3771 | { (eval echo "$as_me:3771: \"$ac_try\"") >&5 |
| 3772 | (eval $ac_try) 2>&5 |
| 3773 | ac_status=$? |
| 3774 | echo "$as_me:3774: \$? = $ac_status" >&5 |
| 3775 | (exit $ac_status); }; }; then |
| 3776 | cf_XOPEN_SOURCE_set_ok=yes |
| 3777 | else |
| 3778 | echo "$as_me: failed program was:" >&5 |
| 3779 | cat conftest.$ac_ext >&5 |
| 3780 | cf_XOPEN_SOURCE_set_ok=no |
| 3781 | fi |
| 3782 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3783 | if test $cf_XOPEN_SOURCE_set_ok = no |
| 3784 | then |
| 3785 | { echo "$as_me:3785: WARNING: _XOPEN_SOURCE is lower than requested" >&5 |
| 3786 | echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;} |
| 3787 | fi |
| 3788 | else |
| 3789 | |
| 3790 | echo "$as_me:3790: checking if we should define _XOPEN_SOURCE" >&5 |
| 3791 | echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6 |
| 3792 | if test "${cf_cv_xopen_source+set}" = set; then |
| 3793 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3794 | else |
| 3795 | |
| 3796 | cat >conftest.$ac_ext <<_ACEOF |
| 3797 | #line 3797 "configure" |
| 3798 | #include "confdefs.h" |
| 3799 | |
| 3800 | #include <stdlib.h> |
| 3801 | #include <string.h> |
| 3802 | #include <sys/types.h> |
| 3803 | |
| 3804 | int |
| 3805 | main () |
| 3806 | { |
| 3807 | |
| 3808 | #ifndef _XOPEN_SOURCE |
| 3809 | make an error |
| 3810 | #endif |
| 3811 | ; |
| 3812 | return 0; |
| 3813 | } |
| 3814 | _ACEOF |
| 3815 | rm -f conftest.$ac_objext |
| 3816 | if { (eval echo "$as_me:3816: \"$ac_compile\"") >&5 |
| 3817 | (eval $ac_compile) 2>&5 |
| 3818 | ac_status=$? |
| 3819 | echo "$as_me:3819: \$? = $ac_status" >&5 |
| 3820 | (exit $ac_status); } && |
| 3821 | { ac_try='test -s conftest.$ac_objext' |
| 3822 | { (eval echo "$as_me:3822: \"$ac_try\"") >&5 |
| 3823 | (eval $ac_try) 2>&5 |
| 3824 | ac_status=$? |
| 3825 | echo "$as_me:3825: \$? = $ac_status" >&5 |
| 3826 | (exit $ac_status); }; }; then |
| 3827 | cf_cv_xopen_source=no |
| 3828 | else |
| 3829 | echo "$as_me: failed program was:" >&5 |
| 3830 | cat conftest.$ac_ext >&5 |
| 3831 | cf_save="$CPPFLAGS" |
| 3832 | CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" |
| 3833 | cat >conftest.$ac_ext <<_ACEOF |
| 3834 | #line 3834 "configure" |
| 3835 | #include "confdefs.h" |
| 3836 | |
| 3837 | #include <stdlib.h> |
| 3838 | #include <string.h> |
| 3839 | #include <sys/types.h> |
| 3840 | |
| 3841 | int |
| 3842 | main () |
| 3843 | { |
| 3844 | |
| 3845 | #ifdef _XOPEN_SOURCE |
| 3846 | make an error |
| 3847 | #endif |
| 3848 | ; |
| 3849 | return 0; |
| 3850 | } |
| 3851 | _ACEOF |
| 3852 | rm -f conftest.$ac_objext |
| 3853 | if { (eval echo "$as_me:3853: \"$ac_compile\"") >&5 |
| 3854 | (eval $ac_compile) 2>&5 |
| 3855 | ac_status=$? |
| 3856 | echo "$as_me:3856: \$? = $ac_status" >&5 |
| 3857 | (exit $ac_status); } && |
| 3858 | { ac_try='test -s conftest.$ac_objext' |
| 3859 | { (eval echo "$as_me:3859: \"$ac_try\"") >&5 |
| 3860 | (eval $ac_try) 2>&5 |
| 3861 | ac_status=$? |
| 3862 | echo "$as_me:3862: \$? = $ac_status" >&5 |
| 3863 | (exit $ac_status); }; }; then |
| 3864 | cf_cv_xopen_source=no |
| 3865 | else |
| 3866 | echo "$as_me: failed program was:" >&5 |
| 3867 | cat conftest.$ac_ext >&5 |
| 3868 | cf_cv_xopen_source=$cf_XOPEN_SOURCE |
| 3869 | fi |
| 3870 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3871 | CPPFLAGS="$cf_save" |
| 3872 | |
| 3873 | fi |
| 3874 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 3875 | |
| 3876 | fi |
| 3877 | echo "$as_me:3877: result: $cf_cv_xopen_source" >&5 |
| 3878 | echo "${ECHO_T}$cf_cv_xopen_source" >&6 |
| 3879 | |
| 3880 | if test "$cf_cv_xopen_source" != no ; then |
| 3881 | |
| 3882 | CFLAGS=`echo "$CFLAGS" | \ |
| 3883 | sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3884 | -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 3885 | |
| 3886 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 3887 | sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3888 | -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 3889 | |
| 3890 | cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source" |
| 3891 | |
| 3892 | cf_fix_cppflags=no |
| 3893 | cf_new_cflags= |
| 3894 | cf_new_cppflags= |
| 3895 | cf_new_extra_cppflags= |
| 3896 | |
| 3897 | for cf_add_cflags in $cf_temp_xopen_source |
| 3898 | do |
| 3899 | case $cf_fix_cppflags in |
| 3900 | (no) |
| 3901 | case $cf_add_cflags in |
| 3902 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 3903 | case $cf_add_cflags in |
| 3904 | (-D*) |
| 3905 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 3906 | |
| 3907 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3908 | && test -z "${cf_tst_cflags}" \ |
| 3909 | && cf_fix_cppflags=yes |
| 3910 | |
| 3911 | if test $cf_fix_cppflags = yes ; then |
| 3912 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3913 | continue |
| 3914 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 3915 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3916 | continue |
| 3917 | fi |
| 3918 | ;; |
| 3919 | esac |
| 3920 | case "$CPPFLAGS" in |
| 3921 | (*$cf_add_cflags) |
| 3922 | ;; |
| 3923 | (*) |
| 3924 | case $cf_add_cflags in |
| 3925 | (-D*) |
| 3926 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 3927 | |
| 3928 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 3929 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 3930 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 3931 | |
| 3932 | ;; |
| 3933 | esac |
| 3934 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 3935 | ;; |
| 3936 | esac |
| 3937 | ;; |
| 3938 | (*) |
| 3939 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 3940 | ;; |
| 3941 | esac |
| 3942 | ;; |
| 3943 | (yes) |
| 3944 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 3945 | |
| 3946 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 3947 | |
| 3948 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 3949 | && test -z "${cf_tst_cflags}" \ |
| 3950 | && cf_fix_cppflags=no |
| 3951 | ;; |
| 3952 | esac |
| 3953 | done |
| 3954 | |
| 3955 | if test -n "$cf_new_cflags" ; then |
| 3956 | |
| 3957 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 3958 | fi |
| 3959 | |
| 3960 | if test -n "$cf_new_cppflags" ; then |
| 3961 | |
| 3962 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 3963 | fi |
| 3964 | |
| 3965 | if test -n "$cf_new_extra_cppflags" ; then |
| 3966 | |
| 3967 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 3968 | fi |
| 3969 | |
| 3970 | fi |
| 3971 | |
| 3972 | fi |
| 3973 | fi |
| 3974 | |
| 3975 | echo "$as_me:3975: checking for signal global datatype" >&5 |
| 3976 | echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6 |
| 3977 | if test "${cf_cv_sig_atomic_t+set}" = set; then |
| 3978 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3979 | else |
| 3980 | |
| 3981 | for cf_type in \ |
| 3982 | "volatile sig_atomic_t" \ |
| 3983 | "sig_atomic_t" \ |
| 3984 | "int" |
| 3985 | do |
| 3986 | cat >conftest.$ac_ext <<_ACEOF |
| 3987 | #line 3987 "configure" |
| 3988 | #include "confdefs.h" |
| 3989 | |
| 3990 | #include <sys/types.h> |
| 3991 | #include <signal.h> |
| 3992 | #include <stdio.h> |
| 3993 | |
| 3994 | extern $cf_type x; |
| 3995 | $cf_type x; |
| 3996 | static void handler(int sig) |
| 3997 | { |
| 3998 | x = 5; |
| 3999 | } |
| 4000 | int |
| 4001 | main () |
| 4002 | { |
| 4003 | signal(SIGINT, handler); |
| 4004 | x = 1 |
| 4005 | ; |
| 4006 | return 0; |
| 4007 | } |
| 4008 | _ACEOF |
| 4009 | rm -f conftest.$ac_objext |
| 4010 | if { (eval echo "$as_me:4010: \"$ac_compile\"") >&5 |
| 4011 | (eval $ac_compile) 2>&5 |
| 4012 | ac_status=$? |
| 4013 | echo "$as_me:4013: \$? = $ac_status" >&5 |
| 4014 | (exit $ac_status); } && |
| 4015 | { ac_try='test -s conftest.$ac_objext' |
| 4016 | { (eval echo "$as_me:4016: \"$ac_try\"") >&5 |
| 4017 | (eval $ac_try) 2>&5 |
| 4018 | ac_status=$? |
| 4019 | echo "$as_me:4019: \$? = $ac_status" >&5 |
| 4020 | (exit $ac_status); }; }; then |
| 4021 | cf_cv_sig_atomic_t=$cf_type |
| 4022 | else |
| 4023 | echo "$as_me: failed program was:" >&5 |
| 4024 | cat conftest.$ac_ext >&5 |
| 4025 | cf_cv_sig_atomic_t=no |
| 4026 | fi |
| 4027 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 4028 | test "$cf_cv_sig_atomic_t" != no && break |
| 4029 | done |
| 4030 | |
| 4031 | fi |
| 4032 | |
| 4033 | echo "$as_me:4033: result: $cf_cv_sig_atomic_t" >&5 |
| 4034 | echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6 |
| 4035 | test "$cf_cv_sig_atomic_t" != no && |
| 4036 | cat >>confdefs.h <<EOF |
| 4037 | #define SIG_ATOMIC_T $cf_cv_sig_atomic_t |
| 4038 | EOF |
| 4039 | |
| 4040 | echo "$as_me:4040: checking if you want to use pkg-config" >&5 |
| 4041 | echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6 |
| 4042 | |
| 4043 | # Check whether --with-pkg-config or --without-pkg-config was given. |
| 4044 | if test "${with_pkg_config+set}" = set; then |
| 4045 | withval="$with_pkg_config" |
| 4046 | cf_pkg_config=$withval |
| 4047 | else |
| 4048 | cf_pkg_config=yes |
| 4049 | fi; |
| 4050 | echo "$as_me:4050: result: $cf_pkg_config" >&5 |
| 4051 | echo "${ECHO_T}$cf_pkg_config" >&6 |
| 4052 | |
| 4053 | case $cf_pkg_config in |
| 4054 | (no) |
| 4055 | PKG_CONFIG=none |
| 4056 | ;; |
| 4057 | (yes) |
| 4058 | |
| 4059 | if test -n "$ac_tool_prefix"; then |
| 4060 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. |
| 4061 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 |
| 4062 | echo "$as_me:4062: checking for $ac_word" >&5 |
| 4063 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4064 | if test "${ac_cv_path_PKG_CONFIG+set}" = set; then |
| 4065 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4066 | else |
| 4067 | case $PKG_CONFIG in |
| 4068 | [\\/]* | ?:[\\/]*) |
| 4069 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. |
| 4070 | ;; |
| 4071 | *) |
| 4072 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4073 | ac_dummy="$PATH" |
| 4074 | for ac_dir in $ac_dummy; do |
| 4075 | IFS=$ac_save_IFS |
| 4076 | test -z "$ac_dir" && ac_dir=. |
| 4077 | if $as_executable_p "$ac_dir/$ac_word"; then |
| 4078 | ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word" |
| 4079 | echo "$as_me:4079: found $ac_dir/$ac_word" >&5 |
| 4080 | break |
| 4081 | fi |
| 4082 | done |
| 4083 | |
| 4084 | ;; |
| 4085 | esac |
| 4086 | fi |
| 4087 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG |
| 4088 | |
| 4089 | if test -n "$PKG_CONFIG"; then |
| 4090 | echo "$as_me:4090: result: $PKG_CONFIG" >&5 |
| 4091 | echo "${ECHO_T}$PKG_CONFIG" >&6 |
| 4092 | else |
| 4093 | echo "$as_me:4093: result: no" >&5 |
| 4094 | echo "${ECHO_T}no" >&6 |
| 4095 | fi |
| 4096 | |
| 4097 | fi |
| 4098 | if test -z "$ac_cv_path_PKG_CONFIG"; then |
| 4099 | ac_pt_PKG_CONFIG=$PKG_CONFIG |
| 4100 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 4101 | set dummy pkg-config; ac_word=$2 |
| 4102 | echo "$as_me:4102: checking for $ac_word" >&5 |
| 4103 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4104 | if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then |
| 4105 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4106 | else |
| 4107 | case $ac_pt_PKG_CONFIG in |
| 4108 | [\\/]* | ?:[\\/]*) |
| 4109 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. |
| 4110 | ;; |
| 4111 | *) |
| 4112 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4113 | ac_dummy="$PATH" |
| 4114 | for ac_dir in $ac_dummy; do |
| 4115 | IFS=$ac_save_IFS |
| 4116 | test -z "$ac_dir" && ac_dir=. |
| 4117 | if $as_executable_p "$ac_dir/$ac_word"; then |
| 4118 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word" |
| 4119 | echo "$as_me:4119: found $ac_dir/$ac_word" >&5 |
| 4120 | break |
| 4121 | fi |
| 4122 | done |
| 4123 | |
| 4124 | test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none" |
| 4125 | ;; |
| 4126 | esac |
| 4127 | fi |
| 4128 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG |
| 4129 | |
| 4130 | if test -n "$ac_pt_PKG_CONFIG"; then |
| 4131 | echo "$as_me:4131: result: $ac_pt_PKG_CONFIG" >&5 |
| 4132 | echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 |
| 4133 | else |
| 4134 | echo "$as_me:4134: result: no" >&5 |
| 4135 | echo "${ECHO_T}no" >&6 |
| 4136 | fi |
| 4137 | |
| 4138 | PKG_CONFIG=$ac_pt_PKG_CONFIG |
| 4139 | else |
| 4140 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" |
| 4141 | fi |
| 4142 | |
| 4143 | ;; |
| 4144 | (*) |
| 4145 | PKG_CONFIG=$withval |
| 4146 | ;; |
| 4147 | esac |
| 4148 | |
| 4149 | test -z "$PKG_CONFIG" && PKG_CONFIG=none |
| 4150 | if test "$PKG_CONFIG" != none ; then |
| 4151 | |
| 4152 | if test "x$prefix" != xNONE; then |
| 4153 | cf_path_syntax="$prefix" |
| 4154 | else |
| 4155 | cf_path_syntax="$ac_default_prefix" |
| 4156 | fi |
| 4157 | |
| 4158 | case ".$PKG_CONFIG" in |
| 4159 | (.\$\(*\)*|.\'*\'*) |
| 4160 | ;; |
| 4161 | (..|./*|.\\*) |
| 4162 | ;; |
| 4163 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 4164 | ;; |
| 4165 | (.\${*prefix}*|.\${*dir}*) |
| 4166 | eval PKG_CONFIG="$PKG_CONFIG" |
| 4167 | case ".$PKG_CONFIG" in |
| 4168 | (.NONE/*) |
| 4169 | PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%` |
| 4170 | ;; |
| 4171 | esac |
| 4172 | ;; |
| 4173 | (.no|.NONE/*) |
| 4174 | PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%` |
| 4175 | ;; |
| 4176 | (*) |
| 4177 | { { echo "$as_me:4177: error: expected a pathname, not \"$PKG_CONFIG\"" >&5 |
| 4178 | echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;} |
| 4179 | { (exit 1); exit 1; }; } |
| 4180 | ;; |
| 4181 | esac |
| 4182 | |
| 4183 | elif test "x$cf_pkg_config" != xno ; then |
| 4184 | { echo "$as_me:4184: WARNING: pkg-config is not installed" >&5 |
| 4185 | echo "$as_me: WARNING: pkg-config is not installed" >&2;} |
| 4186 | fi |
| 4187 | |
| 4188 | echo "$as_me:4188: checking if you want to see long compiling messages" >&5 |
| 4189 | echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6 |
| 4190 | |
| 4191 | # Check whether --enable-echo or --disable-echo was given. |
| 4192 | if test "${enable_echo+set}" = set; then |
| 4193 | enableval="$enable_echo" |
| 4194 | test "$enableval" != no && enableval=yes |
| 4195 | if test "$enableval" != "yes" ; then |
| 4196 | |
| 4197 | ECHO_LT='--silent' |
| 4198 | ECHO_LD='@echo linking $@;' |
| 4199 | RULE_CC='@echo compiling $<' |
| 4200 | SHOW_CC='@echo compiling $@' |
| 4201 | ECHO_CC='@' |
| 4202 | |
| 4203 | else |
| 4204 | |
| 4205 | ECHO_LT='' |
| 4206 | ECHO_LD='' |
| 4207 | RULE_CC='' |
| 4208 | SHOW_CC='' |
| 4209 | ECHO_CC='' |
| 4210 | |
| 4211 | fi |
| 4212 | else |
| 4213 | enableval=yes |
| 4214 | |
| 4215 | ECHO_LT='' |
| 4216 | ECHO_LD='' |
| 4217 | RULE_CC='' |
| 4218 | SHOW_CC='' |
| 4219 | ECHO_CC='' |
| 4220 | |
| 4221 | fi; |
| 4222 | echo "$as_me:4222: result: $enableval" >&5 |
| 4223 | echo "${ECHO_T}$enableval" >&6 |
| 4224 | |
| 4225 | echo "$as_me:4225: checking for ncurses wrap-prefix" >&5 |
| 4226 | echo $ECHO_N "checking for ncurses wrap-prefix... $ECHO_C" >&6 |
| 4227 | |
| 4228 | # Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given. |
| 4229 | if test "${with_ncurses_wrap_prefix+set}" = set; then |
| 4230 | withval="$with_ncurses_wrap_prefix" |
| 4231 | NCURSES_WRAP_PREFIX=$withval |
| 4232 | else |
| 4233 | NCURSES_WRAP_PREFIX=_nc_ |
| 4234 | fi; |
| 4235 | echo "$as_me:4235: result: $NCURSES_WRAP_PREFIX" >&5 |
| 4236 | echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6 |
| 4237 | |
| 4238 | echo "$as_me:4238: checking if you want to check for wide-character functions" >&5 |
| 4239 | echo $ECHO_N "checking if you want to check for wide-character functions... $ECHO_C" >&6 |
| 4240 | |
| 4241 | # Check whether --enable-widec or --disable-widec was given. |
| 4242 | if test "${enable_widec+set}" = set; then |
| 4243 | enableval="$enable_widec" |
| 4244 | test "$enableval" != no && enableval=yes |
| 4245 | if test "$enableval" != "yes" ; then |
| 4246 | cf_enable_widec=no |
| 4247 | else |
| 4248 | cf_enable_widec=yes |
| 4249 | fi |
| 4250 | else |
| 4251 | enableval=yes |
| 4252 | cf_enable_widec=yes |
| 4253 | |
| 4254 | fi; |
| 4255 | echo "$as_me:4255: result: $cf_enable_widec" >&5 |
| 4256 | echo "${ECHO_T}$cf_enable_widec" >&6 |
| 4257 | |
| 4258 | echo "$as_me:4258: checking for specific curses-directory" >&5 |
| 4259 | echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6 |
| 4260 | |
| 4261 | # Check whether --with-curses-dir or --without-curses-dir was given. |
| 4262 | if test "${with_curses_dir+set}" = set; then |
| 4263 | withval="$with_curses_dir" |
| 4264 | cf_cv_curses_dir=$withval |
| 4265 | else |
| 4266 | cf_cv_curses_dir=no |
| 4267 | fi; |
| 4268 | echo "$as_me:4268: result: $cf_cv_curses_dir" >&5 |
| 4269 | echo "${ECHO_T}$cf_cv_curses_dir" >&6 |
| 4270 | |
| 4271 | if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" ) |
| 4272 | then |
| 4273 | |
| 4274 | if test "x$prefix" != xNONE; then |
| 4275 | cf_path_syntax="$prefix" |
| 4276 | else |
| 4277 | cf_path_syntax="$ac_default_prefix" |
| 4278 | fi |
| 4279 | |
| 4280 | case ".$withval" in |
| 4281 | (.\$\(*\)*|.\'*\'*) |
| 4282 | ;; |
| 4283 | (..|./*|.\\*) |
| 4284 | ;; |
| 4285 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 4286 | ;; |
| 4287 | (.\${*prefix}*|.\${*dir}*) |
| 4288 | eval withval="$withval" |
| 4289 | case ".$withval" in |
| 4290 | (.NONE/*) |
| 4291 | withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` |
| 4292 | ;; |
| 4293 | esac |
| 4294 | ;; |
| 4295 | (.no|.NONE/*) |
| 4296 | withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` |
| 4297 | ;; |
| 4298 | (*) |
| 4299 | { { echo "$as_me:4299: error: expected a pathname, not \"$withval\"" >&5 |
| 4300 | echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;} |
| 4301 | { (exit 1); exit 1; }; } |
| 4302 | ;; |
| 4303 | esac |
| 4304 | |
| 4305 | if test -d "$cf_cv_curses_dir" |
| 4306 | then |
| 4307 | |
| 4308 | if test -n "$cf_cv_curses_dir/include" ; then |
| 4309 | for cf_add_incdir in $cf_cv_curses_dir/include |
| 4310 | do |
| 4311 | while test $cf_add_incdir != /usr/include |
| 4312 | do |
| 4313 | if test -d $cf_add_incdir |
| 4314 | then |
| 4315 | cf_have_incdir=no |
| 4316 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 4317 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 4318 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 4319 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 4320 | cf_have_incdir=yes; break |
| 4321 | fi |
| 4322 | done |
| 4323 | fi |
| 4324 | |
| 4325 | if test "$cf_have_incdir" = no ; then |
| 4326 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 4327 | if test "$GCC" = yes |
| 4328 | then |
| 4329 | cf_save_CPPFLAGS=$CPPFLAGS |
| 4330 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 4331 | cat >conftest.$ac_ext <<_ACEOF |
| 4332 | #line 4332 "configure" |
| 4333 | #include "confdefs.h" |
| 4334 | #include <stdio.h> |
| 4335 | int |
| 4336 | main () |
| 4337 | { |
| 4338 | printf("Hello") |
| 4339 | ; |
| 4340 | return 0; |
| 4341 | } |
| 4342 | _ACEOF |
| 4343 | rm -f conftest.$ac_objext |
| 4344 | if { (eval echo "$as_me:4344: \"$ac_compile\"") >&5 |
| 4345 | (eval $ac_compile) 2>&5 |
| 4346 | ac_status=$? |
| 4347 | echo "$as_me:4347: \$? = $ac_status" >&5 |
| 4348 | (exit $ac_status); } && |
| 4349 | { ac_try='test -s conftest.$ac_objext' |
| 4350 | { (eval echo "$as_me:4350: \"$ac_try\"") >&5 |
| 4351 | (eval $ac_try) 2>&5 |
| 4352 | ac_status=$? |
| 4353 | echo "$as_me:4353: \$? = $ac_status" >&5 |
| 4354 | (exit $ac_status); }; }; then |
| 4355 | : |
| 4356 | else |
| 4357 | echo "$as_me: failed program was:" >&5 |
| 4358 | cat conftest.$ac_ext >&5 |
| 4359 | cf_have_incdir=yes |
| 4360 | fi |
| 4361 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 4362 | CPPFLAGS=$cf_save_CPPFLAGS |
| 4363 | fi |
| 4364 | fi |
| 4365 | fi |
| 4366 | |
| 4367 | if test "$cf_have_incdir" = no ; then |
| 4368 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 4369 | |
| 4370 | echo "${as_me:-configure}:4370: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 4371 | |
| 4372 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 4373 | |
| 4374 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 4375 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 4376 | cf_add_incdir="$cf_top_incdir" |
| 4377 | else |
| 4378 | break |
| 4379 | fi |
| 4380 | else |
| 4381 | break |
| 4382 | fi |
| 4383 | done |
| 4384 | done |
| 4385 | fi |
| 4386 | |
| 4387 | if test -n "$cf_cv_curses_dir/lib" ; then |
| 4388 | for cf_add_libdir in $cf_cv_curses_dir/lib |
| 4389 | do |
| 4390 | if test $cf_add_libdir = /usr/lib ; then |
| 4391 | : |
| 4392 | elif test -d $cf_add_libdir |
| 4393 | then |
| 4394 | cf_have_libdir=no |
| 4395 | if test -n "$LDFLAGS$LIBS" ; then |
| 4396 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 4397 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 4398 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 4399 | cf_have_libdir=yes; break |
| 4400 | fi |
| 4401 | done |
| 4402 | fi |
| 4403 | if test "$cf_have_libdir" = no ; then |
| 4404 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 4405 | |
| 4406 | echo "${as_me:-configure}:4406: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 4407 | |
| 4408 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 4409 | fi |
| 4410 | fi |
| 4411 | done |
| 4412 | fi |
| 4413 | |
| 4414 | fi |
| 4415 | fi |
| 4416 | |
| 4417 | cf_cv_screen=curses |
| 4418 | |
| 4419 | echo "$as_me:4419: checking for specified curses library type" >&5 |
| 4420 | echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6 |
| 4421 | |
| 4422 | # Check whether --with-screen or --without-screen was given. |
| 4423 | if test "${with_screen+set}" = set; then |
| 4424 | withval="$with_screen" |
| 4425 | cf_cv_screen=$withval |
| 4426 | else |
| 4427 | |
| 4428 | # Check whether --with-ncursesw or --without-ncursesw was given. |
| 4429 | if test "${with_ncursesw+set}" = set; then |
| 4430 | withval="$with_ncursesw" |
| 4431 | cf_cv_screen=ncursesw |
| 4432 | else |
| 4433 | |
| 4434 | # Check whether --with-ncurses or --without-ncurses was given. |
| 4435 | if test "${with_ncurses+set}" = set; then |
| 4436 | withval="$with_ncurses" |
| 4437 | cf_cv_screen=ncurses |
| 4438 | else |
| 4439 | |
| 4440 | # Check whether --with-pdcurses or --without-pdcurses was given. |
| 4441 | if test "${with_pdcurses+set}" = set; then |
| 4442 | withval="$with_pdcurses" |
| 4443 | cf_cv_screen=pdcurses |
| 4444 | else |
| 4445 | |
| 4446 | # Check whether --with-curses-colr or --without-curses-colr was given. |
| 4447 | if test "${with_curses_colr+set}" = set; then |
| 4448 | withval="$with_curses_colr" |
| 4449 | cf_cv_screen=curses_colr |
| 4450 | else |
| 4451 | |
| 4452 | # Check whether --with-curses-5lib or --without-curses-5lib was given. |
| 4453 | if test "${with_curses_5lib+set}" = set; then |
| 4454 | withval="$with_curses_5lib" |
| 4455 | cf_cv_screen=curses_5lib |
| 4456 | fi; |
| 4457 | fi; |
| 4458 | fi; |
| 4459 | fi; |
| 4460 | fi; |
| 4461 | fi; |
| 4462 | |
| 4463 | echo "$as_me:4463: result: $cf_cv_screen" >&5 |
| 4464 | echo "${ECHO_T}$cf_cv_screen" >&6 |
| 4465 | |
| 4466 | case $cf_cv_screen in |
| 4467 | (curses|curses_*) |
| 4468 | |
| 4469 | echo "$as_me:4469: checking for extra include directories" >&5 |
| 4470 | echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6 |
| 4471 | if test "${cf_cv_curses_incdir+set}" = set; then |
| 4472 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4473 | else |
| 4474 | |
| 4475 | cf_cv_curses_incdir=no |
| 4476 | case $host_os in |
| 4477 | (hpux10.*) |
| 4478 | if test "x$cf_cv_screen" = "xcurses_colr" |
| 4479 | then |
| 4480 | test -d /usr/include/curses_colr && \ |
| 4481 | cf_cv_curses_incdir="-I/usr/include/curses_colr" |
| 4482 | fi |
| 4483 | ;; |
| 4484 | (sunos3*|sunos4*) |
| 4485 | if test "x$cf_cv_screen" = "xcurses_5lib" |
| 4486 | then |
| 4487 | test -d /usr/5lib && \ |
| 4488 | test -d /usr/5include && \ |
| 4489 | cf_cv_curses_incdir="-I/usr/5include" |
| 4490 | fi |
| 4491 | ;; |
| 4492 | esac |
| 4493 | |
| 4494 | fi |
| 4495 | echo "$as_me:4495: result: $cf_cv_curses_incdir" >&5 |
| 4496 | echo "${ECHO_T}$cf_cv_curses_incdir" >&6 |
| 4497 | test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir" |
| 4498 | |
| 4499 | echo "$as_me:4499: checking if we have identified curses headers" >&5 |
| 4500 | echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6 |
| 4501 | if test "${cf_cv_ncurses_header+set}" = set; then |
| 4502 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4503 | else |
| 4504 | |
| 4505 | cf_cv_ncurses_header=none |
| 4506 | for cf_header in \ |
| 4507 | ncurses.h \ |
| 4508 | curses.h ncurses/ncurses.h ncurses/curses.h |
| 4509 | do |
| 4510 | cat >conftest.$ac_ext <<_ACEOF |
| 4511 | #line 4511 "configure" |
| 4512 | #include "confdefs.h" |
| 4513 | #include <${cf_header}> |
| 4514 | int |
| 4515 | main () |
| 4516 | { |
| 4517 | initscr(); tgoto("?", 0,0) |
| 4518 | ; |
| 4519 | return 0; |
| 4520 | } |
| 4521 | _ACEOF |
| 4522 | rm -f conftest.$ac_objext |
| 4523 | if { (eval echo "$as_me:4523: \"$ac_compile\"") >&5 |
| 4524 | (eval $ac_compile) 2>&5 |
| 4525 | ac_status=$? |
| 4526 | echo "$as_me:4526: \$? = $ac_status" >&5 |
| 4527 | (exit $ac_status); } && |
| 4528 | { ac_try='test -s conftest.$ac_objext' |
| 4529 | { (eval echo "$as_me:4529: \"$ac_try\"") >&5 |
| 4530 | (eval $ac_try) 2>&5 |
| 4531 | ac_status=$? |
| 4532 | echo "$as_me:4532: \$? = $ac_status" >&5 |
| 4533 | (exit $ac_status); }; }; then |
| 4534 | cf_cv_ncurses_header=$cf_header; break |
| 4535 | else |
| 4536 | echo "$as_me: failed program was:" >&5 |
| 4537 | cat conftest.$ac_ext >&5 |
| 4538 | fi |
| 4539 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 4540 | done |
| 4541 | |
| 4542 | fi |
| 4543 | echo "$as_me:4543: result: $cf_cv_ncurses_header" >&5 |
| 4544 | echo "${ECHO_T}$cf_cv_ncurses_header" >&6 |
| 4545 | |
| 4546 | if test "$cf_cv_ncurses_header" = none ; then |
| 4547 | { { echo "$as_me:4547: error: No curses header-files found" >&5 |
| 4548 | echo "$as_me: error: No curses header-files found" >&2;} |
| 4549 | { (exit 1); exit 1; }; } |
| 4550 | fi |
| 4551 | |
| 4552 | # cheat, to get the right #define's for HAVE_NCURSES_H, etc. |
| 4553 | |
| 4554 | for ac_header in $cf_cv_ncurses_header |
| 4555 | do |
| 4556 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4557 | echo "$as_me:4557: checking for $ac_header" >&5 |
| 4558 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 4559 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 4560 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4561 | else |
| 4562 | cat >conftest.$ac_ext <<_ACEOF |
| 4563 | #line 4563 "configure" |
| 4564 | #include "confdefs.h" |
| 4565 | #include <$ac_header> |
| 4566 | _ACEOF |
| 4567 | if { (eval echo "$as_me:4567: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 4568 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 4569 | ac_status=$? |
| 4570 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 4571 | rm -f conftest.er1 |
| 4572 | cat conftest.err >&5 |
| 4573 | echo "$as_me:4573: \$? = $ac_status" >&5 |
| 4574 | (exit $ac_status); } >/dev/null; then |
| 4575 | if test -s conftest.err; then |
| 4576 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 4577 | else |
| 4578 | ac_cpp_err= |
| 4579 | fi |
| 4580 | else |
| 4581 | ac_cpp_err=yes |
| 4582 | fi |
| 4583 | if test -z "$ac_cpp_err"; then |
| 4584 | eval "$as_ac_Header=yes" |
| 4585 | else |
| 4586 | echo "$as_me: failed program was:" >&5 |
| 4587 | cat conftest.$ac_ext >&5 |
| 4588 | eval "$as_ac_Header=no" |
| 4589 | fi |
| 4590 | rm -f conftest.err conftest.$ac_ext |
| 4591 | fi |
| 4592 | echo "$as_me:4592: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 4593 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 4594 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 4595 | cat >>confdefs.h <<EOF |
| 4596 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 4597 | EOF |
| 4598 | |
| 4599 | fi |
| 4600 | done |
| 4601 | |
| 4602 | echo "$as_me:4602: checking for terminfo header" >&5 |
| 4603 | echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6 |
| 4604 | if test "${cf_cv_term_header+set}" = set; then |
| 4605 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4606 | else |
| 4607 | |
| 4608 | case ${cf_cv_ncurses_header} in |
| 4609 | (*/ncurses.h|*/ncursesw.h) |
| 4610 | cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'` |
| 4611 | ;; |
| 4612 | (*) |
| 4613 | cf_term_header=term.h |
| 4614 | ;; |
| 4615 | esac |
| 4616 | |
| 4617 | for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h" |
| 4618 | do |
| 4619 | cat >conftest.$ac_ext <<_ACEOF |
| 4620 | #line 4620 "configure" |
| 4621 | #include "confdefs.h" |
| 4622 | #include <stdio.h> |
| 4623 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 4624 | #include <$cf_test> |
| 4625 | |
| 4626 | int |
| 4627 | main () |
| 4628 | { |
| 4629 | int x = auto_left_margin |
| 4630 | ; |
| 4631 | return 0; |
| 4632 | } |
| 4633 | _ACEOF |
| 4634 | rm -f conftest.$ac_objext |
| 4635 | if { (eval echo "$as_me:4635: \"$ac_compile\"") >&5 |
| 4636 | (eval $ac_compile) 2>&5 |
| 4637 | ac_status=$? |
| 4638 | echo "$as_me:4638: \$? = $ac_status" >&5 |
| 4639 | (exit $ac_status); } && |
| 4640 | { ac_try='test -s conftest.$ac_objext' |
| 4641 | { (eval echo "$as_me:4641: \"$ac_try\"") >&5 |
| 4642 | (eval $ac_try) 2>&5 |
| 4643 | ac_status=$? |
| 4644 | echo "$as_me:4644: \$? = $ac_status" >&5 |
| 4645 | (exit $ac_status); }; }; then |
| 4646 | |
| 4647 | cf_cv_term_header="$cf_test" |
| 4648 | else |
| 4649 | echo "$as_me: failed program was:" >&5 |
| 4650 | cat conftest.$ac_ext >&5 |
| 4651 | |
| 4652 | cf_cv_term_header=unknown |
| 4653 | |
| 4654 | fi |
| 4655 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 4656 | test "$cf_cv_term_header" != unknown && break |
| 4657 | done |
| 4658 | |
| 4659 | fi |
| 4660 | echo "$as_me:4660: result: $cf_cv_term_header" >&5 |
| 4661 | echo "${ECHO_T}$cf_cv_term_header" >&6 |
| 4662 | |
| 4663 | # Set definitions to allow ifdef'ing to accommodate subdirectories |
| 4664 | |
| 4665 | case $cf_cv_term_header in |
| 4666 | (*term.h) |
| 4667 | |
| 4668 | cat >>confdefs.h <<\EOF |
| 4669 | #define HAVE_TERM_H 1 |
| 4670 | EOF |
| 4671 | |
| 4672 | ;; |
| 4673 | esac |
| 4674 | |
| 4675 | case $cf_cv_term_header in |
| 4676 | (ncurses/term.h) |
| 4677 | |
| 4678 | cat >>confdefs.h <<\EOF |
| 4679 | #define HAVE_NCURSES_TERM_H 1 |
| 4680 | EOF |
| 4681 | |
| 4682 | ;; |
| 4683 | (ncursesw/term.h) |
| 4684 | |
| 4685 | cat >>confdefs.h <<\EOF |
| 4686 | #define HAVE_NCURSESW_TERM_H 1 |
| 4687 | EOF |
| 4688 | |
| 4689 | ;; |
| 4690 | esac |
| 4691 | |
| 4692 | echo "$as_me:4692: checking for ncurses version" >&5 |
| 4693 | echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6 |
| 4694 | if test "${cf_cv_ncurses_version+set}" = set; then |
| 4695 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4696 | else |
| 4697 | |
| 4698 | cf_cv_ncurses_version=no |
| 4699 | cf_tempfile=out$$ |
| 4700 | rm -f $cf_tempfile |
| 4701 | if test "$cross_compiling" = yes; then |
| 4702 | |
| 4703 | # This will not work if the preprocessor splits the line after the |
| 4704 | # Autoconf token. The 'unproto' program does that. |
| 4705 | cat > conftest.$ac_ext <<EOF |
| 4706 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 4707 | #undef Autoconf |
| 4708 | #ifdef NCURSES_VERSION |
| 4709 | Autoconf NCURSES_VERSION |
| 4710 | #else |
| 4711 | #ifdef __NCURSES_H |
| 4712 | Autoconf "old" |
| 4713 | #endif |
| 4714 | ; |
| 4715 | #endif |
| 4716 | EOF |
| 4717 | cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out" |
| 4718 | { (eval echo "$as_me:4718: \"$cf_try\"") >&5 |
| 4719 | (eval $cf_try) 2>&5 |
| 4720 | ac_status=$? |
| 4721 | echo "$as_me:4721: \$? = $ac_status" >&5 |
| 4722 | (exit $ac_status); } |
| 4723 | if test -f conftest.out ; then |
| 4724 | cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'` |
| 4725 | test -n "$cf_out" && cf_cv_ncurses_version="$cf_out" |
| 4726 | rm -f conftest.out |
| 4727 | fi |
| 4728 | |
| 4729 | else |
| 4730 | cat >conftest.$ac_ext <<_ACEOF |
| 4731 | #line 4731 "configure" |
| 4732 | #include "confdefs.h" |
| 4733 | |
| 4734 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 4735 | #include <stdio.h> |
| 4736 | int main() |
| 4737 | { |
| 4738 | FILE *fp = fopen("$cf_tempfile", "w"); |
| 4739 | #ifdef NCURSES_VERSION |
| 4740 | # ifdef NCURSES_VERSION_PATCH |
| 4741 | fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH); |
| 4742 | # else |
| 4743 | fprintf(fp, "%s\n", NCURSES_VERSION); |
| 4744 | # endif |
| 4745 | #else |
| 4746 | # ifdef __NCURSES_H |
| 4747 | fprintf(fp, "old\n"); |
| 4748 | # else |
| 4749 | make an error |
| 4750 | # endif |
| 4751 | #endif |
| 4752 | ${cf_cv_main_return:-return}(0); |
| 4753 | } |
| 4754 | _ACEOF |
| 4755 | rm -f conftest$ac_exeext |
| 4756 | if { (eval echo "$as_me:4756: \"$ac_link\"") >&5 |
| 4757 | (eval $ac_link) 2>&5 |
| 4758 | ac_status=$? |
| 4759 | echo "$as_me:4759: \$? = $ac_status" >&5 |
| 4760 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 4761 | { (eval echo "$as_me:4761: \"$ac_try\"") >&5 |
| 4762 | (eval $ac_try) 2>&5 |
| 4763 | ac_status=$? |
| 4764 | echo "$as_me:4764: \$? = $ac_status" >&5 |
| 4765 | (exit $ac_status); }; }; then |
| 4766 | |
| 4767 | cf_cv_ncurses_version=`cat $cf_tempfile` |
| 4768 | else |
| 4769 | echo "$as_me: program exited with status $ac_status" >&5 |
| 4770 | echo "$as_me: failed program was:" >&5 |
| 4771 | cat conftest.$ac_ext >&5 |
| 4772 | fi |
| 4773 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 4774 | fi |
| 4775 | rm -f $cf_tempfile |
| 4776 | |
| 4777 | fi |
| 4778 | echo "$as_me:4778: result: $cf_cv_ncurses_version" >&5 |
| 4779 | echo "${ECHO_T}$cf_cv_ncurses_version" >&6 |
| 4780 | test "$cf_cv_ncurses_version" = no || |
| 4781 | cat >>confdefs.h <<\EOF |
| 4782 | #define NCURSES 1 |
| 4783 | EOF |
| 4784 | |
| 4785 | echo "$as_me:4785: checking if we have identified curses libraries" >&5 |
| 4786 | echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6 |
| 4787 | cat >conftest.$ac_ext <<_ACEOF |
| 4788 | #line 4788 "configure" |
| 4789 | #include "confdefs.h" |
| 4790 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 4791 | int |
| 4792 | main () |
| 4793 | { |
| 4794 | initscr(); tgoto("?", 0,0) |
| 4795 | ; |
| 4796 | return 0; |
| 4797 | } |
| 4798 | _ACEOF |
| 4799 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 4800 | if { (eval echo "$as_me:4800: \"$ac_link\"") >&5 |
| 4801 | (eval $ac_link) 2>&5 |
| 4802 | ac_status=$? |
| 4803 | echo "$as_me:4803: \$? = $ac_status" >&5 |
| 4804 | (exit $ac_status); } && |
| 4805 | { ac_try='test -s conftest$ac_exeext' |
| 4806 | { (eval echo "$as_me:4806: \"$ac_try\"") >&5 |
| 4807 | (eval $ac_try) 2>&5 |
| 4808 | ac_status=$? |
| 4809 | echo "$as_me:4809: \$? = $ac_status" >&5 |
| 4810 | (exit $ac_status); }; }; then |
| 4811 | cf_result=yes |
| 4812 | else |
| 4813 | echo "$as_me: failed program was:" >&5 |
| 4814 | cat conftest.$ac_ext >&5 |
| 4815 | cf_result=no |
| 4816 | fi |
| 4817 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 4818 | echo "$as_me:4818: result: $cf_result" >&5 |
| 4819 | echo "${ECHO_T}$cf_result" >&6 |
| 4820 | |
| 4821 | if test "$cf_result" = no ; then |
| 4822 | case $host_os in |
| 4823 | (freebsd*) |
| 4824 | echo "$as_me:4824: checking for tgoto in -lmytinfo" >&5 |
| 4825 | echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6 |
| 4826 | if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then |
| 4827 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4828 | else |
| 4829 | ac_check_lib_save_LIBS=$LIBS |
| 4830 | LIBS="-lmytinfo $LIBS" |
| 4831 | cat >conftest.$ac_ext <<_ACEOF |
| 4832 | #line 4832 "configure" |
| 4833 | #include "confdefs.h" |
| 4834 | |
| 4835 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4836 | #ifdef __cplusplus |
| 4837 | extern "C" |
| 4838 | #endif |
| 4839 | /* We use char because int might match the return type of a gcc2 |
| 4840 | builtin and then its argument prototype would still apply. */ |
| 4841 | char tgoto (); |
| 4842 | int |
| 4843 | main () |
| 4844 | { |
| 4845 | tgoto (); |
| 4846 | ; |
| 4847 | return 0; |
| 4848 | } |
| 4849 | _ACEOF |
| 4850 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 4851 | if { (eval echo "$as_me:4851: \"$ac_link\"") >&5 |
| 4852 | (eval $ac_link) 2>&5 |
| 4853 | ac_status=$? |
| 4854 | echo "$as_me:4854: \$? = $ac_status" >&5 |
| 4855 | (exit $ac_status); } && |
| 4856 | { ac_try='test -s conftest$ac_exeext' |
| 4857 | { (eval echo "$as_me:4857: \"$ac_try\"") >&5 |
| 4858 | (eval $ac_try) 2>&5 |
| 4859 | ac_status=$? |
| 4860 | echo "$as_me:4860: \$? = $ac_status" >&5 |
| 4861 | (exit $ac_status); }; }; then |
| 4862 | ac_cv_lib_mytinfo_tgoto=yes |
| 4863 | else |
| 4864 | echo "$as_me: failed program was:" >&5 |
| 4865 | cat conftest.$ac_ext >&5 |
| 4866 | ac_cv_lib_mytinfo_tgoto=no |
| 4867 | fi |
| 4868 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 4869 | LIBS=$ac_check_lib_save_LIBS |
| 4870 | fi |
| 4871 | echo "$as_me:4871: result: $ac_cv_lib_mytinfo_tgoto" >&5 |
| 4872 | echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6 |
| 4873 | if test $ac_cv_lib_mytinfo_tgoto = yes; then |
| 4874 | |
| 4875 | cf_add_libs="-lmytinfo" |
| 4876 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 4877 | for cf_add_1lib in $LIBS |
| 4878 | do |
| 4879 | for cf_add_2lib in $cf_add_libs |
| 4880 | do |
| 4881 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 4882 | then |
| 4883 | cf_add_1lib= |
| 4884 | break |
| 4885 | fi |
| 4886 | done |
| 4887 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 4888 | done |
| 4889 | LIBS="$cf_add_libs" |
| 4890 | |
| 4891 | fi |
| 4892 | |
| 4893 | ;; |
| 4894 | (hpux10.*) |
| 4895 | # Looking at HPUX 10.20, the Hcurses library is the oldest (1997), cur_colr |
| 4896 | # next (1998), and xcurses "newer" (2000). There is no header file for |
| 4897 | # Hcurses; the subdirectory curses_colr has the headers (curses.h and |
| 4898 | # term.h) for cur_colr |
| 4899 | if test "x$cf_cv_screen" = "xcurses_colr" |
| 4900 | then |
| 4901 | echo "$as_me:4901: checking for initscr in -lcur_colr" >&5 |
| 4902 | echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6 |
| 4903 | if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then |
| 4904 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4905 | else |
| 4906 | ac_check_lib_save_LIBS=$LIBS |
| 4907 | LIBS="-lcur_colr $LIBS" |
| 4908 | cat >conftest.$ac_ext <<_ACEOF |
| 4909 | #line 4909 "configure" |
| 4910 | #include "confdefs.h" |
| 4911 | |
| 4912 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4913 | #ifdef __cplusplus |
| 4914 | extern "C" |
| 4915 | #endif |
| 4916 | /* We use char because int might match the return type of a gcc2 |
| 4917 | builtin and then its argument prototype would still apply. */ |
| 4918 | char initscr (); |
| 4919 | int |
| 4920 | main () |
| 4921 | { |
| 4922 | initscr (); |
| 4923 | ; |
| 4924 | return 0; |
| 4925 | } |
| 4926 | _ACEOF |
| 4927 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 4928 | if { (eval echo "$as_me:4928: \"$ac_link\"") >&5 |
| 4929 | (eval $ac_link) 2>&5 |
| 4930 | ac_status=$? |
| 4931 | echo "$as_me:4931: \$? = $ac_status" >&5 |
| 4932 | (exit $ac_status); } && |
| 4933 | { ac_try='test -s conftest$ac_exeext' |
| 4934 | { (eval echo "$as_me:4934: \"$ac_try\"") >&5 |
| 4935 | (eval $ac_try) 2>&5 |
| 4936 | ac_status=$? |
| 4937 | echo "$as_me:4937: \$? = $ac_status" >&5 |
| 4938 | (exit $ac_status); }; }; then |
| 4939 | ac_cv_lib_cur_colr_initscr=yes |
| 4940 | else |
| 4941 | echo "$as_me: failed program was:" >&5 |
| 4942 | cat conftest.$ac_ext >&5 |
| 4943 | ac_cv_lib_cur_colr_initscr=no |
| 4944 | fi |
| 4945 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 4946 | LIBS=$ac_check_lib_save_LIBS |
| 4947 | fi |
| 4948 | echo "$as_me:4948: result: $ac_cv_lib_cur_colr_initscr" >&5 |
| 4949 | echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6 |
| 4950 | if test $ac_cv_lib_cur_colr_initscr = yes; then |
| 4951 | |
| 4952 | cf_add_libs="-lcur_colr" |
| 4953 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 4954 | for cf_add_1lib in $LIBS |
| 4955 | do |
| 4956 | for cf_add_2lib in $cf_add_libs |
| 4957 | do |
| 4958 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 4959 | then |
| 4960 | cf_add_1lib= |
| 4961 | break |
| 4962 | fi |
| 4963 | done |
| 4964 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 4965 | done |
| 4966 | LIBS="$cf_add_libs" |
| 4967 | |
| 4968 | ac_cv_func_initscr=yes |
| 4969 | |
| 4970 | else |
| 4971 | |
| 4972 | echo "$as_me:4972: checking for initscr in -lHcurses" >&5 |
| 4973 | echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6 |
| 4974 | if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then |
| 4975 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4976 | else |
| 4977 | ac_check_lib_save_LIBS=$LIBS |
| 4978 | LIBS="-lHcurses $LIBS" |
| 4979 | cat >conftest.$ac_ext <<_ACEOF |
| 4980 | #line 4980 "configure" |
| 4981 | #include "confdefs.h" |
| 4982 | |
| 4983 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4984 | #ifdef __cplusplus |
| 4985 | extern "C" |
| 4986 | #endif |
| 4987 | /* We use char because int might match the return type of a gcc2 |
| 4988 | builtin and then its argument prototype would still apply. */ |
| 4989 | char initscr (); |
| 4990 | int |
| 4991 | main () |
| 4992 | { |
| 4993 | initscr (); |
| 4994 | ; |
| 4995 | return 0; |
| 4996 | } |
| 4997 | _ACEOF |
| 4998 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 4999 | if { (eval echo "$as_me:4999: \"$ac_link\"") >&5 |
| 5000 | (eval $ac_link) 2>&5 |
| 5001 | ac_status=$? |
| 5002 | echo "$as_me:5002: \$? = $ac_status" >&5 |
| 5003 | (exit $ac_status); } && |
| 5004 | { ac_try='test -s conftest$ac_exeext' |
| 5005 | { (eval echo "$as_me:5005: \"$ac_try\"") >&5 |
| 5006 | (eval $ac_try) 2>&5 |
| 5007 | ac_status=$? |
| 5008 | echo "$as_me:5008: \$? = $ac_status" >&5 |
| 5009 | (exit $ac_status); }; }; then |
| 5010 | ac_cv_lib_Hcurses_initscr=yes |
| 5011 | else |
| 5012 | echo "$as_me: failed program was:" >&5 |
| 5013 | cat conftest.$ac_ext >&5 |
| 5014 | ac_cv_lib_Hcurses_initscr=no |
| 5015 | fi |
| 5016 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5017 | LIBS=$ac_check_lib_save_LIBS |
| 5018 | fi |
| 5019 | echo "$as_me:5019: result: $ac_cv_lib_Hcurses_initscr" >&5 |
| 5020 | echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6 |
| 5021 | if test $ac_cv_lib_Hcurses_initscr = yes; then |
| 5022 | |
| 5023 | # HP's header uses __HP_CURSES, but user claims _HP_CURSES. |
| 5024 | |
| 5025 | cf_add_libs="-lHcurses" |
| 5026 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 5027 | for cf_add_1lib in $LIBS |
| 5028 | do |
| 5029 | for cf_add_2lib in $cf_add_libs |
| 5030 | do |
| 5031 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 5032 | then |
| 5033 | cf_add_1lib= |
| 5034 | break |
| 5035 | fi |
| 5036 | done |
| 5037 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 5038 | done |
| 5039 | LIBS="$cf_add_libs" |
| 5040 | |
| 5041 | CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES" |
| 5042 | ac_cv_func_initscr=yes |
| 5043 | |
| 5044 | fi |
| 5045 | |
| 5046 | fi |
| 5047 | |
| 5048 | fi |
| 5049 | ;; |
| 5050 | (linux*) |
| 5051 | case `arch 2>/dev/null` in |
| 5052 | (x86_64) |
| 5053 | if test -d /lib64 |
| 5054 | then |
| 5055 | |
| 5056 | if test -n "/lib64" ; then |
| 5057 | for cf_add_libdir in /lib64 |
| 5058 | do |
| 5059 | if test $cf_add_libdir = /usr/lib ; then |
| 5060 | : |
| 5061 | elif test -d $cf_add_libdir |
| 5062 | then |
| 5063 | cf_have_libdir=no |
| 5064 | if test -n "$LDFLAGS$LIBS" ; then |
| 5065 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 5066 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 5067 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 5068 | cf_have_libdir=yes; break |
| 5069 | fi |
| 5070 | done |
| 5071 | fi |
| 5072 | if test "$cf_have_libdir" = no ; then |
| 5073 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 5074 | |
| 5075 | echo "${as_me:-configure}:5075: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 5076 | |
| 5077 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 5078 | fi |
| 5079 | fi |
| 5080 | done |
| 5081 | fi |
| 5082 | |
| 5083 | else |
| 5084 | |
| 5085 | if test -n "/lib" ; then |
| 5086 | for cf_add_libdir in /lib |
| 5087 | do |
| 5088 | if test $cf_add_libdir = /usr/lib ; then |
| 5089 | : |
| 5090 | elif test -d $cf_add_libdir |
| 5091 | then |
| 5092 | cf_have_libdir=no |
| 5093 | if test -n "$LDFLAGS$LIBS" ; then |
| 5094 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 5095 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 5096 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 5097 | cf_have_libdir=yes; break |
| 5098 | fi |
| 5099 | done |
| 5100 | fi |
| 5101 | if test "$cf_have_libdir" = no ; then |
| 5102 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 5103 | |
| 5104 | echo "${as_me:-configure}:5104: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 5105 | |
| 5106 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 5107 | fi |
| 5108 | fi |
| 5109 | done |
| 5110 | fi |
| 5111 | |
| 5112 | fi |
| 5113 | ;; |
| 5114 | (*) |
| 5115 | |
| 5116 | if test -n "/lib" ; then |
| 5117 | for cf_add_libdir in /lib |
| 5118 | do |
| 5119 | if test $cf_add_libdir = /usr/lib ; then |
| 5120 | : |
| 5121 | elif test -d $cf_add_libdir |
| 5122 | then |
| 5123 | cf_have_libdir=no |
| 5124 | if test -n "$LDFLAGS$LIBS" ; then |
| 5125 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 5126 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 5127 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 5128 | cf_have_libdir=yes; break |
| 5129 | fi |
| 5130 | done |
| 5131 | fi |
| 5132 | if test "$cf_have_libdir" = no ; then |
| 5133 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 5134 | |
| 5135 | echo "${as_me:-configure}:5135: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 5136 | |
| 5137 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 5138 | fi |
| 5139 | fi |
| 5140 | done |
| 5141 | fi |
| 5142 | |
| 5143 | ;; |
| 5144 | esac |
| 5145 | ;; |
| 5146 | (sunos3*|sunos4*) |
| 5147 | if test "x$cf_cv_screen" = "xcurses_5lib" |
| 5148 | then |
| 5149 | if test -d /usr/5lib ; then |
| 5150 | |
| 5151 | if test -n "/usr/5lib" ; then |
| 5152 | for cf_add_libdir in /usr/5lib |
| 5153 | do |
| 5154 | if test $cf_add_libdir = /usr/lib ; then |
| 5155 | : |
| 5156 | elif test -d $cf_add_libdir |
| 5157 | then |
| 5158 | cf_have_libdir=no |
| 5159 | if test -n "$LDFLAGS$LIBS" ; then |
| 5160 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 5161 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 5162 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 5163 | cf_have_libdir=yes; break |
| 5164 | fi |
| 5165 | done |
| 5166 | fi |
| 5167 | if test "$cf_have_libdir" = no ; then |
| 5168 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 5169 | |
| 5170 | echo "${as_me:-configure}:5170: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 5171 | |
| 5172 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 5173 | fi |
| 5174 | fi |
| 5175 | done |
| 5176 | fi |
| 5177 | |
| 5178 | cf_add_libs="-lcurses -ltermcap" |
| 5179 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 5180 | for cf_add_1lib in $LIBS |
| 5181 | do |
| 5182 | for cf_add_2lib in $cf_add_libs |
| 5183 | do |
| 5184 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 5185 | then |
| 5186 | cf_add_1lib= |
| 5187 | break |
| 5188 | fi |
| 5189 | done |
| 5190 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 5191 | done |
| 5192 | LIBS="$cf_add_libs" |
| 5193 | |
| 5194 | fi |
| 5195 | fi |
| 5196 | ac_cv_func_initscr=yes |
| 5197 | ;; |
| 5198 | esac |
| 5199 | |
| 5200 | if test ".$ac_cv_func_initscr" != .yes ; then |
| 5201 | cf_save_LIBS="$LIBS" |
| 5202 | |
| 5203 | if test ".${cf_cv_ncurses_version:-no}" != .no |
| 5204 | then |
| 5205 | cf_check_list="ncurses curses cursesX" |
| 5206 | else |
| 5207 | cf_check_list="cursesX curses ncurses" |
| 5208 | fi |
| 5209 | |
| 5210 | # Check for library containing tgoto. Do this before curses library |
| 5211 | # because it may be needed to link the test-case for initscr. |
| 5212 | if test "x$cf_term_lib" = x |
| 5213 | then |
| 5214 | echo "$as_me:5214: checking for tgoto" >&5 |
| 5215 | echo $ECHO_N "checking for tgoto... $ECHO_C" >&6 |
| 5216 | if test "${ac_cv_func_tgoto+set}" = set; then |
| 5217 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5218 | else |
| 5219 | cat >conftest.$ac_ext <<_ACEOF |
| 5220 | #line 5220 "configure" |
| 5221 | #include "confdefs.h" |
| 5222 | /* System header to define __stub macros and hopefully few prototypes, |
| 5223 | which can conflict with char tgoto (); below. */ |
| 5224 | #include <assert.h> |
| 5225 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5226 | #ifdef __cplusplus |
| 5227 | extern "C" |
| 5228 | #endif |
| 5229 | /* We use char because int might match the return type of a gcc2 |
| 5230 | builtin and then its argument prototype would still apply. */ |
| 5231 | char tgoto (); |
| 5232 | char (*f) (); |
| 5233 | |
| 5234 | int |
| 5235 | main () |
| 5236 | { |
| 5237 | /* The GNU C library defines this for functions which it implements |
| 5238 | to always fail with ENOSYS. Some functions are actually named |
| 5239 | something starting with __ and the normal name is an alias. */ |
| 5240 | #if defined (__stub_tgoto) || defined (__stub___tgoto) |
| 5241 | choke me |
| 5242 | #else |
| 5243 | f = tgoto; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 5244 | #endif |
| 5245 | |
| 5246 | ; |
| 5247 | return 0; |
| 5248 | } |
| 5249 | _ACEOF |
| 5250 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5251 | if { (eval echo "$as_me:5251: \"$ac_link\"") >&5 |
| 5252 | (eval $ac_link) 2>&5 |
| 5253 | ac_status=$? |
| 5254 | echo "$as_me:5254: \$? = $ac_status" >&5 |
| 5255 | (exit $ac_status); } && |
| 5256 | { ac_try='test -s conftest$ac_exeext' |
| 5257 | { (eval echo "$as_me:5257: \"$ac_try\"") >&5 |
| 5258 | (eval $ac_try) 2>&5 |
| 5259 | ac_status=$? |
| 5260 | echo "$as_me:5260: \$? = $ac_status" >&5 |
| 5261 | (exit $ac_status); }; }; then |
| 5262 | ac_cv_func_tgoto=yes |
| 5263 | else |
| 5264 | echo "$as_me: failed program was:" >&5 |
| 5265 | cat conftest.$ac_ext >&5 |
| 5266 | ac_cv_func_tgoto=no |
| 5267 | fi |
| 5268 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5269 | fi |
| 5270 | echo "$as_me:5270: result: $ac_cv_func_tgoto" >&5 |
| 5271 | echo "${ECHO_T}$ac_cv_func_tgoto" >&6 |
| 5272 | if test $ac_cv_func_tgoto = yes; then |
| 5273 | cf_term_lib=predefined |
| 5274 | else |
| 5275 | |
| 5276 | for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown |
| 5277 | do |
| 5278 | as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh` |
| 5279 | echo "$as_me:5279: checking for tgoto in -l$cf_term_lib" >&5 |
| 5280 | echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6 |
| 5281 | if eval "test \"\${$as_ac_Lib+set}\" = set"; then |
| 5282 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5283 | else |
| 5284 | ac_check_lib_save_LIBS=$LIBS |
| 5285 | LIBS="-l$cf_term_lib $LIBS" |
| 5286 | cat >conftest.$ac_ext <<_ACEOF |
| 5287 | #line 5287 "configure" |
| 5288 | #include "confdefs.h" |
| 5289 | |
| 5290 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5291 | #ifdef __cplusplus |
| 5292 | extern "C" |
| 5293 | #endif |
| 5294 | /* We use char because int might match the return type of a gcc2 |
| 5295 | builtin and then its argument prototype would still apply. */ |
| 5296 | char tgoto (); |
| 5297 | int |
| 5298 | main () |
| 5299 | { |
| 5300 | tgoto (); |
| 5301 | ; |
| 5302 | return 0; |
| 5303 | } |
| 5304 | _ACEOF |
| 5305 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5306 | if { (eval echo "$as_me:5306: \"$ac_link\"") >&5 |
| 5307 | (eval $ac_link) 2>&5 |
| 5308 | ac_status=$? |
| 5309 | echo "$as_me:5309: \$? = $ac_status" >&5 |
| 5310 | (exit $ac_status); } && |
| 5311 | { ac_try='test -s conftest$ac_exeext' |
| 5312 | { (eval echo "$as_me:5312: \"$ac_try\"") >&5 |
| 5313 | (eval $ac_try) 2>&5 |
| 5314 | ac_status=$? |
| 5315 | echo "$as_me:5315: \$? = $ac_status" >&5 |
| 5316 | (exit $ac_status); }; }; then |
| 5317 | eval "$as_ac_Lib=yes" |
| 5318 | else |
| 5319 | echo "$as_me: failed program was:" >&5 |
| 5320 | cat conftest.$ac_ext >&5 |
| 5321 | eval "$as_ac_Lib=no" |
| 5322 | fi |
| 5323 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5324 | LIBS=$ac_check_lib_save_LIBS |
| 5325 | fi |
| 5326 | echo "$as_me:5326: result: `eval echo '${'$as_ac_Lib'}'`" >&5 |
| 5327 | echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 |
| 5328 | if test `eval echo '${'$as_ac_Lib'}'` = yes; then |
| 5329 | break |
| 5330 | fi |
| 5331 | |
| 5332 | done |
| 5333 | |
| 5334 | fi |
| 5335 | |
| 5336 | fi |
| 5337 | |
| 5338 | # Check for library containing initscr |
| 5339 | test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS" |
| 5340 | if test "x$cf_curs_lib" = x |
| 5341 | then |
| 5342 | for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown |
| 5343 | do |
| 5344 | as_ac_Lib=`echo "ac_cv_lib_$cf_curs_lib''_initscr" | $as_tr_sh` |
| 5345 | echo "$as_me:5345: checking for initscr in -l$cf_curs_lib" >&5 |
| 5346 | echo $ECHO_N "checking for initscr in -l$cf_curs_lib... $ECHO_C" >&6 |
| 5347 | if eval "test \"\${$as_ac_Lib+set}\" = set"; then |
| 5348 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5349 | else |
| 5350 | ac_check_lib_save_LIBS=$LIBS |
| 5351 | LIBS="-l$cf_curs_lib $LIBS" |
| 5352 | cat >conftest.$ac_ext <<_ACEOF |
| 5353 | #line 5353 "configure" |
| 5354 | #include "confdefs.h" |
| 5355 | |
| 5356 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5357 | #ifdef __cplusplus |
| 5358 | extern "C" |
| 5359 | #endif |
| 5360 | /* We use char because int might match the return type of a gcc2 |
| 5361 | builtin and then its argument prototype would still apply. */ |
| 5362 | char initscr (); |
| 5363 | int |
| 5364 | main () |
| 5365 | { |
| 5366 | initscr (); |
| 5367 | ; |
| 5368 | return 0; |
| 5369 | } |
| 5370 | _ACEOF |
| 5371 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5372 | if { (eval echo "$as_me:5372: \"$ac_link\"") >&5 |
| 5373 | (eval $ac_link) 2>&5 |
| 5374 | ac_status=$? |
| 5375 | echo "$as_me:5375: \$? = $ac_status" >&5 |
| 5376 | (exit $ac_status); } && |
| 5377 | { ac_try='test -s conftest$ac_exeext' |
| 5378 | { (eval echo "$as_me:5378: \"$ac_try\"") >&5 |
| 5379 | (eval $ac_try) 2>&5 |
| 5380 | ac_status=$? |
| 5381 | echo "$as_me:5381: \$? = $ac_status" >&5 |
| 5382 | (exit $ac_status); }; }; then |
| 5383 | eval "$as_ac_Lib=yes" |
| 5384 | else |
| 5385 | echo "$as_me: failed program was:" >&5 |
| 5386 | cat conftest.$ac_ext >&5 |
| 5387 | eval "$as_ac_Lib=no" |
| 5388 | fi |
| 5389 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5390 | LIBS=$ac_check_lib_save_LIBS |
| 5391 | fi |
| 5392 | echo "$as_me:5392: result: `eval echo '${'$as_ac_Lib'}'`" >&5 |
| 5393 | echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 |
| 5394 | if test `eval echo '${'$as_ac_Lib'}'` = yes; then |
| 5395 | break |
| 5396 | fi |
| 5397 | |
| 5398 | done |
| 5399 | fi |
| 5400 | test $cf_curs_lib = unknown && { { echo "$as_me:5400: error: no curses library found" >&5 |
| 5401 | echo "$as_me: error: no curses library found" >&2;} |
| 5402 | { (exit 1); exit 1; }; } |
| 5403 | |
| 5404 | LIBS="-l$cf_curs_lib $cf_save_LIBS" |
| 5405 | if test "$cf_term_lib" = unknown ; then |
| 5406 | echo "$as_me:5406: checking if we can link with $cf_curs_lib library" >&5 |
| 5407 | echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6 |
| 5408 | cat >conftest.$ac_ext <<_ACEOF |
| 5409 | #line 5409 "configure" |
| 5410 | #include "confdefs.h" |
| 5411 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 5412 | int |
| 5413 | main () |
| 5414 | { |
| 5415 | initscr() |
| 5416 | ; |
| 5417 | return 0; |
| 5418 | } |
| 5419 | _ACEOF |
| 5420 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5421 | if { (eval echo "$as_me:5421: \"$ac_link\"") >&5 |
| 5422 | (eval $ac_link) 2>&5 |
| 5423 | ac_status=$? |
| 5424 | echo "$as_me:5424: \$? = $ac_status" >&5 |
| 5425 | (exit $ac_status); } && |
| 5426 | { ac_try='test -s conftest$ac_exeext' |
| 5427 | { (eval echo "$as_me:5427: \"$ac_try\"") >&5 |
| 5428 | (eval $ac_try) 2>&5 |
| 5429 | ac_status=$? |
| 5430 | echo "$as_me:5430: \$? = $ac_status" >&5 |
| 5431 | (exit $ac_status); }; }; then |
| 5432 | cf_result=yes |
| 5433 | else |
| 5434 | echo "$as_me: failed program was:" >&5 |
| 5435 | cat conftest.$ac_ext >&5 |
| 5436 | cf_result=no |
| 5437 | fi |
| 5438 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5439 | echo "$as_me:5439: result: $cf_result" >&5 |
| 5440 | echo "${ECHO_T}$cf_result" >&6 |
| 5441 | test $cf_result = no && { { echo "$as_me:5441: error: Cannot link curses library" >&5 |
| 5442 | echo "$as_me: error: Cannot link curses library" >&2;} |
| 5443 | { (exit 1); exit 1; }; } |
| 5444 | elif test "$cf_curs_lib" = "$cf_term_lib" ; then |
| 5445 | : |
| 5446 | elif test "$cf_term_lib" != predefined ; then |
| 5447 | echo "$as_me:5447: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5 |
| 5448 | echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6 |
| 5449 | cat >conftest.$ac_ext <<_ACEOF |
| 5450 | #line 5450 "configure" |
| 5451 | #include "confdefs.h" |
| 5452 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 5453 | int |
| 5454 | main () |
| 5455 | { |
| 5456 | initscr(); tgoto((char *)0, 0, 0); |
| 5457 | ; |
| 5458 | return 0; |
| 5459 | } |
| 5460 | _ACEOF |
| 5461 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5462 | if { (eval echo "$as_me:5462: \"$ac_link\"") >&5 |
| 5463 | (eval $ac_link) 2>&5 |
| 5464 | ac_status=$? |
| 5465 | echo "$as_me:5465: \$? = $ac_status" >&5 |
| 5466 | (exit $ac_status); } && |
| 5467 | { ac_try='test -s conftest$ac_exeext' |
| 5468 | { (eval echo "$as_me:5468: \"$ac_try\"") >&5 |
| 5469 | (eval $ac_try) 2>&5 |
| 5470 | ac_status=$? |
| 5471 | echo "$as_me:5471: \$? = $ac_status" >&5 |
| 5472 | (exit $ac_status); }; }; then |
| 5473 | cf_result=no |
| 5474 | else |
| 5475 | echo "$as_me: failed program was:" >&5 |
| 5476 | cat conftest.$ac_ext >&5 |
| 5477 | |
| 5478 | LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS" |
| 5479 | cat >conftest.$ac_ext <<_ACEOF |
| 5480 | #line 5480 "configure" |
| 5481 | #include "confdefs.h" |
| 5482 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 5483 | int |
| 5484 | main () |
| 5485 | { |
| 5486 | initscr() |
| 5487 | ; |
| 5488 | return 0; |
| 5489 | } |
| 5490 | _ACEOF |
| 5491 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5492 | if { (eval echo "$as_me:5492: \"$ac_link\"") >&5 |
| 5493 | (eval $ac_link) 2>&5 |
| 5494 | ac_status=$? |
| 5495 | echo "$as_me:5495: \$? = $ac_status" >&5 |
| 5496 | (exit $ac_status); } && |
| 5497 | { ac_try='test -s conftest$ac_exeext' |
| 5498 | { (eval echo "$as_me:5498: \"$ac_try\"") >&5 |
| 5499 | (eval $ac_try) 2>&5 |
| 5500 | ac_status=$? |
| 5501 | echo "$as_me:5501: \$? = $ac_status" >&5 |
| 5502 | (exit $ac_status); }; }; then |
| 5503 | cf_result=yes |
| 5504 | else |
| 5505 | echo "$as_me: failed program was:" >&5 |
| 5506 | cat conftest.$ac_ext >&5 |
| 5507 | cf_result=error |
| 5508 | fi |
| 5509 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5510 | |
| 5511 | fi |
| 5512 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5513 | echo "$as_me:5513: result: $cf_result" >&5 |
| 5514 | echo "${ECHO_T}$cf_result" >&6 |
| 5515 | fi |
| 5516 | fi |
| 5517 | fi |
| 5518 | |
| 5519 | ;; |
| 5520 | (ncursesw*) |
| 5521 | |
| 5522 | echo "$as_me:5522: checking for multibyte character support" >&5 |
| 5523 | echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6 |
| 5524 | if test "${cf_cv_utf8_lib+set}" = set; then |
| 5525 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5526 | else |
| 5527 | |
| 5528 | cf_save_LIBS="$LIBS" |
| 5529 | cat >conftest.$ac_ext <<_ACEOF |
| 5530 | #line 5530 "configure" |
| 5531 | #include "confdefs.h" |
| 5532 | |
| 5533 | #include <stdlib.h> |
| 5534 | int |
| 5535 | main () |
| 5536 | { |
| 5537 | putwc(0,0); |
| 5538 | ; |
| 5539 | return 0; |
| 5540 | } |
| 5541 | _ACEOF |
| 5542 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5543 | if { (eval echo "$as_me:5543: \"$ac_link\"") >&5 |
| 5544 | (eval $ac_link) 2>&5 |
| 5545 | ac_status=$? |
| 5546 | echo "$as_me:5546: \$? = $ac_status" >&5 |
| 5547 | (exit $ac_status); } && |
| 5548 | { ac_try='test -s conftest$ac_exeext' |
| 5549 | { (eval echo "$as_me:5549: \"$ac_try\"") >&5 |
| 5550 | (eval $ac_try) 2>&5 |
| 5551 | ac_status=$? |
| 5552 | echo "$as_me:5552: \$? = $ac_status" >&5 |
| 5553 | (exit $ac_status); }; }; then |
| 5554 | cf_cv_utf8_lib=yes |
| 5555 | else |
| 5556 | echo "$as_me: failed program was:" >&5 |
| 5557 | cat conftest.$ac_ext >&5 |
| 5558 | |
| 5559 | # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these |
| 5560 | # will be set on completion of the AC_TRY_LINK below. |
| 5561 | cf_cv_header_path_utf8= |
| 5562 | cf_cv_library_path_utf8= |
| 5563 | |
| 5564 | echo "${as_me:-configure}:5564: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5 |
| 5565 | |
| 5566 | cf_save_LIBS="$LIBS" |
| 5567 | |
| 5568 | cat >conftest.$ac_ext <<_ACEOF |
| 5569 | #line 5569 "configure" |
| 5570 | #include "confdefs.h" |
| 5571 | |
| 5572 | #include <libutf8.h> |
| 5573 | int |
| 5574 | main () |
| 5575 | { |
| 5576 | putwc(0,0); |
| 5577 | ; |
| 5578 | return 0; |
| 5579 | } |
| 5580 | _ACEOF |
| 5581 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5582 | if { (eval echo "$as_me:5582: \"$ac_link\"") >&5 |
| 5583 | (eval $ac_link) 2>&5 |
| 5584 | ac_status=$? |
| 5585 | echo "$as_me:5585: \$? = $ac_status" >&5 |
| 5586 | (exit $ac_status); } && |
| 5587 | { ac_try='test -s conftest$ac_exeext' |
| 5588 | { (eval echo "$as_me:5588: \"$ac_try\"") >&5 |
| 5589 | (eval $ac_try) 2>&5 |
| 5590 | ac_status=$? |
| 5591 | echo "$as_me:5591: \$? = $ac_status" >&5 |
| 5592 | (exit $ac_status); }; }; then |
| 5593 | |
| 5594 | cf_cv_find_linkage_utf8=yes |
| 5595 | cf_cv_header_path_utf8=/usr/include |
| 5596 | cf_cv_library_path_utf8=/usr/lib |
| 5597 | |
| 5598 | else |
| 5599 | echo "$as_me: failed program was:" >&5 |
| 5600 | cat conftest.$ac_ext >&5 |
| 5601 | |
| 5602 | LIBS="-lutf8 $cf_save_LIBS" |
| 5603 | |
| 5604 | cat >conftest.$ac_ext <<_ACEOF |
| 5605 | #line 5605 "configure" |
| 5606 | #include "confdefs.h" |
| 5607 | |
| 5608 | #include <libutf8.h> |
| 5609 | int |
| 5610 | main () |
| 5611 | { |
| 5612 | putwc(0,0); |
| 5613 | ; |
| 5614 | return 0; |
| 5615 | } |
| 5616 | _ACEOF |
| 5617 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5618 | if { (eval echo "$as_me:5618: \"$ac_link\"") >&5 |
| 5619 | (eval $ac_link) 2>&5 |
| 5620 | ac_status=$? |
| 5621 | echo "$as_me:5621: \$? = $ac_status" >&5 |
| 5622 | (exit $ac_status); } && |
| 5623 | { ac_try='test -s conftest$ac_exeext' |
| 5624 | { (eval echo "$as_me:5624: \"$ac_try\"") >&5 |
| 5625 | (eval $ac_try) 2>&5 |
| 5626 | ac_status=$? |
| 5627 | echo "$as_me:5627: \$? = $ac_status" >&5 |
| 5628 | (exit $ac_status); }; }; then |
| 5629 | |
| 5630 | cf_cv_find_linkage_utf8=yes |
| 5631 | cf_cv_header_path_utf8=/usr/include |
| 5632 | cf_cv_library_path_utf8=/usr/lib |
| 5633 | cf_cv_library_file_utf8="-lutf8" |
| 5634 | |
| 5635 | else |
| 5636 | echo "$as_me: failed program was:" >&5 |
| 5637 | cat conftest.$ac_ext >&5 |
| 5638 | |
| 5639 | cf_cv_find_linkage_utf8=no |
| 5640 | LIBS="$cf_save_LIBS" |
| 5641 | |
| 5642 | test -n "$verbose" && echo " find linkage for utf8 library" 1>&6 |
| 5643 | |
| 5644 | echo "${as_me:-configure}:5644: testing find linkage for utf8 library ..." 1>&5 |
| 5645 | |
| 5646 | echo "${as_me:-configure}:5646: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5 |
| 5647 | |
| 5648 | cf_save_CPPFLAGS="$CPPFLAGS" |
| 5649 | cf_test_CPPFLAGS="$CPPFLAGS" |
| 5650 | |
| 5651 | cf_search= |
| 5652 | |
| 5653 | # collect the current set of include-directories from compiler flags |
| 5654 | cf_header_path_list="" |
| 5655 | if test -n "${CFLAGS}${CPPFLAGS}" ; then |
| 5656 | for cf_header_path in $CPPFLAGS $CFLAGS |
| 5657 | do |
| 5658 | case $cf_header_path in |
| 5659 | (-I*) |
| 5660 | cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'` |
| 5661 | |
| 5662 | test "x$cf_header_path" != "xNONE" && \ |
| 5663 | test -d "$cf_header_path" && \ |
| 5664 | { |
| 5665 | test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path" |
| 5666 | test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include" |
| 5667 | test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8" |
| 5668 | test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include" |
| 5669 | test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include" |
| 5670 | test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8" |
| 5671 | } |
| 5672 | |
| 5673 | cf_header_path_list="$cf_header_path_list $cf_search" |
| 5674 | ;; |
| 5675 | esac |
| 5676 | done |
| 5677 | fi |
| 5678 | |
| 5679 | # add the variations for the package we are looking for |
| 5680 | |
| 5681 | cf_search= |
| 5682 | |
| 5683 | test "x$prefix" != "xNONE" && \ |
| 5684 | test -d "$prefix" && \ |
| 5685 | { |
| 5686 | test -n "$verbose" && echo " ... testing for include-directories under $prefix" |
| 5687 | test -d $prefix/include && cf_search="$cf_search $prefix/include" |
| 5688 | test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8" |
| 5689 | test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include" |
| 5690 | test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include" |
| 5691 | test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8" |
| 5692 | } |
| 5693 | |
| 5694 | for cf_subdir_prefix in \ |
| 5695 | /usr \ |
| 5696 | /usr/local \ |
| 5697 | /usr/pkg \ |
| 5698 | /opt \ |
| 5699 | /opt/local \ |
| 5700 | $HOME |
| 5701 | do |
| 5702 | |
| 5703 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 5704 | test -d "$cf_subdir_prefix" && \ |
| 5705 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 5706 | test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix" |
| 5707 | test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include" |
| 5708 | test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8" |
| 5709 | test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include" |
| 5710 | test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include" |
| 5711 | test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8" |
| 5712 | } |
| 5713 | |
| 5714 | done |
| 5715 | |
| 5716 | test "$includedir" != NONE && \ |
| 5717 | test "$includedir" != "/usr/include" && \ |
| 5718 | test -d "$includedir" && { |
| 5719 | test -d $includedir && cf_search="$cf_search $includedir" |
| 5720 | test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8" |
| 5721 | } |
| 5722 | |
| 5723 | test "$oldincludedir" != NONE && \ |
| 5724 | test "$oldincludedir" != "/usr/include" && \ |
| 5725 | test -d "$oldincludedir" && { |
| 5726 | test -d $oldincludedir && cf_search="$cf_search $oldincludedir" |
| 5727 | test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8" |
| 5728 | } |
| 5729 | |
| 5730 | cf_search="$cf_search $cf_header_path_list" |
| 5731 | |
| 5732 | for cf_cv_header_path_utf8 in $cf_search |
| 5733 | do |
| 5734 | if test -d $cf_cv_header_path_utf8 ; then |
| 5735 | test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6 |
| 5736 | |
| 5737 | echo "${as_me:-configure}:5737: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5 |
| 5738 | |
| 5739 | CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8" |
| 5740 | cat >conftest.$ac_ext <<_ACEOF |
| 5741 | #line 5741 "configure" |
| 5742 | #include "confdefs.h" |
| 5743 | |
| 5744 | #include <libutf8.h> |
| 5745 | int |
| 5746 | main () |
| 5747 | { |
| 5748 | putwc(0,0); |
| 5749 | ; |
| 5750 | return 0; |
| 5751 | } |
| 5752 | _ACEOF |
| 5753 | rm -f conftest.$ac_objext |
| 5754 | if { (eval echo "$as_me:5754: \"$ac_compile\"") >&5 |
| 5755 | (eval $ac_compile) 2>&5 |
| 5756 | ac_status=$? |
| 5757 | echo "$as_me:5757: \$? = $ac_status" >&5 |
| 5758 | (exit $ac_status); } && |
| 5759 | { ac_try='test -s conftest.$ac_objext' |
| 5760 | { (eval echo "$as_me:5760: \"$ac_try\"") >&5 |
| 5761 | (eval $ac_try) 2>&5 |
| 5762 | ac_status=$? |
| 5763 | echo "$as_me:5763: \$? = $ac_status" >&5 |
| 5764 | (exit $ac_status); }; }; then |
| 5765 | |
| 5766 | test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6 |
| 5767 | |
| 5768 | echo "${as_me:-configure}:5768: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5 |
| 5769 | |
| 5770 | cf_cv_find_linkage_utf8=maybe |
| 5771 | cf_test_CPPFLAGS="$CPPFLAGS" |
| 5772 | break |
| 5773 | else |
| 5774 | echo "$as_me: failed program was:" >&5 |
| 5775 | cat conftest.$ac_ext >&5 |
| 5776 | |
| 5777 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 5778 | |
| 5779 | fi |
| 5780 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 5781 | fi |
| 5782 | done |
| 5783 | |
| 5784 | if test "$cf_cv_find_linkage_utf8" = maybe ; then |
| 5785 | |
| 5786 | echo "${as_me:-configure}:5786: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5 |
| 5787 | |
| 5788 | cf_save_LIBS="$LIBS" |
| 5789 | cf_save_LDFLAGS="$LDFLAGS" |
| 5790 | |
| 5791 | if test "$cf_cv_find_linkage_utf8" != yes ; then |
| 5792 | |
| 5793 | cf_search= |
| 5794 | cf_library_path_list="" |
| 5795 | if test -n "${LDFLAGS}${LIBS}" ; then |
| 5796 | for cf_library_path in $LDFLAGS $LIBS |
| 5797 | do |
| 5798 | case $cf_library_path in |
| 5799 | (-L*) |
| 5800 | cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'` |
| 5801 | |
| 5802 | test "x$cf_library_path" != "xNONE" && \ |
| 5803 | test -d "$cf_library_path" && \ |
| 5804 | { |
| 5805 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path" |
| 5806 | test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib" |
| 5807 | test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8" |
| 5808 | test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib" |
| 5809 | test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib" |
| 5810 | test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8" |
| 5811 | } |
| 5812 | |
| 5813 | cf_library_path_list="$cf_library_path_list $cf_search" |
| 5814 | ;; |
| 5815 | esac |
| 5816 | done |
| 5817 | fi |
| 5818 | |
| 5819 | cf_search= |
| 5820 | |
| 5821 | test "x$prefix" != "xNONE" && \ |
| 5822 | test -d "$prefix" && \ |
| 5823 | { |
| 5824 | test -n "$verbose" && echo " ... testing for lib-directories under $prefix" |
| 5825 | test -d $prefix/lib && cf_search="$cf_search $prefix/lib" |
| 5826 | test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8" |
| 5827 | test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib" |
| 5828 | test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib" |
| 5829 | test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8" |
| 5830 | } |
| 5831 | |
| 5832 | for cf_subdir_prefix in \ |
| 5833 | /usr \ |
| 5834 | /usr/local \ |
| 5835 | /usr/pkg \ |
| 5836 | /opt \ |
| 5837 | /opt/local \ |
| 5838 | $HOME |
| 5839 | do |
| 5840 | |
| 5841 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 5842 | test -d "$cf_subdir_prefix" && \ |
| 5843 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 5844 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix" |
| 5845 | test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib" |
| 5846 | test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8" |
| 5847 | test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib" |
| 5848 | test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib" |
| 5849 | test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8" |
| 5850 | } |
| 5851 | |
| 5852 | done |
| 5853 | |
| 5854 | cf_search="$cf_library_path_list $cf_search" |
| 5855 | |
| 5856 | for cf_cv_library_path_utf8 in $cf_search |
| 5857 | do |
| 5858 | if test -d $cf_cv_library_path_utf8 ; then |
| 5859 | test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6 |
| 5860 | |
| 5861 | echo "${as_me:-configure}:5861: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5 |
| 5862 | |
| 5863 | CPPFLAGS="$cf_test_CPPFLAGS" |
| 5864 | LIBS="-lutf8 $cf_save_LIBS" |
| 5865 | LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8" |
| 5866 | cat >conftest.$ac_ext <<_ACEOF |
| 5867 | #line 5867 "configure" |
| 5868 | #include "confdefs.h" |
| 5869 | |
| 5870 | #include <libutf8.h> |
| 5871 | int |
| 5872 | main () |
| 5873 | { |
| 5874 | putwc(0,0); |
| 5875 | ; |
| 5876 | return 0; |
| 5877 | } |
| 5878 | _ACEOF |
| 5879 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5880 | if { (eval echo "$as_me:5880: \"$ac_link\"") >&5 |
| 5881 | (eval $ac_link) 2>&5 |
| 5882 | ac_status=$? |
| 5883 | echo "$as_me:5883: \$? = $ac_status" >&5 |
| 5884 | (exit $ac_status); } && |
| 5885 | { ac_try='test -s conftest$ac_exeext' |
| 5886 | { (eval echo "$as_me:5886: \"$ac_try\"") >&5 |
| 5887 | (eval $ac_try) 2>&5 |
| 5888 | ac_status=$? |
| 5889 | echo "$as_me:5889: \$? = $ac_status" >&5 |
| 5890 | (exit $ac_status); }; }; then |
| 5891 | |
| 5892 | test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6 |
| 5893 | |
| 5894 | echo "${as_me:-configure}:5894: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5 |
| 5895 | |
| 5896 | cf_cv_find_linkage_utf8=yes |
| 5897 | cf_cv_library_file_utf8="-lutf8" |
| 5898 | break |
| 5899 | else |
| 5900 | echo "$as_me: failed program was:" >&5 |
| 5901 | cat conftest.$ac_ext >&5 |
| 5902 | |
| 5903 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 5904 | LIBS="$cf_save_LIBS" |
| 5905 | LDFLAGS="$cf_save_LDFLAGS" |
| 5906 | |
| 5907 | fi |
| 5908 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5909 | fi |
| 5910 | done |
| 5911 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 5912 | LDFLAGS="$cf_save_LDFLAGS" |
| 5913 | fi |
| 5914 | |
| 5915 | else |
| 5916 | cf_cv_find_linkage_utf8=no |
| 5917 | fi |
| 5918 | |
| 5919 | fi |
| 5920 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5921 | |
| 5922 | fi |
| 5923 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5924 | |
| 5925 | LIBS="$cf_save_LIBS" |
| 5926 | |
| 5927 | if test "$cf_cv_find_linkage_utf8" = yes ; then |
| 5928 | cf_cv_utf8_lib=add-on |
| 5929 | else |
| 5930 | cf_cv_utf8_lib=no |
| 5931 | fi |
| 5932 | |
| 5933 | fi |
| 5934 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5935 | fi |
| 5936 | echo "$as_me:5936: result: $cf_cv_utf8_lib" >&5 |
| 5937 | echo "${ECHO_T}$cf_cv_utf8_lib" >&6 |
| 5938 | |
| 5939 | # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between |
| 5940 | # ncurses/ncursesw: |
| 5941 | if test "$cf_cv_utf8_lib" = "add-on" ; then |
| 5942 | |
| 5943 | cat >>confdefs.h <<\EOF |
| 5944 | #define HAVE_LIBUTF8_H 1 |
| 5945 | EOF |
| 5946 | |
| 5947 | if test -n "$cf_cv_header_path_utf8" ; then |
| 5948 | for cf_add_incdir in $cf_cv_header_path_utf8 |
| 5949 | do |
| 5950 | while test $cf_add_incdir != /usr/include |
| 5951 | do |
| 5952 | if test -d $cf_add_incdir |
| 5953 | then |
| 5954 | cf_have_incdir=no |
| 5955 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 5956 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 5957 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 5958 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 5959 | cf_have_incdir=yes; break |
| 5960 | fi |
| 5961 | done |
| 5962 | fi |
| 5963 | |
| 5964 | if test "$cf_have_incdir" = no ; then |
| 5965 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 5966 | if test "$GCC" = yes |
| 5967 | then |
| 5968 | cf_save_CPPFLAGS=$CPPFLAGS |
| 5969 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 5970 | cat >conftest.$ac_ext <<_ACEOF |
| 5971 | #line 5971 "configure" |
| 5972 | #include "confdefs.h" |
| 5973 | #include <stdio.h> |
| 5974 | int |
| 5975 | main () |
| 5976 | { |
| 5977 | printf("Hello") |
| 5978 | ; |
| 5979 | return 0; |
| 5980 | } |
| 5981 | _ACEOF |
| 5982 | rm -f conftest.$ac_objext |
| 5983 | if { (eval echo "$as_me:5983: \"$ac_compile\"") >&5 |
| 5984 | (eval $ac_compile) 2>&5 |
| 5985 | ac_status=$? |
| 5986 | echo "$as_me:5986: \$? = $ac_status" >&5 |
| 5987 | (exit $ac_status); } && |
| 5988 | { ac_try='test -s conftest.$ac_objext' |
| 5989 | { (eval echo "$as_me:5989: \"$ac_try\"") >&5 |
| 5990 | (eval $ac_try) 2>&5 |
| 5991 | ac_status=$? |
| 5992 | echo "$as_me:5992: \$? = $ac_status" >&5 |
| 5993 | (exit $ac_status); }; }; then |
| 5994 | : |
| 5995 | else |
| 5996 | echo "$as_me: failed program was:" >&5 |
| 5997 | cat conftest.$ac_ext >&5 |
| 5998 | cf_have_incdir=yes |
| 5999 | fi |
| 6000 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6001 | CPPFLAGS=$cf_save_CPPFLAGS |
| 6002 | fi |
| 6003 | fi |
| 6004 | fi |
| 6005 | |
| 6006 | if test "$cf_have_incdir" = no ; then |
| 6007 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 6008 | |
| 6009 | echo "${as_me:-configure}:6009: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 6010 | |
| 6011 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 6012 | |
| 6013 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 6014 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 6015 | cf_add_incdir="$cf_top_incdir" |
| 6016 | else |
| 6017 | break |
| 6018 | fi |
| 6019 | else |
| 6020 | break |
| 6021 | fi |
| 6022 | done |
| 6023 | done |
| 6024 | fi |
| 6025 | |
| 6026 | if test -n "$cf_cv_library_path_utf8" ; then |
| 6027 | for cf_add_libdir in $cf_cv_library_path_utf8 |
| 6028 | do |
| 6029 | if test $cf_add_libdir = /usr/lib ; then |
| 6030 | : |
| 6031 | elif test -d $cf_add_libdir |
| 6032 | then |
| 6033 | cf_have_libdir=no |
| 6034 | if test -n "$LDFLAGS$LIBS" ; then |
| 6035 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 6036 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 6037 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 6038 | cf_have_libdir=yes; break |
| 6039 | fi |
| 6040 | done |
| 6041 | fi |
| 6042 | if test "$cf_have_libdir" = no ; then |
| 6043 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 6044 | |
| 6045 | echo "${as_me:-configure}:6045: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 6046 | |
| 6047 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 6048 | fi |
| 6049 | fi |
| 6050 | done |
| 6051 | fi |
| 6052 | |
| 6053 | cf_add_libs="$cf_cv_library_file_utf8" |
| 6054 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 6055 | for cf_add_1lib in $LIBS |
| 6056 | do |
| 6057 | for cf_add_2lib in $cf_add_libs |
| 6058 | do |
| 6059 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 6060 | then |
| 6061 | cf_add_1lib= |
| 6062 | break |
| 6063 | fi |
| 6064 | done |
| 6065 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 6066 | done |
| 6067 | LIBS="$cf_add_libs" |
| 6068 | |
| 6069 | fi |
| 6070 | |
| 6071 | cf_ncuconfig_root=$cf_cv_screen |
| 6072 | cf_have_ncuconfig=no |
| 6073 | |
| 6074 | if test "x${PKG_CONFIG:=none}" != xnone; then |
| 6075 | echo "$as_me:6075: checking pkg-config for $cf_ncuconfig_root" >&5 |
| 6076 | echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6 |
| 6077 | if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then |
| 6078 | echo "$as_me:6078: result: yes" >&5 |
| 6079 | echo "${ECHO_T}yes" >&6 |
| 6080 | |
| 6081 | echo "$as_me:6081: checking if the $cf_ncuconfig_root package files work" >&5 |
| 6082 | echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6 |
| 6083 | cf_have_ncuconfig=unknown |
| 6084 | |
| 6085 | cf_save_CPPFLAGS="$CPPFLAGS" |
| 6086 | cf_save_LIBS="$LIBS" |
| 6087 | |
| 6088 | CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`" |
| 6089 | |
| 6090 | cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`" |
| 6091 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 6092 | for cf_add_1lib in $LIBS |
| 6093 | do |
| 6094 | for cf_add_2lib in $cf_add_libs |
| 6095 | do |
| 6096 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 6097 | then |
| 6098 | cf_add_1lib= |
| 6099 | break |
| 6100 | fi |
| 6101 | done |
| 6102 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 6103 | done |
| 6104 | LIBS="$cf_add_libs" |
| 6105 | |
| 6106 | cat >conftest.$ac_ext <<_ACEOF |
| 6107 | #line 6107 "configure" |
| 6108 | #include "confdefs.h" |
| 6109 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 6110 | int |
| 6111 | main () |
| 6112 | { |
| 6113 | initscr(); mousemask(0,0); tgoto((char *)0, 0, 0); |
| 6114 | ; |
| 6115 | return 0; |
| 6116 | } |
| 6117 | _ACEOF |
| 6118 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 6119 | if { (eval echo "$as_me:6119: \"$ac_link\"") >&5 |
| 6120 | (eval $ac_link) 2>&5 |
| 6121 | ac_status=$? |
| 6122 | echo "$as_me:6122: \$? = $ac_status" >&5 |
| 6123 | (exit $ac_status); } && |
| 6124 | { ac_try='test -s conftest$ac_exeext' |
| 6125 | { (eval echo "$as_me:6125: \"$ac_try\"") >&5 |
| 6126 | (eval $ac_try) 2>&5 |
| 6127 | ac_status=$? |
| 6128 | echo "$as_me:6128: \$? = $ac_status" >&5 |
| 6129 | (exit $ac_status); }; }; then |
| 6130 | if test "$cross_compiling" = yes; then |
| 6131 | cf_have_ncuconfig=maybe |
| 6132 | else |
| 6133 | cat >conftest.$ac_ext <<_ACEOF |
| 6134 | #line 6134 "configure" |
| 6135 | #include "confdefs.h" |
| 6136 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 6137 | int main(void) |
| 6138 | { char *xx = curses_version(); return (xx == 0); } |
| 6139 | _ACEOF |
| 6140 | rm -f conftest$ac_exeext |
| 6141 | if { (eval echo "$as_me:6141: \"$ac_link\"") >&5 |
| 6142 | (eval $ac_link) 2>&5 |
| 6143 | ac_status=$? |
| 6144 | echo "$as_me:6144: \$? = $ac_status" >&5 |
| 6145 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 6146 | { (eval echo "$as_me:6146: \"$ac_try\"") >&5 |
| 6147 | (eval $ac_try) 2>&5 |
| 6148 | ac_status=$? |
| 6149 | echo "$as_me:6149: \$? = $ac_status" >&5 |
| 6150 | (exit $ac_status); }; }; then |
| 6151 | cf_have_ncuconfig=yes |
| 6152 | else |
| 6153 | echo "$as_me: program exited with status $ac_status" >&5 |
| 6154 | echo "$as_me: failed program was:" >&5 |
| 6155 | cat conftest.$ac_ext >&5 |
| 6156 | cf_have_ncuconfig=no |
| 6157 | fi |
| 6158 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 6159 | fi |
| 6160 | else |
| 6161 | echo "$as_me: failed program was:" >&5 |
| 6162 | cat conftest.$ac_ext >&5 |
| 6163 | cf_have_ncuconfig=no |
| 6164 | fi |
| 6165 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 6166 | echo "$as_me:6166: result: $cf_have_ncuconfig" >&5 |
| 6167 | echo "${ECHO_T}$cf_have_ncuconfig" >&6 |
| 6168 | test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes |
| 6169 | if test "$cf_have_ncuconfig" != "yes" |
| 6170 | then |
| 6171 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 6172 | LIBS="$cf_save_LIBS" |
| 6173 | NCURSES_CONFIG_PKG=none |
| 6174 | else |
| 6175 | |
| 6176 | cat >>confdefs.h <<\EOF |
| 6177 | #define NCURSES 1 |
| 6178 | EOF |
| 6179 | |
| 6180 | NCURSES_CONFIG_PKG=$cf_ncuconfig_root |
| 6181 | fi |
| 6182 | |
| 6183 | else |
| 6184 | echo "$as_me:6184: result: no" >&5 |
| 6185 | echo "${ECHO_T}no" >&6 |
| 6186 | NCURSES_CONFIG_PKG=none |
| 6187 | fi |
| 6188 | else |
| 6189 | NCURSES_CONFIG_PKG=none |
| 6190 | fi |
| 6191 | |
| 6192 | if test "x$cf_have_ncuconfig" = "xno"; then |
| 6193 | echo "Looking for ${cf_ncuconfig_root}-config" |
| 6194 | |
| 6195 | if test -n "$ac_tool_prefix"; then |
| 6196 | for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config |
| 6197 | do |
| 6198 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 6199 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
| 6200 | echo "$as_me:6200: checking for $ac_word" >&5 |
| 6201 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 6202 | if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then |
| 6203 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6204 | else |
| 6205 | if test -n "$NCURSES_CONFIG"; then |
| 6206 | ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test. |
| 6207 | else |
| 6208 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 6209 | ac_dummy="$PATH" |
| 6210 | for ac_dir in $ac_dummy; do |
| 6211 | IFS=$ac_save_IFS |
| 6212 | test -z "$ac_dir" && ac_dir=. |
| 6213 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 6214 | ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog" |
| 6215 | echo "$as_me:6215: found $ac_dir/$ac_word" >&5 |
| 6216 | break |
| 6217 | done |
| 6218 | |
| 6219 | fi |
| 6220 | fi |
| 6221 | NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG |
| 6222 | if test -n "$NCURSES_CONFIG"; then |
| 6223 | echo "$as_me:6223: result: $NCURSES_CONFIG" >&5 |
| 6224 | echo "${ECHO_T}$NCURSES_CONFIG" >&6 |
| 6225 | else |
| 6226 | echo "$as_me:6226: result: no" >&5 |
| 6227 | echo "${ECHO_T}no" >&6 |
| 6228 | fi |
| 6229 | |
| 6230 | test -n "$NCURSES_CONFIG" && break |
| 6231 | done |
| 6232 | fi |
| 6233 | if test -z "$NCURSES_CONFIG"; then |
| 6234 | ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG |
| 6235 | for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config |
| 6236 | do |
| 6237 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 6238 | set dummy $ac_prog; ac_word=$2 |
| 6239 | echo "$as_me:6239: checking for $ac_word" >&5 |
| 6240 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 6241 | if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then |
| 6242 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6243 | else |
| 6244 | if test -n "$ac_ct_NCURSES_CONFIG"; then |
| 6245 | ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test. |
| 6246 | else |
| 6247 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 6248 | ac_dummy="$PATH" |
| 6249 | for ac_dir in $ac_dummy; do |
| 6250 | IFS=$ac_save_IFS |
| 6251 | test -z "$ac_dir" && ac_dir=. |
| 6252 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 6253 | ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog" |
| 6254 | echo "$as_me:6254: found $ac_dir/$ac_word" >&5 |
| 6255 | break |
| 6256 | done |
| 6257 | |
| 6258 | fi |
| 6259 | fi |
| 6260 | ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG |
| 6261 | if test -n "$ac_ct_NCURSES_CONFIG"; then |
| 6262 | echo "$as_me:6262: result: $ac_ct_NCURSES_CONFIG" >&5 |
| 6263 | echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6 |
| 6264 | else |
| 6265 | echo "$as_me:6265: result: no" >&5 |
| 6266 | echo "${ECHO_T}no" >&6 |
| 6267 | fi |
| 6268 | |
| 6269 | test -n "$ac_ct_NCURSES_CONFIG" && break |
| 6270 | done |
| 6271 | test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none" |
| 6272 | |
| 6273 | NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG |
| 6274 | fi |
| 6275 | |
| 6276 | if test "$NCURSES_CONFIG" != none ; then |
| 6277 | |
| 6278 | CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`" |
| 6279 | |
| 6280 | cf_add_libs="`$NCURSES_CONFIG --libs`" |
| 6281 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 6282 | for cf_add_1lib in $LIBS |
| 6283 | do |
| 6284 | for cf_add_2lib in $cf_add_libs |
| 6285 | do |
| 6286 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 6287 | then |
| 6288 | cf_add_1lib= |
| 6289 | break |
| 6290 | fi |
| 6291 | done |
| 6292 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 6293 | done |
| 6294 | LIBS="$cf_add_libs" |
| 6295 | |
| 6296 | # even with config script, some packages use no-override for curses.h |
| 6297 | |
| 6298 | echo "$as_me:6298: checking if we have identified curses headers" >&5 |
| 6299 | echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6 |
| 6300 | if test "${cf_cv_ncurses_header+set}" = set; then |
| 6301 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6302 | else |
| 6303 | |
| 6304 | cf_cv_ncurses_header=none |
| 6305 | for cf_header in \ |
| 6306 | ncurses.h $cf_cv_screen/ncurses.h \ |
| 6307 | curses.h $cf_cv_screen/curses.h |
| 6308 | do |
| 6309 | cat >conftest.$ac_ext <<_ACEOF |
| 6310 | #line 6310 "configure" |
| 6311 | #include "confdefs.h" |
| 6312 | #include <${cf_header}> |
| 6313 | int |
| 6314 | main () |
| 6315 | { |
| 6316 | initscr(); tgoto("?", 0,0) |
| 6317 | ; |
| 6318 | return 0; |
| 6319 | } |
| 6320 | _ACEOF |
| 6321 | rm -f conftest.$ac_objext |
| 6322 | if { (eval echo "$as_me:6322: \"$ac_compile\"") >&5 |
| 6323 | (eval $ac_compile) 2>&5 |
| 6324 | ac_status=$? |
| 6325 | echo "$as_me:6325: \$? = $ac_status" >&5 |
| 6326 | (exit $ac_status); } && |
| 6327 | { ac_try='test -s conftest.$ac_objext' |
| 6328 | { (eval echo "$as_me:6328: \"$ac_try\"") >&5 |
| 6329 | (eval $ac_try) 2>&5 |
| 6330 | ac_status=$? |
| 6331 | echo "$as_me:6331: \$? = $ac_status" >&5 |
| 6332 | (exit $ac_status); }; }; then |
| 6333 | cf_cv_ncurses_header=$cf_header; break |
| 6334 | else |
| 6335 | echo "$as_me: failed program was:" >&5 |
| 6336 | cat conftest.$ac_ext >&5 |
| 6337 | fi |
| 6338 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6339 | done |
| 6340 | |
| 6341 | fi |
| 6342 | echo "$as_me:6342: result: $cf_cv_ncurses_header" >&5 |
| 6343 | echo "${ECHO_T}$cf_cv_ncurses_header" >&6 |
| 6344 | |
| 6345 | if test "$cf_cv_ncurses_header" = none ; then |
| 6346 | { { echo "$as_me:6346: error: No curses header-files found" >&5 |
| 6347 | echo "$as_me: error: No curses header-files found" >&2;} |
| 6348 | { (exit 1); exit 1; }; } |
| 6349 | fi |
| 6350 | |
| 6351 | # cheat, to get the right #define's for HAVE_NCURSES_H, etc. |
| 6352 | |
| 6353 | for ac_header in $cf_cv_ncurses_header |
| 6354 | do |
| 6355 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 6356 | echo "$as_me:6356: checking for $ac_header" >&5 |
| 6357 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 6358 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 6359 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6360 | else |
| 6361 | cat >conftest.$ac_ext <<_ACEOF |
| 6362 | #line 6362 "configure" |
| 6363 | #include "confdefs.h" |
| 6364 | #include <$ac_header> |
| 6365 | _ACEOF |
| 6366 | if { (eval echo "$as_me:6366: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 6367 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 6368 | ac_status=$? |
| 6369 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 6370 | rm -f conftest.er1 |
| 6371 | cat conftest.err >&5 |
| 6372 | echo "$as_me:6372: \$? = $ac_status" >&5 |
| 6373 | (exit $ac_status); } >/dev/null; then |
| 6374 | if test -s conftest.err; then |
| 6375 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 6376 | else |
| 6377 | ac_cpp_err= |
| 6378 | fi |
| 6379 | else |
| 6380 | ac_cpp_err=yes |
| 6381 | fi |
| 6382 | if test -z "$ac_cpp_err"; then |
| 6383 | eval "$as_ac_Header=yes" |
| 6384 | else |
| 6385 | echo "$as_me: failed program was:" >&5 |
| 6386 | cat conftest.$ac_ext >&5 |
| 6387 | eval "$as_ac_Header=no" |
| 6388 | fi |
| 6389 | rm -f conftest.err conftest.$ac_ext |
| 6390 | fi |
| 6391 | echo "$as_me:6391: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 6392 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 6393 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 6394 | cat >>confdefs.h <<EOF |
| 6395 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 6396 | EOF |
| 6397 | |
| 6398 | fi |
| 6399 | done |
| 6400 | |
| 6401 | cat >>confdefs.h <<\EOF |
| 6402 | #define NCURSES 1 |
| 6403 | EOF |
| 6404 | |
| 6405 | cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 6406 | |
| 6407 | cat >>confdefs.h <<EOF |
| 6408 | #define $cf_nculib_ROOT 1 |
| 6409 | EOF |
| 6410 | |
| 6411 | cf_cv_ncurses_version=`$NCURSES_CONFIG --version` |
| 6412 | |
| 6413 | else |
| 6414 | |
| 6415 | cf_ncuhdr_root=$cf_cv_screen |
| 6416 | |
| 6417 | test -n "$cf_cv_curses_dir" && \ |
| 6418 | test "$cf_cv_curses_dir" != "no" && { \ |
| 6419 | |
| 6420 | if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then |
| 6421 | for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root |
| 6422 | do |
| 6423 | while test $cf_add_incdir != /usr/include |
| 6424 | do |
| 6425 | if test -d $cf_add_incdir |
| 6426 | then |
| 6427 | cf_have_incdir=no |
| 6428 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 6429 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 6430 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 6431 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 6432 | cf_have_incdir=yes; break |
| 6433 | fi |
| 6434 | done |
| 6435 | fi |
| 6436 | |
| 6437 | if test "$cf_have_incdir" = no ; then |
| 6438 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 6439 | if test "$GCC" = yes |
| 6440 | then |
| 6441 | cf_save_CPPFLAGS=$CPPFLAGS |
| 6442 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 6443 | cat >conftest.$ac_ext <<_ACEOF |
| 6444 | #line 6444 "configure" |
| 6445 | #include "confdefs.h" |
| 6446 | #include <stdio.h> |
| 6447 | int |
| 6448 | main () |
| 6449 | { |
| 6450 | printf("Hello") |
| 6451 | ; |
| 6452 | return 0; |
| 6453 | } |
| 6454 | _ACEOF |
| 6455 | rm -f conftest.$ac_objext |
| 6456 | if { (eval echo "$as_me:6456: \"$ac_compile\"") >&5 |
| 6457 | (eval $ac_compile) 2>&5 |
| 6458 | ac_status=$? |
| 6459 | echo "$as_me:6459: \$? = $ac_status" >&5 |
| 6460 | (exit $ac_status); } && |
| 6461 | { ac_try='test -s conftest.$ac_objext' |
| 6462 | { (eval echo "$as_me:6462: \"$ac_try\"") >&5 |
| 6463 | (eval $ac_try) 2>&5 |
| 6464 | ac_status=$? |
| 6465 | echo "$as_me:6465: \$? = $ac_status" >&5 |
| 6466 | (exit $ac_status); }; }; then |
| 6467 | : |
| 6468 | else |
| 6469 | echo "$as_me: failed program was:" >&5 |
| 6470 | cat conftest.$ac_ext >&5 |
| 6471 | cf_have_incdir=yes |
| 6472 | fi |
| 6473 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6474 | CPPFLAGS=$cf_save_CPPFLAGS |
| 6475 | fi |
| 6476 | fi |
| 6477 | fi |
| 6478 | |
| 6479 | if test "$cf_have_incdir" = no ; then |
| 6480 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 6481 | |
| 6482 | echo "${as_me:-configure}:6482: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 6483 | |
| 6484 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 6485 | |
| 6486 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 6487 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 6488 | cf_add_incdir="$cf_top_incdir" |
| 6489 | else |
| 6490 | break |
| 6491 | fi |
| 6492 | else |
| 6493 | break |
| 6494 | fi |
| 6495 | done |
| 6496 | done |
| 6497 | fi |
| 6498 | |
| 6499 | } |
| 6500 | |
| 6501 | echo "$as_me:6501: checking for $cf_ncuhdr_root header in include-path" >&5 |
| 6502 | echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6 |
| 6503 | if test "${cf_cv_ncurses_h+set}" = set; then |
| 6504 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6505 | else |
| 6506 | |
| 6507 | cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h" |
| 6508 | ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h" |
| 6509 | for cf_header in $cf_header_list |
| 6510 | do |
| 6511 | |
| 6512 | cat >conftest.$ac_ext <<_ACEOF |
| 6513 | #line 6513 "configure" |
| 6514 | #include "confdefs.h" |
| 6515 | |
| 6516 | #include <$cf_header> |
| 6517 | int |
| 6518 | main () |
| 6519 | { |
| 6520 | |
| 6521 | #ifdef NCURSES_VERSION |
| 6522 | |
| 6523 | printf("%s\n", NCURSES_VERSION); |
| 6524 | #else |
| 6525 | #ifdef __NCURSES_H |
| 6526 | printf("old\n"); |
| 6527 | #else |
| 6528 | make an error |
| 6529 | #endif |
| 6530 | #endif |
| 6531 | |
| 6532 | ; |
| 6533 | return 0; |
| 6534 | } |
| 6535 | _ACEOF |
| 6536 | rm -f conftest.$ac_objext |
| 6537 | if { (eval echo "$as_me:6537: \"$ac_compile\"") >&5 |
| 6538 | (eval $ac_compile) 2>&5 |
| 6539 | ac_status=$? |
| 6540 | echo "$as_me:6540: \$? = $ac_status" >&5 |
| 6541 | (exit $ac_status); } && |
| 6542 | { ac_try='test -s conftest.$ac_objext' |
| 6543 | { (eval echo "$as_me:6543: \"$ac_try\"") >&5 |
| 6544 | (eval $ac_try) 2>&5 |
| 6545 | ac_status=$? |
| 6546 | echo "$as_me:6546: \$? = $ac_status" >&5 |
| 6547 | (exit $ac_status); }; }; then |
| 6548 | cf_cv_ncurses_h=$cf_header |
| 6549 | |
| 6550 | else |
| 6551 | echo "$as_me: failed program was:" >&5 |
| 6552 | cat conftest.$ac_ext >&5 |
| 6553 | cf_cv_ncurses_h=no |
| 6554 | fi |
| 6555 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6556 | |
| 6557 | test "$cf_cv_ncurses_h" != no && break |
| 6558 | done |
| 6559 | |
| 6560 | fi |
| 6561 | echo "$as_me:6561: result: $cf_cv_ncurses_h" >&5 |
| 6562 | echo "${ECHO_T}$cf_cv_ncurses_h" >&6 |
| 6563 | |
| 6564 | if test "$cf_cv_ncurses_h" != no ; then |
| 6565 | cf_cv_ncurses_header=$cf_cv_ncurses_h |
| 6566 | else |
| 6567 | |
| 6568 | echo "$as_me:6568: checking for $cf_ncuhdr_root include-path" >&5 |
| 6569 | echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6 |
| 6570 | if test "${cf_cv_ncurses_h2+set}" = set; then |
| 6571 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6572 | else |
| 6573 | |
| 6574 | test -n "$verbose" && echo |
| 6575 | |
| 6576 | cf_search= |
| 6577 | |
| 6578 | # collect the current set of include-directories from compiler flags |
| 6579 | cf_header_path_list="" |
| 6580 | if test -n "${CFLAGS}${CPPFLAGS}" ; then |
| 6581 | for cf_header_path in $CPPFLAGS $CFLAGS |
| 6582 | do |
| 6583 | case $cf_header_path in |
| 6584 | (-I*) |
| 6585 | cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'` |
| 6586 | |
| 6587 | test "x$cf_header_path" != "xNONE" && \ |
| 6588 | test -d "$cf_header_path" && \ |
| 6589 | { |
| 6590 | test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path" |
| 6591 | test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include" |
| 6592 | test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root" |
| 6593 | test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include" |
| 6594 | test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include" |
| 6595 | test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root" |
| 6596 | } |
| 6597 | |
| 6598 | cf_header_path_list="$cf_header_path_list $cf_search" |
| 6599 | ;; |
| 6600 | esac |
| 6601 | done |
| 6602 | fi |
| 6603 | |
| 6604 | # add the variations for the package we are looking for |
| 6605 | |
| 6606 | cf_search= |
| 6607 | |
| 6608 | test "x$prefix" != "xNONE" && \ |
| 6609 | test -d "$prefix" && \ |
| 6610 | { |
| 6611 | test -n "$verbose" && echo " ... testing for include-directories under $prefix" |
| 6612 | test -d $prefix/include && cf_search="$cf_search $prefix/include" |
| 6613 | test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root" |
| 6614 | test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include" |
| 6615 | test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include" |
| 6616 | test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" |
| 6617 | } |
| 6618 | |
| 6619 | for cf_subdir_prefix in \ |
| 6620 | /usr \ |
| 6621 | /usr/local \ |
| 6622 | /usr/pkg \ |
| 6623 | /opt \ |
| 6624 | /opt/local \ |
| 6625 | $HOME |
| 6626 | do |
| 6627 | |
| 6628 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 6629 | test -d "$cf_subdir_prefix" && \ |
| 6630 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 6631 | test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix" |
| 6632 | test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include" |
| 6633 | test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root" |
| 6634 | test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include" |
| 6635 | test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include" |
| 6636 | test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" |
| 6637 | } |
| 6638 | |
| 6639 | done |
| 6640 | |
| 6641 | test "$includedir" != NONE && \ |
| 6642 | test "$includedir" != "/usr/include" && \ |
| 6643 | test -d "$includedir" && { |
| 6644 | test -d $includedir && cf_search="$cf_search $includedir" |
| 6645 | test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root" |
| 6646 | } |
| 6647 | |
| 6648 | test "$oldincludedir" != NONE && \ |
| 6649 | test "$oldincludedir" != "/usr/include" && \ |
| 6650 | test -d "$oldincludedir" && { |
| 6651 | test -d $oldincludedir && cf_search="$cf_search $oldincludedir" |
| 6652 | test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root" |
| 6653 | } |
| 6654 | |
| 6655 | cf_search="$cf_search $cf_header_path_list" |
| 6656 | |
| 6657 | test -n "$verbose" && echo search path $cf_search |
| 6658 | cf_save2_CPPFLAGS="$CPPFLAGS" |
| 6659 | for cf_incdir in $cf_search |
| 6660 | do |
| 6661 | |
| 6662 | if test -n "$cf_incdir" ; then |
| 6663 | for cf_add_incdir in $cf_incdir |
| 6664 | do |
| 6665 | while test $cf_add_incdir != /usr/include |
| 6666 | do |
| 6667 | if test -d $cf_add_incdir |
| 6668 | then |
| 6669 | cf_have_incdir=no |
| 6670 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 6671 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 6672 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 6673 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 6674 | cf_have_incdir=yes; break |
| 6675 | fi |
| 6676 | done |
| 6677 | fi |
| 6678 | |
| 6679 | if test "$cf_have_incdir" = no ; then |
| 6680 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 6681 | if test "$GCC" = yes |
| 6682 | then |
| 6683 | cf_save_CPPFLAGS=$CPPFLAGS |
| 6684 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 6685 | cat >conftest.$ac_ext <<_ACEOF |
| 6686 | #line 6686 "configure" |
| 6687 | #include "confdefs.h" |
| 6688 | #include <stdio.h> |
| 6689 | int |
| 6690 | main () |
| 6691 | { |
| 6692 | printf("Hello") |
| 6693 | ; |
| 6694 | return 0; |
| 6695 | } |
| 6696 | _ACEOF |
| 6697 | rm -f conftest.$ac_objext |
| 6698 | if { (eval echo "$as_me:6698: \"$ac_compile\"") >&5 |
| 6699 | (eval $ac_compile) 2>&5 |
| 6700 | ac_status=$? |
| 6701 | echo "$as_me:6701: \$? = $ac_status" >&5 |
| 6702 | (exit $ac_status); } && |
| 6703 | { ac_try='test -s conftest.$ac_objext' |
| 6704 | { (eval echo "$as_me:6704: \"$ac_try\"") >&5 |
| 6705 | (eval $ac_try) 2>&5 |
| 6706 | ac_status=$? |
| 6707 | echo "$as_me:6707: \$? = $ac_status" >&5 |
| 6708 | (exit $ac_status); }; }; then |
| 6709 | : |
| 6710 | else |
| 6711 | echo "$as_me: failed program was:" >&5 |
| 6712 | cat conftest.$ac_ext >&5 |
| 6713 | cf_have_incdir=yes |
| 6714 | fi |
| 6715 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6716 | CPPFLAGS=$cf_save_CPPFLAGS |
| 6717 | fi |
| 6718 | fi |
| 6719 | fi |
| 6720 | |
| 6721 | if test "$cf_have_incdir" = no ; then |
| 6722 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 6723 | |
| 6724 | echo "${as_me:-configure}:6724: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 6725 | |
| 6726 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 6727 | |
| 6728 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 6729 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 6730 | cf_add_incdir="$cf_top_incdir" |
| 6731 | else |
| 6732 | break |
| 6733 | fi |
| 6734 | else |
| 6735 | break |
| 6736 | fi |
| 6737 | done |
| 6738 | done |
| 6739 | fi |
| 6740 | |
| 6741 | for cf_header in \ |
| 6742 | ncurses.h \ |
| 6743 | curses.h |
| 6744 | do |
| 6745 | |
| 6746 | cat >conftest.$ac_ext <<_ACEOF |
| 6747 | #line 6747 "configure" |
| 6748 | #include "confdefs.h" |
| 6749 | |
| 6750 | #include <$cf_header> |
| 6751 | int |
| 6752 | main () |
| 6753 | { |
| 6754 | |
| 6755 | #ifdef NCURSES_VERSION |
| 6756 | |
| 6757 | printf("%s\n", NCURSES_VERSION); |
| 6758 | #else |
| 6759 | #ifdef __NCURSES_H |
| 6760 | printf("old\n"); |
| 6761 | #else |
| 6762 | make an error |
| 6763 | #endif |
| 6764 | #endif |
| 6765 | |
| 6766 | ; |
| 6767 | return 0; |
| 6768 | } |
| 6769 | _ACEOF |
| 6770 | rm -f conftest.$ac_objext |
| 6771 | if { (eval echo "$as_me:6771: \"$ac_compile\"") >&5 |
| 6772 | (eval $ac_compile) 2>&5 |
| 6773 | ac_status=$? |
| 6774 | echo "$as_me:6774: \$? = $ac_status" >&5 |
| 6775 | (exit $ac_status); } && |
| 6776 | { ac_try='test -s conftest.$ac_objext' |
| 6777 | { (eval echo "$as_me:6777: \"$ac_try\"") >&5 |
| 6778 | (eval $ac_try) 2>&5 |
| 6779 | ac_status=$? |
| 6780 | echo "$as_me:6780: \$? = $ac_status" >&5 |
| 6781 | (exit $ac_status); }; }; then |
| 6782 | cf_cv_ncurses_h2=$cf_header |
| 6783 | |
| 6784 | else |
| 6785 | echo "$as_me: failed program was:" >&5 |
| 6786 | cat conftest.$ac_ext >&5 |
| 6787 | cf_cv_ncurses_h2=no |
| 6788 | fi |
| 6789 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6790 | |
| 6791 | if test "$cf_cv_ncurses_h2" != no ; then |
| 6792 | cf_cv_ncurses_h2=$cf_incdir/$cf_header |
| 6793 | test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6 |
| 6794 | break |
| 6795 | fi |
| 6796 | test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6 |
| 6797 | done |
| 6798 | CPPFLAGS="$cf_save2_CPPFLAGS" |
| 6799 | test "$cf_cv_ncurses_h2" != no && break |
| 6800 | done |
| 6801 | test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:6801: error: not found" >&5 |
| 6802 | echo "$as_me: error: not found" >&2;} |
| 6803 | { (exit 1); exit 1; }; } |
| 6804 | |
| 6805 | fi |
| 6806 | echo "$as_me:6806: result: $cf_cv_ncurses_h2" >&5 |
| 6807 | echo "${ECHO_T}$cf_cv_ncurses_h2" >&6 |
| 6808 | |
| 6809 | cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'` |
| 6810 | cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2` |
| 6811 | if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then |
| 6812 | cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header |
| 6813 | fi |
| 6814 | |
| 6815 | if test -n "$cf_1st_incdir" ; then |
| 6816 | for cf_add_incdir in $cf_1st_incdir |
| 6817 | do |
| 6818 | while test $cf_add_incdir != /usr/include |
| 6819 | do |
| 6820 | if test -d $cf_add_incdir |
| 6821 | then |
| 6822 | cf_have_incdir=no |
| 6823 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 6824 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 6825 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 6826 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 6827 | cf_have_incdir=yes; break |
| 6828 | fi |
| 6829 | done |
| 6830 | fi |
| 6831 | |
| 6832 | if test "$cf_have_incdir" = no ; then |
| 6833 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 6834 | if test "$GCC" = yes |
| 6835 | then |
| 6836 | cf_save_CPPFLAGS=$CPPFLAGS |
| 6837 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 6838 | cat >conftest.$ac_ext <<_ACEOF |
| 6839 | #line 6839 "configure" |
| 6840 | #include "confdefs.h" |
| 6841 | #include <stdio.h> |
| 6842 | int |
| 6843 | main () |
| 6844 | { |
| 6845 | printf("Hello") |
| 6846 | ; |
| 6847 | return 0; |
| 6848 | } |
| 6849 | _ACEOF |
| 6850 | rm -f conftest.$ac_objext |
| 6851 | if { (eval echo "$as_me:6851: \"$ac_compile\"") >&5 |
| 6852 | (eval $ac_compile) 2>&5 |
| 6853 | ac_status=$? |
| 6854 | echo "$as_me:6854: \$? = $ac_status" >&5 |
| 6855 | (exit $ac_status); } && |
| 6856 | { ac_try='test -s conftest.$ac_objext' |
| 6857 | { (eval echo "$as_me:6857: \"$ac_try\"") >&5 |
| 6858 | (eval $ac_try) 2>&5 |
| 6859 | ac_status=$? |
| 6860 | echo "$as_me:6860: \$? = $ac_status" >&5 |
| 6861 | (exit $ac_status); }; }; then |
| 6862 | : |
| 6863 | else |
| 6864 | echo "$as_me: failed program was:" >&5 |
| 6865 | cat conftest.$ac_ext >&5 |
| 6866 | cf_have_incdir=yes |
| 6867 | fi |
| 6868 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6869 | CPPFLAGS=$cf_save_CPPFLAGS |
| 6870 | fi |
| 6871 | fi |
| 6872 | fi |
| 6873 | |
| 6874 | if test "$cf_have_incdir" = no ; then |
| 6875 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 6876 | |
| 6877 | echo "${as_me:-configure}:6877: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 6878 | |
| 6879 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 6880 | |
| 6881 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 6882 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 6883 | cf_add_incdir="$cf_top_incdir" |
| 6884 | else |
| 6885 | break |
| 6886 | fi |
| 6887 | else |
| 6888 | break |
| 6889 | fi |
| 6890 | done |
| 6891 | done |
| 6892 | fi |
| 6893 | |
| 6894 | fi |
| 6895 | |
| 6896 | # Set definitions to allow ifdef'ing for ncurses.h |
| 6897 | |
| 6898 | case $cf_cv_ncurses_header in |
| 6899 | (*ncurses.h) |
| 6900 | |
| 6901 | cat >>confdefs.h <<\EOF |
| 6902 | #define HAVE_NCURSES_H 1 |
| 6903 | EOF |
| 6904 | |
| 6905 | ;; |
| 6906 | esac |
| 6907 | |
| 6908 | case $cf_cv_ncurses_header in |
| 6909 | (ncurses/curses.h|ncurses/ncurses.h) |
| 6910 | |
| 6911 | cat >>confdefs.h <<\EOF |
| 6912 | #define HAVE_NCURSES_NCURSES_H 1 |
| 6913 | EOF |
| 6914 | |
| 6915 | ;; |
| 6916 | (ncursesw/curses.h|ncursesw/ncurses.h) |
| 6917 | |
| 6918 | cat >>confdefs.h <<\EOF |
| 6919 | #define HAVE_NCURSESW_NCURSES_H 1 |
| 6920 | EOF |
| 6921 | |
| 6922 | ;; |
| 6923 | esac |
| 6924 | |
| 6925 | echo "$as_me:6925: checking for terminfo header" >&5 |
| 6926 | echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6 |
| 6927 | if test "${cf_cv_term_header+set}" = set; then |
| 6928 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6929 | else |
| 6930 | |
| 6931 | case ${cf_cv_ncurses_header} in |
| 6932 | (*/ncurses.h|*/ncursesw.h) |
| 6933 | cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'` |
| 6934 | ;; |
| 6935 | (*) |
| 6936 | cf_term_header=term.h |
| 6937 | ;; |
| 6938 | esac |
| 6939 | |
| 6940 | for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h" |
| 6941 | do |
| 6942 | cat >conftest.$ac_ext <<_ACEOF |
| 6943 | #line 6943 "configure" |
| 6944 | #include "confdefs.h" |
| 6945 | #include <stdio.h> |
| 6946 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 6947 | #include <$cf_test> |
| 6948 | |
| 6949 | int |
| 6950 | main () |
| 6951 | { |
| 6952 | int x = auto_left_margin |
| 6953 | ; |
| 6954 | return 0; |
| 6955 | } |
| 6956 | _ACEOF |
| 6957 | rm -f conftest.$ac_objext |
| 6958 | if { (eval echo "$as_me:6958: \"$ac_compile\"") >&5 |
| 6959 | (eval $ac_compile) 2>&5 |
| 6960 | ac_status=$? |
| 6961 | echo "$as_me:6961: \$? = $ac_status" >&5 |
| 6962 | (exit $ac_status); } && |
| 6963 | { ac_try='test -s conftest.$ac_objext' |
| 6964 | { (eval echo "$as_me:6964: \"$ac_try\"") >&5 |
| 6965 | (eval $ac_try) 2>&5 |
| 6966 | ac_status=$? |
| 6967 | echo "$as_me:6967: \$? = $ac_status" >&5 |
| 6968 | (exit $ac_status); }; }; then |
| 6969 | |
| 6970 | cf_cv_term_header="$cf_test" |
| 6971 | else |
| 6972 | echo "$as_me: failed program was:" >&5 |
| 6973 | cat conftest.$ac_ext >&5 |
| 6974 | |
| 6975 | cf_cv_term_header=unknown |
| 6976 | |
| 6977 | fi |
| 6978 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6979 | test "$cf_cv_term_header" != unknown && break |
| 6980 | done |
| 6981 | |
| 6982 | fi |
| 6983 | echo "$as_me:6983: result: $cf_cv_term_header" >&5 |
| 6984 | echo "${ECHO_T}$cf_cv_term_header" >&6 |
| 6985 | |
| 6986 | # Set definitions to allow ifdef'ing to accommodate subdirectories |
| 6987 | |
| 6988 | case $cf_cv_term_header in |
| 6989 | (*term.h) |
| 6990 | |
| 6991 | cat >>confdefs.h <<\EOF |
| 6992 | #define HAVE_TERM_H 1 |
| 6993 | EOF |
| 6994 | |
| 6995 | ;; |
| 6996 | esac |
| 6997 | |
| 6998 | case $cf_cv_term_header in |
| 6999 | (ncurses/term.h) |
| 7000 | |
| 7001 | cat >>confdefs.h <<\EOF |
| 7002 | #define HAVE_NCURSES_TERM_H 1 |
| 7003 | EOF |
| 7004 | |
| 7005 | ;; |
| 7006 | (ncursesw/term.h) |
| 7007 | |
| 7008 | cat >>confdefs.h <<\EOF |
| 7009 | #define HAVE_NCURSESW_TERM_H 1 |
| 7010 | EOF |
| 7011 | |
| 7012 | ;; |
| 7013 | esac |
| 7014 | |
| 7015 | # some applications need this, but should check for NCURSES_VERSION |
| 7016 | |
| 7017 | cat >>confdefs.h <<\EOF |
| 7018 | #define NCURSES 1 |
| 7019 | EOF |
| 7020 | |
| 7021 | echo "$as_me:7021: checking for ncurses version" >&5 |
| 7022 | echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6 |
| 7023 | if test "${cf_cv_ncurses_version+set}" = set; then |
| 7024 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7025 | else |
| 7026 | |
| 7027 | cf_cv_ncurses_version=no |
| 7028 | cf_tempfile=out$$ |
| 7029 | rm -f $cf_tempfile |
| 7030 | if test "$cross_compiling" = yes; then |
| 7031 | |
| 7032 | # This will not work if the preprocessor splits the line after the |
| 7033 | # Autoconf token. The 'unproto' program does that. |
| 7034 | cat > conftest.$ac_ext <<EOF |
| 7035 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 7036 | #undef Autoconf |
| 7037 | #ifdef NCURSES_VERSION |
| 7038 | Autoconf NCURSES_VERSION |
| 7039 | #else |
| 7040 | #ifdef __NCURSES_H |
| 7041 | Autoconf "old" |
| 7042 | #endif |
| 7043 | ; |
| 7044 | #endif |
| 7045 | EOF |
| 7046 | cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out" |
| 7047 | { (eval echo "$as_me:7047: \"$cf_try\"") >&5 |
| 7048 | (eval $cf_try) 2>&5 |
| 7049 | ac_status=$? |
| 7050 | echo "$as_me:7050: \$? = $ac_status" >&5 |
| 7051 | (exit $ac_status); } |
| 7052 | if test -f conftest.out ; then |
| 7053 | cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'` |
| 7054 | test -n "$cf_out" && cf_cv_ncurses_version="$cf_out" |
| 7055 | rm -f conftest.out |
| 7056 | fi |
| 7057 | |
| 7058 | else |
| 7059 | cat >conftest.$ac_ext <<_ACEOF |
| 7060 | #line 7060 "configure" |
| 7061 | #include "confdefs.h" |
| 7062 | |
| 7063 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 7064 | #include <stdio.h> |
| 7065 | int main() |
| 7066 | { |
| 7067 | FILE *fp = fopen("$cf_tempfile", "w"); |
| 7068 | #ifdef NCURSES_VERSION |
| 7069 | # ifdef NCURSES_VERSION_PATCH |
| 7070 | fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH); |
| 7071 | # else |
| 7072 | fprintf(fp, "%s\n", NCURSES_VERSION); |
| 7073 | # endif |
| 7074 | #else |
| 7075 | # ifdef __NCURSES_H |
| 7076 | fprintf(fp, "old\n"); |
| 7077 | # else |
| 7078 | make an error |
| 7079 | # endif |
| 7080 | #endif |
| 7081 | ${cf_cv_main_return:-return}(0); |
| 7082 | } |
| 7083 | _ACEOF |
| 7084 | rm -f conftest$ac_exeext |
| 7085 | if { (eval echo "$as_me:7085: \"$ac_link\"") >&5 |
| 7086 | (eval $ac_link) 2>&5 |
| 7087 | ac_status=$? |
| 7088 | echo "$as_me:7088: \$? = $ac_status" >&5 |
| 7089 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 7090 | { (eval echo "$as_me:7090: \"$ac_try\"") >&5 |
| 7091 | (eval $ac_try) 2>&5 |
| 7092 | ac_status=$? |
| 7093 | echo "$as_me:7093: \$? = $ac_status" >&5 |
| 7094 | (exit $ac_status); }; }; then |
| 7095 | |
| 7096 | cf_cv_ncurses_version=`cat $cf_tempfile` |
| 7097 | else |
| 7098 | echo "$as_me: program exited with status $ac_status" >&5 |
| 7099 | echo "$as_me: failed program was:" >&5 |
| 7100 | cat conftest.$ac_ext >&5 |
| 7101 | fi |
| 7102 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 7103 | fi |
| 7104 | rm -f $cf_tempfile |
| 7105 | |
| 7106 | fi |
| 7107 | echo "$as_me:7107: result: $cf_cv_ncurses_version" >&5 |
| 7108 | echo "${ECHO_T}$cf_cv_ncurses_version" >&6 |
| 7109 | test "$cf_cv_ncurses_version" = no || |
| 7110 | cat >>confdefs.h <<\EOF |
| 7111 | #define NCURSES 1 |
| 7112 | EOF |
| 7113 | |
| 7114 | cf_nculib_root=$cf_cv_screen |
| 7115 | # This works, except for the special case where we find gpm, but |
| 7116 | # ncurses is in a nonstandard location via $LIBS, and we really want |
| 7117 | # to link gpm. |
| 7118 | cf_ncurses_LIBS="" |
| 7119 | cf_ncurses_SAVE="$LIBS" |
| 7120 | echo "$as_me:7120: checking for Gpm_Open in -lgpm" >&5 |
| 7121 | echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6 |
| 7122 | if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then |
| 7123 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7124 | else |
| 7125 | ac_check_lib_save_LIBS=$LIBS |
| 7126 | LIBS="-lgpm $LIBS" |
| 7127 | cat >conftest.$ac_ext <<_ACEOF |
| 7128 | #line 7128 "configure" |
| 7129 | #include "confdefs.h" |
| 7130 | |
| 7131 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 7132 | #ifdef __cplusplus |
| 7133 | extern "C" |
| 7134 | #endif |
| 7135 | /* We use char because int might match the return type of a gcc2 |
| 7136 | builtin and then its argument prototype would still apply. */ |
| 7137 | char Gpm_Open (); |
| 7138 | int |
| 7139 | main () |
| 7140 | { |
| 7141 | Gpm_Open (); |
| 7142 | ; |
| 7143 | return 0; |
| 7144 | } |
| 7145 | _ACEOF |
| 7146 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7147 | if { (eval echo "$as_me:7147: \"$ac_link\"") >&5 |
| 7148 | (eval $ac_link) 2>&5 |
| 7149 | ac_status=$? |
| 7150 | echo "$as_me:7150: \$? = $ac_status" >&5 |
| 7151 | (exit $ac_status); } && |
| 7152 | { ac_try='test -s conftest$ac_exeext' |
| 7153 | { (eval echo "$as_me:7153: \"$ac_try\"") >&5 |
| 7154 | (eval $ac_try) 2>&5 |
| 7155 | ac_status=$? |
| 7156 | echo "$as_me:7156: \$? = $ac_status" >&5 |
| 7157 | (exit $ac_status); }; }; then |
| 7158 | ac_cv_lib_gpm_Gpm_Open=yes |
| 7159 | else |
| 7160 | echo "$as_me: failed program was:" >&5 |
| 7161 | cat conftest.$ac_ext >&5 |
| 7162 | ac_cv_lib_gpm_Gpm_Open=no |
| 7163 | fi |
| 7164 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7165 | LIBS=$ac_check_lib_save_LIBS |
| 7166 | fi |
| 7167 | echo "$as_me:7167: result: $ac_cv_lib_gpm_Gpm_Open" >&5 |
| 7168 | echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6 |
| 7169 | if test $ac_cv_lib_gpm_Gpm_Open = yes; then |
| 7170 | echo "$as_me:7170: checking for initscr in -lgpm" >&5 |
| 7171 | echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6 |
| 7172 | if test "${ac_cv_lib_gpm_initscr+set}" = set; then |
| 7173 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7174 | else |
| 7175 | ac_check_lib_save_LIBS=$LIBS |
| 7176 | LIBS="-lgpm $LIBS" |
| 7177 | cat >conftest.$ac_ext <<_ACEOF |
| 7178 | #line 7178 "configure" |
| 7179 | #include "confdefs.h" |
| 7180 | |
| 7181 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 7182 | #ifdef __cplusplus |
| 7183 | extern "C" |
| 7184 | #endif |
| 7185 | /* We use char because int might match the return type of a gcc2 |
| 7186 | builtin and then its argument prototype would still apply. */ |
| 7187 | char initscr (); |
| 7188 | int |
| 7189 | main () |
| 7190 | { |
| 7191 | initscr (); |
| 7192 | ; |
| 7193 | return 0; |
| 7194 | } |
| 7195 | _ACEOF |
| 7196 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7197 | if { (eval echo "$as_me:7197: \"$ac_link\"") >&5 |
| 7198 | (eval $ac_link) 2>&5 |
| 7199 | ac_status=$? |
| 7200 | echo "$as_me:7200: \$? = $ac_status" >&5 |
| 7201 | (exit $ac_status); } && |
| 7202 | { ac_try='test -s conftest$ac_exeext' |
| 7203 | { (eval echo "$as_me:7203: \"$ac_try\"") >&5 |
| 7204 | (eval $ac_try) 2>&5 |
| 7205 | ac_status=$? |
| 7206 | echo "$as_me:7206: \$? = $ac_status" >&5 |
| 7207 | (exit $ac_status); }; }; then |
| 7208 | ac_cv_lib_gpm_initscr=yes |
| 7209 | else |
| 7210 | echo "$as_me: failed program was:" >&5 |
| 7211 | cat conftest.$ac_ext >&5 |
| 7212 | ac_cv_lib_gpm_initscr=no |
| 7213 | fi |
| 7214 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7215 | LIBS=$ac_check_lib_save_LIBS |
| 7216 | fi |
| 7217 | echo "$as_me:7217: result: $ac_cv_lib_gpm_initscr" >&5 |
| 7218 | echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6 |
| 7219 | if test $ac_cv_lib_gpm_initscr = yes; then |
| 7220 | LIBS="$cf_ncurses_SAVE" |
| 7221 | else |
| 7222 | cf_ncurses_LIBS="-lgpm" |
| 7223 | fi |
| 7224 | |
| 7225 | fi |
| 7226 | |
| 7227 | case $host_os in |
| 7228 | (freebsd*) |
| 7229 | # This is only necessary if you are linking against an obsolete |
| 7230 | # version of ncurses (but it should do no harm, since it's static). |
| 7231 | if test "$cf_nculib_root" = ncurses ; then |
| 7232 | echo "$as_me:7232: checking for tgoto in -lmytinfo" >&5 |
| 7233 | echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6 |
| 7234 | if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then |
| 7235 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7236 | else |
| 7237 | ac_check_lib_save_LIBS=$LIBS |
| 7238 | LIBS="-lmytinfo $LIBS" |
| 7239 | cat >conftest.$ac_ext <<_ACEOF |
| 7240 | #line 7240 "configure" |
| 7241 | #include "confdefs.h" |
| 7242 | |
| 7243 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 7244 | #ifdef __cplusplus |
| 7245 | extern "C" |
| 7246 | #endif |
| 7247 | /* We use char because int might match the return type of a gcc2 |
| 7248 | builtin and then its argument prototype would still apply. */ |
| 7249 | char tgoto (); |
| 7250 | int |
| 7251 | main () |
| 7252 | { |
| 7253 | tgoto (); |
| 7254 | ; |
| 7255 | return 0; |
| 7256 | } |
| 7257 | _ACEOF |
| 7258 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7259 | if { (eval echo "$as_me:7259: \"$ac_link\"") >&5 |
| 7260 | (eval $ac_link) 2>&5 |
| 7261 | ac_status=$? |
| 7262 | echo "$as_me:7262: \$? = $ac_status" >&5 |
| 7263 | (exit $ac_status); } && |
| 7264 | { ac_try='test -s conftest$ac_exeext' |
| 7265 | { (eval echo "$as_me:7265: \"$ac_try\"") >&5 |
| 7266 | (eval $ac_try) 2>&5 |
| 7267 | ac_status=$? |
| 7268 | echo "$as_me:7268: \$? = $ac_status" >&5 |
| 7269 | (exit $ac_status); }; }; then |
| 7270 | ac_cv_lib_mytinfo_tgoto=yes |
| 7271 | else |
| 7272 | echo "$as_me: failed program was:" >&5 |
| 7273 | cat conftest.$ac_ext >&5 |
| 7274 | ac_cv_lib_mytinfo_tgoto=no |
| 7275 | fi |
| 7276 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7277 | LIBS=$ac_check_lib_save_LIBS |
| 7278 | fi |
| 7279 | echo "$as_me:7279: result: $ac_cv_lib_mytinfo_tgoto" >&5 |
| 7280 | echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6 |
| 7281 | if test $ac_cv_lib_mytinfo_tgoto = yes; then |
| 7282 | cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS" |
| 7283 | fi |
| 7284 | |
| 7285 | fi |
| 7286 | ;; |
| 7287 | esac |
| 7288 | |
| 7289 | cf_add_libs="$cf_ncurses_LIBS" |
| 7290 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 7291 | for cf_add_1lib in $LIBS |
| 7292 | do |
| 7293 | for cf_add_2lib in $cf_add_libs |
| 7294 | do |
| 7295 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 7296 | then |
| 7297 | cf_add_1lib= |
| 7298 | break |
| 7299 | fi |
| 7300 | done |
| 7301 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 7302 | done |
| 7303 | LIBS="$cf_add_libs" |
| 7304 | |
| 7305 | if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" ) |
| 7306 | then |
| 7307 | |
| 7308 | cf_add_libs="-l$cf_nculib_root" |
| 7309 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 7310 | for cf_add_1lib in $LIBS |
| 7311 | do |
| 7312 | for cf_add_2lib in $cf_add_libs |
| 7313 | do |
| 7314 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 7315 | then |
| 7316 | cf_add_1lib= |
| 7317 | break |
| 7318 | fi |
| 7319 | done |
| 7320 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 7321 | done |
| 7322 | LIBS="$cf_add_libs" |
| 7323 | |
| 7324 | else |
| 7325 | |
| 7326 | eval 'cf_cv_have_lib_'$cf_nculib_root'=no' |
| 7327 | cf_libdir="" |
| 7328 | echo "$as_me:7328: checking for initscr" >&5 |
| 7329 | echo $ECHO_N "checking for initscr... $ECHO_C" >&6 |
| 7330 | if test "${ac_cv_func_initscr+set}" = set; then |
| 7331 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7332 | else |
| 7333 | cat >conftest.$ac_ext <<_ACEOF |
| 7334 | #line 7334 "configure" |
| 7335 | #include "confdefs.h" |
| 7336 | /* System header to define __stub macros and hopefully few prototypes, |
| 7337 | which can conflict with char initscr (); below. */ |
| 7338 | #include <assert.h> |
| 7339 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 7340 | #ifdef __cplusplus |
| 7341 | extern "C" |
| 7342 | #endif |
| 7343 | /* We use char because int might match the return type of a gcc2 |
| 7344 | builtin and then its argument prototype would still apply. */ |
| 7345 | char initscr (); |
| 7346 | char (*f) (); |
| 7347 | |
| 7348 | int |
| 7349 | main () |
| 7350 | { |
| 7351 | /* The GNU C library defines this for functions which it implements |
| 7352 | to always fail with ENOSYS. Some functions are actually named |
| 7353 | something starting with __ and the normal name is an alias. */ |
| 7354 | #if defined (__stub_initscr) || defined (__stub___initscr) |
| 7355 | choke me |
| 7356 | #else |
| 7357 | f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 7358 | #endif |
| 7359 | |
| 7360 | ; |
| 7361 | return 0; |
| 7362 | } |
| 7363 | _ACEOF |
| 7364 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7365 | if { (eval echo "$as_me:7365: \"$ac_link\"") >&5 |
| 7366 | (eval $ac_link) 2>&5 |
| 7367 | ac_status=$? |
| 7368 | echo "$as_me:7368: \$? = $ac_status" >&5 |
| 7369 | (exit $ac_status); } && |
| 7370 | { ac_try='test -s conftest$ac_exeext' |
| 7371 | { (eval echo "$as_me:7371: \"$ac_try\"") >&5 |
| 7372 | (eval $ac_try) 2>&5 |
| 7373 | ac_status=$? |
| 7374 | echo "$as_me:7374: \$? = $ac_status" >&5 |
| 7375 | (exit $ac_status); }; }; then |
| 7376 | ac_cv_func_initscr=yes |
| 7377 | else |
| 7378 | echo "$as_me: failed program was:" >&5 |
| 7379 | cat conftest.$ac_ext >&5 |
| 7380 | ac_cv_func_initscr=no |
| 7381 | fi |
| 7382 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7383 | fi |
| 7384 | echo "$as_me:7384: result: $ac_cv_func_initscr" >&5 |
| 7385 | echo "${ECHO_T}$ac_cv_func_initscr" >&6 |
| 7386 | if test $ac_cv_func_initscr = yes; then |
| 7387 | eval 'cf_cv_have_lib_'$cf_nculib_root'=yes' |
| 7388 | else |
| 7389 | |
| 7390 | cf_save_LIBS="$LIBS" |
| 7391 | echo "$as_me:7391: checking for initscr in -l$cf_nculib_root" >&5 |
| 7392 | echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6 |
| 7393 | LIBS="-l$cf_nculib_root $LIBS" |
| 7394 | cat >conftest.$ac_ext <<_ACEOF |
| 7395 | #line 7395 "configure" |
| 7396 | #include "confdefs.h" |
| 7397 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 7398 | int |
| 7399 | main () |
| 7400 | { |
| 7401 | initscr() |
| 7402 | ; |
| 7403 | return 0; |
| 7404 | } |
| 7405 | _ACEOF |
| 7406 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7407 | if { (eval echo "$as_me:7407: \"$ac_link\"") >&5 |
| 7408 | (eval $ac_link) 2>&5 |
| 7409 | ac_status=$? |
| 7410 | echo "$as_me:7410: \$? = $ac_status" >&5 |
| 7411 | (exit $ac_status); } && |
| 7412 | { ac_try='test -s conftest$ac_exeext' |
| 7413 | { (eval echo "$as_me:7413: \"$ac_try\"") >&5 |
| 7414 | (eval $ac_try) 2>&5 |
| 7415 | ac_status=$? |
| 7416 | echo "$as_me:7416: \$? = $ac_status" >&5 |
| 7417 | (exit $ac_status); }; }; then |
| 7418 | echo "$as_me:7418: result: yes" >&5 |
| 7419 | echo "${ECHO_T}yes" >&6 |
| 7420 | eval 'cf_cv_have_lib_'$cf_nculib_root'=yes' |
| 7421 | |
| 7422 | else |
| 7423 | echo "$as_me: failed program was:" >&5 |
| 7424 | cat conftest.$ac_ext >&5 |
| 7425 | echo "$as_me:7425: result: no" >&5 |
| 7426 | echo "${ECHO_T}no" >&6 |
| 7427 | |
| 7428 | cf_search= |
| 7429 | cf_library_path_list="" |
| 7430 | if test -n "${LDFLAGS}${LIBS}" ; then |
| 7431 | for cf_library_path in $LDFLAGS $LIBS |
| 7432 | do |
| 7433 | case $cf_library_path in |
| 7434 | (-L*) |
| 7435 | cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'` |
| 7436 | |
| 7437 | test "x$cf_library_path" != "xNONE" && \ |
| 7438 | test -d "$cf_library_path" && \ |
| 7439 | { |
| 7440 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path" |
| 7441 | test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib" |
| 7442 | test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root" |
| 7443 | test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib" |
| 7444 | test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib" |
| 7445 | test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root" |
| 7446 | } |
| 7447 | |
| 7448 | cf_library_path_list="$cf_library_path_list $cf_search" |
| 7449 | ;; |
| 7450 | esac |
| 7451 | done |
| 7452 | fi |
| 7453 | |
| 7454 | cf_search= |
| 7455 | |
| 7456 | test "x$prefix" != "xNONE" && \ |
| 7457 | test -d "$prefix" && \ |
| 7458 | { |
| 7459 | test -n "$verbose" && echo " ... testing for lib-directories under $prefix" |
| 7460 | test -d $prefix/lib && cf_search="$cf_search $prefix/lib" |
| 7461 | test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root" |
| 7462 | test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib" |
| 7463 | test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib" |
| 7464 | test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root" |
| 7465 | } |
| 7466 | |
| 7467 | for cf_subdir_prefix in \ |
| 7468 | /usr \ |
| 7469 | /usr/local \ |
| 7470 | /usr/pkg \ |
| 7471 | /opt \ |
| 7472 | /opt/local \ |
| 7473 | $HOME |
| 7474 | do |
| 7475 | |
| 7476 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 7477 | test -d "$cf_subdir_prefix" && \ |
| 7478 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 7479 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix" |
| 7480 | test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib" |
| 7481 | test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root" |
| 7482 | test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib" |
| 7483 | test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib" |
| 7484 | test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root" |
| 7485 | } |
| 7486 | |
| 7487 | done |
| 7488 | |
| 7489 | cf_search="$cf_library_path_list $cf_search" |
| 7490 | |
| 7491 | for cf_libdir in $cf_search |
| 7492 | do |
| 7493 | echo "$as_me:7493: checking for -l$cf_nculib_root in $cf_libdir" >&5 |
| 7494 | echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6 |
| 7495 | LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS" |
| 7496 | cat >conftest.$ac_ext <<_ACEOF |
| 7497 | #line 7497 "configure" |
| 7498 | #include "confdefs.h" |
| 7499 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 7500 | int |
| 7501 | main () |
| 7502 | { |
| 7503 | initscr() |
| 7504 | ; |
| 7505 | return 0; |
| 7506 | } |
| 7507 | _ACEOF |
| 7508 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7509 | if { (eval echo "$as_me:7509: \"$ac_link\"") >&5 |
| 7510 | (eval $ac_link) 2>&5 |
| 7511 | ac_status=$? |
| 7512 | echo "$as_me:7512: \$? = $ac_status" >&5 |
| 7513 | (exit $ac_status); } && |
| 7514 | { ac_try='test -s conftest$ac_exeext' |
| 7515 | { (eval echo "$as_me:7515: \"$ac_try\"") >&5 |
| 7516 | (eval $ac_try) 2>&5 |
| 7517 | ac_status=$? |
| 7518 | echo "$as_me:7518: \$? = $ac_status" >&5 |
| 7519 | (exit $ac_status); }; }; then |
| 7520 | echo "$as_me:7520: result: yes" >&5 |
| 7521 | echo "${ECHO_T}yes" >&6 |
| 7522 | eval 'cf_cv_have_lib_'$cf_nculib_root'=yes' |
| 7523 | break |
| 7524 | else |
| 7525 | echo "$as_me: failed program was:" >&5 |
| 7526 | cat conftest.$ac_ext >&5 |
| 7527 | echo "$as_me:7527: result: no" >&5 |
| 7528 | echo "${ECHO_T}no" >&6 |
| 7529 | LIBS="$cf_save_LIBS" |
| 7530 | fi |
| 7531 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7532 | done |
| 7533 | |
| 7534 | fi |
| 7535 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7536 | |
| 7537 | fi |
| 7538 | |
| 7539 | eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root |
| 7540 | |
| 7541 | if test $cf_found_library = no ; then |
| 7542 | { { echo "$as_me:7542: error: Cannot link $cf_nculib_root library" >&5 |
| 7543 | echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;} |
| 7544 | { (exit 1); exit 1; }; } |
| 7545 | fi |
| 7546 | |
| 7547 | fi |
| 7548 | |
| 7549 | if test -n "$cf_ncurses_LIBS" ; then |
| 7550 | echo "$as_me:7550: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5 |
| 7551 | echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6 |
| 7552 | cf_ncurses_SAVE="$LIBS" |
| 7553 | for p in $cf_ncurses_LIBS ; do |
| 7554 | q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"` |
| 7555 | if test "$q" != "$LIBS" ; then |
| 7556 | LIBS="$q" |
| 7557 | fi |
| 7558 | done |
| 7559 | cat >conftest.$ac_ext <<_ACEOF |
| 7560 | #line 7560 "configure" |
| 7561 | #include "confdefs.h" |
| 7562 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 7563 | int |
| 7564 | main () |
| 7565 | { |
| 7566 | initscr(); mousemask(0,0); tgoto((char *)0, 0, 0); |
| 7567 | ; |
| 7568 | return 0; |
| 7569 | } |
| 7570 | _ACEOF |
| 7571 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7572 | if { (eval echo "$as_me:7572: \"$ac_link\"") >&5 |
| 7573 | (eval $ac_link) 2>&5 |
| 7574 | ac_status=$? |
| 7575 | echo "$as_me:7575: \$? = $ac_status" >&5 |
| 7576 | (exit $ac_status); } && |
| 7577 | { ac_try='test -s conftest$ac_exeext' |
| 7578 | { (eval echo "$as_me:7578: \"$ac_try\"") >&5 |
| 7579 | (eval $ac_try) 2>&5 |
| 7580 | ac_status=$? |
| 7581 | echo "$as_me:7581: \$? = $ac_status" >&5 |
| 7582 | (exit $ac_status); }; }; then |
| 7583 | echo "$as_me:7583: result: yes" >&5 |
| 7584 | echo "${ECHO_T}yes" >&6 |
| 7585 | else |
| 7586 | echo "$as_me: failed program was:" >&5 |
| 7587 | cat conftest.$ac_ext >&5 |
| 7588 | echo "$as_me:7588: result: no" >&5 |
| 7589 | echo "${ECHO_T}no" >&6 |
| 7590 | LIBS="$cf_ncurses_SAVE" |
| 7591 | fi |
| 7592 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7593 | fi |
| 7594 | |
| 7595 | cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 7596 | |
| 7597 | cat >>confdefs.h <<EOF |
| 7598 | #define $cf_nculib_ROOT 1 |
| 7599 | EOF |
| 7600 | |
| 7601 | fi |
| 7602 | else |
| 7603 | NCURSES_CONFIG=none |
| 7604 | fi |
| 7605 | |
| 7606 | ;; |
| 7607 | (ncurses*) |
| 7608 | |
| 7609 | cf_ncuconfig_root=$cf_cv_screen |
| 7610 | cf_have_ncuconfig=no |
| 7611 | |
| 7612 | if test "x${PKG_CONFIG:=none}" != xnone; then |
| 7613 | echo "$as_me:7613: checking pkg-config for $cf_ncuconfig_root" >&5 |
| 7614 | echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6 |
| 7615 | if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then |
| 7616 | echo "$as_me:7616: result: yes" >&5 |
| 7617 | echo "${ECHO_T}yes" >&6 |
| 7618 | |
| 7619 | echo "$as_me:7619: checking if the $cf_ncuconfig_root package files work" >&5 |
| 7620 | echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6 |
| 7621 | cf_have_ncuconfig=unknown |
| 7622 | |
| 7623 | cf_save_CPPFLAGS="$CPPFLAGS" |
| 7624 | cf_save_LIBS="$LIBS" |
| 7625 | |
| 7626 | CPPFLAGS="$CPPFLAGS `$PKG_CONFIG --cflags $cf_ncuconfig_root`" |
| 7627 | |
| 7628 | cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`" |
| 7629 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 7630 | for cf_add_1lib in $LIBS |
| 7631 | do |
| 7632 | for cf_add_2lib in $cf_add_libs |
| 7633 | do |
| 7634 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 7635 | then |
| 7636 | cf_add_1lib= |
| 7637 | break |
| 7638 | fi |
| 7639 | done |
| 7640 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 7641 | done |
| 7642 | LIBS="$cf_add_libs" |
| 7643 | |
| 7644 | cat >conftest.$ac_ext <<_ACEOF |
| 7645 | #line 7645 "configure" |
| 7646 | #include "confdefs.h" |
| 7647 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 7648 | int |
| 7649 | main () |
| 7650 | { |
| 7651 | initscr(); mousemask(0,0); tgoto((char *)0, 0, 0); |
| 7652 | ; |
| 7653 | return 0; |
| 7654 | } |
| 7655 | _ACEOF |
| 7656 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7657 | if { (eval echo "$as_me:7657: \"$ac_link\"") >&5 |
| 7658 | (eval $ac_link) 2>&5 |
| 7659 | ac_status=$? |
| 7660 | echo "$as_me:7660: \$? = $ac_status" >&5 |
| 7661 | (exit $ac_status); } && |
| 7662 | { ac_try='test -s conftest$ac_exeext' |
| 7663 | { (eval echo "$as_me:7663: \"$ac_try\"") >&5 |
| 7664 | (eval $ac_try) 2>&5 |
| 7665 | ac_status=$? |
| 7666 | echo "$as_me:7666: \$? = $ac_status" >&5 |
| 7667 | (exit $ac_status); }; }; then |
| 7668 | if test "$cross_compiling" = yes; then |
| 7669 | cf_have_ncuconfig=maybe |
| 7670 | else |
| 7671 | cat >conftest.$ac_ext <<_ACEOF |
| 7672 | #line 7672 "configure" |
| 7673 | #include "confdefs.h" |
| 7674 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 7675 | int main(void) |
| 7676 | { char *xx = curses_version(); return (xx == 0); } |
| 7677 | _ACEOF |
| 7678 | rm -f conftest$ac_exeext |
| 7679 | if { (eval echo "$as_me:7679: \"$ac_link\"") >&5 |
| 7680 | (eval $ac_link) 2>&5 |
| 7681 | ac_status=$? |
| 7682 | echo "$as_me:7682: \$? = $ac_status" >&5 |
| 7683 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 7684 | { (eval echo "$as_me:7684: \"$ac_try\"") >&5 |
| 7685 | (eval $ac_try) 2>&5 |
| 7686 | ac_status=$? |
| 7687 | echo "$as_me:7687: \$? = $ac_status" >&5 |
| 7688 | (exit $ac_status); }; }; then |
| 7689 | cf_have_ncuconfig=yes |
| 7690 | else |
| 7691 | echo "$as_me: program exited with status $ac_status" >&5 |
| 7692 | echo "$as_me: failed program was:" >&5 |
| 7693 | cat conftest.$ac_ext >&5 |
| 7694 | cf_have_ncuconfig=no |
| 7695 | fi |
| 7696 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 7697 | fi |
| 7698 | else |
| 7699 | echo "$as_me: failed program was:" >&5 |
| 7700 | cat conftest.$ac_ext >&5 |
| 7701 | cf_have_ncuconfig=no |
| 7702 | fi |
| 7703 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7704 | echo "$as_me:7704: result: $cf_have_ncuconfig" >&5 |
| 7705 | echo "${ECHO_T}$cf_have_ncuconfig" >&6 |
| 7706 | test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes |
| 7707 | if test "$cf_have_ncuconfig" != "yes" |
| 7708 | then |
| 7709 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 7710 | LIBS="$cf_save_LIBS" |
| 7711 | NCURSES_CONFIG_PKG=none |
| 7712 | else |
| 7713 | |
| 7714 | cat >>confdefs.h <<\EOF |
| 7715 | #define NCURSES 1 |
| 7716 | EOF |
| 7717 | |
| 7718 | NCURSES_CONFIG_PKG=$cf_ncuconfig_root |
| 7719 | fi |
| 7720 | |
| 7721 | else |
| 7722 | echo "$as_me:7722: result: no" >&5 |
| 7723 | echo "${ECHO_T}no" >&6 |
| 7724 | NCURSES_CONFIG_PKG=none |
| 7725 | fi |
| 7726 | else |
| 7727 | NCURSES_CONFIG_PKG=none |
| 7728 | fi |
| 7729 | |
| 7730 | if test "x$cf_have_ncuconfig" = "xno"; then |
| 7731 | echo "Looking for ${cf_ncuconfig_root}-config" |
| 7732 | |
| 7733 | if test -n "$ac_tool_prefix"; then |
| 7734 | for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config |
| 7735 | do |
| 7736 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 7737 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
| 7738 | echo "$as_me:7738: checking for $ac_word" >&5 |
| 7739 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 7740 | if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then |
| 7741 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7742 | else |
| 7743 | if test -n "$NCURSES_CONFIG"; then |
| 7744 | ac_cv_prog_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test. |
| 7745 | else |
| 7746 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 7747 | ac_dummy="$PATH" |
| 7748 | for ac_dir in $ac_dummy; do |
| 7749 | IFS=$ac_save_IFS |
| 7750 | test -z "$ac_dir" && ac_dir=. |
| 7751 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 7752 | ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog" |
| 7753 | echo "$as_me:7753: found $ac_dir/$ac_word" >&5 |
| 7754 | break |
| 7755 | done |
| 7756 | |
| 7757 | fi |
| 7758 | fi |
| 7759 | NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG |
| 7760 | if test -n "$NCURSES_CONFIG"; then |
| 7761 | echo "$as_me:7761: result: $NCURSES_CONFIG" >&5 |
| 7762 | echo "${ECHO_T}$NCURSES_CONFIG" >&6 |
| 7763 | else |
| 7764 | echo "$as_me:7764: result: no" >&5 |
| 7765 | echo "${ECHO_T}no" >&6 |
| 7766 | fi |
| 7767 | |
| 7768 | test -n "$NCURSES_CONFIG" && break |
| 7769 | done |
| 7770 | fi |
| 7771 | if test -z "$NCURSES_CONFIG"; then |
| 7772 | ac_ct_NCURSES_CONFIG=$NCURSES_CONFIG |
| 7773 | for ac_prog in ${cf_ncuconfig_root}-config ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config |
| 7774 | do |
| 7775 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 7776 | set dummy $ac_prog; ac_word=$2 |
| 7777 | echo "$as_me:7777: checking for $ac_word" >&5 |
| 7778 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 7779 | if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then |
| 7780 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7781 | else |
| 7782 | if test -n "$ac_ct_NCURSES_CONFIG"; then |
| 7783 | ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_ct_NCURSES_CONFIG" # Let the user override the test. |
| 7784 | else |
| 7785 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 7786 | ac_dummy="$PATH" |
| 7787 | for ac_dir in $ac_dummy; do |
| 7788 | IFS=$ac_save_IFS |
| 7789 | test -z "$ac_dir" && ac_dir=. |
| 7790 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 7791 | ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog" |
| 7792 | echo "$as_me:7792: found $ac_dir/$ac_word" >&5 |
| 7793 | break |
| 7794 | done |
| 7795 | |
| 7796 | fi |
| 7797 | fi |
| 7798 | ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG |
| 7799 | if test -n "$ac_ct_NCURSES_CONFIG"; then |
| 7800 | echo "$as_me:7800: result: $ac_ct_NCURSES_CONFIG" >&5 |
| 7801 | echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6 |
| 7802 | else |
| 7803 | echo "$as_me:7803: result: no" >&5 |
| 7804 | echo "${ECHO_T}no" >&6 |
| 7805 | fi |
| 7806 | |
| 7807 | test -n "$ac_ct_NCURSES_CONFIG" && break |
| 7808 | done |
| 7809 | test -n "$ac_ct_NCURSES_CONFIG" || ac_ct_NCURSES_CONFIG="none" |
| 7810 | |
| 7811 | NCURSES_CONFIG=$ac_ct_NCURSES_CONFIG |
| 7812 | fi |
| 7813 | |
| 7814 | if test "$NCURSES_CONFIG" != none ; then |
| 7815 | |
| 7816 | CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`" |
| 7817 | |
| 7818 | cf_add_libs="`$NCURSES_CONFIG --libs`" |
| 7819 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 7820 | for cf_add_1lib in $LIBS |
| 7821 | do |
| 7822 | for cf_add_2lib in $cf_add_libs |
| 7823 | do |
| 7824 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 7825 | then |
| 7826 | cf_add_1lib= |
| 7827 | break |
| 7828 | fi |
| 7829 | done |
| 7830 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 7831 | done |
| 7832 | LIBS="$cf_add_libs" |
| 7833 | |
| 7834 | # even with config script, some packages use no-override for curses.h |
| 7835 | |
| 7836 | echo "$as_me:7836: checking if we have identified curses headers" >&5 |
| 7837 | echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6 |
| 7838 | if test "${cf_cv_ncurses_header+set}" = set; then |
| 7839 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7840 | else |
| 7841 | |
| 7842 | cf_cv_ncurses_header=none |
| 7843 | for cf_header in \ |
| 7844 | ncurses.h $cf_cv_screen/ncurses.h \ |
| 7845 | curses.h $cf_cv_screen/curses.h |
| 7846 | do |
| 7847 | cat >conftest.$ac_ext <<_ACEOF |
| 7848 | #line 7848 "configure" |
| 7849 | #include "confdefs.h" |
| 7850 | #include <${cf_header}> |
| 7851 | int |
| 7852 | main () |
| 7853 | { |
| 7854 | initscr(); tgoto("?", 0,0) |
| 7855 | ; |
| 7856 | return 0; |
| 7857 | } |
| 7858 | _ACEOF |
| 7859 | rm -f conftest.$ac_objext |
| 7860 | if { (eval echo "$as_me:7860: \"$ac_compile\"") >&5 |
| 7861 | (eval $ac_compile) 2>&5 |
| 7862 | ac_status=$? |
| 7863 | echo "$as_me:7863: \$? = $ac_status" >&5 |
| 7864 | (exit $ac_status); } && |
| 7865 | { ac_try='test -s conftest.$ac_objext' |
| 7866 | { (eval echo "$as_me:7866: \"$ac_try\"") >&5 |
| 7867 | (eval $ac_try) 2>&5 |
| 7868 | ac_status=$? |
| 7869 | echo "$as_me:7869: \$? = $ac_status" >&5 |
| 7870 | (exit $ac_status); }; }; then |
| 7871 | cf_cv_ncurses_header=$cf_header; break |
| 7872 | else |
| 7873 | echo "$as_me: failed program was:" >&5 |
| 7874 | cat conftest.$ac_ext >&5 |
| 7875 | fi |
| 7876 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 7877 | done |
| 7878 | |
| 7879 | fi |
| 7880 | echo "$as_me:7880: result: $cf_cv_ncurses_header" >&5 |
| 7881 | echo "${ECHO_T}$cf_cv_ncurses_header" >&6 |
| 7882 | |
| 7883 | if test "$cf_cv_ncurses_header" = none ; then |
| 7884 | { { echo "$as_me:7884: error: No curses header-files found" >&5 |
| 7885 | echo "$as_me: error: No curses header-files found" >&2;} |
| 7886 | { (exit 1); exit 1; }; } |
| 7887 | fi |
| 7888 | |
| 7889 | # cheat, to get the right #define's for HAVE_NCURSES_H, etc. |
| 7890 | |
| 7891 | for ac_header in $cf_cv_ncurses_header |
| 7892 | do |
| 7893 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 7894 | echo "$as_me:7894: checking for $ac_header" >&5 |
| 7895 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 7896 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 7897 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7898 | else |
| 7899 | cat >conftest.$ac_ext <<_ACEOF |
| 7900 | #line 7900 "configure" |
| 7901 | #include "confdefs.h" |
| 7902 | #include <$ac_header> |
| 7903 | _ACEOF |
| 7904 | if { (eval echo "$as_me:7904: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 7905 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 7906 | ac_status=$? |
| 7907 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 7908 | rm -f conftest.er1 |
| 7909 | cat conftest.err >&5 |
| 7910 | echo "$as_me:7910: \$? = $ac_status" >&5 |
| 7911 | (exit $ac_status); } >/dev/null; then |
| 7912 | if test -s conftest.err; then |
| 7913 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 7914 | else |
| 7915 | ac_cpp_err= |
| 7916 | fi |
| 7917 | else |
| 7918 | ac_cpp_err=yes |
| 7919 | fi |
| 7920 | if test -z "$ac_cpp_err"; then |
| 7921 | eval "$as_ac_Header=yes" |
| 7922 | else |
| 7923 | echo "$as_me: failed program was:" >&5 |
| 7924 | cat conftest.$ac_ext >&5 |
| 7925 | eval "$as_ac_Header=no" |
| 7926 | fi |
| 7927 | rm -f conftest.err conftest.$ac_ext |
| 7928 | fi |
| 7929 | echo "$as_me:7929: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 7930 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 7931 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 7932 | cat >>confdefs.h <<EOF |
| 7933 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 7934 | EOF |
| 7935 | |
| 7936 | fi |
| 7937 | done |
| 7938 | |
| 7939 | cat >>confdefs.h <<\EOF |
| 7940 | #define NCURSES 1 |
| 7941 | EOF |
| 7942 | |
| 7943 | cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 7944 | |
| 7945 | cat >>confdefs.h <<EOF |
| 7946 | #define $cf_nculib_ROOT 1 |
| 7947 | EOF |
| 7948 | |
| 7949 | cf_cv_ncurses_version=`$NCURSES_CONFIG --version` |
| 7950 | |
| 7951 | else |
| 7952 | |
| 7953 | cf_ncuhdr_root=$cf_cv_screen |
| 7954 | |
| 7955 | test -n "$cf_cv_curses_dir" && \ |
| 7956 | test "$cf_cv_curses_dir" != "no" && { \ |
| 7957 | |
| 7958 | if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then |
| 7959 | for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root |
| 7960 | do |
| 7961 | while test $cf_add_incdir != /usr/include |
| 7962 | do |
| 7963 | if test -d $cf_add_incdir |
| 7964 | then |
| 7965 | cf_have_incdir=no |
| 7966 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 7967 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 7968 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 7969 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 7970 | cf_have_incdir=yes; break |
| 7971 | fi |
| 7972 | done |
| 7973 | fi |
| 7974 | |
| 7975 | if test "$cf_have_incdir" = no ; then |
| 7976 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 7977 | if test "$GCC" = yes |
| 7978 | then |
| 7979 | cf_save_CPPFLAGS=$CPPFLAGS |
| 7980 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 7981 | cat >conftest.$ac_ext <<_ACEOF |
| 7982 | #line 7982 "configure" |
| 7983 | #include "confdefs.h" |
| 7984 | #include <stdio.h> |
| 7985 | int |
| 7986 | main () |
| 7987 | { |
| 7988 | printf("Hello") |
| 7989 | ; |
| 7990 | return 0; |
| 7991 | } |
| 7992 | _ACEOF |
| 7993 | rm -f conftest.$ac_objext |
| 7994 | if { (eval echo "$as_me:7994: \"$ac_compile\"") >&5 |
| 7995 | (eval $ac_compile) 2>&5 |
| 7996 | ac_status=$? |
| 7997 | echo "$as_me:7997: \$? = $ac_status" >&5 |
| 7998 | (exit $ac_status); } && |
| 7999 | { ac_try='test -s conftest.$ac_objext' |
| 8000 | { (eval echo "$as_me:8000: \"$ac_try\"") >&5 |
| 8001 | (eval $ac_try) 2>&5 |
| 8002 | ac_status=$? |
| 8003 | echo "$as_me:8003: \$? = $ac_status" >&5 |
| 8004 | (exit $ac_status); }; }; then |
| 8005 | : |
| 8006 | else |
| 8007 | echo "$as_me: failed program was:" >&5 |
| 8008 | cat conftest.$ac_ext >&5 |
| 8009 | cf_have_incdir=yes |
| 8010 | fi |
| 8011 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8012 | CPPFLAGS=$cf_save_CPPFLAGS |
| 8013 | fi |
| 8014 | fi |
| 8015 | fi |
| 8016 | |
| 8017 | if test "$cf_have_incdir" = no ; then |
| 8018 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 8019 | |
| 8020 | echo "${as_me:-configure}:8020: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 8021 | |
| 8022 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 8023 | |
| 8024 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 8025 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 8026 | cf_add_incdir="$cf_top_incdir" |
| 8027 | else |
| 8028 | break |
| 8029 | fi |
| 8030 | else |
| 8031 | break |
| 8032 | fi |
| 8033 | done |
| 8034 | done |
| 8035 | fi |
| 8036 | |
| 8037 | } |
| 8038 | |
| 8039 | echo "$as_me:8039: checking for $cf_ncuhdr_root header in include-path" >&5 |
| 8040 | echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6 |
| 8041 | if test "${cf_cv_ncurses_h+set}" = set; then |
| 8042 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8043 | else |
| 8044 | |
| 8045 | cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h" |
| 8046 | ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h" |
| 8047 | for cf_header in $cf_header_list |
| 8048 | do |
| 8049 | |
| 8050 | cat >conftest.$ac_ext <<_ACEOF |
| 8051 | #line 8051 "configure" |
| 8052 | #include "confdefs.h" |
| 8053 | |
| 8054 | #include <$cf_header> |
| 8055 | int |
| 8056 | main () |
| 8057 | { |
| 8058 | |
| 8059 | #ifdef NCURSES_VERSION |
| 8060 | |
| 8061 | printf("%s\n", NCURSES_VERSION); |
| 8062 | #else |
| 8063 | #ifdef __NCURSES_H |
| 8064 | printf("old\n"); |
| 8065 | #else |
| 8066 | make an error |
| 8067 | #endif |
| 8068 | #endif |
| 8069 | |
| 8070 | ; |
| 8071 | return 0; |
| 8072 | } |
| 8073 | _ACEOF |
| 8074 | rm -f conftest.$ac_objext |
| 8075 | if { (eval echo "$as_me:8075: \"$ac_compile\"") >&5 |
| 8076 | (eval $ac_compile) 2>&5 |
| 8077 | ac_status=$? |
| 8078 | echo "$as_me:8078: \$? = $ac_status" >&5 |
| 8079 | (exit $ac_status); } && |
| 8080 | { ac_try='test -s conftest.$ac_objext' |
| 8081 | { (eval echo "$as_me:8081: \"$ac_try\"") >&5 |
| 8082 | (eval $ac_try) 2>&5 |
| 8083 | ac_status=$? |
| 8084 | echo "$as_me:8084: \$? = $ac_status" >&5 |
| 8085 | (exit $ac_status); }; }; then |
| 8086 | cf_cv_ncurses_h=$cf_header |
| 8087 | |
| 8088 | else |
| 8089 | echo "$as_me: failed program was:" >&5 |
| 8090 | cat conftest.$ac_ext >&5 |
| 8091 | cf_cv_ncurses_h=no |
| 8092 | fi |
| 8093 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8094 | |
| 8095 | test "$cf_cv_ncurses_h" != no && break |
| 8096 | done |
| 8097 | |
| 8098 | fi |
| 8099 | echo "$as_me:8099: result: $cf_cv_ncurses_h" >&5 |
| 8100 | echo "${ECHO_T}$cf_cv_ncurses_h" >&6 |
| 8101 | |
| 8102 | if test "$cf_cv_ncurses_h" != no ; then |
| 8103 | cf_cv_ncurses_header=$cf_cv_ncurses_h |
| 8104 | else |
| 8105 | |
| 8106 | echo "$as_me:8106: checking for $cf_ncuhdr_root include-path" >&5 |
| 8107 | echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6 |
| 8108 | if test "${cf_cv_ncurses_h2+set}" = set; then |
| 8109 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8110 | else |
| 8111 | |
| 8112 | test -n "$verbose" && echo |
| 8113 | |
| 8114 | cf_search= |
| 8115 | |
| 8116 | # collect the current set of include-directories from compiler flags |
| 8117 | cf_header_path_list="" |
| 8118 | if test -n "${CFLAGS}${CPPFLAGS}" ; then |
| 8119 | for cf_header_path in $CPPFLAGS $CFLAGS |
| 8120 | do |
| 8121 | case $cf_header_path in |
| 8122 | (-I*) |
| 8123 | cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'` |
| 8124 | |
| 8125 | test "x$cf_header_path" != "xNONE" && \ |
| 8126 | test -d "$cf_header_path" && \ |
| 8127 | { |
| 8128 | test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path" |
| 8129 | test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include" |
| 8130 | test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root" |
| 8131 | test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include" |
| 8132 | test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include" |
| 8133 | test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root" |
| 8134 | } |
| 8135 | |
| 8136 | cf_header_path_list="$cf_header_path_list $cf_search" |
| 8137 | ;; |
| 8138 | esac |
| 8139 | done |
| 8140 | fi |
| 8141 | |
| 8142 | # add the variations for the package we are looking for |
| 8143 | |
| 8144 | cf_search= |
| 8145 | |
| 8146 | test "x$prefix" != "xNONE" && \ |
| 8147 | test -d "$prefix" && \ |
| 8148 | { |
| 8149 | test -n "$verbose" && echo " ... testing for include-directories under $prefix" |
| 8150 | test -d $prefix/include && cf_search="$cf_search $prefix/include" |
| 8151 | test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root" |
| 8152 | test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include" |
| 8153 | test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include" |
| 8154 | test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" |
| 8155 | } |
| 8156 | |
| 8157 | for cf_subdir_prefix in \ |
| 8158 | /usr \ |
| 8159 | /usr/local \ |
| 8160 | /usr/pkg \ |
| 8161 | /opt \ |
| 8162 | /opt/local \ |
| 8163 | $HOME |
| 8164 | do |
| 8165 | |
| 8166 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 8167 | test -d "$cf_subdir_prefix" && \ |
| 8168 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 8169 | test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix" |
| 8170 | test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include" |
| 8171 | test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root" |
| 8172 | test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include" |
| 8173 | test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include" |
| 8174 | test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" |
| 8175 | } |
| 8176 | |
| 8177 | done |
| 8178 | |
| 8179 | test "$includedir" != NONE && \ |
| 8180 | test "$includedir" != "/usr/include" && \ |
| 8181 | test -d "$includedir" && { |
| 8182 | test -d $includedir && cf_search="$cf_search $includedir" |
| 8183 | test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root" |
| 8184 | } |
| 8185 | |
| 8186 | test "$oldincludedir" != NONE && \ |
| 8187 | test "$oldincludedir" != "/usr/include" && \ |
| 8188 | test -d "$oldincludedir" && { |
| 8189 | test -d $oldincludedir && cf_search="$cf_search $oldincludedir" |
| 8190 | test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root" |
| 8191 | } |
| 8192 | |
| 8193 | cf_search="$cf_search $cf_header_path_list" |
| 8194 | |
| 8195 | test -n "$verbose" && echo search path $cf_search |
| 8196 | cf_save2_CPPFLAGS="$CPPFLAGS" |
| 8197 | for cf_incdir in $cf_search |
| 8198 | do |
| 8199 | |
| 8200 | if test -n "$cf_incdir" ; then |
| 8201 | for cf_add_incdir in $cf_incdir |
| 8202 | do |
| 8203 | while test $cf_add_incdir != /usr/include |
| 8204 | do |
| 8205 | if test -d $cf_add_incdir |
| 8206 | then |
| 8207 | cf_have_incdir=no |
| 8208 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 8209 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 8210 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 8211 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 8212 | cf_have_incdir=yes; break |
| 8213 | fi |
| 8214 | done |
| 8215 | fi |
| 8216 | |
| 8217 | if test "$cf_have_incdir" = no ; then |
| 8218 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 8219 | if test "$GCC" = yes |
| 8220 | then |
| 8221 | cf_save_CPPFLAGS=$CPPFLAGS |
| 8222 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 8223 | cat >conftest.$ac_ext <<_ACEOF |
| 8224 | #line 8224 "configure" |
| 8225 | #include "confdefs.h" |
| 8226 | #include <stdio.h> |
| 8227 | int |
| 8228 | main () |
| 8229 | { |
| 8230 | printf("Hello") |
| 8231 | ; |
| 8232 | return 0; |
| 8233 | } |
| 8234 | _ACEOF |
| 8235 | rm -f conftest.$ac_objext |
| 8236 | if { (eval echo "$as_me:8236: \"$ac_compile\"") >&5 |
| 8237 | (eval $ac_compile) 2>&5 |
| 8238 | ac_status=$? |
| 8239 | echo "$as_me:8239: \$? = $ac_status" >&5 |
| 8240 | (exit $ac_status); } && |
| 8241 | { ac_try='test -s conftest.$ac_objext' |
| 8242 | { (eval echo "$as_me:8242: \"$ac_try\"") >&5 |
| 8243 | (eval $ac_try) 2>&5 |
| 8244 | ac_status=$? |
| 8245 | echo "$as_me:8245: \$? = $ac_status" >&5 |
| 8246 | (exit $ac_status); }; }; then |
| 8247 | : |
| 8248 | else |
| 8249 | echo "$as_me: failed program was:" >&5 |
| 8250 | cat conftest.$ac_ext >&5 |
| 8251 | cf_have_incdir=yes |
| 8252 | fi |
| 8253 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8254 | CPPFLAGS=$cf_save_CPPFLAGS |
| 8255 | fi |
| 8256 | fi |
| 8257 | fi |
| 8258 | |
| 8259 | if test "$cf_have_incdir" = no ; then |
| 8260 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 8261 | |
| 8262 | echo "${as_me:-configure}:8262: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 8263 | |
| 8264 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 8265 | |
| 8266 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 8267 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 8268 | cf_add_incdir="$cf_top_incdir" |
| 8269 | else |
| 8270 | break |
| 8271 | fi |
| 8272 | else |
| 8273 | break |
| 8274 | fi |
| 8275 | done |
| 8276 | done |
| 8277 | fi |
| 8278 | |
| 8279 | for cf_header in \ |
| 8280 | ncurses.h \ |
| 8281 | curses.h |
| 8282 | do |
| 8283 | |
| 8284 | cat >conftest.$ac_ext <<_ACEOF |
| 8285 | #line 8285 "configure" |
| 8286 | #include "confdefs.h" |
| 8287 | |
| 8288 | #include <$cf_header> |
| 8289 | int |
| 8290 | main () |
| 8291 | { |
| 8292 | |
| 8293 | #ifdef NCURSES_VERSION |
| 8294 | |
| 8295 | printf("%s\n", NCURSES_VERSION); |
| 8296 | #else |
| 8297 | #ifdef __NCURSES_H |
| 8298 | printf("old\n"); |
| 8299 | #else |
| 8300 | make an error |
| 8301 | #endif |
| 8302 | #endif |
| 8303 | |
| 8304 | ; |
| 8305 | return 0; |
| 8306 | } |
| 8307 | _ACEOF |
| 8308 | rm -f conftest.$ac_objext |
| 8309 | if { (eval echo "$as_me:8309: \"$ac_compile\"") >&5 |
| 8310 | (eval $ac_compile) 2>&5 |
| 8311 | ac_status=$? |
| 8312 | echo "$as_me:8312: \$? = $ac_status" >&5 |
| 8313 | (exit $ac_status); } && |
| 8314 | { ac_try='test -s conftest.$ac_objext' |
| 8315 | { (eval echo "$as_me:8315: \"$ac_try\"") >&5 |
| 8316 | (eval $ac_try) 2>&5 |
| 8317 | ac_status=$? |
| 8318 | echo "$as_me:8318: \$? = $ac_status" >&5 |
| 8319 | (exit $ac_status); }; }; then |
| 8320 | cf_cv_ncurses_h2=$cf_header |
| 8321 | |
| 8322 | else |
| 8323 | echo "$as_me: failed program was:" >&5 |
| 8324 | cat conftest.$ac_ext >&5 |
| 8325 | cf_cv_ncurses_h2=no |
| 8326 | fi |
| 8327 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8328 | |
| 8329 | if test "$cf_cv_ncurses_h2" != no ; then |
| 8330 | cf_cv_ncurses_h2=$cf_incdir/$cf_header |
| 8331 | test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6 |
| 8332 | break |
| 8333 | fi |
| 8334 | test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6 |
| 8335 | done |
| 8336 | CPPFLAGS="$cf_save2_CPPFLAGS" |
| 8337 | test "$cf_cv_ncurses_h2" != no && break |
| 8338 | done |
| 8339 | test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:8339: error: not found" >&5 |
| 8340 | echo "$as_me: error: not found" >&2;} |
| 8341 | { (exit 1); exit 1; }; } |
| 8342 | |
| 8343 | fi |
| 8344 | echo "$as_me:8344: result: $cf_cv_ncurses_h2" >&5 |
| 8345 | echo "${ECHO_T}$cf_cv_ncurses_h2" >&6 |
| 8346 | |
| 8347 | cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'` |
| 8348 | cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2` |
| 8349 | if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then |
| 8350 | cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header |
| 8351 | fi |
| 8352 | |
| 8353 | if test -n "$cf_1st_incdir" ; then |
| 8354 | for cf_add_incdir in $cf_1st_incdir |
| 8355 | do |
| 8356 | while test $cf_add_incdir != /usr/include |
| 8357 | do |
| 8358 | if test -d $cf_add_incdir |
| 8359 | then |
| 8360 | cf_have_incdir=no |
| 8361 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 8362 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 8363 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 8364 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 8365 | cf_have_incdir=yes; break |
| 8366 | fi |
| 8367 | done |
| 8368 | fi |
| 8369 | |
| 8370 | if test "$cf_have_incdir" = no ; then |
| 8371 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 8372 | if test "$GCC" = yes |
| 8373 | then |
| 8374 | cf_save_CPPFLAGS=$CPPFLAGS |
| 8375 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 8376 | cat >conftest.$ac_ext <<_ACEOF |
| 8377 | #line 8377 "configure" |
| 8378 | #include "confdefs.h" |
| 8379 | #include <stdio.h> |
| 8380 | int |
| 8381 | main () |
| 8382 | { |
| 8383 | printf("Hello") |
| 8384 | ; |
| 8385 | return 0; |
| 8386 | } |
| 8387 | _ACEOF |
| 8388 | rm -f conftest.$ac_objext |
| 8389 | if { (eval echo "$as_me:8389: \"$ac_compile\"") >&5 |
| 8390 | (eval $ac_compile) 2>&5 |
| 8391 | ac_status=$? |
| 8392 | echo "$as_me:8392: \$? = $ac_status" >&5 |
| 8393 | (exit $ac_status); } && |
| 8394 | { ac_try='test -s conftest.$ac_objext' |
| 8395 | { (eval echo "$as_me:8395: \"$ac_try\"") >&5 |
| 8396 | (eval $ac_try) 2>&5 |
| 8397 | ac_status=$? |
| 8398 | echo "$as_me:8398: \$? = $ac_status" >&5 |
| 8399 | (exit $ac_status); }; }; then |
| 8400 | : |
| 8401 | else |
| 8402 | echo "$as_me: failed program was:" >&5 |
| 8403 | cat conftest.$ac_ext >&5 |
| 8404 | cf_have_incdir=yes |
| 8405 | fi |
| 8406 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8407 | CPPFLAGS=$cf_save_CPPFLAGS |
| 8408 | fi |
| 8409 | fi |
| 8410 | fi |
| 8411 | |
| 8412 | if test "$cf_have_incdir" = no ; then |
| 8413 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 8414 | |
| 8415 | echo "${as_me:-configure}:8415: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 8416 | |
| 8417 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 8418 | |
| 8419 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 8420 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 8421 | cf_add_incdir="$cf_top_incdir" |
| 8422 | else |
| 8423 | break |
| 8424 | fi |
| 8425 | else |
| 8426 | break |
| 8427 | fi |
| 8428 | done |
| 8429 | done |
| 8430 | fi |
| 8431 | |
| 8432 | fi |
| 8433 | |
| 8434 | # Set definitions to allow ifdef'ing for ncurses.h |
| 8435 | |
| 8436 | case $cf_cv_ncurses_header in |
| 8437 | (*ncurses.h) |
| 8438 | |
| 8439 | cat >>confdefs.h <<\EOF |
| 8440 | #define HAVE_NCURSES_H 1 |
| 8441 | EOF |
| 8442 | |
| 8443 | ;; |
| 8444 | esac |
| 8445 | |
| 8446 | case $cf_cv_ncurses_header in |
| 8447 | (ncurses/curses.h|ncurses/ncurses.h) |
| 8448 | |
| 8449 | cat >>confdefs.h <<\EOF |
| 8450 | #define HAVE_NCURSES_NCURSES_H 1 |
| 8451 | EOF |
| 8452 | |
| 8453 | ;; |
| 8454 | (ncursesw/curses.h|ncursesw/ncurses.h) |
| 8455 | |
| 8456 | cat >>confdefs.h <<\EOF |
| 8457 | #define HAVE_NCURSESW_NCURSES_H 1 |
| 8458 | EOF |
| 8459 | |
| 8460 | ;; |
| 8461 | esac |
| 8462 | |
| 8463 | echo "$as_me:8463: checking for terminfo header" >&5 |
| 8464 | echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6 |
| 8465 | if test "${cf_cv_term_header+set}" = set; then |
| 8466 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8467 | else |
| 8468 | |
| 8469 | case ${cf_cv_ncurses_header} in |
| 8470 | (*/ncurses.h|*/ncursesw.h) |
| 8471 | cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'` |
| 8472 | ;; |
| 8473 | (*) |
| 8474 | cf_term_header=term.h |
| 8475 | ;; |
| 8476 | esac |
| 8477 | |
| 8478 | for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h" |
| 8479 | do |
| 8480 | cat >conftest.$ac_ext <<_ACEOF |
| 8481 | #line 8481 "configure" |
| 8482 | #include "confdefs.h" |
| 8483 | #include <stdio.h> |
| 8484 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 8485 | #include <$cf_test> |
| 8486 | |
| 8487 | int |
| 8488 | main () |
| 8489 | { |
| 8490 | int x = auto_left_margin |
| 8491 | ; |
| 8492 | return 0; |
| 8493 | } |
| 8494 | _ACEOF |
| 8495 | rm -f conftest.$ac_objext |
| 8496 | if { (eval echo "$as_me:8496: \"$ac_compile\"") >&5 |
| 8497 | (eval $ac_compile) 2>&5 |
| 8498 | ac_status=$? |
| 8499 | echo "$as_me:8499: \$? = $ac_status" >&5 |
| 8500 | (exit $ac_status); } && |
| 8501 | { ac_try='test -s conftest.$ac_objext' |
| 8502 | { (eval echo "$as_me:8502: \"$ac_try\"") >&5 |
| 8503 | (eval $ac_try) 2>&5 |
| 8504 | ac_status=$? |
| 8505 | echo "$as_me:8505: \$? = $ac_status" >&5 |
| 8506 | (exit $ac_status); }; }; then |
| 8507 | |
| 8508 | cf_cv_term_header="$cf_test" |
| 8509 | else |
| 8510 | echo "$as_me: failed program was:" >&5 |
| 8511 | cat conftest.$ac_ext >&5 |
| 8512 | |
| 8513 | cf_cv_term_header=unknown |
| 8514 | |
| 8515 | fi |
| 8516 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8517 | test "$cf_cv_term_header" != unknown && break |
| 8518 | done |
| 8519 | |
| 8520 | fi |
| 8521 | echo "$as_me:8521: result: $cf_cv_term_header" >&5 |
| 8522 | echo "${ECHO_T}$cf_cv_term_header" >&6 |
| 8523 | |
| 8524 | # Set definitions to allow ifdef'ing to accommodate subdirectories |
| 8525 | |
| 8526 | case $cf_cv_term_header in |
| 8527 | (*term.h) |
| 8528 | |
| 8529 | cat >>confdefs.h <<\EOF |
| 8530 | #define HAVE_TERM_H 1 |
| 8531 | EOF |
| 8532 | |
| 8533 | ;; |
| 8534 | esac |
| 8535 | |
| 8536 | case $cf_cv_term_header in |
| 8537 | (ncurses/term.h) |
| 8538 | |
| 8539 | cat >>confdefs.h <<\EOF |
| 8540 | #define HAVE_NCURSES_TERM_H 1 |
| 8541 | EOF |
| 8542 | |
| 8543 | ;; |
| 8544 | (ncursesw/term.h) |
| 8545 | |
| 8546 | cat >>confdefs.h <<\EOF |
| 8547 | #define HAVE_NCURSESW_TERM_H 1 |
| 8548 | EOF |
| 8549 | |
| 8550 | ;; |
| 8551 | esac |
| 8552 | |
| 8553 | # some applications need this, but should check for NCURSES_VERSION |
| 8554 | |
| 8555 | cat >>confdefs.h <<\EOF |
| 8556 | #define NCURSES 1 |
| 8557 | EOF |
| 8558 | |
| 8559 | echo "$as_me:8559: checking for ncurses version" >&5 |
| 8560 | echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6 |
| 8561 | if test "${cf_cv_ncurses_version+set}" = set; then |
| 8562 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8563 | else |
| 8564 | |
| 8565 | cf_cv_ncurses_version=no |
| 8566 | cf_tempfile=out$$ |
| 8567 | rm -f $cf_tempfile |
| 8568 | if test "$cross_compiling" = yes; then |
| 8569 | |
| 8570 | # This will not work if the preprocessor splits the line after the |
| 8571 | # Autoconf token. The 'unproto' program does that. |
| 8572 | cat > conftest.$ac_ext <<EOF |
| 8573 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 8574 | #undef Autoconf |
| 8575 | #ifdef NCURSES_VERSION |
| 8576 | Autoconf NCURSES_VERSION |
| 8577 | #else |
| 8578 | #ifdef __NCURSES_H |
| 8579 | Autoconf "old" |
| 8580 | #endif |
| 8581 | ; |
| 8582 | #endif |
| 8583 | EOF |
| 8584 | cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out" |
| 8585 | { (eval echo "$as_me:8585: \"$cf_try\"") >&5 |
| 8586 | (eval $cf_try) 2>&5 |
| 8587 | ac_status=$? |
| 8588 | echo "$as_me:8588: \$? = $ac_status" >&5 |
| 8589 | (exit $ac_status); } |
| 8590 | if test -f conftest.out ; then |
| 8591 | cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'` |
| 8592 | test -n "$cf_out" && cf_cv_ncurses_version="$cf_out" |
| 8593 | rm -f conftest.out |
| 8594 | fi |
| 8595 | |
| 8596 | else |
| 8597 | cat >conftest.$ac_ext <<_ACEOF |
| 8598 | #line 8598 "configure" |
| 8599 | #include "confdefs.h" |
| 8600 | |
| 8601 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 8602 | #include <stdio.h> |
| 8603 | int main() |
| 8604 | { |
| 8605 | FILE *fp = fopen("$cf_tempfile", "w"); |
| 8606 | #ifdef NCURSES_VERSION |
| 8607 | # ifdef NCURSES_VERSION_PATCH |
| 8608 | fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH); |
| 8609 | # else |
| 8610 | fprintf(fp, "%s\n", NCURSES_VERSION); |
| 8611 | # endif |
| 8612 | #else |
| 8613 | # ifdef __NCURSES_H |
| 8614 | fprintf(fp, "old\n"); |
| 8615 | # else |
| 8616 | make an error |
| 8617 | # endif |
| 8618 | #endif |
| 8619 | ${cf_cv_main_return:-return}(0); |
| 8620 | } |
| 8621 | _ACEOF |
| 8622 | rm -f conftest$ac_exeext |
| 8623 | if { (eval echo "$as_me:8623: \"$ac_link\"") >&5 |
| 8624 | (eval $ac_link) 2>&5 |
| 8625 | ac_status=$? |
| 8626 | echo "$as_me:8626: \$? = $ac_status" >&5 |
| 8627 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 8628 | { (eval echo "$as_me:8628: \"$ac_try\"") >&5 |
| 8629 | (eval $ac_try) 2>&5 |
| 8630 | ac_status=$? |
| 8631 | echo "$as_me:8631: \$? = $ac_status" >&5 |
| 8632 | (exit $ac_status); }; }; then |
| 8633 | |
| 8634 | cf_cv_ncurses_version=`cat $cf_tempfile` |
| 8635 | else |
| 8636 | echo "$as_me: program exited with status $ac_status" >&5 |
| 8637 | echo "$as_me: failed program was:" >&5 |
| 8638 | cat conftest.$ac_ext >&5 |
| 8639 | fi |
| 8640 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 8641 | fi |
| 8642 | rm -f $cf_tempfile |
| 8643 | |
| 8644 | fi |
| 8645 | echo "$as_me:8645: result: $cf_cv_ncurses_version" >&5 |
| 8646 | echo "${ECHO_T}$cf_cv_ncurses_version" >&6 |
| 8647 | test "$cf_cv_ncurses_version" = no || |
| 8648 | cat >>confdefs.h <<\EOF |
| 8649 | #define NCURSES 1 |
| 8650 | EOF |
| 8651 | |
| 8652 | cf_nculib_root=$cf_cv_screen |
| 8653 | # This works, except for the special case where we find gpm, but |
| 8654 | # ncurses is in a nonstandard location via $LIBS, and we really want |
| 8655 | # to link gpm. |
| 8656 | cf_ncurses_LIBS="" |
| 8657 | cf_ncurses_SAVE="$LIBS" |
| 8658 | echo "$as_me:8658: checking for Gpm_Open in -lgpm" >&5 |
| 8659 | echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6 |
| 8660 | if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then |
| 8661 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8662 | else |
| 8663 | ac_check_lib_save_LIBS=$LIBS |
| 8664 | LIBS="-lgpm $LIBS" |
| 8665 | cat >conftest.$ac_ext <<_ACEOF |
| 8666 | #line 8666 "configure" |
| 8667 | #include "confdefs.h" |
| 8668 | |
| 8669 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 8670 | #ifdef __cplusplus |
| 8671 | extern "C" |
| 8672 | #endif |
| 8673 | /* We use char because int might match the return type of a gcc2 |
| 8674 | builtin and then its argument prototype would still apply. */ |
| 8675 | char Gpm_Open (); |
| 8676 | int |
| 8677 | main () |
| 8678 | { |
| 8679 | Gpm_Open (); |
| 8680 | ; |
| 8681 | return 0; |
| 8682 | } |
| 8683 | _ACEOF |
| 8684 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 8685 | if { (eval echo "$as_me:8685: \"$ac_link\"") >&5 |
| 8686 | (eval $ac_link) 2>&5 |
| 8687 | ac_status=$? |
| 8688 | echo "$as_me:8688: \$? = $ac_status" >&5 |
| 8689 | (exit $ac_status); } && |
| 8690 | { ac_try='test -s conftest$ac_exeext' |
| 8691 | { (eval echo "$as_me:8691: \"$ac_try\"") >&5 |
| 8692 | (eval $ac_try) 2>&5 |
| 8693 | ac_status=$? |
| 8694 | echo "$as_me:8694: \$? = $ac_status" >&5 |
| 8695 | (exit $ac_status); }; }; then |
| 8696 | ac_cv_lib_gpm_Gpm_Open=yes |
| 8697 | else |
| 8698 | echo "$as_me: failed program was:" >&5 |
| 8699 | cat conftest.$ac_ext >&5 |
| 8700 | ac_cv_lib_gpm_Gpm_Open=no |
| 8701 | fi |
| 8702 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 8703 | LIBS=$ac_check_lib_save_LIBS |
| 8704 | fi |
| 8705 | echo "$as_me:8705: result: $ac_cv_lib_gpm_Gpm_Open" >&5 |
| 8706 | echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6 |
| 8707 | if test $ac_cv_lib_gpm_Gpm_Open = yes; then |
| 8708 | echo "$as_me:8708: checking for initscr in -lgpm" >&5 |
| 8709 | echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6 |
| 8710 | if test "${ac_cv_lib_gpm_initscr+set}" = set; then |
| 8711 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8712 | else |
| 8713 | ac_check_lib_save_LIBS=$LIBS |
| 8714 | LIBS="-lgpm $LIBS" |
| 8715 | cat >conftest.$ac_ext <<_ACEOF |
| 8716 | #line 8716 "configure" |
| 8717 | #include "confdefs.h" |
| 8718 | |
| 8719 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 8720 | #ifdef __cplusplus |
| 8721 | extern "C" |
| 8722 | #endif |
| 8723 | /* We use char because int might match the return type of a gcc2 |
| 8724 | builtin and then its argument prototype would still apply. */ |
| 8725 | char initscr (); |
| 8726 | int |
| 8727 | main () |
| 8728 | { |
| 8729 | initscr (); |
| 8730 | ; |
| 8731 | return 0; |
| 8732 | } |
| 8733 | _ACEOF |
| 8734 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 8735 | if { (eval echo "$as_me:8735: \"$ac_link\"") >&5 |
| 8736 | (eval $ac_link) 2>&5 |
| 8737 | ac_status=$? |
| 8738 | echo "$as_me:8738: \$? = $ac_status" >&5 |
| 8739 | (exit $ac_status); } && |
| 8740 | { ac_try='test -s conftest$ac_exeext' |
| 8741 | { (eval echo "$as_me:8741: \"$ac_try\"") >&5 |
| 8742 | (eval $ac_try) 2>&5 |
| 8743 | ac_status=$? |
| 8744 | echo "$as_me:8744: \$? = $ac_status" >&5 |
| 8745 | (exit $ac_status); }; }; then |
| 8746 | ac_cv_lib_gpm_initscr=yes |
| 8747 | else |
| 8748 | echo "$as_me: failed program was:" >&5 |
| 8749 | cat conftest.$ac_ext >&5 |
| 8750 | ac_cv_lib_gpm_initscr=no |
| 8751 | fi |
| 8752 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 8753 | LIBS=$ac_check_lib_save_LIBS |
| 8754 | fi |
| 8755 | echo "$as_me:8755: result: $ac_cv_lib_gpm_initscr" >&5 |
| 8756 | echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6 |
| 8757 | if test $ac_cv_lib_gpm_initscr = yes; then |
| 8758 | LIBS="$cf_ncurses_SAVE" |
| 8759 | else |
| 8760 | cf_ncurses_LIBS="-lgpm" |
| 8761 | fi |
| 8762 | |
| 8763 | fi |
| 8764 | |
| 8765 | case $host_os in |
| 8766 | (freebsd*) |
| 8767 | # This is only necessary if you are linking against an obsolete |
| 8768 | # version of ncurses (but it should do no harm, since it's static). |
| 8769 | if test "$cf_nculib_root" = ncurses ; then |
| 8770 | echo "$as_me:8770: checking for tgoto in -lmytinfo" >&5 |
| 8771 | echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6 |
| 8772 | if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then |
| 8773 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8774 | else |
| 8775 | ac_check_lib_save_LIBS=$LIBS |
| 8776 | LIBS="-lmytinfo $LIBS" |
| 8777 | cat >conftest.$ac_ext <<_ACEOF |
| 8778 | #line 8778 "configure" |
| 8779 | #include "confdefs.h" |
| 8780 | |
| 8781 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 8782 | #ifdef __cplusplus |
| 8783 | extern "C" |
| 8784 | #endif |
| 8785 | /* We use char because int might match the return type of a gcc2 |
| 8786 | builtin and then its argument prototype would still apply. */ |
| 8787 | char tgoto (); |
| 8788 | int |
| 8789 | main () |
| 8790 | { |
| 8791 | tgoto (); |
| 8792 | ; |
| 8793 | return 0; |
| 8794 | } |
| 8795 | _ACEOF |
| 8796 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 8797 | if { (eval echo "$as_me:8797: \"$ac_link\"") >&5 |
| 8798 | (eval $ac_link) 2>&5 |
| 8799 | ac_status=$? |
| 8800 | echo "$as_me:8800: \$? = $ac_status" >&5 |
| 8801 | (exit $ac_status); } && |
| 8802 | { ac_try='test -s conftest$ac_exeext' |
| 8803 | { (eval echo "$as_me:8803: \"$ac_try\"") >&5 |
| 8804 | (eval $ac_try) 2>&5 |
| 8805 | ac_status=$? |
| 8806 | echo "$as_me:8806: \$? = $ac_status" >&5 |
| 8807 | (exit $ac_status); }; }; then |
| 8808 | ac_cv_lib_mytinfo_tgoto=yes |
| 8809 | else |
| 8810 | echo "$as_me: failed program was:" >&5 |
| 8811 | cat conftest.$ac_ext >&5 |
| 8812 | ac_cv_lib_mytinfo_tgoto=no |
| 8813 | fi |
| 8814 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 8815 | LIBS=$ac_check_lib_save_LIBS |
| 8816 | fi |
| 8817 | echo "$as_me:8817: result: $ac_cv_lib_mytinfo_tgoto" >&5 |
| 8818 | echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6 |
| 8819 | if test $ac_cv_lib_mytinfo_tgoto = yes; then |
| 8820 | cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS" |
| 8821 | fi |
| 8822 | |
| 8823 | fi |
| 8824 | ;; |
| 8825 | esac |
| 8826 | |
| 8827 | cf_add_libs="$cf_ncurses_LIBS" |
| 8828 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 8829 | for cf_add_1lib in $LIBS |
| 8830 | do |
| 8831 | for cf_add_2lib in $cf_add_libs |
| 8832 | do |
| 8833 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 8834 | then |
| 8835 | cf_add_1lib= |
| 8836 | break |
| 8837 | fi |
| 8838 | done |
| 8839 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 8840 | done |
| 8841 | LIBS="$cf_add_libs" |
| 8842 | |
| 8843 | if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" ) |
| 8844 | then |
| 8845 | |
| 8846 | cf_add_libs="-l$cf_nculib_root" |
| 8847 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 8848 | for cf_add_1lib in $LIBS |
| 8849 | do |
| 8850 | for cf_add_2lib in $cf_add_libs |
| 8851 | do |
| 8852 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 8853 | then |
| 8854 | cf_add_1lib= |
| 8855 | break |
| 8856 | fi |
| 8857 | done |
| 8858 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 8859 | done |
| 8860 | LIBS="$cf_add_libs" |
| 8861 | |
| 8862 | else |
| 8863 | |
| 8864 | eval 'cf_cv_have_lib_'$cf_nculib_root'=no' |
| 8865 | cf_libdir="" |
| 8866 | echo "$as_me:8866: checking for initscr" >&5 |
| 8867 | echo $ECHO_N "checking for initscr... $ECHO_C" >&6 |
| 8868 | if test "${ac_cv_func_initscr+set}" = set; then |
| 8869 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8870 | else |
| 8871 | cat >conftest.$ac_ext <<_ACEOF |
| 8872 | #line 8872 "configure" |
| 8873 | #include "confdefs.h" |
| 8874 | /* System header to define __stub macros and hopefully few prototypes, |
| 8875 | which can conflict with char initscr (); below. */ |
| 8876 | #include <assert.h> |
| 8877 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 8878 | #ifdef __cplusplus |
| 8879 | extern "C" |
| 8880 | #endif |
| 8881 | /* We use char because int might match the return type of a gcc2 |
| 8882 | builtin and then its argument prototype would still apply. */ |
| 8883 | char initscr (); |
| 8884 | char (*f) (); |
| 8885 | |
| 8886 | int |
| 8887 | main () |
| 8888 | { |
| 8889 | /* The GNU C library defines this for functions which it implements |
| 8890 | to always fail with ENOSYS. Some functions are actually named |
| 8891 | something starting with __ and the normal name is an alias. */ |
| 8892 | #if defined (__stub_initscr) || defined (__stub___initscr) |
| 8893 | choke me |
| 8894 | #else |
| 8895 | f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 8896 | #endif |
| 8897 | |
| 8898 | ; |
| 8899 | return 0; |
| 8900 | } |
| 8901 | _ACEOF |
| 8902 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 8903 | if { (eval echo "$as_me:8903: \"$ac_link\"") >&5 |
| 8904 | (eval $ac_link) 2>&5 |
| 8905 | ac_status=$? |
| 8906 | echo "$as_me:8906: \$? = $ac_status" >&5 |
| 8907 | (exit $ac_status); } && |
| 8908 | { ac_try='test -s conftest$ac_exeext' |
| 8909 | { (eval echo "$as_me:8909: \"$ac_try\"") >&5 |
| 8910 | (eval $ac_try) 2>&5 |
| 8911 | ac_status=$? |
| 8912 | echo "$as_me:8912: \$? = $ac_status" >&5 |
| 8913 | (exit $ac_status); }; }; then |
| 8914 | ac_cv_func_initscr=yes |
| 8915 | else |
| 8916 | echo "$as_me: failed program was:" >&5 |
| 8917 | cat conftest.$ac_ext >&5 |
| 8918 | ac_cv_func_initscr=no |
| 8919 | fi |
| 8920 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 8921 | fi |
| 8922 | echo "$as_me:8922: result: $ac_cv_func_initscr" >&5 |
| 8923 | echo "${ECHO_T}$ac_cv_func_initscr" >&6 |
| 8924 | if test $ac_cv_func_initscr = yes; then |
| 8925 | eval 'cf_cv_have_lib_'$cf_nculib_root'=yes' |
| 8926 | else |
| 8927 | |
| 8928 | cf_save_LIBS="$LIBS" |
| 8929 | echo "$as_me:8929: checking for initscr in -l$cf_nculib_root" >&5 |
| 8930 | echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6 |
| 8931 | LIBS="-l$cf_nculib_root $LIBS" |
| 8932 | cat >conftest.$ac_ext <<_ACEOF |
| 8933 | #line 8933 "configure" |
| 8934 | #include "confdefs.h" |
| 8935 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 8936 | int |
| 8937 | main () |
| 8938 | { |
| 8939 | initscr() |
| 8940 | ; |
| 8941 | return 0; |
| 8942 | } |
| 8943 | _ACEOF |
| 8944 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 8945 | if { (eval echo "$as_me:8945: \"$ac_link\"") >&5 |
| 8946 | (eval $ac_link) 2>&5 |
| 8947 | ac_status=$? |
| 8948 | echo "$as_me:8948: \$? = $ac_status" >&5 |
| 8949 | (exit $ac_status); } && |
| 8950 | { ac_try='test -s conftest$ac_exeext' |
| 8951 | { (eval echo "$as_me:8951: \"$ac_try\"") >&5 |
| 8952 | (eval $ac_try) 2>&5 |
| 8953 | ac_status=$? |
| 8954 | echo "$as_me:8954: \$? = $ac_status" >&5 |
| 8955 | (exit $ac_status); }; }; then |
| 8956 | echo "$as_me:8956: result: yes" >&5 |
| 8957 | echo "${ECHO_T}yes" >&6 |
| 8958 | eval 'cf_cv_have_lib_'$cf_nculib_root'=yes' |
| 8959 | |
| 8960 | else |
| 8961 | echo "$as_me: failed program was:" >&5 |
| 8962 | cat conftest.$ac_ext >&5 |
| 8963 | echo "$as_me:8963: result: no" >&5 |
| 8964 | echo "${ECHO_T}no" >&6 |
| 8965 | |
| 8966 | cf_search= |
| 8967 | cf_library_path_list="" |
| 8968 | if test -n "${LDFLAGS}${LIBS}" ; then |
| 8969 | for cf_library_path in $LDFLAGS $LIBS |
| 8970 | do |
| 8971 | case $cf_library_path in |
| 8972 | (-L*) |
| 8973 | cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'` |
| 8974 | |
| 8975 | test "x$cf_library_path" != "xNONE" && \ |
| 8976 | test -d "$cf_library_path" && \ |
| 8977 | { |
| 8978 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path" |
| 8979 | test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib" |
| 8980 | test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root" |
| 8981 | test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib" |
| 8982 | test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib" |
| 8983 | test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root" |
| 8984 | } |
| 8985 | |
| 8986 | cf_library_path_list="$cf_library_path_list $cf_search" |
| 8987 | ;; |
| 8988 | esac |
| 8989 | done |
| 8990 | fi |
| 8991 | |
| 8992 | cf_search= |
| 8993 | |
| 8994 | test "x$prefix" != "xNONE" && \ |
| 8995 | test -d "$prefix" && \ |
| 8996 | { |
| 8997 | test -n "$verbose" && echo " ... testing for lib-directories under $prefix" |
| 8998 | test -d $prefix/lib && cf_search="$cf_search $prefix/lib" |
| 8999 | test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root" |
| 9000 | test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib" |
| 9001 | test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib" |
| 9002 | test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root" |
| 9003 | } |
| 9004 | |
| 9005 | for cf_subdir_prefix in \ |
| 9006 | /usr \ |
| 9007 | /usr/local \ |
| 9008 | /usr/pkg \ |
| 9009 | /opt \ |
| 9010 | /opt/local \ |
| 9011 | $HOME |
| 9012 | do |
| 9013 | |
| 9014 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 9015 | test -d "$cf_subdir_prefix" && \ |
| 9016 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 9017 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix" |
| 9018 | test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib" |
| 9019 | test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root" |
| 9020 | test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib" |
| 9021 | test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib" |
| 9022 | test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root" |
| 9023 | } |
| 9024 | |
| 9025 | done |
| 9026 | |
| 9027 | cf_search="$cf_library_path_list $cf_search" |
| 9028 | |
| 9029 | for cf_libdir in $cf_search |
| 9030 | do |
| 9031 | echo "$as_me:9031: checking for -l$cf_nculib_root in $cf_libdir" >&5 |
| 9032 | echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6 |
| 9033 | LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS" |
| 9034 | cat >conftest.$ac_ext <<_ACEOF |
| 9035 | #line 9035 "configure" |
| 9036 | #include "confdefs.h" |
| 9037 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 9038 | int |
| 9039 | main () |
| 9040 | { |
| 9041 | initscr() |
| 9042 | ; |
| 9043 | return 0; |
| 9044 | } |
| 9045 | _ACEOF |
| 9046 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9047 | if { (eval echo "$as_me:9047: \"$ac_link\"") >&5 |
| 9048 | (eval $ac_link) 2>&5 |
| 9049 | ac_status=$? |
| 9050 | echo "$as_me:9050: \$? = $ac_status" >&5 |
| 9051 | (exit $ac_status); } && |
| 9052 | { ac_try='test -s conftest$ac_exeext' |
| 9053 | { (eval echo "$as_me:9053: \"$ac_try\"") >&5 |
| 9054 | (eval $ac_try) 2>&5 |
| 9055 | ac_status=$? |
| 9056 | echo "$as_me:9056: \$? = $ac_status" >&5 |
| 9057 | (exit $ac_status); }; }; then |
| 9058 | echo "$as_me:9058: result: yes" >&5 |
| 9059 | echo "${ECHO_T}yes" >&6 |
| 9060 | eval 'cf_cv_have_lib_'$cf_nculib_root'=yes' |
| 9061 | break |
| 9062 | else |
| 9063 | echo "$as_me: failed program was:" >&5 |
| 9064 | cat conftest.$ac_ext >&5 |
| 9065 | echo "$as_me:9065: result: no" >&5 |
| 9066 | echo "${ECHO_T}no" >&6 |
| 9067 | LIBS="$cf_save_LIBS" |
| 9068 | fi |
| 9069 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9070 | done |
| 9071 | |
| 9072 | fi |
| 9073 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9074 | |
| 9075 | fi |
| 9076 | |
| 9077 | eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root |
| 9078 | |
| 9079 | if test $cf_found_library = no ; then |
| 9080 | { { echo "$as_me:9080: error: Cannot link $cf_nculib_root library" >&5 |
| 9081 | echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;} |
| 9082 | { (exit 1); exit 1; }; } |
| 9083 | fi |
| 9084 | |
| 9085 | fi |
| 9086 | |
| 9087 | if test -n "$cf_ncurses_LIBS" ; then |
| 9088 | echo "$as_me:9088: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5 |
| 9089 | echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6 |
| 9090 | cf_ncurses_SAVE="$LIBS" |
| 9091 | for p in $cf_ncurses_LIBS ; do |
| 9092 | q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"` |
| 9093 | if test "$q" != "$LIBS" ; then |
| 9094 | LIBS="$q" |
| 9095 | fi |
| 9096 | done |
| 9097 | cat >conftest.$ac_ext <<_ACEOF |
| 9098 | #line 9098 "configure" |
| 9099 | #include "confdefs.h" |
| 9100 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 9101 | int |
| 9102 | main () |
| 9103 | { |
| 9104 | initscr(); mousemask(0,0); tgoto((char *)0, 0, 0); |
| 9105 | ; |
| 9106 | return 0; |
| 9107 | } |
| 9108 | _ACEOF |
| 9109 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9110 | if { (eval echo "$as_me:9110: \"$ac_link\"") >&5 |
| 9111 | (eval $ac_link) 2>&5 |
| 9112 | ac_status=$? |
| 9113 | echo "$as_me:9113: \$? = $ac_status" >&5 |
| 9114 | (exit $ac_status); } && |
| 9115 | { ac_try='test -s conftest$ac_exeext' |
| 9116 | { (eval echo "$as_me:9116: \"$ac_try\"") >&5 |
| 9117 | (eval $ac_try) 2>&5 |
| 9118 | ac_status=$? |
| 9119 | echo "$as_me:9119: \$? = $ac_status" >&5 |
| 9120 | (exit $ac_status); }; }; then |
| 9121 | echo "$as_me:9121: result: yes" >&5 |
| 9122 | echo "${ECHO_T}yes" >&6 |
| 9123 | else |
| 9124 | echo "$as_me: failed program was:" >&5 |
| 9125 | cat conftest.$ac_ext >&5 |
| 9126 | echo "$as_me:9126: result: no" >&5 |
| 9127 | echo "${ECHO_T}no" >&6 |
| 9128 | LIBS="$cf_ncurses_SAVE" |
| 9129 | fi |
| 9130 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9131 | fi |
| 9132 | |
| 9133 | cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 9134 | |
| 9135 | cat >>confdefs.h <<EOF |
| 9136 | #define $cf_nculib_ROOT 1 |
| 9137 | EOF |
| 9138 | |
| 9139 | fi |
| 9140 | else |
| 9141 | NCURSES_CONFIG=none |
| 9142 | fi |
| 9143 | |
| 9144 | ;; |
| 9145 | (pdcurses) |
| 9146 | echo "$as_me:9146: checking for X" >&5 |
| 9147 | echo $ECHO_N "checking for X... $ECHO_C" >&6 |
| 9148 | |
| 9149 | # Check whether --with-x or --without-x was given. |
| 9150 | if test "${with_x+set}" = set; then |
| 9151 | withval="$with_x" |
| 9152 | |
| 9153 | fi; |
| 9154 | # $have_x is `yes', `no', `disabled', or empty when we do not yet know. |
| 9155 | if test "x$with_x" = xno; then |
| 9156 | # The user explicitly disabled X. |
| 9157 | have_x=disabled |
| 9158 | else |
| 9159 | if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then |
| 9160 | # Both variables are already set. |
| 9161 | have_x=yes |
| 9162 | else |
| 9163 | if test "${ac_cv_have_x+set}" = set; then |
| 9164 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9165 | else |
| 9166 | # One or both of the vars are not set, and there is no cached value. |
| 9167 | ac_x_includes=no ac_x_libraries=no |
| 9168 | rm -fr conftest.dir |
| 9169 | if mkdir conftest.dir; then |
| 9170 | cd conftest.dir |
| 9171 | # Make sure to not put "make" in the Imakefile rules, since we grep it out. |
| 9172 | cat >Imakefile <<'EOF' |
| 9173 | acfindx: |
| 9174 | @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"' |
| 9175 | EOF |
| 9176 | if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then |
| 9177 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. |
| 9178 | eval `${MAKE-make} acfindx 2>/dev/null | grep -v make` |
| 9179 | # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. |
| 9180 | for ac_extension in a so sl dylib dll; do |
| 9181 | if test ! -f $ac_im_usrlibdir/libX11.$ac_extension && |
| 9182 | test -f $ac_im_libdir/libX11.$ac_extension; then |
| 9183 | ac_im_usrlibdir=$ac_im_libdir; break |
| 9184 | fi |
| 9185 | done |
| 9186 | # Screen out bogus values from the imake configuration. They are |
| 9187 | # bogus both because they are the default anyway, and because |
| 9188 | # using them would break gcc on systems where it needs fixed includes. |
| 9189 | case $ac_im_incroot in |
| 9190 | /usr/include) ;; |
| 9191 | *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; |
| 9192 | esac |
| 9193 | case $ac_im_usrlibdir in |
| 9194 | /usr/lib | /lib) ;; |
| 9195 | *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; |
| 9196 | esac |
| 9197 | fi |
| 9198 | cd .. |
| 9199 | rm -fr conftest.dir |
| 9200 | fi |
| 9201 | |
| 9202 | # Standard set of common directories for X headers. |
| 9203 | # Check X11 before X11Rn because it is often a symlink to the current release. |
| 9204 | ac_x_header_dirs=' |
| 9205 | /usr/X11/include |
| 9206 | /usr/X11R6/include |
| 9207 | /usr/X11R5/include |
| 9208 | /usr/X11R4/include |
| 9209 | |
| 9210 | /usr/include/X11 |
| 9211 | /usr/include/X11R6 |
| 9212 | /usr/include/X11R5 |
| 9213 | /usr/include/X11R4 |
| 9214 | |
| 9215 | /usr/local/X11/include |
| 9216 | /usr/local/X11R6/include |
| 9217 | /usr/local/X11R5/include |
| 9218 | /usr/local/X11R4/include |
| 9219 | |
| 9220 | /usr/local/include/X11 |
| 9221 | /usr/local/include/X11R6 |
| 9222 | /usr/local/include/X11R5 |
| 9223 | /usr/local/include/X11R4 |
| 9224 | |
| 9225 | /usr/X386/include |
| 9226 | /usr/x386/include |
| 9227 | /usr/XFree86/include/X11 |
| 9228 | |
| 9229 | /usr/include |
| 9230 | /usr/local/include |
| 9231 | /usr/unsupported/include |
| 9232 | /usr/athena/include |
| 9233 | /usr/local/x11r5/include |
| 9234 | /usr/lpp/Xamples/include |
| 9235 | |
| 9236 | /usr/openwin/include |
| 9237 | /usr/openwin/share/include' |
| 9238 | |
| 9239 | if test "$ac_x_includes" = no; then |
| 9240 | # Guess where to find include files, by looking for Intrinsic.h. |
| 9241 | # First, try using that file with no special directory specified. |
| 9242 | cat >conftest.$ac_ext <<_ACEOF |
| 9243 | #line 9243 "configure" |
| 9244 | #include "confdefs.h" |
| 9245 | #include <X11/Intrinsic.h> |
| 9246 | _ACEOF |
| 9247 | if { (eval echo "$as_me:9247: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 9248 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 9249 | ac_status=$? |
| 9250 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 9251 | rm -f conftest.er1 |
| 9252 | cat conftest.err >&5 |
| 9253 | echo "$as_me:9253: \$? = $ac_status" >&5 |
| 9254 | (exit $ac_status); } >/dev/null; then |
| 9255 | if test -s conftest.err; then |
| 9256 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 9257 | else |
| 9258 | ac_cpp_err= |
| 9259 | fi |
| 9260 | else |
| 9261 | ac_cpp_err=yes |
| 9262 | fi |
| 9263 | if test -z "$ac_cpp_err"; then |
| 9264 | # We can compile using X headers with no special include directory. |
| 9265 | ac_x_includes= |
| 9266 | else |
| 9267 | echo "$as_me: failed program was:" >&5 |
| 9268 | cat conftest.$ac_ext >&5 |
| 9269 | for ac_dir in $ac_x_header_dirs; do |
| 9270 | if test -r "$ac_dir/X11/Intrinsic.h"; then |
| 9271 | ac_x_includes=$ac_dir |
| 9272 | break |
| 9273 | fi |
| 9274 | done |
| 9275 | fi |
| 9276 | rm -f conftest.err conftest.$ac_ext |
| 9277 | fi # $ac_x_includes = no |
| 9278 | |
| 9279 | if test "$ac_x_libraries" = no; then |
| 9280 | # Check for the libraries. |
| 9281 | # See if we find them without any special options. |
| 9282 | # Don't add to $LIBS permanently. |
| 9283 | ac_save_LIBS=$LIBS |
| 9284 | LIBS="-lXt $LIBS" |
| 9285 | cat >conftest.$ac_ext <<_ACEOF |
| 9286 | #line 9286 "configure" |
| 9287 | #include "confdefs.h" |
| 9288 | #include <X11/Intrinsic.h> |
| 9289 | int |
| 9290 | main () |
| 9291 | { |
| 9292 | XtMalloc (0) |
| 9293 | ; |
| 9294 | return 0; |
| 9295 | } |
| 9296 | _ACEOF |
| 9297 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9298 | if { (eval echo "$as_me:9298: \"$ac_link\"") >&5 |
| 9299 | (eval $ac_link) 2>&5 |
| 9300 | ac_status=$? |
| 9301 | echo "$as_me:9301: \$? = $ac_status" >&5 |
| 9302 | (exit $ac_status); } && |
| 9303 | { ac_try='test -s conftest$ac_exeext' |
| 9304 | { (eval echo "$as_me:9304: \"$ac_try\"") >&5 |
| 9305 | (eval $ac_try) 2>&5 |
| 9306 | ac_status=$? |
| 9307 | echo "$as_me:9307: \$? = $ac_status" >&5 |
| 9308 | (exit $ac_status); }; }; then |
| 9309 | LIBS=$ac_save_LIBS |
| 9310 | # We can link X programs with no special library path. |
| 9311 | ac_x_libraries= |
| 9312 | else |
| 9313 | echo "$as_me: failed program was:" >&5 |
| 9314 | cat conftest.$ac_ext >&5 |
| 9315 | LIBS=$ac_save_LIBS |
| 9316 | for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` |
| 9317 | do |
| 9318 | # Don't even attempt the hair of trying to link an X program! |
| 9319 | for ac_extension in a so sl dylib dll; do |
| 9320 | if test -r $ac_dir/libXt.$ac_extension; then |
| 9321 | ac_x_libraries=$ac_dir |
| 9322 | break 2 |
| 9323 | fi |
| 9324 | done |
| 9325 | done |
| 9326 | fi |
| 9327 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9328 | fi # $ac_x_libraries = no |
| 9329 | |
| 9330 | if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then |
| 9331 | # Didn't find X anywhere. Cache the known absence of X. |
| 9332 | ac_cv_have_x="have_x=no" |
| 9333 | else |
| 9334 | # Record where we found X for the cache. |
| 9335 | ac_cv_have_x="have_x=yes \ |
| 9336 | ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries" |
| 9337 | fi |
| 9338 | fi |
| 9339 | |
| 9340 | fi |
| 9341 | eval "$ac_cv_have_x" |
| 9342 | fi # $with_x != no |
| 9343 | |
| 9344 | if test "$have_x" != yes; then |
| 9345 | echo "$as_me:9345: result: $have_x" >&5 |
| 9346 | echo "${ECHO_T}$have_x" >&6 |
| 9347 | no_x=yes |
| 9348 | else |
| 9349 | # If each of the values was on the command line, it overrides each guess. |
| 9350 | test "x$x_includes" = xNONE && x_includes=$ac_x_includes |
| 9351 | test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries |
| 9352 | # Update the cache value to reflect the command line values. |
| 9353 | ac_cv_have_x="have_x=yes \ |
| 9354 | ac_x_includes=$x_includes ac_x_libraries=$x_libraries" |
| 9355 | echo "$as_me:9355: result: libraries $x_libraries, headers $x_includes" >&5 |
| 9356 | echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6 |
| 9357 | fi |
| 9358 | |
| 9359 | if test "$no_x" = yes; then |
| 9360 | # Not all programs may use this symbol, but it does not hurt to define it. |
| 9361 | |
| 9362 | cat >>confdefs.h <<\EOF |
| 9363 | #define X_DISPLAY_MISSING 1 |
| 9364 | EOF |
| 9365 | |
| 9366 | X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= |
| 9367 | else |
| 9368 | if test -n "$x_includes"; then |
| 9369 | X_CFLAGS="$X_CFLAGS -I$x_includes" |
| 9370 | fi |
| 9371 | |
| 9372 | # It would also be nice to do this for all -L options, not just this one. |
| 9373 | if test -n "$x_libraries"; then |
| 9374 | X_LIBS="$X_LIBS -L$x_libraries" |
| 9375 | # For Solaris; some versions of Sun CC require a space after -R and |
| 9376 | # others require no space. Words are not sufficient . . . . |
| 9377 | case `(uname -sr) 2>/dev/null` in |
| 9378 | "SunOS 5"*) |
| 9379 | echo "$as_me:9379: checking whether -R must be followed by a space" >&5 |
| 9380 | echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6 |
| 9381 | ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" |
| 9382 | cat >conftest.$ac_ext <<_ACEOF |
| 9383 | #line 9383 "configure" |
| 9384 | #include "confdefs.h" |
| 9385 | |
| 9386 | int |
| 9387 | main () |
| 9388 | { |
| 9389 | |
| 9390 | ; |
| 9391 | return 0; |
| 9392 | } |
| 9393 | _ACEOF |
| 9394 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9395 | if { (eval echo "$as_me:9395: \"$ac_link\"") >&5 |
| 9396 | (eval $ac_link) 2>&5 |
| 9397 | ac_status=$? |
| 9398 | echo "$as_me:9398: \$? = $ac_status" >&5 |
| 9399 | (exit $ac_status); } && |
| 9400 | { ac_try='test -s conftest$ac_exeext' |
| 9401 | { (eval echo "$as_me:9401: \"$ac_try\"") >&5 |
| 9402 | (eval $ac_try) 2>&5 |
| 9403 | ac_status=$? |
| 9404 | echo "$as_me:9404: \$? = $ac_status" >&5 |
| 9405 | (exit $ac_status); }; }; then |
| 9406 | ac_R_nospace=yes |
| 9407 | else |
| 9408 | echo "$as_me: failed program was:" >&5 |
| 9409 | cat conftest.$ac_ext >&5 |
| 9410 | ac_R_nospace=no |
| 9411 | fi |
| 9412 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9413 | if test $ac_R_nospace = yes; then |
| 9414 | echo "$as_me:9414: result: no" >&5 |
| 9415 | echo "${ECHO_T}no" >&6 |
| 9416 | X_LIBS="$X_LIBS -R$x_libraries" |
| 9417 | else |
| 9418 | LIBS="$ac_xsave_LIBS -R $x_libraries" |
| 9419 | cat >conftest.$ac_ext <<_ACEOF |
| 9420 | #line 9420 "configure" |
| 9421 | #include "confdefs.h" |
| 9422 | |
| 9423 | int |
| 9424 | main () |
| 9425 | { |
| 9426 | |
| 9427 | ; |
| 9428 | return 0; |
| 9429 | } |
| 9430 | _ACEOF |
| 9431 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9432 | if { (eval echo "$as_me:9432: \"$ac_link\"") >&5 |
| 9433 | (eval $ac_link) 2>&5 |
| 9434 | ac_status=$? |
| 9435 | echo "$as_me:9435: \$? = $ac_status" >&5 |
| 9436 | (exit $ac_status); } && |
| 9437 | { ac_try='test -s conftest$ac_exeext' |
| 9438 | { (eval echo "$as_me:9438: \"$ac_try\"") >&5 |
| 9439 | (eval $ac_try) 2>&5 |
| 9440 | ac_status=$? |
| 9441 | echo "$as_me:9441: \$? = $ac_status" >&5 |
| 9442 | (exit $ac_status); }; }; then |
| 9443 | ac_R_space=yes |
| 9444 | else |
| 9445 | echo "$as_me: failed program was:" >&5 |
| 9446 | cat conftest.$ac_ext >&5 |
| 9447 | ac_R_space=no |
| 9448 | fi |
| 9449 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9450 | if test $ac_R_space = yes; then |
| 9451 | echo "$as_me:9451: result: yes" >&5 |
| 9452 | echo "${ECHO_T}yes" >&6 |
| 9453 | X_LIBS="$X_LIBS -R $x_libraries" |
| 9454 | else |
| 9455 | echo "$as_me:9455: result: neither works" >&5 |
| 9456 | echo "${ECHO_T}neither works" >&6 |
| 9457 | fi |
| 9458 | fi |
| 9459 | LIBS=$ac_xsave_LIBS |
| 9460 | esac |
| 9461 | fi |
| 9462 | |
| 9463 | # Check for system-dependent libraries X programs must link with. |
| 9464 | # Do this before checking for the system-independent R6 libraries |
| 9465 | # (-lICE), since we may need -lsocket or whatever for X linking. |
| 9466 | |
| 9467 | if test "$ISC" = yes; then |
| 9468 | X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" |
| 9469 | else |
| 9470 | # Martyn Johnson says this is needed for Ultrix, if the X |
| 9471 | # libraries were built with DECnet support. And Karl Berry says |
| 9472 | # the Alpha needs dnet_stub (dnet does not exist). |
| 9473 | ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" |
| 9474 | cat >conftest.$ac_ext <<_ACEOF |
| 9475 | #line 9475 "configure" |
| 9476 | #include "confdefs.h" |
| 9477 | |
| 9478 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9479 | #ifdef __cplusplus |
| 9480 | extern "C" |
| 9481 | #endif |
| 9482 | /* We use char because int might match the return type of a gcc2 |
| 9483 | builtin and then its argument prototype would still apply. */ |
| 9484 | char XOpenDisplay (); |
| 9485 | int |
| 9486 | main () |
| 9487 | { |
| 9488 | XOpenDisplay (); |
| 9489 | ; |
| 9490 | return 0; |
| 9491 | } |
| 9492 | _ACEOF |
| 9493 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9494 | if { (eval echo "$as_me:9494: \"$ac_link\"") >&5 |
| 9495 | (eval $ac_link) 2>&5 |
| 9496 | ac_status=$? |
| 9497 | echo "$as_me:9497: \$? = $ac_status" >&5 |
| 9498 | (exit $ac_status); } && |
| 9499 | { ac_try='test -s conftest$ac_exeext' |
| 9500 | { (eval echo "$as_me:9500: \"$ac_try\"") >&5 |
| 9501 | (eval $ac_try) 2>&5 |
| 9502 | ac_status=$? |
| 9503 | echo "$as_me:9503: \$? = $ac_status" >&5 |
| 9504 | (exit $ac_status); }; }; then |
| 9505 | : |
| 9506 | else |
| 9507 | echo "$as_me: failed program was:" >&5 |
| 9508 | cat conftest.$ac_ext >&5 |
| 9509 | echo "$as_me:9509: checking for dnet_ntoa in -ldnet" >&5 |
| 9510 | echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6 |
| 9511 | if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then |
| 9512 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9513 | else |
| 9514 | ac_check_lib_save_LIBS=$LIBS |
| 9515 | LIBS="-ldnet $LIBS" |
| 9516 | cat >conftest.$ac_ext <<_ACEOF |
| 9517 | #line 9517 "configure" |
| 9518 | #include "confdefs.h" |
| 9519 | |
| 9520 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9521 | #ifdef __cplusplus |
| 9522 | extern "C" |
| 9523 | #endif |
| 9524 | /* We use char because int might match the return type of a gcc2 |
| 9525 | builtin and then its argument prototype would still apply. */ |
| 9526 | char dnet_ntoa (); |
| 9527 | int |
| 9528 | main () |
| 9529 | { |
| 9530 | dnet_ntoa (); |
| 9531 | ; |
| 9532 | return 0; |
| 9533 | } |
| 9534 | _ACEOF |
| 9535 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9536 | if { (eval echo "$as_me:9536: \"$ac_link\"") >&5 |
| 9537 | (eval $ac_link) 2>&5 |
| 9538 | ac_status=$? |
| 9539 | echo "$as_me:9539: \$? = $ac_status" >&5 |
| 9540 | (exit $ac_status); } && |
| 9541 | { ac_try='test -s conftest$ac_exeext' |
| 9542 | { (eval echo "$as_me:9542: \"$ac_try\"") >&5 |
| 9543 | (eval $ac_try) 2>&5 |
| 9544 | ac_status=$? |
| 9545 | echo "$as_me:9545: \$? = $ac_status" >&5 |
| 9546 | (exit $ac_status); }; }; then |
| 9547 | ac_cv_lib_dnet_dnet_ntoa=yes |
| 9548 | else |
| 9549 | echo "$as_me: failed program was:" >&5 |
| 9550 | cat conftest.$ac_ext >&5 |
| 9551 | ac_cv_lib_dnet_dnet_ntoa=no |
| 9552 | fi |
| 9553 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9554 | LIBS=$ac_check_lib_save_LIBS |
| 9555 | fi |
| 9556 | echo "$as_me:9556: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 |
| 9557 | echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6 |
| 9558 | if test $ac_cv_lib_dnet_dnet_ntoa = yes; then |
| 9559 | X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" |
| 9560 | fi |
| 9561 | |
| 9562 | if test $ac_cv_lib_dnet_dnet_ntoa = no; then |
| 9563 | echo "$as_me:9563: checking for dnet_ntoa in -ldnet_stub" >&5 |
| 9564 | echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6 |
| 9565 | if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then |
| 9566 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9567 | else |
| 9568 | ac_check_lib_save_LIBS=$LIBS |
| 9569 | LIBS="-ldnet_stub $LIBS" |
| 9570 | cat >conftest.$ac_ext <<_ACEOF |
| 9571 | #line 9571 "configure" |
| 9572 | #include "confdefs.h" |
| 9573 | |
| 9574 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9575 | #ifdef __cplusplus |
| 9576 | extern "C" |
| 9577 | #endif |
| 9578 | /* We use char because int might match the return type of a gcc2 |
| 9579 | builtin and then its argument prototype would still apply. */ |
| 9580 | char dnet_ntoa (); |
| 9581 | int |
| 9582 | main () |
| 9583 | { |
| 9584 | dnet_ntoa (); |
| 9585 | ; |
| 9586 | return 0; |
| 9587 | } |
| 9588 | _ACEOF |
| 9589 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9590 | if { (eval echo "$as_me:9590: \"$ac_link\"") >&5 |
| 9591 | (eval $ac_link) 2>&5 |
| 9592 | ac_status=$? |
| 9593 | echo "$as_me:9593: \$? = $ac_status" >&5 |
| 9594 | (exit $ac_status); } && |
| 9595 | { ac_try='test -s conftest$ac_exeext' |
| 9596 | { (eval echo "$as_me:9596: \"$ac_try\"") >&5 |
| 9597 | (eval $ac_try) 2>&5 |
| 9598 | ac_status=$? |
| 9599 | echo "$as_me:9599: \$? = $ac_status" >&5 |
| 9600 | (exit $ac_status); }; }; then |
| 9601 | ac_cv_lib_dnet_stub_dnet_ntoa=yes |
| 9602 | else |
| 9603 | echo "$as_me: failed program was:" >&5 |
| 9604 | cat conftest.$ac_ext >&5 |
| 9605 | ac_cv_lib_dnet_stub_dnet_ntoa=no |
| 9606 | fi |
| 9607 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9608 | LIBS=$ac_check_lib_save_LIBS |
| 9609 | fi |
| 9610 | echo "$as_me:9610: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 |
| 9611 | echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6 |
| 9612 | if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then |
| 9613 | X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" |
| 9614 | fi |
| 9615 | |
| 9616 | fi |
| 9617 | fi |
| 9618 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9619 | LIBS="$ac_xsave_LIBS" |
| 9620 | |
| 9621 | # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, |
| 9622 | # to get the SysV transport functions. |
| 9623 | # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) |
| 9624 | # needs -lnsl. |
| 9625 | # The nsl library prevents programs from opening the X display |
| 9626 | # on Irix 5.2, according to T.E. Dickey. |
| 9627 | # The functions gethostbyname, getservbyname, and inet_addr are |
| 9628 | # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. |
| 9629 | echo "$as_me:9629: checking for gethostbyname" >&5 |
| 9630 | echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6 |
| 9631 | if test "${ac_cv_func_gethostbyname+set}" = set; then |
| 9632 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9633 | else |
| 9634 | cat >conftest.$ac_ext <<_ACEOF |
| 9635 | #line 9635 "configure" |
| 9636 | #include "confdefs.h" |
| 9637 | /* System header to define __stub macros and hopefully few prototypes, |
| 9638 | which can conflict with char gethostbyname (); below. */ |
| 9639 | #include <assert.h> |
| 9640 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9641 | #ifdef __cplusplus |
| 9642 | extern "C" |
| 9643 | #endif |
| 9644 | /* We use char because int might match the return type of a gcc2 |
| 9645 | builtin and then its argument prototype would still apply. */ |
| 9646 | char gethostbyname (); |
| 9647 | char (*f) (); |
| 9648 | |
| 9649 | int |
| 9650 | main () |
| 9651 | { |
| 9652 | /* The GNU C library defines this for functions which it implements |
| 9653 | to always fail with ENOSYS. Some functions are actually named |
| 9654 | something starting with __ and the normal name is an alias. */ |
| 9655 | #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) |
| 9656 | choke me |
| 9657 | #else |
| 9658 | f = gethostbyname; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 9659 | #endif |
| 9660 | |
| 9661 | ; |
| 9662 | return 0; |
| 9663 | } |
| 9664 | _ACEOF |
| 9665 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9666 | if { (eval echo "$as_me:9666: \"$ac_link\"") >&5 |
| 9667 | (eval $ac_link) 2>&5 |
| 9668 | ac_status=$? |
| 9669 | echo "$as_me:9669: \$? = $ac_status" >&5 |
| 9670 | (exit $ac_status); } && |
| 9671 | { ac_try='test -s conftest$ac_exeext' |
| 9672 | { (eval echo "$as_me:9672: \"$ac_try\"") >&5 |
| 9673 | (eval $ac_try) 2>&5 |
| 9674 | ac_status=$? |
| 9675 | echo "$as_me:9675: \$? = $ac_status" >&5 |
| 9676 | (exit $ac_status); }; }; then |
| 9677 | ac_cv_func_gethostbyname=yes |
| 9678 | else |
| 9679 | echo "$as_me: failed program was:" >&5 |
| 9680 | cat conftest.$ac_ext >&5 |
| 9681 | ac_cv_func_gethostbyname=no |
| 9682 | fi |
| 9683 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9684 | fi |
| 9685 | echo "$as_me:9685: result: $ac_cv_func_gethostbyname" >&5 |
| 9686 | echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6 |
| 9687 | |
| 9688 | if test $ac_cv_func_gethostbyname = no; then |
| 9689 | echo "$as_me:9689: checking for gethostbyname in -lnsl" >&5 |
| 9690 | echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6 |
| 9691 | if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then |
| 9692 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9693 | else |
| 9694 | ac_check_lib_save_LIBS=$LIBS |
| 9695 | LIBS="-lnsl $LIBS" |
| 9696 | cat >conftest.$ac_ext <<_ACEOF |
| 9697 | #line 9697 "configure" |
| 9698 | #include "confdefs.h" |
| 9699 | |
| 9700 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9701 | #ifdef __cplusplus |
| 9702 | extern "C" |
| 9703 | #endif |
| 9704 | /* We use char because int might match the return type of a gcc2 |
| 9705 | builtin and then its argument prototype would still apply. */ |
| 9706 | char gethostbyname (); |
| 9707 | int |
| 9708 | main () |
| 9709 | { |
| 9710 | gethostbyname (); |
| 9711 | ; |
| 9712 | return 0; |
| 9713 | } |
| 9714 | _ACEOF |
| 9715 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9716 | if { (eval echo "$as_me:9716: \"$ac_link\"") >&5 |
| 9717 | (eval $ac_link) 2>&5 |
| 9718 | ac_status=$? |
| 9719 | echo "$as_me:9719: \$? = $ac_status" >&5 |
| 9720 | (exit $ac_status); } && |
| 9721 | { ac_try='test -s conftest$ac_exeext' |
| 9722 | { (eval echo "$as_me:9722: \"$ac_try\"") >&5 |
| 9723 | (eval $ac_try) 2>&5 |
| 9724 | ac_status=$? |
| 9725 | echo "$as_me:9725: \$? = $ac_status" >&5 |
| 9726 | (exit $ac_status); }; }; then |
| 9727 | ac_cv_lib_nsl_gethostbyname=yes |
| 9728 | else |
| 9729 | echo "$as_me: failed program was:" >&5 |
| 9730 | cat conftest.$ac_ext >&5 |
| 9731 | ac_cv_lib_nsl_gethostbyname=no |
| 9732 | fi |
| 9733 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9734 | LIBS=$ac_check_lib_save_LIBS |
| 9735 | fi |
| 9736 | echo "$as_me:9736: result: $ac_cv_lib_nsl_gethostbyname" >&5 |
| 9737 | echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6 |
| 9738 | if test $ac_cv_lib_nsl_gethostbyname = yes; then |
| 9739 | X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" |
| 9740 | fi |
| 9741 | |
| 9742 | if test $ac_cv_lib_nsl_gethostbyname = no; then |
| 9743 | echo "$as_me:9743: checking for gethostbyname in -lbsd" >&5 |
| 9744 | echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6 |
| 9745 | if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then |
| 9746 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9747 | else |
| 9748 | ac_check_lib_save_LIBS=$LIBS |
| 9749 | LIBS="-lbsd $LIBS" |
| 9750 | cat >conftest.$ac_ext <<_ACEOF |
| 9751 | #line 9751 "configure" |
| 9752 | #include "confdefs.h" |
| 9753 | |
| 9754 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9755 | #ifdef __cplusplus |
| 9756 | extern "C" |
| 9757 | #endif |
| 9758 | /* We use char because int might match the return type of a gcc2 |
| 9759 | builtin and then its argument prototype would still apply. */ |
| 9760 | char gethostbyname (); |
| 9761 | int |
| 9762 | main () |
| 9763 | { |
| 9764 | gethostbyname (); |
| 9765 | ; |
| 9766 | return 0; |
| 9767 | } |
| 9768 | _ACEOF |
| 9769 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9770 | if { (eval echo "$as_me:9770: \"$ac_link\"") >&5 |
| 9771 | (eval $ac_link) 2>&5 |
| 9772 | ac_status=$? |
| 9773 | echo "$as_me:9773: \$? = $ac_status" >&5 |
| 9774 | (exit $ac_status); } && |
| 9775 | { ac_try='test -s conftest$ac_exeext' |
| 9776 | { (eval echo "$as_me:9776: \"$ac_try\"") >&5 |
| 9777 | (eval $ac_try) 2>&5 |
| 9778 | ac_status=$? |
| 9779 | echo "$as_me:9779: \$? = $ac_status" >&5 |
| 9780 | (exit $ac_status); }; }; then |
| 9781 | ac_cv_lib_bsd_gethostbyname=yes |
| 9782 | else |
| 9783 | echo "$as_me: failed program was:" >&5 |
| 9784 | cat conftest.$ac_ext >&5 |
| 9785 | ac_cv_lib_bsd_gethostbyname=no |
| 9786 | fi |
| 9787 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9788 | LIBS=$ac_check_lib_save_LIBS |
| 9789 | fi |
| 9790 | echo "$as_me:9790: result: $ac_cv_lib_bsd_gethostbyname" >&5 |
| 9791 | echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6 |
| 9792 | if test $ac_cv_lib_bsd_gethostbyname = yes; then |
| 9793 | X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" |
| 9794 | fi |
| 9795 | |
| 9796 | fi |
| 9797 | fi |
| 9798 | |
| 9799 | # lieder@skyler.mavd.honeywell.com says without -lsocket, |
| 9800 | # socket/setsockopt and other routines are undefined under SCO ODT |
| 9801 | # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary |
| 9802 | # on later versions), says Simon Leinen: it contains gethostby* |
| 9803 | # variants that don't use the nameserver (or something). -lsocket |
| 9804 | # must be given before -lnsl if both are needed. We assume that |
| 9805 | # if connect needs -lnsl, so does gethostbyname. |
| 9806 | echo "$as_me:9806: checking for connect" >&5 |
| 9807 | echo $ECHO_N "checking for connect... $ECHO_C" >&6 |
| 9808 | if test "${ac_cv_func_connect+set}" = set; then |
| 9809 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9810 | else |
| 9811 | cat >conftest.$ac_ext <<_ACEOF |
| 9812 | #line 9812 "configure" |
| 9813 | #include "confdefs.h" |
| 9814 | /* System header to define __stub macros and hopefully few prototypes, |
| 9815 | which can conflict with char connect (); below. */ |
| 9816 | #include <assert.h> |
| 9817 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9818 | #ifdef __cplusplus |
| 9819 | extern "C" |
| 9820 | #endif |
| 9821 | /* We use char because int might match the return type of a gcc2 |
| 9822 | builtin and then its argument prototype would still apply. */ |
| 9823 | char connect (); |
| 9824 | char (*f) (); |
| 9825 | |
| 9826 | int |
| 9827 | main () |
| 9828 | { |
| 9829 | /* The GNU C library defines this for functions which it implements |
| 9830 | to always fail with ENOSYS. Some functions are actually named |
| 9831 | something starting with __ and the normal name is an alias. */ |
| 9832 | #if defined (__stub_connect) || defined (__stub___connect) |
| 9833 | choke me |
| 9834 | #else |
| 9835 | f = connect; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 9836 | #endif |
| 9837 | |
| 9838 | ; |
| 9839 | return 0; |
| 9840 | } |
| 9841 | _ACEOF |
| 9842 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9843 | if { (eval echo "$as_me:9843: \"$ac_link\"") >&5 |
| 9844 | (eval $ac_link) 2>&5 |
| 9845 | ac_status=$? |
| 9846 | echo "$as_me:9846: \$? = $ac_status" >&5 |
| 9847 | (exit $ac_status); } && |
| 9848 | { ac_try='test -s conftest$ac_exeext' |
| 9849 | { (eval echo "$as_me:9849: \"$ac_try\"") >&5 |
| 9850 | (eval $ac_try) 2>&5 |
| 9851 | ac_status=$? |
| 9852 | echo "$as_me:9852: \$? = $ac_status" >&5 |
| 9853 | (exit $ac_status); }; }; then |
| 9854 | ac_cv_func_connect=yes |
| 9855 | else |
| 9856 | echo "$as_me: failed program was:" >&5 |
| 9857 | cat conftest.$ac_ext >&5 |
| 9858 | ac_cv_func_connect=no |
| 9859 | fi |
| 9860 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9861 | fi |
| 9862 | echo "$as_me:9862: result: $ac_cv_func_connect" >&5 |
| 9863 | echo "${ECHO_T}$ac_cv_func_connect" >&6 |
| 9864 | |
| 9865 | if test $ac_cv_func_connect = no; then |
| 9866 | echo "$as_me:9866: checking for connect in -lsocket" >&5 |
| 9867 | echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6 |
| 9868 | if test "${ac_cv_lib_socket_connect+set}" = set; then |
| 9869 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9870 | else |
| 9871 | ac_check_lib_save_LIBS=$LIBS |
| 9872 | LIBS="-lsocket $X_EXTRA_LIBS $LIBS" |
| 9873 | cat >conftest.$ac_ext <<_ACEOF |
| 9874 | #line 9874 "configure" |
| 9875 | #include "confdefs.h" |
| 9876 | |
| 9877 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9878 | #ifdef __cplusplus |
| 9879 | extern "C" |
| 9880 | #endif |
| 9881 | /* We use char because int might match the return type of a gcc2 |
| 9882 | builtin and then its argument prototype would still apply. */ |
| 9883 | char connect (); |
| 9884 | int |
| 9885 | main () |
| 9886 | { |
| 9887 | connect (); |
| 9888 | ; |
| 9889 | return 0; |
| 9890 | } |
| 9891 | _ACEOF |
| 9892 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9893 | if { (eval echo "$as_me:9893: \"$ac_link\"") >&5 |
| 9894 | (eval $ac_link) 2>&5 |
| 9895 | ac_status=$? |
| 9896 | echo "$as_me:9896: \$? = $ac_status" >&5 |
| 9897 | (exit $ac_status); } && |
| 9898 | { ac_try='test -s conftest$ac_exeext' |
| 9899 | { (eval echo "$as_me:9899: \"$ac_try\"") >&5 |
| 9900 | (eval $ac_try) 2>&5 |
| 9901 | ac_status=$? |
| 9902 | echo "$as_me:9902: \$? = $ac_status" >&5 |
| 9903 | (exit $ac_status); }; }; then |
| 9904 | ac_cv_lib_socket_connect=yes |
| 9905 | else |
| 9906 | echo "$as_me: failed program was:" >&5 |
| 9907 | cat conftest.$ac_ext >&5 |
| 9908 | ac_cv_lib_socket_connect=no |
| 9909 | fi |
| 9910 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9911 | LIBS=$ac_check_lib_save_LIBS |
| 9912 | fi |
| 9913 | echo "$as_me:9913: result: $ac_cv_lib_socket_connect" >&5 |
| 9914 | echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6 |
| 9915 | if test $ac_cv_lib_socket_connect = yes; then |
| 9916 | X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" |
| 9917 | fi |
| 9918 | |
| 9919 | fi |
| 9920 | |
| 9921 | # Guillermo Gomez says -lposix is necessary on A/UX. |
| 9922 | echo "$as_me:9922: checking for remove" >&5 |
| 9923 | echo $ECHO_N "checking for remove... $ECHO_C" >&6 |
| 9924 | if test "${ac_cv_func_remove+set}" = set; then |
| 9925 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9926 | else |
| 9927 | cat >conftest.$ac_ext <<_ACEOF |
| 9928 | #line 9928 "configure" |
| 9929 | #include "confdefs.h" |
| 9930 | /* System header to define __stub macros and hopefully few prototypes, |
| 9931 | which can conflict with char remove (); below. */ |
| 9932 | #include <assert.h> |
| 9933 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9934 | #ifdef __cplusplus |
| 9935 | extern "C" |
| 9936 | #endif |
| 9937 | /* We use char because int might match the return type of a gcc2 |
| 9938 | builtin and then its argument prototype would still apply. */ |
| 9939 | char remove (); |
| 9940 | char (*f) (); |
| 9941 | |
| 9942 | int |
| 9943 | main () |
| 9944 | { |
| 9945 | /* The GNU C library defines this for functions which it implements |
| 9946 | to always fail with ENOSYS. Some functions are actually named |
| 9947 | something starting with __ and the normal name is an alias. */ |
| 9948 | #if defined (__stub_remove) || defined (__stub___remove) |
| 9949 | choke me |
| 9950 | #else |
| 9951 | f = remove; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 9952 | #endif |
| 9953 | |
| 9954 | ; |
| 9955 | return 0; |
| 9956 | } |
| 9957 | _ACEOF |
| 9958 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9959 | if { (eval echo "$as_me:9959: \"$ac_link\"") >&5 |
| 9960 | (eval $ac_link) 2>&5 |
| 9961 | ac_status=$? |
| 9962 | echo "$as_me:9962: \$? = $ac_status" >&5 |
| 9963 | (exit $ac_status); } && |
| 9964 | { ac_try='test -s conftest$ac_exeext' |
| 9965 | { (eval echo "$as_me:9965: \"$ac_try\"") >&5 |
| 9966 | (eval $ac_try) 2>&5 |
| 9967 | ac_status=$? |
| 9968 | echo "$as_me:9968: \$? = $ac_status" >&5 |
| 9969 | (exit $ac_status); }; }; then |
| 9970 | ac_cv_func_remove=yes |
| 9971 | else |
| 9972 | echo "$as_me: failed program was:" >&5 |
| 9973 | cat conftest.$ac_ext >&5 |
| 9974 | ac_cv_func_remove=no |
| 9975 | fi |
| 9976 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9977 | fi |
| 9978 | echo "$as_me:9978: result: $ac_cv_func_remove" >&5 |
| 9979 | echo "${ECHO_T}$ac_cv_func_remove" >&6 |
| 9980 | |
| 9981 | if test $ac_cv_func_remove = no; then |
| 9982 | echo "$as_me:9982: checking for remove in -lposix" >&5 |
| 9983 | echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6 |
| 9984 | if test "${ac_cv_lib_posix_remove+set}" = set; then |
| 9985 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9986 | else |
| 9987 | ac_check_lib_save_LIBS=$LIBS |
| 9988 | LIBS="-lposix $LIBS" |
| 9989 | cat >conftest.$ac_ext <<_ACEOF |
| 9990 | #line 9990 "configure" |
| 9991 | #include "confdefs.h" |
| 9992 | |
| 9993 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9994 | #ifdef __cplusplus |
| 9995 | extern "C" |
| 9996 | #endif |
| 9997 | /* We use char because int might match the return type of a gcc2 |
| 9998 | builtin and then its argument prototype would still apply. */ |
| 9999 | char remove (); |
| 10000 | int |
| 10001 | main () |
| 10002 | { |
| 10003 | remove (); |
| 10004 | ; |
| 10005 | return 0; |
| 10006 | } |
| 10007 | _ACEOF |
| 10008 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 10009 | if { (eval echo "$as_me:10009: \"$ac_link\"") >&5 |
| 10010 | (eval $ac_link) 2>&5 |
| 10011 | ac_status=$? |
| 10012 | echo "$as_me:10012: \$? = $ac_status" >&5 |
| 10013 | (exit $ac_status); } && |
| 10014 | { ac_try='test -s conftest$ac_exeext' |
| 10015 | { (eval echo "$as_me:10015: \"$ac_try\"") >&5 |
| 10016 | (eval $ac_try) 2>&5 |
| 10017 | ac_status=$? |
| 10018 | echo "$as_me:10018: \$? = $ac_status" >&5 |
| 10019 | (exit $ac_status); }; }; then |
| 10020 | ac_cv_lib_posix_remove=yes |
| 10021 | else |
| 10022 | echo "$as_me: failed program was:" >&5 |
| 10023 | cat conftest.$ac_ext >&5 |
| 10024 | ac_cv_lib_posix_remove=no |
| 10025 | fi |
| 10026 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 10027 | LIBS=$ac_check_lib_save_LIBS |
| 10028 | fi |
| 10029 | echo "$as_me:10029: result: $ac_cv_lib_posix_remove" >&5 |
| 10030 | echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6 |
| 10031 | if test $ac_cv_lib_posix_remove = yes; then |
| 10032 | X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" |
| 10033 | fi |
| 10034 | |
| 10035 | fi |
| 10036 | |
| 10037 | # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. |
| 10038 | echo "$as_me:10038: checking for shmat" >&5 |
| 10039 | echo $ECHO_N "checking for shmat... $ECHO_C" >&6 |
| 10040 | if test "${ac_cv_func_shmat+set}" = set; then |
| 10041 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10042 | else |
| 10043 | cat >conftest.$ac_ext <<_ACEOF |
| 10044 | #line 10044 "configure" |
| 10045 | #include "confdefs.h" |
| 10046 | /* System header to define __stub macros and hopefully few prototypes, |
| 10047 | which can conflict with char shmat (); below. */ |
| 10048 | #include <assert.h> |
| 10049 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 10050 | #ifdef __cplusplus |
| 10051 | extern "C" |
| 10052 | #endif |
| 10053 | /* We use char because int might match the return type of a gcc2 |
| 10054 | builtin and then its argument prototype would still apply. */ |
| 10055 | char shmat (); |
| 10056 | char (*f) (); |
| 10057 | |
| 10058 | int |
| 10059 | main () |
| 10060 | { |
| 10061 | /* The GNU C library defines this for functions which it implements |
| 10062 | to always fail with ENOSYS. Some functions are actually named |
| 10063 | something starting with __ and the normal name is an alias. */ |
| 10064 | #if defined (__stub_shmat) || defined (__stub___shmat) |
| 10065 | choke me |
| 10066 | #else |
| 10067 | f = shmat; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 10068 | #endif |
| 10069 | |
| 10070 | ; |
| 10071 | return 0; |
| 10072 | } |
| 10073 | _ACEOF |
| 10074 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 10075 | if { (eval echo "$as_me:10075: \"$ac_link\"") >&5 |
| 10076 | (eval $ac_link) 2>&5 |
| 10077 | ac_status=$? |
| 10078 | echo "$as_me:10078: \$? = $ac_status" >&5 |
| 10079 | (exit $ac_status); } && |
| 10080 | { ac_try='test -s conftest$ac_exeext' |
| 10081 | { (eval echo "$as_me:10081: \"$ac_try\"") >&5 |
| 10082 | (eval $ac_try) 2>&5 |
| 10083 | ac_status=$? |
| 10084 | echo "$as_me:10084: \$? = $ac_status" >&5 |
| 10085 | (exit $ac_status); }; }; then |
| 10086 | ac_cv_func_shmat=yes |
| 10087 | else |
| 10088 | echo "$as_me: failed program was:" >&5 |
| 10089 | cat conftest.$ac_ext >&5 |
| 10090 | ac_cv_func_shmat=no |
| 10091 | fi |
| 10092 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 10093 | fi |
| 10094 | echo "$as_me:10094: result: $ac_cv_func_shmat" >&5 |
| 10095 | echo "${ECHO_T}$ac_cv_func_shmat" >&6 |
| 10096 | |
| 10097 | if test $ac_cv_func_shmat = no; then |
| 10098 | echo "$as_me:10098: checking for shmat in -lipc" >&5 |
| 10099 | echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6 |
| 10100 | if test "${ac_cv_lib_ipc_shmat+set}" = set; then |
| 10101 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10102 | else |
| 10103 | ac_check_lib_save_LIBS=$LIBS |
| 10104 | LIBS="-lipc $LIBS" |
| 10105 | cat >conftest.$ac_ext <<_ACEOF |
| 10106 | #line 10106 "configure" |
| 10107 | #include "confdefs.h" |
| 10108 | |
| 10109 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 10110 | #ifdef __cplusplus |
| 10111 | extern "C" |
| 10112 | #endif |
| 10113 | /* We use char because int might match the return type of a gcc2 |
| 10114 | builtin and then its argument prototype would still apply. */ |
| 10115 | char shmat (); |
| 10116 | int |
| 10117 | main () |
| 10118 | { |
| 10119 | shmat (); |
| 10120 | ; |
| 10121 | return 0; |
| 10122 | } |
| 10123 | _ACEOF |
| 10124 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 10125 | if { (eval echo "$as_me:10125: \"$ac_link\"") >&5 |
| 10126 | (eval $ac_link) 2>&5 |
| 10127 | ac_status=$? |
| 10128 | echo "$as_me:10128: \$? = $ac_status" >&5 |
| 10129 | (exit $ac_status); } && |
| 10130 | { ac_try='test -s conftest$ac_exeext' |
| 10131 | { (eval echo "$as_me:10131: \"$ac_try\"") >&5 |
| 10132 | (eval $ac_try) 2>&5 |
| 10133 | ac_status=$? |
| 10134 | echo "$as_me:10134: \$? = $ac_status" >&5 |
| 10135 | (exit $ac_status); }; }; then |
| 10136 | ac_cv_lib_ipc_shmat=yes |
| 10137 | else |
| 10138 | echo "$as_me: failed program was:" >&5 |
| 10139 | cat conftest.$ac_ext >&5 |
| 10140 | ac_cv_lib_ipc_shmat=no |
| 10141 | fi |
| 10142 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 10143 | LIBS=$ac_check_lib_save_LIBS |
| 10144 | fi |
| 10145 | echo "$as_me:10145: result: $ac_cv_lib_ipc_shmat" >&5 |
| 10146 | echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6 |
| 10147 | if test $ac_cv_lib_ipc_shmat = yes; then |
| 10148 | X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" |
| 10149 | fi |
| 10150 | |
| 10151 | fi |
| 10152 | fi |
| 10153 | |
| 10154 | # Check for libraries that X11R6 Xt/Xaw programs need. |
| 10155 | ac_save_LDFLAGS=$LDFLAGS |
| 10156 | test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" |
| 10157 | # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to |
| 10158 | # check for ICE first), but we must link in the order -lSM -lICE or |
| 10159 | # we get undefined symbols. So assume we have SM if we have ICE. |
| 10160 | # These have to be linked with before -lX11, unlike the other |
| 10161 | # libraries we check for below, so use a different variable. |
| 10162 | # John Interrante, Karl Berry |
| 10163 | echo "$as_me:10163: checking for IceConnectionNumber in -lICE" >&5 |
| 10164 | echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6 |
| 10165 | if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then |
| 10166 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10167 | else |
| 10168 | ac_check_lib_save_LIBS=$LIBS |
| 10169 | LIBS="-lICE $X_EXTRA_LIBS $LIBS" |
| 10170 | cat >conftest.$ac_ext <<_ACEOF |
| 10171 | #line 10171 "configure" |
| 10172 | #include "confdefs.h" |
| 10173 | |
| 10174 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 10175 | #ifdef __cplusplus |
| 10176 | extern "C" |
| 10177 | #endif |
| 10178 | /* We use char because int might match the return type of a gcc2 |
| 10179 | builtin and then its argument prototype would still apply. */ |
| 10180 | char IceConnectionNumber (); |
| 10181 | int |
| 10182 | main () |
| 10183 | { |
| 10184 | IceConnectionNumber (); |
| 10185 | ; |
| 10186 | return 0; |
| 10187 | } |
| 10188 | _ACEOF |
| 10189 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 10190 | if { (eval echo "$as_me:10190: \"$ac_link\"") >&5 |
| 10191 | (eval $ac_link) 2>&5 |
| 10192 | ac_status=$? |
| 10193 | echo "$as_me:10193: \$? = $ac_status" >&5 |
| 10194 | (exit $ac_status); } && |
| 10195 | { ac_try='test -s conftest$ac_exeext' |
| 10196 | { (eval echo "$as_me:10196: \"$ac_try\"") >&5 |
| 10197 | (eval $ac_try) 2>&5 |
| 10198 | ac_status=$? |
| 10199 | echo "$as_me:10199: \$? = $ac_status" >&5 |
| 10200 | (exit $ac_status); }; }; then |
| 10201 | ac_cv_lib_ICE_IceConnectionNumber=yes |
| 10202 | else |
| 10203 | echo "$as_me: failed program was:" >&5 |
| 10204 | cat conftest.$ac_ext >&5 |
| 10205 | ac_cv_lib_ICE_IceConnectionNumber=no |
| 10206 | fi |
| 10207 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 10208 | LIBS=$ac_check_lib_save_LIBS |
| 10209 | fi |
| 10210 | echo "$as_me:10210: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 |
| 10211 | echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6 |
| 10212 | if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then |
| 10213 | X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" |
| 10214 | fi |
| 10215 | |
| 10216 | LDFLAGS=$ac_save_LDFLAGS |
| 10217 | |
| 10218 | fi |
| 10219 | |
| 10220 | cf_x_athena=${cf_x_athena:-Xaw} |
| 10221 | |
| 10222 | echo "$as_me:10222: checking if you want to link with Xaw 3d library" >&5 |
| 10223 | echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6 |
| 10224 | withval= |
| 10225 | |
| 10226 | # Check whether --with-Xaw3d or --without-Xaw3d was given. |
| 10227 | if test "${with_Xaw3d+set}" = set; then |
| 10228 | withval="$with_Xaw3d" |
| 10229 | |
| 10230 | fi; |
| 10231 | if test "$withval" = yes ; then |
| 10232 | cf_x_athena=Xaw3d |
| 10233 | echo "$as_me:10233: result: yes" >&5 |
| 10234 | echo "${ECHO_T}yes" >&6 |
| 10235 | else |
| 10236 | echo "$as_me:10236: result: no" >&5 |
| 10237 | echo "${ECHO_T}no" >&6 |
| 10238 | fi |
| 10239 | |
| 10240 | echo "$as_me:10240: checking if you want to link with Xaw 3d xft library" >&5 |
| 10241 | echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6 |
| 10242 | withval= |
| 10243 | |
| 10244 | # Check whether --with-Xaw3dxft or --without-Xaw3dxft was given. |
| 10245 | if test "${with_Xaw3dxft+set}" = set; then |
| 10246 | withval="$with_Xaw3dxft" |
| 10247 | |
| 10248 | fi; |
| 10249 | if test "$withval" = yes ; then |
| 10250 | cf_x_athena=Xaw3dxft |
| 10251 | echo "$as_me:10251: result: yes" >&5 |
| 10252 | echo "${ECHO_T}yes" >&6 |
| 10253 | else |
| 10254 | echo "$as_me:10254: result: no" >&5 |
| 10255 | echo "${ECHO_T}no" >&6 |
| 10256 | fi |
| 10257 | |
| 10258 | echo "$as_me:10258: checking if you want to link with neXT Athena library" >&5 |
| 10259 | echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6 |
| 10260 | withval= |
| 10261 | |
| 10262 | # Check whether --with-neXtaw or --without-neXtaw was given. |
| 10263 | if test "${with_neXtaw+set}" = set; then |
| 10264 | withval="$with_neXtaw" |
| 10265 | |
| 10266 | fi; |
| 10267 | if test "$withval" = yes ; then |
| 10268 | cf_x_athena=neXtaw |
| 10269 | echo "$as_me:10269: result: yes" >&5 |
| 10270 | echo "${ECHO_T}yes" >&6 |
| 10271 | else |
| 10272 | echo "$as_me:10272: result: no" >&5 |
| 10273 | echo "${ECHO_T}no" >&6 |
| 10274 | fi |
| 10275 | |
| 10276 | echo "$as_me:10276: checking if you want to link with Athena-Plus library" >&5 |
| 10277 | echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6 |
| 10278 | withval= |
| 10279 | |
| 10280 | # Check whether --with-XawPlus or --without-XawPlus was given. |
| 10281 | if test "${with_XawPlus+set}" = set; then |
| 10282 | withval="$with_XawPlus" |
| 10283 | |
| 10284 | fi; |
| 10285 | if test "$withval" = yes ; then |
| 10286 | cf_x_athena=XawPlus |
| 10287 | echo "$as_me:10287: result: yes" >&5 |
| 10288 | echo "${ECHO_T}yes" >&6 |
| 10289 | else |
| 10290 | echo "$as_me:10290: result: no" >&5 |
| 10291 | echo "${ECHO_T}no" >&6 |
| 10292 | fi |
| 10293 | |
| 10294 | cf_x_athena_lib="" |
| 10295 | |
| 10296 | if test "$PKG_CONFIG" != none ; then |
| 10297 | cf_athena_list= |
| 10298 | test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6" |
| 10299 | for cf_athena_pkg in \ |
| 10300 | $cf_athena_list \ |
| 10301 | ${cf_x_athena} \ |
| 10302 | ${cf_x_athena}-devel \ |
| 10303 | lib${cf_x_athena} \ |
| 10304 | lib${cf_x_athena}-devel |
| 10305 | do |
| 10306 | |
| 10307 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then |
| 10308 | test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6 |
| 10309 | |
| 10310 | echo "${as_me:-configure}:10310: testing found package $cf_athena_pkg ..." 1>&5 |
| 10311 | |
| 10312 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`" |
| 10313 | cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`" |
| 10314 | test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 10315 | |
| 10316 | echo "${as_me:-configure}:10316: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 10317 | |
| 10318 | test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6 |
| 10319 | |
| 10320 | echo "${as_me:-configure}:10320: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 10321 | |
| 10322 | cf_fix_cppflags=no |
| 10323 | cf_new_cflags= |
| 10324 | cf_new_cppflags= |
| 10325 | cf_new_extra_cppflags= |
| 10326 | |
| 10327 | for cf_add_cflags in $cf_pkgconfig_incs |
| 10328 | do |
| 10329 | case $cf_fix_cppflags in |
| 10330 | (no) |
| 10331 | case $cf_add_cflags in |
| 10332 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 10333 | case $cf_add_cflags in |
| 10334 | (-D*) |
| 10335 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 10336 | |
| 10337 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 10338 | && test -z "${cf_tst_cflags}" \ |
| 10339 | && cf_fix_cppflags=yes |
| 10340 | |
| 10341 | if test $cf_fix_cppflags = yes ; then |
| 10342 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10343 | continue |
| 10344 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 10345 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10346 | continue |
| 10347 | fi |
| 10348 | ;; |
| 10349 | esac |
| 10350 | case "$CPPFLAGS" in |
| 10351 | (*$cf_add_cflags) |
| 10352 | ;; |
| 10353 | (*) |
| 10354 | case $cf_add_cflags in |
| 10355 | (-D*) |
| 10356 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 10357 | |
| 10358 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 10359 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 10360 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 10361 | |
| 10362 | ;; |
| 10363 | esac |
| 10364 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 10365 | ;; |
| 10366 | esac |
| 10367 | ;; |
| 10368 | (*) |
| 10369 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 10370 | ;; |
| 10371 | esac |
| 10372 | ;; |
| 10373 | (yes) |
| 10374 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10375 | |
| 10376 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 10377 | |
| 10378 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 10379 | && test -z "${cf_tst_cflags}" \ |
| 10380 | && cf_fix_cppflags=no |
| 10381 | ;; |
| 10382 | esac |
| 10383 | done |
| 10384 | |
| 10385 | if test -n "$cf_new_cflags" ; then |
| 10386 | |
| 10387 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 10388 | fi |
| 10389 | |
| 10390 | if test -n "$cf_new_cppflags" ; then |
| 10391 | |
| 10392 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 10393 | fi |
| 10394 | |
| 10395 | if test -n "$cf_new_extra_cppflags" ; then |
| 10396 | |
| 10397 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 10398 | fi |
| 10399 | |
| 10400 | cf_add_libs="$cf_pkgconfig_libs" |
| 10401 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 10402 | for cf_add_1lib in $LIBS |
| 10403 | do |
| 10404 | for cf_add_2lib in $cf_add_libs |
| 10405 | do |
| 10406 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 10407 | then |
| 10408 | cf_add_1lib= |
| 10409 | break |
| 10410 | fi |
| 10411 | done |
| 10412 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 10413 | done |
| 10414 | LIBS="$cf_add_libs" |
| 10415 | |
| 10416 | cf_x_athena_lib="$cf_pkgconfig_libs" |
| 10417 | |
| 10418 | cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 10419 | |
| 10420 | cat >>confdefs.h <<EOF |
| 10421 | #define $cf_x_athena_LIBS 1 |
| 10422 | EOF |
| 10423 | |
| 10424 | for cf_trim_lib in Xmu Xt X11 |
| 10425 | do |
| 10426 | case "$LIBS" in |
| 10427 | (*-l$cf_trim_lib\ *-l$cf_trim_lib*) |
| 10428 | LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'` |
| 10429 | test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6 |
| 10430 | |
| 10431 | echo "${as_me:-configure}:10431: testing ..trimmed $LIBS ..." 1>&5 |
| 10432 | |
| 10433 | ;; |
| 10434 | esac |
| 10435 | done |
| 10436 | |
| 10437 | echo "$as_me:10437: checking for usable $cf_x_athena/Xmu package" >&5 |
| 10438 | echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6 |
| 10439 | if test "${cf_cv_xaw_compat+set}" = set; then |
| 10440 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10441 | else |
| 10442 | |
| 10443 | cat >conftest.$ac_ext <<_ACEOF |
| 10444 | #line 10444 "configure" |
| 10445 | #include "confdefs.h" |
| 10446 | |
| 10447 | #include <X11/Xmu/CharSet.h> |
| 10448 | |
| 10449 | int |
| 10450 | main () |
| 10451 | { |
| 10452 | |
| 10453 | int check = XmuCompareISOLatin1("big", "small") |
| 10454 | |
| 10455 | ; |
| 10456 | return 0; |
| 10457 | } |
| 10458 | _ACEOF |
| 10459 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 10460 | if { (eval echo "$as_me:10460: \"$ac_link\"") >&5 |
| 10461 | (eval $ac_link) 2>&5 |
| 10462 | ac_status=$? |
| 10463 | echo "$as_me:10463: \$? = $ac_status" >&5 |
| 10464 | (exit $ac_status); } && |
| 10465 | { ac_try='test -s conftest$ac_exeext' |
| 10466 | { (eval echo "$as_me:10466: \"$ac_try\"") >&5 |
| 10467 | (eval $ac_try) 2>&5 |
| 10468 | ac_status=$? |
| 10469 | echo "$as_me:10469: \$? = $ac_status" >&5 |
| 10470 | (exit $ac_status); }; }; then |
| 10471 | cf_cv_xaw_compat=yes |
| 10472 | else |
| 10473 | echo "$as_me: failed program was:" >&5 |
| 10474 | cat conftest.$ac_ext >&5 |
| 10475 | cf_cv_xaw_compat=no |
| 10476 | fi |
| 10477 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 10478 | fi |
| 10479 | echo "$as_me:10479: result: $cf_cv_xaw_compat" >&5 |
| 10480 | echo "${ECHO_T}$cf_cv_xaw_compat" >&6 |
| 10481 | |
| 10482 | if test "$cf_cv_xaw_compat" = no |
| 10483 | then |
| 10484 | # workaround for broken ".pc" files... |
| 10485 | case "$cf_x_athena_lib" in |
| 10486 | (*-lXmu*) |
| 10487 | ;; |
| 10488 | (*) |
| 10489 | test -n "$verbose" && echo " work around broken package" 1>&6 |
| 10490 | |
| 10491 | echo "${as_me:-configure}:10491: testing work around broken package ..." 1>&5 |
| 10492 | |
| 10493 | cf_save_xmu="$LIBS" |
| 10494 | cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'` |
| 10495 | |
| 10496 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then |
| 10497 | test -n "$verbose" && echo " found package xmu" 1>&6 |
| 10498 | |
| 10499 | echo "${as_me:-configure}:10499: testing found package xmu ..." 1>&5 |
| 10500 | |
| 10501 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`" |
| 10502 | cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`" |
| 10503 | test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 10504 | |
| 10505 | echo "${as_me:-configure}:10505: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 10506 | |
| 10507 | test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6 |
| 10508 | |
| 10509 | echo "${as_me:-configure}:10509: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 10510 | |
| 10511 | cf_fix_cppflags=no |
| 10512 | cf_new_cflags= |
| 10513 | cf_new_cppflags= |
| 10514 | cf_new_extra_cppflags= |
| 10515 | |
| 10516 | for cf_add_cflags in $cf_pkgconfig_incs |
| 10517 | do |
| 10518 | case $cf_fix_cppflags in |
| 10519 | (no) |
| 10520 | case $cf_add_cflags in |
| 10521 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 10522 | case $cf_add_cflags in |
| 10523 | (-D*) |
| 10524 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 10525 | |
| 10526 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 10527 | && test -z "${cf_tst_cflags}" \ |
| 10528 | && cf_fix_cppflags=yes |
| 10529 | |
| 10530 | if test $cf_fix_cppflags = yes ; then |
| 10531 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10532 | continue |
| 10533 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 10534 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10535 | continue |
| 10536 | fi |
| 10537 | ;; |
| 10538 | esac |
| 10539 | case "$CPPFLAGS" in |
| 10540 | (*$cf_add_cflags) |
| 10541 | ;; |
| 10542 | (*) |
| 10543 | case $cf_add_cflags in |
| 10544 | (-D*) |
| 10545 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 10546 | |
| 10547 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 10548 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 10549 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 10550 | |
| 10551 | ;; |
| 10552 | esac |
| 10553 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 10554 | ;; |
| 10555 | esac |
| 10556 | ;; |
| 10557 | (*) |
| 10558 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 10559 | ;; |
| 10560 | esac |
| 10561 | ;; |
| 10562 | (yes) |
| 10563 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10564 | |
| 10565 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 10566 | |
| 10567 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 10568 | && test -z "${cf_tst_cflags}" \ |
| 10569 | && cf_fix_cppflags=no |
| 10570 | ;; |
| 10571 | esac |
| 10572 | done |
| 10573 | |
| 10574 | if test -n "$cf_new_cflags" ; then |
| 10575 | |
| 10576 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 10577 | fi |
| 10578 | |
| 10579 | if test -n "$cf_new_cppflags" ; then |
| 10580 | |
| 10581 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 10582 | fi |
| 10583 | |
| 10584 | if test -n "$cf_new_extra_cppflags" ; then |
| 10585 | |
| 10586 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 10587 | fi |
| 10588 | |
| 10589 | cf_add_libs="$cf_pkgconfig_libs" |
| 10590 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 10591 | for cf_add_1lib in $LIBS |
| 10592 | do |
| 10593 | for cf_add_2lib in $cf_add_libs |
| 10594 | do |
| 10595 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 10596 | then |
| 10597 | cf_add_1lib= |
| 10598 | break |
| 10599 | fi |
| 10600 | done |
| 10601 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 10602 | done |
| 10603 | LIBS="$cf_add_libs" |
| 10604 | |
| 10605 | LIBS="$cf_save_xmu" |
| 10606 | |
| 10607 | test -n "$verbose" && echo " ...before $LIBS" 1>&6 |
| 10608 | |
| 10609 | echo "${as_me:-configure}:10609: testing ...before $LIBS ..." 1>&5 |
| 10610 | |
| 10611 | LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'` |
| 10612 | test -n "$verbose" && echo " ...after $LIBS" 1>&6 |
| 10613 | |
| 10614 | echo "${as_me:-configure}:10614: testing ...after $LIBS ..." 1>&5 |
| 10615 | |
| 10616 | else |
| 10617 | cf_pkgconfig_incs= |
| 10618 | cf_pkgconfig_libs= |
| 10619 | |
| 10620 | test -n "$verbose" && echo " ...before $LIBS" 1>&6 |
| 10621 | |
| 10622 | echo "${as_me:-configure}:10622: testing ...before $LIBS ..." 1>&5 |
| 10623 | |
| 10624 | LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'` |
| 10625 | test -n "$verbose" && echo " ...after $LIBS" 1>&6 |
| 10626 | |
| 10627 | echo "${as_me:-configure}:10627: testing ...after $LIBS ..." 1>&5 |
| 10628 | |
| 10629 | fi |
| 10630 | |
| 10631 | for cf_trim_lib in Xmu Xt X11 |
| 10632 | do |
| 10633 | case "$LIBS" in |
| 10634 | (*-l$cf_trim_lib\ *-l$cf_trim_lib*) |
| 10635 | LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'` |
| 10636 | test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6 |
| 10637 | |
| 10638 | echo "${as_me:-configure}:10638: testing ..trimmed $LIBS ..." 1>&5 |
| 10639 | |
| 10640 | ;; |
| 10641 | esac |
| 10642 | done |
| 10643 | |
| 10644 | ;; |
| 10645 | esac |
| 10646 | fi |
| 10647 | |
| 10648 | break |
| 10649 | else |
| 10650 | cf_pkgconfig_incs= |
| 10651 | cf_pkgconfig_libs= |
| 10652 | : |
| 10653 | fi |
| 10654 | |
| 10655 | done |
| 10656 | fi |
| 10657 | |
| 10658 | if test -z "$cf_x_athena_lib" ; then |
| 10659 | |
| 10660 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then |
| 10661 | test -n "$verbose" && echo " found package Xext" 1>&6 |
| 10662 | |
| 10663 | echo "${as_me:-configure}:10663: testing found package Xext ..." 1>&5 |
| 10664 | |
| 10665 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`" |
| 10666 | cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`" |
| 10667 | test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 10668 | |
| 10669 | echo "${as_me:-configure}:10669: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 10670 | |
| 10671 | test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6 |
| 10672 | |
| 10673 | echo "${as_me:-configure}:10673: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 10674 | |
| 10675 | cf_fix_cppflags=no |
| 10676 | cf_new_cflags= |
| 10677 | cf_new_cppflags= |
| 10678 | cf_new_extra_cppflags= |
| 10679 | |
| 10680 | for cf_add_cflags in $cf_pkgconfig_incs |
| 10681 | do |
| 10682 | case $cf_fix_cppflags in |
| 10683 | (no) |
| 10684 | case $cf_add_cflags in |
| 10685 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 10686 | case $cf_add_cflags in |
| 10687 | (-D*) |
| 10688 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 10689 | |
| 10690 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 10691 | && test -z "${cf_tst_cflags}" \ |
| 10692 | && cf_fix_cppflags=yes |
| 10693 | |
| 10694 | if test $cf_fix_cppflags = yes ; then |
| 10695 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10696 | continue |
| 10697 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 10698 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10699 | continue |
| 10700 | fi |
| 10701 | ;; |
| 10702 | esac |
| 10703 | case "$CPPFLAGS" in |
| 10704 | (*$cf_add_cflags) |
| 10705 | ;; |
| 10706 | (*) |
| 10707 | case $cf_add_cflags in |
| 10708 | (-D*) |
| 10709 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 10710 | |
| 10711 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 10712 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 10713 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 10714 | |
| 10715 | ;; |
| 10716 | esac |
| 10717 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 10718 | ;; |
| 10719 | esac |
| 10720 | ;; |
| 10721 | (*) |
| 10722 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 10723 | ;; |
| 10724 | esac |
| 10725 | ;; |
| 10726 | (yes) |
| 10727 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10728 | |
| 10729 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 10730 | |
| 10731 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 10732 | && test -z "${cf_tst_cflags}" \ |
| 10733 | && cf_fix_cppflags=no |
| 10734 | ;; |
| 10735 | esac |
| 10736 | done |
| 10737 | |
| 10738 | if test -n "$cf_new_cflags" ; then |
| 10739 | |
| 10740 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 10741 | fi |
| 10742 | |
| 10743 | if test -n "$cf_new_cppflags" ; then |
| 10744 | |
| 10745 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 10746 | fi |
| 10747 | |
| 10748 | if test -n "$cf_new_extra_cppflags" ; then |
| 10749 | |
| 10750 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 10751 | fi |
| 10752 | |
| 10753 | cf_add_libs="$cf_pkgconfig_libs" |
| 10754 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 10755 | for cf_add_1lib in $LIBS |
| 10756 | do |
| 10757 | for cf_add_2lib in $cf_add_libs |
| 10758 | do |
| 10759 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 10760 | then |
| 10761 | cf_add_1lib= |
| 10762 | break |
| 10763 | fi |
| 10764 | done |
| 10765 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 10766 | done |
| 10767 | LIBS="$cf_add_libs" |
| 10768 | |
| 10769 | : |
| 10770 | else |
| 10771 | cf_pkgconfig_incs= |
| 10772 | cf_pkgconfig_libs= |
| 10773 | |
| 10774 | echo "$as_me:10774: checking for XextCreateExtension in -lXext" >&5 |
| 10775 | echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6 |
| 10776 | if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then |
| 10777 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10778 | else |
| 10779 | ac_check_lib_save_LIBS=$LIBS |
| 10780 | LIBS="-lXext $LIBS" |
| 10781 | cat >conftest.$ac_ext <<_ACEOF |
| 10782 | #line 10782 "configure" |
| 10783 | #include "confdefs.h" |
| 10784 | |
| 10785 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 10786 | #ifdef __cplusplus |
| 10787 | extern "C" |
| 10788 | #endif |
| 10789 | /* We use char because int might match the return type of a gcc2 |
| 10790 | builtin and then its argument prototype would still apply. */ |
| 10791 | char XextCreateExtension (); |
| 10792 | int |
| 10793 | main () |
| 10794 | { |
| 10795 | XextCreateExtension (); |
| 10796 | ; |
| 10797 | return 0; |
| 10798 | } |
| 10799 | _ACEOF |
| 10800 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 10801 | if { (eval echo "$as_me:10801: \"$ac_link\"") >&5 |
| 10802 | (eval $ac_link) 2>&5 |
| 10803 | ac_status=$? |
| 10804 | echo "$as_me:10804: \$? = $ac_status" >&5 |
| 10805 | (exit $ac_status); } && |
| 10806 | { ac_try='test -s conftest$ac_exeext' |
| 10807 | { (eval echo "$as_me:10807: \"$ac_try\"") >&5 |
| 10808 | (eval $ac_try) 2>&5 |
| 10809 | ac_status=$? |
| 10810 | echo "$as_me:10810: \$? = $ac_status" >&5 |
| 10811 | (exit $ac_status); }; }; then |
| 10812 | ac_cv_lib_Xext_XextCreateExtension=yes |
| 10813 | else |
| 10814 | echo "$as_me: failed program was:" >&5 |
| 10815 | cat conftest.$ac_ext >&5 |
| 10816 | ac_cv_lib_Xext_XextCreateExtension=no |
| 10817 | fi |
| 10818 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 10819 | LIBS=$ac_check_lib_save_LIBS |
| 10820 | fi |
| 10821 | echo "$as_me:10821: result: $ac_cv_lib_Xext_XextCreateExtension" >&5 |
| 10822 | echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6 |
| 10823 | if test $ac_cv_lib_Xext_XextCreateExtension = yes; then |
| 10824 | |
| 10825 | cf_add_libs="-lXext" |
| 10826 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 10827 | for cf_add_1lib in $LIBS |
| 10828 | do |
| 10829 | for cf_add_2lib in $cf_add_libs |
| 10830 | do |
| 10831 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 10832 | then |
| 10833 | cf_add_1lib= |
| 10834 | break |
| 10835 | fi |
| 10836 | done |
| 10837 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 10838 | done |
| 10839 | LIBS="$cf_add_libs" |
| 10840 | |
| 10841 | fi |
| 10842 | |
| 10843 | fi |
| 10844 | |
| 10845 | # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new), and (and |
| 10846 | # in some cases has installed dummy files in the former, other cases replaced |
| 10847 | # it with a link to the new location). This complicates the configure script. |
| 10848 | # Check for that pitfall, and recover using pkg-config |
| 10849 | # |
| 10850 | # If none of these are set, the configuration is almost certainly broken. |
| 10851 | if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}" |
| 10852 | then |
| 10853 | |
| 10854 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then |
| 10855 | test -n "$verbose" && echo " found package x11" 1>&6 |
| 10856 | |
| 10857 | echo "${as_me:-configure}:10857: testing found package x11 ..." 1>&5 |
| 10858 | |
| 10859 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`" |
| 10860 | cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`" |
| 10861 | test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 10862 | |
| 10863 | echo "${as_me:-configure}:10863: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 10864 | |
| 10865 | test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6 |
| 10866 | |
| 10867 | echo "${as_me:-configure}:10867: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 10868 | |
| 10869 | cf_fix_cppflags=no |
| 10870 | cf_new_cflags= |
| 10871 | cf_new_cppflags= |
| 10872 | cf_new_extra_cppflags= |
| 10873 | |
| 10874 | for cf_add_cflags in $cf_pkgconfig_incs |
| 10875 | do |
| 10876 | case $cf_fix_cppflags in |
| 10877 | (no) |
| 10878 | case $cf_add_cflags in |
| 10879 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 10880 | case $cf_add_cflags in |
| 10881 | (-D*) |
| 10882 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 10883 | |
| 10884 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 10885 | && test -z "${cf_tst_cflags}" \ |
| 10886 | && cf_fix_cppflags=yes |
| 10887 | |
| 10888 | if test $cf_fix_cppflags = yes ; then |
| 10889 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10890 | continue |
| 10891 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 10892 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10893 | continue |
| 10894 | fi |
| 10895 | ;; |
| 10896 | esac |
| 10897 | case "$CPPFLAGS" in |
| 10898 | (*$cf_add_cflags) |
| 10899 | ;; |
| 10900 | (*) |
| 10901 | case $cf_add_cflags in |
| 10902 | (-D*) |
| 10903 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 10904 | |
| 10905 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 10906 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 10907 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 10908 | |
| 10909 | ;; |
| 10910 | esac |
| 10911 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 10912 | ;; |
| 10913 | esac |
| 10914 | ;; |
| 10915 | (*) |
| 10916 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 10917 | ;; |
| 10918 | esac |
| 10919 | ;; |
| 10920 | (yes) |
| 10921 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 10922 | |
| 10923 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 10924 | |
| 10925 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 10926 | && test -z "${cf_tst_cflags}" \ |
| 10927 | && cf_fix_cppflags=no |
| 10928 | ;; |
| 10929 | esac |
| 10930 | done |
| 10931 | |
| 10932 | if test -n "$cf_new_cflags" ; then |
| 10933 | |
| 10934 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 10935 | fi |
| 10936 | |
| 10937 | if test -n "$cf_new_cppflags" ; then |
| 10938 | |
| 10939 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 10940 | fi |
| 10941 | |
| 10942 | if test -n "$cf_new_extra_cppflags" ; then |
| 10943 | |
| 10944 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 10945 | fi |
| 10946 | |
| 10947 | cf_add_libs="$cf_pkgconfig_libs" |
| 10948 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 10949 | for cf_add_1lib in $LIBS |
| 10950 | do |
| 10951 | for cf_add_2lib in $cf_add_libs |
| 10952 | do |
| 10953 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 10954 | then |
| 10955 | cf_add_1lib= |
| 10956 | break |
| 10957 | fi |
| 10958 | done |
| 10959 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 10960 | done |
| 10961 | LIBS="$cf_add_libs" |
| 10962 | |
| 10963 | : |
| 10964 | else |
| 10965 | cf_pkgconfig_incs= |
| 10966 | cf_pkgconfig_libs= |
| 10967 | { echo "$as_me:10967: WARNING: unable to find X11 library" >&5 |
| 10968 | echo "$as_me: WARNING: unable to find X11 library" >&2;} |
| 10969 | fi |
| 10970 | |
| 10971 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then |
| 10972 | test -n "$verbose" && echo " found package ice" 1>&6 |
| 10973 | |
| 10974 | echo "${as_me:-configure}:10974: testing found package ice ..." 1>&5 |
| 10975 | |
| 10976 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`" |
| 10977 | cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`" |
| 10978 | test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 10979 | |
| 10980 | echo "${as_me:-configure}:10980: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 10981 | |
| 10982 | test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6 |
| 10983 | |
| 10984 | echo "${as_me:-configure}:10984: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 10985 | |
| 10986 | cf_fix_cppflags=no |
| 10987 | cf_new_cflags= |
| 10988 | cf_new_cppflags= |
| 10989 | cf_new_extra_cppflags= |
| 10990 | |
| 10991 | for cf_add_cflags in $cf_pkgconfig_incs |
| 10992 | do |
| 10993 | case $cf_fix_cppflags in |
| 10994 | (no) |
| 10995 | case $cf_add_cflags in |
| 10996 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 10997 | case $cf_add_cflags in |
| 10998 | (-D*) |
| 10999 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 11000 | |
| 11001 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11002 | && test -z "${cf_tst_cflags}" \ |
| 11003 | && cf_fix_cppflags=yes |
| 11004 | |
| 11005 | if test $cf_fix_cppflags = yes ; then |
| 11006 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11007 | continue |
| 11008 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 11009 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11010 | continue |
| 11011 | fi |
| 11012 | ;; |
| 11013 | esac |
| 11014 | case "$CPPFLAGS" in |
| 11015 | (*$cf_add_cflags) |
| 11016 | ;; |
| 11017 | (*) |
| 11018 | case $cf_add_cflags in |
| 11019 | (-D*) |
| 11020 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 11021 | |
| 11022 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 11023 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 11024 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 11025 | |
| 11026 | ;; |
| 11027 | esac |
| 11028 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 11029 | ;; |
| 11030 | esac |
| 11031 | ;; |
| 11032 | (*) |
| 11033 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 11034 | ;; |
| 11035 | esac |
| 11036 | ;; |
| 11037 | (yes) |
| 11038 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11039 | |
| 11040 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 11041 | |
| 11042 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11043 | && test -z "${cf_tst_cflags}" \ |
| 11044 | && cf_fix_cppflags=no |
| 11045 | ;; |
| 11046 | esac |
| 11047 | done |
| 11048 | |
| 11049 | if test -n "$cf_new_cflags" ; then |
| 11050 | |
| 11051 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 11052 | fi |
| 11053 | |
| 11054 | if test -n "$cf_new_cppflags" ; then |
| 11055 | |
| 11056 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 11057 | fi |
| 11058 | |
| 11059 | if test -n "$cf_new_extra_cppflags" ; then |
| 11060 | |
| 11061 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 11062 | fi |
| 11063 | |
| 11064 | cf_add_libs="$cf_pkgconfig_libs" |
| 11065 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 11066 | for cf_add_1lib in $LIBS |
| 11067 | do |
| 11068 | for cf_add_2lib in $cf_add_libs |
| 11069 | do |
| 11070 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 11071 | then |
| 11072 | cf_add_1lib= |
| 11073 | break |
| 11074 | fi |
| 11075 | done |
| 11076 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 11077 | done |
| 11078 | LIBS="$cf_add_libs" |
| 11079 | |
| 11080 | : |
| 11081 | else |
| 11082 | cf_pkgconfig_incs= |
| 11083 | cf_pkgconfig_libs= |
| 11084 | { echo "$as_me:11084: WARNING: unable to find ICE library" >&5 |
| 11085 | echo "$as_me: WARNING: unable to find ICE library" >&2;} |
| 11086 | fi |
| 11087 | |
| 11088 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then |
| 11089 | test -n "$verbose" && echo " found package sm" 1>&6 |
| 11090 | |
| 11091 | echo "${as_me:-configure}:11091: testing found package sm ..." 1>&5 |
| 11092 | |
| 11093 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`" |
| 11094 | cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`" |
| 11095 | test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 11096 | |
| 11097 | echo "${as_me:-configure}:11097: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 11098 | |
| 11099 | test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6 |
| 11100 | |
| 11101 | echo "${as_me:-configure}:11101: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 11102 | |
| 11103 | cf_fix_cppflags=no |
| 11104 | cf_new_cflags= |
| 11105 | cf_new_cppflags= |
| 11106 | cf_new_extra_cppflags= |
| 11107 | |
| 11108 | for cf_add_cflags in $cf_pkgconfig_incs |
| 11109 | do |
| 11110 | case $cf_fix_cppflags in |
| 11111 | (no) |
| 11112 | case $cf_add_cflags in |
| 11113 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 11114 | case $cf_add_cflags in |
| 11115 | (-D*) |
| 11116 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 11117 | |
| 11118 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11119 | && test -z "${cf_tst_cflags}" \ |
| 11120 | && cf_fix_cppflags=yes |
| 11121 | |
| 11122 | if test $cf_fix_cppflags = yes ; then |
| 11123 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11124 | continue |
| 11125 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 11126 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11127 | continue |
| 11128 | fi |
| 11129 | ;; |
| 11130 | esac |
| 11131 | case "$CPPFLAGS" in |
| 11132 | (*$cf_add_cflags) |
| 11133 | ;; |
| 11134 | (*) |
| 11135 | case $cf_add_cflags in |
| 11136 | (-D*) |
| 11137 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 11138 | |
| 11139 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 11140 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 11141 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 11142 | |
| 11143 | ;; |
| 11144 | esac |
| 11145 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 11146 | ;; |
| 11147 | esac |
| 11148 | ;; |
| 11149 | (*) |
| 11150 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 11151 | ;; |
| 11152 | esac |
| 11153 | ;; |
| 11154 | (yes) |
| 11155 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11156 | |
| 11157 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 11158 | |
| 11159 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11160 | && test -z "${cf_tst_cflags}" \ |
| 11161 | && cf_fix_cppflags=no |
| 11162 | ;; |
| 11163 | esac |
| 11164 | done |
| 11165 | |
| 11166 | if test -n "$cf_new_cflags" ; then |
| 11167 | |
| 11168 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 11169 | fi |
| 11170 | |
| 11171 | if test -n "$cf_new_cppflags" ; then |
| 11172 | |
| 11173 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 11174 | fi |
| 11175 | |
| 11176 | if test -n "$cf_new_extra_cppflags" ; then |
| 11177 | |
| 11178 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 11179 | fi |
| 11180 | |
| 11181 | cf_add_libs="$cf_pkgconfig_libs" |
| 11182 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 11183 | for cf_add_1lib in $LIBS |
| 11184 | do |
| 11185 | for cf_add_2lib in $cf_add_libs |
| 11186 | do |
| 11187 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 11188 | then |
| 11189 | cf_add_1lib= |
| 11190 | break |
| 11191 | fi |
| 11192 | done |
| 11193 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 11194 | done |
| 11195 | LIBS="$cf_add_libs" |
| 11196 | |
| 11197 | : |
| 11198 | else |
| 11199 | cf_pkgconfig_incs= |
| 11200 | cf_pkgconfig_libs= |
| 11201 | { echo "$as_me:11201: WARNING: unable to find SM library" >&5 |
| 11202 | echo "$as_me: WARNING: unable to find SM library" >&2;} |
| 11203 | fi |
| 11204 | |
| 11205 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then |
| 11206 | test -n "$verbose" && echo " found package xt" 1>&6 |
| 11207 | |
| 11208 | echo "${as_me:-configure}:11208: testing found package xt ..." 1>&5 |
| 11209 | |
| 11210 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`" |
| 11211 | cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`" |
| 11212 | test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 11213 | |
| 11214 | echo "${as_me:-configure}:11214: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 11215 | |
| 11216 | test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6 |
| 11217 | |
| 11218 | echo "${as_me:-configure}:11218: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 11219 | |
| 11220 | cf_fix_cppflags=no |
| 11221 | cf_new_cflags= |
| 11222 | cf_new_cppflags= |
| 11223 | cf_new_extra_cppflags= |
| 11224 | |
| 11225 | for cf_add_cflags in $cf_pkgconfig_incs |
| 11226 | do |
| 11227 | case $cf_fix_cppflags in |
| 11228 | (no) |
| 11229 | case $cf_add_cflags in |
| 11230 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 11231 | case $cf_add_cflags in |
| 11232 | (-D*) |
| 11233 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 11234 | |
| 11235 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11236 | && test -z "${cf_tst_cflags}" \ |
| 11237 | && cf_fix_cppflags=yes |
| 11238 | |
| 11239 | if test $cf_fix_cppflags = yes ; then |
| 11240 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11241 | continue |
| 11242 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 11243 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11244 | continue |
| 11245 | fi |
| 11246 | ;; |
| 11247 | esac |
| 11248 | case "$CPPFLAGS" in |
| 11249 | (*$cf_add_cflags) |
| 11250 | ;; |
| 11251 | (*) |
| 11252 | case $cf_add_cflags in |
| 11253 | (-D*) |
| 11254 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 11255 | |
| 11256 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 11257 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 11258 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 11259 | |
| 11260 | ;; |
| 11261 | esac |
| 11262 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 11263 | ;; |
| 11264 | esac |
| 11265 | ;; |
| 11266 | (*) |
| 11267 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 11268 | ;; |
| 11269 | esac |
| 11270 | ;; |
| 11271 | (yes) |
| 11272 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11273 | |
| 11274 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 11275 | |
| 11276 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11277 | && test -z "${cf_tst_cflags}" \ |
| 11278 | && cf_fix_cppflags=no |
| 11279 | ;; |
| 11280 | esac |
| 11281 | done |
| 11282 | |
| 11283 | if test -n "$cf_new_cflags" ; then |
| 11284 | |
| 11285 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 11286 | fi |
| 11287 | |
| 11288 | if test -n "$cf_new_cppflags" ; then |
| 11289 | |
| 11290 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 11291 | fi |
| 11292 | |
| 11293 | if test -n "$cf_new_extra_cppflags" ; then |
| 11294 | |
| 11295 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 11296 | fi |
| 11297 | |
| 11298 | cf_add_libs="$cf_pkgconfig_libs" |
| 11299 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 11300 | for cf_add_1lib in $LIBS |
| 11301 | do |
| 11302 | for cf_add_2lib in $cf_add_libs |
| 11303 | do |
| 11304 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 11305 | then |
| 11306 | cf_add_1lib= |
| 11307 | break |
| 11308 | fi |
| 11309 | done |
| 11310 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 11311 | done |
| 11312 | LIBS="$cf_add_libs" |
| 11313 | |
| 11314 | : |
| 11315 | else |
| 11316 | cf_pkgconfig_incs= |
| 11317 | cf_pkgconfig_libs= |
| 11318 | { echo "$as_me:11318: WARNING: unable to find Xt library" >&5 |
| 11319 | echo "$as_me: WARNING: unable to find Xt library" >&2;} |
| 11320 | fi |
| 11321 | |
| 11322 | fi |
| 11323 | |
| 11324 | cf_have_X_LIBS=no |
| 11325 | |
| 11326 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then |
| 11327 | test -n "$verbose" && echo " found package xt" 1>&6 |
| 11328 | |
| 11329 | echo "${as_me:-configure}:11329: testing found package xt ..." 1>&5 |
| 11330 | |
| 11331 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`" |
| 11332 | cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`" |
| 11333 | test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 11334 | |
| 11335 | echo "${as_me:-configure}:11335: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 11336 | |
| 11337 | test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6 |
| 11338 | |
| 11339 | echo "${as_me:-configure}:11339: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 11340 | |
| 11341 | cf_fix_cppflags=no |
| 11342 | cf_new_cflags= |
| 11343 | cf_new_cppflags= |
| 11344 | cf_new_extra_cppflags= |
| 11345 | |
| 11346 | for cf_add_cflags in $cf_pkgconfig_incs |
| 11347 | do |
| 11348 | case $cf_fix_cppflags in |
| 11349 | (no) |
| 11350 | case $cf_add_cflags in |
| 11351 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 11352 | case $cf_add_cflags in |
| 11353 | (-D*) |
| 11354 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 11355 | |
| 11356 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11357 | && test -z "${cf_tst_cflags}" \ |
| 11358 | && cf_fix_cppflags=yes |
| 11359 | |
| 11360 | if test $cf_fix_cppflags = yes ; then |
| 11361 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11362 | continue |
| 11363 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 11364 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11365 | continue |
| 11366 | fi |
| 11367 | ;; |
| 11368 | esac |
| 11369 | case "$CPPFLAGS" in |
| 11370 | (*$cf_add_cflags) |
| 11371 | ;; |
| 11372 | (*) |
| 11373 | case $cf_add_cflags in |
| 11374 | (-D*) |
| 11375 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 11376 | |
| 11377 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 11378 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 11379 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 11380 | |
| 11381 | ;; |
| 11382 | esac |
| 11383 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 11384 | ;; |
| 11385 | esac |
| 11386 | ;; |
| 11387 | (*) |
| 11388 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 11389 | ;; |
| 11390 | esac |
| 11391 | ;; |
| 11392 | (yes) |
| 11393 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11394 | |
| 11395 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 11396 | |
| 11397 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11398 | && test -z "${cf_tst_cflags}" \ |
| 11399 | && cf_fix_cppflags=no |
| 11400 | ;; |
| 11401 | esac |
| 11402 | done |
| 11403 | |
| 11404 | if test -n "$cf_new_cflags" ; then |
| 11405 | |
| 11406 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 11407 | fi |
| 11408 | |
| 11409 | if test -n "$cf_new_cppflags" ; then |
| 11410 | |
| 11411 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 11412 | fi |
| 11413 | |
| 11414 | if test -n "$cf_new_extra_cppflags" ; then |
| 11415 | |
| 11416 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 11417 | fi |
| 11418 | |
| 11419 | cf_add_libs="$cf_pkgconfig_libs" |
| 11420 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 11421 | for cf_add_1lib in $LIBS |
| 11422 | do |
| 11423 | for cf_add_2lib in $cf_add_libs |
| 11424 | do |
| 11425 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 11426 | then |
| 11427 | cf_add_1lib= |
| 11428 | break |
| 11429 | fi |
| 11430 | done |
| 11431 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 11432 | done |
| 11433 | LIBS="$cf_add_libs" |
| 11434 | |
| 11435 | case "x$LIBS" in |
| 11436 | (*-lX11*) |
| 11437 | ;; |
| 11438 | (*) |
| 11439 | # we have an "xt" package, but it may omit Xt's dependency on X11 |
| 11440 | echo "$as_me:11440: checking for usable X dependency" >&5 |
| 11441 | echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6 |
| 11442 | if test "${cf_cv_xt_x11_compat+set}" = set; then |
| 11443 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 11444 | else |
| 11445 | |
| 11446 | cat >conftest.$ac_ext <<_ACEOF |
| 11447 | #line 11447 "configure" |
| 11448 | #include "confdefs.h" |
| 11449 | |
| 11450 | #include <X11/Xlib.h> |
| 11451 | |
| 11452 | int |
| 11453 | main () |
| 11454 | { |
| 11455 | |
| 11456 | int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0); |
| 11457 | int rc2 = XClearWindow((Display*) 0, (Window) 0); |
| 11458 | int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0); |
| 11459 | int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0); |
| 11460 | |
| 11461 | ; |
| 11462 | return 0; |
| 11463 | } |
| 11464 | _ACEOF |
| 11465 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 11466 | if { (eval echo "$as_me:11466: \"$ac_link\"") >&5 |
| 11467 | (eval $ac_link) 2>&5 |
| 11468 | ac_status=$? |
| 11469 | echo "$as_me:11469: \$? = $ac_status" >&5 |
| 11470 | (exit $ac_status); } && |
| 11471 | { ac_try='test -s conftest$ac_exeext' |
| 11472 | { (eval echo "$as_me:11472: \"$ac_try\"") >&5 |
| 11473 | (eval $ac_try) 2>&5 |
| 11474 | ac_status=$? |
| 11475 | echo "$as_me:11475: \$? = $ac_status" >&5 |
| 11476 | (exit $ac_status); }; }; then |
| 11477 | cf_cv_xt_x11_compat=yes |
| 11478 | else |
| 11479 | echo "$as_me: failed program was:" >&5 |
| 11480 | cat conftest.$ac_ext >&5 |
| 11481 | cf_cv_xt_x11_compat=no |
| 11482 | fi |
| 11483 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 11484 | fi |
| 11485 | echo "$as_me:11485: result: $cf_cv_xt_x11_compat" >&5 |
| 11486 | echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6 |
| 11487 | if test "$cf_cv_xt_x11_compat" = no |
| 11488 | then |
| 11489 | test -n "$verbose" && echo " work around broken X11 dependency" 1>&6 |
| 11490 | |
| 11491 | echo "${as_me:-configure}:11491: testing work around broken X11 dependency ..." 1>&5 |
| 11492 | |
| 11493 | # 2010/11/19 - good enough until a working Xt on Xcb is delivered. |
| 11494 | |
| 11495 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then |
| 11496 | test -n "$verbose" && echo " found package x11" 1>&6 |
| 11497 | |
| 11498 | echo "${as_me:-configure}:11498: testing found package x11 ..." 1>&5 |
| 11499 | |
| 11500 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`" |
| 11501 | cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`" |
| 11502 | test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 11503 | |
| 11504 | echo "${as_me:-configure}:11504: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 11505 | |
| 11506 | test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6 |
| 11507 | |
| 11508 | echo "${as_me:-configure}:11508: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 11509 | |
| 11510 | cf_fix_cppflags=no |
| 11511 | cf_new_cflags= |
| 11512 | cf_new_cppflags= |
| 11513 | cf_new_extra_cppflags= |
| 11514 | |
| 11515 | for cf_add_cflags in $cf_pkgconfig_incs |
| 11516 | do |
| 11517 | case $cf_fix_cppflags in |
| 11518 | (no) |
| 11519 | case $cf_add_cflags in |
| 11520 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 11521 | case $cf_add_cflags in |
| 11522 | (-D*) |
| 11523 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 11524 | |
| 11525 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11526 | && test -z "${cf_tst_cflags}" \ |
| 11527 | && cf_fix_cppflags=yes |
| 11528 | |
| 11529 | if test $cf_fix_cppflags = yes ; then |
| 11530 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11531 | continue |
| 11532 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 11533 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11534 | continue |
| 11535 | fi |
| 11536 | ;; |
| 11537 | esac |
| 11538 | case "$CPPFLAGS" in |
| 11539 | (*$cf_add_cflags) |
| 11540 | ;; |
| 11541 | (*) |
| 11542 | case $cf_add_cflags in |
| 11543 | (-D*) |
| 11544 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 11545 | |
| 11546 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 11547 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 11548 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 11549 | |
| 11550 | ;; |
| 11551 | esac |
| 11552 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 11553 | ;; |
| 11554 | esac |
| 11555 | ;; |
| 11556 | (*) |
| 11557 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 11558 | ;; |
| 11559 | esac |
| 11560 | ;; |
| 11561 | (yes) |
| 11562 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11563 | |
| 11564 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 11565 | |
| 11566 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11567 | && test -z "${cf_tst_cflags}" \ |
| 11568 | && cf_fix_cppflags=no |
| 11569 | ;; |
| 11570 | esac |
| 11571 | done |
| 11572 | |
| 11573 | if test -n "$cf_new_cflags" ; then |
| 11574 | |
| 11575 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 11576 | fi |
| 11577 | |
| 11578 | if test -n "$cf_new_cppflags" ; then |
| 11579 | |
| 11580 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 11581 | fi |
| 11582 | |
| 11583 | if test -n "$cf_new_extra_cppflags" ; then |
| 11584 | |
| 11585 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 11586 | fi |
| 11587 | |
| 11588 | cf_add_libs="$cf_pkgconfig_libs" |
| 11589 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 11590 | for cf_add_1lib in $LIBS |
| 11591 | do |
| 11592 | for cf_add_2lib in $cf_add_libs |
| 11593 | do |
| 11594 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 11595 | then |
| 11596 | cf_add_1lib= |
| 11597 | break |
| 11598 | fi |
| 11599 | done |
| 11600 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 11601 | done |
| 11602 | LIBS="$cf_add_libs" |
| 11603 | |
| 11604 | : |
| 11605 | else |
| 11606 | cf_pkgconfig_incs= |
| 11607 | cf_pkgconfig_libs= |
| 11608 | |
| 11609 | test -n "$verbose" && echo " ...before $LIBS" 1>&6 |
| 11610 | |
| 11611 | echo "${as_me:-configure}:11611: testing ...before $LIBS ..." 1>&5 |
| 11612 | |
| 11613 | LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'` |
| 11614 | test -n "$verbose" && echo " ...after $LIBS" 1>&6 |
| 11615 | |
| 11616 | echo "${as_me:-configure}:11616: testing ...after $LIBS ..." 1>&5 |
| 11617 | |
| 11618 | fi |
| 11619 | |
| 11620 | fi |
| 11621 | ;; |
| 11622 | esac |
| 11623 | |
| 11624 | echo "$as_me:11624: checking for usable X Toolkit package" >&5 |
| 11625 | echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6 |
| 11626 | if test "${cf_cv_xt_ice_compat+set}" = set; then |
| 11627 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 11628 | else |
| 11629 | |
| 11630 | cat >conftest.$ac_ext <<_ACEOF |
| 11631 | #line 11631 "configure" |
| 11632 | #include "confdefs.h" |
| 11633 | |
| 11634 | #include <X11/Shell.h> |
| 11635 | |
| 11636 | int |
| 11637 | main () |
| 11638 | { |
| 11639 | int num = IceConnectionNumber(0) |
| 11640 | |
| 11641 | ; |
| 11642 | return 0; |
| 11643 | } |
| 11644 | _ACEOF |
| 11645 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 11646 | if { (eval echo "$as_me:11646: \"$ac_link\"") >&5 |
| 11647 | (eval $ac_link) 2>&5 |
| 11648 | ac_status=$? |
| 11649 | echo "$as_me:11649: \$? = $ac_status" >&5 |
| 11650 | (exit $ac_status); } && |
| 11651 | { ac_try='test -s conftest$ac_exeext' |
| 11652 | { (eval echo "$as_me:11652: \"$ac_try\"") >&5 |
| 11653 | (eval $ac_try) 2>&5 |
| 11654 | ac_status=$? |
| 11655 | echo "$as_me:11655: \$? = $ac_status" >&5 |
| 11656 | (exit $ac_status); }; }; then |
| 11657 | cf_cv_xt_ice_compat=yes |
| 11658 | else |
| 11659 | echo "$as_me: failed program was:" >&5 |
| 11660 | cat conftest.$ac_ext >&5 |
| 11661 | cf_cv_xt_ice_compat=no |
| 11662 | fi |
| 11663 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 11664 | fi |
| 11665 | echo "$as_me:11665: result: $cf_cv_xt_ice_compat" >&5 |
| 11666 | echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6 |
| 11667 | |
| 11668 | if test "$cf_cv_xt_ice_compat" = no |
| 11669 | then |
| 11670 | # workaround for broken ".pc" files used for X Toolkit. |
| 11671 | case "x$X_PRE_LIBS" in |
| 11672 | (*-lICE*) |
| 11673 | case "x$LIBS" in |
| 11674 | (*-lICE*) |
| 11675 | ;; |
| 11676 | (*) |
| 11677 | test -n "$verbose" && echo " work around broken ICE dependency" 1>&6 |
| 11678 | |
| 11679 | echo "${as_me:-configure}:11679: testing work around broken ICE dependency ..." 1>&5 |
| 11680 | |
| 11681 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then |
| 11682 | test -n "$verbose" && echo " found package ice" 1>&6 |
| 11683 | |
| 11684 | echo "${as_me:-configure}:11684: testing found package ice ..." 1>&5 |
| 11685 | |
| 11686 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`" |
| 11687 | cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`" |
| 11688 | test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 11689 | |
| 11690 | echo "${as_me:-configure}:11690: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 11691 | |
| 11692 | test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6 |
| 11693 | |
| 11694 | echo "${as_me:-configure}:11694: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 11695 | |
| 11696 | cf_fix_cppflags=no |
| 11697 | cf_new_cflags= |
| 11698 | cf_new_cppflags= |
| 11699 | cf_new_extra_cppflags= |
| 11700 | |
| 11701 | for cf_add_cflags in $cf_pkgconfig_incs |
| 11702 | do |
| 11703 | case $cf_fix_cppflags in |
| 11704 | (no) |
| 11705 | case $cf_add_cflags in |
| 11706 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 11707 | case $cf_add_cflags in |
| 11708 | (-D*) |
| 11709 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 11710 | |
| 11711 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11712 | && test -z "${cf_tst_cflags}" \ |
| 11713 | && cf_fix_cppflags=yes |
| 11714 | |
| 11715 | if test $cf_fix_cppflags = yes ; then |
| 11716 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11717 | continue |
| 11718 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 11719 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11720 | continue |
| 11721 | fi |
| 11722 | ;; |
| 11723 | esac |
| 11724 | case "$CPPFLAGS" in |
| 11725 | (*$cf_add_cflags) |
| 11726 | ;; |
| 11727 | (*) |
| 11728 | case $cf_add_cflags in |
| 11729 | (-D*) |
| 11730 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 11731 | |
| 11732 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 11733 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 11734 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 11735 | |
| 11736 | ;; |
| 11737 | esac |
| 11738 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 11739 | ;; |
| 11740 | esac |
| 11741 | ;; |
| 11742 | (*) |
| 11743 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 11744 | ;; |
| 11745 | esac |
| 11746 | ;; |
| 11747 | (yes) |
| 11748 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11749 | |
| 11750 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 11751 | |
| 11752 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11753 | && test -z "${cf_tst_cflags}" \ |
| 11754 | && cf_fix_cppflags=no |
| 11755 | ;; |
| 11756 | esac |
| 11757 | done |
| 11758 | |
| 11759 | if test -n "$cf_new_cflags" ; then |
| 11760 | |
| 11761 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 11762 | fi |
| 11763 | |
| 11764 | if test -n "$cf_new_cppflags" ; then |
| 11765 | |
| 11766 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 11767 | fi |
| 11768 | |
| 11769 | if test -n "$cf_new_extra_cppflags" ; then |
| 11770 | |
| 11771 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 11772 | fi |
| 11773 | |
| 11774 | cf_add_libs="$cf_pkgconfig_libs" |
| 11775 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 11776 | for cf_add_1lib in $LIBS |
| 11777 | do |
| 11778 | for cf_add_2lib in $cf_add_libs |
| 11779 | do |
| 11780 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 11781 | then |
| 11782 | cf_add_1lib= |
| 11783 | break |
| 11784 | fi |
| 11785 | done |
| 11786 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 11787 | done |
| 11788 | LIBS="$cf_add_libs" |
| 11789 | |
| 11790 | if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then |
| 11791 | test -n "$verbose" && echo " found package sm" 1>&6 |
| 11792 | |
| 11793 | echo "${as_me:-configure}:11793: testing found package sm ..." 1>&5 |
| 11794 | |
| 11795 | cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`" |
| 11796 | cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`" |
| 11797 | test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6 |
| 11798 | |
| 11799 | echo "${as_me:-configure}:11799: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5 |
| 11800 | |
| 11801 | test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6 |
| 11802 | |
| 11803 | echo "${as_me:-configure}:11803: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5 |
| 11804 | |
| 11805 | cf_fix_cppflags=no |
| 11806 | cf_new_cflags= |
| 11807 | cf_new_cppflags= |
| 11808 | cf_new_extra_cppflags= |
| 11809 | |
| 11810 | for cf_add_cflags in $cf_pkgconfig_incs |
| 11811 | do |
| 11812 | case $cf_fix_cppflags in |
| 11813 | (no) |
| 11814 | case $cf_add_cflags in |
| 11815 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 11816 | case $cf_add_cflags in |
| 11817 | (-D*) |
| 11818 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 11819 | |
| 11820 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11821 | && test -z "${cf_tst_cflags}" \ |
| 11822 | && cf_fix_cppflags=yes |
| 11823 | |
| 11824 | if test $cf_fix_cppflags = yes ; then |
| 11825 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11826 | continue |
| 11827 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 11828 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11829 | continue |
| 11830 | fi |
| 11831 | ;; |
| 11832 | esac |
| 11833 | case "$CPPFLAGS" in |
| 11834 | (*$cf_add_cflags) |
| 11835 | ;; |
| 11836 | (*) |
| 11837 | case $cf_add_cflags in |
| 11838 | (-D*) |
| 11839 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 11840 | |
| 11841 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 11842 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 11843 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 11844 | |
| 11845 | ;; |
| 11846 | esac |
| 11847 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 11848 | ;; |
| 11849 | esac |
| 11850 | ;; |
| 11851 | (*) |
| 11852 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 11853 | ;; |
| 11854 | esac |
| 11855 | ;; |
| 11856 | (yes) |
| 11857 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11858 | |
| 11859 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 11860 | |
| 11861 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11862 | && test -z "${cf_tst_cflags}" \ |
| 11863 | && cf_fix_cppflags=no |
| 11864 | ;; |
| 11865 | esac |
| 11866 | done |
| 11867 | |
| 11868 | if test -n "$cf_new_cflags" ; then |
| 11869 | |
| 11870 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 11871 | fi |
| 11872 | |
| 11873 | if test -n "$cf_new_cppflags" ; then |
| 11874 | |
| 11875 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 11876 | fi |
| 11877 | |
| 11878 | if test -n "$cf_new_extra_cppflags" ; then |
| 11879 | |
| 11880 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 11881 | fi |
| 11882 | |
| 11883 | cf_add_libs="$cf_pkgconfig_libs" |
| 11884 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 11885 | for cf_add_1lib in $LIBS |
| 11886 | do |
| 11887 | for cf_add_2lib in $cf_add_libs |
| 11888 | do |
| 11889 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 11890 | then |
| 11891 | cf_add_1lib= |
| 11892 | break |
| 11893 | fi |
| 11894 | done |
| 11895 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 11896 | done |
| 11897 | LIBS="$cf_add_libs" |
| 11898 | |
| 11899 | : |
| 11900 | else |
| 11901 | cf_pkgconfig_incs= |
| 11902 | cf_pkgconfig_libs= |
| 11903 | : |
| 11904 | fi |
| 11905 | |
| 11906 | else |
| 11907 | cf_pkgconfig_incs= |
| 11908 | cf_pkgconfig_libs= |
| 11909 | |
| 11910 | test -n "$verbose" && echo " ...before $LIBS" 1>&6 |
| 11911 | |
| 11912 | echo "${as_me:-configure}:11912: testing ...before $LIBS ..." 1>&5 |
| 11913 | |
| 11914 | LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'` |
| 11915 | test -n "$verbose" && echo " ...after $LIBS" 1>&6 |
| 11916 | |
| 11917 | echo "${as_me:-configure}:11917: testing ...after $LIBS ..." 1>&5 |
| 11918 | |
| 11919 | fi |
| 11920 | |
| 11921 | ;; |
| 11922 | esac |
| 11923 | ;; |
| 11924 | esac |
| 11925 | fi |
| 11926 | |
| 11927 | cf_have_X_LIBS=yes |
| 11928 | |
| 11929 | else |
| 11930 | cf_pkgconfig_incs= |
| 11931 | cf_pkgconfig_libs= |
| 11932 | |
| 11933 | LDFLAGS="$X_LIBS $LDFLAGS" |
| 11934 | |
| 11935 | test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6 |
| 11936 | |
| 11937 | echo "${as_me:-configure}:11937: testing checking additions to CFLAGS ..." 1>&5 |
| 11938 | |
| 11939 | cf_check_cflags="$CFLAGS" |
| 11940 | cf_check_cppflags="$CPPFLAGS" |
| 11941 | |
| 11942 | cf_fix_cppflags=no |
| 11943 | cf_new_cflags= |
| 11944 | cf_new_cppflags= |
| 11945 | cf_new_extra_cppflags= |
| 11946 | |
| 11947 | for cf_add_cflags in $X_CFLAGS |
| 11948 | do |
| 11949 | case $cf_fix_cppflags in |
| 11950 | (no) |
| 11951 | case $cf_add_cflags in |
| 11952 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 11953 | case $cf_add_cflags in |
| 11954 | (-D*) |
| 11955 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 11956 | |
| 11957 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11958 | && test -z "${cf_tst_cflags}" \ |
| 11959 | && cf_fix_cppflags=yes |
| 11960 | |
| 11961 | if test $cf_fix_cppflags = yes ; then |
| 11962 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11963 | continue |
| 11964 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 11965 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11966 | continue |
| 11967 | fi |
| 11968 | ;; |
| 11969 | esac |
| 11970 | case "$CPPFLAGS" in |
| 11971 | (*$cf_add_cflags) |
| 11972 | ;; |
| 11973 | (*) |
| 11974 | case $cf_add_cflags in |
| 11975 | (-D*) |
| 11976 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 11977 | |
| 11978 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 11979 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 11980 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 11981 | |
| 11982 | ;; |
| 11983 | esac |
| 11984 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 11985 | ;; |
| 11986 | esac |
| 11987 | ;; |
| 11988 | (*) |
| 11989 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 11990 | ;; |
| 11991 | esac |
| 11992 | ;; |
| 11993 | (yes) |
| 11994 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 11995 | |
| 11996 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 11997 | |
| 11998 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 11999 | && test -z "${cf_tst_cflags}" \ |
| 12000 | && cf_fix_cppflags=no |
| 12001 | ;; |
| 12002 | esac |
| 12003 | done |
| 12004 | |
| 12005 | if test -n "$cf_new_cflags" ; then |
| 12006 | test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6 |
| 12007 | |
| 12008 | echo "${as_me:-configure}:12008: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5 |
| 12009 | |
| 12010 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 12011 | fi |
| 12012 | |
| 12013 | if test -n "$cf_new_cppflags" ; then |
| 12014 | test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6 |
| 12015 | |
| 12016 | echo "${as_me:-configure}:12016: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5 |
| 12017 | |
| 12018 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 12019 | fi |
| 12020 | |
| 12021 | if test -n "$cf_new_extra_cppflags" ; then |
| 12022 | test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6 |
| 12023 | |
| 12024 | echo "${as_me:-configure}:12024: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5 |
| 12025 | |
| 12026 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 12027 | fi |
| 12028 | |
| 12029 | if test "x$cf_check_cflags" != "x$CFLAGS" ; then |
| 12030 | cat >conftest.$ac_ext <<_ACEOF |
| 12031 | #line 12031 "configure" |
| 12032 | #include "confdefs.h" |
| 12033 | #include <stdio.h> |
| 12034 | int |
| 12035 | main () |
| 12036 | { |
| 12037 | printf("Hello world"); |
| 12038 | ; |
| 12039 | return 0; |
| 12040 | } |
| 12041 | _ACEOF |
| 12042 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12043 | if { (eval echo "$as_me:12043: \"$ac_link\"") >&5 |
| 12044 | (eval $ac_link) 2>&5 |
| 12045 | ac_status=$? |
| 12046 | echo "$as_me:12046: \$? = $ac_status" >&5 |
| 12047 | (exit $ac_status); } && |
| 12048 | { ac_try='test -s conftest$ac_exeext' |
| 12049 | { (eval echo "$as_me:12049: \"$ac_try\"") >&5 |
| 12050 | (eval $ac_try) 2>&5 |
| 12051 | ac_status=$? |
| 12052 | echo "$as_me:12052: \$? = $ac_status" >&5 |
| 12053 | (exit $ac_status); }; }; then |
| 12054 | : |
| 12055 | else |
| 12056 | echo "$as_me: failed program was:" >&5 |
| 12057 | cat conftest.$ac_ext >&5 |
| 12058 | test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6 |
| 12059 | |
| 12060 | echo "${as_me:-configure}:12060: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5 |
| 12061 | |
| 12062 | if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then |
| 12063 | test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6 |
| 12064 | |
| 12065 | echo "${as_me:-configure}:12065: testing but keeping change to \$CPPFLAGS ..." 1>&5 |
| 12066 | |
| 12067 | fi |
| 12068 | CFLAGS="$cf_check_flags" |
| 12069 | fi |
| 12070 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12071 | fi |
| 12072 | |
| 12073 | echo "$as_me:12073: checking for XOpenDisplay" >&5 |
| 12074 | echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6 |
| 12075 | if test "${ac_cv_func_XOpenDisplay+set}" = set; then |
| 12076 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12077 | else |
| 12078 | cat >conftest.$ac_ext <<_ACEOF |
| 12079 | #line 12079 "configure" |
| 12080 | #include "confdefs.h" |
| 12081 | /* System header to define __stub macros and hopefully few prototypes, |
| 12082 | which can conflict with char XOpenDisplay (); below. */ |
| 12083 | #include <assert.h> |
| 12084 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 12085 | #ifdef __cplusplus |
| 12086 | extern "C" |
| 12087 | #endif |
| 12088 | /* We use char because int might match the return type of a gcc2 |
| 12089 | builtin and then its argument prototype would still apply. */ |
| 12090 | char XOpenDisplay (); |
| 12091 | char (*f) (); |
| 12092 | |
| 12093 | int |
| 12094 | main () |
| 12095 | { |
| 12096 | /* The GNU C library defines this for functions which it implements |
| 12097 | to always fail with ENOSYS. Some functions are actually named |
| 12098 | something starting with __ and the normal name is an alias. */ |
| 12099 | #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay) |
| 12100 | choke me |
| 12101 | #else |
| 12102 | f = XOpenDisplay; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 12103 | #endif |
| 12104 | |
| 12105 | ; |
| 12106 | return 0; |
| 12107 | } |
| 12108 | _ACEOF |
| 12109 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12110 | if { (eval echo "$as_me:12110: \"$ac_link\"") >&5 |
| 12111 | (eval $ac_link) 2>&5 |
| 12112 | ac_status=$? |
| 12113 | echo "$as_me:12113: \$? = $ac_status" >&5 |
| 12114 | (exit $ac_status); } && |
| 12115 | { ac_try='test -s conftest$ac_exeext' |
| 12116 | { (eval echo "$as_me:12116: \"$ac_try\"") >&5 |
| 12117 | (eval $ac_try) 2>&5 |
| 12118 | ac_status=$? |
| 12119 | echo "$as_me:12119: \$? = $ac_status" >&5 |
| 12120 | (exit $ac_status); }; }; then |
| 12121 | ac_cv_func_XOpenDisplay=yes |
| 12122 | else |
| 12123 | echo "$as_me: failed program was:" >&5 |
| 12124 | cat conftest.$ac_ext >&5 |
| 12125 | ac_cv_func_XOpenDisplay=no |
| 12126 | fi |
| 12127 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12128 | fi |
| 12129 | echo "$as_me:12129: result: $ac_cv_func_XOpenDisplay" >&5 |
| 12130 | echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6 |
| 12131 | if test $ac_cv_func_XOpenDisplay = yes; then |
| 12132 | : |
| 12133 | else |
| 12134 | |
| 12135 | echo "$as_me:12135: checking for XOpenDisplay in -lX11" >&5 |
| 12136 | echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6 |
| 12137 | if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then |
| 12138 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12139 | else |
| 12140 | ac_check_lib_save_LIBS=$LIBS |
| 12141 | LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" |
| 12142 | cat >conftest.$ac_ext <<_ACEOF |
| 12143 | #line 12143 "configure" |
| 12144 | #include "confdefs.h" |
| 12145 | |
| 12146 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 12147 | #ifdef __cplusplus |
| 12148 | extern "C" |
| 12149 | #endif |
| 12150 | /* We use char because int might match the return type of a gcc2 |
| 12151 | builtin and then its argument prototype would still apply. */ |
| 12152 | char XOpenDisplay (); |
| 12153 | int |
| 12154 | main () |
| 12155 | { |
| 12156 | XOpenDisplay (); |
| 12157 | ; |
| 12158 | return 0; |
| 12159 | } |
| 12160 | _ACEOF |
| 12161 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12162 | if { (eval echo "$as_me:12162: \"$ac_link\"") >&5 |
| 12163 | (eval $ac_link) 2>&5 |
| 12164 | ac_status=$? |
| 12165 | echo "$as_me:12165: \$? = $ac_status" >&5 |
| 12166 | (exit $ac_status); } && |
| 12167 | { ac_try='test -s conftest$ac_exeext' |
| 12168 | { (eval echo "$as_me:12168: \"$ac_try\"") >&5 |
| 12169 | (eval $ac_try) 2>&5 |
| 12170 | ac_status=$? |
| 12171 | echo "$as_me:12171: \$? = $ac_status" >&5 |
| 12172 | (exit $ac_status); }; }; then |
| 12173 | ac_cv_lib_X11_XOpenDisplay=yes |
| 12174 | else |
| 12175 | echo "$as_me: failed program was:" >&5 |
| 12176 | cat conftest.$ac_ext >&5 |
| 12177 | ac_cv_lib_X11_XOpenDisplay=no |
| 12178 | fi |
| 12179 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12180 | LIBS=$ac_check_lib_save_LIBS |
| 12181 | fi |
| 12182 | echo "$as_me:12182: result: $ac_cv_lib_X11_XOpenDisplay" >&5 |
| 12183 | echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6 |
| 12184 | if test $ac_cv_lib_X11_XOpenDisplay = yes; then |
| 12185 | |
| 12186 | cf_add_libs="-lX11" |
| 12187 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12188 | for cf_add_1lib in $LIBS |
| 12189 | do |
| 12190 | for cf_add_2lib in $cf_add_libs |
| 12191 | do |
| 12192 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12193 | then |
| 12194 | cf_add_1lib= |
| 12195 | break |
| 12196 | fi |
| 12197 | done |
| 12198 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12199 | done |
| 12200 | LIBS="$cf_add_libs" |
| 12201 | |
| 12202 | fi |
| 12203 | |
| 12204 | fi |
| 12205 | |
| 12206 | echo "$as_me:12206: checking for XtAppInitialize" >&5 |
| 12207 | echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6 |
| 12208 | if test "${ac_cv_func_XtAppInitialize+set}" = set; then |
| 12209 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12210 | else |
| 12211 | cat >conftest.$ac_ext <<_ACEOF |
| 12212 | #line 12212 "configure" |
| 12213 | #include "confdefs.h" |
| 12214 | /* System header to define __stub macros and hopefully few prototypes, |
| 12215 | which can conflict with char XtAppInitialize (); below. */ |
| 12216 | #include <assert.h> |
| 12217 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 12218 | #ifdef __cplusplus |
| 12219 | extern "C" |
| 12220 | #endif |
| 12221 | /* We use char because int might match the return type of a gcc2 |
| 12222 | builtin and then its argument prototype would still apply. */ |
| 12223 | char XtAppInitialize (); |
| 12224 | char (*f) (); |
| 12225 | |
| 12226 | int |
| 12227 | main () |
| 12228 | { |
| 12229 | /* The GNU C library defines this for functions which it implements |
| 12230 | to always fail with ENOSYS. Some functions are actually named |
| 12231 | something starting with __ and the normal name is an alias. */ |
| 12232 | #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize) |
| 12233 | choke me |
| 12234 | #else |
| 12235 | f = XtAppInitialize; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 12236 | #endif |
| 12237 | |
| 12238 | ; |
| 12239 | return 0; |
| 12240 | } |
| 12241 | _ACEOF |
| 12242 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12243 | if { (eval echo "$as_me:12243: \"$ac_link\"") >&5 |
| 12244 | (eval $ac_link) 2>&5 |
| 12245 | ac_status=$? |
| 12246 | echo "$as_me:12246: \$? = $ac_status" >&5 |
| 12247 | (exit $ac_status); } && |
| 12248 | { ac_try='test -s conftest$ac_exeext' |
| 12249 | { (eval echo "$as_me:12249: \"$ac_try\"") >&5 |
| 12250 | (eval $ac_try) 2>&5 |
| 12251 | ac_status=$? |
| 12252 | echo "$as_me:12252: \$? = $ac_status" >&5 |
| 12253 | (exit $ac_status); }; }; then |
| 12254 | ac_cv_func_XtAppInitialize=yes |
| 12255 | else |
| 12256 | echo "$as_me: failed program was:" >&5 |
| 12257 | cat conftest.$ac_ext >&5 |
| 12258 | ac_cv_func_XtAppInitialize=no |
| 12259 | fi |
| 12260 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12261 | fi |
| 12262 | echo "$as_me:12262: result: $ac_cv_func_XtAppInitialize" >&5 |
| 12263 | echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6 |
| 12264 | if test $ac_cv_func_XtAppInitialize = yes; then |
| 12265 | : |
| 12266 | else |
| 12267 | |
| 12268 | echo "$as_me:12268: checking for XtAppInitialize in -lXt" >&5 |
| 12269 | echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6 |
| 12270 | if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then |
| 12271 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12272 | else |
| 12273 | ac_check_lib_save_LIBS=$LIBS |
| 12274 | LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" |
| 12275 | cat >conftest.$ac_ext <<_ACEOF |
| 12276 | #line 12276 "configure" |
| 12277 | #include "confdefs.h" |
| 12278 | |
| 12279 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 12280 | #ifdef __cplusplus |
| 12281 | extern "C" |
| 12282 | #endif |
| 12283 | /* We use char because int might match the return type of a gcc2 |
| 12284 | builtin and then its argument prototype would still apply. */ |
| 12285 | char XtAppInitialize (); |
| 12286 | int |
| 12287 | main () |
| 12288 | { |
| 12289 | XtAppInitialize (); |
| 12290 | ; |
| 12291 | return 0; |
| 12292 | } |
| 12293 | _ACEOF |
| 12294 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12295 | if { (eval echo "$as_me:12295: \"$ac_link\"") >&5 |
| 12296 | (eval $ac_link) 2>&5 |
| 12297 | ac_status=$? |
| 12298 | echo "$as_me:12298: \$? = $ac_status" >&5 |
| 12299 | (exit $ac_status); } && |
| 12300 | { ac_try='test -s conftest$ac_exeext' |
| 12301 | { (eval echo "$as_me:12301: \"$ac_try\"") >&5 |
| 12302 | (eval $ac_try) 2>&5 |
| 12303 | ac_status=$? |
| 12304 | echo "$as_me:12304: \$? = $ac_status" >&5 |
| 12305 | (exit $ac_status); }; }; then |
| 12306 | ac_cv_lib_Xt_XtAppInitialize=yes |
| 12307 | else |
| 12308 | echo "$as_me: failed program was:" >&5 |
| 12309 | cat conftest.$ac_ext >&5 |
| 12310 | ac_cv_lib_Xt_XtAppInitialize=no |
| 12311 | fi |
| 12312 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12313 | LIBS=$ac_check_lib_save_LIBS |
| 12314 | fi |
| 12315 | echo "$as_me:12315: result: $ac_cv_lib_Xt_XtAppInitialize" >&5 |
| 12316 | echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6 |
| 12317 | if test $ac_cv_lib_Xt_XtAppInitialize = yes; then |
| 12318 | |
| 12319 | cat >>confdefs.h <<\EOF |
| 12320 | #define HAVE_LIBXT 1 |
| 12321 | EOF |
| 12322 | |
| 12323 | cf_have_X_LIBS=Xt |
| 12324 | LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS" |
| 12325 | fi |
| 12326 | |
| 12327 | fi |
| 12328 | |
| 12329 | fi |
| 12330 | |
| 12331 | if test $cf_have_X_LIBS = no ; then |
| 12332 | { echo "$as_me:12332: WARNING: Unable to successfully link X Toolkit library (-lXt) with |
| 12333 | test program. You will have to check and add the proper libraries by hand |
| 12334 | to makefile." >&5 |
| 12335 | echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with |
| 12336 | test program. You will have to check and add the proper libraries by hand |
| 12337 | to makefile." >&2;} |
| 12338 | fi |
| 12339 | |
| 12340 | cf_x_athena_root=$cf_x_athena |
| 12341 | cf_x_athena_inc="" |
| 12342 | |
| 12343 | for cf_path in default \ |
| 12344 | /usr/contrib/X11R6 \ |
| 12345 | /usr/contrib/X11R5 \ |
| 12346 | /usr/lib/X11R5 \ |
| 12347 | /usr/local |
| 12348 | do |
| 12349 | if test -z "$cf_x_athena_inc" ; then |
| 12350 | cf_save="$CPPFLAGS" |
| 12351 | cf_test=X11/$cf_x_athena_root/SimpleMenu.h |
| 12352 | if test $cf_path != default ; then |
| 12353 | CPPFLAGS="$cf_save -I$cf_path/include" |
| 12354 | echo "$as_me:12354: checking for $cf_test in $cf_path" >&5 |
| 12355 | echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6 |
| 12356 | else |
| 12357 | echo "$as_me:12357: checking for $cf_test" >&5 |
| 12358 | echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6 |
| 12359 | fi |
| 12360 | cat >conftest.$ac_ext <<_ACEOF |
| 12361 | #line 12361 "configure" |
| 12362 | #include "confdefs.h" |
| 12363 | |
| 12364 | #include <X11/Intrinsic.h> |
| 12365 | #include <$cf_test> |
| 12366 | int |
| 12367 | main () |
| 12368 | { |
| 12369 | |
| 12370 | ; |
| 12371 | return 0; |
| 12372 | } |
| 12373 | _ACEOF |
| 12374 | rm -f conftest.$ac_objext |
| 12375 | if { (eval echo "$as_me:12375: \"$ac_compile\"") >&5 |
| 12376 | (eval $ac_compile) 2>&5 |
| 12377 | ac_status=$? |
| 12378 | echo "$as_me:12378: \$? = $ac_status" >&5 |
| 12379 | (exit $ac_status); } && |
| 12380 | { ac_try='test -s conftest.$ac_objext' |
| 12381 | { (eval echo "$as_me:12381: \"$ac_try\"") >&5 |
| 12382 | (eval $ac_try) 2>&5 |
| 12383 | ac_status=$? |
| 12384 | echo "$as_me:12384: \$? = $ac_status" >&5 |
| 12385 | (exit $ac_status); }; }; then |
| 12386 | cf_result=yes |
| 12387 | else |
| 12388 | echo "$as_me: failed program was:" >&5 |
| 12389 | cat conftest.$ac_ext >&5 |
| 12390 | cf_result=no |
| 12391 | fi |
| 12392 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 12393 | echo "$as_me:12393: result: $cf_result" >&5 |
| 12394 | echo "${ECHO_T}$cf_result" >&6 |
| 12395 | if test "$cf_result" = yes ; then |
| 12396 | cf_x_athena_inc=$cf_path |
| 12397 | break |
| 12398 | else |
| 12399 | CPPFLAGS="$cf_save" |
| 12400 | fi |
| 12401 | fi |
| 12402 | done |
| 12403 | |
| 12404 | if test -z "$cf_x_athena_inc" ; then |
| 12405 | { echo "$as_me:12405: WARNING: Unable to successfully find Athena header files with test program" >&5 |
| 12406 | echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;} |
| 12407 | elif test "$cf_x_athena_inc" != default ; then |
| 12408 | CPPFLAGS="$CPPFLAGS -I$cf_x_athena_inc" |
| 12409 | fi |
| 12410 | |
| 12411 | cf_x_athena_root=$cf_x_athena |
| 12412 | cf_x_athena_lib="" |
| 12413 | |
| 12414 | for cf_path in default \ |
| 12415 | /usr/contrib/X11R6 \ |
| 12416 | /usr/contrib/X11R5 \ |
| 12417 | /usr/lib/X11R5 \ |
| 12418 | /usr/local |
| 12419 | do |
| 12420 | for cf_lib in \ |
| 12421 | ${cf_x_athena_root} \ |
| 12422 | ${cf_x_athena_root}7 \ |
| 12423 | ${cf_x_athena_root}6 |
| 12424 | do |
| 12425 | for cf_libs in \ |
| 12426 | "-l$cf_lib -lXmu" \ |
| 12427 | "-l$cf_lib -lXpm -lXmu" \ |
| 12428 | "-l${cf_lib}_s -lXmu_s" |
| 12429 | do |
| 12430 | if test -z "$cf_x_athena_lib" ; then |
| 12431 | cf_save="$LIBS" |
| 12432 | cf_test=XawSimpleMenuAddGlobalActions |
| 12433 | if test $cf_path != default ; then |
| 12434 | |
| 12435 | cf_add_libs="-L$cf_path/lib $cf_libs" |
| 12436 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12437 | for cf_add_1lib in $LIBS |
| 12438 | do |
| 12439 | for cf_add_2lib in $cf_add_libs |
| 12440 | do |
| 12441 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12442 | then |
| 12443 | cf_add_1lib= |
| 12444 | break |
| 12445 | fi |
| 12446 | done |
| 12447 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12448 | done |
| 12449 | LIBS="$cf_add_libs" |
| 12450 | |
| 12451 | echo "$as_me:12451: checking for $cf_libs in $cf_path" >&5 |
| 12452 | echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6 |
| 12453 | else |
| 12454 | |
| 12455 | cf_add_libs="$cf_libs" |
| 12456 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12457 | for cf_add_1lib in $LIBS |
| 12458 | do |
| 12459 | for cf_add_2lib in $cf_add_libs |
| 12460 | do |
| 12461 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12462 | then |
| 12463 | cf_add_1lib= |
| 12464 | break |
| 12465 | fi |
| 12466 | done |
| 12467 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12468 | done |
| 12469 | LIBS="$cf_add_libs" |
| 12470 | |
| 12471 | echo "$as_me:12471: checking for $cf_test in $cf_libs" >&5 |
| 12472 | echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6 |
| 12473 | fi |
| 12474 | cat >conftest.$ac_ext <<_ACEOF |
| 12475 | #line 12475 "configure" |
| 12476 | #include "confdefs.h" |
| 12477 | |
| 12478 | #include <X11/Intrinsic.h> |
| 12479 | #include <X11/$cf_x_athena_root/SimpleMenu.h> |
| 12480 | |
| 12481 | int |
| 12482 | main () |
| 12483 | { |
| 12484 | |
| 12485 | $cf_test((XtAppContext) 0) |
| 12486 | ; |
| 12487 | return 0; |
| 12488 | } |
| 12489 | _ACEOF |
| 12490 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12491 | if { (eval echo "$as_me:12491: \"$ac_link\"") >&5 |
| 12492 | (eval $ac_link) 2>&5 |
| 12493 | ac_status=$? |
| 12494 | echo "$as_me:12494: \$? = $ac_status" >&5 |
| 12495 | (exit $ac_status); } && |
| 12496 | { ac_try='test -s conftest$ac_exeext' |
| 12497 | { (eval echo "$as_me:12497: \"$ac_try\"") >&5 |
| 12498 | (eval $ac_try) 2>&5 |
| 12499 | ac_status=$? |
| 12500 | echo "$as_me:12500: \$? = $ac_status" >&5 |
| 12501 | (exit $ac_status); }; }; then |
| 12502 | cf_result=yes |
| 12503 | else |
| 12504 | echo "$as_me: failed program was:" >&5 |
| 12505 | cat conftest.$ac_ext >&5 |
| 12506 | cf_result=no |
| 12507 | fi |
| 12508 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12509 | echo "$as_me:12509: result: $cf_result" >&5 |
| 12510 | echo "${ECHO_T}$cf_result" >&6 |
| 12511 | if test "$cf_result" = yes ; then |
| 12512 | cf_x_athena_lib="$cf_libs" |
| 12513 | break |
| 12514 | fi |
| 12515 | LIBS="$cf_save" |
| 12516 | fi |
| 12517 | done # cf_libs |
| 12518 | test -n "$cf_x_athena_lib" && break |
| 12519 | done # cf_lib |
| 12520 | done |
| 12521 | |
| 12522 | if test -z "$cf_x_athena_lib" ; then |
| 12523 | { { echo "$as_me:12523: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5 |
| 12524 | echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;} |
| 12525 | { (exit 1); exit 1; }; } |
| 12526 | fi |
| 12527 | |
| 12528 | cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 12529 | |
| 12530 | cat >>confdefs.h <<EOF |
| 12531 | #define $cf_x_athena_LIBS 1 |
| 12532 | EOF |
| 12533 | |
| 12534 | fi |
| 12535 | |
| 12536 | if test -n "$ac_tool_prefix"; then |
| 12537 | for ac_prog in xcurses-config |
| 12538 | do |
| 12539 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 12540 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
| 12541 | echo "$as_me:12541: checking for $ac_word" >&5 |
| 12542 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 12543 | if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then |
| 12544 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12545 | else |
| 12546 | if test -n "$XCURSES_CONFIG"; then |
| 12547 | ac_cv_prog_XCURSES_CONFIG="$XCURSES_CONFIG" # Let the user override the test. |
| 12548 | else |
| 12549 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 12550 | ac_dummy="$PATH" |
| 12551 | for ac_dir in $ac_dummy; do |
| 12552 | IFS=$ac_save_IFS |
| 12553 | test -z "$ac_dir" && ac_dir=. |
| 12554 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 12555 | ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog" |
| 12556 | echo "$as_me:12556: found $ac_dir/$ac_word" >&5 |
| 12557 | break |
| 12558 | done |
| 12559 | |
| 12560 | fi |
| 12561 | fi |
| 12562 | XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG |
| 12563 | if test -n "$XCURSES_CONFIG"; then |
| 12564 | echo "$as_me:12564: result: $XCURSES_CONFIG" >&5 |
| 12565 | echo "${ECHO_T}$XCURSES_CONFIG" >&6 |
| 12566 | else |
| 12567 | echo "$as_me:12567: result: no" >&5 |
| 12568 | echo "${ECHO_T}no" >&6 |
| 12569 | fi |
| 12570 | |
| 12571 | test -n "$XCURSES_CONFIG" && break |
| 12572 | done |
| 12573 | fi |
| 12574 | if test -z "$XCURSES_CONFIG"; then |
| 12575 | ac_ct_XCURSES_CONFIG=$XCURSES_CONFIG |
| 12576 | for ac_prog in xcurses-config |
| 12577 | do |
| 12578 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 12579 | set dummy $ac_prog; ac_word=$2 |
| 12580 | echo "$as_me:12580: checking for $ac_word" >&5 |
| 12581 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 12582 | if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then |
| 12583 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12584 | else |
| 12585 | if test -n "$ac_ct_XCURSES_CONFIG"; then |
| 12586 | ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_ct_XCURSES_CONFIG" # Let the user override the test. |
| 12587 | else |
| 12588 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 12589 | ac_dummy="$PATH" |
| 12590 | for ac_dir in $ac_dummy; do |
| 12591 | IFS=$ac_save_IFS |
| 12592 | test -z "$ac_dir" && ac_dir=. |
| 12593 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 12594 | ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog" |
| 12595 | echo "$as_me:12595: found $ac_dir/$ac_word" >&5 |
| 12596 | break |
| 12597 | done |
| 12598 | |
| 12599 | fi |
| 12600 | fi |
| 12601 | ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG |
| 12602 | if test -n "$ac_ct_XCURSES_CONFIG"; then |
| 12603 | echo "$as_me:12603: result: $ac_ct_XCURSES_CONFIG" >&5 |
| 12604 | echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6 |
| 12605 | else |
| 12606 | echo "$as_me:12606: result: no" >&5 |
| 12607 | echo "${ECHO_T}no" >&6 |
| 12608 | fi |
| 12609 | |
| 12610 | test -n "$ac_ct_XCURSES_CONFIG" && break |
| 12611 | done |
| 12612 | test -n "$ac_ct_XCURSES_CONFIG" || ac_ct_XCURSES_CONFIG="none" |
| 12613 | |
| 12614 | XCURSES_CONFIG=$ac_ct_XCURSES_CONFIG |
| 12615 | fi |
| 12616 | |
| 12617 | if test "$XCURSES_CONFIG" != none ; then |
| 12618 | |
| 12619 | CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`" |
| 12620 | |
| 12621 | cf_add_libs="`$XCURSES_CONFIG --libs`" |
| 12622 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12623 | for cf_add_1lib in $LIBS |
| 12624 | do |
| 12625 | for cf_add_2lib in $cf_add_libs |
| 12626 | do |
| 12627 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12628 | then |
| 12629 | cf_add_1lib= |
| 12630 | break |
| 12631 | fi |
| 12632 | done |
| 12633 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12634 | done |
| 12635 | LIBS="$cf_add_libs" |
| 12636 | |
| 12637 | cf_cv_lib_XCurses=yes |
| 12638 | |
| 12639 | else |
| 12640 | |
| 12641 | LDFLAGS="$LDFLAGS $X_LIBS" |
| 12642 | |
| 12643 | test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6 |
| 12644 | |
| 12645 | echo "${as_me:-configure}:12645: testing checking additions to CFLAGS ..." 1>&5 |
| 12646 | |
| 12647 | cf_check_cflags="$CFLAGS" |
| 12648 | cf_check_cppflags="$CPPFLAGS" |
| 12649 | |
| 12650 | cf_fix_cppflags=no |
| 12651 | cf_new_cflags= |
| 12652 | cf_new_cppflags= |
| 12653 | cf_new_extra_cppflags= |
| 12654 | |
| 12655 | for cf_add_cflags in $X_CFLAGS |
| 12656 | do |
| 12657 | case $cf_fix_cppflags in |
| 12658 | (no) |
| 12659 | case $cf_add_cflags in |
| 12660 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 12661 | case $cf_add_cflags in |
| 12662 | (-D*) |
| 12663 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 12664 | |
| 12665 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 12666 | && test -z "${cf_tst_cflags}" \ |
| 12667 | && cf_fix_cppflags=yes |
| 12668 | |
| 12669 | if test $cf_fix_cppflags = yes ; then |
| 12670 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 12671 | continue |
| 12672 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 12673 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 12674 | continue |
| 12675 | fi |
| 12676 | ;; |
| 12677 | esac |
| 12678 | case "$CPPFLAGS" in |
| 12679 | (*$cf_add_cflags) |
| 12680 | ;; |
| 12681 | (*) |
| 12682 | case $cf_add_cflags in |
| 12683 | (-D*) |
| 12684 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 12685 | |
| 12686 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 12687 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 12688 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 12689 | |
| 12690 | ;; |
| 12691 | esac |
| 12692 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 12693 | ;; |
| 12694 | esac |
| 12695 | ;; |
| 12696 | (*) |
| 12697 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 12698 | ;; |
| 12699 | esac |
| 12700 | ;; |
| 12701 | (yes) |
| 12702 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 12703 | |
| 12704 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 12705 | |
| 12706 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 12707 | && test -z "${cf_tst_cflags}" \ |
| 12708 | && cf_fix_cppflags=no |
| 12709 | ;; |
| 12710 | esac |
| 12711 | done |
| 12712 | |
| 12713 | if test -n "$cf_new_cflags" ; then |
| 12714 | test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6 |
| 12715 | |
| 12716 | echo "${as_me:-configure}:12716: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5 |
| 12717 | |
| 12718 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 12719 | fi |
| 12720 | |
| 12721 | if test -n "$cf_new_cppflags" ; then |
| 12722 | test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6 |
| 12723 | |
| 12724 | echo "${as_me:-configure}:12724: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5 |
| 12725 | |
| 12726 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 12727 | fi |
| 12728 | |
| 12729 | if test -n "$cf_new_extra_cppflags" ; then |
| 12730 | test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6 |
| 12731 | |
| 12732 | echo "${as_me:-configure}:12732: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5 |
| 12733 | |
| 12734 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 12735 | fi |
| 12736 | |
| 12737 | if test "x$cf_check_cflags" != "x$CFLAGS" ; then |
| 12738 | cat >conftest.$ac_ext <<_ACEOF |
| 12739 | #line 12739 "configure" |
| 12740 | #include "confdefs.h" |
| 12741 | #include <stdio.h> |
| 12742 | int |
| 12743 | main () |
| 12744 | { |
| 12745 | printf("Hello world"); |
| 12746 | ; |
| 12747 | return 0; |
| 12748 | } |
| 12749 | _ACEOF |
| 12750 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12751 | if { (eval echo "$as_me:12751: \"$ac_link\"") >&5 |
| 12752 | (eval $ac_link) 2>&5 |
| 12753 | ac_status=$? |
| 12754 | echo "$as_me:12754: \$? = $ac_status" >&5 |
| 12755 | (exit $ac_status); } && |
| 12756 | { ac_try='test -s conftest$ac_exeext' |
| 12757 | { (eval echo "$as_me:12757: \"$ac_try\"") >&5 |
| 12758 | (eval $ac_try) 2>&5 |
| 12759 | ac_status=$? |
| 12760 | echo "$as_me:12760: \$? = $ac_status" >&5 |
| 12761 | (exit $ac_status); }; }; then |
| 12762 | : |
| 12763 | else |
| 12764 | echo "$as_me: failed program was:" >&5 |
| 12765 | cat conftest.$ac_ext >&5 |
| 12766 | test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6 |
| 12767 | |
| 12768 | echo "${as_me:-configure}:12768: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5 |
| 12769 | |
| 12770 | if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then |
| 12771 | test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6 |
| 12772 | |
| 12773 | echo "${as_me:-configure}:12773: testing but keeping change to \$CPPFLAGS ..." 1>&5 |
| 12774 | |
| 12775 | fi |
| 12776 | CFLAGS="$cf_check_flags" |
| 12777 | fi |
| 12778 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12779 | fi |
| 12780 | |
| 12781 | echo "$as_me:12781: checking for XOpenDisplay in -lX11" >&5 |
| 12782 | echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6 |
| 12783 | if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then |
| 12784 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12785 | else |
| 12786 | ac_check_lib_save_LIBS=$LIBS |
| 12787 | LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS" |
| 12788 | cat >conftest.$ac_ext <<_ACEOF |
| 12789 | #line 12789 "configure" |
| 12790 | #include "confdefs.h" |
| 12791 | |
| 12792 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 12793 | #ifdef __cplusplus |
| 12794 | extern "C" |
| 12795 | #endif |
| 12796 | /* We use char because int might match the return type of a gcc2 |
| 12797 | builtin and then its argument prototype would still apply. */ |
| 12798 | char XOpenDisplay (); |
| 12799 | int |
| 12800 | main () |
| 12801 | { |
| 12802 | XOpenDisplay (); |
| 12803 | ; |
| 12804 | return 0; |
| 12805 | } |
| 12806 | _ACEOF |
| 12807 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12808 | if { (eval echo "$as_me:12808: \"$ac_link\"") >&5 |
| 12809 | (eval $ac_link) 2>&5 |
| 12810 | ac_status=$? |
| 12811 | echo "$as_me:12811: \$? = $ac_status" >&5 |
| 12812 | (exit $ac_status); } && |
| 12813 | { ac_try='test -s conftest$ac_exeext' |
| 12814 | { (eval echo "$as_me:12814: \"$ac_try\"") >&5 |
| 12815 | (eval $ac_try) 2>&5 |
| 12816 | ac_status=$? |
| 12817 | echo "$as_me:12817: \$? = $ac_status" >&5 |
| 12818 | (exit $ac_status); }; }; then |
| 12819 | ac_cv_lib_X11_XOpenDisplay=yes |
| 12820 | else |
| 12821 | echo "$as_me: failed program was:" >&5 |
| 12822 | cat conftest.$ac_ext >&5 |
| 12823 | ac_cv_lib_X11_XOpenDisplay=no |
| 12824 | fi |
| 12825 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12826 | LIBS=$ac_check_lib_save_LIBS |
| 12827 | fi |
| 12828 | echo "$as_me:12828: result: $ac_cv_lib_X11_XOpenDisplay" >&5 |
| 12829 | echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6 |
| 12830 | if test $ac_cv_lib_X11_XOpenDisplay = yes; then |
| 12831 | |
| 12832 | cf_add_libs="-lX11" |
| 12833 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12834 | for cf_add_1lib in $LIBS |
| 12835 | do |
| 12836 | for cf_add_2lib in $cf_add_libs |
| 12837 | do |
| 12838 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12839 | then |
| 12840 | cf_add_1lib= |
| 12841 | break |
| 12842 | fi |
| 12843 | done |
| 12844 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12845 | done |
| 12846 | LIBS="$cf_add_libs" |
| 12847 | |
| 12848 | fi |
| 12849 | |
| 12850 | echo "$as_me:12850: checking for XCurses library" >&5 |
| 12851 | echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6 |
| 12852 | if test "${cf_cv_lib_XCurses+set}" = set; then |
| 12853 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12854 | else |
| 12855 | |
| 12856 | cf_add_libs="-lXCurses" |
| 12857 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12858 | for cf_add_1lib in $LIBS |
| 12859 | do |
| 12860 | for cf_add_2lib in $cf_add_libs |
| 12861 | do |
| 12862 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12863 | then |
| 12864 | cf_add_1lib= |
| 12865 | break |
| 12866 | fi |
| 12867 | done |
| 12868 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12869 | done |
| 12870 | LIBS="$cf_add_libs" |
| 12871 | |
| 12872 | cat >conftest.$ac_ext <<_ACEOF |
| 12873 | #line 12873 "configure" |
| 12874 | #include "confdefs.h" |
| 12875 | |
| 12876 | #include <xcurses.h> |
| 12877 | char *XCursesProgramName = "test"; |
| 12878 | |
| 12879 | int |
| 12880 | main () |
| 12881 | { |
| 12882 | XCursesExit(); |
| 12883 | ; |
| 12884 | return 0; |
| 12885 | } |
| 12886 | _ACEOF |
| 12887 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12888 | if { (eval echo "$as_me:12888: \"$ac_link\"") >&5 |
| 12889 | (eval $ac_link) 2>&5 |
| 12890 | ac_status=$? |
| 12891 | echo "$as_me:12891: \$? = $ac_status" >&5 |
| 12892 | (exit $ac_status); } && |
| 12893 | { ac_try='test -s conftest$ac_exeext' |
| 12894 | { (eval echo "$as_me:12894: \"$ac_try\"") >&5 |
| 12895 | (eval $ac_try) 2>&5 |
| 12896 | ac_status=$? |
| 12897 | echo "$as_me:12897: \$? = $ac_status" >&5 |
| 12898 | (exit $ac_status); }; }; then |
| 12899 | cf_cv_lib_XCurses=yes |
| 12900 | else |
| 12901 | echo "$as_me: failed program was:" >&5 |
| 12902 | cat conftest.$ac_ext >&5 |
| 12903 | cf_cv_lib_XCurses=no |
| 12904 | fi |
| 12905 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12906 | |
| 12907 | fi |
| 12908 | echo "$as_me:12908: result: $cf_cv_lib_XCurses" >&5 |
| 12909 | echo "${ECHO_T}$cf_cv_lib_XCurses" >&6 |
| 12910 | |
| 12911 | fi |
| 12912 | |
| 12913 | if test $cf_cv_lib_XCurses = yes ; then |
| 12914 | |
| 12915 | cat >>confdefs.h <<\EOF |
| 12916 | #define UNIX 1 |
| 12917 | EOF |
| 12918 | |
| 12919 | cat >>confdefs.h <<\EOF |
| 12920 | #define XCURSES 1 |
| 12921 | EOF |
| 12922 | |
| 12923 | echo "$as_me:12923: checking for xcurses.h" >&5 |
| 12924 | echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6 |
| 12925 | if test "${ac_cv_header_xcurses_h+set}" = set; then |
| 12926 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12927 | else |
| 12928 | cat >conftest.$ac_ext <<_ACEOF |
| 12929 | #line 12929 "configure" |
| 12930 | #include "confdefs.h" |
| 12931 | #include <xcurses.h> |
| 12932 | _ACEOF |
| 12933 | if { (eval echo "$as_me:12933: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 12934 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 12935 | ac_status=$? |
| 12936 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 12937 | rm -f conftest.er1 |
| 12938 | cat conftest.err >&5 |
| 12939 | echo "$as_me:12939: \$? = $ac_status" >&5 |
| 12940 | (exit $ac_status); } >/dev/null; then |
| 12941 | if test -s conftest.err; then |
| 12942 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 12943 | else |
| 12944 | ac_cpp_err= |
| 12945 | fi |
| 12946 | else |
| 12947 | ac_cpp_err=yes |
| 12948 | fi |
| 12949 | if test -z "$ac_cpp_err"; then |
| 12950 | ac_cv_header_xcurses_h=yes |
| 12951 | else |
| 12952 | echo "$as_me: failed program was:" >&5 |
| 12953 | cat conftest.$ac_ext >&5 |
| 12954 | ac_cv_header_xcurses_h=no |
| 12955 | fi |
| 12956 | rm -f conftest.err conftest.$ac_ext |
| 12957 | fi |
| 12958 | echo "$as_me:12958: result: $ac_cv_header_xcurses_h" >&5 |
| 12959 | echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6 |
| 12960 | if test $ac_cv_header_xcurses_h = yes; then |
| 12961 | |
| 12962 | cat >>confdefs.h <<\EOF |
| 12963 | #define HAVE_XCURSES 1 |
| 12964 | EOF |
| 12965 | |
| 12966 | fi |
| 12967 | |
| 12968 | else |
| 12969 | { { echo "$as_me:12969: error: Cannot link with XCurses" >&5 |
| 12970 | echo "$as_me: error: Cannot link with XCurses" >&2;} |
| 12971 | { (exit 1); exit 1; }; } |
| 12972 | fi |
| 12973 | |
| 12974 | ;; |
| 12975 | (*) |
| 12976 | { { echo "$as_me:12976: error: unexpected screen-value: $cf_cv_screen" >&5 |
| 12977 | echo "$as_me: error: unexpected screen-value: $cf_cv_screen" >&2;} |
| 12978 | { (exit 1); exit 1; }; } |
| 12979 | ;; |
| 12980 | esac |
| 12981 | |
| 12982 | case $cf_cv_screen in |
| 12983 | (ncurses*) |
| 12984 | cf_cv_libtype=`echo "$cf_cv_screen" | sed -e 's/^ncurses//'` |
| 12985 | ;; |
| 12986 | (curses|curses_*) |
| 12987 | |
| 12988 | echo "$as_me:12988: checking for NetBSD form.h" >&5 |
| 12989 | echo $ECHO_N "checking for NetBSD form.h... $ECHO_C" >&6 |
| 12990 | if test "${cf_cv_netbsd_form_h+set}" = set; then |
| 12991 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12992 | else |
| 12993 | |
| 12994 | cat >conftest.$ac_ext <<_ACEOF |
| 12995 | #line 12995 "configure" |
| 12996 | #include "confdefs.h" |
| 12997 | |
| 12998 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 12999 | #include <form.h> |
| 13000 | |
| 13001 | int |
| 13002 | main () |
| 13003 | { |
| 13004 | |
| 13005 | FORM *form; |
| 13006 | int y = current_field(form)->cursor_ypos; |
| 13007 | int x = current_field(form)->cursor_xpos; |
| 13008 | |
| 13009 | ; |
| 13010 | return 0; |
| 13011 | } |
| 13012 | _ACEOF |
| 13013 | rm -f conftest.$ac_objext |
| 13014 | if { (eval echo "$as_me:13014: \"$ac_compile\"") >&5 |
| 13015 | (eval $ac_compile) 2>&5 |
| 13016 | ac_status=$? |
| 13017 | echo "$as_me:13017: \$? = $ac_status" >&5 |
| 13018 | (exit $ac_status); } && |
| 13019 | { ac_try='test -s conftest.$ac_objext' |
| 13020 | { (eval echo "$as_me:13020: \"$ac_try\"") >&5 |
| 13021 | (eval $ac_try) 2>&5 |
| 13022 | ac_status=$? |
| 13023 | echo "$as_me:13023: \$? = $ac_status" >&5 |
| 13024 | (exit $ac_status); }; }; then |
| 13025 | cf_cv_netbsd_form_h=yes |
| 13026 | |
| 13027 | else |
| 13028 | echo "$as_me: failed program was:" >&5 |
| 13029 | cat conftest.$ac_ext >&5 |
| 13030 | cf_cv_netbsd_form_h=no |
| 13031 | fi |
| 13032 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 13033 | |
| 13034 | fi |
| 13035 | echo "$as_me:13035: result: $cf_cv_netbsd_form_h" >&5 |
| 13036 | echo "${ECHO_T}$cf_cv_netbsd_form_h" >&6 |
| 13037 | |
| 13038 | test "$cf_cv_netbsd_form_h" = yes && |
| 13039 | cat >>confdefs.h <<\EOF |
| 13040 | #define HAVE_NETBSD_FORM_H 1 |
| 13041 | EOF |
| 13042 | |
| 13043 | echo "$as_me:13043: checking for NetBSD menu.h" >&5 |
| 13044 | echo $ECHO_N "checking for NetBSD menu.h... $ECHO_C" >&6 |
| 13045 | if test "${cf_cv_netbsd_menu_h+set}" = set; then |
| 13046 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13047 | else |
| 13048 | |
| 13049 | cat >conftest.$ac_ext <<_ACEOF |
| 13050 | #line 13050 "configure" |
| 13051 | #include "confdefs.h" |
| 13052 | |
| 13053 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 13054 | #include <menu.h> |
| 13055 | |
| 13056 | int |
| 13057 | main () |
| 13058 | { |
| 13059 | |
| 13060 | MENU *menu; |
| 13061 | int y = menu->max_item_width; |
| 13062 | |
| 13063 | ; |
| 13064 | return 0; |
| 13065 | } |
| 13066 | _ACEOF |
| 13067 | rm -f conftest.$ac_objext |
| 13068 | if { (eval echo "$as_me:13068: \"$ac_compile\"") >&5 |
| 13069 | (eval $ac_compile) 2>&5 |
| 13070 | ac_status=$? |
| 13071 | echo "$as_me:13071: \$? = $ac_status" >&5 |
| 13072 | (exit $ac_status); } && |
| 13073 | { ac_try='test -s conftest.$ac_objext' |
| 13074 | { (eval echo "$as_me:13074: \"$ac_try\"") >&5 |
| 13075 | (eval $ac_try) 2>&5 |
| 13076 | ac_status=$? |
| 13077 | echo "$as_me:13077: \$? = $ac_status" >&5 |
| 13078 | (exit $ac_status); }; }; then |
| 13079 | cf_cv_netbsd_menu_h=yes |
| 13080 | |
| 13081 | else |
| 13082 | echo "$as_me: failed program was:" >&5 |
| 13083 | cat conftest.$ac_ext >&5 |
| 13084 | cf_cv_netbsd_menu_h=no |
| 13085 | fi |
| 13086 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 13087 | |
| 13088 | fi |
| 13089 | echo "$as_me:13089: result: $cf_cv_netbsd_menu_h" >&5 |
| 13090 | echo "${ECHO_T}$cf_cv_netbsd_menu_h" >&6 |
| 13091 | |
| 13092 | test "$cf_cv_netbsd_menu_h" = yes && |
| 13093 | cat >>confdefs.h <<\EOF |
| 13094 | #define HAVE_NETBSD_MENU_H 1 |
| 13095 | EOF |
| 13096 | |
| 13097 | ;; |
| 13098 | esac |
| 13099 | |
| 13100 | case $cf_cv_screen in |
| 13101 | (pdcurses) |
| 13102 | ;; |
| 13103 | (*) |
| 13104 | # look for curses-related libraries |
| 13105 | |
| 13106 | as_ac_Lib=`echo "ac_cv_lib_panel$cf_cv_libtype''_new_panel" | $as_tr_sh` |
| 13107 | echo "$as_me:13107: checking for new_panel in -lpanel$cf_cv_libtype" >&5 |
| 13108 | echo $ECHO_N "checking for new_panel in -lpanel$cf_cv_libtype... $ECHO_C" >&6 |
| 13109 | if eval "test \"\${$as_ac_Lib+set}\" = set"; then |
| 13110 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13111 | else |
| 13112 | ac_check_lib_save_LIBS=$LIBS |
| 13113 | LIBS="-lpanel$cf_cv_libtype $LIBS" |
| 13114 | cat >conftest.$ac_ext <<_ACEOF |
| 13115 | #line 13115 "configure" |
| 13116 | #include "confdefs.h" |
| 13117 | |
| 13118 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 13119 | #ifdef __cplusplus |
| 13120 | extern "C" |
| 13121 | #endif |
| 13122 | /* We use char because int might match the return type of a gcc2 |
| 13123 | builtin and then its argument prototype would still apply. */ |
| 13124 | char new_panel (); |
| 13125 | int |
| 13126 | main () |
| 13127 | { |
| 13128 | new_panel (); |
| 13129 | ; |
| 13130 | return 0; |
| 13131 | } |
| 13132 | _ACEOF |
| 13133 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13134 | if { (eval echo "$as_me:13134: \"$ac_link\"") >&5 |
| 13135 | (eval $ac_link) 2>&5 |
| 13136 | ac_status=$? |
| 13137 | echo "$as_me:13137: \$? = $ac_status" >&5 |
| 13138 | (exit $ac_status); } && |
| 13139 | { ac_try='test -s conftest$ac_exeext' |
| 13140 | { (eval echo "$as_me:13140: \"$ac_try\"") >&5 |
| 13141 | (eval $ac_try) 2>&5 |
| 13142 | ac_status=$? |
| 13143 | echo "$as_me:13143: \$? = $ac_status" >&5 |
| 13144 | (exit $ac_status); }; }; then |
| 13145 | eval "$as_ac_Lib=yes" |
| 13146 | else |
| 13147 | echo "$as_me: failed program was:" >&5 |
| 13148 | cat conftest.$ac_ext >&5 |
| 13149 | eval "$as_ac_Lib=no" |
| 13150 | fi |
| 13151 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13152 | LIBS=$ac_check_lib_save_LIBS |
| 13153 | fi |
| 13154 | echo "$as_me:13154: result: `eval echo '${'$as_ac_Lib'}'`" >&5 |
| 13155 | echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 |
| 13156 | if test `eval echo '${'$as_ac_Lib'}'` = yes; then |
| 13157 | |
| 13158 | cf_upper=`echo "have_libpanel" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 13159 | |
| 13160 | cf_add_libs="-lpanel$cf_cv_libtype" |
| 13161 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 13162 | for cf_add_1lib in $LIBS |
| 13163 | do |
| 13164 | for cf_add_2lib in $cf_add_libs |
| 13165 | do |
| 13166 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 13167 | then |
| 13168 | cf_add_1lib= |
| 13169 | break |
| 13170 | fi |
| 13171 | done |
| 13172 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 13173 | done |
| 13174 | LIBS="$cf_add_libs" |
| 13175 | |
| 13176 | cat >>confdefs.h <<EOF |
| 13177 | #define $cf_upper 1 |
| 13178 | EOF |
| 13179 | |
| 13180 | fi |
| 13181 | |
| 13182 | as_ac_Lib=`echo "ac_cv_lib_menu$cf_cv_libtype''_menu_driver" | $as_tr_sh` |
| 13183 | echo "$as_me:13183: checking for menu_driver in -lmenu$cf_cv_libtype" >&5 |
| 13184 | echo $ECHO_N "checking for menu_driver in -lmenu$cf_cv_libtype... $ECHO_C" >&6 |
| 13185 | if eval "test \"\${$as_ac_Lib+set}\" = set"; then |
| 13186 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13187 | else |
| 13188 | ac_check_lib_save_LIBS=$LIBS |
| 13189 | LIBS="-lmenu$cf_cv_libtype $LIBS" |
| 13190 | cat >conftest.$ac_ext <<_ACEOF |
| 13191 | #line 13191 "configure" |
| 13192 | #include "confdefs.h" |
| 13193 | |
| 13194 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 13195 | #ifdef __cplusplus |
| 13196 | extern "C" |
| 13197 | #endif |
| 13198 | /* We use char because int might match the return type of a gcc2 |
| 13199 | builtin and then its argument prototype would still apply. */ |
| 13200 | char menu_driver (); |
| 13201 | int |
| 13202 | main () |
| 13203 | { |
| 13204 | menu_driver (); |
| 13205 | ; |
| 13206 | return 0; |
| 13207 | } |
| 13208 | _ACEOF |
| 13209 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13210 | if { (eval echo "$as_me:13210: \"$ac_link\"") >&5 |
| 13211 | (eval $ac_link) 2>&5 |
| 13212 | ac_status=$? |
| 13213 | echo "$as_me:13213: \$? = $ac_status" >&5 |
| 13214 | (exit $ac_status); } && |
| 13215 | { ac_try='test -s conftest$ac_exeext' |
| 13216 | { (eval echo "$as_me:13216: \"$ac_try\"") >&5 |
| 13217 | (eval $ac_try) 2>&5 |
| 13218 | ac_status=$? |
| 13219 | echo "$as_me:13219: \$? = $ac_status" >&5 |
| 13220 | (exit $ac_status); }; }; then |
| 13221 | eval "$as_ac_Lib=yes" |
| 13222 | else |
| 13223 | echo "$as_me: failed program was:" >&5 |
| 13224 | cat conftest.$ac_ext >&5 |
| 13225 | eval "$as_ac_Lib=no" |
| 13226 | fi |
| 13227 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13228 | LIBS=$ac_check_lib_save_LIBS |
| 13229 | fi |
| 13230 | echo "$as_me:13230: result: `eval echo '${'$as_ac_Lib'}'`" >&5 |
| 13231 | echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 |
| 13232 | if test `eval echo '${'$as_ac_Lib'}'` = yes; then |
| 13233 | |
| 13234 | cf_upper=`echo "have_libmenu" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 13235 | |
| 13236 | cf_add_libs="-lmenu$cf_cv_libtype" |
| 13237 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 13238 | for cf_add_1lib in $LIBS |
| 13239 | do |
| 13240 | for cf_add_2lib in $cf_add_libs |
| 13241 | do |
| 13242 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 13243 | then |
| 13244 | cf_add_1lib= |
| 13245 | break |
| 13246 | fi |
| 13247 | done |
| 13248 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 13249 | done |
| 13250 | LIBS="$cf_add_libs" |
| 13251 | |
| 13252 | cat >>confdefs.h <<EOF |
| 13253 | #define $cf_upper 1 |
| 13254 | EOF |
| 13255 | |
| 13256 | fi |
| 13257 | |
| 13258 | as_ac_Lib=`echo "ac_cv_lib_form$cf_cv_libtype''_form_driver" | $as_tr_sh` |
| 13259 | echo "$as_me:13259: checking for form_driver in -lform$cf_cv_libtype" >&5 |
| 13260 | echo $ECHO_N "checking for form_driver in -lform$cf_cv_libtype... $ECHO_C" >&6 |
| 13261 | if eval "test \"\${$as_ac_Lib+set}\" = set"; then |
| 13262 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13263 | else |
| 13264 | ac_check_lib_save_LIBS=$LIBS |
| 13265 | LIBS="-lform$cf_cv_libtype $LIBS" |
| 13266 | cat >conftest.$ac_ext <<_ACEOF |
| 13267 | #line 13267 "configure" |
| 13268 | #include "confdefs.h" |
| 13269 | |
| 13270 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 13271 | #ifdef __cplusplus |
| 13272 | extern "C" |
| 13273 | #endif |
| 13274 | /* We use char because int might match the return type of a gcc2 |
| 13275 | builtin and then its argument prototype would still apply. */ |
| 13276 | char form_driver (); |
| 13277 | int |
| 13278 | main () |
| 13279 | { |
| 13280 | form_driver (); |
| 13281 | ; |
| 13282 | return 0; |
| 13283 | } |
| 13284 | _ACEOF |
| 13285 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13286 | if { (eval echo "$as_me:13286: \"$ac_link\"") >&5 |
| 13287 | (eval $ac_link) 2>&5 |
| 13288 | ac_status=$? |
| 13289 | echo "$as_me:13289: \$? = $ac_status" >&5 |
| 13290 | (exit $ac_status); } && |
| 13291 | { ac_try='test -s conftest$ac_exeext' |
| 13292 | { (eval echo "$as_me:13292: \"$ac_try\"") >&5 |
| 13293 | (eval $ac_try) 2>&5 |
| 13294 | ac_status=$? |
| 13295 | echo "$as_me:13295: \$? = $ac_status" >&5 |
| 13296 | (exit $ac_status); }; }; then |
| 13297 | eval "$as_ac_Lib=yes" |
| 13298 | else |
| 13299 | echo "$as_me: failed program was:" >&5 |
| 13300 | cat conftest.$ac_ext >&5 |
| 13301 | eval "$as_ac_Lib=no" |
| 13302 | fi |
| 13303 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13304 | LIBS=$ac_check_lib_save_LIBS |
| 13305 | fi |
| 13306 | echo "$as_me:13306: result: `eval echo '${'$as_ac_Lib'}'`" >&5 |
| 13307 | echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 |
| 13308 | if test `eval echo '${'$as_ac_Lib'}'` = yes; then |
| 13309 | |
| 13310 | cf_upper=`echo "have_libform" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 13311 | |
| 13312 | cf_add_libs="-lform$cf_cv_libtype" |
| 13313 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 13314 | for cf_add_1lib in $LIBS |
| 13315 | do |
| 13316 | for cf_add_2lib in $cf_add_libs |
| 13317 | do |
| 13318 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 13319 | then |
| 13320 | cf_add_1lib= |
| 13321 | break |
| 13322 | fi |
| 13323 | done |
| 13324 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 13325 | done |
| 13326 | LIBS="$cf_add_libs" |
| 13327 | |
| 13328 | cat >>confdefs.h <<EOF |
| 13329 | #define $cf_upper 1 |
| 13330 | EOF |
| 13331 | |
| 13332 | fi |
| 13333 | |
| 13334 | # look for curses-related headers |
| 13335 | |
| 13336 | for ac_header in \ |
| 13337 | nc_alloc.h \ |
| 13338 | nomacros.h \ |
| 13339 | form.h \ |
| 13340 | menu.h \ |
| 13341 | panel.h \ |
| 13342 | term_entry.h \ |
| 13343 | |
| 13344 | do |
| 13345 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 13346 | echo "$as_me:13346: checking for $ac_header" >&5 |
| 13347 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 13348 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 13349 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13350 | else |
| 13351 | cat >conftest.$ac_ext <<_ACEOF |
| 13352 | #line 13352 "configure" |
| 13353 | #include "confdefs.h" |
| 13354 | #include <$ac_header> |
| 13355 | _ACEOF |
| 13356 | if { (eval echo "$as_me:13356: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 13357 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 13358 | ac_status=$? |
| 13359 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 13360 | rm -f conftest.er1 |
| 13361 | cat conftest.err >&5 |
| 13362 | echo "$as_me:13362: \$? = $ac_status" >&5 |
| 13363 | (exit $ac_status); } >/dev/null; then |
| 13364 | if test -s conftest.err; then |
| 13365 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 13366 | else |
| 13367 | ac_cpp_err= |
| 13368 | fi |
| 13369 | else |
| 13370 | ac_cpp_err=yes |
| 13371 | fi |
| 13372 | if test -z "$ac_cpp_err"; then |
| 13373 | eval "$as_ac_Header=yes" |
| 13374 | else |
| 13375 | echo "$as_me: failed program was:" >&5 |
| 13376 | cat conftest.$ac_ext >&5 |
| 13377 | eval "$as_ac_Header=no" |
| 13378 | fi |
| 13379 | rm -f conftest.err conftest.$ac_ext |
| 13380 | fi |
| 13381 | echo "$as_me:13381: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 13382 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 13383 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 13384 | cat >>confdefs.h <<EOF |
| 13385 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 13386 | EOF |
| 13387 | |
| 13388 | fi |
| 13389 | done |
| 13390 | |
| 13391 | ;; |
| 13392 | esac |
| 13393 | |
| 13394 | echo "$as_me:13394: checking for ANSI C header files" >&5 |
| 13395 | echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6 |
| 13396 | if test "${ac_cv_header_stdc+set}" = set; then |
| 13397 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13398 | else |
| 13399 | cat >conftest.$ac_ext <<_ACEOF |
| 13400 | #line 13400 "configure" |
| 13401 | #include "confdefs.h" |
| 13402 | #include <stdlib.h> |
| 13403 | #include <stdarg.h> |
| 13404 | #include <string.h> |
| 13405 | #include <float.h> |
| 13406 | |
| 13407 | _ACEOF |
| 13408 | if { (eval echo "$as_me:13408: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 13409 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 13410 | ac_status=$? |
| 13411 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 13412 | rm -f conftest.er1 |
| 13413 | cat conftest.err >&5 |
| 13414 | echo "$as_me:13414: \$? = $ac_status" >&5 |
| 13415 | (exit $ac_status); } >/dev/null; then |
| 13416 | if test -s conftest.err; then |
| 13417 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 13418 | else |
| 13419 | ac_cpp_err= |
| 13420 | fi |
| 13421 | else |
| 13422 | ac_cpp_err=yes |
| 13423 | fi |
| 13424 | if test -z "$ac_cpp_err"; then |
| 13425 | ac_cv_header_stdc=yes |
| 13426 | else |
| 13427 | echo "$as_me: failed program was:" >&5 |
| 13428 | cat conftest.$ac_ext >&5 |
| 13429 | ac_cv_header_stdc=no |
| 13430 | fi |
| 13431 | rm -f conftest.err conftest.$ac_ext |
| 13432 | |
| 13433 | if test $ac_cv_header_stdc = yes; then |
| 13434 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 13435 | cat >conftest.$ac_ext <<_ACEOF |
| 13436 | #line 13436 "configure" |
| 13437 | #include "confdefs.h" |
| 13438 | #include <string.h> |
| 13439 | |
| 13440 | _ACEOF |
| 13441 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 13442 | egrep "memchr" >/dev/null 2>&1; then |
| 13443 | : |
| 13444 | else |
| 13445 | ac_cv_header_stdc=no |
| 13446 | fi |
| 13447 | rm -rf conftest* |
| 13448 | |
| 13449 | fi |
| 13450 | |
| 13451 | if test $ac_cv_header_stdc = yes; then |
| 13452 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 13453 | cat >conftest.$ac_ext <<_ACEOF |
| 13454 | #line 13454 "configure" |
| 13455 | #include "confdefs.h" |
| 13456 | #include <stdlib.h> |
| 13457 | |
| 13458 | _ACEOF |
| 13459 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 13460 | egrep "free" >/dev/null 2>&1; then |
| 13461 | : |
| 13462 | else |
| 13463 | ac_cv_header_stdc=no |
| 13464 | fi |
| 13465 | rm -rf conftest* |
| 13466 | |
| 13467 | fi |
| 13468 | |
| 13469 | if test $ac_cv_header_stdc = yes; then |
| 13470 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 13471 | if test "$cross_compiling" = yes; then |
| 13472 | : |
| 13473 | else |
| 13474 | cat >conftest.$ac_ext <<_ACEOF |
| 13475 | #line 13475 "configure" |
| 13476 | #include "confdefs.h" |
| 13477 | #include <ctype.h> |
| 13478 | #if ((' ' & 0x0FF) == 0x020) |
| 13479 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 13480 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 13481 | #else |
| 13482 | # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \ |
| 13483 | || ('j' <= (c) && (c) <= 'r') \ |
| 13484 | || ('s' <= (c) && (c) <= 'z')) |
| 13485 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 13486 | #endif |
| 13487 | |
| 13488 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 13489 | int |
| 13490 | main () |
| 13491 | { |
| 13492 | int i; |
| 13493 | for (i = 0; i < 256; i++) |
| 13494 | if (XOR (islower (i), ISLOWER (i)) |
| 13495 | || toupper (i) != TOUPPER (i)) |
| 13496 | $ac_main_return(2); |
| 13497 | $ac_main_return (0); |
| 13498 | } |
| 13499 | _ACEOF |
| 13500 | rm -f conftest$ac_exeext |
| 13501 | if { (eval echo "$as_me:13501: \"$ac_link\"") >&5 |
| 13502 | (eval $ac_link) 2>&5 |
| 13503 | ac_status=$? |
| 13504 | echo "$as_me:13504: \$? = $ac_status" >&5 |
| 13505 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 13506 | { (eval echo "$as_me:13506: \"$ac_try\"") >&5 |
| 13507 | (eval $ac_try) 2>&5 |
| 13508 | ac_status=$? |
| 13509 | echo "$as_me:13509: \$? = $ac_status" >&5 |
| 13510 | (exit $ac_status); }; }; then |
| 13511 | : |
| 13512 | else |
| 13513 | echo "$as_me: program exited with status $ac_status" >&5 |
| 13514 | echo "$as_me: failed program was:" >&5 |
| 13515 | cat conftest.$ac_ext >&5 |
| 13516 | ac_cv_header_stdc=no |
| 13517 | fi |
| 13518 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 13519 | fi |
| 13520 | fi |
| 13521 | fi |
| 13522 | echo "$as_me:13522: result: $ac_cv_header_stdc" >&5 |
| 13523 | echo "${ECHO_T}$ac_cv_header_stdc" >&6 |
| 13524 | if test $ac_cv_header_stdc = yes; then |
| 13525 | |
| 13526 | cat >>confdefs.h <<\EOF |
| 13527 | #define STDC_HEADERS 1 |
| 13528 | EOF |
| 13529 | |
| 13530 | fi |
| 13531 | |
| 13532 | echo "$as_me:13532: checking whether time.h and sys/time.h may both be included" >&5 |
| 13533 | echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6 |
| 13534 | if test "${ac_cv_header_time+set}" = set; then |
| 13535 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13536 | else |
| 13537 | cat >conftest.$ac_ext <<_ACEOF |
| 13538 | #line 13538 "configure" |
| 13539 | #include "confdefs.h" |
| 13540 | #include <sys/types.h> |
| 13541 | #include <sys/time.h> |
| 13542 | #include <time.h> |
| 13543 | |
| 13544 | int |
| 13545 | main () |
| 13546 | { |
| 13547 | if ((struct tm *) 0) |
| 13548 | return 0; |
| 13549 | ; |
| 13550 | return 0; |
| 13551 | } |
| 13552 | _ACEOF |
| 13553 | rm -f conftest.$ac_objext |
| 13554 | if { (eval echo "$as_me:13554: \"$ac_compile\"") >&5 |
| 13555 | (eval $ac_compile) 2>&5 |
| 13556 | ac_status=$? |
| 13557 | echo "$as_me:13557: \$? = $ac_status" >&5 |
| 13558 | (exit $ac_status); } && |
| 13559 | { ac_try='test -s conftest.$ac_objext' |
| 13560 | { (eval echo "$as_me:13560: \"$ac_try\"") >&5 |
| 13561 | (eval $ac_try) 2>&5 |
| 13562 | ac_status=$? |
| 13563 | echo "$as_me:13563: \$? = $ac_status" >&5 |
| 13564 | (exit $ac_status); }; }; then |
| 13565 | ac_cv_header_time=yes |
| 13566 | else |
| 13567 | echo "$as_me: failed program was:" >&5 |
| 13568 | cat conftest.$ac_ext >&5 |
| 13569 | ac_cv_header_time=no |
| 13570 | fi |
| 13571 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 13572 | fi |
| 13573 | echo "$as_me:13573: result: $ac_cv_header_time" >&5 |
| 13574 | echo "${ECHO_T}$ac_cv_header_time" >&6 |
| 13575 | if test $ac_cv_header_time = yes; then |
| 13576 | |
| 13577 | cat >>confdefs.h <<\EOF |
| 13578 | #define TIME_WITH_SYS_TIME 1 |
| 13579 | EOF |
| 13580 | |
| 13581 | fi |
| 13582 | |
| 13583 | for ac_header in \ |
| 13584 | getopt.h \ |
| 13585 | locale.h \ |
| 13586 | math.h \ |
| 13587 | stdarg.h \ |
| 13588 | sys/ioctl.h \ |
| 13589 | sys/select.h \ |
| 13590 | sys/time.h \ |
| 13591 | termios.h \ |
| 13592 | unistd.h \ |
| 13593 | |
| 13594 | do |
| 13595 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 13596 | echo "$as_me:13596: checking for $ac_header" >&5 |
| 13597 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 13598 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 13599 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13600 | else |
| 13601 | cat >conftest.$ac_ext <<_ACEOF |
| 13602 | #line 13602 "configure" |
| 13603 | #include "confdefs.h" |
| 13604 | #include <$ac_header> |
| 13605 | _ACEOF |
| 13606 | if { (eval echo "$as_me:13606: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 13607 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 13608 | ac_status=$? |
| 13609 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 13610 | rm -f conftest.er1 |
| 13611 | cat conftest.err >&5 |
| 13612 | echo "$as_me:13612: \$? = $ac_status" >&5 |
| 13613 | (exit $ac_status); } >/dev/null; then |
| 13614 | if test -s conftest.err; then |
| 13615 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 13616 | else |
| 13617 | ac_cpp_err= |
| 13618 | fi |
| 13619 | else |
| 13620 | ac_cpp_err=yes |
| 13621 | fi |
| 13622 | if test -z "$ac_cpp_err"; then |
| 13623 | eval "$as_ac_Header=yes" |
| 13624 | else |
| 13625 | echo "$as_me: failed program was:" >&5 |
| 13626 | cat conftest.$ac_ext >&5 |
| 13627 | eval "$as_ac_Header=no" |
| 13628 | fi |
| 13629 | rm -f conftest.err conftest.$ac_ext |
| 13630 | fi |
| 13631 | echo "$as_me:13631: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 13632 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 13633 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 13634 | cat >>confdefs.h <<EOF |
| 13635 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 13636 | EOF |
| 13637 | |
| 13638 | fi |
| 13639 | done |
| 13640 | |
| 13641 | for ac_header in unistd.h getopt.h |
| 13642 | do |
| 13643 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 13644 | echo "$as_me:13644: checking for $ac_header" >&5 |
| 13645 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 13646 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 13647 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13648 | else |
| 13649 | cat >conftest.$ac_ext <<_ACEOF |
| 13650 | #line 13650 "configure" |
| 13651 | #include "confdefs.h" |
| 13652 | #include <$ac_header> |
| 13653 | _ACEOF |
| 13654 | if { (eval echo "$as_me:13654: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 13655 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 13656 | ac_status=$? |
| 13657 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 13658 | rm -f conftest.er1 |
| 13659 | cat conftest.err >&5 |
| 13660 | echo "$as_me:13660: \$? = $ac_status" >&5 |
| 13661 | (exit $ac_status); } >/dev/null; then |
| 13662 | if test -s conftest.err; then |
| 13663 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 13664 | else |
| 13665 | ac_cpp_err= |
| 13666 | fi |
| 13667 | else |
| 13668 | ac_cpp_err=yes |
| 13669 | fi |
| 13670 | if test -z "$ac_cpp_err"; then |
| 13671 | eval "$as_ac_Header=yes" |
| 13672 | else |
| 13673 | echo "$as_me: failed program was:" >&5 |
| 13674 | cat conftest.$ac_ext >&5 |
| 13675 | eval "$as_ac_Header=no" |
| 13676 | fi |
| 13677 | rm -f conftest.err conftest.$ac_ext |
| 13678 | fi |
| 13679 | echo "$as_me:13679: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 13680 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 13681 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 13682 | cat >>confdefs.h <<EOF |
| 13683 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 13684 | EOF |
| 13685 | |
| 13686 | fi |
| 13687 | done |
| 13688 | |
| 13689 | echo "$as_me:13689: checking for header declaring getopt variables" >&5 |
| 13690 | echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6 |
| 13691 | if test "${cf_cv_getopt_header+set}" = set; then |
| 13692 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13693 | else |
| 13694 | |
| 13695 | cf_cv_getopt_header=none |
| 13696 | for cf_header in stdio.h stdlib.h unistd.h getopt.h |
| 13697 | do |
| 13698 | cat >conftest.$ac_ext <<_ACEOF |
| 13699 | #line 13699 "configure" |
| 13700 | #include "confdefs.h" |
| 13701 | |
| 13702 | #include <$cf_header> |
| 13703 | int |
| 13704 | main () |
| 13705 | { |
| 13706 | int x = optind; char *y = optarg |
| 13707 | ; |
| 13708 | return 0; |
| 13709 | } |
| 13710 | _ACEOF |
| 13711 | rm -f conftest.$ac_objext |
| 13712 | if { (eval echo "$as_me:13712: \"$ac_compile\"") >&5 |
| 13713 | (eval $ac_compile) 2>&5 |
| 13714 | ac_status=$? |
| 13715 | echo "$as_me:13715: \$? = $ac_status" >&5 |
| 13716 | (exit $ac_status); } && |
| 13717 | { ac_try='test -s conftest.$ac_objext' |
| 13718 | { (eval echo "$as_me:13718: \"$ac_try\"") >&5 |
| 13719 | (eval $ac_try) 2>&5 |
| 13720 | ac_status=$? |
| 13721 | echo "$as_me:13721: \$? = $ac_status" >&5 |
| 13722 | (exit $ac_status); }; }; then |
| 13723 | cf_cv_getopt_header=$cf_header |
| 13724 | break |
| 13725 | else |
| 13726 | echo "$as_me: failed program was:" >&5 |
| 13727 | cat conftest.$ac_ext >&5 |
| 13728 | fi |
| 13729 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 13730 | done |
| 13731 | |
| 13732 | fi |
| 13733 | echo "$as_me:13733: result: $cf_cv_getopt_header" >&5 |
| 13734 | echo "${ECHO_T}$cf_cv_getopt_header" >&6 |
| 13735 | if test $cf_cv_getopt_header != none ; then |
| 13736 | |
| 13737 | cat >>confdefs.h <<\EOF |
| 13738 | #define HAVE_GETOPT_HEADER 1 |
| 13739 | EOF |
| 13740 | |
| 13741 | fi |
| 13742 | if test $cf_cv_getopt_header = getopt.h ; then |
| 13743 | |
| 13744 | cat >>confdefs.h <<\EOF |
| 13745 | #define NEED_GETOPT_H 1 |
| 13746 | EOF |
| 13747 | |
| 13748 | fi |
| 13749 | |
| 13750 | for ac_func in \ |
| 13751 | getopt \ |
| 13752 | gettimeofday \ |
| 13753 | |
| 13754 | do |
| 13755 | as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 13756 | echo "$as_me:13756: checking for $ac_func" >&5 |
| 13757 | echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 |
| 13758 | if eval "test \"\${$as_ac_var+set}\" = set"; then |
| 13759 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13760 | else |
| 13761 | cat >conftest.$ac_ext <<_ACEOF |
| 13762 | #line 13762 "configure" |
| 13763 | #include "confdefs.h" |
| 13764 | /* System header to define __stub macros and hopefully few prototypes, |
| 13765 | which can conflict with char $ac_func (); below. */ |
| 13766 | #include <assert.h> |
| 13767 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 13768 | #ifdef __cplusplus |
| 13769 | extern "C" |
| 13770 | #endif |
| 13771 | /* We use char because int might match the return type of a gcc2 |
| 13772 | builtin and then its argument prototype would still apply. */ |
| 13773 | char $ac_func (); |
| 13774 | char (*f) (); |
| 13775 | |
| 13776 | int |
| 13777 | main () |
| 13778 | { |
| 13779 | /* The GNU C library defines this for functions which it implements |
| 13780 | to always fail with ENOSYS. Some functions are actually named |
| 13781 | something starting with __ and the normal name is an alias. */ |
| 13782 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 13783 | choke me |
| 13784 | #else |
| 13785 | f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 13786 | #endif |
| 13787 | |
| 13788 | ; |
| 13789 | return 0; |
| 13790 | } |
| 13791 | _ACEOF |
| 13792 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13793 | if { (eval echo "$as_me:13793: \"$ac_link\"") >&5 |
| 13794 | (eval $ac_link) 2>&5 |
| 13795 | ac_status=$? |
| 13796 | echo "$as_me:13796: \$? = $ac_status" >&5 |
| 13797 | (exit $ac_status); } && |
| 13798 | { ac_try='test -s conftest$ac_exeext' |
| 13799 | { (eval echo "$as_me:13799: \"$ac_try\"") >&5 |
| 13800 | (eval $ac_try) 2>&5 |
| 13801 | ac_status=$? |
| 13802 | echo "$as_me:13802: \$? = $ac_status" >&5 |
| 13803 | (exit $ac_status); }; }; then |
| 13804 | eval "$as_ac_var=yes" |
| 13805 | else |
| 13806 | echo "$as_me: failed program was:" >&5 |
| 13807 | cat conftest.$ac_ext >&5 |
| 13808 | eval "$as_ac_var=no" |
| 13809 | fi |
| 13810 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13811 | fi |
| 13812 | echo "$as_me:13812: result: `eval echo '${'$as_ac_var'}'`" >&5 |
| 13813 | echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 |
| 13814 | if test `eval echo '${'$as_ac_var'}'` = yes; then |
| 13815 | cat >>confdefs.h <<EOF |
| 13816 | #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 13817 | EOF |
| 13818 | |
| 13819 | fi |
| 13820 | done |
| 13821 | |
| 13822 | if test "x$ac_cv_func_getopt" = xno; then |
| 13823 | { { echo "$as_me:13823: error: getopt is required for building programs" >&5 |
| 13824 | echo "$as_me: error: getopt is required for building programs" >&2;} |
| 13825 | { (exit 1); exit 1; }; } |
| 13826 | fi |
| 13827 | |
| 13828 | if test "$cf_enable_widec" = yes; then |
| 13829 | |
| 13830 | for ac_func in \ |
| 13831 | mblen \ |
| 13832 | mbrlen \ |
| 13833 | mbrtowc \ |
| 13834 | mbsrtowcs \ |
| 13835 | mbstowcs \ |
| 13836 | mbtowc \ |
| 13837 | wcsrtombs \ |
| 13838 | wcstombs \ |
| 13839 | |
| 13840 | do |
| 13841 | as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 13842 | echo "$as_me:13842: checking for $ac_func" >&5 |
| 13843 | echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 |
| 13844 | if eval "test \"\${$as_ac_var+set}\" = set"; then |
| 13845 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13846 | else |
| 13847 | cat >conftest.$ac_ext <<_ACEOF |
| 13848 | #line 13848 "configure" |
| 13849 | #include "confdefs.h" |
| 13850 | /* System header to define __stub macros and hopefully few prototypes, |
| 13851 | which can conflict with char $ac_func (); below. */ |
| 13852 | #include <assert.h> |
| 13853 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 13854 | #ifdef __cplusplus |
| 13855 | extern "C" |
| 13856 | #endif |
| 13857 | /* We use char because int might match the return type of a gcc2 |
| 13858 | builtin and then its argument prototype would still apply. */ |
| 13859 | char $ac_func (); |
| 13860 | char (*f) (); |
| 13861 | |
| 13862 | int |
| 13863 | main () |
| 13864 | { |
| 13865 | /* The GNU C library defines this for functions which it implements |
| 13866 | to always fail with ENOSYS. Some functions are actually named |
| 13867 | something starting with __ and the normal name is an alias. */ |
| 13868 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 13869 | choke me |
| 13870 | #else |
| 13871 | f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 13872 | #endif |
| 13873 | |
| 13874 | ; |
| 13875 | return 0; |
| 13876 | } |
| 13877 | _ACEOF |
| 13878 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13879 | if { (eval echo "$as_me:13879: \"$ac_link\"") >&5 |
| 13880 | (eval $ac_link) 2>&5 |
| 13881 | ac_status=$? |
| 13882 | echo "$as_me:13882: \$? = $ac_status" >&5 |
| 13883 | (exit $ac_status); } && |
| 13884 | { ac_try='test -s conftest$ac_exeext' |
| 13885 | { (eval echo "$as_me:13885: \"$ac_try\"") >&5 |
| 13886 | (eval $ac_try) 2>&5 |
| 13887 | ac_status=$? |
| 13888 | echo "$as_me:13888: \$? = $ac_status" >&5 |
| 13889 | (exit $ac_status); }; }; then |
| 13890 | eval "$as_ac_var=yes" |
| 13891 | else |
| 13892 | echo "$as_me: failed program was:" >&5 |
| 13893 | cat conftest.$ac_ext >&5 |
| 13894 | eval "$as_ac_var=no" |
| 13895 | fi |
| 13896 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13897 | fi |
| 13898 | echo "$as_me:13898: result: `eval echo '${'$as_ac_var'}'`" >&5 |
| 13899 | echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 |
| 13900 | if test `eval echo '${'$as_ac_var'}'` = yes; then |
| 13901 | cat >>confdefs.h <<EOF |
| 13902 | #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 13903 | EOF |
| 13904 | |
| 13905 | fi |
| 13906 | done |
| 13907 | |
| 13908 | fi |
| 13909 | |
| 13910 | echo "$as_me:13910: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5 |
| 13911 | echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6 |
| 13912 | if test "${cf_cv_need_xopen_extension+set}" = set; then |
| 13913 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13914 | else |
| 13915 | |
| 13916 | cat >conftest.$ac_ext <<_ACEOF |
| 13917 | #line 13917 "configure" |
| 13918 | #include "confdefs.h" |
| 13919 | |
| 13920 | #include <stdlib.h> |
| 13921 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 13922 | int |
| 13923 | main () |
| 13924 | { |
| 13925 | |
| 13926 | #if defined(NCURSES_VERSION_PATCH) |
| 13927 | #if (NCURSES_VERSION_PATCH < 20100501) && (NCURSES_VERSION_PATCH >= 20100403) |
| 13928 | make an error |
| 13929 | #endif |
| 13930 | #endif |
| 13931 | long x = winnstr(stdscr, "", 0); |
| 13932 | int x1, y1; |
| 13933 | getbegyx(stdscr, y1, x1) |
| 13934 | ; |
| 13935 | return 0; |
| 13936 | } |
| 13937 | _ACEOF |
| 13938 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13939 | if { (eval echo "$as_me:13939: \"$ac_link\"") >&5 |
| 13940 | (eval $ac_link) 2>&5 |
| 13941 | ac_status=$? |
| 13942 | echo "$as_me:13942: \$? = $ac_status" >&5 |
| 13943 | (exit $ac_status); } && |
| 13944 | { ac_try='test -s conftest$ac_exeext' |
| 13945 | { (eval echo "$as_me:13945: \"$ac_try\"") >&5 |
| 13946 | (eval $ac_try) 2>&5 |
| 13947 | ac_status=$? |
| 13948 | echo "$as_me:13948: \$? = $ac_status" >&5 |
| 13949 | (exit $ac_status); }; }; then |
| 13950 | cf_cv_need_xopen_extension=no |
| 13951 | else |
| 13952 | echo "$as_me: failed program was:" >&5 |
| 13953 | cat conftest.$ac_ext >&5 |
| 13954 | cat >conftest.$ac_ext <<_ACEOF |
| 13955 | #line 13955 "configure" |
| 13956 | #include "confdefs.h" |
| 13957 | |
| 13958 | #define _XOPEN_SOURCE_EXTENDED |
| 13959 | #include <stdlib.h> |
| 13960 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 13961 | int |
| 13962 | main () |
| 13963 | { |
| 13964 | |
| 13965 | #ifdef NCURSES_VERSION |
| 13966 | cchar_t check; |
| 13967 | int check2 = curs_set((int)sizeof(check)); |
| 13968 | #endif |
| 13969 | long x = winnstr(stdscr, "", 0); |
| 13970 | int x1, y1; |
| 13971 | getbegyx(stdscr, y1, x1) |
| 13972 | ; |
| 13973 | return 0; |
| 13974 | } |
| 13975 | _ACEOF |
| 13976 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13977 | if { (eval echo "$as_me:13977: \"$ac_link\"") >&5 |
| 13978 | (eval $ac_link) 2>&5 |
| 13979 | ac_status=$? |
| 13980 | echo "$as_me:13980: \$? = $ac_status" >&5 |
| 13981 | (exit $ac_status); } && |
| 13982 | { ac_try='test -s conftest$ac_exeext' |
| 13983 | { (eval echo "$as_me:13983: \"$ac_try\"") >&5 |
| 13984 | (eval $ac_try) 2>&5 |
| 13985 | ac_status=$? |
| 13986 | echo "$as_me:13986: \$? = $ac_status" >&5 |
| 13987 | (exit $ac_status); }; }; then |
| 13988 | cf_cv_need_xopen_extension=yes |
| 13989 | else |
| 13990 | echo "$as_me: failed program was:" >&5 |
| 13991 | cat conftest.$ac_ext >&5 |
| 13992 | cf_cv_need_xopen_extension=unknown |
| 13993 | fi |
| 13994 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13995 | fi |
| 13996 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13997 | fi |
| 13998 | echo "$as_me:13998: result: $cf_cv_need_xopen_extension" >&5 |
| 13999 | echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6 |
| 14000 | test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED" |
| 14001 | |
| 14002 | echo "$as_me:14002: checking for term.h" >&5 |
| 14003 | echo $ECHO_N "checking for term.h... $ECHO_C" >&6 |
| 14004 | if test "${cf_cv_term_header+set}" = set; then |
| 14005 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14006 | else |
| 14007 | |
| 14008 | # If we found <ncurses/curses.h>, look for <ncurses/term.h>, but always look |
| 14009 | # for <term.h> if we do not find the variant. |
| 14010 | |
| 14011 | cf_header_list="term.h ncurses/term.h ncursesw/term.h" |
| 14012 | |
| 14013 | case ${cf_cv_ncurses_header:-curses.h} in |
| 14014 | (*/*) |
| 14015 | cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h |
| 14016 | cf_header_list="$cf_header_item $cf_header_list" |
| 14017 | ;; |
| 14018 | esac |
| 14019 | |
| 14020 | for cf_header in $cf_header_list |
| 14021 | do |
| 14022 | cat >conftest.$ac_ext <<_ACEOF |
| 14023 | #line 14023 "configure" |
| 14024 | #include "confdefs.h" |
| 14025 | |
| 14026 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14027 | #include <${cf_header}> |
| 14028 | int |
| 14029 | main () |
| 14030 | { |
| 14031 | WINDOW *x |
| 14032 | ; |
| 14033 | return 0; |
| 14034 | } |
| 14035 | _ACEOF |
| 14036 | rm -f conftest.$ac_objext |
| 14037 | if { (eval echo "$as_me:14037: \"$ac_compile\"") >&5 |
| 14038 | (eval $ac_compile) 2>&5 |
| 14039 | ac_status=$? |
| 14040 | echo "$as_me:14040: \$? = $ac_status" >&5 |
| 14041 | (exit $ac_status); } && |
| 14042 | { ac_try='test -s conftest.$ac_objext' |
| 14043 | { (eval echo "$as_me:14043: \"$ac_try\"") >&5 |
| 14044 | (eval $ac_try) 2>&5 |
| 14045 | ac_status=$? |
| 14046 | echo "$as_me:14046: \$? = $ac_status" >&5 |
| 14047 | (exit $ac_status); }; }; then |
| 14048 | cf_cv_term_header=$cf_header |
| 14049 | break |
| 14050 | else |
| 14051 | echo "$as_me: failed program was:" >&5 |
| 14052 | cat conftest.$ac_ext >&5 |
| 14053 | cf_cv_term_header=no |
| 14054 | fi |
| 14055 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14056 | done |
| 14057 | |
| 14058 | case $cf_cv_term_header in |
| 14059 | (no) |
| 14060 | # If curses is ncurses, some packagers still mess it up by trying to make |
| 14061 | # us use GNU termcap. This handles the most common case. |
| 14062 | for cf_header in ncurses/term.h ncursesw/term.h |
| 14063 | do |
| 14064 | cat >conftest.$ac_ext <<_ACEOF |
| 14065 | #line 14065 "configure" |
| 14066 | #include "confdefs.h" |
| 14067 | |
| 14068 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14069 | #ifdef NCURSES_VERSION |
| 14070 | #include <${cf_header}> |
| 14071 | #else |
| 14072 | make an error |
| 14073 | #endif |
| 14074 | int |
| 14075 | main () |
| 14076 | { |
| 14077 | WINDOW *x |
| 14078 | ; |
| 14079 | return 0; |
| 14080 | } |
| 14081 | _ACEOF |
| 14082 | rm -f conftest.$ac_objext |
| 14083 | if { (eval echo "$as_me:14083: \"$ac_compile\"") >&5 |
| 14084 | (eval $ac_compile) 2>&5 |
| 14085 | ac_status=$? |
| 14086 | echo "$as_me:14086: \$? = $ac_status" >&5 |
| 14087 | (exit $ac_status); } && |
| 14088 | { ac_try='test -s conftest.$ac_objext' |
| 14089 | { (eval echo "$as_me:14089: \"$ac_try\"") >&5 |
| 14090 | (eval $ac_try) 2>&5 |
| 14091 | ac_status=$? |
| 14092 | echo "$as_me:14092: \$? = $ac_status" >&5 |
| 14093 | (exit $ac_status); }; }; then |
| 14094 | cf_cv_term_header=$cf_header |
| 14095 | break |
| 14096 | else |
| 14097 | echo "$as_me: failed program was:" >&5 |
| 14098 | cat conftest.$ac_ext >&5 |
| 14099 | cf_cv_term_header=no |
| 14100 | fi |
| 14101 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14102 | done |
| 14103 | ;; |
| 14104 | esac |
| 14105 | |
| 14106 | fi |
| 14107 | echo "$as_me:14107: result: $cf_cv_term_header" >&5 |
| 14108 | echo "${ECHO_T}$cf_cv_term_header" >&6 |
| 14109 | |
| 14110 | case $cf_cv_term_header in |
| 14111 | (term.h) |
| 14112 | |
| 14113 | cat >>confdefs.h <<\EOF |
| 14114 | #define HAVE_TERM_H 1 |
| 14115 | EOF |
| 14116 | |
| 14117 | ;; |
| 14118 | (ncurses/term.h) |
| 14119 | |
| 14120 | cat >>confdefs.h <<\EOF |
| 14121 | #define HAVE_NCURSES_TERM_H 1 |
| 14122 | EOF |
| 14123 | |
| 14124 | ;; |
| 14125 | (ncursesw/term.h) |
| 14126 | |
| 14127 | cat >>confdefs.h <<\EOF |
| 14128 | #define HAVE_NCURSESW_TERM_H 1 |
| 14129 | EOF |
| 14130 | |
| 14131 | ;; |
| 14132 | esac |
| 14133 | |
| 14134 | echo "$as_me:14134: checking for unctrl.h" >&5 |
| 14135 | echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6 |
| 14136 | if test "${cf_cv_unctrl_header+set}" = set; then |
| 14137 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14138 | else |
| 14139 | |
| 14140 | # If we found <ncurses/curses.h>, look for <ncurses/unctrl.h>, but always look |
| 14141 | # for <unctrl.h> if we do not find the variant. |
| 14142 | |
| 14143 | cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h" |
| 14144 | |
| 14145 | case ${cf_cv_ncurses_header:-curses.h} in |
| 14146 | (*/*) |
| 14147 | cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h |
| 14148 | cf_header_list="$cf_header_item $cf_header_list" |
| 14149 | ;; |
| 14150 | esac |
| 14151 | |
| 14152 | for cf_header in $cf_header_list |
| 14153 | do |
| 14154 | cat >conftest.$ac_ext <<_ACEOF |
| 14155 | #line 14155 "configure" |
| 14156 | #include "confdefs.h" |
| 14157 | |
| 14158 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14159 | #include <${cf_header}> |
| 14160 | int |
| 14161 | main () |
| 14162 | { |
| 14163 | WINDOW *x |
| 14164 | ; |
| 14165 | return 0; |
| 14166 | } |
| 14167 | _ACEOF |
| 14168 | rm -f conftest.$ac_objext |
| 14169 | if { (eval echo "$as_me:14169: \"$ac_compile\"") >&5 |
| 14170 | (eval $ac_compile) 2>&5 |
| 14171 | ac_status=$? |
| 14172 | echo "$as_me:14172: \$? = $ac_status" >&5 |
| 14173 | (exit $ac_status); } && |
| 14174 | { ac_try='test -s conftest.$ac_objext' |
| 14175 | { (eval echo "$as_me:14175: \"$ac_try\"") >&5 |
| 14176 | (eval $ac_try) 2>&5 |
| 14177 | ac_status=$? |
| 14178 | echo "$as_me:14178: \$? = $ac_status" >&5 |
| 14179 | (exit $ac_status); }; }; then |
| 14180 | cf_cv_unctrl_header=$cf_header |
| 14181 | break |
| 14182 | else |
| 14183 | echo "$as_me: failed program was:" >&5 |
| 14184 | cat conftest.$ac_ext >&5 |
| 14185 | cf_cv_unctrl_header=no |
| 14186 | fi |
| 14187 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14188 | done |
| 14189 | |
| 14190 | fi |
| 14191 | echo "$as_me:14191: result: $cf_cv_unctrl_header" >&5 |
| 14192 | echo "${ECHO_T}$cf_cv_unctrl_header" >&6 |
| 14193 | |
| 14194 | case $cf_cv_unctrl_header in |
| 14195 | (no) |
| 14196 | { echo "$as_me:14196: WARNING: unctrl.h header not found" >&5 |
| 14197 | echo "$as_me: WARNING: unctrl.h header not found" >&2;} |
| 14198 | ;; |
| 14199 | esac |
| 14200 | |
| 14201 | case $cf_cv_unctrl_header in |
| 14202 | (unctrl.h) |
| 14203 | |
| 14204 | cat >>confdefs.h <<\EOF |
| 14205 | #define HAVE_UNCTRL_H 1 |
| 14206 | EOF |
| 14207 | |
| 14208 | ;; |
| 14209 | (ncurses/unctrl.h) |
| 14210 | |
| 14211 | cat >>confdefs.h <<\EOF |
| 14212 | #define HAVE_NCURSES_UNCTRL_H 1 |
| 14213 | EOF |
| 14214 | |
| 14215 | ;; |
| 14216 | (ncursesw/unctrl.h) |
| 14217 | |
| 14218 | cat >>confdefs.h <<\EOF |
| 14219 | #define HAVE_NCURSESW_UNCTRL_H 1 |
| 14220 | EOF |
| 14221 | |
| 14222 | ;; |
| 14223 | esac |
| 14224 | |
| 14225 | for cf_func in \ |
| 14226 | assume_default_colors \ |
| 14227 | chgat \ |
| 14228 | color_set \ |
| 14229 | filter \ |
| 14230 | getbegx \ |
| 14231 | getcurx \ |
| 14232 | getmaxx \ |
| 14233 | getnstr \ |
| 14234 | getparx \ |
| 14235 | getwin \ |
| 14236 | mvvline \ |
| 14237 | mvwvline \ |
| 14238 | napms \ |
| 14239 | putwin \ |
| 14240 | resize_term \ |
| 14241 | resizeterm \ |
| 14242 | ripoffline \ |
| 14243 | scr_dump \ |
| 14244 | setupterm \ |
| 14245 | slk_color \ |
| 14246 | slk_init \ |
| 14247 | termattrs \ |
| 14248 | tgetent \ |
| 14249 | tigetnum \ |
| 14250 | tigetstr \ |
| 14251 | typeahead \ |
| 14252 | use_default_colors \ |
| 14253 | use_env \ |
| 14254 | use_extended_names \ |
| 14255 | use_screen \ |
| 14256 | use_window \ |
| 14257 | vid_puts \ |
| 14258 | vidputs \ |
| 14259 | vsscanf \ |
| 14260 | vw_printw \ |
| 14261 | wchgat \ |
| 14262 | winsstr \ |
| 14263 | wresize \ |
| 14264 | wsyncdown \ |
| 14265 | |
| 14266 | do |
| 14267 | |
| 14268 | cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 14269 | |
| 14270 | echo "$as_me:14270: checking for ${cf_func}" >&5 |
| 14271 | echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6 |
| 14272 | |
| 14273 | echo "${as_me:-configure}:14273: testing ${cf_func} ..." 1>&5 |
| 14274 | |
| 14275 | if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then |
| 14276 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14277 | else |
| 14278 | |
| 14279 | eval cf_result='$ac_cv_func_'$cf_func |
| 14280 | if test ".$cf_result" != ".no"; then |
| 14281 | cat >conftest.$ac_ext <<_ACEOF |
| 14282 | #line 14282 "configure" |
| 14283 | #include "confdefs.h" |
| 14284 | |
| 14285 | #ifdef HAVE_XCURSES |
| 14286 | #include <xcurses.h> |
| 14287 | char * XCursesProgramName = "test"; |
| 14288 | #else |
| 14289 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14290 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 14291 | #include <ncursesw/term.h> |
| 14292 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 14293 | #include <ncurses/term.h> |
| 14294 | #elif defined(HAVE_TERM_H) |
| 14295 | #include <term.h> |
| 14296 | #endif |
| 14297 | #endif |
| 14298 | |
| 14299 | int |
| 14300 | main () |
| 14301 | { |
| 14302 | |
| 14303 | #ifndef ${cf_func} |
| 14304 | long foo = (long)(&${cf_func}); |
| 14305 | fprintf(stderr, "testing linkage of $cf_func:%p\n", foo); |
| 14306 | if (foo + 1234 > 5678) |
| 14307 | ${cf_cv_main_return:-return}(foo); |
| 14308 | #endif |
| 14309 | |
| 14310 | ; |
| 14311 | return 0; |
| 14312 | } |
| 14313 | _ACEOF |
| 14314 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14315 | if { (eval echo "$as_me:14315: \"$ac_link\"") >&5 |
| 14316 | (eval $ac_link) 2>&5 |
| 14317 | ac_status=$? |
| 14318 | echo "$as_me:14318: \$? = $ac_status" >&5 |
| 14319 | (exit $ac_status); } && |
| 14320 | { ac_try='test -s conftest$ac_exeext' |
| 14321 | { (eval echo "$as_me:14321: \"$ac_try\"") >&5 |
| 14322 | (eval $ac_try) 2>&5 |
| 14323 | ac_status=$? |
| 14324 | echo "$as_me:14324: \$? = $ac_status" >&5 |
| 14325 | (exit $ac_status); }; }; then |
| 14326 | cf_result=yes |
| 14327 | else |
| 14328 | echo "$as_me: failed program was:" >&5 |
| 14329 | cat conftest.$ac_ext >&5 |
| 14330 | cf_result=no |
| 14331 | fi |
| 14332 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14333 | fi |
| 14334 | eval 'cf_cv_func_'$cf_func'=$cf_result' |
| 14335 | |
| 14336 | fi |
| 14337 | |
| 14338 | # use the computed/retrieved cache-value: |
| 14339 | eval 'cf_result=$cf_cv_func_'$cf_func |
| 14340 | echo "$as_me:14340: result: $cf_result" >&5 |
| 14341 | echo "${ECHO_T}$cf_result" >&6 |
| 14342 | if test $cf_result != no; then |
| 14343 | cat >>confdefs.h <<EOF |
| 14344 | #define HAVE_${cf_tr_func} 1 |
| 14345 | EOF |
| 14346 | |
| 14347 | fi |
| 14348 | done |
| 14349 | |
| 14350 | for cf_func in tputs |
| 14351 | do |
| 14352 | |
| 14353 | cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 14354 | |
| 14355 | echo "$as_me:14355: checking for ${cf_func}" >&5 |
| 14356 | echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6 |
| 14357 | |
| 14358 | echo "${as_me:-configure}:14358: testing ${cf_func} ..." 1>&5 |
| 14359 | |
| 14360 | if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then |
| 14361 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14362 | else |
| 14363 | |
| 14364 | eval cf_result='$ac_cv_func_'$cf_func |
| 14365 | if test ".$cf_result" != ".no"; then |
| 14366 | cat >conftest.$ac_ext <<_ACEOF |
| 14367 | #line 14367 "configure" |
| 14368 | #include "confdefs.h" |
| 14369 | |
| 14370 | #ifdef HAVE_XCURSES |
| 14371 | #include <xcurses.h> |
| 14372 | char * XCursesProgramName = "test"; |
| 14373 | #else |
| 14374 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14375 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 14376 | #include <ncursesw/term.h> |
| 14377 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 14378 | #include <ncurses/term.h> |
| 14379 | #elif defined(HAVE_TERM_H) |
| 14380 | #include <term.h> |
| 14381 | #endif |
| 14382 | #endif |
| 14383 | |
| 14384 | int |
| 14385 | main () |
| 14386 | { |
| 14387 | |
| 14388 | #ifndef ${cf_func} |
| 14389 | long foo = (long)(&${cf_func}); |
| 14390 | fprintf(stderr, "testing linkage of $cf_func:%p\n", foo); |
| 14391 | if (foo + 1234 > 5678) |
| 14392 | ${cf_cv_main_return:-return}(foo); |
| 14393 | #endif |
| 14394 | |
| 14395 | ; |
| 14396 | return 0; |
| 14397 | } |
| 14398 | _ACEOF |
| 14399 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14400 | if { (eval echo "$as_me:14400: \"$ac_link\"") >&5 |
| 14401 | (eval $ac_link) 2>&5 |
| 14402 | ac_status=$? |
| 14403 | echo "$as_me:14403: \$? = $ac_status" >&5 |
| 14404 | (exit $ac_status); } && |
| 14405 | { ac_try='test -s conftest$ac_exeext' |
| 14406 | { (eval echo "$as_me:14406: \"$ac_try\"") >&5 |
| 14407 | (eval $ac_try) 2>&5 |
| 14408 | ac_status=$? |
| 14409 | echo "$as_me:14409: \$? = $ac_status" >&5 |
| 14410 | (exit $ac_status); }; }; then |
| 14411 | cf_result=yes |
| 14412 | else |
| 14413 | echo "$as_me: failed program was:" >&5 |
| 14414 | cat conftest.$ac_ext >&5 |
| 14415 | cf_result=no |
| 14416 | fi |
| 14417 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14418 | fi |
| 14419 | eval 'cf_cv_func_'$cf_func'=$cf_result' |
| 14420 | |
| 14421 | fi |
| 14422 | |
| 14423 | # use the computed/retrieved cache-value: |
| 14424 | eval 'cf_result=$cf_cv_func_'$cf_func |
| 14425 | echo "$as_me:14425: result: $cf_result" >&5 |
| 14426 | echo "${ECHO_T}$cf_result" >&6 |
| 14427 | if test $cf_result != no; then |
| 14428 | cat >>confdefs.h <<EOF |
| 14429 | #define HAVE_${cf_tr_func} 1 |
| 14430 | EOF |
| 14431 | |
| 14432 | fi |
| 14433 | done |
| 14434 | |
| 14435 | if test x$cf_cv_func_tputs = xyes |
| 14436 | then |
| 14437 | cf_done=no |
| 14438 | for cf_arg in int char |
| 14439 | do |
| 14440 | for cf_ret in int void |
| 14441 | do |
| 14442 | if test $cf_ret = void |
| 14443 | then |
| 14444 | cf_return="/* nothing */" |
| 14445 | else |
| 14446 | cf_return="return value" |
| 14447 | fi |
| 14448 | cat >conftest.$ac_ext <<_ACEOF |
| 14449 | #line 14449 "configure" |
| 14450 | #include "confdefs.h" |
| 14451 | |
| 14452 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14453 | #include <$cf_cv_term_header> |
| 14454 | |
| 14455 | static $cf_ret outc($cf_arg value) { $cf_return; } |
| 14456 | |
| 14457 | int |
| 14458 | main () |
| 14459 | { |
| 14460 | |
| 14461 | tputs("hello", 0, outc); |
| 14462 | ${cf_cv_main_return:-return}(0); |
| 14463 | |
| 14464 | ; |
| 14465 | return 0; |
| 14466 | } |
| 14467 | _ACEOF |
| 14468 | rm -f conftest.$ac_objext |
| 14469 | if { (eval echo "$as_me:14469: \"$ac_compile\"") >&5 |
| 14470 | (eval $ac_compile) 2>&5 |
| 14471 | ac_status=$? |
| 14472 | echo "$as_me:14472: \$? = $ac_status" >&5 |
| 14473 | (exit $ac_status); } && |
| 14474 | { ac_try='test -s conftest.$ac_objext' |
| 14475 | { (eval echo "$as_me:14475: \"$ac_try\"") >&5 |
| 14476 | (eval $ac_try) 2>&5 |
| 14477 | ac_status=$? |
| 14478 | echo "$as_me:14478: \$? = $ac_status" >&5 |
| 14479 | (exit $ac_status); }; }; then |
| 14480 | |
| 14481 | test -n "$verbose" && echo " prototype $cf_ret func($cf_arg value)" 1>&6 |
| 14482 | |
| 14483 | echo "${as_me:-configure}:14483: testing prototype $cf_ret func($cf_arg value) ..." 1>&5 |
| 14484 | |
| 14485 | cat >>confdefs.h <<EOF |
| 14486 | #define TPUTS_ARG $cf_arg |
| 14487 | #define TPUTS_PROTO(func,value) $cf_ret func(TPUTS_ARG value) |
| 14488 | #define TPUTS_RETURN(value) $cf_return |
| 14489 | EOF |
| 14490 | cf_done=yes |
| 14491 | break |
| 14492 | |
| 14493 | else |
| 14494 | echo "$as_me: failed program was:" >&5 |
| 14495 | cat conftest.$ac_ext >&5 |
| 14496 | fi |
| 14497 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14498 | done |
| 14499 | test $cf_done = yes && break |
| 14500 | done |
| 14501 | fi |
| 14502 | |
| 14503 | echo "$as_me:14503: checking for ncurses extended functions" >&5 |
| 14504 | echo $ECHO_N "checking for ncurses extended functions... $ECHO_C" >&6 |
| 14505 | if test "${cf_cv_ncurses_ext_funcs+set}" = set; then |
| 14506 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14507 | else |
| 14508 | |
| 14509 | cat >conftest.$ac_ext <<_ACEOF |
| 14510 | #line 14510 "configure" |
| 14511 | #include "confdefs.h" |
| 14512 | |
| 14513 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14514 | int |
| 14515 | main () |
| 14516 | { |
| 14517 | |
| 14518 | int x = NCURSES_EXT_FUNCS |
| 14519 | |
| 14520 | ; |
| 14521 | return 0; |
| 14522 | } |
| 14523 | _ACEOF |
| 14524 | rm -f conftest.$ac_objext |
| 14525 | if { (eval echo "$as_me:14525: \"$ac_compile\"") >&5 |
| 14526 | (eval $ac_compile) 2>&5 |
| 14527 | ac_status=$? |
| 14528 | echo "$as_me:14528: \$? = $ac_status" >&5 |
| 14529 | (exit $ac_status); } && |
| 14530 | { ac_try='test -s conftest.$ac_objext' |
| 14531 | { (eval echo "$as_me:14531: \"$ac_try\"") >&5 |
| 14532 | (eval $ac_try) 2>&5 |
| 14533 | ac_status=$? |
| 14534 | echo "$as_me:14534: \$? = $ac_status" >&5 |
| 14535 | (exit $ac_status); }; }; then |
| 14536 | cf_cv_ncurses_ext_funcs=defined |
| 14537 | else |
| 14538 | echo "$as_me: failed program was:" >&5 |
| 14539 | cat conftest.$ac_ext >&5 |
| 14540 | |
| 14541 | cat >conftest.$ac_ext <<_ACEOF |
| 14542 | #line 14542 "configure" |
| 14543 | #include "confdefs.h" |
| 14544 | |
| 14545 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14546 | int |
| 14547 | main () |
| 14548 | { |
| 14549 | |
| 14550 | (void) assume_default_colors (0, 0); |
| 14551 | (void) curses_version (); |
| 14552 | (void) define_key (0, 0); |
| 14553 | (void) is_term_resized (0, 0); |
| 14554 | (void) key_defined (0); |
| 14555 | (void) keybound (0, 0); |
| 14556 | (void) keyok (0, 0); |
| 14557 | (void) resize_term (0, 0); |
| 14558 | (void) resizeterm (0, 0); |
| 14559 | (void) use_default_colors (); |
| 14560 | (void) use_extended_names (0); |
| 14561 | (void) wresize (0, 0, 0); |
| 14562 | ; |
| 14563 | return 0; |
| 14564 | } |
| 14565 | _ACEOF |
| 14566 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14567 | if { (eval echo "$as_me:14567: \"$ac_link\"") >&5 |
| 14568 | (eval $ac_link) 2>&5 |
| 14569 | ac_status=$? |
| 14570 | echo "$as_me:14570: \$? = $ac_status" >&5 |
| 14571 | (exit $ac_status); } && |
| 14572 | { ac_try='test -s conftest$ac_exeext' |
| 14573 | { (eval echo "$as_me:14573: \"$ac_try\"") >&5 |
| 14574 | (eval $ac_try) 2>&5 |
| 14575 | ac_status=$? |
| 14576 | echo "$as_me:14576: \$? = $ac_status" >&5 |
| 14577 | (exit $ac_status); }; }; then |
| 14578 | cf_cv_ncurses_ext_funcs=yes |
| 14579 | else |
| 14580 | echo "$as_me: failed program was:" >&5 |
| 14581 | cat conftest.$ac_ext >&5 |
| 14582 | cf_cv_ncurses_ext_funcs=no |
| 14583 | fi |
| 14584 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14585 | |
| 14586 | fi |
| 14587 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14588 | |
| 14589 | fi |
| 14590 | echo "$as_me:14590: result: $cf_cv_ncurses_ext_funcs" >&5 |
| 14591 | echo "${ECHO_T}$cf_cv_ncurses_ext_funcs" >&6 |
| 14592 | test "$cf_cv_ncurses_ext_funcs" = yes && |
| 14593 | cat >>confdefs.h <<\EOF |
| 14594 | #define NCURSES_EXT_FUNCS 1 |
| 14595 | EOF |
| 14596 | |
| 14597 | if test "$cf_enable_widec" = yes |
| 14598 | then |
| 14599 | # workaround for systems with ncurses before 20111029, due to change of |
| 14600 | # feature test macro from _XPG5 to _XOPEN_SOURCE |
| 14601 | if test -n "$cf_cv_ncurses_version" && test "x$cf_cv_ncurses_version" != xno |
| 14602 | then |
| 14603 | cf_define_xpg5=no |
| 14604 | echo "$as_me:14604: checking if _XPG5 should be defined to enable wide-characters" >&5 |
| 14605 | echo $ECHO_N "checking if _XPG5 should be defined to enable wide-characters... $ECHO_C" >&6 |
| 14606 | |
| 14607 | cat >conftest.$ac_ext <<_ACEOF |
| 14608 | #line 14608 "configure" |
| 14609 | #include "confdefs.h" |
| 14610 | |
| 14611 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14612 | int |
| 14613 | main () |
| 14614 | { |
| 14615 | int x = _XPG5 |
| 14616 | ; |
| 14617 | return 0; |
| 14618 | } |
| 14619 | _ACEOF |
| 14620 | rm -f conftest.$ac_objext |
| 14621 | if { (eval echo "$as_me:14621: \"$ac_compile\"") >&5 |
| 14622 | (eval $ac_compile) 2>&5 |
| 14623 | ac_status=$? |
| 14624 | echo "$as_me:14624: \$? = $ac_status" >&5 |
| 14625 | (exit $ac_status); } && |
| 14626 | { ac_try='test -s conftest.$ac_objext' |
| 14627 | { (eval echo "$as_me:14627: \"$ac_try\"") >&5 |
| 14628 | (eval $ac_try) 2>&5 |
| 14629 | ac_status=$? |
| 14630 | echo "$as_me:14630: \$? = $ac_status" >&5 |
| 14631 | (exit $ac_status); }; }; then |
| 14632 | : |
| 14633 | else |
| 14634 | echo "$as_me: failed program was:" >&5 |
| 14635 | cat conftest.$ac_ext >&5 |
| 14636 | cf_save_cppflags="$CPPFLAGS" |
| 14637 | CPPFLAGS="$CPPFLAGS -D_XPG5" |
| 14638 | cat >conftest.$ac_ext <<_ACEOF |
| 14639 | #line 14639 "configure" |
| 14640 | #include "confdefs.h" |
| 14641 | |
| 14642 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14643 | int |
| 14644 | main () |
| 14645 | { |
| 14646 | int x = _XPG5 |
| 14647 | ; |
| 14648 | return 0; |
| 14649 | } |
| 14650 | _ACEOF |
| 14651 | rm -f conftest.$ac_objext |
| 14652 | if { (eval echo "$as_me:14652: \"$ac_compile\"") >&5 |
| 14653 | (eval $ac_compile) 2>&5 |
| 14654 | ac_status=$? |
| 14655 | echo "$as_me:14655: \$? = $ac_status" >&5 |
| 14656 | (exit $ac_status); } && |
| 14657 | { ac_try='test -s conftest.$ac_objext' |
| 14658 | { (eval echo "$as_me:14658: \"$ac_try\"") >&5 |
| 14659 | (eval $ac_try) 2>&5 |
| 14660 | ac_status=$? |
| 14661 | echo "$as_me:14661: \$? = $ac_status" >&5 |
| 14662 | (exit $ac_status); }; }; then |
| 14663 | cf_define_xpg5=yes |
| 14664 | else |
| 14665 | echo "$as_me: failed program was:" >&5 |
| 14666 | cat conftest.$ac_ext >&5 |
| 14667 | fi |
| 14668 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14669 | CPPFLAGS="$cf_save_cppflags" |
| 14670 | fi |
| 14671 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14672 | echo "$as_me:14672: result: $cf_define_xpg5" >&5 |
| 14673 | echo "${ECHO_T}$cf_define_xpg5" >&6 |
| 14674 | |
| 14675 | if test "$cf_define_xpg5" = yes |
| 14676 | then |
| 14677 | CPPFLAGS="$CPPFLAGS -D_XPG5" |
| 14678 | fi |
| 14679 | fi |
| 14680 | |
| 14681 | echo "$as_me:14681: checking for wide-character functions" >&5 |
| 14682 | echo $ECHO_N "checking for wide-character functions... $ECHO_C" >&6 |
| 14683 | if test "${cf_cv_widechar_funcs+set}" = set; then |
| 14684 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14685 | else |
| 14686 | |
| 14687 | cat >conftest.$ac_ext <<_ACEOF |
| 14688 | #line 14688 "configure" |
| 14689 | #include "confdefs.h" |
| 14690 | |
| 14691 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14692 | int |
| 14693 | main () |
| 14694 | { |
| 14695 | |
| 14696 | static wchar_t src_wchar[2]; |
| 14697 | static cchar_t dst_cchar; |
| 14698 | setcchar(&dst_cchar, src_wchar, A_NORMAL, 0, (void *) 0); |
| 14699 | |
| 14700 | ; |
| 14701 | return 0; |
| 14702 | } |
| 14703 | _ACEOF |
| 14704 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14705 | if { (eval echo "$as_me:14705: \"$ac_link\"") >&5 |
| 14706 | (eval $ac_link) 2>&5 |
| 14707 | ac_status=$? |
| 14708 | echo "$as_me:14708: \$? = $ac_status" >&5 |
| 14709 | (exit $ac_status); } && |
| 14710 | { ac_try='test -s conftest$ac_exeext' |
| 14711 | { (eval echo "$as_me:14711: \"$ac_try\"") >&5 |
| 14712 | (eval $ac_try) 2>&5 |
| 14713 | ac_status=$? |
| 14714 | echo "$as_me:14714: \$? = $ac_status" >&5 |
| 14715 | (exit $ac_status); }; }; then |
| 14716 | cf_cv_widechar_funcs=yes |
| 14717 | else |
| 14718 | echo "$as_me: failed program was:" >&5 |
| 14719 | cat conftest.$ac_ext >&5 |
| 14720 | cf_cv_widechar_funcs=no |
| 14721 | fi |
| 14722 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14723 | |
| 14724 | fi |
| 14725 | echo "$as_me:14725: result: $cf_cv_widechar_funcs" >&5 |
| 14726 | echo "${ECHO_T}$cf_cv_widechar_funcs" >&6 |
| 14727 | if test "$cf_cv_widechar_funcs" != no ; then |
| 14728 | |
| 14729 | cat >>confdefs.h <<\EOF |
| 14730 | #define USE_WIDEC_SUPPORT 1 |
| 14731 | EOF |
| 14732 | |
| 14733 | else |
| 14734 | cat >>confdefs.h <<\EOF |
| 14735 | #define USE_WIDEC_SUPPORT 0 |
| 14736 | EOF |
| 14737 | |
| 14738 | fi |
| 14739 | else |
| 14740 | cat >>confdefs.h <<\EOF |
| 14741 | #define USE_WIDEC_SUPPORT 0 |
| 14742 | EOF |
| 14743 | |
| 14744 | fi |
| 14745 | |
| 14746 | echo "$as_me:14746: checking if $cf_cv_screen library uses pthreads" >&5 |
| 14747 | echo $ECHO_N "checking if $cf_cv_screen library uses pthreads... $ECHO_C" >&6 |
| 14748 | if test "${cf_cv_use_pthreads+set}" = set; then |
| 14749 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14750 | else |
| 14751 | |
| 14752 | cat >conftest.$ac_ext <<_ACEOF |
| 14753 | #line 14753 "configure" |
| 14754 | #include "confdefs.h" |
| 14755 | |
| 14756 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14757 | extern void _nc_init_pthreads(void); |
| 14758 | |
| 14759 | int |
| 14760 | main () |
| 14761 | { |
| 14762 | |
| 14763 | initscr(); |
| 14764 | _nc_init_pthreads(); |
| 14765 | |
| 14766 | ; |
| 14767 | return 0; |
| 14768 | } |
| 14769 | _ACEOF |
| 14770 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14771 | if { (eval echo "$as_me:14771: \"$ac_link\"") >&5 |
| 14772 | (eval $ac_link) 2>&5 |
| 14773 | ac_status=$? |
| 14774 | echo "$as_me:14774: \$? = $ac_status" >&5 |
| 14775 | (exit $ac_status); } && |
| 14776 | { ac_try='test -s conftest$ac_exeext' |
| 14777 | { (eval echo "$as_me:14777: \"$ac_try\"") >&5 |
| 14778 | (eval $ac_try) 2>&5 |
| 14779 | ac_status=$? |
| 14780 | echo "$as_me:14780: \$? = $ac_status" >&5 |
| 14781 | (exit $ac_status); }; }; then |
| 14782 | cf_cv_use_pthreads=yes |
| 14783 | else |
| 14784 | echo "$as_me: failed program was:" >&5 |
| 14785 | cat conftest.$ac_ext >&5 |
| 14786 | cf_cv_use_pthreads=no |
| 14787 | fi |
| 14788 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14789 | |
| 14790 | fi |
| 14791 | echo "$as_me:14791: result: $cf_cv_use_pthreads" >&5 |
| 14792 | echo "${ECHO_T}$cf_cv_use_pthreads" >&6 |
| 14793 | test $cf_cv_use_pthreads = yes && cat >>confdefs.h <<\EOF |
| 14794 | #define USE_PTHREADS 1 |
| 14795 | EOF |
| 14796 | |
| 14797 | echo "$as_me:14797: checking if sys/time.h works with sys/select.h" >&5 |
| 14798 | echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6 |
| 14799 | if test "${cf_cv_sys_time_select+set}" = set; then |
| 14800 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14801 | else |
| 14802 | |
| 14803 | cat >conftest.$ac_ext <<_ACEOF |
| 14804 | #line 14804 "configure" |
| 14805 | #include "confdefs.h" |
| 14806 | |
| 14807 | #include <sys/types.h> |
| 14808 | #ifdef HAVE_SYS_TIME_H |
| 14809 | #include <sys/time.h> |
| 14810 | #endif |
| 14811 | #ifdef HAVE_SYS_SELECT_H |
| 14812 | #include <sys/select.h> |
| 14813 | #endif |
| 14814 | |
| 14815 | int |
| 14816 | main () |
| 14817 | { |
| 14818 | |
| 14819 | ; |
| 14820 | return 0; |
| 14821 | } |
| 14822 | _ACEOF |
| 14823 | rm -f conftest.$ac_objext |
| 14824 | if { (eval echo "$as_me:14824: \"$ac_compile\"") >&5 |
| 14825 | (eval $ac_compile) 2>&5 |
| 14826 | ac_status=$? |
| 14827 | echo "$as_me:14827: \$? = $ac_status" >&5 |
| 14828 | (exit $ac_status); } && |
| 14829 | { ac_try='test -s conftest.$ac_objext' |
| 14830 | { (eval echo "$as_me:14830: \"$ac_try\"") >&5 |
| 14831 | (eval $ac_try) 2>&5 |
| 14832 | ac_status=$? |
| 14833 | echo "$as_me:14833: \$? = $ac_status" >&5 |
| 14834 | (exit $ac_status); }; }; then |
| 14835 | cf_cv_sys_time_select=yes |
| 14836 | else |
| 14837 | echo "$as_me: failed program was:" >&5 |
| 14838 | cat conftest.$ac_ext >&5 |
| 14839 | cf_cv_sys_time_select=no |
| 14840 | fi |
| 14841 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14842 | |
| 14843 | fi |
| 14844 | |
| 14845 | echo "$as_me:14845: result: $cf_cv_sys_time_select" >&5 |
| 14846 | echo "${ECHO_T}$cf_cv_sys_time_select" >&6 |
| 14847 | test "$cf_cv_sys_time_select" = yes && |
| 14848 | cat >>confdefs.h <<\EOF |
| 14849 | #define HAVE_SYS_TIME_SELECT 1 |
| 14850 | EOF |
| 14851 | |
| 14852 | echo "$as_me:14852: checking for function curses_version" >&5 |
| 14853 | echo $ECHO_N "checking for function curses_version... $ECHO_C" >&6 |
| 14854 | if test "${cf_cv_func_curses_version+set}" = set; then |
| 14855 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14856 | else |
| 14857 | |
| 14858 | if test "$cross_compiling" = yes; then |
| 14859 | cf_cv_func_curses_version=unknown |
| 14860 | else |
| 14861 | cat >conftest.$ac_ext <<_ACEOF |
| 14862 | #line 14862 "configure" |
| 14863 | #include "confdefs.h" |
| 14864 | |
| 14865 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14866 | int main() |
| 14867 | { |
| 14868 | char temp[1024]; |
| 14869 | sprintf(temp, "%s\n", curses_version()); |
| 14870 | ${cf_cv_main_return:-return}(0); |
| 14871 | } |
| 14872 | |
| 14873 | _ACEOF |
| 14874 | rm -f conftest$ac_exeext |
| 14875 | if { (eval echo "$as_me:14875: \"$ac_link\"") >&5 |
| 14876 | (eval $ac_link) 2>&5 |
| 14877 | ac_status=$? |
| 14878 | echo "$as_me:14878: \$? = $ac_status" >&5 |
| 14879 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 14880 | { (eval echo "$as_me:14880: \"$ac_try\"") >&5 |
| 14881 | (eval $ac_try) 2>&5 |
| 14882 | ac_status=$? |
| 14883 | echo "$as_me:14883: \$? = $ac_status" >&5 |
| 14884 | (exit $ac_status); }; }; then |
| 14885 | cf_cv_func_curses_version=yes |
| 14886 | |
| 14887 | else |
| 14888 | echo "$as_me: program exited with status $ac_status" >&5 |
| 14889 | echo "$as_me: failed program was:" >&5 |
| 14890 | cat conftest.$ac_ext >&5 |
| 14891 | cf_cv_func_curses_version=no |
| 14892 | |
| 14893 | fi |
| 14894 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 14895 | fi |
| 14896 | rm -f core |
| 14897 | fi |
| 14898 | echo "$as_me:14898: result: $cf_cv_func_curses_version" >&5 |
| 14899 | echo "${ECHO_T}$cf_cv_func_curses_version" >&6 |
| 14900 | test "$cf_cv_func_curses_version" = yes && |
| 14901 | cat >>confdefs.h <<\EOF |
| 14902 | #define HAVE_CURSES_VERSION 1 |
| 14903 | EOF |
| 14904 | |
| 14905 | echo "$as_me:14905: checking for alternate character set array" >&5 |
| 14906 | echo $ECHO_N "checking for alternate character set array... $ECHO_C" >&6 |
| 14907 | if test "${cf_cv_curses_acs_map+set}" = set; then |
| 14908 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14909 | else |
| 14910 | |
| 14911 | cf_cv_curses_acs_map=unknown |
| 14912 | for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map |
| 14913 | do |
| 14914 | cat >conftest.$ac_ext <<_ACEOF |
| 14915 | #line 14915 "configure" |
| 14916 | #include "confdefs.h" |
| 14917 | |
| 14918 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14919 | |
| 14920 | int |
| 14921 | main () |
| 14922 | { |
| 14923 | |
| 14924 | $name['k'] = ACS_PLUS |
| 14925 | |
| 14926 | ; |
| 14927 | return 0; |
| 14928 | } |
| 14929 | _ACEOF |
| 14930 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14931 | if { (eval echo "$as_me:14931: \"$ac_link\"") >&5 |
| 14932 | (eval $ac_link) 2>&5 |
| 14933 | ac_status=$? |
| 14934 | echo "$as_me:14934: \$? = $ac_status" >&5 |
| 14935 | (exit $ac_status); } && |
| 14936 | { ac_try='test -s conftest$ac_exeext' |
| 14937 | { (eval echo "$as_me:14937: \"$ac_try\"") >&5 |
| 14938 | (eval $ac_try) 2>&5 |
| 14939 | ac_status=$? |
| 14940 | echo "$as_me:14940: \$? = $ac_status" >&5 |
| 14941 | (exit $ac_status); }; }; then |
| 14942 | cf_cv_curses_acs_map=$name; break |
| 14943 | else |
| 14944 | echo "$as_me: failed program was:" >&5 |
| 14945 | cat conftest.$ac_ext >&5 |
| 14946 | fi |
| 14947 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14948 | done |
| 14949 | |
| 14950 | fi |
| 14951 | echo "$as_me:14951: result: $cf_cv_curses_acs_map" >&5 |
| 14952 | echo "${ECHO_T}$cf_cv_curses_acs_map" >&6 |
| 14953 | |
| 14954 | test "$cf_cv_curses_acs_map" != unknown && |
| 14955 | cat >>confdefs.h <<EOF |
| 14956 | #define CURSES_ACS_ARRAY $cf_cv_curses_acs_map |
| 14957 | EOF |
| 14958 | |
| 14959 | if test "$cf_enable_widec" = yes; then |
| 14960 | |
| 14961 | echo "$as_me:14961: checking for wide alternate character set array" >&5 |
| 14962 | echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6 |
| 14963 | if test "${cf_cv_curses_wacs_map+set}" = set; then |
| 14964 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14965 | else |
| 14966 | |
| 14967 | cf_cv_curses_wacs_map=unknown |
| 14968 | for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char |
| 14969 | do |
| 14970 | cat >conftest.$ac_ext <<_ACEOF |
| 14971 | #line 14971 "configure" |
| 14972 | #include "confdefs.h" |
| 14973 | |
| 14974 | #ifndef _XOPEN_SOURCE_EXTENDED |
| 14975 | #define _XOPEN_SOURCE_EXTENDED |
| 14976 | #endif |
| 14977 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 14978 | int |
| 14979 | main () |
| 14980 | { |
| 14981 | void *foo = &($name['k']) |
| 14982 | ; |
| 14983 | return 0; |
| 14984 | } |
| 14985 | _ACEOF |
| 14986 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14987 | if { (eval echo "$as_me:14987: \"$ac_link\"") >&5 |
| 14988 | (eval $ac_link) 2>&5 |
| 14989 | ac_status=$? |
| 14990 | echo "$as_me:14990: \$? = $ac_status" >&5 |
| 14991 | (exit $ac_status); } && |
| 14992 | { ac_try='test -s conftest$ac_exeext' |
| 14993 | { (eval echo "$as_me:14993: \"$ac_try\"") >&5 |
| 14994 | (eval $ac_try) 2>&5 |
| 14995 | ac_status=$? |
| 14996 | echo "$as_me:14996: \$? = $ac_status" >&5 |
| 14997 | (exit $ac_status); }; }; then |
| 14998 | cf_cv_curses_wacs_map=$name |
| 14999 | break |
| 15000 | else |
| 15001 | echo "$as_me: failed program was:" >&5 |
| 15002 | cat conftest.$ac_ext >&5 |
| 15003 | fi |
| 15004 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15005 | done |
| 15006 | fi |
| 15007 | echo "$as_me:15007: result: $cf_cv_curses_wacs_map" >&5 |
| 15008 | echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6 |
| 15009 | |
| 15010 | test "$cf_cv_curses_wacs_map" != unknown && |
| 15011 | cat >>confdefs.h <<EOF |
| 15012 | #define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map |
| 15013 | EOF |
| 15014 | |
| 15015 | echo "$as_me:15015: checking for wide alternate character constants" >&5 |
| 15016 | echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6 |
| 15017 | if test "${cf_cv_curses_wacs_symbols+set}" = set; then |
| 15018 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15019 | else |
| 15020 | |
| 15021 | cf_cv_curses_wacs_symbols=no |
| 15022 | if test "$cf_cv_curses_wacs_map" != unknown |
| 15023 | then |
| 15024 | cat >conftest.$ac_ext <<_ACEOF |
| 15025 | #line 15025 "configure" |
| 15026 | #include "confdefs.h" |
| 15027 | |
| 15028 | #ifndef _XOPEN_SOURCE_EXTENDED |
| 15029 | #define _XOPEN_SOURCE_EXTENDED |
| 15030 | #endif |
| 15031 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15032 | int |
| 15033 | main () |
| 15034 | { |
| 15035 | cchar_t *foo = WACS_PLUS; |
| 15036 | $cf_cv_curses_wacs_map['k'] = *WACS_PLUS |
| 15037 | ; |
| 15038 | return 0; |
| 15039 | } |
| 15040 | _ACEOF |
| 15041 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15042 | if { (eval echo "$as_me:15042: \"$ac_link\"") >&5 |
| 15043 | (eval $ac_link) 2>&5 |
| 15044 | ac_status=$? |
| 15045 | echo "$as_me:15045: \$? = $ac_status" >&5 |
| 15046 | (exit $ac_status); } && |
| 15047 | { ac_try='test -s conftest$ac_exeext' |
| 15048 | { (eval echo "$as_me:15048: \"$ac_try\"") >&5 |
| 15049 | (eval $ac_try) 2>&5 |
| 15050 | ac_status=$? |
| 15051 | echo "$as_me:15051: \$? = $ac_status" >&5 |
| 15052 | (exit $ac_status); }; }; then |
| 15053 | cf_cv_curses_wacs_symbols=yes |
| 15054 | else |
| 15055 | echo "$as_me: failed program was:" >&5 |
| 15056 | cat conftest.$ac_ext >&5 |
| 15057 | fi |
| 15058 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15059 | else |
| 15060 | cat >conftest.$ac_ext <<_ACEOF |
| 15061 | #line 15061 "configure" |
| 15062 | #include "confdefs.h" |
| 15063 | |
| 15064 | #ifndef _XOPEN_SOURCE_EXTENDED |
| 15065 | #define _XOPEN_SOURCE_EXTENDED |
| 15066 | #endif |
| 15067 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15068 | int |
| 15069 | main () |
| 15070 | { |
| 15071 | cchar_t *foo = WACS_PLUS |
| 15072 | ; |
| 15073 | return 0; |
| 15074 | } |
| 15075 | _ACEOF |
| 15076 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15077 | if { (eval echo "$as_me:15077: \"$ac_link\"") >&5 |
| 15078 | (eval $ac_link) 2>&5 |
| 15079 | ac_status=$? |
| 15080 | echo "$as_me:15080: \$? = $ac_status" >&5 |
| 15081 | (exit $ac_status); } && |
| 15082 | { ac_try='test -s conftest$ac_exeext' |
| 15083 | { (eval echo "$as_me:15083: \"$ac_try\"") >&5 |
| 15084 | (eval $ac_try) 2>&5 |
| 15085 | ac_status=$? |
| 15086 | echo "$as_me:15086: \$? = $ac_status" >&5 |
| 15087 | (exit $ac_status); }; }; then |
| 15088 | cf_cv_curses_wacs_symbols=yes |
| 15089 | else |
| 15090 | echo "$as_me: failed program was:" >&5 |
| 15091 | cat conftest.$ac_ext >&5 |
| 15092 | fi |
| 15093 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15094 | fi |
| 15095 | |
| 15096 | fi |
| 15097 | echo "$as_me:15097: result: $cf_cv_curses_wacs_symbols" >&5 |
| 15098 | echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6 |
| 15099 | |
| 15100 | test "$cf_cv_curses_wacs_symbols" != no && |
| 15101 | cat >>confdefs.h <<\EOF |
| 15102 | #define CURSES_WACS_SYMBOLS 1 |
| 15103 | EOF |
| 15104 | |
| 15105 | fi |
| 15106 | |
| 15107 | echo "$as_me:15107: checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}" >&5 |
| 15108 | echo $ECHO_N "checking for type attr_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6 |
| 15109 | cat >conftest.$ac_ext <<_ACEOF |
| 15110 | #line 15110 "configure" |
| 15111 | #include "confdefs.h" |
| 15112 | |
| 15113 | #ifndef _XOPEN_SOURCE_EXTENDED |
| 15114 | #define _XOPEN_SOURCE_EXTENDED |
| 15115 | #endif |
| 15116 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15117 | int |
| 15118 | main () |
| 15119 | { |
| 15120 | |
| 15121 | attr_t foo |
| 15122 | |
| 15123 | ; |
| 15124 | return 0; |
| 15125 | } |
| 15126 | _ACEOF |
| 15127 | rm -f conftest.$ac_objext |
| 15128 | if { (eval echo "$as_me:15128: \"$ac_compile\"") >&5 |
| 15129 | (eval $ac_compile) 2>&5 |
| 15130 | ac_status=$? |
| 15131 | echo "$as_me:15131: \$? = $ac_status" >&5 |
| 15132 | (exit $ac_status); } && |
| 15133 | { ac_try='test -s conftest.$ac_objext' |
| 15134 | { (eval echo "$as_me:15134: \"$ac_try\"") >&5 |
| 15135 | (eval $ac_try) 2>&5 |
| 15136 | ac_status=$? |
| 15137 | echo "$as_me:15137: \$? = $ac_status" >&5 |
| 15138 | (exit $ac_status); }; }; then |
| 15139 | cf_result=yes |
| 15140 | else |
| 15141 | echo "$as_me: failed program was:" >&5 |
| 15142 | cat conftest.$ac_ext >&5 |
| 15143 | cf_result=no |
| 15144 | fi |
| 15145 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15146 | echo "$as_me:15146: result: $cf_result" >&5 |
| 15147 | echo "${ECHO_T}$cf_result" >&6 |
| 15148 | if test $cf_result = yes ; then |
| 15149 | |
| 15150 | cf_result=`echo "have_type_attr_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 15151 | |
| 15152 | cat >>confdefs.h <<EOF |
| 15153 | #define $cf_result 1 |
| 15154 | EOF |
| 15155 | |
| 15156 | else |
| 15157 | |
| 15158 | cat >>confdefs.h <<EOF |
| 15159 | #define attr_t long |
| 15160 | EOF |
| 15161 | |
| 15162 | fi |
| 15163 | |
| 15164 | if test "$cf_enable_widec" = yes; then |
| 15165 | |
| 15166 | # This is needed on Tru64 5.0 to declare mbstate_t |
| 15167 | echo "$as_me:15167: checking if we must include wchar.h to declare mbstate_t" >&5 |
| 15168 | echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6 |
| 15169 | if test "${cf_cv_mbstate_t+set}" = set; then |
| 15170 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15171 | else |
| 15172 | |
| 15173 | cat >conftest.$ac_ext <<_ACEOF |
| 15174 | #line 15174 "configure" |
| 15175 | #include "confdefs.h" |
| 15176 | |
| 15177 | #include <stdlib.h> |
| 15178 | #include <stdarg.h> |
| 15179 | #include <stdio.h> |
| 15180 | #ifdef HAVE_LIBUTF8_H |
| 15181 | #include <libutf8.h> |
| 15182 | #endif |
| 15183 | int |
| 15184 | main () |
| 15185 | { |
| 15186 | mbstate_t state |
| 15187 | ; |
| 15188 | return 0; |
| 15189 | } |
| 15190 | _ACEOF |
| 15191 | rm -f conftest.$ac_objext |
| 15192 | if { (eval echo "$as_me:15192: \"$ac_compile\"") >&5 |
| 15193 | (eval $ac_compile) 2>&5 |
| 15194 | ac_status=$? |
| 15195 | echo "$as_me:15195: \$? = $ac_status" >&5 |
| 15196 | (exit $ac_status); } && |
| 15197 | { ac_try='test -s conftest.$ac_objext' |
| 15198 | { (eval echo "$as_me:15198: \"$ac_try\"") >&5 |
| 15199 | (eval $ac_try) 2>&5 |
| 15200 | ac_status=$? |
| 15201 | echo "$as_me:15201: \$? = $ac_status" >&5 |
| 15202 | (exit $ac_status); }; }; then |
| 15203 | cf_cv_mbstate_t=no |
| 15204 | else |
| 15205 | echo "$as_me: failed program was:" >&5 |
| 15206 | cat conftest.$ac_ext >&5 |
| 15207 | cat >conftest.$ac_ext <<_ACEOF |
| 15208 | #line 15208 "configure" |
| 15209 | #include "confdefs.h" |
| 15210 | |
| 15211 | #include <stdlib.h> |
| 15212 | #include <stdarg.h> |
| 15213 | #include <stdio.h> |
| 15214 | #include <wchar.h> |
| 15215 | #ifdef HAVE_LIBUTF8_H |
| 15216 | #include <libutf8.h> |
| 15217 | #endif |
| 15218 | int |
| 15219 | main () |
| 15220 | { |
| 15221 | mbstate_t value |
| 15222 | ; |
| 15223 | return 0; |
| 15224 | } |
| 15225 | _ACEOF |
| 15226 | rm -f conftest.$ac_objext |
| 15227 | if { (eval echo "$as_me:15227: \"$ac_compile\"") >&5 |
| 15228 | (eval $ac_compile) 2>&5 |
| 15229 | ac_status=$? |
| 15230 | echo "$as_me:15230: \$? = $ac_status" >&5 |
| 15231 | (exit $ac_status); } && |
| 15232 | { ac_try='test -s conftest.$ac_objext' |
| 15233 | { (eval echo "$as_me:15233: \"$ac_try\"") >&5 |
| 15234 | (eval $ac_try) 2>&5 |
| 15235 | ac_status=$? |
| 15236 | echo "$as_me:15236: \$? = $ac_status" >&5 |
| 15237 | (exit $ac_status); }; }; then |
| 15238 | cf_cv_mbstate_t=yes |
| 15239 | else |
| 15240 | echo "$as_me: failed program was:" >&5 |
| 15241 | cat conftest.$ac_ext >&5 |
| 15242 | cf_cv_mbstate_t=unknown |
| 15243 | fi |
| 15244 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15245 | fi |
| 15246 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15247 | fi |
| 15248 | echo "$as_me:15248: result: $cf_cv_mbstate_t" >&5 |
| 15249 | echo "${ECHO_T}$cf_cv_mbstate_t" >&6 |
| 15250 | |
| 15251 | if test "$cf_cv_mbstate_t" = yes ; then |
| 15252 | |
| 15253 | cat >>confdefs.h <<\EOF |
| 15254 | #define NEED_WCHAR_H 1 |
| 15255 | EOF |
| 15256 | |
| 15257 | NEED_WCHAR_H=1 |
| 15258 | fi |
| 15259 | |
| 15260 | # if we do not find mbstate_t in either place, use substitution to provide a fallback. |
| 15261 | if test "$cf_cv_mbstate_t" = unknown ; then |
| 15262 | NCURSES_MBSTATE_T=1 |
| 15263 | fi |
| 15264 | |
| 15265 | # if we find mbstate_t in either place, use substitution to provide a fallback. |
| 15266 | if test "$cf_cv_mbstate_t" != unknown ; then |
| 15267 | NCURSES_OK_MBSTATE_T=1 |
| 15268 | fi |
| 15269 | |
| 15270 | # This is needed on Tru64 5.0 to declare wchar_t |
| 15271 | echo "$as_me:15271: checking if we must include wchar.h to declare wchar_t" >&5 |
| 15272 | echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6 |
| 15273 | if test "${cf_cv_wchar_t+set}" = set; then |
| 15274 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15275 | else |
| 15276 | |
| 15277 | cat >conftest.$ac_ext <<_ACEOF |
| 15278 | #line 15278 "configure" |
| 15279 | #include "confdefs.h" |
| 15280 | |
| 15281 | #include <stdlib.h> |
| 15282 | #include <stdarg.h> |
| 15283 | #include <stdio.h> |
| 15284 | #ifdef HAVE_LIBUTF8_H |
| 15285 | #include <libutf8.h> |
| 15286 | #endif |
| 15287 | int |
| 15288 | main () |
| 15289 | { |
| 15290 | wchar_t state |
| 15291 | ; |
| 15292 | return 0; |
| 15293 | } |
| 15294 | _ACEOF |
| 15295 | rm -f conftest.$ac_objext |
| 15296 | if { (eval echo "$as_me:15296: \"$ac_compile\"") >&5 |
| 15297 | (eval $ac_compile) 2>&5 |
| 15298 | ac_status=$? |
| 15299 | echo "$as_me:15299: \$? = $ac_status" >&5 |
| 15300 | (exit $ac_status); } && |
| 15301 | { ac_try='test -s conftest.$ac_objext' |
| 15302 | { (eval echo "$as_me:15302: \"$ac_try\"") >&5 |
| 15303 | (eval $ac_try) 2>&5 |
| 15304 | ac_status=$? |
| 15305 | echo "$as_me:15305: \$? = $ac_status" >&5 |
| 15306 | (exit $ac_status); }; }; then |
| 15307 | cf_cv_wchar_t=no |
| 15308 | else |
| 15309 | echo "$as_me: failed program was:" >&5 |
| 15310 | cat conftest.$ac_ext >&5 |
| 15311 | cat >conftest.$ac_ext <<_ACEOF |
| 15312 | #line 15312 "configure" |
| 15313 | #include "confdefs.h" |
| 15314 | |
| 15315 | #include <stdlib.h> |
| 15316 | #include <stdarg.h> |
| 15317 | #include <stdio.h> |
| 15318 | #include <wchar.h> |
| 15319 | #ifdef HAVE_LIBUTF8_H |
| 15320 | #include <libutf8.h> |
| 15321 | #endif |
| 15322 | int |
| 15323 | main () |
| 15324 | { |
| 15325 | wchar_t value |
| 15326 | ; |
| 15327 | return 0; |
| 15328 | } |
| 15329 | _ACEOF |
| 15330 | rm -f conftest.$ac_objext |
| 15331 | if { (eval echo "$as_me:15331: \"$ac_compile\"") >&5 |
| 15332 | (eval $ac_compile) 2>&5 |
| 15333 | ac_status=$? |
| 15334 | echo "$as_me:15334: \$? = $ac_status" >&5 |
| 15335 | (exit $ac_status); } && |
| 15336 | { ac_try='test -s conftest.$ac_objext' |
| 15337 | { (eval echo "$as_me:15337: \"$ac_try\"") >&5 |
| 15338 | (eval $ac_try) 2>&5 |
| 15339 | ac_status=$? |
| 15340 | echo "$as_me:15340: \$? = $ac_status" >&5 |
| 15341 | (exit $ac_status); }; }; then |
| 15342 | cf_cv_wchar_t=yes |
| 15343 | else |
| 15344 | echo "$as_me: failed program was:" >&5 |
| 15345 | cat conftest.$ac_ext >&5 |
| 15346 | cf_cv_wchar_t=unknown |
| 15347 | fi |
| 15348 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15349 | fi |
| 15350 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15351 | fi |
| 15352 | echo "$as_me:15352: result: $cf_cv_wchar_t" >&5 |
| 15353 | echo "${ECHO_T}$cf_cv_wchar_t" >&6 |
| 15354 | |
| 15355 | if test "$cf_cv_wchar_t" = yes ; then |
| 15356 | |
| 15357 | cat >>confdefs.h <<\EOF |
| 15358 | #define NEED_WCHAR_H 1 |
| 15359 | EOF |
| 15360 | |
| 15361 | NEED_WCHAR_H=1 |
| 15362 | fi |
| 15363 | |
| 15364 | # if we do not find wchar_t in either place, use substitution to provide a fallback. |
| 15365 | if test "$cf_cv_wchar_t" = unknown ; then |
| 15366 | NCURSES_WCHAR_T=1 |
| 15367 | fi |
| 15368 | |
| 15369 | # if we find wchar_t in either place, use substitution to provide a fallback. |
| 15370 | if test "$cf_cv_wchar_t" != unknown ; then |
| 15371 | NCURSES_OK_WCHAR_T=1 |
| 15372 | fi |
| 15373 | |
| 15374 | # This is needed on Tru64 5.0 to declare wint_t |
| 15375 | echo "$as_me:15375: checking if we must include wchar.h to declare wint_t" >&5 |
| 15376 | echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6 |
| 15377 | if test "${cf_cv_wint_t+set}" = set; then |
| 15378 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15379 | else |
| 15380 | |
| 15381 | cat >conftest.$ac_ext <<_ACEOF |
| 15382 | #line 15382 "configure" |
| 15383 | #include "confdefs.h" |
| 15384 | |
| 15385 | #include <stdlib.h> |
| 15386 | #include <stdarg.h> |
| 15387 | #include <stdio.h> |
| 15388 | #ifdef HAVE_LIBUTF8_H |
| 15389 | #include <libutf8.h> |
| 15390 | #endif |
| 15391 | int |
| 15392 | main () |
| 15393 | { |
| 15394 | wint_t state |
| 15395 | ; |
| 15396 | return 0; |
| 15397 | } |
| 15398 | _ACEOF |
| 15399 | rm -f conftest.$ac_objext |
| 15400 | if { (eval echo "$as_me:15400: \"$ac_compile\"") >&5 |
| 15401 | (eval $ac_compile) 2>&5 |
| 15402 | ac_status=$? |
| 15403 | echo "$as_me:15403: \$? = $ac_status" >&5 |
| 15404 | (exit $ac_status); } && |
| 15405 | { ac_try='test -s conftest.$ac_objext' |
| 15406 | { (eval echo "$as_me:15406: \"$ac_try\"") >&5 |
| 15407 | (eval $ac_try) 2>&5 |
| 15408 | ac_status=$? |
| 15409 | echo "$as_me:15409: \$? = $ac_status" >&5 |
| 15410 | (exit $ac_status); }; }; then |
| 15411 | cf_cv_wint_t=no |
| 15412 | else |
| 15413 | echo "$as_me: failed program was:" >&5 |
| 15414 | cat conftest.$ac_ext >&5 |
| 15415 | cat >conftest.$ac_ext <<_ACEOF |
| 15416 | #line 15416 "configure" |
| 15417 | #include "confdefs.h" |
| 15418 | |
| 15419 | #include <stdlib.h> |
| 15420 | #include <stdarg.h> |
| 15421 | #include <stdio.h> |
| 15422 | #include <wchar.h> |
| 15423 | #ifdef HAVE_LIBUTF8_H |
| 15424 | #include <libutf8.h> |
| 15425 | #endif |
| 15426 | int |
| 15427 | main () |
| 15428 | { |
| 15429 | wint_t value |
| 15430 | ; |
| 15431 | return 0; |
| 15432 | } |
| 15433 | _ACEOF |
| 15434 | rm -f conftest.$ac_objext |
| 15435 | if { (eval echo "$as_me:15435: \"$ac_compile\"") >&5 |
| 15436 | (eval $ac_compile) 2>&5 |
| 15437 | ac_status=$? |
| 15438 | echo "$as_me:15438: \$? = $ac_status" >&5 |
| 15439 | (exit $ac_status); } && |
| 15440 | { ac_try='test -s conftest.$ac_objext' |
| 15441 | { (eval echo "$as_me:15441: \"$ac_try\"") >&5 |
| 15442 | (eval $ac_try) 2>&5 |
| 15443 | ac_status=$? |
| 15444 | echo "$as_me:15444: \$? = $ac_status" >&5 |
| 15445 | (exit $ac_status); }; }; then |
| 15446 | cf_cv_wint_t=yes |
| 15447 | else |
| 15448 | echo "$as_me: failed program was:" >&5 |
| 15449 | cat conftest.$ac_ext >&5 |
| 15450 | cf_cv_wint_t=unknown |
| 15451 | fi |
| 15452 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15453 | fi |
| 15454 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15455 | fi |
| 15456 | echo "$as_me:15456: result: $cf_cv_wint_t" >&5 |
| 15457 | echo "${ECHO_T}$cf_cv_wint_t" >&6 |
| 15458 | |
| 15459 | if test "$cf_cv_wint_t" = yes ; then |
| 15460 | |
| 15461 | cat >>confdefs.h <<\EOF |
| 15462 | #define NEED_WCHAR_H 1 |
| 15463 | EOF |
| 15464 | |
| 15465 | NEED_WCHAR_H=1 |
| 15466 | fi |
| 15467 | |
| 15468 | # if we do not find wint_t in either place, use substitution to provide a fallback. |
| 15469 | if test "$cf_cv_wint_t" = unknown ; then |
| 15470 | NCURSES_WINT_T=1 |
| 15471 | fi |
| 15472 | |
| 15473 | # if we find wint_t in either place, use substitution to provide a fallback. |
| 15474 | if test "$cf_cv_wint_t" != unknown ; then |
| 15475 | NCURSES_OK_WINT_T=1 |
| 15476 | fi |
| 15477 | |
| 15478 | if test "$NCURSES_OK_MBSTATE_T" = 0 ; then |
| 15479 | |
| 15480 | echo "$as_me:15480: checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}" >&5 |
| 15481 | echo $ECHO_N "checking for type mbstate_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6 |
| 15482 | cat >conftest.$ac_ext <<_ACEOF |
| 15483 | #line 15483 "configure" |
| 15484 | #include "confdefs.h" |
| 15485 | |
| 15486 | #ifndef _XOPEN_SOURCE_EXTENDED |
| 15487 | #define _XOPEN_SOURCE_EXTENDED |
| 15488 | #endif |
| 15489 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15490 | int |
| 15491 | main () |
| 15492 | { |
| 15493 | |
| 15494 | mbstate_t foo |
| 15495 | |
| 15496 | ; |
| 15497 | return 0; |
| 15498 | } |
| 15499 | _ACEOF |
| 15500 | rm -f conftest.$ac_objext |
| 15501 | if { (eval echo "$as_me:15501: \"$ac_compile\"") >&5 |
| 15502 | (eval $ac_compile) 2>&5 |
| 15503 | ac_status=$? |
| 15504 | echo "$as_me:15504: \$? = $ac_status" >&5 |
| 15505 | (exit $ac_status); } && |
| 15506 | { ac_try='test -s conftest.$ac_objext' |
| 15507 | { (eval echo "$as_me:15507: \"$ac_try\"") >&5 |
| 15508 | (eval $ac_try) 2>&5 |
| 15509 | ac_status=$? |
| 15510 | echo "$as_me:15510: \$? = $ac_status" >&5 |
| 15511 | (exit $ac_status); }; }; then |
| 15512 | cf_result=yes |
| 15513 | else |
| 15514 | echo "$as_me: failed program was:" >&5 |
| 15515 | cat conftest.$ac_ext >&5 |
| 15516 | cf_result=no |
| 15517 | fi |
| 15518 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15519 | echo "$as_me:15519: result: $cf_result" >&5 |
| 15520 | echo "${ECHO_T}$cf_result" >&6 |
| 15521 | if test $cf_result = yes ; then |
| 15522 | |
| 15523 | cf_result=`echo "have_type_mbstate_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 15524 | |
| 15525 | cat >>confdefs.h <<EOF |
| 15526 | #define $cf_result 1 |
| 15527 | EOF |
| 15528 | |
| 15529 | else |
| 15530 | |
| 15531 | cat >>confdefs.h <<EOF |
| 15532 | #define mbstate_t long |
| 15533 | EOF |
| 15534 | |
| 15535 | fi |
| 15536 | |
| 15537 | fi |
| 15538 | |
| 15539 | if test "$NCURSES_OK_WCHAR_T" = 0 ; then |
| 15540 | |
| 15541 | echo "$as_me:15541: checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}" >&5 |
| 15542 | echo $ECHO_N "checking for type wchar_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6 |
| 15543 | cat >conftest.$ac_ext <<_ACEOF |
| 15544 | #line 15544 "configure" |
| 15545 | #include "confdefs.h" |
| 15546 | |
| 15547 | #ifndef _XOPEN_SOURCE_EXTENDED |
| 15548 | #define _XOPEN_SOURCE_EXTENDED |
| 15549 | #endif |
| 15550 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15551 | int |
| 15552 | main () |
| 15553 | { |
| 15554 | |
| 15555 | wchar_t foo |
| 15556 | |
| 15557 | ; |
| 15558 | return 0; |
| 15559 | } |
| 15560 | _ACEOF |
| 15561 | rm -f conftest.$ac_objext |
| 15562 | if { (eval echo "$as_me:15562: \"$ac_compile\"") >&5 |
| 15563 | (eval $ac_compile) 2>&5 |
| 15564 | ac_status=$? |
| 15565 | echo "$as_me:15565: \$? = $ac_status" >&5 |
| 15566 | (exit $ac_status); } && |
| 15567 | { ac_try='test -s conftest.$ac_objext' |
| 15568 | { (eval echo "$as_me:15568: \"$ac_try\"") >&5 |
| 15569 | (eval $ac_try) 2>&5 |
| 15570 | ac_status=$? |
| 15571 | echo "$as_me:15571: \$? = $ac_status" >&5 |
| 15572 | (exit $ac_status); }; }; then |
| 15573 | cf_result=yes |
| 15574 | else |
| 15575 | echo "$as_me: failed program was:" >&5 |
| 15576 | cat conftest.$ac_ext >&5 |
| 15577 | cf_result=no |
| 15578 | fi |
| 15579 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15580 | echo "$as_me:15580: result: $cf_result" >&5 |
| 15581 | echo "${ECHO_T}$cf_result" >&6 |
| 15582 | if test $cf_result = yes ; then |
| 15583 | |
| 15584 | cf_result=`echo "have_type_wchar_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 15585 | |
| 15586 | cat >>confdefs.h <<EOF |
| 15587 | #define $cf_result 1 |
| 15588 | EOF |
| 15589 | |
| 15590 | else |
| 15591 | |
| 15592 | cat >>confdefs.h <<EOF |
| 15593 | #define wchar_t long |
| 15594 | EOF |
| 15595 | |
| 15596 | fi |
| 15597 | |
| 15598 | fi |
| 15599 | |
| 15600 | if test "$NCURSES_OK_WINT_T" = 0 ; then |
| 15601 | |
| 15602 | echo "$as_me:15602: checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}" >&5 |
| 15603 | echo $ECHO_N "checking for type wint_t in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6 |
| 15604 | cat >conftest.$ac_ext <<_ACEOF |
| 15605 | #line 15605 "configure" |
| 15606 | #include "confdefs.h" |
| 15607 | |
| 15608 | #ifndef _XOPEN_SOURCE_EXTENDED |
| 15609 | #define _XOPEN_SOURCE_EXTENDED |
| 15610 | #endif |
| 15611 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15612 | int |
| 15613 | main () |
| 15614 | { |
| 15615 | |
| 15616 | wint_t foo |
| 15617 | |
| 15618 | ; |
| 15619 | return 0; |
| 15620 | } |
| 15621 | _ACEOF |
| 15622 | rm -f conftest.$ac_objext |
| 15623 | if { (eval echo "$as_me:15623: \"$ac_compile\"") >&5 |
| 15624 | (eval $ac_compile) 2>&5 |
| 15625 | ac_status=$? |
| 15626 | echo "$as_me:15626: \$? = $ac_status" >&5 |
| 15627 | (exit $ac_status); } && |
| 15628 | { ac_try='test -s conftest.$ac_objext' |
| 15629 | { (eval echo "$as_me:15629: \"$ac_try\"") >&5 |
| 15630 | (eval $ac_try) 2>&5 |
| 15631 | ac_status=$? |
| 15632 | echo "$as_me:15632: \$? = $ac_status" >&5 |
| 15633 | (exit $ac_status); }; }; then |
| 15634 | cf_result=yes |
| 15635 | else |
| 15636 | echo "$as_me: failed program was:" >&5 |
| 15637 | cat conftest.$ac_ext >&5 |
| 15638 | cf_result=no |
| 15639 | fi |
| 15640 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15641 | echo "$as_me:15641: result: $cf_result" >&5 |
| 15642 | echo "${ECHO_T}$cf_result" >&6 |
| 15643 | if test $cf_result = yes ; then |
| 15644 | |
| 15645 | cf_result=`echo "have_type_wint_t" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 15646 | |
| 15647 | cat >>confdefs.h <<EOF |
| 15648 | #define $cf_result 1 |
| 15649 | EOF |
| 15650 | |
| 15651 | else |
| 15652 | |
| 15653 | cat >>confdefs.h <<EOF |
| 15654 | #define wint_t long |
| 15655 | EOF |
| 15656 | |
| 15657 | fi |
| 15658 | |
| 15659 | fi |
| 15660 | fi |
| 15661 | |
| 15662 | echo "$as_me:15662: checking for data ospeed declaration in ${cf_cv_ncurses_header:-curses.h}" >&5 |
| 15663 | echo $ECHO_N "checking for data ospeed declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6 |
| 15664 | |
| 15665 | cat >conftest.$ac_ext <<_ACEOF |
| 15666 | #line 15666 "configure" |
| 15667 | #include "confdefs.h" |
| 15668 | |
| 15669 | #ifdef HAVE_XCURSES |
| 15670 | #include <xcurses.h> |
| 15671 | char * XCursesProgramName = "test"; |
| 15672 | #else |
| 15673 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15674 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 15675 | #include <ncursesw/term.h> |
| 15676 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 15677 | #include <ncurses/term.h> |
| 15678 | #elif defined(HAVE_TERM_H) |
| 15679 | #include <term.h> |
| 15680 | #endif |
| 15681 | #endif |
| 15682 | |
| 15683 | int |
| 15684 | main () |
| 15685 | { |
| 15686 | |
| 15687 | void *foo = &(ospeed) |
| 15688 | |
| 15689 | ; |
| 15690 | return 0; |
| 15691 | } |
| 15692 | _ACEOF |
| 15693 | rm -f conftest.$ac_objext |
| 15694 | if { (eval echo "$as_me:15694: \"$ac_compile\"") >&5 |
| 15695 | (eval $ac_compile) 2>&5 |
| 15696 | ac_status=$? |
| 15697 | echo "$as_me:15697: \$? = $ac_status" >&5 |
| 15698 | (exit $ac_status); } && |
| 15699 | { ac_try='test -s conftest.$ac_objext' |
| 15700 | { (eval echo "$as_me:15700: \"$ac_try\"") >&5 |
| 15701 | (eval $ac_try) 2>&5 |
| 15702 | ac_status=$? |
| 15703 | echo "$as_me:15703: \$? = $ac_status" >&5 |
| 15704 | (exit $ac_status); }; }; then |
| 15705 | cf_result=yes |
| 15706 | else |
| 15707 | echo "$as_me: failed program was:" >&5 |
| 15708 | cat conftest.$ac_ext >&5 |
| 15709 | cf_result=no |
| 15710 | fi |
| 15711 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15712 | echo "$as_me:15712: result: $cf_result" >&5 |
| 15713 | echo "${ECHO_T}$cf_result" >&6 |
| 15714 | |
| 15715 | if test $cf_result = yes ; then |
| 15716 | |
| 15717 | cf_result=`echo "have_curses_data_ospeed" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 15718 | |
| 15719 | cat >>confdefs.h <<EOF |
| 15720 | #define $cf_result 1 |
| 15721 | EOF |
| 15722 | |
| 15723 | else |
| 15724 | echo "$as_me:15724: checking for data ospeed in library" >&5 |
| 15725 | echo $ECHO_N "checking for data ospeed in library... $ECHO_C" >&6 |
| 15726 | # BSD linkers insist on making weak linkage, but resolve at runtime. |
| 15727 | if test "$cross_compiling" = yes; then |
| 15728 | |
| 15729 | # cross-compiling |
| 15730 | cat >conftest.$ac_ext <<_ACEOF |
| 15731 | #line 15731 "configure" |
| 15732 | #include "confdefs.h" |
| 15733 | |
| 15734 | #ifdef HAVE_XCURSES |
| 15735 | #include <xcurses.h> |
| 15736 | char * XCursesProgramName = "test"; |
| 15737 | #else |
| 15738 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15739 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 15740 | #include <ncursesw/term.h> |
| 15741 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 15742 | #include <ncurses/term.h> |
| 15743 | #elif defined(HAVE_TERM_H) |
| 15744 | #include <term.h> |
| 15745 | #endif |
| 15746 | #endif |
| 15747 | |
| 15748 | extern char ospeed; |
| 15749 | int |
| 15750 | main () |
| 15751 | { |
| 15752 | |
| 15753 | do { |
| 15754 | void *foo = &(ospeed); |
| 15755 | fprintf(stderr, "testing linkage of ospeed:%p\n", foo); |
| 15756 | ${cf_cv_main_return:-return}(foo == 0); |
| 15757 | } while (0) |
| 15758 | |
| 15759 | ; |
| 15760 | return 0; |
| 15761 | } |
| 15762 | _ACEOF |
| 15763 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15764 | if { (eval echo "$as_me:15764: \"$ac_link\"") >&5 |
| 15765 | (eval $ac_link) 2>&5 |
| 15766 | ac_status=$? |
| 15767 | echo "$as_me:15767: \$? = $ac_status" >&5 |
| 15768 | (exit $ac_status); } && |
| 15769 | { ac_try='test -s conftest$ac_exeext' |
| 15770 | { (eval echo "$as_me:15770: \"$ac_try\"") >&5 |
| 15771 | (eval $ac_try) 2>&5 |
| 15772 | ac_status=$? |
| 15773 | echo "$as_me:15773: \$? = $ac_status" >&5 |
| 15774 | (exit $ac_status); }; }; then |
| 15775 | cf_result=yes |
| 15776 | else |
| 15777 | echo "$as_me: failed program was:" >&5 |
| 15778 | cat conftest.$ac_ext >&5 |
| 15779 | cf_result=no |
| 15780 | fi |
| 15781 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15782 | |
| 15783 | else |
| 15784 | cat >conftest.$ac_ext <<_ACEOF |
| 15785 | #line 15785 "configure" |
| 15786 | #include "confdefs.h" |
| 15787 | |
| 15788 | #ifdef HAVE_XCURSES |
| 15789 | #include <xcurses.h> |
| 15790 | char * XCursesProgramName = "test"; |
| 15791 | #else |
| 15792 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15793 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 15794 | #include <ncursesw/term.h> |
| 15795 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 15796 | #include <ncurses/term.h> |
| 15797 | #elif defined(HAVE_TERM_H) |
| 15798 | #include <term.h> |
| 15799 | #endif |
| 15800 | #endif |
| 15801 | |
| 15802 | extern char ospeed; |
| 15803 | int main(void) |
| 15804 | { |
| 15805 | void *foo = &(ospeed); |
| 15806 | fprintf(stderr, "testing linkage of ospeed:%p\n", foo); |
| 15807 | ${cf_cv_main_return:-return}(foo == 0); |
| 15808 | } |
| 15809 | _ACEOF |
| 15810 | rm -f conftest$ac_exeext |
| 15811 | if { (eval echo "$as_me:15811: \"$ac_link\"") >&5 |
| 15812 | (eval $ac_link) 2>&5 |
| 15813 | ac_status=$? |
| 15814 | echo "$as_me:15814: \$? = $ac_status" >&5 |
| 15815 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 15816 | { (eval echo "$as_me:15816: \"$ac_try\"") >&5 |
| 15817 | (eval $ac_try) 2>&5 |
| 15818 | ac_status=$? |
| 15819 | echo "$as_me:15819: \$? = $ac_status" >&5 |
| 15820 | (exit $ac_status); }; }; then |
| 15821 | cf_result=yes |
| 15822 | else |
| 15823 | echo "$as_me: program exited with status $ac_status" >&5 |
| 15824 | echo "$as_me: failed program was:" >&5 |
| 15825 | cat conftest.$ac_ext >&5 |
| 15826 | cf_result=no |
| 15827 | fi |
| 15828 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 15829 | fi |
| 15830 | echo "$as_me:15830: result: $cf_result" >&5 |
| 15831 | echo "${ECHO_T}$cf_result" >&6 |
| 15832 | if test $cf_result = yes ; then |
| 15833 | |
| 15834 | cf_result=`echo "decl_curses_data_ospeed" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 15835 | |
| 15836 | cat >>confdefs.h <<EOF |
| 15837 | #define $cf_result 1 |
| 15838 | EOF |
| 15839 | |
| 15840 | fi |
| 15841 | fi |
| 15842 | |
| 15843 | echo "$as_me:15843: checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5 |
| 15844 | echo $ECHO_N "checking for data boolnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6 |
| 15845 | |
| 15846 | cat >conftest.$ac_ext <<_ACEOF |
| 15847 | #line 15847 "configure" |
| 15848 | #include "confdefs.h" |
| 15849 | |
| 15850 | #ifdef HAVE_XCURSES |
| 15851 | #include <xcurses.h> |
| 15852 | char * XCursesProgramName = "test"; |
| 15853 | #else |
| 15854 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15855 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 15856 | #include <ncursesw/term.h> |
| 15857 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 15858 | #include <ncurses/term.h> |
| 15859 | #elif defined(HAVE_TERM_H) |
| 15860 | #include <term.h> |
| 15861 | #endif |
| 15862 | #endif |
| 15863 | |
| 15864 | int |
| 15865 | main () |
| 15866 | { |
| 15867 | |
| 15868 | void *foo = &(boolnames) |
| 15869 | |
| 15870 | ; |
| 15871 | return 0; |
| 15872 | } |
| 15873 | _ACEOF |
| 15874 | rm -f conftest.$ac_objext |
| 15875 | if { (eval echo "$as_me:15875: \"$ac_compile\"") >&5 |
| 15876 | (eval $ac_compile) 2>&5 |
| 15877 | ac_status=$? |
| 15878 | echo "$as_me:15878: \$? = $ac_status" >&5 |
| 15879 | (exit $ac_status); } && |
| 15880 | { ac_try='test -s conftest.$ac_objext' |
| 15881 | { (eval echo "$as_me:15881: \"$ac_try\"") >&5 |
| 15882 | (eval $ac_try) 2>&5 |
| 15883 | ac_status=$? |
| 15884 | echo "$as_me:15884: \$? = $ac_status" >&5 |
| 15885 | (exit $ac_status); }; }; then |
| 15886 | cf_result=yes |
| 15887 | else |
| 15888 | echo "$as_me: failed program was:" >&5 |
| 15889 | cat conftest.$ac_ext >&5 |
| 15890 | cf_result=no |
| 15891 | fi |
| 15892 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15893 | echo "$as_me:15893: result: $cf_result" >&5 |
| 15894 | echo "${ECHO_T}$cf_result" >&6 |
| 15895 | |
| 15896 | if test $cf_result = yes ; then |
| 15897 | |
| 15898 | cf_result=`echo "have_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 15899 | |
| 15900 | cat >>confdefs.h <<EOF |
| 15901 | #define $cf_result 1 |
| 15902 | EOF |
| 15903 | |
| 15904 | else |
| 15905 | echo "$as_me:15905: checking for data boolnames in library" >&5 |
| 15906 | echo $ECHO_N "checking for data boolnames in library... $ECHO_C" >&6 |
| 15907 | # BSD linkers insist on making weak linkage, but resolve at runtime. |
| 15908 | if test "$cross_compiling" = yes; then |
| 15909 | |
| 15910 | # cross-compiling |
| 15911 | cat >conftest.$ac_ext <<_ACEOF |
| 15912 | #line 15912 "configure" |
| 15913 | #include "confdefs.h" |
| 15914 | |
| 15915 | #ifdef HAVE_XCURSES |
| 15916 | #include <xcurses.h> |
| 15917 | char * XCursesProgramName = "test"; |
| 15918 | #else |
| 15919 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15920 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 15921 | #include <ncursesw/term.h> |
| 15922 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 15923 | #include <ncurses/term.h> |
| 15924 | #elif defined(HAVE_TERM_H) |
| 15925 | #include <term.h> |
| 15926 | #endif |
| 15927 | #endif |
| 15928 | |
| 15929 | extern char boolnames; |
| 15930 | int |
| 15931 | main () |
| 15932 | { |
| 15933 | |
| 15934 | do { |
| 15935 | void *foo = &(boolnames); |
| 15936 | fprintf(stderr, "testing linkage of boolnames:%p\n", foo); |
| 15937 | ${cf_cv_main_return:-return}(foo == 0); |
| 15938 | } while (0) |
| 15939 | |
| 15940 | ; |
| 15941 | return 0; |
| 15942 | } |
| 15943 | _ACEOF |
| 15944 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15945 | if { (eval echo "$as_me:15945: \"$ac_link\"") >&5 |
| 15946 | (eval $ac_link) 2>&5 |
| 15947 | ac_status=$? |
| 15948 | echo "$as_me:15948: \$? = $ac_status" >&5 |
| 15949 | (exit $ac_status); } && |
| 15950 | { ac_try='test -s conftest$ac_exeext' |
| 15951 | { (eval echo "$as_me:15951: \"$ac_try\"") >&5 |
| 15952 | (eval $ac_try) 2>&5 |
| 15953 | ac_status=$? |
| 15954 | echo "$as_me:15954: \$? = $ac_status" >&5 |
| 15955 | (exit $ac_status); }; }; then |
| 15956 | cf_result=yes |
| 15957 | else |
| 15958 | echo "$as_me: failed program was:" >&5 |
| 15959 | cat conftest.$ac_ext >&5 |
| 15960 | cf_result=no |
| 15961 | fi |
| 15962 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15963 | |
| 15964 | else |
| 15965 | cat >conftest.$ac_ext <<_ACEOF |
| 15966 | #line 15966 "configure" |
| 15967 | #include "confdefs.h" |
| 15968 | |
| 15969 | #ifdef HAVE_XCURSES |
| 15970 | #include <xcurses.h> |
| 15971 | char * XCursesProgramName = "test"; |
| 15972 | #else |
| 15973 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 15974 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 15975 | #include <ncursesw/term.h> |
| 15976 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 15977 | #include <ncurses/term.h> |
| 15978 | #elif defined(HAVE_TERM_H) |
| 15979 | #include <term.h> |
| 15980 | #endif |
| 15981 | #endif |
| 15982 | |
| 15983 | extern char boolnames; |
| 15984 | int main(void) |
| 15985 | { |
| 15986 | void *foo = &(boolnames); |
| 15987 | fprintf(stderr, "testing linkage of boolnames:%p\n", foo); |
| 15988 | ${cf_cv_main_return:-return}(foo == 0); |
| 15989 | } |
| 15990 | _ACEOF |
| 15991 | rm -f conftest$ac_exeext |
| 15992 | if { (eval echo "$as_me:15992: \"$ac_link\"") >&5 |
| 15993 | (eval $ac_link) 2>&5 |
| 15994 | ac_status=$? |
| 15995 | echo "$as_me:15995: \$? = $ac_status" >&5 |
| 15996 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 15997 | { (eval echo "$as_me:15997: \"$ac_try\"") >&5 |
| 15998 | (eval $ac_try) 2>&5 |
| 15999 | ac_status=$? |
| 16000 | echo "$as_me:16000: \$? = $ac_status" >&5 |
| 16001 | (exit $ac_status); }; }; then |
| 16002 | cf_result=yes |
| 16003 | else |
| 16004 | echo "$as_me: program exited with status $ac_status" >&5 |
| 16005 | echo "$as_me: failed program was:" >&5 |
| 16006 | cat conftest.$ac_ext >&5 |
| 16007 | cf_result=no |
| 16008 | fi |
| 16009 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 16010 | fi |
| 16011 | echo "$as_me:16011: result: $cf_result" >&5 |
| 16012 | echo "${ECHO_T}$cf_result" >&6 |
| 16013 | if test $cf_result = yes ; then |
| 16014 | |
| 16015 | cf_result=`echo "decl_curses_data_boolnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 16016 | |
| 16017 | cat >>confdefs.h <<EOF |
| 16018 | #define $cf_result 1 |
| 16019 | EOF |
| 16020 | |
| 16021 | fi |
| 16022 | fi |
| 16023 | |
| 16024 | echo "$as_me:16024: checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}" >&5 |
| 16025 | echo $ECHO_N "checking for data boolfnames declaration in ${cf_cv_ncurses_header:-curses.h}... $ECHO_C" >&6 |
| 16026 | |
| 16027 | cat >conftest.$ac_ext <<_ACEOF |
| 16028 | #line 16028 "configure" |
| 16029 | #include "confdefs.h" |
| 16030 | |
| 16031 | #ifdef HAVE_XCURSES |
| 16032 | #include <xcurses.h> |
| 16033 | char * XCursesProgramName = "test"; |
| 16034 | #else |
| 16035 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 16036 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 16037 | #include <ncursesw/term.h> |
| 16038 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 16039 | #include <ncurses/term.h> |
| 16040 | #elif defined(HAVE_TERM_H) |
| 16041 | #include <term.h> |
| 16042 | #endif |
| 16043 | #endif |
| 16044 | |
| 16045 | int |
| 16046 | main () |
| 16047 | { |
| 16048 | |
| 16049 | void *foo = &(boolfnames) |
| 16050 | |
| 16051 | ; |
| 16052 | return 0; |
| 16053 | } |
| 16054 | _ACEOF |
| 16055 | rm -f conftest.$ac_objext |
| 16056 | if { (eval echo "$as_me:16056: \"$ac_compile\"") >&5 |
| 16057 | (eval $ac_compile) 2>&5 |
| 16058 | ac_status=$? |
| 16059 | echo "$as_me:16059: \$? = $ac_status" >&5 |
| 16060 | (exit $ac_status); } && |
| 16061 | { ac_try='test -s conftest.$ac_objext' |
| 16062 | { (eval echo "$as_me:16062: \"$ac_try\"") >&5 |
| 16063 | (eval $ac_try) 2>&5 |
| 16064 | ac_status=$? |
| 16065 | echo "$as_me:16065: \$? = $ac_status" >&5 |
| 16066 | (exit $ac_status); }; }; then |
| 16067 | cf_result=yes |
| 16068 | else |
| 16069 | echo "$as_me: failed program was:" >&5 |
| 16070 | cat conftest.$ac_ext >&5 |
| 16071 | cf_result=no |
| 16072 | fi |
| 16073 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 16074 | echo "$as_me:16074: result: $cf_result" >&5 |
| 16075 | echo "${ECHO_T}$cf_result" >&6 |
| 16076 | |
| 16077 | if test $cf_result = yes ; then |
| 16078 | |
| 16079 | cf_result=`echo "have_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 16080 | |
| 16081 | cat >>confdefs.h <<EOF |
| 16082 | #define $cf_result 1 |
| 16083 | EOF |
| 16084 | |
| 16085 | else |
| 16086 | echo "$as_me:16086: checking for data boolfnames in library" >&5 |
| 16087 | echo $ECHO_N "checking for data boolfnames in library... $ECHO_C" >&6 |
| 16088 | # BSD linkers insist on making weak linkage, but resolve at runtime. |
| 16089 | if test "$cross_compiling" = yes; then |
| 16090 | |
| 16091 | # cross-compiling |
| 16092 | cat >conftest.$ac_ext <<_ACEOF |
| 16093 | #line 16093 "configure" |
| 16094 | #include "confdefs.h" |
| 16095 | |
| 16096 | #ifdef HAVE_XCURSES |
| 16097 | #include <xcurses.h> |
| 16098 | char * XCursesProgramName = "test"; |
| 16099 | #else |
| 16100 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 16101 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 16102 | #include <ncursesw/term.h> |
| 16103 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 16104 | #include <ncurses/term.h> |
| 16105 | #elif defined(HAVE_TERM_H) |
| 16106 | #include <term.h> |
| 16107 | #endif |
| 16108 | #endif |
| 16109 | |
| 16110 | extern char boolfnames; |
| 16111 | int |
| 16112 | main () |
| 16113 | { |
| 16114 | |
| 16115 | do { |
| 16116 | void *foo = &(boolfnames); |
| 16117 | fprintf(stderr, "testing linkage of boolfnames:%p\n", foo); |
| 16118 | ${cf_cv_main_return:-return}(foo == 0); |
| 16119 | } while (0) |
| 16120 | |
| 16121 | ; |
| 16122 | return 0; |
| 16123 | } |
| 16124 | _ACEOF |
| 16125 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 16126 | if { (eval echo "$as_me:16126: \"$ac_link\"") >&5 |
| 16127 | (eval $ac_link) 2>&5 |
| 16128 | ac_status=$? |
| 16129 | echo "$as_me:16129: \$? = $ac_status" >&5 |
| 16130 | (exit $ac_status); } && |
| 16131 | { ac_try='test -s conftest$ac_exeext' |
| 16132 | { (eval echo "$as_me:16132: \"$ac_try\"") >&5 |
| 16133 | (eval $ac_try) 2>&5 |
| 16134 | ac_status=$? |
| 16135 | echo "$as_me:16135: \$? = $ac_status" >&5 |
| 16136 | (exit $ac_status); }; }; then |
| 16137 | cf_result=yes |
| 16138 | else |
| 16139 | echo "$as_me: failed program was:" >&5 |
| 16140 | cat conftest.$ac_ext >&5 |
| 16141 | cf_result=no |
| 16142 | fi |
| 16143 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 16144 | |
| 16145 | else |
| 16146 | cat >conftest.$ac_ext <<_ACEOF |
| 16147 | #line 16147 "configure" |
| 16148 | #include "confdefs.h" |
| 16149 | |
| 16150 | #ifdef HAVE_XCURSES |
| 16151 | #include <xcurses.h> |
| 16152 | char * XCursesProgramName = "test"; |
| 16153 | #else |
| 16154 | #include <${cf_cv_ncurses_header:-curses.h}> |
| 16155 | #if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H) |
| 16156 | #include <ncursesw/term.h> |
| 16157 | #elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H) |
| 16158 | #include <ncurses/term.h> |
| 16159 | #elif defined(HAVE_TERM_H) |
| 16160 | #include <term.h> |
| 16161 | #endif |
| 16162 | #endif |
| 16163 | |
| 16164 | extern char boolfnames; |
| 16165 | int main(void) |
| 16166 | { |
| 16167 | void *foo = &(boolfnames); |
| 16168 | fprintf(stderr, "testing linkage of boolfnames:%p\n", foo); |
| 16169 | ${cf_cv_main_return:-return}(foo == 0); |
| 16170 | } |
| 16171 | _ACEOF |
| 16172 | rm -f conftest$ac_exeext |
| 16173 | if { (eval echo "$as_me:16173: \"$ac_link\"") >&5 |
| 16174 | (eval $ac_link) 2>&5 |
| 16175 | ac_status=$? |
| 16176 | echo "$as_me:16176: \$? = $ac_status" >&5 |
| 16177 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 16178 | { (eval echo "$as_me:16178: \"$ac_try\"") >&5 |
| 16179 | (eval $ac_try) 2>&5 |
| 16180 | ac_status=$? |
| 16181 | echo "$as_me:16181: \$? = $ac_status" >&5 |
| 16182 | (exit $ac_status); }; }; then |
| 16183 | cf_result=yes |
| 16184 | else |
| 16185 | echo "$as_me: program exited with status $ac_status" >&5 |
| 16186 | echo "$as_me: failed program was:" >&5 |
| 16187 | cat conftest.$ac_ext >&5 |
| 16188 | cf_result=no |
| 16189 | fi |
| 16190 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 16191 | fi |
| 16192 | echo "$as_me:16192: result: $cf_result" >&5 |
| 16193 | echo "${ECHO_T}$cf_result" >&6 |
| 16194 | if test $cf_result = yes ; then |
| 16195 | |
| 16196 | cf_result=`echo "decl_curses_data_boolfnames" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 16197 | |
| 16198 | cat >>confdefs.h <<EOF |
| 16199 | #define $cf_result 1 |
| 16200 | EOF |
| 16201 | |
| 16202 | fi |
| 16203 | fi |
| 16204 | |
| 16205 | if ( test "$GCC" = yes || test "$GXX" = yes ) |
| 16206 | then |
| 16207 | echo "$as_me:16207: checking if you want to turn on gcc warnings" >&5 |
| 16208 | echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6 |
| 16209 | |
| 16210 | # Check whether --enable-warnings or --disable-warnings was given. |
| 16211 | if test "${enable_warnings+set}" = set; then |
| 16212 | enableval="$enable_warnings" |
| 16213 | test "$enableval" != yes && enableval=no |
| 16214 | if test "$enableval" != "no" ; then |
| 16215 | with_warnings=yes |
| 16216 | else |
| 16217 | with_warnings=no |
| 16218 | fi |
| 16219 | else |
| 16220 | enableval=no |
| 16221 | with_warnings=no |
| 16222 | |
| 16223 | fi; |
| 16224 | echo "$as_me:16224: result: $with_warnings" >&5 |
| 16225 | echo "${ECHO_T}$with_warnings" >&6 |
| 16226 | if test "$with_warnings" = "yes" |
| 16227 | then |
| 16228 | |
| 16229 | if test "$GCC" = yes |
| 16230 | then |
| 16231 | cat > conftest.i <<EOF |
| 16232 | #ifndef GCC_PRINTF |
| 16233 | #define GCC_PRINTF 0 |
| 16234 | #endif |
| 16235 | #ifndef GCC_SCANF |
| 16236 | #define GCC_SCANF 0 |
| 16237 | #endif |
| 16238 | #ifndef GCC_NORETURN |
| 16239 | #define GCC_NORETURN /* nothing */ |
| 16240 | #endif |
| 16241 | #ifndef GCC_UNUSED |
| 16242 | #define GCC_UNUSED /* nothing */ |
| 16243 | #endif |
| 16244 | EOF |
| 16245 | if test "$GCC" = yes |
| 16246 | then |
| 16247 | { echo "$as_me:16247: checking for $CC __attribute__ directives..." >&5 |
| 16248 | echo "$as_me: checking for $CC __attribute__ directives..." >&6;} |
| 16249 | cat > conftest.$ac_ext <<EOF |
| 16250 | #line 16250 "${as_me:-configure}" |
| 16251 | #include "confdefs.h" |
| 16252 | #include "conftest.h" |
| 16253 | #include "conftest.i" |
| 16254 | #if GCC_PRINTF |
| 16255 | #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var))) |
| 16256 | #else |
| 16257 | #define GCC_PRINTFLIKE(fmt,var) /*nothing*/ |
| 16258 | #endif |
| 16259 | #if GCC_SCANF |
| 16260 | #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var))) |
| 16261 | #else |
| 16262 | #define GCC_SCANFLIKE(fmt,var) /*nothing*/ |
| 16263 | #endif |
| 16264 | extern void wow(char *,...) GCC_SCANFLIKE(1,2); |
| 16265 | extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN; |
| 16266 | extern void foo(void) GCC_NORETURN; |
| 16267 | int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; } |
| 16268 | EOF |
| 16269 | cf_printf_attribute=no |
| 16270 | cf_scanf_attribute=no |
| 16271 | for cf_attribute in scanf printf unused noreturn |
| 16272 | do |
| 16273 | |
| 16274 | cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 16275 | |
| 16276 | cf_directive="__attribute__(($cf_attribute))" |
| 16277 | echo "checking for $CC $cf_directive" 1>&5 |
| 16278 | |
| 16279 | case $cf_attribute in |
| 16280 | (printf) |
| 16281 | cf_printf_attribute=yes |
| 16282 | cat >conftest.h <<EOF |
| 16283 | #define GCC_$cf_ATTRIBUTE 1 |
| 16284 | EOF |
| 16285 | ;; |
| 16286 | (scanf) |
| 16287 | cf_scanf_attribute=yes |
| 16288 | cat >conftest.h <<EOF |
| 16289 | #define GCC_$cf_ATTRIBUTE 1 |
| 16290 | EOF |
| 16291 | ;; |
| 16292 | (*) |
| 16293 | cat >conftest.h <<EOF |
| 16294 | #define GCC_$cf_ATTRIBUTE $cf_directive |
| 16295 | EOF |
| 16296 | ;; |
| 16297 | esac |
| 16298 | |
| 16299 | if { (eval echo "$as_me:16299: \"$ac_compile\"") >&5 |
| 16300 | (eval $ac_compile) 2>&5 |
| 16301 | ac_status=$? |
| 16302 | echo "$as_me:16302: \$? = $ac_status" >&5 |
| 16303 | (exit $ac_status); }; then |
| 16304 | test -n "$verbose" && echo "$as_me:16304: result: ... $cf_attribute" >&5 |
| 16305 | echo "${ECHO_T}... $cf_attribute" >&6 |
| 16306 | cat conftest.h >>confdefs.h |
| 16307 | case $cf_attribute in |
| 16308 | (noreturn) |
| 16309 | |
| 16310 | cat >>confdefs.h <<EOF |
| 16311 | #define GCC_NORETURN $cf_directive |
| 16312 | EOF |
| 16313 | |
| 16314 | ;; |
| 16315 | (printf) |
| 16316 | cf_value='/* nothing */' |
| 16317 | if test "$cf_printf_attribute" != no ; then |
| 16318 | cf_value='__attribute__((format(printf,fmt,var)))' |
| 16319 | |
| 16320 | cat >>confdefs.h <<\EOF |
| 16321 | #define GCC_PRINTF 1 |
| 16322 | EOF |
| 16323 | |
| 16324 | fi |
| 16325 | |
| 16326 | cat >>confdefs.h <<EOF |
| 16327 | #define GCC_PRINTFLIKE(fmt,var) $cf_value |
| 16328 | EOF |
| 16329 | |
| 16330 | ;; |
| 16331 | (scanf) |
| 16332 | cf_value='/* nothing */' |
| 16333 | if test "$cf_scanf_attribute" != no ; then |
| 16334 | cf_value='__attribute__((format(scanf,fmt,var)))' |
| 16335 | |
| 16336 | cat >>confdefs.h <<\EOF |
| 16337 | #define GCC_SCANF 1 |
| 16338 | EOF |
| 16339 | |
| 16340 | fi |
| 16341 | |
| 16342 | cat >>confdefs.h <<EOF |
| 16343 | #define GCC_SCANFLIKE(fmt,var) $cf_value |
| 16344 | EOF |
| 16345 | |
| 16346 | ;; |
| 16347 | (unused) |
| 16348 | |
| 16349 | cat >>confdefs.h <<EOF |
| 16350 | #define GCC_UNUSED $cf_directive |
| 16351 | EOF |
| 16352 | |
| 16353 | ;; |
| 16354 | esac |
| 16355 | fi |
| 16356 | done |
| 16357 | else |
| 16358 | fgrep define conftest.i >>confdefs.h |
| 16359 | fi |
| 16360 | rm -rf conftest* |
| 16361 | fi |
| 16362 | |
| 16363 | INTEL_COMPILER=no |
| 16364 | |
| 16365 | if test "$GCC" = yes ; then |
| 16366 | case $host_os in |
| 16367 | (linux*|gnu*) |
| 16368 | echo "$as_me:16368: checking if this is really Intel C compiler" >&5 |
| 16369 | echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6 |
| 16370 | cf_save_CFLAGS="$CFLAGS" |
| 16371 | CFLAGS="$CFLAGS -no-gcc" |
| 16372 | cat >conftest.$ac_ext <<_ACEOF |
| 16373 | #line 16373 "configure" |
| 16374 | #include "confdefs.h" |
| 16375 | |
| 16376 | int |
| 16377 | main () |
| 16378 | { |
| 16379 | |
| 16380 | #ifdef __INTEL_COMPILER |
| 16381 | #else |
| 16382 | make an error |
| 16383 | #endif |
| 16384 | |
| 16385 | ; |
| 16386 | return 0; |
| 16387 | } |
| 16388 | _ACEOF |
| 16389 | rm -f conftest.$ac_objext |
| 16390 | if { (eval echo "$as_me:16390: \"$ac_compile\"") >&5 |
| 16391 | (eval $ac_compile) 2>&5 |
| 16392 | ac_status=$? |
| 16393 | echo "$as_me:16393: \$? = $ac_status" >&5 |
| 16394 | (exit $ac_status); } && |
| 16395 | { ac_try='test -s conftest.$ac_objext' |
| 16396 | { (eval echo "$as_me:16396: \"$ac_try\"") >&5 |
| 16397 | (eval $ac_try) 2>&5 |
| 16398 | ac_status=$? |
| 16399 | echo "$as_me:16399: \$? = $ac_status" >&5 |
| 16400 | (exit $ac_status); }; }; then |
| 16401 | INTEL_COMPILER=yes |
| 16402 | cf_save_CFLAGS="$cf_save_CFLAGS -we147" |
| 16403 | |
| 16404 | else |
| 16405 | echo "$as_me: failed program was:" >&5 |
| 16406 | cat conftest.$ac_ext >&5 |
| 16407 | fi |
| 16408 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 16409 | CFLAGS="$cf_save_CFLAGS" |
| 16410 | echo "$as_me:16410: result: $INTEL_COMPILER" >&5 |
| 16411 | echo "${ECHO_T}$INTEL_COMPILER" >&6 |
| 16412 | ;; |
| 16413 | esac |
| 16414 | fi |
| 16415 | |
| 16416 | CLANG_COMPILER=no |
| 16417 | |
| 16418 | if test "$GCC" = yes ; then |
| 16419 | echo "$as_me:16419: checking if this is really Clang C compiler" >&5 |
| 16420 | echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6 |
| 16421 | cf_save_CFLAGS="$CFLAGS" |
| 16422 | CFLAGS="$CFLAGS -Qunused-arguments" |
| 16423 | cat >conftest.$ac_ext <<_ACEOF |
| 16424 | #line 16424 "configure" |
| 16425 | #include "confdefs.h" |
| 16426 | |
| 16427 | int |
| 16428 | main () |
| 16429 | { |
| 16430 | |
| 16431 | #ifdef __clang__ |
| 16432 | #else |
| 16433 | make an error |
| 16434 | #endif |
| 16435 | |
| 16436 | ; |
| 16437 | return 0; |
| 16438 | } |
| 16439 | _ACEOF |
| 16440 | rm -f conftest.$ac_objext |
| 16441 | if { (eval echo "$as_me:16441: \"$ac_compile\"") >&5 |
| 16442 | (eval $ac_compile) 2>&5 |
| 16443 | ac_status=$? |
| 16444 | echo "$as_me:16444: \$? = $ac_status" >&5 |
| 16445 | (exit $ac_status); } && |
| 16446 | { ac_try='test -s conftest.$ac_objext' |
| 16447 | { (eval echo "$as_me:16447: \"$ac_try\"") >&5 |
| 16448 | (eval $ac_try) 2>&5 |
| 16449 | ac_status=$? |
| 16450 | echo "$as_me:16450: \$? = $ac_status" >&5 |
| 16451 | (exit $ac_status); }; }; then |
| 16452 | CLANG_COMPILER=yes |
| 16453 | cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments" |
| 16454 | |
| 16455 | else |
| 16456 | echo "$as_me: failed program was:" >&5 |
| 16457 | cat conftest.$ac_ext >&5 |
| 16458 | fi |
| 16459 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 16460 | CFLAGS="$cf_save_CFLAGS" |
| 16461 | echo "$as_me:16461: result: $CLANG_COMPILER" >&5 |
| 16462 | echo "${ECHO_T}$CLANG_COMPILER" >&6 |
| 16463 | fi |
| 16464 | |
| 16465 | cat > conftest.$ac_ext <<EOF |
| 16466 | #line 16466 "${as_me:-configure}" |
| 16467 | int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; } |
| 16468 | EOF |
| 16469 | |
| 16470 | if test "$INTEL_COMPILER" = yes |
| 16471 | then |
| 16472 | # The "-wdXXX" options suppress warnings: |
| 16473 | # remark #1419: external declaration in primary source file |
| 16474 | # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem) |
| 16475 | # remark #1684: conversion from pointer to same-sized integral type (potential portability problem) |
| 16476 | # remark #193: zero used for undefined preprocessing identifier |
| 16477 | # remark #593: variable "curs_sb_left_arrow" was set but never used |
| 16478 | # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits |
| 16479 | # remark #869: parameter "tw" was never referenced |
| 16480 | # remark #981: operands are evaluated in unspecified order |
| 16481 | # warning #279: controlling expression is constant |
| 16482 | |
| 16483 | { echo "$as_me:16483: checking for $CC warning options..." >&5 |
| 16484 | echo "$as_me: checking for $CC warning options..." >&6;} |
| 16485 | cf_save_CFLAGS="$CFLAGS" |
| 16486 | EXTRA_CFLAGS="-Wall" |
| 16487 | for cf_opt in \ |
| 16488 | wd1419 \ |
| 16489 | wd1683 \ |
| 16490 | wd1684 \ |
| 16491 | wd193 \ |
| 16492 | wd593 \ |
| 16493 | wd279 \ |
| 16494 | wd810 \ |
| 16495 | wd869 \ |
| 16496 | wd981 |
| 16497 | do |
| 16498 | CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt" |
| 16499 | if { (eval echo "$as_me:16499: \"$ac_compile\"") >&5 |
| 16500 | (eval $ac_compile) 2>&5 |
| 16501 | ac_status=$? |
| 16502 | echo "$as_me:16502: \$? = $ac_status" >&5 |
| 16503 | (exit $ac_status); }; then |
| 16504 | test -n "$verbose" && echo "$as_me:16504: result: ... -$cf_opt" >&5 |
| 16505 | echo "${ECHO_T}... -$cf_opt" >&6 |
| 16506 | EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt" |
| 16507 | fi |
| 16508 | done |
| 16509 | CFLAGS="$cf_save_CFLAGS" |
| 16510 | |
| 16511 | elif test "$GCC" = yes |
| 16512 | then |
| 16513 | { echo "$as_me:16513: checking for $CC warning options..." >&5 |
| 16514 | echo "$as_me: checking for $CC warning options..." >&6;} |
| 16515 | cf_save_CFLAGS="$CFLAGS" |
| 16516 | EXTRA_CFLAGS= |
| 16517 | cf_warn_CONST="" |
| 16518 | test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings" |
| 16519 | cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs" |
| 16520 | test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings= |
| 16521 | for cf_opt in W Wall \ |
| 16522 | Wbad-function-cast \ |
| 16523 | Wcast-align \ |
| 16524 | Wcast-qual \ |
| 16525 | Wdeclaration-after-statement \ |
| 16526 | Wextra \ |
| 16527 | Winline \ |
| 16528 | Wmissing-declarations \ |
| 16529 | Wmissing-prototypes \ |
| 16530 | Wnested-externs \ |
| 16531 | Wpointer-arith \ |
| 16532 | Wshadow \ |
| 16533 | Wstrict-prototypes \ |
| 16534 | Wundef $cf_gcc_warnings $cf_warn_CONST |
| 16535 | do |
| 16536 | CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt" |
| 16537 | if { (eval echo "$as_me:16537: \"$ac_compile\"") >&5 |
| 16538 | (eval $ac_compile) 2>&5 |
| 16539 | ac_status=$? |
| 16540 | echo "$as_me:16540: \$? = $ac_status" >&5 |
| 16541 | (exit $ac_status); }; then |
| 16542 | test -n "$verbose" && echo "$as_me:16542: result: ... -$cf_opt" >&5 |
| 16543 | echo "${ECHO_T}... -$cf_opt" >&6 |
| 16544 | case $cf_opt in |
| 16545 | (Wcast-qual) |
| 16546 | CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES" |
| 16547 | ;; |
| 16548 | (Winline) |
| 16549 | case $GCC_VERSION in |
| 16550 | ([34].*) |
| 16551 | test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6 |
| 16552 | |
| 16553 | echo "${as_me:-configure}:16553: testing feature is broken in gcc $GCC_VERSION ..." 1>&5 |
| 16554 | |
| 16555 | continue;; |
| 16556 | esac |
| 16557 | ;; |
| 16558 | (Wpointer-arith) |
| 16559 | case $GCC_VERSION in |
| 16560 | ([12].*) |
| 16561 | test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6 |
| 16562 | |
| 16563 | echo "${as_me:-configure}:16563: testing feature is broken in gcc $GCC_VERSION ..." 1>&5 |
| 16564 | |
| 16565 | continue;; |
| 16566 | esac |
| 16567 | ;; |
| 16568 | esac |
| 16569 | EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt" |
| 16570 | fi |
| 16571 | done |
| 16572 | CFLAGS="$cf_save_CFLAGS" |
| 16573 | fi |
| 16574 | rm -rf conftest* |
| 16575 | |
| 16576 | fi |
| 16577 | fi |
| 16578 | |
| 16579 | echo "$as_me:16579: checking if you want to use dmalloc for testing" >&5 |
| 16580 | echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6 |
| 16581 | |
| 16582 | # Check whether --with-dmalloc or --without-dmalloc was given. |
| 16583 | if test "${with_dmalloc+set}" = set; then |
| 16584 | withval="$with_dmalloc" |
| 16585 | |
| 16586 | cat >>confdefs.h <<EOF |
| 16587 | #define USE_DMALLOC 1 |
| 16588 | EOF |
| 16589 | |
| 16590 | : ${with_cflags:=-g} |
| 16591 | : ${with_no_leaks:=yes} |
| 16592 | with_dmalloc=yes |
| 16593 | else |
| 16594 | with_dmalloc= |
| 16595 | fi; |
| 16596 | echo "$as_me:16596: result: ${with_dmalloc:-no}" >&5 |
| 16597 | echo "${ECHO_T}${with_dmalloc:-no}" >&6 |
| 16598 | |
| 16599 | case .$with_cflags in |
| 16600 | (.*-g*) |
| 16601 | case .$CFLAGS in |
| 16602 | (.*-g*) |
| 16603 | ;; |
| 16604 | (*) |
| 16605 | |
| 16606 | cf_fix_cppflags=no |
| 16607 | cf_new_cflags= |
| 16608 | cf_new_cppflags= |
| 16609 | cf_new_extra_cppflags= |
| 16610 | |
| 16611 | for cf_add_cflags in -g |
| 16612 | do |
| 16613 | case $cf_fix_cppflags in |
| 16614 | (no) |
| 16615 | case $cf_add_cflags in |
| 16616 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 16617 | case $cf_add_cflags in |
| 16618 | (-D*) |
| 16619 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 16620 | |
| 16621 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 16622 | && test -z "${cf_tst_cflags}" \ |
| 16623 | && cf_fix_cppflags=yes |
| 16624 | |
| 16625 | if test $cf_fix_cppflags = yes ; then |
| 16626 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 16627 | continue |
| 16628 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 16629 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 16630 | continue |
| 16631 | fi |
| 16632 | ;; |
| 16633 | esac |
| 16634 | case "$CPPFLAGS" in |
| 16635 | (*$cf_add_cflags) |
| 16636 | ;; |
| 16637 | (*) |
| 16638 | case $cf_add_cflags in |
| 16639 | (-D*) |
| 16640 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 16641 | |
| 16642 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 16643 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 16644 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 16645 | |
| 16646 | ;; |
| 16647 | esac |
| 16648 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 16649 | ;; |
| 16650 | esac |
| 16651 | ;; |
| 16652 | (*) |
| 16653 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 16654 | ;; |
| 16655 | esac |
| 16656 | ;; |
| 16657 | (yes) |
| 16658 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 16659 | |
| 16660 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 16661 | |
| 16662 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 16663 | && test -z "${cf_tst_cflags}" \ |
| 16664 | && cf_fix_cppflags=no |
| 16665 | ;; |
| 16666 | esac |
| 16667 | done |
| 16668 | |
| 16669 | if test -n "$cf_new_cflags" ; then |
| 16670 | |
| 16671 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 16672 | fi |
| 16673 | |
| 16674 | if test -n "$cf_new_cppflags" ; then |
| 16675 | |
| 16676 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 16677 | fi |
| 16678 | |
| 16679 | if test -n "$cf_new_extra_cppflags" ; then |
| 16680 | |
| 16681 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 16682 | fi |
| 16683 | |
| 16684 | ;; |
| 16685 | esac |
| 16686 | ;; |
| 16687 | esac |
| 16688 | |
| 16689 | if test "$with_dmalloc" = yes ; then |
| 16690 | echo "$as_me:16690: checking for dmalloc.h" >&5 |
| 16691 | echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6 |
| 16692 | if test "${ac_cv_header_dmalloc_h+set}" = set; then |
| 16693 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16694 | else |
| 16695 | cat >conftest.$ac_ext <<_ACEOF |
| 16696 | #line 16696 "configure" |
| 16697 | #include "confdefs.h" |
| 16698 | #include <dmalloc.h> |
| 16699 | _ACEOF |
| 16700 | if { (eval echo "$as_me:16700: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 16701 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 16702 | ac_status=$? |
| 16703 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 16704 | rm -f conftest.er1 |
| 16705 | cat conftest.err >&5 |
| 16706 | echo "$as_me:16706: \$? = $ac_status" >&5 |
| 16707 | (exit $ac_status); } >/dev/null; then |
| 16708 | if test -s conftest.err; then |
| 16709 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 16710 | else |
| 16711 | ac_cpp_err= |
| 16712 | fi |
| 16713 | else |
| 16714 | ac_cpp_err=yes |
| 16715 | fi |
| 16716 | if test -z "$ac_cpp_err"; then |
| 16717 | ac_cv_header_dmalloc_h=yes |
| 16718 | else |
| 16719 | echo "$as_me: failed program was:" >&5 |
| 16720 | cat conftest.$ac_ext >&5 |
| 16721 | ac_cv_header_dmalloc_h=no |
| 16722 | fi |
| 16723 | rm -f conftest.err conftest.$ac_ext |
| 16724 | fi |
| 16725 | echo "$as_me:16725: result: $ac_cv_header_dmalloc_h" >&5 |
| 16726 | echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6 |
| 16727 | if test $ac_cv_header_dmalloc_h = yes; then |
| 16728 | |
| 16729 | echo "$as_me:16729: checking for dmalloc_debug in -ldmalloc" >&5 |
| 16730 | echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6 |
| 16731 | if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then |
| 16732 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16733 | else |
| 16734 | ac_check_lib_save_LIBS=$LIBS |
| 16735 | LIBS="-ldmalloc $LIBS" |
| 16736 | cat >conftest.$ac_ext <<_ACEOF |
| 16737 | #line 16737 "configure" |
| 16738 | #include "confdefs.h" |
| 16739 | |
| 16740 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 16741 | #ifdef __cplusplus |
| 16742 | extern "C" |
| 16743 | #endif |
| 16744 | /* We use char because int might match the return type of a gcc2 |
| 16745 | builtin and then its argument prototype would still apply. */ |
| 16746 | char dmalloc_debug (); |
| 16747 | int |
| 16748 | main () |
| 16749 | { |
| 16750 | dmalloc_debug (); |
| 16751 | ; |
| 16752 | return 0; |
| 16753 | } |
| 16754 | _ACEOF |
| 16755 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 16756 | if { (eval echo "$as_me:16756: \"$ac_link\"") >&5 |
| 16757 | (eval $ac_link) 2>&5 |
| 16758 | ac_status=$? |
| 16759 | echo "$as_me:16759: \$? = $ac_status" >&5 |
| 16760 | (exit $ac_status); } && |
| 16761 | { ac_try='test -s conftest$ac_exeext' |
| 16762 | { (eval echo "$as_me:16762: \"$ac_try\"") >&5 |
| 16763 | (eval $ac_try) 2>&5 |
| 16764 | ac_status=$? |
| 16765 | echo "$as_me:16765: \$? = $ac_status" >&5 |
| 16766 | (exit $ac_status); }; }; then |
| 16767 | ac_cv_lib_dmalloc_dmalloc_debug=yes |
| 16768 | else |
| 16769 | echo "$as_me: failed program was:" >&5 |
| 16770 | cat conftest.$ac_ext >&5 |
| 16771 | ac_cv_lib_dmalloc_dmalloc_debug=no |
| 16772 | fi |
| 16773 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 16774 | LIBS=$ac_check_lib_save_LIBS |
| 16775 | fi |
| 16776 | echo "$as_me:16776: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5 |
| 16777 | echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6 |
| 16778 | if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then |
| 16779 | cat >>confdefs.h <<EOF |
| 16780 | #define HAVE_LIBDMALLOC 1 |
| 16781 | EOF |
| 16782 | |
| 16783 | LIBS="-ldmalloc $LIBS" |
| 16784 | |
| 16785 | fi |
| 16786 | |
| 16787 | fi |
| 16788 | |
| 16789 | fi |
| 16790 | |
| 16791 | echo "$as_me:16791: checking if you want to use dbmalloc for testing" >&5 |
| 16792 | echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6 |
| 16793 | |
| 16794 | # Check whether --with-dbmalloc or --without-dbmalloc was given. |
| 16795 | if test "${with_dbmalloc+set}" = set; then |
| 16796 | withval="$with_dbmalloc" |
| 16797 | |
| 16798 | cat >>confdefs.h <<EOF |
| 16799 | #define USE_DBMALLOC 1 |
| 16800 | EOF |
| 16801 | |
| 16802 | : ${with_cflags:=-g} |
| 16803 | : ${with_no_leaks:=yes} |
| 16804 | with_dbmalloc=yes |
| 16805 | else |
| 16806 | with_dbmalloc= |
| 16807 | fi; |
| 16808 | echo "$as_me:16808: result: ${with_dbmalloc:-no}" >&5 |
| 16809 | echo "${ECHO_T}${with_dbmalloc:-no}" >&6 |
| 16810 | |
| 16811 | case .$with_cflags in |
| 16812 | (.*-g*) |
| 16813 | case .$CFLAGS in |
| 16814 | (.*-g*) |
| 16815 | ;; |
| 16816 | (*) |
| 16817 | |
| 16818 | cf_fix_cppflags=no |
| 16819 | cf_new_cflags= |
| 16820 | cf_new_cppflags= |
| 16821 | cf_new_extra_cppflags= |
| 16822 | |
| 16823 | for cf_add_cflags in -g |
| 16824 | do |
| 16825 | case $cf_fix_cppflags in |
| 16826 | (no) |
| 16827 | case $cf_add_cflags in |
| 16828 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 16829 | case $cf_add_cflags in |
| 16830 | (-D*) |
| 16831 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 16832 | |
| 16833 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 16834 | && test -z "${cf_tst_cflags}" \ |
| 16835 | && cf_fix_cppflags=yes |
| 16836 | |
| 16837 | if test $cf_fix_cppflags = yes ; then |
| 16838 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 16839 | continue |
| 16840 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 16841 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 16842 | continue |
| 16843 | fi |
| 16844 | ;; |
| 16845 | esac |
| 16846 | case "$CPPFLAGS" in |
| 16847 | (*$cf_add_cflags) |
| 16848 | ;; |
| 16849 | (*) |
| 16850 | case $cf_add_cflags in |
| 16851 | (-D*) |
| 16852 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 16853 | |
| 16854 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 16855 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 16856 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 16857 | |
| 16858 | ;; |
| 16859 | esac |
| 16860 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 16861 | ;; |
| 16862 | esac |
| 16863 | ;; |
| 16864 | (*) |
| 16865 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 16866 | ;; |
| 16867 | esac |
| 16868 | ;; |
| 16869 | (yes) |
| 16870 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 16871 | |
| 16872 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 16873 | |
| 16874 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 16875 | && test -z "${cf_tst_cflags}" \ |
| 16876 | && cf_fix_cppflags=no |
| 16877 | ;; |
| 16878 | esac |
| 16879 | done |
| 16880 | |
| 16881 | if test -n "$cf_new_cflags" ; then |
| 16882 | |
| 16883 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 16884 | fi |
| 16885 | |
| 16886 | if test -n "$cf_new_cppflags" ; then |
| 16887 | |
| 16888 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 16889 | fi |
| 16890 | |
| 16891 | if test -n "$cf_new_extra_cppflags" ; then |
| 16892 | |
| 16893 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 16894 | fi |
| 16895 | |
| 16896 | ;; |
| 16897 | esac |
| 16898 | ;; |
| 16899 | esac |
| 16900 | |
| 16901 | if test "$with_dbmalloc" = yes ; then |
| 16902 | echo "$as_me:16902: checking for dbmalloc.h" >&5 |
| 16903 | echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6 |
| 16904 | if test "${ac_cv_header_dbmalloc_h+set}" = set; then |
| 16905 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16906 | else |
| 16907 | cat >conftest.$ac_ext <<_ACEOF |
| 16908 | #line 16908 "configure" |
| 16909 | #include "confdefs.h" |
| 16910 | #include <dbmalloc.h> |
| 16911 | _ACEOF |
| 16912 | if { (eval echo "$as_me:16912: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 16913 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 16914 | ac_status=$? |
| 16915 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 16916 | rm -f conftest.er1 |
| 16917 | cat conftest.err >&5 |
| 16918 | echo "$as_me:16918: \$? = $ac_status" >&5 |
| 16919 | (exit $ac_status); } >/dev/null; then |
| 16920 | if test -s conftest.err; then |
| 16921 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 16922 | else |
| 16923 | ac_cpp_err= |
| 16924 | fi |
| 16925 | else |
| 16926 | ac_cpp_err=yes |
| 16927 | fi |
| 16928 | if test -z "$ac_cpp_err"; then |
| 16929 | ac_cv_header_dbmalloc_h=yes |
| 16930 | else |
| 16931 | echo "$as_me: failed program was:" >&5 |
| 16932 | cat conftest.$ac_ext >&5 |
| 16933 | ac_cv_header_dbmalloc_h=no |
| 16934 | fi |
| 16935 | rm -f conftest.err conftest.$ac_ext |
| 16936 | fi |
| 16937 | echo "$as_me:16937: result: $ac_cv_header_dbmalloc_h" >&5 |
| 16938 | echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6 |
| 16939 | if test $ac_cv_header_dbmalloc_h = yes; then |
| 16940 | |
| 16941 | echo "$as_me:16941: checking for debug_malloc in -ldbmalloc" >&5 |
| 16942 | echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6 |
| 16943 | if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then |
| 16944 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16945 | else |
| 16946 | ac_check_lib_save_LIBS=$LIBS |
| 16947 | LIBS="-ldbmalloc $LIBS" |
| 16948 | cat >conftest.$ac_ext <<_ACEOF |
| 16949 | #line 16949 "configure" |
| 16950 | #include "confdefs.h" |
| 16951 | |
| 16952 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 16953 | #ifdef __cplusplus |
| 16954 | extern "C" |
| 16955 | #endif |
| 16956 | /* We use char because int might match the return type of a gcc2 |
| 16957 | builtin and then its argument prototype would still apply. */ |
| 16958 | char debug_malloc (); |
| 16959 | int |
| 16960 | main () |
| 16961 | { |
| 16962 | debug_malloc (); |
| 16963 | ; |
| 16964 | return 0; |
| 16965 | } |
| 16966 | _ACEOF |
| 16967 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 16968 | if { (eval echo "$as_me:16968: \"$ac_link\"") >&5 |
| 16969 | (eval $ac_link) 2>&5 |
| 16970 | ac_status=$? |
| 16971 | echo "$as_me:16971: \$? = $ac_status" >&5 |
| 16972 | (exit $ac_status); } && |
| 16973 | { ac_try='test -s conftest$ac_exeext' |
| 16974 | { (eval echo "$as_me:16974: \"$ac_try\"") >&5 |
| 16975 | (eval $ac_try) 2>&5 |
| 16976 | ac_status=$? |
| 16977 | echo "$as_me:16977: \$? = $ac_status" >&5 |
| 16978 | (exit $ac_status); }; }; then |
| 16979 | ac_cv_lib_dbmalloc_debug_malloc=yes |
| 16980 | else |
| 16981 | echo "$as_me: failed program was:" >&5 |
| 16982 | cat conftest.$ac_ext >&5 |
| 16983 | ac_cv_lib_dbmalloc_debug_malloc=no |
| 16984 | fi |
| 16985 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 16986 | LIBS=$ac_check_lib_save_LIBS |
| 16987 | fi |
| 16988 | echo "$as_me:16988: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5 |
| 16989 | echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6 |
| 16990 | if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then |
| 16991 | cat >>confdefs.h <<EOF |
| 16992 | #define HAVE_LIBDBMALLOC 1 |
| 16993 | EOF |
| 16994 | |
| 16995 | LIBS="-ldbmalloc $LIBS" |
| 16996 | |
| 16997 | fi |
| 16998 | |
| 16999 | fi |
| 17000 | |
| 17001 | fi |
| 17002 | |
| 17003 | echo "$as_me:17003: checking if you want to use valgrind for testing" >&5 |
| 17004 | echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6 |
| 17005 | |
| 17006 | # Check whether --with-valgrind or --without-valgrind was given. |
| 17007 | if test "${with_valgrind+set}" = set; then |
| 17008 | withval="$with_valgrind" |
| 17009 | |
| 17010 | cat >>confdefs.h <<EOF |
| 17011 | #define USE_VALGRIND 1 |
| 17012 | EOF |
| 17013 | |
| 17014 | : ${with_cflags:=-g} |
| 17015 | : ${with_no_leaks:=yes} |
| 17016 | with_valgrind=yes |
| 17017 | else |
| 17018 | with_valgrind= |
| 17019 | fi; |
| 17020 | echo "$as_me:17020: result: ${with_valgrind:-no}" >&5 |
| 17021 | echo "${ECHO_T}${with_valgrind:-no}" >&6 |
| 17022 | |
| 17023 | case .$with_cflags in |
| 17024 | (.*-g*) |
| 17025 | case .$CFLAGS in |
| 17026 | (.*-g*) |
| 17027 | ;; |
| 17028 | (*) |
| 17029 | |
| 17030 | cf_fix_cppflags=no |
| 17031 | cf_new_cflags= |
| 17032 | cf_new_cppflags= |
| 17033 | cf_new_extra_cppflags= |
| 17034 | |
| 17035 | for cf_add_cflags in -g |
| 17036 | do |
| 17037 | case $cf_fix_cppflags in |
| 17038 | (no) |
| 17039 | case $cf_add_cflags in |
| 17040 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 17041 | case $cf_add_cflags in |
| 17042 | (-D*) |
| 17043 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 17044 | |
| 17045 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 17046 | && test -z "${cf_tst_cflags}" \ |
| 17047 | && cf_fix_cppflags=yes |
| 17048 | |
| 17049 | if test $cf_fix_cppflags = yes ; then |
| 17050 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 17051 | continue |
| 17052 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 17053 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 17054 | continue |
| 17055 | fi |
| 17056 | ;; |
| 17057 | esac |
| 17058 | case "$CPPFLAGS" in |
| 17059 | (*$cf_add_cflags) |
| 17060 | ;; |
| 17061 | (*) |
| 17062 | case $cf_add_cflags in |
| 17063 | (-D*) |
| 17064 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 17065 | |
| 17066 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 17067 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 17068 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 17069 | |
| 17070 | ;; |
| 17071 | esac |
| 17072 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 17073 | ;; |
| 17074 | esac |
| 17075 | ;; |
| 17076 | (*) |
| 17077 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 17078 | ;; |
| 17079 | esac |
| 17080 | ;; |
| 17081 | (yes) |
| 17082 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 17083 | |
| 17084 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 17085 | |
| 17086 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 17087 | && test -z "${cf_tst_cflags}" \ |
| 17088 | && cf_fix_cppflags=no |
| 17089 | ;; |
| 17090 | esac |
| 17091 | done |
| 17092 | |
| 17093 | if test -n "$cf_new_cflags" ; then |
| 17094 | |
| 17095 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 17096 | fi |
| 17097 | |
| 17098 | if test -n "$cf_new_cppflags" ; then |
| 17099 | |
| 17100 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 17101 | fi |
| 17102 | |
| 17103 | if test -n "$cf_new_extra_cppflags" ; then |
| 17104 | |
| 17105 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 17106 | fi |
| 17107 | |
| 17108 | ;; |
| 17109 | esac |
| 17110 | ;; |
| 17111 | esac |
| 17112 | |
| 17113 | echo "$as_me:17113: checking if you want to perform memory-leak testing" >&5 |
| 17114 | echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6 |
| 17115 | |
| 17116 | # Check whether --enable-leaks or --disable-leaks was given. |
| 17117 | if test "${enable_leaks+set}" = set; then |
| 17118 | enableval="$enable_leaks" |
| 17119 | if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi |
| 17120 | else |
| 17121 | : ${with_no_leaks:=no} |
| 17122 | fi; |
| 17123 | echo "$as_me:17123: result: $with_no_leaks" >&5 |
| 17124 | echo "${ECHO_T}$with_no_leaks" >&6 |
| 17125 | |
| 17126 | if test "$with_no_leaks" = yes ; then |
| 17127 | |
| 17128 | cat >>confdefs.h <<\EOF |
| 17129 | #define NO_LEAKS 1 |
| 17130 | EOF |
| 17131 | |
| 17132 | cat >>confdefs.h <<\EOF |
| 17133 | #define YY_NO_LEAKS 1 |
| 17134 | EOF |
| 17135 | |
| 17136 | fi |
| 17137 | |
| 17138 | LD_RPATH_OPT= |
| 17139 | echo "$as_me:17139: checking for an rpath option" >&5 |
| 17140 | echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6 |
| 17141 | case $cf_cv_system_name in |
| 17142 | (irix*) |
| 17143 | if test "$GCC" = yes; then |
| 17144 | LD_RPATH_OPT="-Wl,-rpath," |
| 17145 | else |
| 17146 | LD_RPATH_OPT="-rpath " |
| 17147 | fi |
| 17148 | ;; |
| 17149 | (linux*|gnu*|k*bsd*-gnu) |
| 17150 | LD_RPATH_OPT="-Wl,-rpath," |
| 17151 | ;; |
| 17152 | (openbsd[2-9].*|mirbsd*) |
| 17153 | LD_RPATH_OPT="-Wl,-rpath," |
| 17154 | ;; |
| 17155 | (dragonfly*|freebsd*) |
| 17156 | LD_RPATH_OPT="-rpath " |
| 17157 | ;; |
| 17158 | (netbsd*) |
| 17159 | LD_RPATH_OPT="-Wl,-rpath," |
| 17160 | ;; |
| 17161 | (osf*|mls+*) |
| 17162 | LD_RPATH_OPT="-rpath " |
| 17163 | ;; |
| 17164 | (solaris2*) |
| 17165 | LD_RPATH_OPT="-R" |
| 17166 | ;; |
| 17167 | (*) |
| 17168 | ;; |
| 17169 | esac |
| 17170 | echo "$as_me:17170: result: $LD_RPATH_OPT" >&5 |
| 17171 | echo "${ECHO_T}$LD_RPATH_OPT" >&6 |
| 17172 | |
| 17173 | case "x$LD_RPATH_OPT" in |
| 17174 | (x-R*) |
| 17175 | echo "$as_me:17175: checking if we need a space after rpath option" >&5 |
| 17176 | echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6 |
| 17177 | cf_save_LIBS="$LIBS" |
| 17178 | |
| 17179 | cf_add_libs="${LD_RPATH_OPT}$libdir" |
| 17180 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 17181 | for cf_add_1lib in $LIBS |
| 17182 | do |
| 17183 | for cf_add_2lib in $cf_add_libs |
| 17184 | do |
| 17185 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 17186 | then |
| 17187 | cf_add_1lib= |
| 17188 | break |
| 17189 | fi |
| 17190 | done |
| 17191 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 17192 | done |
| 17193 | LIBS="$cf_add_libs" |
| 17194 | |
| 17195 | cat >conftest.$ac_ext <<_ACEOF |
| 17196 | #line 17196 "configure" |
| 17197 | #include "confdefs.h" |
| 17198 | |
| 17199 | int |
| 17200 | main () |
| 17201 | { |
| 17202 | |
| 17203 | ; |
| 17204 | return 0; |
| 17205 | } |
| 17206 | _ACEOF |
| 17207 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 17208 | if { (eval echo "$as_me:17208: \"$ac_link\"") >&5 |
| 17209 | (eval $ac_link) 2>&5 |
| 17210 | ac_status=$? |
| 17211 | echo "$as_me:17211: \$? = $ac_status" >&5 |
| 17212 | (exit $ac_status); } && |
| 17213 | { ac_try='test -s conftest$ac_exeext' |
| 17214 | { (eval echo "$as_me:17214: \"$ac_try\"") >&5 |
| 17215 | (eval $ac_try) 2>&5 |
| 17216 | ac_status=$? |
| 17217 | echo "$as_me:17217: \$? = $ac_status" >&5 |
| 17218 | (exit $ac_status); }; }; then |
| 17219 | cf_rpath_space=no |
| 17220 | else |
| 17221 | echo "$as_me: failed program was:" >&5 |
| 17222 | cat conftest.$ac_ext >&5 |
| 17223 | cf_rpath_space=yes |
| 17224 | fi |
| 17225 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17226 | LIBS="$cf_save_LIBS" |
| 17227 | echo "$as_me:17227: result: $cf_rpath_space" >&5 |
| 17228 | echo "${ECHO_T}$cf_rpath_space" >&6 |
| 17229 | test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT " |
| 17230 | ;; |
| 17231 | esac |
| 17232 | |
| 17233 | echo "$as_me:17233: checking if rpath-hack should be disabled" >&5 |
| 17234 | echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6 |
| 17235 | |
| 17236 | # Check whether --enable-rpath-hack or --disable-rpath-hack was given. |
| 17237 | if test "${enable_rpath_hack+set}" = set; then |
| 17238 | enableval="$enable_rpath_hack" |
| 17239 | test "$enableval" != no && enableval=yes |
| 17240 | if test "$enableval" != "yes" ; then |
| 17241 | cf_disable_rpath_hack=yes |
| 17242 | else |
| 17243 | cf_disable_rpath_hack=no |
| 17244 | fi |
| 17245 | else |
| 17246 | enableval=yes |
| 17247 | cf_disable_rpath_hack=no |
| 17248 | |
| 17249 | fi; |
| 17250 | echo "$as_me:17250: result: $cf_disable_rpath_hack" >&5 |
| 17251 | echo "${ECHO_T}$cf_disable_rpath_hack" >&6 |
| 17252 | if test "$cf_disable_rpath_hack" = no ; then |
| 17253 | |
| 17254 | echo "$as_me:17254: checking for updated LDFLAGS" >&5 |
| 17255 | echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6 |
| 17256 | if test -n "$LD_RPATH_OPT" ; then |
| 17257 | echo "$as_me:17257: result: maybe" >&5 |
| 17258 | echo "${ECHO_T}maybe" >&6 |
| 17259 | |
| 17260 | for ac_prog in ldd |
| 17261 | do |
| 17262 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 17263 | set dummy $ac_prog; ac_word=$2 |
| 17264 | echo "$as_me:17264: checking for $ac_word" >&5 |
| 17265 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 17266 | if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then |
| 17267 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17268 | else |
| 17269 | if test -n "$cf_ldd_prog"; then |
| 17270 | ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test. |
| 17271 | else |
| 17272 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 17273 | ac_dummy="$PATH" |
| 17274 | for ac_dir in $ac_dummy; do |
| 17275 | IFS=$ac_save_IFS |
| 17276 | test -z "$ac_dir" && ac_dir=. |
| 17277 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 17278 | ac_cv_prog_cf_ldd_prog="$ac_prog" |
| 17279 | echo "$as_me:17279: found $ac_dir/$ac_word" >&5 |
| 17280 | break |
| 17281 | done |
| 17282 | |
| 17283 | fi |
| 17284 | fi |
| 17285 | cf_ldd_prog=$ac_cv_prog_cf_ldd_prog |
| 17286 | if test -n "$cf_ldd_prog"; then |
| 17287 | echo "$as_me:17287: result: $cf_ldd_prog" >&5 |
| 17288 | echo "${ECHO_T}$cf_ldd_prog" >&6 |
| 17289 | else |
| 17290 | echo "$as_me:17290: result: no" >&5 |
| 17291 | echo "${ECHO_T}no" >&6 |
| 17292 | fi |
| 17293 | |
| 17294 | test -n "$cf_ldd_prog" && break |
| 17295 | done |
| 17296 | test -n "$cf_ldd_prog" || cf_ldd_prog="no" |
| 17297 | |
| 17298 | cf_rpath_list="/usr/lib /lib" |
| 17299 | if test "$cf_ldd_prog" != no |
| 17300 | then |
| 17301 | cf_rpath_oops= |
| 17302 | |
| 17303 | cat >conftest.$ac_ext <<_ACEOF |
| 17304 | #line 17304 "configure" |
| 17305 | #include "confdefs.h" |
| 17306 | #include <stdio.h> |
| 17307 | int |
| 17308 | main () |
| 17309 | { |
| 17310 | printf("Hello"); |
| 17311 | ; |
| 17312 | return 0; |
| 17313 | } |
| 17314 | _ACEOF |
| 17315 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 17316 | if { (eval echo "$as_me:17316: \"$ac_link\"") >&5 |
| 17317 | (eval $ac_link) 2>&5 |
| 17318 | ac_status=$? |
| 17319 | echo "$as_me:17319: \$? = $ac_status" >&5 |
| 17320 | (exit $ac_status); } && |
| 17321 | { ac_try='test -s conftest$ac_exeext' |
| 17322 | { (eval echo "$as_me:17322: \"$ac_try\"") >&5 |
| 17323 | (eval $ac_try) 2>&5 |
| 17324 | ac_status=$? |
| 17325 | echo "$as_me:17325: \$? = $ac_status" >&5 |
| 17326 | (exit $ac_status); }; }; then |
| 17327 | cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq` |
| 17328 | cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq` |
| 17329 | else |
| 17330 | echo "$as_me: failed program was:" >&5 |
| 17331 | cat conftest.$ac_ext >&5 |
| 17332 | fi |
| 17333 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17334 | |
| 17335 | # If we passed the link-test, but get a "not found" on a given library, |
| 17336 | # this could be due to inept reconfiguration of gcc to make it only |
| 17337 | # partly honor /usr/local/lib (or whatever). Sometimes this behavior |
| 17338 | # is intentional, e.g., installing gcc in /usr/bin and suppressing the |
| 17339 | # /usr/local libraries. |
| 17340 | if test -n "$cf_rpath_oops" |
| 17341 | then |
| 17342 | for cf_rpath_src in $cf_rpath_oops |
| 17343 | do |
| 17344 | for cf_rpath_dir in \ |
| 17345 | /usr/local \ |
| 17346 | /usr/pkg \ |
| 17347 | /opt/sfw |
| 17348 | do |
| 17349 | if test -f $cf_rpath_dir/lib/$cf_rpath_src |
| 17350 | then |
| 17351 | test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6 |
| 17352 | |
| 17353 | echo "${as_me:-configure}:17353: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5 |
| 17354 | |
| 17355 | LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib" |
| 17356 | break |
| 17357 | fi |
| 17358 | done |
| 17359 | done |
| 17360 | fi |
| 17361 | fi |
| 17362 | |
| 17363 | test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6 |
| 17364 | |
| 17365 | echo "${as_me:-configure}:17365: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5 |
| 17366 | |
| 17367 | test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6 |
| 17368 | |
| 17369 | echo "${as_me:-configure}:17369: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5 |
| 17370 | |
| 17371 | cf_rpath_dst= |
| 17372 | for cf_rpath_src in $LDFLAGS |
| 17373 | do |
| 17374 | case $cf_rpath_src in |
| 17375 | (-L*) |
| 17376 | |
| 17377 | # check if this refers to a directory which we will ignore |
| 17378 | cf_rpath_skip=no |
| 17379 | if test -n "$cf_rpath_list" |
| 17380 | then |
| 17381 | for cf_rpath_item in $cf_rpath_list |
| 17382 | do |
| 17383 | if test "x$cf_rpath_src" = "x-L$cf_rpath_item" |
| 17384 | then |
| 17385 | cf_rpath_skip=yes |
| 17386 | break |
| 17387 | fi |
| 17388 | done |
| 17389 | fi |
| 17390 | |
| 17391 | if test "$cf_rpath_skip" = no |
| 17392 | then |
| 17393 | # transform the option |
| 17394 | if test "$LD_RPATH_OPT" = "-R " ; then |
| 17395 | cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"` |
| 17396 | else |
| 17397 | cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"` |
| 17398 | fi |
| 17399 | |
| 17400 | # if we have not already added this, add it now |
| 17401 | cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"` |
| 17402 | if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS" |
| 17403 | then |
| 17404 | test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6 |
| 17405 | |
| 17406 | echo "${as_me:-configure}:17406: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5 |
| 17407 | |
| 17408 | EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS" |
| 17409 | fi |
| 17410 | fi |
| 17411 | ;; |
| 17412 | esac |
| 17413 | cf_rpath_dst="$cf_rpath_dst $cf_rpath_src" |
| 17414 | done |
| 17415 | LDFLAGS=$cf_rpath_dst |
| 17416 | |
| 17417 | test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6 |
| 17418 | |
| 17419 | echo "${as_me:-configure}:17419: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5 |
| 17420 | |
| 17421 | test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6 |
| 17422 | |
| 17423 | echo "${as_me:-configure}:17423: testing ...checking LIBS $LIBS ..." 1>&5 |
| 17424 | |
| 17425 | cf_rpath_dst= |
| 17426 | for cf_rpath_src in $LIBS |
| 17427 | do |
| 17428 | case $cf_rpath_src in |
| 17429 | (-L*) |
| 17430 | |
| 17431 | # check if this refers to a directory which we will ignore |
| 17432 | cf_rpath_skip=no |
| 17433 | if test -n "$cf_rpath_list" |
| 17434 | then |
| 17435 | for cf_rpath_item in $cf_rpath_list |
| 17436 | do |
| 17437 | if test "x$cf_rpath_src" = "x-L$cf_rpath_item" |
| 17438 | then |
| 17439 | cf_rpath_skip=yes |
| 17440 | break |
| 17441 | fi |
| 17442 | done |
| 17443 | fi |
| 17444 | |
| 17445 | if test "$cf_rpath_skip" = no |
| 17446 | then |
| 17447 | # transform the option |
| 17448 | if test "$LD_RPATH_OPT" = "-R " ; then |
| 17449 | cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"` |
| 17450 | else |
| 17451 | cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"` |
| 17452 | fi |
| 17453 | |
| 17454 | # if we have not already added this, add it now |
| 17455 | cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"` |
| 17456 | if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS" |
| 17457 | then |
| 17458 | test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6 |
| 17459 | |
| 17460 | echo "${as_me:-configure}:17460: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5 |
| 17461 | |
| 17462 | EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS" |
| 17463 | fi |
| 17464 | fi |
| 17465 | ;; |
| 17466 | esac |
| 17467 | cf_rpath_dst="$cf_rpath_dst $cf_rpath_src" |
| 17468 | done |
| 17469 | LIBS=$cf_rpath_dst |
| 17470 | |
| 17471 | test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6 |
| 17472 | |
| 17473 | echo "${as_me:-configure}:17473: testing ...checked LIBS $LIBS ..." 1>&5 |
| 17474 | |
| 17475 | test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6 |
| 17476 | |
| 17477 | echo "${as_me:-configure}:17477: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5 |
| 17478 | |
| 17479 | else |
| 17480 | echo "$as_me:17480: result: no" >&5 |
| 17481 | echo "${ECHO_T}no" >&6 |
| 17482 | fi |
| 17483 | |
| 17484 | fi |
| 17485 | |
| 17486 | TEST_ARGS="$LIBS" |
| 17487 | LIBS= |
| 17488 | |
| 17489 | ac_config_files="$ac_config_files Makefile" |
| 17490 | ac_config_commands="$ac_config_commands default" |
| 17491 | cat >confcache <<\_ACEOF |
| 17492 | # This file is a shell script that caches the results of configure |
| 17493 | # tests run on this system so they can be shared between configure |
| 17494 | # scripts and configure runs, see configure's option --config-cache. |
| 17495 | # It is not useful on other systems. If it contains results you don't |
| 17496 | # want to keep, you may remove or edit it. |
| 17497 | # |
| 17498 | # config.status only pays attention to the cache file if you give it |
| 17499 | # the --recheck option to rerun configure. |
| 17500 | # |
| 17501 | # `ac_cv_env_foo' variables (set or unset) will be overriden when |
| 17502 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 17503 | # following values. |
| 17504 | |
| 17505 | _ACEOF |
| 17506 | |
| 17507 | # The following way of writing the cache mishandles newlines in values, |
| 17508 | # but we know of no workaround that is simple, portable, and efficient. |
| 17509 | # So, don't put newlines in cache variables' values. |
| 17510 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 17511 | # and sets the high bit in the cache file unless we assign to the vars. |
| 17512 | { |
| 17513 | (set) 2>&1 | |
| 17514 | case `(ac_space=' '; set | grep ac_space) 2>&1` in |
| 17515 | *ac_space=\ *) |
| 17516 | # `set' does not quote correctly, so add quotes (double-quote |
| 17517 | # substitution turns \\\\ into \\, and sed turns \\ into \). |
| 17518 | sed -n \ |
| 17519 | "s/'/'\\\\''/g; |
| 17520 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" |
| 17521 | ;; |
| 17522 | *) |
| 17523 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 17524 | sed -n \ |
| 17525 | "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" |
| 17526 | ;; |
| 17527 | esac; |
| 17528 | } | |
| 17529 | sed ' |
| 17530 | t clear |
| 17531 | : clear |
| 17532 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 17533 | t end |
| 17534 | /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 17535 | : end' >>confcache |
| 17536 | if cmp -s $cache_file confcache; then :; else |
| 17537 | if test -w $cache_file; then |
| 17538 | test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file" |
| 17539 | cat confcache >$cache_file |
| 17540 | else |
| 17541 | echo "not updating unwritable cache $cache_file" |
| 17542 | fi |
| 17543 | fi |
| 17544 | rm -f confcache |
| 17545 | |
| 17546 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 17547 | # Let make expand exec_prefix. |
| 17548 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
| 17549 | |
| 17550 | # VPATH may cause trouble with some makes, so we remove $(srcdir), |
| 17551 | # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and |
| 17552 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 17553 | # (actually we leave an empty line to preserve line numbers). |
| 17554 | if test "x$srcdir" = x.; then |
| 17555 | ac_vpsub='/^[ ]*VPATH[ ]*=/{ |
| 17556 | s/:*\$(srcdir):*/:/; |
| 17557 | s/:*\${srcdir}:*/:/; |
| 17558 | s/:*@srcdir@:*/:/; |
| 17559 | s/^\([^=]*=[ ]*\):*/\1/; |
| 17560 | s/:*$//; |
| 17561 | s/^[^=]*=[ ]*$//; |
| 17562 | }' |
| 17563 | fi |
| 17564 | |
| 17565 | DEFS=-DHAVE_CONFIG_H |
| 17566 | |
| 17567 | : ${CONFIG_STATUS=./config.status} |
| 17568 | ac_clean_files_save=$ac_clean_files |
| 17569 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
| 17570 | { echo "$as_me:17570: creating $CONFIG_STATUS" >&5 |
| 17571 | echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 17572 | cat >$CONFIG_STATUS <<_ACEOF |
| 17573 | #! $SHELL |
| 17574 | # Generated automatically by configure. |
| 17575 | # Run this file to recreate the current configuration. |
| 17576 | # Compiler output produced by configure, useful for debugging |
| 17577 | # configure, is in config.log if it exists. |
| 17578 | |
| 17579 | debug=false |
| 17580 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 17581 | ac_cs_invocation="\$0 \$@" |
| 17582 | |
| 17583 | _ACEOF |
| 17584 | |
| 17585 | cat >>$CONFIG_STATUS <<\_ACEOF |
| 17586 | # Be Bourne compatible |
| 17587 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then |
| 17588 | emulate sh |
| 17589 | NULLCMD=: |
| 17590 | elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then |
| 17591 | set -o posix |
| 17592 | fi |
| 17593 | |
| 17594 | # Name of the executable. |
| 17595 | as_me=`echo "$0" |sed 's,.*[\\/],,'` |
| 17596 | |
| 17597 | if expr a : '\(a\)' >/dev/null 2>&1; then |
| 17598 | as_expr=expr |
| 17599 | else |
| 17600 | as_expr=false |
| 17601 | fi |
| 17602 | |
| 17603 | rm -f conf$$ conf$$.exe conf$$.file |
| 17604 | echo >conf$$.file |
| 17605 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 17606 | # We could just check for DJGPP; but this test a) works b) is more generic |
| 17607 | # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). |
| 17608 | if test -f conf$$.exe; then |
| 17609 | # Don't use ln at all; we don't have any links |
| 17610 | as_ln_s='cp -p' |
| 17611 | else |
| 17612 | as_ln_s='ln -s' |
| 17613 | fi |
| 17614 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 17615 | as_ln_s=ln |
| 17616 | else |
| 17617 | as_ln_s='cp -p' |
| 17618 | fi |
| 17619 | rm -f conf$$ conf$$.exe conf$$.file |
| 17620 | |
| 17621 | as_executable_p="test -f" |
| 17622 | |
| 17623 | # Support unset when possible. |
| 17624 | if (FOO=FOO; unset FOO) >/dev/null 2>&1; then |
| 17625 | as_unset=unset |
| 17626 | else |
| 17627 | as_unset=false |
| 17628 | fi |
| 17629 | |
| 17630 | # NLS nuisances. |
| 17631 | $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; } |
| 17632 | $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; } |
| 17633 | $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; } |
| 17634 | $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; } |
| 17635 | $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; } |
| 17636 | $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; } |
| 17637 | $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; } |
| 17638 | $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; } |
| 17639 | |
| 17640 | # IFS |
| 17641 | # We need space, tab and new line, in precisely that order. |
| 17642 | as_nl=' |
| 17643 | ' |
| 17644 | IFS=" $as_nl" |
| 17645 | |
| 17646 | # CDPATH. |
| 17647 | $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; } |
| 17648 | |
| 17649 | exec 6>&1 |
| 17650 | |
| 17651 | _ACEOF |
| 17652 | |
| 17653 | # Files that config.status was made for. |
| 17654 | if test -n "$ac_config_files"; then |
| 17655 | echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS |
| 17656 | fi |
| 17657 | |
| 17658 | if test -n "$ac_config_headers"; then |
| 17659 | echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS |
| 17660 | fi |
| 17661 | |
| 17662 | if test -n "$ac_config_links"; then |
| 17663 | echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS |
| 17664 | fi |
| 17665 | |
| 17666 | if test -n "$ac_config_commands"; then |
| 17667 | echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS |
| 17668 | fi |
| 17669 | |
| 17670 | cat >>$CONFIG_STATUS <<\EOF |
| 17671 | |
| 17672 | ac_cs_usage="\ |
| 17673 | \`$as_me' instantiates files from templates according to the |
| 17674 | current configuration. |
| 17675 | |
| 17676 | Usage: $0 [OPTIONS] [FILE]... |
| 17677 | |
| 17678 | -h, --help print this help, then exit |
| 17679 | -V, --version print version number, then exit |
| 17680 | -d, --debug don't remove temporary files |
| 17681 | --recheck update $as_me by reconfiguring in the same conditions |
| 17682 | --file=FILE[:TEMPLATE] |
| 17683 | instantiate the configuration file FILE |
| 17684 | --header=FILE[:TEMPLATE] |
| 17685 | instantiate the configuration header FILE |
| 17686 | |
| 17687 | Configuration files: |
| 17688 | $config_files |
| 17689 | |
| 17690 | Configuration headers: |
| 17691 | $config_headers |
| 17692 | |
| 17693 | Configuration commands: |
| 17694 | $config_commands |
| 17695 | |
| 17696 | Report bugs to <dickey@invisible-island.net>." |
| 17697 | EOF |
| 17698 | |
| 17699 | cat >>$CONFIG_STATUS <<EOF |
| 17700 | ac_cs_version="\\ |
| 17701 | config.status |
| 17702 | configured by $0, generated by GNU Autoconf 2.52.20141204, |
| 17703 | with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\" |
| 17704 | |
| 17705 | Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001 |
| 17706 | Free Software Foundation, Inc. |
| 17707 | This config.status script is free software; the Free Software Foundation |
| 17708 | gives unlimited permission to copy, distribute and modify it." |
| 17709 | srcdir=$srcdir |
| 17710 | INSTALL="$INSTALL" |
| 17711 | EOF |
| 17712 | |
| 17713 | cat >>$CONFIG_STATUS <<\EOF |
| 17714 | # If no file are specified by the user, then we need to provide default |
| 17715 | # value. By we need to know if files were specified by the user. |
| 17716 | ac_need_defaults=: |
| 17717 | while test $# != 0 |
| 17718 | do |
| 17719 | case $1 in |
| 17720 | --*=*) |
| 17721 | ac_option=`expr "x$1" : 'x\([^=]*\)='` |
| 17722 | ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'` |
| 17723 | shift |
| 17724 | set dummy "$ac_option" "$ac_optarg" ${1+"$@"} |
| 17725 | shift |
| 17726 | ;; |
| 17727 | -*);; |
| 17728 | *) # This is not an option, so the user has probably given explicit |
| 17729 | # arguments. |
| 17730 | ac_need_defaults=false;; |
| 17731 | esac |
| 17732 | |
| 17733 | case $1 in |
| 17734 | # Handling of the options. |
| 17735 | EOF |
| 17736 | cat >>$CONFIG_STATUS <<EOF |
| 17737 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 17738 | echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion" |
| 17739 | exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;; |
| 17740 | EOF |
| 17741 | cat >>$CONFIG_STATUS <<\EOF |
| 17742 | --version | --vers* | -V ) |
| 17743 | echo "$ac_cs_version"; exit 0 ;; |
| 17744 | --he | --h) |
| 17745 | # Conflict between --help and --header |
| 17746 | { { echo "$as_me:17746: error: ambiguous option: $1 |
| 17747 | Try \`$0 --help' for more information." >&5 |
| 17748 | echo "$as_me: error: ambiguous option: $1 |
| 17749 | Try \`$0 --help' for more information." >&2;} |
| 17750 | { (exit 1); exit 1; }; };; |
| 17751 | --help | --hel | -h ) |
| 17752 | echo "$ac_cs_usage"; exit 0 ;; |
| 17753 | --debug | --d* | -d ) |
| 17754 | debug=: ;; |
| 17755 | --file | --fil | --fi | --f ) |
| 17756 | shift |
| 17757 | CONFIG_FILES="$CONFIG_FILES $1" |
| 17758 | ac_need_defaults=false;; |
| 17759 | --header | --heade | --head | --hea ) |
| 17760 | shift |
| 17761 | CONFIG_HEADERS="$CONFIG_HEADERS $1" |
| 17762 | ac_need_defaults=false;; |
| 17763 | |
| 17764 | # This is an error. |
| 17765 | -*) { { echo "$as_me:17765: error: unrecognized option: $1 |
| 17766 | Try \`$0 --help' for more information." >&5 |
| 17767 | echo "$as_me: error: unrecognized option: $1 |
| 17768 | Try \`$0 --help' for more information." >&2;} |
| 17769 | { (exit 1); exit 1; }; } ;; |
| 17770 | |
| 17771 | *) ac_config_targets="$ac_config_targets $1" ;; |
| 17772 | |
| 17773 | esac |
| 17774 | shift |
| 17775 | done |
| 17776 | |
| 17777 | exec 5>>config.log |
| 17778 | cat >&5 << _ACEOF |
| 17779 | |
| 17780 | ## ----------------------- ## |
| 17781 | ## Running config.status. ## |
| 17782 | ## ----------------------- ## |
| 17783 | |
| 17784 | This file was extended by $as_me 2.52.20141204, executed with |
| 17785 | CONFIG_FILES = $CONFIG_FILES |
| 17786 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 17787 | CONFIG_LINKS = $CONFIG_LINKS |
| 17788 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 17789 | > $ac_cs_invocation |
| 17790 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 17791 | |
| 17792 | _ACEOF |
| 17793 | EOF |
| 17794 | |
| 17795 | cat >>$CONFIG_STATUS <<EOF |
| 17796 | # |
| 17797 | # INIT-COMMANDS section. |
| 17798 | # |
| 17799 | |
| 17800 | AWK="$AWK" |
| 17801 | ECHO_CC="$ECHO_CC" |
| 17802 | ECHO_LD="$ECHO_LD" |
| 17803 | SHOW_CC="$SHOW_LD" |
| 17804 | |
| 17805 | EOF |
| 17806 | |
| 17807 | cat >>$CONFIG_STATUS <<\EOF |
| 17808 | for ac_config_target in $ac_config_targets |
| 17809 | do |
| 17810 | case "$ac_config_target" in |
| 17811 | # Handling of arguments. |
| 17812 | "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;; |
| 17813 | "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; |
| 17814 | "ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS ncurses_cfg.h:ncurses_tst.hin" ;; |
| 17815 | *) { { echo "$as_me:17815: error: invalid argument: $ac_config_target" >&5 |
| 17816 | echo "$as_me: error: invalid argument: $ac_config_target" >&2;} |
| 17817 | { (exit 1); exit 1; }; };; |
| 17818 | esac |
| 17819 | done |
| 17820 | |
| 17821 | # If the user did not use the arguments to specify the items to instantiate, |
| 17822 | # then the envvar interface is used. Set only those that are not. |
| 17823 | # We use the long form for the default assignment because of an extremely |
| 17824 | # bizarre bug on SunOS 4.1.3. |
| 17825 | if $ac_need_defaults; then |
| 17826 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 17827 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 17828 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands |
| 17829 | fi |
| 17830 | |
| 17831 | # Create a temporary directory, and hook for its removal unless debugging. |
| 17832 | $debug || |
| 17833 | { |
| 17834 | trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0 |
| 17835 | trap '{ (exit 1); exit 1; }' 1 2 13 15 |
| 17836 | } |
| 17837 | |
| 17838 | # Create a (secure) tmp directory for tmp files. |
| 17839 | : ${TMPDIR=/tmp} |
| 17840 | { |
| 17841 | tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` && |
| 17842 | test -n "$tmp" && test -d "$tmp" |
| 17843 | } || |
| 17844 | { |
| 17845 | tmp=$TMPDIR/cs$$-$RANDOM |
| 17846 | (umask 077 && mkdir $tmp) |
| 17847 | } || |
| 17848 | { |
| 17849 | echo "$me: cannot create a temporary directory in $TMPDIR" >&2 |
| 17850 | { (exit 1); exit 1; } |
| 17851 | } |
| 17852 | |
| 17853 | EOF |
| 17854 | |
| 17855 | cat >>$CONFIG_STATUS <<EOF |
| 17856 | |
| 17857 | # |
| 17858 | # CONFIG_FILES section. |
| 17859 | # |
| 17860 | |
| 17861 | # No need to generate the scripts if there are no CONFIG_FILES. |
| 17862 | # This happens for instance when ./config.status config.h |
| 17863 | if test -n "\$CONFIG_FILES"; then |
| 17864 | # Protect against being on the right side of a sed subst in config.status. |
| 17865 | sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g; |
| 17866 | s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF |
| 17867 | s,@SHELL@,$SHELL,;t t |
| 17868 | s,@exec_prefix@,$exec_prefix,;t t |
| 17869 | s,@prefix@,$prefix,;t t |
| 17870 | s,@program_transform_name@,$program_transform_name,;t t |
| 17871 | s,@bindir@,$bindir,;t t |
| 17872 | s,@sbindir@,$sbindir,;t t |
| 17873 | s,@libexecdir@,$libexecdir,;t t |
| 17874 | s,@datarootdir@,$datarootdir,;t t |
| 17875 | s,@datadir@,$datadir,;t t |
| 17876 | s,@sysconfdir@,$sysconfdir,;t t |
| 17877 | s,@sharedstatedir@,$sharedstatedir,;t t |
| 17878 | s,@localstatedir@,$localstatedir,;t t |
| 17879 | s,@libdir@,$libdir,;t t |
| 17880 | s,@includedir@,$includedir,;t t |
| 17881 | s,@oldincludedir@,$oldincludedir,;t t |
| 17882 | s,@infodir@,$infodir,;t t |
| 17883 | s,@mandir@,$mandir,;t t |
| 17884 | s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t |
| 17885 | s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t |
| 17886 | s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t |
| 17887 | s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t |
| 17888 | s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t |
| 17889 | s,@build_alias@,$build_alias,;t t |
| 17890 | s,@host_alias@,$host_alias,;t t |
| 17891 | s,@target_alias@,$target_alias,;t t |
| 17892 | s,@ECHO_C@,$ECHO_C,;t t |
| 17893 | s,@ECHO_N@,$ECHO_N,;t t |
| 17894 | s,@ECHO_T@,$ECHO_T,;t t |
| 17895 | s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t |
| 17896 | s,@DEFS@,$DEFS,;t t |
| 17897 | s,@LIBS@,$LIBS,;t t |
| 17898 | s,@build@,$build,;t t |
| 17899 | s,@build_cpu@,$build_cpu,;t t |
| 17900 | s,@build_vendor@,$build_vendor,;t t |
| 17901 | s,@build_os@,$build_os,;t t |
| 17902 | s,@host@,$host,;t t |
| 17903 | s,@host_cpu@,$host_cpu,;t t |
| 17904 | s,@host_vendor@,$host_vendor,;t t |
| 17905 | s,@host_os@,$host_os,;t t |
| 17906 | s,@SET_MAKE@,$SET_MAKE,;t t |
| 17907 | s,@CC@,$CC,;t t |
| 17908 | s,@CFLAGS@,$CFLAGS,;t t |
| 17909 | s,@LDFLAGS@,$LDFLAGS,;t t |
| 17910 | s,@CPPFLAGS@,$CPPFLAGS,;t t |
| 17911 | s,@ac_ct_CC@,$ac_ct_CC,;t t |
| 17912 | s,@EXEEXT@,$EXEEXT,;t t |
| 17913 | s,@OBJEXT@,$OBJEXT,;t t |
| 17914 | s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t |
| 17915 | s,@CPP@,$CPP,;t t |
| 17916 | s,@AWK@,$AWK,;t t |
| 17917 | s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t |
| 17918 | s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t |
| 17919 | s,@INSTALL_DATA@,$INSTALL_DATA,;t t |
| 17920 | s,@LINT@,$LINT,;t t |
| 17921 | s,@LINT_OPTS@,$LINT_OPTS,;t t |
| 17922 | s,@CTAGS@,$CTAGS,;t t |
| 17923 | s,@ETAGS@,$ETAGS,;t t |
| 17924 | s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t |
| 17925 | s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t |
| 17926 | s,@MATH_LIB@,$MATH_LIB,;t t |
| 17927 | s,@top_builddir@,$top_builddir,;t t |
| 17928 | s,@CC_G_OPT@,$CC_G_OPT,;t t |
| 17929 | s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t |
| 17930 | s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t |
| 17931 | s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t |
| 17932 | s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t |
| 17933 | s,@LD@,$LD,;t t |
| 17934 | s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t |
| 17935 | s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t |
| 17936 | s,@LD_MODEL@,$LD_MODEL,;t t |
| 17937 | s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t |
| 17938 | s,@LIBTOOL@,$LIBTOOL,;t t |
| 17939 | s,@LIBTOOL_OPTS@,$LIBTOOL_OPTS,;t t |
| 17940 | s,@LIB_CLEAN@,$LIB_CLEAN,;t t |
| 17941 | s,@LIB_COMPILE@,$LIB_COMPILE,;t t |
| 17942 | s,@LIB_LINK@,$LIB_LINK,;t t |
| 17943 | s,@LINK_TESTS@,$LINK_TESTS,;t t |
| 17944 | s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t |
| 17945 | s,@PACKAGE@,$PACKAGE,;t t |
| 17946 | s,@PTHREAD@,$PTHREAD,;t t |
| 17947 | s,@TEST_ARGS@,$TEST_ARGS,;t t |
| 17948 | s,@TEST_DEPS@,$TEST_DEPS,;t t |
| 17949 | s,@TEST_LIBS@,$TEST_LIBS,;t t |
| 17950 | s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t |
| 17951 | s,@TINFO_LIBS@,$TINFO_LIBS,;t t |
| 17952 | s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t |
| 17953 | s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t |
| 17954 | s,@includesubdir@,$includesubdir,;t t |
| 17955 | s,@PKG_CONFIG@,$PKG_CONFIG,;t t |
| 17956 | s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t |
| 17957 | s,@ECHO_LT@,$ECHO_LT,;t t |
| 17958 | s,@ECHO_LD@,$ECHO_LD,;t t |
| 17959 | s,@RULE_CC@,$RULE_CC,;t t |
| 17960 | s,@SHOW_CC@,$SHOW_CC,;t t |
| 17961 | s,@ECHO_CC@,$ECHO_CC,;t t |
| 17962 | s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t |
| 17963 | s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t |
| 17964 | s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t |
| 17965 | s,@X_CFLAGS@,$X_CFLAGS,;t t |
| 17966 | s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t |
| 17967 | s,@X_LIBS@,$X_LIBS,;t t |
| 17968 | s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t |
| 17969 | s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t |
| 17970 | s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t |
| 17971 | s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t |
| 17972 | s,@cf_ldd_prog@,$cf_ldd_prog,;t t |
| 17973 | s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t |
| 17974 | CEOF |
| 17975 | |
| 17976 | EOF |
| 17977 | |
| 17978 | cat >>$CONFIG_STATUS <<\EOF |
| 17979 | # Split the substitutions into bite-sized pieces for seds with |
| 17980 | # small command number limits, like on Digital OSF/1 and HP-UX. |
| 17981 | ac_max_sed_lines=48 |
| 17982 | ac_sed_frag=1 # Number of current file. |
| 17983 | ac_beg=1 # First line for current file. |
| 17984 | ac_end=$ac_max_sed_lines # Line after last line for current file. |
| 17985 | ac_more_lines=: |
| 17986 | ac_sed_cmds= |
| 17987 | while $ac_more_lines; do |
| 17988 | if test $ac_beg -gt 1; then |
| 17989 | sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag |
| 17990 | else |
| 17991 | sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag |
| 17992 | fi |
| 17993 | if test ! -s $tmp/subs.frag; then |
| 17994 | ac_more_lines=false |
| 17995 | else |
| 17996 | # The purpose of the label and of the branching condition is to |
| 17997 | # speed up the sed processing (if there are no `@' at all, there |
| 17998 | # is no need to browse any of the substitutions). |
| 17999 | # These are the two extra sed commands mentioned above. |
| 18000 | (echo ':t |
| 18001 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed |
| 18002 | if test -z "$ac_sed_cmds"; then |
| 18003 | ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed" |
| 18004 | else |
| 18005 | ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed" |
| 18006 | fi |
| 18007 | ac_sed_frag=`expr $ac_sed_frag + 1` |
| 18008 | ac_beg=$ac_end |
| 18009 | ac_end=`expr $ac_end + $ac_max_sed_lines` |
| 18010 | fi |
| 18011 | done |
| 18012 | if test -z "$ac_sed_cmds"; then |
| 18013 | ac_sed_cmds=cat |
| 18014 | fi |
| 18015 | fi # test -n "$CONFIG_FILES" |
| 18016 | |
| 18017 | EOF |
| 18018 | cat >>$CONFIG_STATUS <<\EOF |
| 18019 | for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue |
| 18020 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
| 18021 | case $ac_file in |
| 18022 | - | *:- | *:-:* ) # input from stdin |
| 18023 | cat >$tmp/stdin |
| 18024 | ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 18025 | ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; |
| 18026 | *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 18027 | ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; |
| 18028 | * ) ac_file_in=$ac_file.in ;; |
| 18029 | esac |
| 18030 | |
| 18031 | # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories. |
| 18032 | ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 18033 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 18034 | X"$ac_file" : 'X\(//\)$' \| \ |
| 18035 | X"$ac_file" : 'X\(/\)' \| \ |
| 18036 | . : '\(.\)' 2>/dev/null || |
| 18037 | echo X"$ac_file" | |
| 18038 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } |
| 18039 | /^X\(\/\/\)[^/].*/{ s//\1/; q; } |
| 18040 | /^X\(\/\/\)$/{ s//\1/; q; } |
| 18041 | /^X\(\/\).*/{ s//\1/; q; } |
| 18042 | s/.*/./; q'` |
| 18043 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 18044 | { case "$ac_dir" in |
| 18045 | [\\/]* | ?:[\\/]* ) as_incr_dir=;; |
| 18046 | *) as_incr_dir=.;; |
| 18047 | esac |
| 18048 | as_dummy="$ac_dir" |
| 18049 | for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do |
| 18050 | case $as_mkdir_dir in |
| 18051 | # Skip DOS drivespec |
| 18052 | ?:) as_incr_dir=$as_mkdir_dir ;; |
| 18053 | *) |
| 18054 | as_incr_dir=$as_incr_dir/$as_mkdir_dir |
| 18055 | test -d "$as_incr_dir" || mkdir "$as_incr_dir" |
| 18056 | ;; |
| 18057 | esac |
| 18058 | done; } |
| 18059 | |
| 18060 | ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`" |
| 18061 | # A "../" for each directory in $ac_dir_suffix. |
| 18062 | ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'` |
| 18063 | else |
| 18064 | ac_dir_suffix= ac_dots= |
| 18065 | fi |
| 18066 | |
| 18067 | case $srcdir in |
| 18068 | .) ac_srcdir=. |
| 18069 | if test -z "$ac_dots"; then |
| 18070 | ac_top_srcdir=. |
| 18071 | else |
| 18072 | ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'` |
| 18073 | fi ;; |
| 18074 | [\\/]* | ?:[\\/]* ) |
| 18075 | ac_srcdir=$srcdir$ac_dir_suffix; |
| 18076 | ac_top_srcdir=$srcdir ;; |
| 18077 | *) # Relative path. |
| 18078 | ac_srcdir=$ac_dots$srcdir$ac_dir_suffix |
| 18079 | ac_top_srcdir=$ac_dots$srcdir ;; |
| 18080 | esac |
| 18081 | |
| 18082 | case $INSTALL in |
| 18083 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
| 18084 | *) ac_INSTALL=$ac_dots$INSTALL ;; |
| 18085 | esac |
| 18086 | |
| 18087 | if test x"$ac_file" != x-; then |
| 18088 | { echo "$as_me:18088: creating $ac_file" >&5 |
| 18089 | echo "$as_me: creating $ac_file" >&6;} |
| 18090 | rm -f "$ac_file" |
| 18091 | fi |
| 18092 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 18093 | # use $as_me), people would be surprised to read: |
| 18094 | # /* config.h. Generated automatically by config.status. */ |
| 18095 | configure_input="Generated automatically from `echo $ac_file_in | |
| 18096 | sed 's,.*/,,'` by configure." |
| 18097 | |
| 18098 | # First look for the input files in the build tree, otherwise in the |
| 18099 | # src tree. |
| 18100 | ac_file_inputs=`IFS=: |
| 18101 | for f in $ac_file_in; do |
| 18102 | case $f in |
| 18103 | -) echo $tmp/stdin ;; |
| 18104 | [\\/$]*) |
| 18105 | # Absolute (can't be DOS-style, as IFS=:) |
| 18106 | test -f "$f" || { { echo "$as_me:18106: error: cannot find input file: $f" >&5 |
| 18107 | echo "$as_me: error: cannot find input file: $f" >&2;} |
| 18108 | { (exit 1); exit 1; }; } |
| 18109 | echo $f;; |
| 18110 | *) # Relative |
| 18111 | if test -f "$f"; then |
| 18112 | # Build tree |
| 18113 | echo $f |
| 18114 | elif test -f "$srcdir/$f"; then |
| 18115 | # Source tree |
| 18116 | echo $srcdir/$f |
| 18117 | else |
| 18118 | # /dev/null tree |
| 18119 | { { echo "$as_me:18119: error: cannot find input file: $f" >&5 |
| 18120 | echo "$as_me: error: cannot find input file: $f" >&2;} |
| 18121 | { (exit 1); exit 1; }; } |
| 18122 | fi;; |
| 18123 | esac |
| 18124 | done` || { (exit 1); exit 1; } |
| 18125 | EOF |
| 18126 | cat >>$CONFIG_STATUS <<\EOF |
| 18127 | ac_warn_datarootdir=no |
| 18128 | if test x"$ac_file" != x-; then |
| 18129 | for ac_item in $ac_file_inputs |
| 18130 | do |
| 18131 | ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item` |
| 18132 | if test -n "$ac_seen"; then |
| 18133 | ac_used=`grep '@datarootdir@' $ac_item` |
| 18134 | if test -z "$ac_used"; then |
| 18135 | { echo "$as_me:18135: WARNING: datarootdir was used implicitly but not set: |
| 18136 | $ac_seen" >&5 |
| 18137 | echo "$as_me: WARNING: datarootdir was used implicitly but not set: |
| 18138 | $ac_seen" >&2;} |
| 18139 | ac_warn_datarootdir=yes |
| 18140 | fi |
| 18141 | fi |
| 18142 | ac_seen=`grep '${datarootdir}' $ac_item` |
| 18143 | if test -n "$ac_seen"; then |
| 18144 | { echo "$as_me:18144: WARNING: datarootdir was used explicitly but not set: |
| 18145 | $ac_seen" >&5 |
| 18146 | echo "$as_me: WARNING: datarootdir was used explicitly but not set: |
| 18147 | $ac_seen" >&2;} |
| 18148 | ac_warn_datarootdir=yes |
| 18149 | fi |
| 18150 | done |
| 18151 | fi |
| 18152 | |
| 18153 | if test "x$ac_warn_datarootdir" = xyes; then |
| 18154 | ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'" |
| 18155 | fi |
| 18156 | |
| 18157 | EOF |
| 18158 | cat >>$CONFIG_STATUS <<EOF |
| 18159 | sed "$ac_vpsub |
| 18160 | $extrasub |
| 18161 | EOF |
| 18162 | cat >>$CONFIG_STATUS <<\EOF |
| 18163 | :t |
| 18164 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
| 18165 | s,@configure_input@,$configure_input,;t t |
| 18166 | s,@srcdir@,$ac_srcdir,;t t |
| 18167 | s,@top_srcdir@,$ac_top_srcdir,;t t |
| 18168 | s,@INSTALL@,$ac_INSTALL,;t t |
| 18169 | " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out |
| 18170 | rm -f $tmp/stdin |
| 18171 | if test x"$ac_file" != x-; then |
| 18172 | cp $tmp/out $ac_file |
| 18173 | |
| 18174 | for ac_name in prefix exec_prefix datarootdir |
| 18175 | do |
| 18176 | ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file` |
| 18177 | if test -n "$ac_seen"; then |
| 18178 | ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file` |
| 18179 | if test -z "$ac_init"; then |
| 18180 | ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'` |
| 18181 | { echo "$as_me:18181: WARNING: Variable $ac_name is used but was not set: |
| 18182 | $ac_seen" >&5 |
| 18183 | echo "$as_me: WARNING: Variable $ac_name is used but was not set: |
| 18184 | $ac_seen" >&2;} |
| 18185 | fi |
| 18186 | fi |
| 18187 | done |
| 18188 | egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out |
| 18189 | egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out |
| 18190 | if test -s $tmp/out; then |
| 18191 | ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out` |
| 18192 | { echo "$as_me:18192: WARNING: Some variables may not be substituted: |
| 18193 | $ac_seen" >&5 |
| 18194 | echo "$as_me: WARNING: Some variables may not be substituted: |
| 18195 | $ac_seen" >&2;} |
| 18196 | fi |
| 18197 | else |
| 18198 | cat $tmp/out |
| 18199 | fi |
| 18200 | rm -f $tmp/out |
| 18201 | |
| 18202 | done |
| 18203 | EOF |
| 18204 | cat >>$CONFIG_STATUS <<\EOF |
| 18205 | |
| 18206 | # |
| 18207 | # CONFIG_HEADER section. |
| 18208 | # |
| 18209 | |
| 18210 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 18211 | # NAME is the cpp macro being defined and VALUE is the value it is being given. |
| 18212 | # |
| 18213 | # ac_d sets the value in "#define NAME VALUE" lines. |
| 18214 | ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 18215 | ac_dB='[ ].*$,\1#\2' |
| 18216 | ac_dC=' ' |
| 18217 | ac_dD=',;t' |
| 18218 | # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE". |
| 18219 | ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 18220 | ac_iB='\([ ]\),\1#\2define\3' |
| 18221 | ac_iC=' ' |
| 18222 | ac_iD='\4,;t' |
| 18223 | # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE". |
| 18224 | ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 18225 | ac_uB='$,\1#\2define\3' |
| 18226 | ac_uC=' ' |
| 18227 | ac_uD=',;t' |
| 18228 | |
| 18229 | for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue |
| 18230 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
| 18231 | case $ac_file in |
| 18232 | - | *:- | *:-:* ) # input from stdin |
| 18233 | cat >$tmp/stdin |
| 18234 | ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 18235 | ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; |
| 18236 | *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 18237 | ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; |
| 18238 | * ) ac_file_in=$ac_file.in ;; |
| 18239 | esac |
| 18240 | |
| 18241 | test x"$ac_file" != x- && { echo "$as_me:18241: creating $ac_file" >&5 |
| 18242 | echo "$as_me: creating $ac_file" >&6;} |
| 18243 | |
| 18244 | # First look for the input files in the build tree, otherwise in the |
| 18245 | # src tree. |
| 18246 | ac_file_inputs=`IFS=: |
| 18247 | for f in $ac_file_in; do |
| 18248 | case $f in |
| 18249 | -) echo $tmp/stdin ;; |
| 18250 | [\\/$]*) |
| 18251 | # Absolute (can't be DOS-style, as IFS=:) |
| 18252 | test -f "$f" || { { echo "$as_me:18252: error: cannot find input file: $f" >&5 |
| 18253 | echo "$as_me: error: cannot find input file: $f" >&2;} |
| 18254 | { (exit 1); exit 1; }; } |
| 18255 | echo $f;; |
| 18256 | *) # Relative |
| 18257 | if test -f "$f"; then |
| 18258 | # Build tree |
| 18259 | echo $f |
| 18260 | elif test -f "$srcdir/$f"; then |
| 18261 | # Source tree |
| 18262 | echo $srcdir/$f |
| 18263 | else |
| 18264 | # /dev/null tree |
| 18265 | { { echo "$as_me:18265: error: cannot find input file: $f" >&5 |
| 18266 | echo "$as_me: error: cannot find input file: $f" >&2;} |
| 18267 | { (exit 1); exit 1; }; } |
| 18268 | fi;; |
| 18269 | esac |
| 18270 | done` || { (exit 1); exit 1; } |
| 18271 | # Remove the trailing spaces. |
| 18272 | sed 's/[ ]*$//' $ac_file_inputs >$tmp/in |
| 18273 | |
| 18274 | EOF |
| 18275 | |
| 18276 | # Transform confdefs.h into a list of #define's. We won't use it as a sed |
| 18277 | # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to |
| 18278 | # be either 'cat' or 'sort'. |
| 18279 | cat confdefs.h | uniq >conftest.vals |
| 18280 | |
| 18281 | # Break up conftest.vals because some shells have a limit on |
| 18282 | # the size of here documents, and old seds have small limits too. |
| 18283 | |
| 18284 | rm -f conftest.tail |
| 18285 | echo ' rm -f conftest.frag' >> $CONFIG_STATUS |
| 18286 | while grep . conftest.vals >/dev/null |
| 18287 | do |
| 18288 | # Write chunks of a limited-size here document to conftest.frag. |
| 18289 | echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 18290 | sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS |
| 18291 | echo 'CEOF' >> $CONFIG_STATUS |
| 18292 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 18293 | rm -f conftest.vals |
| 18294 | mv conftest.tail conftest.vals |
| 18295 | done |
| 18296 | rm -f conftest.vals |
| 18297 | |
| 18298 | # Run sed to substitute the contents of conftest.frag into $tmp/in at the |
| 18299 | # marker @DEFS@. |
| 18300 | echo ' cat >> conftest.edit <<CEOF |
| 18301 | /@DEFS@/r conftest.frag |
| 18302 | /@DEFS@/d |
| 18303 | CEOF |
| 18304 | sed -f conftest.edit $tmp/in > $tmp/out |
| 18305 | rm -f $tmp/in |
| 18306 | mv $tmp/out $tmp/in |
| 18307 | rm -f conftest.edit conftest.frag |
| 18308 | ' >> $CONFIG_STATUS |
| 18309 | |
| 18310 | cat >>$CONFIG_STATUS <<\EOF |
| 18311 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 18312 | # use $as_me), people would be surprised to read: |
| 18313 | # /* config.h. Generated automatically by config.status. */ |
| 18314 | if test x"$ac_file" = x-; then |
| 18315 | echo "/* Generated automatically by configure. */" >$tmp/config.h |
| 18316 | else |
| 18317 | echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h |
| 18318 | fi |
| 18319 | cat $tmp/in >>$tmp/config.h |
| 18320 | rm -f $tmp/in |
| 18321 | if test x"$ac_file" != x-; then |
| 18322 | if cmp -s $ac_file $tmp/config.h 2>/dev/null; then |
| 18323 | { echo "$as_me:18323: $ac_file is unchanged" >&5 |
| 18324 | echo "$as_me: $ac_file is unchanged" >&6;} |
| 18325 | else |
| 18326 | ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 18327 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 18328 | X"$ac_file" : 'X\(//\)$' \| \ |
| 18329 | X"$ac_file" : 'X\(/\)' \| \ |
| 18330 | . : '\(.\)' 2>/dev/null || |
| 18331 | echo X"$ac_file" | |
| 18332 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } |
| 18333 | /^X\(\/\/\)[^/].*/{ s//\1/; q; } |
| 18334 | /^X\(\/\/\)$/{ s//\1/; q; } |
| 18335 | /^X\(\/\).*/{ s//\1/; q; } |
| 18336 | s/.*/./; q'` |
| 18337 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 18338 | { case "$ac_dir" in |
| 18339 | [\\/]* | ?:[\\/]* ) as_incr_dir=;; |
| 18340 | *) as_incr_dir=.;; |
| 18341 | esac |
| 18342 | as_dummy="$ac_dir" |
| 18343 | for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do |
| 18344 | case $as_mkdir_dir in |
| 18345 | # Skip DOS drivespec |
| 18346 | ?:) as_incr_dir=$as_mkdir_dir ;; |
| 18347 | *) |
| 18348 | as_incr_dir=$as_incr_dir/$as_mkdir_dir |
| 18349 | test -d "$as_incr_dir" || mkdir "$as_incr_dir" |
| 18350 | ;; |
| 18351 | esac |
| 18352 | done; } |
| 18353 | |
| 18354 | fi |
| 18355 | rm -f $ac_file |
| 18356 | mv $tmp/config.h $ac_file |
| 18357 | fi |
| 18358 | else |
| 18359 | cat $tmp/config.h |
| 18360 | rm -f $tmp/config.h |
| 18361 | fi |
| 18362 | done |
| 18363 | EOF |
| 18364 | cat >>$CONFIG_STATUS <<\EOF |
| 18365 | # |
| 18366 | # CONFIG_COMMANDS section. |
| 18367 | # |
| 18368 | for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue |
| 18369 | ac_dest=`echo "$ac_file" | sed 's,:.*,,'` |
| 18370 | ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 18371 | |
| 18372 | case $ac_dest in |
| 18373 | default ) |
| 18374 | |
| 18375 | for cf_dir in . |
| 18376 | do |
| 18377 | if test ! -d $srcdir/$cf_dir; then |
| 18378 | continue |
| 18379 | elif test -f $srcdir/$cf_dir/programs; then |
| 18380 | $AWK -f $srcdir/mk-test.awk INSTALL=yes ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile |
| 18381 | fi |
| 18382 | done |
| 18383 | |
| 18384 | cat >>Makefile <<TEST_EOF |
| 18385 | |
| 18386 | # These rules are generated so we do not rely on suffix rules, which do not |
| 18387 | # work consistently for different make-programs (the '\$(MODEL)/' confuses |
| 18388 | # some, and the '\$x' confuses others). |
| 18389 | TEST_EOF |
| 18390 | |
| 18391 | LIST=`sed -e 's/[ ].*//' -e '/^[#@]/d' $srcdir/modules` |
| 18392 | for N in $LIST |
| 18393 | do |
| 18394 | cat >>Makefile <<TEST_EOF |
| 18395 | |
| 18396 | \$(MODEL)/$N.o : \$(srcdir)/$N.c \\ |
| 18397 | \$(srcdir)/test.priv.h \\ |
| 18398 | ncurses_cfg.h |
| 18399 | $SHOW_CC |
| 18400 | $ECHO_CC\$(CC) -c \$(CFLAGS_DEFAULT) \$(srcdir)/$N.c |
| 18401 | TEST_EOF |
| 18402 | done |
| 18403 | |
| 18404 | if test -f ../config.guess && test -f ../config.sub |
| 18405 | then |
| 18406 | cat >>Makefile <<TEST_EOF |
| 18407 | |
| 18408 | # if we used CF_INHERIT for getting these files, we can remove them |
| 18409 | distclean:: |
| 18410 | rm -f config.guess config.sub |
| 18411 | TEST_EOF |
| 18412 | fi |
| 18413 | ;; |
| 18414 | esac |
| 18415 | done |
| 18416 | EOF |
| 18417 | |
| 18418 | cat >>$CONFIG_STATUS <<\EOF |
| 18419 | |
| 18420 | { (exit 0); exit 0; } |
| 18421 | EOF |
| 18422 | chmod +x $CONFIG_STATUS |
| 18423 | ac_clean_files=$ac_clean_files_save |
| 18424 | |
| 18425 | # configure is writing to config.log, and then calls config.status. |
| 18426 | # config.status does its own redirection, appending to config.log. |
| 18427 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 18428 | # by configure, so config.status won't be able to write to it; its |
| 18429 | # output is simply discarded. So we exec the FD to /dev/null, |
| 18430 | # effectively closing config.log, so it can be properly (re)opened and |
| 18431 | # appended to by config.status. When coming back to configure, we |
| 18432 | # need to make the FD available again. |
| 18433 | if test "$no_create" != yes; then |
| 18434 | ac_cs_success=: |
| 18435 | exec 5>/dev/null |
| 18436 | $SHELL $CONFIG_STATUS || ac_cs_success=false |
| 18437 | exec 5>>config.log |
| 18438 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 18439 | # would make configure fail if this is the last instruction. |
| 18440 | $ac_cs_success || { (exit 1); exit 1; } |
| 18441 | fi |
| 18442 | |