Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1 | #! /bin/sh |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2 | # From configure.in Revision: 1.618 . |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 3 | # Guess values for system-dependent variables and create Makefiles. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 4 | # Generated by Autoconf 2.52.20141204. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 5 | # |
| 6 | # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001 |
| 7 | # Free Software Foundation, Inc. |
| 8 | # This configure script is free software; the Free Software Foundation |
| 9 | # gives unlimited permission to copy, distribute and modify it. |
| 10 | |
| 11 | # Avoid depending upon Character Ranges. |
| 12 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 13 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 14 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 15 | as_cr_digits='0123456789' |
| 16 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
| 17 | |
| 18 | # Sed expression to map a string onto a valid variable name. |
| 19 | as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g" |
| 20 | |
| 21 | # Sed expression to map a string onto a valid CPP name. |
| 22 | as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g" |
| 23 | |
| 24 | # Be Bourne compatible |
| 25 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then |
| 26 | emulate sh |
| 27 | NULLCMD=: |
| 28 | elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then |
| 29 | set -o posix |
| 30 | fi |
| 31 | |
| 32 | # Name of the executable. |
| 33 | as_me=`echo "$0" |sed 's,.*[\\/],,'` |
| 34 | |
| 35 | if expr a : '\(a\)' >/dev/null 2>&1; then |
| 36 | as_expr=expr |
| 37 | else |
| 38 | as_expr=false |
| 39 | fi |
| 40 | |
| 41 | rm -f conf$$ conf$$.exe conf$$.file |
| 42 | echo >conf$$.file |
| 43 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 44 | # We could just check for DJGPP; but this test a) works b) is more generic |
| 45 | # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). |
| 46 | if test -f conf$$.exe; then |
| 47 | # Don't use ln at all; we don't have any links |
| 48 | as_ln_s='cp -p' |
| 49 | else |
| 50 | as_ln_s='ln -s' |
| 51 | fi |
| 52 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 53 | as_ln_s=ln |
| 54 | else |
| 55 | as_ln_s='cp -p' |
| 56 | fi |
| 57 | rm -f conf$$ conf$$.exe conf$$.file |
| 58 | |
| 59 | as_executable_p="test -f" |
| 60 | |
| 61 | # Support unset when possible. |
| 62 | if (FOO=FOO; unset FOO) >/dev/null 2>&1; then |
| 63 | as_unset=unset |
| 64 | else |
| 65 | as_unset=false |
| 66 | fi |
| 67 | |
| 68 | # NLS nuisances. |
| 69 | $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; } |
| 70 | $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; } |
| 71 | $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; } |
| 72 | $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; } |
| 73 | $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; } |
| 74 | $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; } |
| 75 | $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; } |
| 76 | $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; } |
| 77 | |
| 78 | # IFS |
| 79 | # We need space, tab and new line, in precisely that order. |
| 80 | as_nl=' |
| 81 | ' |
| 82 | IFS=" $as_nl" |
| 83 | |
| 84 | # CDPATH. |
| 85 | $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; } |
| 86 | |
| 87 | # Name of the host. |
| 88 | # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, |
| 89 | # so uname gets run too. |
| 90 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` |
| 91 | |
| 92 | exec 6>&1 |
| 93 | |
| 94 | # |
| 95 | # Initializations. |
| 96 | # |
| 97 | ac_default_prefix=/usr/local |
| 98 | cross_compiling=no |
| 99 | subdirs= |
| 100 | MFLAGS= MAKEFLAGS= |
| 101 | SHELL=${CONFIG_SHELL-/bin/sh} |
| 102 | |
| 103 | # Maximum number of lines to put in a shell here document. |
| 104 | # This variable seems obsolete. It should probably be removed, and |
| 105 | # only ac_max_sed_lines should be used. |
| 106 | : ${ac_max_here_lines=38} |
| 107 | |
| 108 | ac_unique_file="ncurses/base/lib_initscr.c" |
| 109 | # Factoring default headers for most tests. |
| 110 | ac_includes_default="\ |
| 111 | #include <stdio.h> |
| 112 | #if HAVE_SYS_TYPES_H |
| 113 | # include <sys/types.h> |
| 114 | #endif |
| 115 | #if HAVE_SYS_STAT_H |
| 116 | # include <sys/stat.h> |
| 117 | #endif |
| 118 | #if STDC_HEADERS |
| 119 | # include <stdlib.h> |
| 120 | # include <stddef.h> |
| 121 | #else |
| 122 | # if HAVE_STDLIB_H |
| 123 | # include <stdlib.h> |
| 124 | # endif |
| 125 | #endif |
| 126 | #if HAVE_STRING_H |
| 127 | # if !STDC_HEADERS && HAVE_MEMORY_H |
| 128 | # include <memory.h> |
| 129 | # endif |
| 130 | # include <string.h> |
| 131 | #endif |
| 132 | #if HAVE_STRINGS_H |
| 133 | # include <strings.h> |
| 134 | #endif |
| 135 | #if HAVE_INTTYPES_H |
| 136 | # include <inttypes.h> |
| 137 | #else |
| 138 | # if HAVE_STDINT_H |
| 139 | # include <stdint.h> |
| 140 | # endif |
| 141 | #endif |
| 142 | #if HAVE_UNISTD_H |
| 143 | # include <unistd.h> |
| 144 | #endif" |
| 145 | |
| 146 | # Initialize some variables set by options. |
| 147 | ac_init_help= |
| 148 | ac_init_version=false |
| 149 | # The variables have the same names as the options, with |
| 150 | # dashes changed to underlines. |
| 151 | cache_file=/dev/null |
| 152 | exec_prefix=NONE |
| 153 | no_create= |
| 154 | no_recursion= |
| 155 | prefix=NONE |
| 156 | program_prefix=NONE |
| 157 | program_suffix=NONE |
| 158 | program_transform_name=s,x,x, |
| 159 | silent= |
| 160 | site= |
| 161 | srcdir= |
| 162 | verbose= |
| 163 | x_includes=NONE |
| 164 | x_libraries=NONE |
| 165 | |
| 166 | # Installation directory options. |
| 167 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 168 | # and all the variables that are supposed to be based on exec_prefix |
| 169 | # by default will actually change. |
| 170 | # Use braces instead of parens because sh, perl, etc. also accept them. |
| 171 | bindir='${exec_prefix}/bin' |
| 172 | sbindir='${exec_prefix}/sbin' |
| 173 | libexecdir='${exec_prefix}/libexec' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 174 | datarootdir='${prefix}/share' |
| 175 | datadir='${datarootdir}' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 176 | sysconfdir='${prefix}/etc' |
| 177 | sharedstatedir='${prefix}/com' |
| 178 | localstatedir='${prefix}/var' |
| 179 | libdir='${exec_prefix}/lib' |
| 180 | includedir='${prefix}/include' |
| 181 | oldincludedir='/usr/include' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 182 | infodir='${datarootdir}/info' |
| 183 | mandir='${datarootdir}/man' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 184 | |
| 185 | # Identity of this package. |
| 186 | PACKAGE_NAME= |
| 187 | PACKAGE_TARNAME= |
| 188 | PACKAGE_VERSION= |
| 189 | PACKAGE_STRING= |
| 190 | PACKAGE_BUGREPORT= |
| 191 | |
| 192 | ac_prev= |
| 193 | for ac_option |
| 194 | do |
| 195 | # If the previous option needs an argument, assign it. |
| 196 | if test -n "$ac_prev"; then |
| 197 | eval "$ac_prev=\$ac_option" |
| 198 | ac_prev= |
| 199 | continue |
| 200 | fi |
| 201 | |
| 202 | ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'` |
| 203 | |
| 204 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 205 | |
| 206 | case $ac_option in |
| 207 | |
| 208 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 209 | ac_prev=bindir ;; |
| 210 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 211 | bindir=$ac_optarg ;; |
| 212 | |
| 213 | -build | --build | --buil | --bui | --bu) |
| 214 | ac_prev=build_alias ;; |
| 215 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
| 216 | build_alias=$ac_optarg ;; |
| 217 | |
| 218 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 219 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 220 | ac_prev=cache_file ;; |
| 221 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 222 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 223 | cache_file=$ac_optarg ;; |
| 224 | |
| 225 | --config-cache | -C) |
| 226 | cache_file=config.cache ;; |
| 227 | |
| 228 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 229 | ac_prev=datadir ;; |
| 230 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 231 | | --da=*) |
| 232 | datadir=$ac_optarg ;; |
| 233 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 234 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 235 | | --dataroo | --dataro | --datar) |
| 236 | ac_prev=datarootdir ;; |
| 237 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 238 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 239 | datarootdir=$ac_optarg ;; |
| 240 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 241 | -disable-* | --disable-*) |
| 242 | ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
| 243 | # Reject names that are not valid shell variable names. |
| 244 | expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && |
| 245 | { echo "$as_me: error: invalid feature name: $ac_feature" >&2 |
| 246 | { (exit 1); exit 1; }; } |
| 247 | ac_feature=`echo $ac_feature | sed 's/-/_/g'` |
| 248 | eval "enable_$ac_feature=no" ;; |
| 249 | |
| 250 | -enable-* | --enable-*) |
| 251 | ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
| 252 | # Reject names that are not valid shell variable names. |
| 253 | expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && |
| 254 | { echo "$as_me: error: invalid feature name: $ac_feature" >&2 |
| 255 | { (exit 1); exit 1; }; } |
| 256 | ac_feature=`echo $ac_feature | sed 's/-/_/g'` |
| 257 | case $ac_option in |
| 258 | *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; |
| 259 | *) ac_optarg=yes ;; |
| 260 | esac |
| 261 | eval "enable_$ac_feature='$ac_optarg'" ;; |
| 262 | |
| 263 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 264 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 265 | | --exec | --exe | --ex) |
| 266 | ac_prev=exec_prefix ;; |
| 267 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 268 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 269 | | --exec=* | --exe=* | --ex=*) |
| 270 | exec_prefix=$ac_optarg ;; |
| 271 | |
| 272 | -gas | --gas | --ga | --g) |
| 273 | # Obsolete; use --with-gas. |
| 274 | with_gas=yes ;; |
| 275 | |
| 276 | -help | --help | --hel | --he | -h) |
| 277 | ac_init_help=long ;; |
| 278 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 279 | ac_init_help=recursive ;; |
| 280 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 281 | ac_init_help=short ;; |
| 282 | |
| 283 | -host | --host | --hos | --ho) |
| 284 | ac_prev=host_alias ;; |
| 285 | -host=* | --host=* | --hos=* | --ho=*) |
| 286 | host_alias=$ac_optarg ;; |
| 287 | |
| 288 | -includedir | --includedir | --includedi | --included | --include \ |
| 289 | | --includ | --inclu | --incl | --inc) |
| 290 | ac_prev=includedir ;; |
| 291 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 292 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 293 | includedir=$ac_optarg ;; |
| 294 | |
| 295 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 296 | ac_prev=infodir ;; |
| 297 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 298 | infodir=$ac_optarg ;; |
| 299 | |
| 300 | -libdir | --libdir | --libdi | --libd) |
| 301 | ac_prev=libdir ;; |
| 302 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 303 | libdir=$ac_optarg ;; |
| 304 | |
| 305 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 306 | | --libexe | --libex | --libe) |
| 307 | ac_prev=libexecdir ;; |
| 308 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 309 | | --libexe=* | --libex=* | --libe=*) |
| 310 | libexecdir=$ac_optarg ;; |
| 311 | |
| 312 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 313 | | --localstate | --localstat | --localsta | --localst \ |
| 314 | | --locals | --local | --loca | --loc | --lo) |
| 315 | ac_prev=localstatedir ;; |
| 316 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 317 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 318 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 319 | localstatedir=$ac_optarg ;; |
| 320 | |
| 321 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 322 | ac_prev=mandir ;; |
| 323 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 324 | mandir=$ac_optarg ;; |
| 325 | |
| 326 | -nfp | --nfp | --nf) |
| 327 | # Obsolete; use --without-fp. |
| 328 | with_fp=no ;; |
| 329 | |
| 330 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 331 | | --no-cr | --no-c) |
| 332 | no_create=yes ;; |
| 333 | |
| 334 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 335 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 336 | no_recursion=yes ;; |
| 337 | |
| 338 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 339 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 340 | | --oldin | --oldi | --old | --ol | --o) |
| 341 | ac_prev=oldincludedir ;; |
| 342 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 343 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 344 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 345 | oldincludedir=$ac_optarg ;; |
| 346 | |
| 347 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 348 | ac_prev=prefix ;; |
| 349 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 350 | prefix=$ac_optarg ;; |
| 351 | |
| 352 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 353 | | --program-pre | --program-pr | --program-p) |
| 354 | ac_prev=program_prefix ;; |
| 355 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 356 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 357 | program_prefix=$ac_optarg ;; |
| 358 | |
| 359 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 360 | | --program-suf | --program-su | --program-s) |
| 361 | ac_prev=program_suffix ;; |
| 362 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 363 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 364 | program_suffix=$ac_optarg ;; |
| 365 | |
| 366 | -program-transform-name | --program-transform-name \ |
| 367 | | --program-transform-nam | --program-transform-na \ |
| 368 | | --program-transform-n | --program-transform- \ |
| 369 | | --program-transform | --program-transfor \ |
| 370 | | --program-transfo | --program-transf \ |
| 371 | | --program-trans | --program-tran \ |
| 372 | | --progr-tra | --program-tr | --program-t) |
| 373 | ac_prev=program_transform_name ;; |
| 374 | -program-transform-name=* | --program-transform-name=* \ |
| 375 | | --program-transform-nam=* | --program-transform-na=* \ |
| 376 | | --program-transform-n=* | --program-transform-=* \ |
| 377 | | --program-transform=* | --program-transfor=* \ |
| 378 | | --program-transfo=* | --program-transf=* \ |
| 379 | | --program-trans=* | --program-tran=* \ |
| 380 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 381 | program_transform_name=$ac_optarg ;; |
| 382 | |
| 383 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 384 | | -silent | --silent | --silen | --sile | --sil) |
| 385 | silent=yes ;; |
| 386 | |
| 387 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 388 | ac_prev=sbindir ;; |
| 389 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 390 | | --sbi=* | --sb=*) |
| 391 | sbindir=$ac_optarg ;; |
| 392 | |
| 393 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 394 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 395 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 396 | | --sha | --sh) |
| 397 | ac_prev=sharedstatedir ;; |
| 398 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 399 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 400 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 401 | | --sha=* | --sh=*) |
| 402 | sharedstatedir=$ac_optarg ;; |
| 403 | |
| 404 | -site | --site | --sit) |
| 405 | ac_prev=site ;; |
| 406 | -site=* | --site=* | --sit=*) |
| 407 | site=$ac_optarg ;; |
| 408 | |
| 409 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 410 | ac_prev=srcdir ;; |
| 411 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 412 | srcdir=$ac_optarg ;; |
| 413 | |
| 414 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 415 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 416 | ac_prev=sysconfdir ;; |
| 417 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 418 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 419 | sysconfdir=$ac_optarg ;; |
| 420 | |
| 421 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 422 | ac_prev=target_alias ;; |
| 423 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 424 | target_alias=$ac_optarg ;; |
| 425 | |
| 426 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 427 | verbose=yes ;; |
| 428 | |
| 429 | -version | --version | --versio | --versi | --vers | -V) |
| 430 | ac_init_version=: ;; |
| 431 | |
| 432 | -with-* | --with-*) |
| 433 | ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
| 434 | # Reject names that are not valid shell variable names. |
| 435 | expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && |
| 436 | { echo "$as_me: error: invalid package name: $ac_package" >&2 |
| 437 | { (exit 1); exit 1; }; } |
| 438 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 439 | case $ac_option in |
| 440 | *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; |
| 441 | *) ac_optarg=yes ;; |
| 442 | esac |
| 443 | eval "with_$ac_package='$ac_optarg'" ;; |
| 444 | |
| 445 | -without-* | --without-*) |
| 446 | ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
| 447 | # Reject names that are not valid shell variable names. |
| 448 | expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && |
| 449 | { echo "$as_me: error: invalid package name: $ac_package" >&2 |
| 450 | { (exit 1); exit 1; }; } |
| 451 | ac_package=`echo $ac_package | sed 's/-/_/g'` |
| 452 | eval "with_$ac_package=no" ;; |
| 453 | |
| 454 | --x) |
| 455 | # Obsolete; use --with-x. |
| 456 | with_x=yes ;; |
| 457 | |
| 458 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 459 | | --x-incl | --x-inc | --x-in | --x-i) |
| 460 | ac_prev=x_includes ;; |
| 461 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 462 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 463 | x_includes=$ac_optarg ;; |
| 464 | |
| 465 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 466 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 467 | ac_prev=x_libraries ;; |
| 468 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 469 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 470 | x_libraries=$ac_optarg ;; |
| 471 | |
| 472 | -*) { echo "$as_me: error: unrecognized option: $ac_option |
| 473 | Try \`$0 --help' for more information." >&2 |
| 474 | { (exit 1); exit 1; }; } |
| 475 | ;; |
| 476 | |
| 477 | *=*) |
| 478 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 479 | # Reject names that are not valid shell variable names. |
| 480 | expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && |
| 481 | { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 |
| 482 | { (exit 1); exit 1; }; } |
| 483 | ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` |
| 484 | eval "$ac_envvar='$ac_optarg'" |
| 485 | export $ac_envvar ;; |
| 486 | |
| 487 | *) |
| 488 | # FIXME: should be removed in autoconf 3.0. |
| 489 | echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
| 490 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
| 491 | echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
| 492 | : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} |
| 493 | ;; |
| 494 | |
| 495 | esac |
| 496 | done |
| 497 | |
| 498 | if test -n "$ac_prev"; then |
| 499 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
| 500 | { echo "$as_me: error: missing argument to $ac_option" >&2 |
| 501 | { (exit 1); exit 1; }; } |
| 502 | fi |
| 503 | |
| 504 | # Be sure to have absolute paths. |
| 505 | for ac_var in exec_prefix prefix |
| 506 | do |
| 507 | eval ac_val=$`echo $ac_var` |
| 508 | case $ac_val in |
| 509 | [\\/$]* | ?:[\\/]* | NONE | '' ) ;; |
| 510 | *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2 |
| 511 | { (exit 1); exit 1; }; };; |
| 512 | esac |
| 513 | done |
| 514 | |
| 515 | # Be sure to have absolute paths. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 516 | for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 517 | localstatedir libdir includedir oldincludedir infodir mandir |
| 518 | do |
| 519 | eval ac_val=$`echo $ac_var` |
| 520 | case $ac_val in |
| 521 | [\\/$]* | ?:[\\/]* ) ;; |
| 522 | *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2 |
| 523 | { (exit 1); exit 1; }; };; |
| 524 | esac |
| 525 | done |
| 526 | |
| 527 | # There might be people who depend on the old broken behavior: `$host' |
| 528 | # used to hold the argument of --host etc. |
| 529 | build=$build_alias |
| 530 | host=$host_alias |
| 531 | target=$target_alias |
| 532 | |
| 533 | # FIXME: should be removed in autoconf 3.0. |
| 534 | if test "x$host_alias" != x; then |
| 535 | if test "x$build_alias" = x; then |
| 536 | cross_compiling=maybe |
| 537 | echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. |
| 538 | If a cross compiler is detected then cross compile mode will be used." >&2 |
| 539 | elif test "x$build_alias" != "x$host_alias"; then |
| 540 | cross_compiling=yes |
| 541 | fi |
| 542 | fi |
| 543 | |
| 544 | ac_tool_prefix= |
| 545 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 546 | |
| 547 | test "$silent" = yes && exec 6>/dev/null |
| 548 | |
| 549 | # Find the source files, if location was not specified. |
| 550 | if test -z "$srcdir"; then |
| 551 | ac_srcdir_defaulted=yes |
| 552 | # Try the directory containing this script, then its parent. |
| 553 | ac_prog=$0 |
| 554 | ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'` |
| 555 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 556 | srcdir=$ac_confdir |
| 557 | if test ! -r $srcdir/$ac_unique_file; then |
| 558 | srcdir=.. |
| 559 | fi |
| 560 | else |
| 561 | ac_srcdir_defaulted=no |
| 562 | fi |
| 563 | if test ! -r $srcdir/$ac_unique_file; then |
| 564 | if test "$ac_srcdir_defaulted" = yes; then |
| 565 | { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2 |
| 566 | { (exit 1); exit 1; }; } |
| 567 | else |
| 568 | { echo "$as_me: error: cannot find sources in $srcdir" >&2 |
| 569 | { (exit 1); exit 1; }; } |
| 570 | fi |
| 571 | fi |
| 572 | srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'` |
| 573 | ac_env_build_alias_set=${build_alias+set} |
| 574 | ac_env_build_alias_value=$build_alias |
| 575 | ac_cv_env_build_alias_set=${build_alias+set} |
| 576 | ac_cv_env_build_alias_value=$build_alias |
| 577 | ac_env_host_alias_set=${host_alias+set} |
| 578 | ac_env_host_alias_value=$host_alias |
| 579 | ac_cv_env_host_alias_set=${host_alias+set} |
| 580 | ac_cv_env_host_alias_value=$host_alias |
| 581 | ac_env_target_alias_set=${target_alias+set} |
| 582 | ac_env_target_alias_value=$target_alias |
| 583 | ac_cv_env_target_alias_set=${target_alias+set} |
| 584 | ac_cv_env_target_alias_value=$target_alias |
| 585 | ac_env_CC_set=${CC+set} |
| 586 | ac_env_CC_value=$CC |
| 587 | ac_cv_env_CC_set=${CC+set} |
| 588 | ac_cv_env_CC_value=$CC |
| 589 | ac_env_CFLAGS_set=${CFLAGS+set} |
| 590 | ac_env_CFLAGS_value=$CFLAGS |
| 591 | ac_cv_env_CFLAGS_set=${CFLAGS+set} |
| 592 | ac_cv_env_CFLAGS_value=$CFLAGS |
| 593 | ac_env_LDFLAGS_set=${LDFLAGS+set} |
| 594 | ac_env_LDFLAGS_value=$LDFLAGS |
| 595 | ac_cv_env_LDFLAGS_set=${LDFLAGS+set} |
| 596 | ac_cv_env_LDFLAGS_value=$LDFLAGS |
| 597 | ac_env_CPPFLAGS_set=${CPPFLAGS+set} |
| 598 | ac_env_CPPFLAGS_value=$CPPFLAGS |
| 599 | ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set} |
| 600 | ac_cv_env_CPPFLAGS_value=$CPPFLAGS |
| 601 | ac_env_CPP_set=${CPP+set} |
| 602 | ac_env_CPP_value=$CPP |
| 603 | ac_cv_env_CPP_set=${CPP+set} |
| 604 | ac_cv_env_CPP_value=$CPP |
| 605 | ac_env_CXX_set=${CXX+set} |
| 606 | ac_env_CXX_value=$CXX |
| 607 | ac_cv_env_CXX_set=${CXX+set} |
| 608 | ac_cv_env_CXX_value=$CXX |
| 609 | ac_env_CXXFLAGS_set=${CXXFLAGS+set} |
| 610 | ac_env_CXXFLAGS_value=$CXXFLAGS |
| 611 | ac_cv_env_CXXFLAGS_set=${CXXFLAGS+set} |
| 612 | ac_cv_env_CXXFLAGS_value=$CXXFLAGS |
| 613 | ac_env_CXXCPP_set=${CXXCPP+set} |
| 614 | ac_env_CXXCPP_value=$CXXCPP |
| 615 | ac_cv_env_CXXCPP_set=${CXXCPP+set} |
| 616 | ac_cv_env_CXXCPP_value=$CXXCPP |
| 617 | |
| 618 | # |
| 619 | # Report the --help message. |
| 620 | # |
| 621 | if test "$ac_init_help" = "long"; then |
| 622 | # Omit some internal or obsolete options to make the list less imposing. |
| 623 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 624 | cat <<EOF |
| 625 | \`configure' configures this package to adapt to many kinds of systems. |
| 626 | |
| 627 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 628 | |
| 629 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 630 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 631 | |
| 632 | Defaults for the options are specified in brackets. |
| 633 | |
| 634 | Configuration: |
| 635 | -h, --help display this help and exit |
| 636 | --help=short display options specific to this package |
| 637 | --help=recursive display the short help of all the included packages |
| 638 | -V, --version display version information and exit |
| 639 | -q, --quiet, --silent do not print \`checking...' messages |
| 640 | --cache-file=FILE cache test results in FILE [disabled] |
| 641 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 642 | -n, --no-create do not create output files |
| 643 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 644 | |
| 645 | EOF |
| 646 | |
| 647 | cat <<EOF |
| 648 | Installation directories: |
| 649 | --prefix=PREFIX install architecture-independent files in PREFIX |
| 650 | [$ac_default_prefix] |
| 651 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
| 652 | [PREFIX] |
| 653 | |
| 654 | By default, \`make install' will install all the files in |
| 655 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 656 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 657 | for instance \`--prefix=\$HOME'. |
| 658 | |
| 659 | For better control, use the options below. |
| 660 | |
| 661 | Fine tuning of the installation directories: |
| 662 | --bindir=DIR user executables [EPREFIX/bin] |
| 663 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 664 | --libexecdir=DIR program executables [EPREFIX/libexec] |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 665 | --datarootdir=DIR read-only architecture-independent data [PREFIX/share] |
| 666 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 667 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 668 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 669 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 670 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 671 | --includedir=DIR C header files [PREFIX/include] |
| 672 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 673 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 674 | --mandir=DIR man documentation [DATAROOTDIR/man] |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 675 | EOF |
| 676 | |
| 677 | cat <<\EOF |
| 678 | |
| 679 | Program names: |
| 680 | --program-prefix=PREFIX prepend PREFIX to installed program names |
| 681 | --program-suffix=SUFFIX append SUFFIX to installed program names |
| 682 | --program-transform-name=PROGRAM run sed PROGRAM on installed program names |
| 683 | |
| 684 | System types: |
| 685 | --build=BUILD configure for building on BUILD [guessed] |
| 686 | --host=HOST build programs to run on HOST [BUILD] |
| 687 | --target=TARGET configure for building compilers for TARGET [HOST] |
| 688 | EOF |
| 689 | fi |
| 690 | |
| 691 | if test -n "$ac_init_help"; then |
| 692 | |
| 693 | cat <<\EOF |
| 694 | |
| 695 | Optional Packages: |
| 696 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 697 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 698 | |
| 699 | Optional Features: |
| 700 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 701 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 702 | |
| 703 | --with-rel-version=XXX override derived release version |
| 704 | --with-abi-version=XXX override derived ABI version |
| 705 | --with-system-type=XXX test: override derived host system-type |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 706 | --without-ada suppress check for Ada95, don't build demo |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 707 | --without-cxx do not adjust ncurses bool to match C++ |
| 708 | --without-cxx-binding do not build C++ binding and demo |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 709 | --disable-db-install suppress install of terminal database |
| 710 | --without-manpages suppress install of manpages |
| 711 | --without-progs suppress build/install with programs (e.g., tic) |
| 712 | --without-tests suppress build/install with test-programs |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 713 | --without-curses-h install curses.h as ncurses.h only |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 714 | --with-pkg-config{=path} enable/disable use of pkg-config |
| 715 | --with-pkg-config-libdir=XXX use given directory for installing pc-files |
| 716 | --enable-pc-files generate and install .pc files for pkg-config |
| 717 | --with-pc-suffix suffixes pc-files |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 718 | --enable-mixed-case tic should assume mixed-case filenames |
| 719 | --with-install-prefix prefixes actual install-location ($DESTDIR) |
| 720 | Build-Tools Needed to Compile Temporary Applications for Cross-compiling: |
| 721 | --with-build-cc=XXX the build C compiler ($BUILD_CC) |
| 722 | --with-build-cpp=XXX the build C preprocessor ($BUILD_CPP) |
| 723 | --with-build-cflags=XXX the build C compiler-flags ($BUILD_CFLAGS) |
| 724 | --with-build-cppflags=XXX the build C preprocessor-flags ($BUILD_CPPFLAGS) |
| 725 | --with-build-ldflags=XXX the build linker-flags ($BUILD_LDFLAGS) |
| 726 | --with-build-libs=XXX the build libraries (${BUILD_LIBS}) |
| 727 | Options to Specify the Libraries Built/Used: |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 728 | --disable-libtool-version enable to use libtool's incompatible naming scheme |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 729 | --with-libtool generate libraries with libtool |
| 730 | --with-shared generate shared-libraries |
| 731 | --with-normal generate normal-libraries (default) |
| 732 | --with-debug generate debug-libraries (default) |
| 733 | --with-profile generate profile-libraries |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 734 | --with-cxx-shared generate C++ shared-libraries |
| 735 | --with-lib-prefix override library-prefix |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 736 | --with-termlib generate separate terminfo library |
| 737 | --with-ticlib generate separate tic library |
| 738 | --with-gpm use Alessandro Rubini's GPM library |
| 739 | --without-dlsym do not use dlsym() to load GPM dynamically |
| 740 | --with-sysmouse use sysmouse (FreeBSD console) |
| 741 | --enable-rpath use rpath option when generating shared libraries |
| 742 | --disable-relink relink shared libraries during install |
| 743 | --with-shlib-version=X Specify rel or abi version for shared libs |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 744 | --with-libtool-opts=XXX specify additional libtool options |
| 745 | --with-export-syms=XXX limit exported symbols using libtool |
| 746 | --with-versioned-syms=X markup versioned symbols using ld |
| 747 | --disable-lib-suffixes disable library suffixes |
| 748 | --disable-rpath-hack don't add rpath options for additional libraries |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 749 | Fine-Tuning Your Configuration: |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 750 | --with-extra-suffix=X append extra suffix to header/library paths |
| 751 | --disable-overwrite put headers in subdir, omit link to -lcurses |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 752 | --disable-database do not use terminfo, only fallbacks/termcap |
| 753 | --with-database=XXX specify terminfo source to install |
| 754 | --with-hashed-db specify hashed-database library |
| 755 | --with-fallbacks=XXX specify list of fallback terminal descriptions |
| 756 | --without-xterm-new specify if xterm terminfo should be old version |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 757 | --with-xterm-kbs=XXX specify if xterm backspace sends BS or DEL |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 758 | --with-terminfo-dirs=XXX specify list of terminfo directories (default: DATADIR/terminfo) |
| 759 | --with-default-terminfo-dir=DIR default terminfo directory (default: DATADIR/terminfo) |
| 760 | --disable-big-core assume machine has little memory |
| 761 | --disable-big-strings assume compiler has only standard-size strings |
| 762 | --enable-termcap compile in termcap fallback support |
| 763 | --with-termpath=XXX specify list of termcap files (default: /etc/termcap:/usr/share/misc/termcap) |
| 764 | --enable-getcap fast termcap load, no xrefs to terminfo |
| 765 | --enable-getcap-cache cache translated termcaps in ~/.terminfo |
| 766 | --disable-home-terminfo drop ~/.terminfo from terminfo search-path |
| 767 | --disable-root-environ restrict environment when running as root |
| 768 | --enable-symlinks make tic use symbolic links not hard links |
| 769 | --enable-broken_linker compile with broken-linker support code |
| 770 | --enable-bsdpad recognize BSD-style prefix padding |
| 771 | --enable-widec compile with wide-char/UTF-8 code |
| 772 | --disable-lp64 allow chtype to be long (ignore _LP64) |
| 773 | --disable-largefile omit support for large files |
| 774 | --disable-tparm-varargs compile tparm() without varargs interface |
| 775 | --disable-tic-depends link tic library without explicit dependency on ncurses library |
| 776 | --with-bool=TYPE override fallback type of bool variable |
| 777 | --with-caps=alt compile with alternate Caps file |
| 778 | --with-chtype=TYPE override type of chtype |
| 779 | --with-ospeed=TYPE override type of ospeed variable |
| 780 | --with-mmask-t=TYPE override type of mmask_t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 781 | --with-ccharw-max=XXX override size CCHARW_MAX |
| 782 | --with-tparm-arg=TYPE override parameter type of tparm |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 783 | --with-rcs-ids compile-in RCS identifiers |
| 784 | Options to Specify How Manpages are Installed: |
| 785 | --with-manpage-format specify manpage-format: gzip/compress/BSDI/normal and |
| 786 | optionally formatted/catonly, e.g., gzip,formatted |
| 787 | --with-manpage-renames specify manpage-renaming |
| 788 | --with-manpage-aliases specify manpage-aliases using .so |
| 789 | --with-manpage-symlinks specify manpage-aliases using symlinks |
| 790 | --with-manpage-tbl specify manpage processing with tbl |
| 791 | Extensions: |
| 792 | --disable-ext-funcs disable function-extensions |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 793 | --enable-sp-funcs enable SCREEN-extensions |
| 794 | --enable-term-driver enable terminal-driver |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 795 | --enable-const compile with extra/non-standard const |
| 796 | --enable-ext-colors compile for 256-color support |
| 797 | --enable-ext-mouse compile for extended mouse-encoding |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 798 | --enable-ext-putwin compile with extended putwin/screendump |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 799 | --enable-no-padding compile with $NCURSES_NO_PADDING code |
| 800 | --enable-signed-char compile using signed Boolean's in term.h |
| 801 | --enable-sigwinch compile with SIGWINCH handler |
| 802 | --enable-tcap-names compile with user-definable terminal capabilities |
| 803 | Development Code: |
| 804 | --without-develop disable development options |
| 805 | --enable-hard-tabs compile with hard-tabs code |
| 806 | --enable-xmc-glitch compile with support for xmc (magic-cookie) |
| 807 | Experimental Code: |
| 808 | --disable-assumed-color do not assume anything about default-colors |
| 809 | --disable-hashmap compile without hashmap scrolling-optimization |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 810 | --enable-colorfgbg compile-in experimental $COLORFGBG code |
| 811 | --enable-interop compile-in interop bindings |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 812 | --with-pthread use POSIX thread library |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 813 | --enable-pthreads-eintr enable EINTR in wgetch with pthreads |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 814 | --enable-weak-symbols enable weak-symbols for pthreads |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 815 | --enable-reentrant compile with reentrant code |
| 816 | --with-wrap-prefix=XXX override prefix used for public variables |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 817 | --enable-safe-sprintf compile with experimental safe-sprintf code |
| 818 | --disable-scroll-hints compile without scroll-hints code |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 819 | --enable-wgetch-events compile with wgetch-events code |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 820 | Testing/development Options: |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 821 | --disable-echo do not display "compiling" commands |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 822 | --enable-warnings build: turn on GCC compiler warnings |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 823 | --enable-string-hacks work around bogus compiler/loader warnings |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 824 | --enable-assertions test: turn on generation of assertion code |
| 825 | --with-dmalloc test: use Gray Watson's dmalloc library |
| 826 | --with-dbmalloc test: use Conor Cahill's dbmalloc library |
| 827 | --with-valgrind test: use valgrind |
| 828 | --disable-leaks test: free permanent memory, analyze leaks |
| 829 | --enable-expanded test: generate functions for certain macros |
| 830 | --disable-macros test: use functions rather than macros |
| 831 | --with-trace test: add trace() function to all models of ncurses |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 832 | --disable-gnat-projects test: disable GNAT projects even if usable |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 833 | Ada95 Binding Options: |
| 834 | --with-ada-compiler=CMD specify Ada95 compiler command (default gnatmake) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 835 | --with-ada-include=DIR Ada includes are in DIR (default: PREFIX/share/ada/adainclude) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 836 | --with-ada-objects=DIR Ada objects are in DIR (default: PREFIX/lib/ada/adalib) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 837 | --with-ada-sharedlib=soname build shared-library (requires GNAT projects) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 838 | |
| 839 | Some influential environment variables: |
| 840 | CC C compiler command |
| 841 | CFLAGS C compiler flags |
| 842 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 843 | nonstandard directory <lib dir> |
| 844 | CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have |
| 845 | headers in a nonstandard directory <include dir> |
| 846 | CPP C preprocessor |
| 847 | CXX C++ compiler command |
| 848 | CXXFLAGS C++ compiler flags |
| 849 | CXXCPP C++ preprocessor |
| 850 | |
| 851 | Use these variables to override the choices made by `configure' or to help |
| 852 | it to find libraries and programs with nonstandard names/locations. |
| 853 | |
| 854 | EOF |
| 855 | fi |
| 856 | |
| 857 | if test "$ac_init_help" = "recursive"; then |
| 858 | # If there are subdirs, report their specific --help. |
| 859 | ac_popdir=`pwd` |
| 860 | for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue |
| 861 | cd $ac_subdir |
| 862 | # A "../" for each directory in /$ac_subdir. |
| 863 | ac_dots=`echo $ac_subdir | |
| 864 | sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'` |
| 865 | |
| 866 | case $srcdir in |
| 867 | .) # No --srcdir option. We are building in place. |
| 868 | ac_sub_srcdir=$srcdir ;; |
| 869 | [\\/]* | ?:[\\/]* ) # Absolute path. |
| 870 | ac_sub_srcdir=$srcdir/$ac_subdir ;; |
| 871 | *) # Relative path. |
| 872 | ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;; |
| 873 | esac |
| 874 | |
| 875 | # Check for guested configure; otherwise get Cygnus style configure. |
| 876 | if test -f $ac_sub_srcdir/configure.gnu; then |
| 877 | echo |
| 878 | $SHELL $ac_sub_srcdir/configure.gnu --help=recursive |
| 879 | elif test -f $ac_sub_srcdir/configure; then |
| 880 | echo |
| 881 | $SHELL $ac_sub_srcdir/configure --help=recursive |
| 882 | elif test -f $ac_sub_srcdir/configure.ac || |
| 883 | test -f $ac_sub_srcdir/configure.in; then |
| 884 | echo |
| 885 | $ac_configure --help |
| 886 | else |
| 887 | echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2 |
| 888 | fi |
| 889 | cd $ac_popdir |
| 890 | done |
| 891 | fi |
| 892 | |
| 893 | test -n "$ac_init_help" && exit 0 |
| 894 | if $ac_init_version; then |
| 895 | cat <<\EOF |
| 896 | |
| 897 | Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001 |
| 898 | Free Software Foundation, Inc. |
| 899 | This configure script is free software; the Free Software Foundation |
| 900 | gives unlimited permission to copy, distribute and modify it. |
| 901 | EOF |
| 902 | exit 0 |
| 903 | fi |
| 904 | exec 5>config.log |
| 905 | cat >&5 <<EOF |
| 906 | This file contains any messages produced by compilers while |
| 907 | running configure, to aid debugging if configure makes a mistake. |
| 908 | |
| 909 | It was created by $as_me, which was |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 910 | generated by GNU Autoconf 2.52.20141204. Invocation command line was |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 911 | |
| 912 | $ $0 $@ |
| 913 | |
| 914 | EOF |
| 915 | { |
| 916 | cat <<_ASUNAME |
| 917 | ## ---------- ## |
| 918 | ## Platform. ## |
| 919 | ## ---------- ## |
| 920 | |
| 921 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 922 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 923 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 924 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 925 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 926 | |
| 927 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 928 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 929 | |
| 930 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 931 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 932 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` |
| 933 | hostinfo = `(hostinfo) 2>/dev/null || echo unknown` |
| 934 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 935 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 936 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 937 | |
| 938 | PATH = $PATH |
| 939 | |
| 940 | _ASUNAME |
| 941 | } >&5 |
| 942 | |
| 943 | cat >&5 <<EOF |
| 944 | ## ------------ ## |
| 945 | ## Core tests. ## |
| 946 | ## ------------ ## |
| 947 | |
| 948 | EOF |
| 949 | |
| 950 | # Keep a trace of the command line. |
| 951 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 952 | # Also quote any args containing shell meta-characters. |
| 953 | ac_configure_args= |
| 954 | ac_sep= |
| 955 | for ac_arg |
| 956 | do |
| 957 | case $ac_arg in |
| 958 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 959 | | --no-cr | --no-c) ;; |
| 960 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 961 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 962 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) |
| 963 | ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` |
| 964 | ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'" |
| 965 | ac_sep=" " ;; |
| 966 | *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg" |
| 967 | ac_sep=" " ;; |
| 968 | esac |
| 969 | # Get rid of the leading space. |
| 970 | done |
| 971 | |
| 972 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 973 | # config.log. We remove comments because anyway the quotes in there |
| 974 | # would cause problems or look ugly. |
| 975 | trap 'exit_status=$? |
| 976 | # Save into config.log some information that might help in debugging. |
| 977 | echo >&5 |
| 978 | echo "## ----------------- ##" >&5 |
| 979 | echo "## Cache variables. ##" >&5 |
| 980 | echo "## ----------------- ##" >&5 |
| 981 | echo >&5 |
| 982 | # The following way of writing the cache mishandles newlines in values, |
| 983 | { |
| 984 | (set) 2>&1 | |
| 985 | case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in |
| 986 | *ac_space=\ *) |
| 987 | sed -n \ |
| 988 | "s/'"'"'/'"'"'\\\\'"'"''"'"'/g; |
| 989 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p" |
| 990 | ;; |
| 991 | *) |
| 992 | sed -n \ |
| 993 | "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" |
| 994 | ;; |
| 995 | esac; |
| 996 | } >&5 |
| 997 | sed "/^$/d" confdefs.h >conftest.log |
| 998 | if test -s conftest.log; then |
| 999 | echo >&5 |
| 1000 | echo "## ------------ ##" >&5 |
| 1001 | echo "## confdefs.h. ##" >&5 |
| 1002 | echo "## ------------ ##" >&5 |
| 1003 | echo >&5 |
| 1004 | cat conftest.log >&5 |
| 1005 | fi |
| 1006 | (echo; echo) >&5 |
| 1007 | test "$ac_signal" != 0 && |
| 1008 | echo "$as_me: caught signal $ac_signal" >&5 |
| 1009 | echo "$as_me: exit $exit_status" >&5 |
| 1010 | rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files && |
| 1011 | exit $exit_status |
| 1012 | ' 0 |
| 1013 | for ac_signal in 1 2 13 15; do |
| 1014 | trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal |
| 1015 | done |
| 1016 | ac_signal=0 |
| 1017 | |
| 1018 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 1019 | rm -rf conftest* confdefs.h |
| 1020 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 1021 | echo >confdefs.h |
| 1022 | |
| 1023 | # Let the site file select an alternate cache file if it wants to. |
| 1024 | # Prefer explicitly selected file to automatically selected ones. |
| 1025 | if test -z "$CONFIG_SITE"; then |
| 1026 | if test "x$prefix" != xNONE; then |
| 1027 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 1028 | else |
| 1029 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 1030 | fi |
| 1031 | fi |
| 1032 | for ac_site_file in $CONFIG_SITE; do |
| 1033 | if test -r "$ac_site_file"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1034 | { echo "$as_me:1034: loading site script $ac_site_file" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1035 | echo "$as_me: loading site script $ac_site_file" >&6;} |
| 1036 | cat "$ac_site_file" >&5 |
| 1037 | . "$ac_site_file" |
| 1038 | fi |
| 1039 | done |
| 1040 | |
| 1041 | if test -r "$cache_file"; then |
| 1042 | # Some versions of bash will fail to source /dev/null (special |
| 1043 | # files actually), so we avoid doing that. |
| 1044 | if test -f "$cache_file"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1045 | { echo "$as_me:1045: loading cache $cache_file" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1046 | echo "$as_me: loading cache $cache_file" >&6;} |
| 1047 | case $cache_file in |
| 1048 | [\\/]* | ?:[\\/]* ) . $cache_file;; |
| 1049 | *) . ./$cache_file;; |
| 1050 | esac |
| 1051 | fi |
| 1052 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1053 | { echo "$as_me:1053: creating cache $cache_file" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1054 | echo "$as_me: creating cache $cache_file" >&6;} |
| 1055 | >$cache_file |
| 1056 | fi |
| 1057 | |
| 1058 | # Check that the precious variables saved in the cache have kept the same |
| 1059 | # value. |
| 1060 | ac_cache_corrupted=false |
| 1061 | for ac_var in `(set) 2>&1 | |
| 1062 | sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do |
| 1063 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 1064 | eval ac_new_set=\$ac_env_${ac_var}_set |
| 1065 | eval ac_old_val="\$ac_cv_env_${ac_var}_value" |
| 1066 | eval ac_new_val="\$ac_env_${ac_var}_value" |
| 1067 | case $ac_old_set,$ac_new_set in |
| 1068 | set,) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1069 | { echo "$as_me:1069: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1070 | echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} |
| 1071 | ac_cache_corrupted=: ;; |
| 1072 | ,set) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1073 | { echo "$as_me:1073: error: \`$ac_var' was not set in the previous run" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1074 | echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} |
| 1075 | ac_cache_corrupted=: ;; |
| 1076 | ,);; |
| 1077 | *) |
| 1078 | if test "x$ac_old_val" != "x$ac_new_val"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1079 | { echo "$as_me:1079: error: \`$ac_var' has changed since the previous run:" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1080 | echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1081 | { echo "$as_me:1081: former value: $ac_old_val" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1082 | echo "$as_me: former value: $ac_old_val" >&2;} |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1083 | { echo "$as_me:1083: current value: $ac_new_val" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1084 | echo "$as_me: current value: $ac_new_val" >&2;} |
| 1085 | ac_cache_corrupted=: |
| 1086 | fi;; |
| 1087 | esac |
| 1088 | # Pass precious variables to config.status. It doesn't matter if |
| 1089 | # we pass some twice (in addition to the command line arguments). |
| 1090 | if test "$ac_new_set" = set; then |
| 1091 | case $ac_new_val in |
| 1092 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) |
| 1093 | ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` |
| 1094 | ac_configure_args="$ac_configure_args '$ac_arg'" |
| 1095 | ;; |
| 1096 | *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val" |
| 1097 | ;; |
| 1098 | esac |
| 1099 | fi |
| 1100 | done |
| 1101 | if $ac_cache_corrupted; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1102 | { echo "$as_me:1102: error: changes in the environment can compromise the build" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1103 | echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1104 | { { echo "$as_me:1104: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1105 | echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} |
| 1106 | { (exit 1); exit 1; }; } |
| 1107 | fi |
| 1108 | |
| 1109 | ac_ext=c |
| 1110 | ac_cpp='$CPP $CPPFLAGS' |
| 1111 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 1112 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 1113 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 1114 | ac_main_return=return |
| 1115 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1116 | case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in |
| 1117 | *c*,-n*) ECHO_N= ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway |
| 1118 | ECHO_T=' ' ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1119 | *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;; |
| 1120 | *) ECHO_N= ECHO_C='\c' ECHO_T= ;; |
| 1121 | esac |
| 1122 | echo "#! $SHELL" >conftest.sh |
| 1123 | echo "exit 0" >>conftest.sh |
| 1124 | chmod +x conftest.sh |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1125 | if { (echo "$as_me:1125: PATH=\".;.\"; conftest.sh") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1126 | (PATH=".;."; conftest.sh) 2>&5 |
| 1127 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1128 | echo "$as_me:1128: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1129 | (exit $ac_status); }; then |
| 1130 | ac_path_separator=';' |
| 1131 | else |
| 1132 | ac_path_separator=: |
| 1133 | fi |
| 1134 | PATH_SEPARATOR="$ac_path_separator" |
| 1135 | rm -f conftest.sh |
| 1136 | |
| 1137 | ac_config_headers="$ac_config_headers include/ncurses_cfg.h:include/ncurses_cfg.hin" |
| 1138 | |
| 1139 | top_builddir=`pwd` |
| 1140 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1141 | echo "$as_me:1141: checking for egrep" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1142 | echo $ECHO_N "checking for egrep... $ECHO_C" >&6 |
| 1143 | if test "${ac_cv_prog_egrep+set}" = set; then |
| 1144 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1145 | else |
| 1146 | if echo a | (grep -E '(a|b)') >/dev/null 2>&1 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1147 | then ac_cv_prog_egrep='grep -E' |
| 1148 | else ac_cv_prog_egrep='egrep' |
| 1149 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1150 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1151 | echo "$as_me:1151: result: $ac_cv_prog_egrep" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1152 | echo "${ECHO_T}$ac_cv_prog_egrep" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1153 | EGREP=$ac_cv_prog_egrep |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1154 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1155 | test -z "$EGREP" && { { echo "$as_me:1155: error: No egrep program found" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1156 | echo "$as_me: error: No egrep program found" >&2;} |
| 1157 | { (exit 1); exit 1; }; } |
| 1158 | |
| 1159 | NCURSES_MAJOR="`$ac_cv_prog_egrep '^NCURSES_MAJOR[ ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`" |
| 1160 | NCURSES_MINOR="`$ac_cv_prog_egrep '^NCURSES_MINOR[ ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`" |
| 1161 | NCURSES_PATCH="`$ac_cv_prog_egrep '^NCURSES_PATCH[ ]*=' $srcdir/dist.mk | sed -e 's/^[^0-9]*//'`" |
| 1162 | cf_cv_abi_version=${NCURSES_MAJOR} |
| 1163 | cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR} |
| 1164 | cf_cv_timestamp=`date` |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1165 | echo "$as_me:1165: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1166 | echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6 |
| 1167 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1168 | if test -f $srcdir/VERSION ; then |
| 1169 | echo "$as_me:1169: checking for package version" >&5 |
| 1170 | echo $ECHO_N "checking for package version... $ECHO_C" >&6 |
| 1171 | |
| 1172 | # if there are not enough fields, cut returns the last one... |
| 1173 | cf_field1=`sed -e '2,$d' $srcdir/VERSION|cut -f1` |
| 1174 | cf_field2=`sed -e '2,$d' $srcdir/VERSION|cut -f2` |
| 1175 | cf_field3=`sed -e '2,$d' $srcdir/VERSION|cut -f3` |
| 1176 | |
| 1177 | # this is how CF_BUNDLED_INTL uses $VERSION: |
| 1178 | VERSION="$cf_field1" |
| 1179 | |
| 1180 | VERSION_MAJOR=`echo "$cf_field2" | sed -e 's/\..*//'` |
| 1181 | test -z "$VERSION_MAJOR" && { { echo "$as_me:1181: error: missing major-version" >&5 |
| 1182 | echo "$as_me: error: missing major-version" >&2;} |
| 1183 | { (exit 1); exit 1; }; } |
| 1184 | |
| 1185 | VERSION_MINOR=`echo "$cf_field2" | sed -e 's/^[^.]*\.//' -e 's/-.*//'` |
| 1186 | test -z "$VERSION_MINOR" && { { echo "$as_me:1186: error: missing minor-version" >&5 |
| 1187 | echo "$as_me: error: missing minor-version" >&2;} |
| 1188 | { (exit 1); exit 1; }; } |
| 1189 | |
| 1190 | echo "$as_me:1190: result: ${VERSION_MAJOR}.${VERSION_MINOR}" >&5 |
| 1191 | echo "${ECHO_T}${VERSION_MAJOR}.${VERSION_MINOR}" >&6 |
| 1192 | |
| 1193 | echo "$as_me:1193: checking for package patch date" >&5 |
| 1194 | echo $ECHO_N "checking for package patch date... $ECHO_C" >&6 |
| 1195 | VERSION_PATCH=`echo "$cf_field3" | sed -e 's/^[^-]*-//'` |
| 1196 | case .$VERSION_PATCH in |
| 1197 | (.) |
| 1198 | { { echo "$as_me:1198: error: missing patch-date $VERSION_PATCH" >&5 |
| 1199 | echo "$as_me: error: missing patch-date $VERSION_PATCH" >&2;} |
| 1200 | { (exit 1); exit 1; }; } |
| 1201 | ;; |
| 1202 | (.[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]) |
| 1203 | ;; |
| 1204 | (*) |
| 1205 | { { echo "$as_me:1205: error: illegal patch-date $VERSION_PATCH" >&5 |
| 1206 | echo "$as_me: error: illegal patch-date $VERSION_PATCH" >&2;} |
| 1207 | { (exit 1); exit 1; }; } |
| 1208 | ;; |
| 1209 | esac |
| 1210 | echo "$as_me:1210: result: $VERSION_PATCH" >&5 |
| 1211 | echo "${ECHO_T}$VERSION_PATCH" >&6 |
| 1212 | else |
| 1213 | { { echo "$as_me:1213: error: did not find $srcdir/VERSION" >&5 |
| 1214 | echo "$as_me: error: did not find $srcdir/VERSION" >&2;} |
| 1215 | { (exit 1); exit 1; }; } |
| 1216 | fi |
| 1217 | |
| 1218 | # show the actual data that we have for versions: |
| 1219 | test -n "$verbose" && echo " ABI VERSION $VERSION" 1>&6 |
| 1220 | |
| 1221 | echo "${as_me:-configure}:1221: testing ABI VERSION $VERSION ..." 1>&5 |
| 1222 | |
| 1223 | test -n "$verbose" && echo " VERSION_MAJOR $VERSION_MAJOR" 1>&6 |
| 1224 | |
| 1225 | echo "${as_me:-configure}:1225: testing VERSION_MAJOR $VERSION_MAJOR ..." 1>&5 |
| 1226 | |
| 1227 | test -n "$verbose" && echo " VERSION_MINOR $VERSION_MINOR" 1>&6 |
| 1228 | |
| 1229 | echo "${as_me:-configure}:1229: testing VERSION_MINOR $VERSION_MINOR ..." 1>&5 |
| 1230 | |
| 1231 | test -n "$verbose" && echo " VERSION_PATCH $VERSION_PATCH" 1>&6 |
| 1232 | |
| 1233 | echo "${as_me:-configure}:1233: testing VERSION_PATCH $VERSION_PATCH ..." 1>&5 |
| 1234 | |
| 1235 | cf_PACKAGE=NCURSES |
| 1236 | PACKAGE=ncurses |
| 1237 | |
| 1238 | cat >>confdefs.h <<EOF |
| 1239 | #define PACKAGE "$PACKAGE" |
| 1240 | EOF |
| 1241 | |
| 1242 | cf_PACKAGE=`echo "$cf_PACKAGE" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 1243 | |
| 1244 | cat >>confdefs.h <<EOF |
| 1245 | #define ${cf_PACKAGE}_VERSION "${VERSION_MAJOR}.${VERSION_MINOR}" |
| 1246 | EOF |
| 1247 | |
| 1248 | cat >>confdefs.h <<EOF |
| 1249 | #define ${cf_PACKAGE}_PATCHDATE ${VERSION_PATCH} |
| 1250 | EOF |
| 1251 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1252 | test -z "$cf_cv_rel_version" && cf_cv_rel_version=0.0 |
| 1253 | |
| 1254 | # Check whether --with-rel-version or --without-rel-version was given. |
| 1255 | if test "${with_rel_version+set}" = set; then |
| 1256 | withval="$with_rel_version" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1257 | { echo "$as_me:1257: WARNING: overriding release version $cf_cv_rel_version to $withval" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1258 | echo "$as_me: WARNING: overriding release version $cf_cv_rel_version to $withval" >&2;} |
| 1259 | cf_cv_rel_version=$withval |
| 1260 | fi; |
| 1261 | |
| 1262 | NCURSES_MAJOR=`echo "$cf_cv_rel_version" | sed -e 's/\..*//'` |
| 1263 | NCURSES_MINOR=`echo "$cf_cv_rel_version" | sed -e 's/^[^.]*//' -e 's/^\.//' -e 's/\..*//'` |
| 1264 | |
| 1265 | if test -n "$NCURSES_MAJOR" ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1266 | case $NCURSES_MAJOR in |
| 1267 | ([0-9]*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1268 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1269 | (*) |
| 1270 | { { echo "$as_me:1270: error: Release major-version is not a number: $NCURSES_MAJOR" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1271 | echo "$as_me: error: Release major-version is not a number: $NCURSES_MAJOR" >&2;} |
| 1272 | { (exit 1); exit 1; }; } |
| 1273 | ;; |
| 1274 | esac |
| 1275 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1276 | { { echo "$as_me:1276: error: Release major-version value is empty" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1277 | echo "$as_me: error: Release major-version value is empty" >&2;} |
| 1278 | { (exit 1); exit 1; }; } |
| 1279 | fi |
| 1280 | |
| 1281 | if test -n "$NCURSES_MINOR" ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1282 | case $NCURSES_MINOR in |
| 1283 | ([0-9]*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1284 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1285 | (*) |
| 1286 | { { echo "$as_me:1286: error: Release minor-version is not a number: $NCURSES_MINOR" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1287 | echo "$as_me: error: Release minor-version is not a number: $NCURSES_MINOR" >&2;} |
| 1288 | { (exit 1); exit 1; }; } |
| 1289 | ;; |
| 1290 | esac |
| 1291 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1292 | { { echo "$as_me:1292: error: Release minor-version value is empty" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1293 | echo "$as_me: error: Release minor-version value is empty" >&2;} |
| 1294 | { (exit 1); exit 1; }; } |
| 1295 | fi |
| 1296 | |
| 1297 | test -z "$cf_cv_abi_version" && cf_cv_abi_version=0 |
| 1298 | |
| 1299 | # Check whether --with-abi-version or --without-abi-version was given. |
| 1300 | if test "${with_abi_version+set}" = set; then |
| 1301 | withval="$with_abi_version" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1302 | |
| 1303 | if test "x$cf_cv_abi_version" != "x$withval" |
| 1304 | then |
| 1305 | { echo "$as_me:1305: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1306 | echo "$as_me: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&2;} |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1307 | case $cf_cv_rel_version in |
| 1308 | (5.*) |
| 1309 | cf_cv_rel_version=$withval.0 |
| 1310 | ;; |
| 1311 | (6.*) |
| 1312 | cf_cv_rel_version=$withval.9 # FIXME: should be 10 as of 6.0 release |
| 1313 | ;; |
| 1314 | esac |
| 1315 | fi |
| 1316 | cf_cv_abi_version=$withval |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1317 | fi; |
| 1318 | |
| 1319 | if test -n "$cf_cv_abi_version" ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1320 | case $cf_cv_abi_version in |
| 1321 | ([0-9]*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1322 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1323 | (*) |
| 1324 | { { echo "$as_me:1324: error: ABI version is not a number: $cf_cv_abi_version" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1325 | echo "$as_me: error: ABI version is not a number: $cf_cv_abi_version" >&2;} |
| 1326 | { (exit 1); exit 1; }; } |
| 1327 | ;; |
| 1328 | esac |
| 1329 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1330 | { { echo "$as_me:1330: error: ABI version value is empty" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1331 | echo "$as_me: error: ABI version value is empty" >&2;} |
| 1332 | { (exit 1); exit 1; }; } |
| 1333 | fi |
| 1334 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1335 | if test "x$cf_cv_abi_version" != "x$with_abi_version" |
| 1336 | then |
| 1337 | case $cf_cv_rel_version in |
| 1338 | (5.*) |
| 1339 | cf_cv_rel_version=$with_abi_version.0 |
| 1340 | ;; |
| 1341 | esac |
| 1342 | fi |
| 1343 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1344 | ac_aux_dir= |
| 1345 | for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do |
| 1346 | if test -f $ac_dir/install-sh; then |
| 1347 | ac_aux_dir=$ac_dir |
| 1348 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 1349 | break |
| 1350 | elif test -f $ac_dir/install.sh; then |
| 1351 | ac_aux_dir=$ac_dir |
| 1352 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 1353 | break |
| 1354 | elif test -f $ac_dir/shtool; then |
| 1355 | ac_aux_dir=$ac_dir |
| 1356 | ac_install_sh="$ac_aux_dir/shtool install -c" |
| 1357 | break |
| 1358 | fi |
| 1359 | done |
| 1360 | if test -z "$ac_aux_dir"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1361 | { { echo "$as_me:1361: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1362 | echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;} |
| 1363 | { (exit 1); exit 1; }; } |
| 1364 | fi |
| 1365 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" |
| 1366 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" |
| 1367 | ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure. |
| 1368 | |
| 1369 | # Make sure we can run config.sub. |
| 1370 | $ac_config_sub sun4 >/dev/null 2>&1 || |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1371 | { { echo "$as_me:1371: error: cannot run $ac_config_sub" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1372 | echo "$as_me: error: cannot run $ac_config_sub" >&2;} |
| 1373 | { (exit 1); exit 1; }; } |
| 1374 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1375 | echo "$as_me:1375: checking build system type" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1376 | echo $ECHO_N "checking build system type... $ECHO_C" >&6 |
| 1377 | if test "${ac_cv_build+set}" = set; then |
| 1378 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1379 | else |
| 1380 | ac_cv_build_alias=$build_alias |
| 1381 | test -z "$ac_cv_build_alias" && |
| 1382 | ac_cv_build_alias=`$ac_config_guess` |
| 1383 | test -z "$ac_cv_build_alias" && |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1384 | { { echo "$as_me:1384: error: cannot guess build type; you must specify one" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1385 | echo "$as_me: error: cannot guess build type; you must specify one" >&2;} |
| 1386 | { (exit 1); exit 1; }; } |
| 1387 | ac_cv_build=`$ac_config_sub $ac_cv_build_alias` || |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1388 | { { echo "$as_me:1388: error: $ac_config_sub $ac_cv_build_alias failed." >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1389 | echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;} |
| 1390 | { (exit 1); exit 1; }; } |
| 1391 | |
| 1392 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1393 | echo "$as_me:1393: result: $ac_cv_build" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1394 | echo "${ECHO_T}$ac_cv_build" >&6 |
| 1395 | build=$ac_cv_build |
| 1396 | build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
| 1397 | build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` |
| 1398 | build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` |
| 1399 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1400 | echo "$as_me:1400: checking host system type" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1401 | echo $ECHO_N "checking host system type... $ECHO_C" >&6 |
| 1402 | if test "${ac_cv_host+set}" = set; then |
| 1403 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1404 | else |
| 1405 | ac_cv_host_alias=$host_alias |
| 1406 | test -z "$ac_cv_host_alias" && |
| 1407 | ac_cv_host_alias=$ac_cv_build_alias |
| 1408 | ac_cv_host=`$ac_config_sub $ac_cv_host_alias` || |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1409 | { { echo "$as_me:1409: error: $ac_config_sub $ac_cv_host_alias failed" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1410 | echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;} |
| 1411 | { (exit 1); exit 1; }; } |
| 1412 | |
| 1413 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1414 | echo "$as_me:1414: result: $ac_cv_host" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1415 | echo "${ECHO_T}$ac_cv_host" >&6 |
| 1416 | host=$ac_cv_host |
| 1417 | host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
| 1418 | host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` |
| 1419 | host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` |
| 1420 | |
| 1421 | if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1422 | echo "$as_me:1422: checking target system type" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1423 | echo $ECHO_N "checking target system type... $ECHO_C" >&6 |
| 1424 | if test "${ac_cv_target+set}" = set; then |
| 1425 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1426 | else |
| 1427 | ac_cv_target_alias=$target_alias |
| 1428 | test "x$ac_cv_target_alias" = "x" && |
| 1429 | ac_cv_target_alias=$ac_cv_host_alias |
| 1430 | ac_cv_target=`$ac_config_sub $ac_cv_target_alias` || |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1431 | { { echo "$as_me:1431: error: $ac_config_sub $ac_cv_target_alias failed" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1432 | echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;} |
| 1433 | { (exit 1); exit 1; }; } |
| 1434 | |
| 1435 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1436 | echo "$as_me:1436: result: $ac_cv_target" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1437 | echo "${ECHO_T}$ac_cv_target" >&6 |
| 1438 | target=$ac_cv_target |
| 1439 | target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` |
| 1440 | target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` |
| 1441 | target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` |
| 1442 | |
| 1443 | # The aliases save the names the user supplied, while $host etc. |
| 1444 | # will get canonicalized. |
| 1445 | test -n "$target_alias" && |
| 1446 | test "$program_prefix$program_suffix$program_transform_name" = \ |
| 1447 | NONENONEs,x,x, && |
| 1448 | program_prefix=${target_alias}- |
| 1449 | system_name="$host_os" |
| 1450 | else |
| 1451 | system_name="`(uname -s -r) 2>/dev/null`" |
| 1452 | if test -z "$system_name" ; then |
| 1453 | system_name="`(hostname) 2>/dev/null`" |
| 1454 | fi |
| 1455 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1456 | test -n "$system_name" && |
| 1457 | cat >>confdefs.h <<EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1458 | #define SYSTEM_NAME "$system_name" |
| 1459 | EOF |
| 1460 | |
| 1461 | if test "${cf_cv_system_name+set}" = set; then |
| 1462 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1463 | else |
| 1464 | cf_cv_system_name="$system_name" |
| 1465 | fi |
| 1466 | |
| 1467 | test -z "$system_name" && system_name="$cf_cv_system_name" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1468 | test -n "$cf_cv_system_name" && echo "$as_me:1468: result: Configuring for $cf_cv_system_name" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1469 | echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6 |
| 1470 | |
| 1471 | if test ".$system_name" != ".$cf_cv_system_name" ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1472 | echo "$as_me:1472: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1473 | echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1474 | { { echo "$as_me:1474: error: \"Please remove config.cache and try again.\"" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1475 | echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;} |
| 1476 | { (exit 1); exit 1; }; } |
| 1477 | fi |
| 1478 | |
| 1479 | # Check whether --with-system-type or --without-system-type was given. |
| 1480 | if test "${with_system_type+set}" = set; then |
| 1481 | withval="$with_system_type" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1482 | { echo "$as_me:1482: WARNING: overriding system type to $withval" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1483 | echo "$as_me: WARNING: overriding system type to $withval" >&2;} |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1484 | cf_cv_system_name=$withval |
| 1485 | host_os=$withval |
| 1486 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1487 | fi; |
| 1488 | |
| 1489 | ### Save the given $CFLAGS to allow user-override. |
| 1490 | cf_user_CFLAGS="$CFLAGS" |
| 1491 | |
| 1492 | ### Default install-location |
| 1493 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1494 | echo "$as_me:1494: checking for prefix" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1495 | echo $ECHO_N "checking for prefix... $ECHO_C" >&6 |
| 1496 | if test "x$prefix" = "xNONE" ; then |
| 1497 | case "$cf_cv_system_name" in |
| 1498 | # non-vendor systems don't have a conflict |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1499 | (openbsd*|freebsd*|mirbsd*|linux*|cygwin*|msys*|k*bsd*-gnu|mingw*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1500 | prefix=/usr |
| 1501 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1502 | (*) prefix=$ac_default_prefix |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1503 | ;; |
| 1504 | esac |
| 1505 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1506 | echo "$as_me:1506: result: $prefix" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1507 | echo "${ECHO_T}$prefix" >&6 |
| 1508 | |
| 1509 | if test "x$prefix" = "xNONE" ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1510 | echo "$as_me:1510: checking for default include-directory" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1511 | echo $ECHO_N "checking for default include-directory... $ECHO_C" >&6 |
| 1512 | test -n "$verbose" && echo 1>&6 |
| 1513 | for cf_symbol in \ |
| 1514 | $includedir \ |
| 1515 | $includedir/ncurses \ |
| 1516 | $prefix/include \ |
| 1517 | $prefix/include/ncurses \ |
| 1518 | /usr/local/include \ |
| 1519 | /usr/local/include/ncurses \ |
| 1520 | /usr/include \ |
| 1521 | /usr/include/ncurses |
| 1522 | do |
| 1523 | cf_dir=`eval echo $cf_symbol` |
| 1524 | if test -f $cf_dir/curses.h ; then |
| 1525 | if ( fgrep NCURSES_VERSION $cf_dir/curses.h 2>&1 >/dev/null ) ; then |
| 1526 | includedir="$cf_symbol" |
| 1527 | test -n "$verbose" && echo $ac_n " found " 1>&6 |
| 1528 | break |
| 1529 | fi |
| 1530 | fi |
| 1531 | test -n "$verbose" && echo " tested $cf_dir" 1>&6 |
| 1532 | done |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1533 | echo "$as_me:1533: result: $includedir" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1534 | echo "${ECHO_T}$includedir" >&6 |
| 1535 | fi |
| 1536 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1537 | ### Defaults for ncurses ABI |
| 1538 | |
| 1539 | case x$cf_cv_abi_version in |
| 1540 | (x[6789]) |
| 1541 | cf_dft_ext_colors=yes |
| 1542 | cf_dft_ext_const=yes |
| 1543 | cf_dft_ext_mouse=yes |
| 1544 | cf_dft_ext_putwin=yes |
| 1545 | cf_dft_ext_spfuncs=yes |
| 1546 | cf_dft_filter_syms=yes |
| 1547 | cf_dft_chtype=uint32_t |
| 1548 | cf_dft_mmask_t=uint32_t |
| 1549 | cf_dft_interop=yes |
| 1550 | cf_dft_tparm_arg=intptr_t |
| 1551 | cf_dft_with_lp64=yes |
| 1552 | ;; |
| 1553 | (*) |
| 1554 | cf_dft_ext_colors=no |
| 1555 | cf_dft_ext_const=no |
| 1556 | cf_dft_ext_mouse=no |
| 1557 | cf_dft_ext_putwin=no |
| 1558 | cf_dft_ext_spfuncs=no |
| 1559 | cf_dft_filter_syms=no |
| 1560 | cf_dft_chtype=auto |
| 1561 | cf_dft_mmask_t=auto |
| 1562 | cf_dft_interop=no |
| 1563 | cf_dft_tparm_arg=long |
| 1564 | cf_dft_with_lp64=no |
| 1565 | ;; |
| 1566 | esac |
| 1567 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1568 | ### Checks for programs. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1569 | |
| 1570 | # Check whether --with-ada or --without-ada was given. |
| 1571 | if test "${with_ada+set}" = set; then |
| 1572 | withval="$with_ada" |
| 1573 | cf_with_ada=$withval |
| 1574 | else |
| 1575 | cf_with_ada=yes |
| 1576 | fi; |
| 1577 | if test "x$cf_with_ada" = xyes |
| 1578 | then |
| 1579 | cf_PROG_CC="gnatgcc gcc cc" |
| 1580 | else |
| 1581 | cf_PROG_CC="gcc cc" |
| 1582 | fi |
| 1583 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1584 | ac_ext=c |
| 1585 | ac_cpp='$CPP $CPPFLAGS' |
| 1586 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 1587 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 1588 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 1589 | ac_main_return=return |
| 1590 | if test -n "$ac_tool_prefix"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1591 | for ac_prog in $cf_PROG_CC |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1592 | do |
| 1593 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 1594 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1595 | echo "$as_me:1595: checking for $ac_word" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1596 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1597 | if test "${ac_cv_prog_CC+set}" = set; then |
| 1598 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1599 | else |
| 1600 | if test -n "$CC"; then |
| 1601 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 1602 | else |
| 1603 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1604 | ac_dummy="$PATH" |
| 1605 | for ac_dir in $ac_dummy; do |
| 1606 | IFS=$ac_save_IFS |
| 1607 | test -z "$ac_dir" && ac_dir=. |
| 1608 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1609 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1610 | echo "$as_me:1610: found $ac_dir/$ac_word" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1611 | break |
| 1612 | done |
| 1613 | |
| 1614 | fi |
| 1615 | fi |
| 1616 | CC=$ac_cv_prog_CC |
| 1617 | if test -n "$CC"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1618 | echo "$as_me:1618: result: $CC" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1619 | echo "${ECHO_T}$CC" >&6 |
| 1620 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1621 | echo "$as_me:1621: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1622 | echo "${ECHO_T}no" >&6 |
| 1623 | fi |
| 1624 | |
| 1625 | test -n "$CC" && break |
| 1626 | done |
| 1627 | fi |
| 1628 | if test -z "$CC"; then |
| 1629 | ac_ct_CC=$CC |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1630 | for ac_prog in $cf_PROG_CC |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1631 | do |
| 1632 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 1633 | set dummy $ac_prog; ac_word=$2 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1634 | echo "$as_me:1634: checking for $ac_word" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1635 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 1636 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then |
| 1637 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1638 | else |
| 1639 | if test -n "$ac_ct_CC"; then |
| 1640 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 1641 | else |
| 1642 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 1643 | ac_dummy="$PATH" |
| 1644 | for ac_dir in $ac_dummy; do |
| 1645 | IFS=$ac_save_IFS |
| 1646 | test -z "$ac_dir" && ac_dir=. |
| 1647 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 1648 | ac_cv_prog_ac_ct_CC="$ac_prog" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1649 | echo "$as_me:1649: found $ac_dir/$ac_word" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1650 | break |
| 1651 | done |
| 1652 | |
| 1653 | fi |
| 1654 | fi |
| 1655 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 1656 | if test -n "$ac_ct_CC"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1657 | echo "$as_me:1657: result: $ac_ct_CC" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1658 | echo "${ECHO_T}$ac_ct_CC" >&6 |
| 1659 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1660 | echo "$as_me:1660: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1661 | echo "${ECHO_T}no" >&6 |
| 1662 | fi |
| 1663 | |
| 1664 | test -n "$ac_ct_CC" && break |
| 1665 | done |
| 1666 | |
| 1667 | CC=$ac_ct_CC |
| 1668 | fi |
| 1669 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1670 | test -z "$CC" && { { echo "$as_me:1670: error: no acceptable cc found in \$PATH" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1671 | echo "$as_me: error: no acceptable cc found in \$PATH" >&2;} |
| 1672 | { (exit 1); exit 1; }; } |
| 1673 | |
| 1674 | # Provide some information about the compiler. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1675 | echo "$as_me:1675:" \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1676 | "checking for C compiler version" >&5 |
| 1677 | ac_compiler=`set X $ac_compile; echo $2` |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1678 | { (eval echo "$as_me:1678: \"$ac_compiler --version </dev/null >&5\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1679 | (eval $ac_compiler --version </dev/null >&5) 2>&5 |
| 1680 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1681 | echo "$as_me:1681: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1682 | (exit $ac_status); } |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1683 | { (eval echo "$as_me:1683: \"$ac_compiler -v </dev/null >&5\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1684 | (eval $ac_compiler -v </dev/null >&5) 2>&5 |
| 1685 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1686 | echo "$as_me:1686: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1687 | (exit $ac_status); } |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1688 | { (eval echo "$as_me:1688: \"$ac_compiler -V </dev/null >&5\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1689 | (eval $ac_compiler -V </dev/null >&5) 2>&5 |
| 1690 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1691 | echo "$as_me:1691: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1692 | (exit $ac_status); } |
| 1693 | |
| 1694 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1695 | #line 1695 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1696 | #include "confdefs.h" |
| 1697 | |
| 1698 | int |
| 1699 | main () |
| 1700 | { |
| 1701 | |
| 1702 | ; |
| 1703 | return 0; |
| 1704 | } |
| 1705 | _ACEOF |
| 1706 | ac_clean_files_save=$ac_clean_files |
| 1707 | ac_clean_files="$ac_clean_files a.out a.exe" |
| 1708 | # Try to create an executable without -o first, disregard a.out. |
| 1709 | # It will help us diagnose broken compilers, and finding out an intuition |
| 1710 | # of exeext. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1711 | echo "$as_me:1711: checking for C compiler default output" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1712 | echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6 |
| 1713 | ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1714 | if { (eval echo "$as_me:1714: \"$ac_link_default\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1715 | (eval $ac_link_default) 2>&5 |
| 1716 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1717 | echo "$as_me:1717: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1718 | (exit $ac_status); }; then |
| 1719 | # Find the output, starting from the most likely. This scheme is |
| 1720 | # not robust to junk in `.', hence go to wildcards (a.*) only as a last |
| 1721 | # resort. |
| 1722 | for ac_file in `ls a.exe conftest.exe 2>/dev/null; |
| 1723 | ls a.out conftest 2>/dev/null; |
| 1724 | ls a.* conftest.* 2>/dev/null`; do |
| 1725 | case $ac_file in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1726 | *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1727 | a.out ) # We found the default executable, but exeext='' is most |
| 1728 | # certainly right. |
| 1729 | break;; |
| 1730 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 1731 | # FIXME: I believe we export ac_cv_exeext for Libtool --akim. |
| 1732 | export ac_cv_exeext |
| 1733 | break;; |
| 1734 | * ) break;; |
| 1735 | esac |
| 1736 | done |
| 1737 | else |
| 1738 | echo "$as_me: failed program was:" >&5 |
| 1739 | cat conftest.$ac_ext >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1740 | { { echo "$as_me:1740: error: C compiler cannot create executables" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1741 | echo "$as_me: error: C compiler cannot create executables" >&2;} |
| 1742 | { (exit 77); exit 77; }; } |
| 1743 | fi |
| 1744 | |
| 1745 | ac_exeext=$ac_cv_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1746 | echo "$as_me:1746: result: $ac_file" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1747 | echo "${ECHO_T}$ac_file" >&6 |
| 1748 | |
| 1749 | # Check the compiler produces executables we can run. If not, either |
| 1750 | # the compiler is broken, or we cross compile. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1751 | echo "$as_me:1751: checking whether the C compiler works" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1752 | echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6 |
| 1753 | # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 |
| 1754 | # If not cross compiling, check that we can run a simple program. |
| 1755 | if test "$cross_compiling" != yes; then |
| 1756 | if { ac_try='./$ac_file' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1757 | { (eval echo "$as_me:1757: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1758 | (eval $ac_try) 2>&5 |
| 1759 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1760 | echo "$as_me:1760: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1761 | (exit $ac_status); }; }; then |
| 1762 | cross_compiling=no |
| 1763 | else |
| 1764 | if test "$cross_compiling" = maybe; then |
| 1765 | cross_compiling=yes |
| 1766 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1767 | { { echo "$as_me:1767: error: cannot run C compiled programs. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1768 | If you meant to cross compile, use \`--host'." >&5 |
| 1769 | echo "$as_me: error: cannot run C compiled programs. |
| 1770 | If you meant to cross compile, use \`--host'." >&2;} |
| 1771 | { (exit 1); exit 1; }; } |
| 1772 | fi |
| 1773 | fi |
| 1774 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1775 | echo "$as_me:1775: result: yes" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1776 | echo "${ECHO_T}yes" >&6 |
| 1777 | |
| 1778 | rm -f a.out a.exe conftest$ac_cv_exeext |
| 1779 | ac_clean_files=$ac_clean_files_save |
| 1780 | # Check the compiler produces executables we can run. If not, either |
| 1781 | # the compiler is broken, or we cross compile. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1782 | echo "$as_me:1782: checking whether we are cross compiling" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1783 | echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1784 | echo "$as_me:1784: result: $cross_compiling" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1785 | echo "${ECHO_T}$cross_compiling" >&6 |
| 1786 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1787 | echo "$as_me:1787: checking for executable suffix" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1788 | echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1789 | if { (eval echo "$as_me:1789: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1790 | (eval $ac_link) 2>&5 |
| 1791 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1792 | echo "$as_me:1792: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1793 | (exit $ac_status); }; then |
| 1794 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 1795 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 1796 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 1797 | # `rm'. |
| 1798 | for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do |
| 1799 | case $ac_file in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1800 | *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1801 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 1802 | export ac_cv_exeext |
| 1803 | break;; |
| 1804 | * ) break;; |
| 1805 | esac |
| 1806 | done |
| 1807 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1808 | { { echo "$as_me:1808: error: cannot compute EXEEXT: cannot compile and link" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1809 | echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;} |
| 1810 | { (exit 1); exit 1; }; } |
| 1811 | fi |
| 1812 | |
| 1813 | rm -f conftest$ac_cv_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1814 | echo "$as_me:1814: result: $ac_cv_exeext" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1815 | echo "${ECHO_T}$ac_cv_exeext" >&6 |
| 1816 | |
| 1817 | rm -f conftest.$ac_ext |
| 1818 | EXEEXT=$ac_cv_exeext |
| 1819 | ac_exeext=$EXEEXT |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1820 | echo "$as_me:1820: checking for object suffix" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1821 | echo $ECHO_N "checking for object suffix... $ECHO_C" >&6 |
| 1822 | if test "${ac_cv_objext+set}" = set; then |
| 1823 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1824 | else |
| 1825 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1826 | #line 1826 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1827 | #include "confdefs.h" |
| 1828 | |
| 1829 | int |
| 1830 | main () |
| 1831 | { |
| 1832 | |
| 1833 | ; |
| 1834 | return 0; |
| 1835 | } |
| 1836 | _ACEOF |
| 1837 | rm -f conftest.o conftest.obj |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1838 | if { (eval echo "$as_me:1838: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1839 | (eval $ac_compile) 2>&5 |
| 1840 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1841 | echo "$as_me:1841: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1842 | (exit $ac_status); }; then |
| 1843 | for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do |
| 1844 | case $ac_file in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1845 | *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1846 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 1847 | break;; |
| 1848 | esac |
| 1849 | done |
| 1850 | else |
| 1851 | echo "$as_me: failed program was:" >&5 |
| 1852 | cat conftest.$ac_ext >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1853 | { { echo "$as_me:1853: error: cannot compute OBJEXT: cannot compile" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1854 | echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;} |
| 1855 | { (exit 1); exit 1; }; } |
| 1856 | fi |
| 1857 | |
| 1858 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
| 1859 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1860 | echo "$as_me:1860: result: $ac_cv_objext" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1861 | echo "${ECHO_T}$ac_cv_objext" >&6 |
| 1862 | OBJEXT=$ac_cv_objext |
| 1863 | ac_objext=$OBJEXT |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1864 | echo "$as_me:1864: checking whether we are using the GNU C compiler" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1865 | echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6 |
| 1866 | if test "${ac_cv_c_compiler_gnu+set}" = set; then |
| 1867 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1868 | else |
| 1869 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1870 | #line 1870 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1871 | #include "confdefs.h" |
| 1872 | |
| 1873 | int |
| 1874 | main () |
| 1875 | { |
| 1876 | #ifndef __GNUC__ |
| 1877 | choke me |
| 1878 | #endif |
| 1879 | |
| 1880 | ; |
| 1881 | return 0; |
| 1882 | } |
| 1883 | _ACEOF |
| 1884 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1885 | if { (eval echo "$as_me:1885: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1886 | (eval $ac_compile) 2>&5 |
| 1887 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1888 | echo "$as_me:1888: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1889 | (exit $ac_status); } && |
| 1890 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1891 | { (eval echo "$as_me:1891: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1892 | (eval $ac_try) 2>&5 |
| 1893 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1894 | echo "$as_me:1894: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1895 | (exit $ac_status); }; }; then |
| 1896 | ac_compiler_gnu=yes |
| 1897 | else |
| 1898 | echo "$as_me: failed program was:" >&5 |
| 1899 | cat conftest.$ac_ext >&5 |
| 1900 | ac_compiler_gnu=no |
| 1901 | fi |
| 1902 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 1903 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 1904 | |
| 1905 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1906 | echo "$as_me:1906: result: $ac_cv_c_compiler_gnu" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1907 | echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6 |
| 1908 | GCC=`test $ac_compiler_gnu = yes && echo yes` |
| 1909 | ac_test_CFLAGS=${CFLAGS+set} |
| 1910 | ac_save_CFLAGS=$CFLAGS |
| 1911 | CFLAGS="-g" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1912 | echo "$as_me:1912: checking whether $CC accepts -g" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1913 | echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6 |
| 1914 | if test "${ac_cv_prog_cc_g+set}" = set; then |
| 1915 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 1916 | else |
| 1917 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1918 | #line 1918 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1919 | #include "confdefs.h" |
| 1920 | |
| 1921 | int |
| 1922 | main () |
| 1923 | { |
| 1924 | |
| 1925 | ; |
| 1926 | return 0; |
| 1927 | } |
| 1928 | _ACEOF |
| 1929 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1930 | if { (eval echo "$as_me:1930: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1931 | (eval $ac_compile) 2>&5 |
| 1932 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1933 | echo "$as_me:1933: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1934 | (exit $ac_status); } && |
| 1935 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1936 | { (eval echo "$as_me:1936: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1937 | (eval $ac_try) 2>&5 |
| 1938 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1939 | echo "$as_me:1939: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1940 | (exit $ac_status); }; }; then |
| 1941 | ac_cv_prog_cc_g=yes |
| 1942 | else |
| 1943 | echo "$as_me: failed program was:" >&5 |
| 1944 | cat conftest.$ac_ext >&5 |
| 1945 | ac_cv_prog_cc_g=no |
| 1946 | fi |
| 1947 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 1948 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1949 | echo "$as_me:1949: result: $ac_cv_prog_cc_g" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1950 | echo "${ECHO_T}$ac_cv_prog_cc_g" >&6 |
| 1951 | if test "$ac_test_CFLAGS" = set; then |
| 1952 | CFLAGS=$ac_save_CFLAGS |
| 1953 | elif test $ac_cv_prog_cc_g = yes; then |
| 1954 | if test "$GCC" = yes; then |
| 1955 | CFLAGS="-g -O2" |
| 1956 | else |
| 1957 | CFLAGS="-g" |
| 1958 | fi |
| 1959 | else |
| 1960 | if test "$GCC" = yes; then |
| 1961 | CFLAGS="-O2" |
| 1962 | else |
| 1963 | CFLAGS= |
| 1964 | fi |
| 1965 | fi |
| 1966 | # Some people use a C++ compiler to compile C. Since we use `exit', |
| 1967 | # in C++ we need to declare it. In case someone uses the same compiler |
| 1968 | # for both compiling C and C++ we need to have the C++ compiler decide |
| 1969 | # the declaration of exit, since it's the most demanding environment. |
| 1970 | cat >conftest.$ac_ext <<_ACEOF |
| 1971 | #ifndef __cplusplus |
| 1972 | choke me |
| 1973 | #endif |
| 1974 | _ACEOF |
| 1975 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1976 | if { (eval echo "$as_me:1976: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1977 | (eval $ac_compile) 2>&5 |
| 1978 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1979 | echo "$as_me:1979: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1980 | (exit $ac_status); } && |
| 1981 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1982 | { (eval echo "$as_me:1982: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1983 | (eval $ac_try) 2>&5 |
| 1984 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1985 | echo "$as_me:1985: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1986 | (exit $ac_status); }; }; then |
| 1987 | for ac_declaration in \ |
| 1988 | ''\ |
| 1989 | '#include <stdlib.h>' \ |
| 1990 | 'extern "C" void std::exit (int) throw (); using std::exit;' \ |
| 1991 | 'extern "C" void std::exit (int); using std::exit;' \ |
| 1992 | 'extern "C" void exit (int) throw ();' \ |
| 1993 | 'extern "C" void exit (int);' \ |
| 1994 | 'void exit (int);' |
| 1995 | do |
| 1996 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 1997 | #line 1997 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 1998 | #include "confdefs.h" |
| 1999 | #include <stdlib.h> |
| 2000 | $ac_declaration |
| 2001 | int |
| 2002 | main () |
| 2003 | { |
| 2004 | exit (42); |
| 2005 | ; |
| 2006 | return 0; |
| 2007 | } |
| 2008 | _ACEOF |
| 2009 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2010 | if { (eval echo "$as_me:2010: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2011 | (eval $ac_compile) 2>&5 |
| 2012 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2013 | echo "$as_me:2013: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2014 | (exit $ac_status); } && |
| 2015 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2016 | { (eval echo "$as_me:2016: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2017 | (eval $ac_try) 2>&5 |
| 2018 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2019 | echo "$as_me:2019: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2020 | (exit $ac_status); }; }; then |
| 2021 | : |
| 2022 | else |
| 2023 | echo "$as_me: failed program was:" >&5 |
| 2024 | cat conftest.$ac_ext >&5 |
| 2025 | continue |
| 2026 | fi |
| 2027 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2028 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2029 | #line 2029 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2030 | #include "confdefs.h" |
| 2031 | $ac_declaration |
| 2032 | int |
| 2033 | main () |
| 2034 | { |
| 2035 | exit (42); |
| 2036 | ; |
| 2037 | return 0; |
| 2038 | } |
| 2039 | _ACEOF |
| 2040 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2041 | if { (eval echo "$as_me:2041: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2042 | (eval $ac_compile) 2>&5 |
| 2043 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2044 | echo "$as_me:2044: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2045 | (exit $ac_status); } && |
| 2046 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2047 | { (eval echo "$as_me:2047: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2048 | (eval $ac_try) 2>&5 |
| 2049 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2050 | echo "$as_me:2050: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2051 | (exit $ac_status); }; }; then |
| 2052 | break |
| 2053 | else |
| 2054 | echo "$as_me: failed program was:" >&5 |
| 2055 | cat conftest.$ac_ext >&5 |
| 2056 | fi |
| 2057 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2058 | done |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2059 | rm -rf conftest* |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2060 | if test -n "$ac_declaration"; then |
| 2061 | echo '#ifdef __cplusplus' >>confdefs.h |
| 2062 | echo $ac_declaration >>confdefs.h |
| 2063 | echo '#endif' >>confdefs.h |
| 2064 | fi |
| 2065 | |
| 2066 | else |
| 2067 | echo "$as_me: failed program was:" >&5 |
| 2068 | cat conftest.$ac_ext >&5 |
| 2069 | fi |
| 2070 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2071 | ac_ext=c |
| 2072 | ac_cpp='$CPP $CPPFLAGS' |
| 2073 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2074 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2075 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2076 | ac_main_return=return |
| 2077 | |
| 2078 | GCC_VERSION=none |
| 2079 | if test "$GCC" = yes ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2080 | echo "$as_me:2080: checking version of $CC" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2081 | echo $ECHO_N "checking version of $CC... $ECHO_C" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2082 | 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.].*//'`" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2083 | test -z "$GCC_VERSION" && GCC_VERSION=unknown |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2084 | echo "$as_me:2084: result: $GCC_VERSION" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2085 | echo "${ECHO_T}$GCC_VERSION" >&6 |
| 2086 | fi |
| 2087 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2088 | echo "$as_me:2088: checking for $CC option to accept ANSI C" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2089 | echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6 |
| 2090 | if test "${ac_cv_prog_cc_stdc+set}" = set; then |
| 2091 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2092 | else |
| 2093 | ac_cv_prog_cc_stdc=no |
| 2094 | ac_save_CC=$CC |
| 2095 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2096 | #line 2096 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2097 | #include "confdefs.h" |
| 2098 | #include <stdarg.h> |
| 2099 | #include <stdio.h> |
| 2100 | #include <sys/types.h> |
| 2101 | #include <sys/stat.h> |
| 2102 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 2103 | struct buf { int x; }; |
| 2104 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 2105 | static char *e (p, i) |
| 2106 | char **p; |
| 2107 | int i; |
| 2108 | { |
| 2109 | return p[i]; |
| 2110 | } |
| 2111 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 2112 | { |
| 2113 | char *s; |
| 2114 | va_list v; |
| 2115 | va_start (v,p); |
| 2116 | s = g (p, va_arg (v,int)); |
| 2117 | va_end (v); |
| 2118 | return s; |
| 2119 | } |
| 2120 | int test (int i, double x); |
| 2121 | struct s1 {int (*f) (int a);}; |
| 2122 | struct s2 {int (*f) (double a);}; |
| 2123 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 2124 | int argc; |
| 2125 | char **argv; |
| 2126 | int |
| 2127 | main () |
| 2128 | { |
| 2129 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 2130 | ; |
| 2131 | return 0; |
| 2132 | } |
| 2133 | _ACEOF |
| 2134 | # Don't try gcc -ansi; that turns off useful extensions and |
| 2135 | # breaks some systems' header files. |
| 2136 | # AIX -qlanglvl=ansi |
| 2137 | # Ultrix and OSF/1 -std1 |
| 2138 | # HP-UX 10.20 and later -Ae |
| 2139 | # HP-UX older versions -Aa -D_HPUX_SOURCE |
| 2140 | # SVR4 -Xc -D__EXTENSIONS__ |
| 2141 | for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
| 2142 | do |
| 2143 | CC="$ac_save_CC $ac_arg" |
| 2144 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2145 | if { (eval echo "$as_me:2145: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2146 | (eval $ac_compile) 2>&5 |
| 2147 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2148 | echo "$as_me:2148: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2149 | (exit $ac_status); } && |
| 2150 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2151 | { (eval echo "$as_me:2151: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2152 | (eval $ac_try) 2>&5 |
| 2153 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2154 | echo "$as_me:2154: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2155 | (exit $ac_status); }; }; then |
| 2156 | ac_cv_prog_cc_stdc=$ac_arg |
| 2157 | break |
| 2158 | else |
| 2159 | echo "$as_me: failed program was:" >&5 |
| 2160 | cat conftest.$ac_ext >&5 |
| 2161 | fi |
| 2162 | rm -f conftest.$ac_objext |
| 2163 | done |
| 2164 | rm -f conftest.$ac_ext conftest.$ac_objext |
| 2165 | CC=$ac_save_CC |
| 2166 | |
| 2167 | fi |
| 2168 | |
| 2169 | case "x$ac_cv_prog_cc_stdc" in |
| 2170 | x|xno) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2171 | echo "$as_me:2171: result: none needed" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2172 | echo "${ECHO_T}none needed" >&6 ;; |
| 2173 | *) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2174 | echo "$as_me:2174: result: $ac_cv_prog_cc_stdc" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 2175 | echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6 |
| 2176 | CC="$CC $ac_cv_prog_cc_stdc" ;; |
| 2177 | esac |
| 2178 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 2179 | # This should have been defined by AC_PROG_CC |
| 2180 | : ${CC:=cc} |
| 2181 | |
| 2182 | echo "$as_me:2182: checking \$CC variable" >&5 |
| 2183 | echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6 |
| 2184 | case "$CC" in |
| 2185 | (*[\ \ ]-[IUD]*) |
| 2186 | echo "$as_me:2186: result: broken" >&5 |
| 2187 | echo "${ECHO_T}broken" >&6 |
| 2188 | { echo "$as_me:2188: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5 |
| 2189 | echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;} |
| 2190 | # humor him... |
| 2191 | cf_flags=`echo "$CC" | sed -e 's/^[^ ]*[ ]//'` |
| 2192 | CC=`echo "$CC" | sed -e 's/[ ].*//'` |
| 2193 | |
| 2194 | cf_fix_cppflags=no |
| 2195 | cf_new_cflags= |
| 2196 | cf_new_cppflags= |
| 2197 | cf_new_extra_cppflags= |
| 2198 | |
| 2199 | for cf_add_cflags in $cf_flags |
| 2200 | do |
| 2201 | case $cf_fix_cppflags in |
| 2202 | (no) |
| 2203 | case $cf_add_cflags in |
| 2204 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 2205 | case $cf_add_cflags in |
| 2206 | (-D*) |
| 2207 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 2208 | |
| 2209 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 2210 | && test -z "${cf_tst_cflags}" \ |
| 2211 | && cf_fix_cppflags=yes |
| 2212 | |
| 2213 | if test $cf_fix_cppflags = yes ; then |
| 2214 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 2215 | continue |
| 2216 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 2217 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 2218 | continue |
| 2219 | fi |
| 2220 | ;; |
| 2221 | esac |
| 2222 | case "$CPPFLAGS" in |
| 2223 | (*$cf_add_cflags) |
| 2224 | ;; |
| 2225 | (*) |
| 2226 | case $cf_add_cflags in |
| 2227 | (-D*) |
| 2228 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 2229 | |
| 2230 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 2231 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 2232 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 2233 | |
| 2234 | ;; |
| 2235 | esac |
| 2236 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 2237 | ;; |
| 2238 | esac |
| 2239 | ;; |
| 2240 | (*) |
| 2241 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 2242 | ;; |
| 2243 | esac |
| 2244 | ;; |
| 2245 | (yes) |
| 2246 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 2247 | |
| 2248 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 2249 | |
| 2250 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 2251 | && test -z "${cf_tst_cflags}" \ |
| 2252 | && cf_fix_cppflags=no |
| 2253 | ;; |
| 2254 | esac |
| 2255 | done |
| 2256 | |
| 2257 | if test -n "$cf_new_cflags" ; then |
| 2258 | |
| 2259 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 2260 | fi |
| 2261 | |
| 2262 | if test -n "$cf_new_cppflags" ; then |
| 2263 | |
| 2264 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 2265 | fi |
| 2266 | |
| 2267 | if test -n "$cf_new_extra_cppflags" ; then |
| 2268 | |
| 2269 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 2270 | fi |
| 2271 | |
| 2272 | ;; |
| 2273 | (*) |
| 2274 | echo "$as_me:2274: result: ok" >&5 |
| 2275 | echo "${ECHO_T}ok" >&6 |
| 2276 | ;; |
| 2277 | esac |
| 2278 | |
| 2279 | ac_ext=c |
| 2280 | ac_cpp='$CPP $CPPFLAGS' |
| 2281 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2282 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2283 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2284 | ac_main_return=return |
| 2285 | echo "$as_me:2285: checking how to run the C preprocessor" >&5 |
| 2286 | echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6 |
| 2287 | # On Suns, sometimes $CPP names a directory. |
| 2288 | if test -n "$CPP" && test -d "$CPP"; then |
| 2289 | CPP= |
| 2290 | fi |
| 2291 | if test -z "$CPP"; then |
| 2292 | if test "${ac_cv_prog_CPP+set}" = set; then |
| 2293 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2294 | else |
| 2295 | # Double quotes because CPP needs to be expanded |
| 2296 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 2297 | do |
| 2298 | ac_preproc_ok=false |
| 2299 | for ac_c_preproc_warn_flag in '' yes |
| 2300 | do |
| 2301 | # Use a header file that comes with gcc, so configuring glibc |
| 2302 | # with a fresh cross-compiler works. |
| 2303 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 2304 | # not just through cpp. "Syntax error" is here to catch this case. |
| 2305 | cat >conftest.$ac_ext <<_ACEOF |
| 2306 | #line 2306 "configure" |
| 2307 | #include "confdefs.h" |
| 2308 | #include <assert.h> |
| 2309 | Syntax error |
| 2310 | _ACEOF |
| 2311 | if { (eval echo "$as_me:2311: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 2312 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 2313 | ac_status=$? |
| 2314 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 2315 | rm -f conftest.er1 |
| 2316 | cat conftest.err >&5 |
| 2317 | echo "$as_me:2317: \$? = $ac_status" >&5 |
| 2318 | (exit $ac_status); } >/dev/null; then |
| 2319 | if test -s conftest.err; then |
| 2320 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 2321 | else |
| 2322 | ac_cpp_err= |
| 2323 | fi |
| 2324 | else |
| 2325 | ac_cpp_err=yes |
| 2326 | fi |
| 2327 | if test -z "$ac_cpp_err"; then |
| 2328 | : |
| 2329 | else |
| 2330 | echo "$as_me: failed program was:" >&5 |
| 2331 | cat conftest.$ac_ext >&5 |
| 2332 | # Broken: fails on valid input. |
| 2333 | continue |
| 2334 | fi |
| 2335 | rm -f conftest.err conftest.$ac_ext |
| 2336 | |
| 2337 | # OK, works on sane cases. Now check whether non-existent headers |
| 2338 | # can be detected and how. |
| 2339 | cat >conftest.$ac_ext <<_ACEOF |
| 2340 | #line 2340 "configure" |
| 2341 | #include "confdefs.h" |
| 2342 | #include <ac_nonexistent.h> |
| 2343 | _ACEOF |
| 2344 | if { (eval echo "$as_me:2344: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 2345 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 2346 | ac_status=$? |
| 2347 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 2348 | rm -f conftest.er1 |
| 2349 | cat conftest.err >&5 |
| 2350 | echo "$as_me:2350: \$? = $ac_status" >&5 |
| 2351 | (exit $ac_status); } >/dev/null; then |
| 2352 | if test -s conftest.err; then |
| 2353 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 2354 | else |
| 2355 | ac_cpp_err= |
| 2356 | fi |
| 2357 | else |
| 2358 | ac_cpp_err=yes |
| 2359 | fi |
| 2360 | if test -z "$ac_cpp_err"; then |
| 2361 | # Broken: success on invalid input. |
| 2362 | continue |
| 2363 | else |
| 2364 | echo "$as_me: failed program was:" >&5 |
| 2365 | cat conftest.$ac_ext >&5 |
| 2366 | # Passes both tests. |
| 2367 | ac_preproc_ok=: |
| 2368 | break |
| 2369 | fi |
| 2370 | rm -f conftest.err conftest.$ac_ext |
| 2371 | |
| 2372 | done |
| 2373 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
| 2374 | rm -f conftest.err conftest.$ac_ext |
| 2375 | if $ac_preproc_ok; then |
| 2376 | break |
| 2377 | fi |
| 2378 | |
| 2379 | done |
| 2380 | ac_cv_prog_CPP=$CPP |
| 2381 | |
| 2382 | fi |
| 2383 | CPP=$ac_cv_prog_CPP |
| 2384 | else |
| 2385 | ac_cv_prog_CPP=$CPP |
| 2386 | fi |
| 2387 | echo "$as_me:2387: result: $CPP" >&5 |
| 2388 | echo "${ECHO_T}$CPP" >&6 |
| 2389 | ac_preproc_ok=false |
| 2390 | for ac_c_preproc_warn_flag in '' yes |
| 2391 | do |
| 2392 | # Use a header file that comes with gcc, so configuring glibc |
| 2393 | # with a fresh cross-compiler works. |
| 2394 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 2395 | # not just through cpp. "Syntax error" is here to catch this case. |
| 2396 | cat >conftest.$ac_ext <<_ACEOF |
| 2397 | #line 2397 "configure" |
| 2398 | #include "confdefs.h" |
| 2399 | #include <assert.h> |
| 2400 | Syntax error |
| 2401 | _ACEOF |
| 2402 | if { (eval echo "$as_me:2402: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 2403 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 2404 | ac_status=$? |
| 2405 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 2406 | rm -f conftest.er1 |
| 2407 | cat conftest.err >&5 |
| 2408 | echo "$as_me:2408: \$? = $ac_status" >&5 |
| 2409 | (exit $ac_status); } >/dev/null; then |
| 2410 | if test -s conftest.err; then |
| 2411 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 2412 | else |
| 2413 | ac_cpp_err= |
| 2414 | fi |
| 2415 | else |
| 2416 | ac_cpp_err=yes |
| 2417 | fi |
| 2418 | if test -z "$ac_cpp_err"; then |
| 2419 | : |
| 2420 | else |
| 2421 | echo "$as_me: failed program was:" >&5 |
| 2422 | cat conftest.$ac_ext >&5 |
| 2423 | # Broken: fails on valid input. |
| 2424 | continue |
| 2425 | fi |
| 2426 | rm -f conftest.err conftest.$ac_ext |
| 2427 | |
| 2428 | # OK, works on sane cases. Now check whether non-existent headers |
| 2429 | # can be detected and how. |
| 2430 | cat >conftest.$ac_ext <<_ACEOF |
| 2431 | #line 2431 "configure" |
| 2432 | #include "confdefs.h" |
| 2433 | #include <ac_nonexistent.h> |
| 2434 | _ACEOF |
| 2435 | if { (eval echo "$as_me:2435: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 2436 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 2437 | ac_status=$? |
| 2438 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 2439 | rm -f conftest.er1 |
| 2440 | cat conftest.err >&5 |
| 2441 | echo "$as_me:2441: \$? = $ac_status" >&5 |
| 2442 | (exit $ac_status); } >/dev/null; then |
| 2443 | if test -s conftest.err; then |
| 2444 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 2445 | else |
| 2446 | ac_cpp_err= |
| 2447 | fi |
| 2448 | else |
| 2449 | ac_cpp_err=yes |
| 2450 | fi |
| 2451 | if test -z "$ac_cpp_err"; then |
| 2452 | # Broken: success on invalid input. |
| 2453 | continue |
| 2454 | else |
| 2455 | echo "$as_me: failed program was:" >&5 |
| 2456 | cat conftest.$ac_ext >&5 |
| 2457 | # Passes both tests. |
| 2458 | ac_preproc_ok=: |
| 2459 | break |
| 2460 | fi |
| 2461 | rm -f conftest.err conftest.$ac_ext |
| 2462 | |
| 2463 | done |
| 2464 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
| 2465 | rm -f conftest.err conftest.$ac_ext |
| 2466 | if $ac_preproc_ok; then |
| 2467 | : |
| 2468 | else |
| 2469 | { { echo "$as_me:2469: error: C preprocessor \"$CPP\" fails sanity check" >&5 |
| 2470 | echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;} |
| 2471 | { (exit 1); exit 1; }; } |
| 2472 | fi |
| 2473 | |
| 2474 | ac_ext=c |
| 2475 | ac_cpp='$CPP $CPPFLAGS' |
| 2476 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2477 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2478 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2479 | ac_main_return=return |
| 2480 | |
| 2481 | if test $ac_cv_c_compiler_gnu = yes; then |
| 2482 | echo "$as_me:2482: checking whether $CC needs -traditional" >&5 |
| 2483 | echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6 |
| 2484 | if test "${ac_cv_prog_gcc_traditional+set}" = set; then |
| 2485 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2486 | else |
| 2487 | ac_pattern="Autoconf.*'x'" |
| 2488 | cat >conftest.$ac_ext <<_ACEOF |
| 2489 | #line 2489 "configure" |
| 2490 | #include "confdefs.h" |
| 2491 | #include <sgtty.h> |
| 2492 | int Autoconf = TIOCGETP; |
| 2493 | _ACEOF |
| 2494 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 2495 | egrep "$ac_pattern" >/dev/null 2>&1; then |
| 2496 | ac_cv_prog_gcc_traditional=yes |
| 2497 | else |
| 2498 | ac_cv_prog_gcc_traditional=no |
| 2499 | fi |
| 2500 | rm -rf conftest* |
| 2501 | |
| 2502 | if test $ac_cv_prog_gcc_traditional = no; then |
| 2503 | cat >conftest.$ac_ext <<_ACEOF |
| 2504 | #line 2504 "configure" |
| 2505 | #include "confdefs.h" |
| 2506 | #include <termio.h> |
| 2507 | int Autoconf = TCGETA; |
| 2508 | _ACEOF |
| 2509 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 2510 | egrep "$ac_pattern" >/dev/null 2>&1; then |
| 2511 | ac_cv_prog_gcc_traditional=yes |
| 2512 | fi |
| 2513 | rm -rf conftest* |
| 2514 | |
| 2515 | fi |
| 2516 | fi |
| 2517 | echo "$as_me:2517: result: $ac_cv_prog_gcc_traditional" >&5 |
| 2518 | echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6 |
| 2519 | if test $ac_cv_prog_gcc_traditional = yes; then |
| 2520 | CC="$CC -traditional" |
| 2521 | fi |
| 2522 | fi |
| 2523 | |
| 2524 | echo "$as_me:2524: checking whether $CC understands -c and -o together" >&5 |
| 2525 | echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6 |
| 2526 | if test "${cf_cv_prog_CC_c_o+set}" = set; then |
| 2527 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2528 | else |
| 2529 | |
| 2530 | cat > conftest.$ac_ext <<CF_EOF |
| 2531 | #include <stdio.h> |
| 2532 | int main() |
| 2533 | { |
| 2534 | ${cf_cv_main_return:-return}(0); |
| 2535 | } |
| 2536 | CF_EOF |
| 2537 | # We do the test twice because some compilers refuse to overwrite an |
| 2538 | # existing .o file with -o, though they will create one. |
| 2539 | ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5' |
| 2540 | if { (eval echo "$as_me:2540: \"$ac_try\"") >&5 |
| 2541 | (eval $ac_try) 2>&5 |
| 2542 | ac_status=$? |
| 2543 | echo "$as_me:2543: \$? = $ac_status" >&5 |
| 2544 | (exit $ac_status); } && |
| 2545 | test -f conftest2.$ac_objext && { (eval echo "$as_me:2545: \"$ac_try\"") >&5 |
| 2546 | (eval $ac_try) 2>&5 |
| 2547 | ac_status=$? |
| 2548 | echo "$as_me:2548: \$? = $ac_status" >&5 |
| 2549 | (exit $ac_status); }; |
| 2550 | then |
| 2551 | eval cf_cv_prog_CC_c_o=yes |
| 2552 | else |
| 2553 | eval cf_cv_prog_CC_c_o=no |
| 2554 | fi |
| 2555 | rm -rf conftest* |
| 2556 | |
| 2557 | fi |
| 2558 | if test $cf_cv_prog_CC_c_o = yes; then |
| 2559 | echo "$as_me:2559: result: yes" >&5 |
| 2560 | echo "${ECHO_T}yes" >&6 |
| 2561 | else |
| 2562 | echo "$as_me:2562: result: no" >&5 |
| 2563 | echo "${ECHO_T}no" >&6 |
| 2564 | fi |
| 2565 | |
| 2566 | if test "$cross_compiling" = yes ; then |
| 2567 | LDCONFIG=: |
| 2568 | else |
| 2569 | case "$cf_cv_system_name" in |
| 2570 | (dragonfly*|mirbsd*|freebsd*) |
| 2571 | test -z "$LDCONFIG" && LDCONFIG="/sbin/ldconfig -R" |
| 2572 | ;; |
| 2573 | (*) LDPATH=$PATH:/sbin:/usr/sbin |
| 2574 | # Extract the first word of "ldconfig", so it can be a program name with args. |
| 2575 | set dummy ldconfig; ac_word=$2 |
| 2576 | echo "$as_me:2576: checking for $ac_word" >&5 |
| 2577 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2578 | if test "${ac_cv_path_LDCONFIG+set}" = set; then |
| 2579 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2580 | else |
| 2581 | case $LDCONFIG in |
| 2582 | [\\/]* | ?:[\\/]*) |
| 2583 | ac_cv_path_LDCONFIG="$LDCONFIG" # Let the user override the test with a path. |
| 2584 | ;; |
| 2585 | *) |
| 2586 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2587 | ac_dummy="$LDPATH" |
| 2588 | for ac_dir in $ac_dummy; do |
| 2589 | IFS=$ac_save_IFS |
| 2590 | test -z "$ac_dir" && ac_dir=. |
| 2591 | if $as_executable_p "$ac_dir/$ac_word"; then |
| 2592 | ac_cv_path_LDCONFIG="$ac_dir/$ac_word" |
| 2593 | echo "$as_me:2593: found $ac_dir/$ac_word" >&5 |
| 2594 | break |
| 2595 | fi |
| 2596 | done |
| 2597 | |
| 2598 | ;; |
| 2599 | esac |
| 2600 | fi |
| 2601 | LDCONFIG=$ac_cv_path_LDCONFIG |
| 2602 | |
| 2603 | if test -n "$LDCONFIG"; then |
| 2604 | echo "$as_me:2604: result: $LDCONFIG" >&5 |
| 2605 | echo "${ECHO_T}$LDCONFIG" >&6 |
| 2606 | else |
| 2607 | echo "$as_me:2607: result: no" >&5 |
| 2608 | echo "${ECHO_T}no" >&6 |
| 2609 | fi |
| 2610 | |
| 2611 | ;; |
| 2612 | esac |
| 2613 | fi |
| 2614 | |
| 2615 | echo "$as_me:2615: checking if you want to ensure bool is consistent with C++" >&5 |
| 2616 | echo $ECHO_N "checking if you want to ensure bool is consistent with C++... $ECHO_C" >&6 |
| 2617 | |
| 2618 | # Check whether --with-cxx or --without-cxx was given. |
| 2619 | if test "${with_cxx+set}" = set; then |
| 2620 | withval="$with_cxx" |
| 2621 | cf_with_cxx=$withval |
| 2622 | else |
| 2623 | cf_with_cxx=yes |
| 2624 | fi; |
| 2625 | echo "$as_me:2625: result: $cf_with_cxx" >&5 |
| 2626 | echo "${ECHO_T}$cf_with_cxx" >&6 |
| 2627 | if test "X$cf_with_cxx" = Xno ; then |
| 2628 | CXX="" |
| 2629 | GXX="" |
| 2630 | else |
| 2631 | # with autoconf 2.13, we can change the error to a warning: |
| 2632 | ac_ext=cc |
| 2633 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 2634 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2635 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2636 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 2637 | ac_main_return=return |
| 2638 | if test -n "$ac_tool_prefix"; then |
| 2639 | for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC |
| 2640 | do |
| 2641 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 2642 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
| 2643 | echo "$as_me:2643: checking for $ac_word" >&5 |
| 2644 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2645 | if test "${ac_cv_prog_CXX+set}" = set; then |
| 2646 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2647 | else |
| 2648 | if test -n "$CXX"; then |
| 2649 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 2650 | else |
| 2651 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2652 | ac_dummy="$PATH" |
| 2653 | for ac_dir in $ac_dummy; do |
| 2654 | IFS=$ac_save_IFS |
| 2655 | test -z "$ac_dir" && ac_dir=. |
| 2656 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 2657 | ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" |
| 2658 | echo "$as_me:2658: found $ac_dir/$ac_word" >&5 |
| 2659 | break |
| 2660 | done |
| 2661 | |
| 2662 | fi |
| 2663 | fi |
| 2664 | CXX=$ac_cv_prog_CXX |
| 2665 | if test -n "$CXX"; then |
| 2666 | echo "$as_me:2666: result: $CXX" >&5 |
| 2667 | echo "${ECHO_T}$CXX" >&6 |
| 2668 | else |
| 2669 | echo "$as_me:2669: result: no" >&5 |
| 2670 | echo "${ECHO_T}no" >&6 |
| 2671 | fi |
| 2672 | |
| 2673 | test -n "$CXX" && break |
| 2674 | done |
| 2675 | fi |
| 2676 | if test -z "$CXX"; then |
| 2677 | ac_ct_CXX=$CXX |
| 2678 | for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC |
| 2679 | do |
| 2680 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 2681 | set dummy $ac_prog; ac_word=$2 |
| 2682 | echo "$as_me:2682: checking for $ac_word" >&5 |
| 2683 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 2684 | if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then |
| 2685 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2686 | else |
| 2687 | if test -n "$ac_ct_CXX"; then |
| 2688 | ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. |
| 2689 | else |
| 2690 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 2691 | ac_dummy="$PATH" |
| 2692 | for ac_dir in $ac_dummy; do |
| 2693 | IFS=$ac_save_IFS |
| 2694 | test -z "$ac_dir" && ac_dir=. |
| 2695 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 2696 | ac_cv_prog_ac_ct_CXX="$ac_prog" |
| 2697 | echo "$as_me:2697: found $ac_dir/$ac_word" >&5 |
| 2698 | break |
| 2699 | done |
| 2700 | |
| 2701 | fi |
| 2702 | fi |
| 2703 | ac_ct_CXX=$ac_cv_prog_ac_ct_CXX |
| 2704 | if test -n "$ac_ct_CXX"; then |
| 2705 | echo "$as_me:2705: result: $ac_ct_CXX" >&5 |
| 2706 | echo "${ECHO_T}$ac_ct_CXX" >&6 |
| 2707 | else |
| 2708 | echo "$as_me:2708: result: no" >&5 |
| 2709 | echo "${ECHO_T}no" >&6 |
| 2710 | fi |
| 2711 | |
| 2712 | test -n "$ac_ct_CXX" && break |
| 2713 | done |
| 2714 | test -n "$ac_ct_CXX" || ac_ct_CXX="g++" |
| 2715 | |
| 2716 | CXX=$ac_ct_CXX |
| 2717 | fi |
| 2718 | |
| 2719 | # Provide some information about the compiler. |
| 2720 | echo "$as_me:2720:" \ |
| 2721 | "checking for C++ compiler version" >&5 |
| 2722 | ac_compiler=`set X $ac_compile; echo $2` |
| 2723 | { (eval echo "$as_me:2723: \"$ac_compiler --version </dev/null >&5\"") >&5 |
| 2724 | (eval $ac_compiler --version </dev/null >&5) 2>&5 |
| 2725 | ac_status=$? |
| 2726 | echo "$as_me:2726: \$? = $ac_status" >&5 |
| 2727 | (exit $ac_status); } |
| 2728 | { (eval echo "$as_me:2728: \"$ac_compiler -v </dev/null >&5\"") >&5 |
| 2729 | (eval $ac_compiler -v </dev/null >&5) 2>&5 |
| 2730 | ac_status=$? |
| 2731 | echo "$as_me:2731: \$? = $ac_status" >&5 |
| 2732 | (exit $ac_status); } |
| 2733 | { (eval echo "$as_me:2733: \"$ac_compiler -V </dev/null >&5\"") >&5 |
| 2734 | (eval $ac_compiler -V </dev/null >&5) 2>&5 |
| 2735 | ac_status=$? |
| 2736 | echo "$as_me:2736: \$? = $ac_status" >&5 |
| 2737 | (exit $ac_status); } |
| 2738 | |
| 2739 | echo "$as_me:2739: checking whether we are using the GNU C++ compiler" >&5 |
| 2740 | echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6 |
| 2741 | if test "${ac_cv_cxx_compiler_gnu+set}" = set; then |
| 2742 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2743 | else |
| 2744 | cat >conftest.$ac_ext <<_ACEOF |
| 2745 | #line 2745 "configure" |
| 2746 | #include "confdefs.h" |
| 2747 | |
| 2748 | int |
| 2749 | main () |
| 2750 | { |
| 2751 | #ifndef __GNUC__ |
| 2752 | choke me |
| 2753 | #endif |
| 2754 | |
| 2755 | ; |
| 2756 | return 0; |
| 2757 | } |
| 2758 | _ACEOF |
| 2759 | rm -f conftest.$ac_objext |
| 2760 | if { (eval echo "$as_me:2760: \"$ac_compile\"") >&5 |
| 2761 | (eval $ac_compile) 2>&5 |
| 2762 | ac_status=$? |
| 2763 | echo "$as_me:2763: \$? = $ac_status" >&5 |
| 2764 | (exit $ac_status); } && |
| 2765 | { ac_try='test -s conftest.$ac_objext' |
| 2766 | { (eval echo "$as_me:2766: \"$ac_try\"") >&5 |
| 2767 | (eval $ac_try) 2>&5 |
| 2768 | ac_status=$? |
| 2769 | echo "$as_me:2769: \$? = $ac_status" >&5 |
| 2770 | (exit $ac_status); }; }; then |
| 2771 | ac_compiler_gnu=yes |
| 2772 | else |
| 2773 | echo "$as_me: failed program was:" >&5 |
| 2774 | cat conftest.$ac_ext >&5 |
| 2775 | ac_compiler_gnu=no |
| 2776 | fi |
| 2777 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2778 | ac_cv_cxx_compiler_gnu=$ac_compiler_gnu |
| 2779 | |
| 2780 | fi |
| 2781 | echo "$as_me:2781: result: $ac_cv_cxx_compiler_gnu" >&5 |
| 2782 | echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6 |
| 2783 | GXX=`test $ac_compiler_gnu = yes && echo yes` |
| 2784 | ac_test_CXXFLAGS=${CXXFLAGS+set} |
| 2785 | ac_save_CXXFLAGS=$CXXFLAGS |
| 2786 | CXXFLAGS="-g" |
| 2787 | echo "$as_me:2787: checking whether $CXX accepts -g" >&5 |
| 2788 | echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6 |
| 2789 | if test "${ac_cv_prog_cxx_g+set}" = set; then |
| 2790 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 2791 | else |
| 2792 | cat >conftest.$ac_ext <<_ACEOF |
| 2793 | #line 2793 "configure" |
| 2794 | #include "confdefs.h" |
| 2795 | |
| 2796 | int |
| 2797 | main () |
| 2798 | { |
| 2799 | |
| 2800 | ; |
| 2801 | return 0; |
| 2802 | } |
| 2803 | _ACEOF |
| 2804 | rm -f conftest.$ac_objext |
| 2805 | if { (eval echo "$as_me:2805: \"$ac_compile\"") >&5 |
| 2806 | (eval $ac_compile) 2>&5 |
| 2807 | ac_status=$? |
| 2808 | echo "$as_me:2808: \$? = $ac_status" >&5 |
| 2809 | (exit $ac_status); } && |
| 2810 | { ac_try='test -s conftest.$ac_objext' |
| 2811 | { (eval echo "$as_me:2811: \"$ac_try\"") >&5 |
| 2812 | (eval $ac_try) 2>&5 |
| 2813 | ac_status=$? |
| 2814 | echo "$as_me:2814: \$? = $ac_status" >&5 |
| 2815 | (exit $ac_status); }; }; then |
| 2816 | ac_cv_prog_cxx_g=yes |
| 2817 | else |
| 2818 | echo "$as_me: failed program was:" >&5 |
| 2819 | cat conftest.$ac_ext >&5 |
| 2820 | ac_cv_prog_cxx_g=no |
| 2821 | fi |
| 2822 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2823 | fi |
| 2824 | echo "$as_me:2824: result: $ac_cv_prog_cxx_g" >&5 |
| 2825 | echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6 |
| 2826 | if test "$ac_test_CXXFLAGS" = set; then |
| 2827 | CXXFLAGS=$ac_save_CXXFLAGS |
| 2828 | elif test $ac_cv_prog_cxx_g = yes; then |
| 2829 | if test "$GXX" = yes; then |
| 2830 | CXXFLAGS="-g -O2" |
| 2831 | else |
| 2832 | CXXFLAGS="-g" |
| 2833 | fi |
| 2834 | else |
| 2835 | if test "$GXX" = yes; then |
| 2836 | CXXFLAGS="-O2" |
| 2837 | else |
| 2838 | CXXFLAGS= |
| 2839 | fi |
| 2840 | fi |
| 2841 | for ac_declaration in \ |
| 2842 | ''\ |
| 2843 | '#include <stdlib.h>' \ |
| 2844 | 'extern "C" void std::exit (int) throw (); using std::exit;' \ |
| 2845 | 'extern "C" void std::exit (int); using std::exit;' \ |
| 2846 | 'extern "C" void exit (int) throw ();' \ |
| 2847 | 'extern "C" void exit (int);' \ |
| 2848 | 'void exit (int);' |
| 2849 | do |
| 2850 | cat >conftest.$ac_ext <<_ACEOF |
| 2851 | #line 2851 "configure" |
| 2852 | #include "confdefs.h" |
| 2853 | #include <stdlib.h> |
| 2854 | $ac_declaration |
| 2855 | int |
| 2856 | main () |
| 2857 | { |
| 2858 | exit (42); |
| 2859 | ; |
| 2860 | return 0; |
| 2861 | } |
| 2862 | _ACEOF |
| 2863 | rm -f conftest.$ac_objext |
| 2864 | if { (eval echo "$as_me:2864: \"$ac_compile\"") >&5 |
| 2865 | (eval $ac_compile) 2>&5 |
| 2866 | ac_status=$? |
| 2867 | echo "$as_me:2867: \$? = $ac_status" >&5 |
| 2868 | (exit $ac_status); } && |
| 2869 | { ac_try='test -s conftest.$ac_objext' |
| 2870 | { (eval echo "$as_me:2870: \"$ac_try\"") >&5 |
| 2871 | (eval $ac_try) 2>&5 |
| 2872 | ac_status=$? |
| 2873 | echo "$as_me:2873: \$? = $ac_status" >&5 |
| 2874 | (exit $ac_status); }; }; then |
| 2875 | : |
| 2876 | else |
| 2877 | echo "$as_me: failed program was:" >&5 |
| 2878 | cat conftest.$ac_ext >&5 |
| 2879 | continue |
| 2880 | fi |
| 2881 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2882 | cat >conftest.$ac_ext <<_ACEOF |
| 2883 | #line 2883 "configure" |
| 2884 | #include "confdefs.h" |
| 2885 | $ac_declaration |
| 2886 | int |
| 2887 | main () |
| 2888 | { |
| 2889 | exit (42); |
| 2890 | ; |
| 2891 | return 0; |
| 2892 | } |
| 2893 | _ACEOF |
| 2894 | rm -f conftest.$ac_objext |
| 2895 | if { (eval echo "$as_me:2895: \"$ac_compile\"") >&5 |
| 2896 | (eval $ac_compile) 2>&5 |
| 2897 | ac_status=$? |
| 2898 | echo "$as_me:2898: \$? = $ac_status" >&5 |
| 2899 | (exit $ac_status); } && |
| 2900 | { ac_try='test -s conftest.$ac_objext' |
| 2901 | { (eval echo "$as_me:2901: \"$ac_try\"") >&5 |
| 2902 | (eval $ac_try) 2>&5 |
| 2903 | ac_status=$? |
| 2904 | echo "$as_me:2904: \$? = $ac_status" >&5 |
| 2905 | (exit $ac_status); }; }; then |
| 2906 | break |
| 2907 | else |
| 2908 | echo "$as_me: failed program was:" >&5 |
| 2909 | cat conftest.$ac_ext >&5 |
| 2910 | fi |
| 2911 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2912 | done |
| 2913 | rm -rf conftest* |
| 2914 | if test -n "$ac_declaration"; then |
| 2915 | echo '#ifdef __cplusplus' >>confdefs.h |
| 2916 | echo $ac_declaration >>confdefs.h |
| 2917 | echo '#endif' >>confdefs.h |
| 2918 | fi |
| 2919 | |
| 2920 | ac_ext=c |
| 2921 | ac_cpp='$CPP $CPPFLAGS' |
| 2922 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2923 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2924 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2925 | ac_main_return=return |
| 2926 | |
| 2927 | ac_ext=cc |
| 2928 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 2929 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2930 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2931 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 2932 | ac_main_return=return |
| 2933 | |
| 2934 | if test "x$cf_with_cxx" != xno |
| 2935 | then |
| 2936 | # Several of the C++ configurations do not work, particularly when |
| 2937 | # cross-compiling (20140913 -TD) |
| 2938 | echo "$as_me:2938: checking if $CXX works" >&5 |
| 2939 | echo $ECHO_N "checking if $CXX works... $ECHO_C" >&6 |
| 2940 | |
| 2941 | save_CPPFLAGS="$CPPFLAGS" |
| 2942 | eval cf_includedir=${includedir} |
| 2943 | CPPFLAGS="$CPPFLAGS -I${cf_includedir}" |
| 2944 | |
| 2945 | cat >conftest.$ac_ext <<_ACEOF |
| 2946 | #line 2946 "configure" |
| 2947 | #include "confdefs.h" |
| 2948 | |
| 2949 | #include <stdlib.h> |
| 2950 | #include <stdio.h> |
| 2951 | |
| 2952 | int |
| 2953 | main () |
| 2954 | { |
| 2955 | |
| 2956 | printf("Hello world!\n") |
| 2957 | |
| 2958 | ; |
| 2959 | return 0; |
| 2960 | } |
| 2961 | _ACEOF |
| 2962 | rm -f conftest.$ac_objext |
| 2963 | if { (eval echo "$as_me:2963: \"$ac_compile\"") >&5 |
| 2964 | (eval $ac_compile) 2>&5 |
| 2965 | ac_status=$? |
| 2966 | echo "$as_me:2966: \$? = $ac_status" >&5 |
| 2967 | (exit $ac_status); } && |
| 2968 | { ac_try='test -s conftest.$ac_objext' |
| 2969 | { (eval echo "$as_me:2969: \"$ac_try\"") >&5 |
| 2970 | (eval $ac_try) 2>&5 |
| 2971 | ac_status=$? |
| 2972 | echo "$as_me:2972: \$? = $ac_status" >&5 |
| 2973 | (exit $ac_status); }; }; then |
| 2974 | cf_cxx_works=yes |
| 2975 | else |
| 2976 | echo "$as_me: failed program was:" >&5 |
| 2977 | cat conftest.$ac_ext >&5 |
| 2978 | cf_cxx_works=no |
| 2979 | fi |
| 2980 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 2981 | CPPFLAGS="$save_CPPFLAGS" |
| 2982 | |
| 2983 | echo "$as_me:2983: result: $cf_cxx_works" >&5 |
| 2984 | echo "${ECHO_T}$cf_cxx_works" >&6 |
| 2985 | if test "x$cf_cxx_works" = xno |
| 2986 | then |
| 2987 | { echo "$as_me:2987: WARNING: Ignore $CXX, since it cannot compile hello-world." >&5 |
| 2988 | echo "$as_me: WARNING: Ignore $CXX, since it cannot compile hello-world." >&2;} |
| 2989 | cf_with_cxx=no; CXX=""; GXX=""; |
| 2990 | fi |
| 2991 | fi |
| 2992 | ac_ext=c |
| 2993 | ac_cpp='$CPP $CPPFLAGS' |
| 2994 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2995 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2996 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2997 | ac_main_return=return |
| 2998 | |
| 2999 | # autoconf 2.5x removed the error (hardcoding it to g++, or just blank) |
| 3000 | if test "$CXX" = "g++" ; then |
| 3001 | # Extract the first word of "g++", so it can be a program name with args. |
| 3002 | set dummy g++; ac_word=$2 |
| 3003 | echo "$as_me:3003: checking for $ac_word" >&5 |
| 3004 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3005 | if test "${ac_cv_path_CXX+set}" = set; then |
| 3006 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3007 | else |
| 3008 | case $CXX in |
| 3009 | [\\/]* | ?:[\\/]*) |
| 3010 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 3011 | ;; |
| 3012 | *) |
| 3013 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3014 | ac_dummy="$PATH" |
| 3015 | for ac_dir in $ac_dummy; do |
| 3016 | IFS=$ac_save_IFS |
| 3017 | test -z "$ac_dir" && ac_dir=. |
| 3018 | if $as_executable_p "$ac_dir/$ac_word"; then |
| 3019 | ac_cv_path_CXX="$ac_dir/$ac_word" |
| 3020 | echo "$as_me:3020: found $ac_dir/$ac_word" >&5 |
| 3021 | break |
| 3022 | fi |
| 3023 | done |
| 3024 | |
| 3025 | ;; |
| 3026 | esac |
| 3027 | fi |
| 3028 | CXX=$ac_cv_path_CXX |
| 3029 | |
| 3030 | if test -n "$CXX"; then |
| 3031 | echo "$as_me:3031: result: $CXX" >&5 |
| 3032 | echo "${ECHO_T}$CXX" >&6 |
| 3033 | else |
| 3034 | echo "$as_me:3034: result: no" >&5 |
| 3035 | echo "${ECHO_T}no" >&6 |
| 3036 | fi |
| 3037 | |
| 3038 | fi |
| 3039 | case "x$CXX" in |
| 3040 | (x|xg++) |
| 3041 | { echo "$as_me:3041: WARNING: You don't have any C++ compiler, too bad" >&5 |
| 3042 | echo "$as_me: WARNING: You don't have any C++ compiler, too bad" >&2;} |
| 3043 | cf_with_cxx=no; CXX=""; GXX=""; |
| 3044 | ;; |
| 3045 | esac |
| 3046 | fi |
| 3047 | |
| 3048 | GXX_VERSION=none |
| 3049 | if test "$GXX" = yes; then |
| 3050 | echo "$as_me:3050: checking version of ${CXX:-g++}" >&5 |
| 3051 | echo $ECHO_N "checking version of ${CXX:-g++}... $ECHO_C" >&6 |
| 3052 | GXX_VERSION="`${CXX:-g++} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`" |
| 3053 | test -z "$GXX_VERSION" && GXX_VERSION=unknown |
| 3054 | echo "$as_me:3054: result: $GXX_VERSION" >&5 |
| 3055 | echo "${ECHO_T}$GXX_VERSION" >&6 |
| 3056 | fi |
| 3057 | |
| 3058 | case $GXX_VERSION in |
| 3059 | (1*|2.[0-6]*) |
| 3060 | # GXX=""; CXX=""; ac_cv_prog_gxx=no |
| 3061 | # cf_cxx_library=no |
| 3062 | { echo "$as_me:3062: WARNING: templates do not work" >&5 |
| 3063 | echo "$as_me: WARNING: templates do not work" >&2;} |
| 3064 | ;; |
| 3065 | esac |
| 3066 | |
| 3067 | echo "$as_me:3067: checking if you want to build C++ binding and demo" >&5 |
| 3068 | echo $ECHO_N "checking if you want to build C++ binding and demo... $ECHO_C" >&6 |
| 3069 | |
| 3070 | # Check whether --with-cxx-binding or --without-cxx-binding was given. |
| 3071 | if test "${with_cxx_binding+set}" = set; then |
| 3072 | withval="$with_cxx_binding" |
| 3073 | cf_with_cxx_binding=$withval |
| 3074 | else |
| 3075 | cf_with_cxx_binding=$cf_with_cxx |
| 3076 | fi; |
| 3077 | echo "$as_me:3077: result: $cf_with_cxx_binding" >&5 |
| 3078 | echo "${ECHO_T}$cf_with_cxx_binding" >&6 |
| 3079 | |
| 3080 | echo "$as_me:3080: checking if you want to build with Ada95" >&5 |
| 3081 | echo $ECHO_N "checking if you want to build with Ada95... $ECHO_C" >&6 |
| 3082 | echo "$as_me:3082: result: $cf_with_ada" >&5 |
| 3083 | echo "${ECHO_T}$cf_with_ada" >&6 |
| 3084 | |
| 3085 | echo "$as_me:3085: checking if you want to install terminal database" >&5 |
| 3086 | echo $ECHO_N "checking if you want to install terminal database... $ECHO_C" >&6 |
| 3087 | |
| 3088 | # Check whether --enable-db-install or --disable-db-install was given. |
| 3089 | if test "${enable_db_install+set}" = set; then |
| 3090 | enableval="$enable_db_install" |
| 3091 | cf_with_db_install=$enableval |
| 3092 | else |
| 3093 | cf_with_db_install=yes |
| 3094 | fi; |
| 3095 | echo "$as_me:3095: result: $cf_with_db_install" >&5 |
| 3096 | echo "${ECHO_T}$cf_with_db_install" >&6 |
| 3097 | |
| 3098 | echo "$as_me:3098: checking if you want to install manpages" >&5 |
| 3099 | echo $ECHO_N "checking if you want to install manpages... $ECHO_C" >&6 |
| 3100 | |
| 3101 | # Check whether --with-manpages or --without-manpages was given. |
| 3102 | if test "${with_manpages+set}" = set; then |
| 3103 | withval="$with_manpages" |
| 3104 | cf_with_manpages=$withval |
| 3105 | else |
| 3106 | cf_with_manpages=yes |
| 3107 | fi; |
| 3108 | echo "$as_me:3108: result: $cf_with_manpages" >&5 |
| 3109 | echo "${ECHO_T}$cf_with_manpages" >&6 |
| 3110 | |
| 3111 | echo "$as_me:3111: checking if you want to build programs such as tic" >&5 |
| 3112 | echo $ECHO_N "checking if you want to build programs such as tic... $ECHO_C" >&6 |
| 3113 | |
| 3114 | # Check whether --with-progs or --without-progs was given. |
| 3115 | if test "${with_progs+set}" = set; then |
| 3116 | withval="$with_progs" |
| 3117 | cf_with_progs=$withval |
| 3118 | else |
| 3119 | cf_with_progs=yes |
| 3120 | fi; |
| 3121 | echo "$as_me:3121: result: $cf_with_progs" >&5 |
| 3122 | echo "${ECHO_T}$cf_with_progs" >&6 |
| 3123 | |
| 3124 | echo "$as_me:3124: checking if you want to build test-programs" >&5 |
| 3125 | echo $ECHO_N "checking if you want to build test-programs... $ECHO_C" >&6 |
| 3126 | |
| 3127 | # Check whether --with-tests or --without-tests was given. |
| 3128 | if test "${with_tests+set}" = set; then |
| 3129 | withval="$with_tests" |
| 3130 | cf_with_tests=$withval |
| 3131 | else |
| 3132 | cf_with_tests=yes |
| 3133 | fi; |
| 3134 | echo "$as_me:3134: result: $cf_with_tests" >&5 |
| 3135 | echo "${ECHO_T}$cf_with_tests" >&6 |
| 3136 | |
| 3137 | echo "$as_me:3137: checking if you wish to install curses.h" >&5 |
| 3138 | echo $ECHO_N "checking if you wish to install curses.h... $ECHO_C" >&6 |
| 3139 | |
| 3140 | # Check whether --with-curses-h or --without-curses-h was given. |
| 3141 | if test "${with_curses_h+set}" = set; then |
| 3142 | withval="$with_curses_h" |
| 3143 | with_curses_h=$withval |
| 3144 | else |
| 3145 | with_curses_h=yes |
| 3146 | fi; |
| 3147 | echo "$as_me:3147: result: $with_curses_h" >&5 |
| 3148 | echo "${ECHO_T}$with_curses_h" >&6 |
| 3149 | |
| 3150 | modules_to_build="ncurses" |
| 3151 | if test "X$cf_with_progs" != Xno ; then |
| 3152 | modules_to_build="$modules_to_build progs tack" |
| 3153 | fi |
| 3154 | modules_to_build="$modules_to_build panel menu form" |
| 3155 | |
| 3156 | test "$program_prefix" != NONE && |
| 3157 | program_transform_name="s,^,$program_prefix,;$program_transform_name" |
| 3158 | # Use a double $ so make ignores it. |
| 3159 | test "$program_suffix" != NONE && |
| 3160 | program_transform_name="s,\$,$program_suffix,;$program_transform_name" |
| 3161 | # Double any \ or $. echo might interpret backslashes. |
| 3162 | # By default was `s,x,x', remove it if useless. |
| 3163 | cat <<\_ACEOF >conftest.sed |
| 3164 | s/[\\$]/&&/g;s/;s,x,x,$// |
| 3165 | _ACEOF |
| 3166 | program_transform_name=`echo $program_transform_name | sed -f conftest.sed` |
| 3167 | rm conftest.sed |
| 3168 | |
| 3169 | for ac_prog in mawk gawk nawk awk |
| 3170 | do |
| 3171 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3172 | set dummy $ac_prog; ac_word=$2 |
| 3173 | echo "$as_me:3173: checking for $ac_word" >&5 |
| 3174 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3175 | if test "${ac_cv_prog_AWK+set}" = set; then |
| 3176 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3177 | else |
| 3178 | if test -n "$AWK"; then |
| 3179 | ac_cv_prog_AWK="$AWK" # Let the user override the test. |
| 3180 | else |
| 3181 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3182 | ac_dummy="$PATH" |
| 3183 | for ac_dir in $ac_dummy; do |
| 3184 | IFS=$ac_save_IFS |
| 3185 | test -z "$ac_dir" && ac_dir=. |
| 3186 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 3187 | ac_cv_prog_AWK="$ac_prog" |
| 3188 | echo "$as_me:3188: found $ac_dir/$ac_word" >&5 |
| 3189 | break |
| 3190 | done |
| 3191 | |
| 3192 | fi |
| 3193 | fi |
| 3194 | AWK=$ac_cv_prog_AWK |
| 3195 | if test -n "$AWK"; then |
| 3196 | echo "$as_me:3196: result: $AWK" >&5 |
| 3197 | echo "${ECHO_T}$AWK" >&6 |
| 3198 | else |
| 3199 | echo "$as_me:3199: result: no" >&5 |
| 3200 | echo "${ECHO_T}no" >&6 |
| 3201 | fi |
| 3202 | |
| 3203 | test -n "$AWK" && break |
| 3204 | done |
| 3205 | |
| 3206 | test -z "$AWK" && { { echo "$as_me:3206: error: No awk program found" >&5 |
| 3207 | echo "$as_me: error: No awk program found" >&2;} |
| 3208 | { (exit 1); exit 1; }; } |
| 3209 | |
| 3210 | echo "$as_me:3210: checking for egrep" >&5 |
| 3211 | echo $ECHO_N "checking for egrep... $ECHO_C" >&6 |
| 3212 | if test "${ac_cv_prog_egrep+set}" = set; then |
| 3213 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3214 | else |
| 3215 | if echo a | (grep -E '(a|b)') >/dev/null 2>&1 |
| 3216 | then ac_cv_prog_egrep='grep -E' |
| 3217 | else ac_cv_prog_egrep='egrep' |
| 3218 | fi |
| 3219 | fi |
| 3220 | echo "$as_me:3220: result: $ac_cv_prog_egrep" >&5 |
| 3221 | echo "${ECHO_T}$ac_cv_prog_egrep" >&6 |
| 3222 | EGREP=$ac_cv_prog_egrep |
| 3223 | |
| 3224 | test -z "$EGREP" && { { echo "$as_me:3224: error: No egrep program found" >&5 |
| 3225 | echo "$as_me: error: No egrep program found" >&2;} |
| 3226 | { (exit 1); exit 1; }; } |
| 3227 | |
| 3228 | # Find a good install program. We prefer a C program (faster), |
| 3229 | # so one script is as good as another. But avoid the broken or |
| 3230 | # incompatible versions: |
| 3231 | # SysV /etc/install, /usr/sbin/install |
| 3232 | # SunOS /usr/etc/install |
| 3233 | # IRIX /sbin/install |
| 3234 | # AIX /bin/install |
| 3235 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 3236 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 3237 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 3238 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 3239 | # ./install, which can be erroneously created by make from ./install.sh. |
| 3240 | echo "$as_me:3240: checking for a BSD compatible install" >&5 |
| 3241 | echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6 |
| 3242 | if test -z "$INSTALL"; then |
| 3243 | if test "${ac_cv_path_install+set}" = set; then |
| 3244 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3245 | else |
| 3246 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3247 | for ac_dir in $PATH; do |
| 3248 | IFS=$ac_save_IFS |
| 3249 | # Account for people who put trailing slashes in PATH elements. |
| 3250 | case $ac_dir/ in |
| 3251 | / | ./ | .// | /cC/* \ |
| 3252 | | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \ |
| 3253 | | /usr/ucb/* ) ;; |
| 3254 | *) |
| 3255 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 3256 | # Don't use installbsd from OSF since it installs stuff as root |
| 3257 | # by default. |
| 3258 | for ac_prog in ginstall scoinst install; do |
| 3259 | if $as_executable_p "$ac_dir/$ac_prog"; then |
| 3260 | if test $ac_prog = install && |
| 3261 | grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then |
| 3262 | # AIX install. It has an incompatible calling convention. |
| 3263 | : |
| 3264 | elif test $ac_prog = install && |
| 3265 | grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then |
| 3266 | # program-specific install script used by HP pwplus--don't use. |
| 3267 | : |
| 3268 | else |
| 3269 | ac_cv_path_install="$ac_dir/$ac_prog -c" |
| 3270 | break 2 |
| 3271 | fi |
| 3272 | fi |
| 3273 | done |
| 3274 | ;; |
| 3275 | esac |
| 3276 | done |
| 3277 | |
| 3278 | fi |
| 3279 | if test "${ac_cv_path_install+set}" = set; then |
| 3280 | INSTALL=$ac_cv_path_install |
| 3281 | else |
| 3282 | # As a last resort, use the slow shell script. We don't cache a |
| 3283 | # path for INSTALL within a source directory, because that will |
| 3284 | # break other packages using the cache if that directory is |
| 3285 | # removed, or if the path is relative. |
| 3286 | INSTALL=$ac_install_sh |
| 3287 | fi |
| 3288 | fi |
| 3289 | echo "$as_me:3289: result: $INSTALL" >&5 |
| 3290 | echo "${ECHO_T}$INSTALL" >&6 |
| 3291 | |
| 3292 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 3293 | # It thinks the first close brace ends the variable substitution. |
| 3294 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 3295 | |
| 3296 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 3297 | |
| 3298 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 3299 | |
| 3300 | case $INSTALL in |
| 3301 | (/*) |
| 3302 | ;; |
| 3303 | (*) |
| 3304 | cf_dir=`echo $INSTALL | sed -e 's%/[^/]*$%%'` |
| 3305 | test -z "$cf_dir" && cf_dir=. |
| 3306 | INSTALL=`cd $cf_dir && pwd`/`echo $INSTALL | sed -e 's%^.*/%%'` |
| 3307 | ;; |
| 3308 | esac |
| 3309 | |
| 3310 | for ac_prog in tdlint lint alint splint lclint |
| 3311 | do |
| 3312 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3313 | set dummy $ac_prog; ac_word=$2 |
| 3314 | echo "$as_me:3314: checking for $ac_word" >&5 |
| 3315 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3316 | if test "${ac_cv_prog_LINT+set}" = set; then |
| 3317 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3318 | else |
| 3319 | if test -n "$LINT"; then |
| 3320 | ac_cv_prog_LINT="$LINT" # Let the user override the test. |
| 3321 | else |
| 3322 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3323 | ac_dummy="$PATH" |
| 3324 | for ac_dir in $ac_dummy; do |
| 3325 | IFS=$ac_save_IFS |
| 3326 | test -z "$ac_dir" && ac_dir=. |
| 3327 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 3328 | ac_cv_prog_LINT="$ac_prog" |
| 3329 | echo "$as_me:3329: found $ac_dir/$ac_word" >&5 |
| 3330 | break |
| 3331 | done |
| 3332 | |
| 3333 | fi |
| 3334 | fi |
| 3335 | LINT=$ac_cv_prog_LINT |
| 3336 | if test -n "$LINT"; then |
| 3337 | echo "$as_me:3337: result: $LINT" >&5 |
| 3338 | echo "${ECHO_T}$LINT" >&6 |
| 3339 | else |
| 3340 | echo "$as_me:3340: result: no" >&5 |
| 3341 | echo "${ECHO_T}no" >&6 |
| 3342 | fi |
| 3343 | |
| 3344 | test -n "$LINT" && break |
| 3345 | done |
| 3346 | |
| 3347 | echo "$as_me:3347: checking whether ln -s works" >&5 |
| 3348 | echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6 |
| 3349 | LN_S=$as_ln_s |
| 3350 | if test "$LN_S" = "ln -s"; then |
| 3351 | echo "$as_me:3351: result: yes" >&5 |
| 3352 | echo "${ECHO_T}yes" >&6 |
| 3353 | else |
| 3354 | echo "$as_me:3354: result: no, using $LN_S" >&5 |
| 3355 | echo "${ECHO_T}no, using $LN_S" >&6 |
| 3356 | fi |
| 3357 | |
| 3358 | echo "$as_me:3358: checking if $LN_S -f options work" >&5 |
| 3359 | echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6 |
| 3360 | |
| 3361 | rm -f conf$$.src conf$$dst |
| 3362 | echo >conf$$.dst |
| 3363 | echo first >conf$$.src |
| 3364 | if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then |
| 3365 | cf_prog_ln_sf=yes |
| 3366 | else |
| 3367 | cf_prog_ln_sf=no |
| 3368 | fi |
| 3369 | rm -f conf$$.dst conf$$src |
| 3370 | echo "$as_me:3370: result: $cf_prog_ln_sf" >&5 |
| 3371 | echo "${ECHO_T}$cf_prog_ln_sf" >&6 |
| 3372 | |
| 3373 | test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f" |
| 3374 | |
| 3375 | echo "$as_me:3375: checking for long file names" >&5 |
| 3376 | echo $ECHO_N "checking for long file names... $ECHO_C" >&6 |
| 3377 | if test "${ac_cv_sys_long_file_names+set}" = set; then |
| 3378 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3379 | else |
| 3380 | ac_cv_sys_long_file_names=yes |
| 3381 | # Test for long file names in all the places we know might matter: |
| 3382 | # . the current directory, where building will happen |
| 3383 | # $prefix/lib where we will be installing things |
| 3384 | # $exec_prefix/lib likewise |
| 3385 | # eval it to expand exec_prefix. |
| 3386 | # $TMPDIR if set, where it might want to write temporary files |
| 3387 | # if $TMPDIR is not set: |
| 3388 | # /tmp where it might want to write temporary files |
| 3389 | # /var/tmp likewise |
| 3390 | # /usr/tmp likewise |
| 3391 | if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then |
| 3392 | ac_tmpdirs=$TMPDIR |
| 3393 | else |
| 3394 | ac_tmpdirs='/tmp /var/tmp /usr/tmp' |
| 3395 | fi |
| 3396 | for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do |
| 3397 | test -d $ac_dir || continue |
| 3398 | test -w $ac_dir || continue # It is less confusing to not echo anything here. |
| 3399 | ac_xdir=$ac_dir/cf$$ |
| 3400 | (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue |
| 3401 | ac_tf1=$ac_xdir/conftest9012345 |
| 3402 | ac_tf2=$ac_xdir/conftest9012346 |
| 3403 | (echo 1 >$ac_tf1) 2>/dev/null |
| 3404 | (echo 2 >$ac_tf2) 2>/dev/null |
| 3405 | ac_val=`cat $ac_tf1 2>/dev/null` |
| 3406 | if test ! -f $ac_tf1 || test "$ac_val" != 1; then |
| 3407 | ac_cv_sys_long_file_names=no |
| 3408 | rm -rf $ac_xdir 2>/dev/null |
| 3409 | break |
| 3410 | fi |
| 3411 | rm -rf $ac_xdir 2>/dev/null |
| 3412 | done |
| 3413 | fi |
| 3414 | echo "$as_me:3414: result: $ac_cv_sys_long_file_names" >&5 |
| 3415 | echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6 |
| 3416 | if test $ac_cv_sys_long_file_names = yes; then |
| 3417 | |
| 3418 | cat >>confdefs.h <<\EOF |
| 3419 | #define HAVE_LONG_FILE_NAMES 1 |
| 3420 | EOF |
| 3421 | |
| 3422 | fi |
| 3423 | |
| 3424 | # if we find pkg-config, check if we should install the ".pc" files. |
| 3425 | |
| 3426 | echo "$as_me:3426: checking if you want to use pkg-config" >&5 |
| 3427 | echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6 |
| 3428 | |
| 3429 | # Check whether --with-pkg-config or --without-pkg-config was given. |
| 3430 | if test "${with_pkg_config+set}" = set; then |
| 3431 | withval="$with_pkg_config" |
| 3432 | cf_pkg_config=$withval |
| 3433 | else |
| 3434 | cf_pkg_config=yes |
| 3435 | fi; |
| 3436 | echo "$as_me:3436: result: $cf_pkg_config" >&5 |
| 3437 | echo "${ECHO_T}$cf_pkg_config" >&6 |
| 3438 | |
| 3439 | case $cf_pkg_config in |
| 3440 | (no) |
| 3441 | PKG_CONFIG=none |
| 3442 | ;; |
| 3443 | (yes) |
| 3444 | |
| 3445 | if test -n "$ac_tool_prefix"; then |
| 3446 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. |
| 3447 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 |
| 3448 | echo "$as_me:3448: checking for $ac_word" >&5 |
| 3449 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3450 | if test "${ac_cv_path_PKG_CONFIG+set}" = set; then |
| 3451 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3452 | else |
| 3453 | case $PKG_CONFIG in |
| 3454 | [\\/]* | ?:[\\/]*) |
| 3455 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. |
| 3456 | ;; |
| 3457 | *) |
| 3458 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3459 | ac_dummy="$PATH" |
| 3460 | for ac_dir in $ac_dummy; do |
| 3461 | IFS=$ac_save_IFS |
| 3462 | test -z "$ac_dir" && ac_dir=. |
| 3463 | if $as_executable_p "$ac_dir/$ac_word"; then |
| 3464 | ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word" |
| 3465 | echo "$as_me:3465: found $ac_dir/$ac_word" >&5 |
| 3466 | break |
| 3467 | fi |
| 3468 | done |
| 3469 | |
| 3470 | ;; |
| 3471 | esac |
| 3472 | fi |
| 3473 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG |
| 3474 | |
| 3475 | if test -n "$PKG_CONFIG"; then |
| 3476 | echo "$as_me:3476: result: $PKG_CONFIG" >&5 |
| 3477 | echo "${ECHO_T}$PKG_CONFIG" >&6 |
| 3478 | else |
| 3479 | echo "$as_me:3479: result: no" >&5 |
| 3480 | echo "${ECHO_T}no" >&6 |
| 3481 | fi |
| 3482 | |
| 3483 | fi |
| 3484 | if test -z "$ac_cv_path_PKG_CONFIG"; then |
| 3485 | ac_pt_PKG_CONFIG=$PKG_CONFIG |
| 3486 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 3487 | set dummy pkg-config; ac_word=$2 |
| 3488 | echo "$as_me:3488: checking for $ac_word" >&5 |
| 3489 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3490 | if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then |
| 3491 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3492 | else |
| 3493 | case $ac_pt_PKG_CONFIG in |
| 3494 | [\\/]* | ?:[\\/]*) |
| 3495 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. |
| 3496 | ;; |
| 3497 | *) |
| 3498 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3499 | ac_dummy="$PATH" |
| 3500 | for ac_dir in $ac_dummy; do |
| 3501 | IFS=$ac_save_IFS |
| 3502 | test -z "$ac_dir" && ac_dir=. |
| 3503 | if $as_executable_p "$ac_dir/$ac_word"; then |
| 3504 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word" |
| 3505 | echo "$as_me:3505: found $ac_dir/$ac_word" >&5 |
| 3506 | break |
| 3507 | fi |
| 3508 | done |
| 3509 | |
| 3510 | test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none" |
| 3511 | ;; |
| 3512 | esac |
| 3513 | fi |
| 3514 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG |
| 3515 | |
| 3516 | if test -n "$ac_pt_PKG_CONFIG"; then |
| 3517 | echo "$as_me:3517: result: $ac_pt_PKG_CONFIG" >&5 |
| 3518 | echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 |
| 3519 | else |
| 3520 | echo "$as_me:3520: result: no" >&5 |
| 3521 | echo "${ECHO_T}no" >&6 |
| 3522 | fi |
| 3523 | |
| 3524 | PKG_CONFIG=$ac_pt_PKG_CONFIG |
| 3525 | else |
| 3526 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" |
| 3527 | fi |
| 3528 | |
| 3529 | ;; |
| 3530 | (*) |
| 3531 | PKG_CONFIG=$withval |
| 3532 | ;; |
| 3533 | esac |
| 3534 | |
| 3535 | test -z "$PKG_CONFIG" && PKG_CONFIG=none |
| 3536 | if test "$PKG_CONFIG" != none ; then |
| 3537 | |
| 3538 | if test "x$prefix" != xNONE; then |
| 3539 | cf_path_syntax="$prefix" |
| 3540 | else |
| 3541 | cf_path_syntax="$ac_default_prefix" |
| 3542 | fi |
| 3543 | |
| 3544 | case ".$PKG_CONFIG" in |
| 3545 | (.\$\(*\)*|.\'*\'*) |
| 3546 | ;; |
| 3547 | (..|./*|.\\*) |
| 3548 | ;; |
| 3549 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 3550 | ;; |
| 3551 | (.\${*prefix}*|.\${*dir}*) |
| 3552 | eval PKG_CONFIG="$PKG_CONFIG" |
| 3553 | case ".$PKG_CONFIG" in |
| 3554 | (.NONE/*) |
| 3555 | PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%` |
| 3556 | ;; |
| 3557 | esac |
| 3558 | ;; |
| 3559 | (.no|.NONE/*) |
| 3560 | PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%` |
| 3561 | ;; |
| 3562 | (*) |
| 3563 | { { echo "$as_me:3563: error: expected a pathname, not \"$PKG_CONFIG\"" >&5 |
| 3564 | echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;} |
| 3565 | { (exit 1); exit 1; }; } |
| 3566 | ;; |
| 3567 | esac |
| 3568 | |
| 3569 | elif test "x$cf_pkg_config" != xno ; then |
| 3570 | { echo "$as_me:3570: WARNING: pkg-config is not installed" >&5 |
| 3571 | echo "$as_me: WARNING: pkg-config is not installed" >&2;} |
| 3572 | fi |
| 3573 | |
| 3574 | if test "x$PKG_CONFIG" = xnone ; then |
| 3575 | PKG_CONFIG_LIBDIR=no |
| 3576 | else |
| 3577 | echo "$as_me:3577: checking for $PKG_CONFIG library directory" >&5 |
| 3578 | echo $ECHO_N "checking for $PKG_CONFIG library directory... $ECHO_C" >&6 |
| 3579 | |
| 3580 | # Check whether --with-pkg-config-libdir or --without-pkg-config-libdir was given. |
| 3581 | if test "${with_pkg_config_libdir+set}" = set; then |
| 3582 | withval="$with_pkg_config_libdir" |
| 3583 | PKG_CONFIG_LIBDIR=$withval |
| 3584 | else |
| 3585 | PKG_CONFIG_LIBDIR=yes |
| 3586 | fi; |
| 3587 | fi |
| 3588 | |
| 3589 | case x$PKG_CONFIG_LIBDIR in |
| 3590 | (x/*) |
| 3591 | ;; |
| 3592 | (xyes) |
| 3593 | # Look for the library directory using the same prefix as the executable |
| 3594 | if test "x$PKG_CONFIG" = xnone |
| 3595 | then |
| 3596 | cf_path=$prefix |
| 3597 | else |
| 3598 | cf_path=`echo "$PKG_CONFIG" | sed -e 's,/[^/]*/[^/]*$,,'` |
| 3599 | fi |
| 3600 | |
| 3601 | # If you don't like using the default architecture, you have to specify the |
| 3602 | # intended library directory and corresponding compiler/linker options. |
| 3603 | # |
| 3604 | # This case allows for Debian's 2014-flavor of multiarch, along with the |
| 3605 | # most common variations before that point. Some other variants spell the |
| 3606 | # directory differently, e.g., "pkg-config", and put it in unusual places. |
| 3607 | # pkg-config has always been poorly standardized, which is ironic... |
| 3608 | case x`(arch) 2>/dev/null` in |
| 3609 | (*64) |
| 3610 | cf_search_path="\ |
| 3611 | $cf_path/lib/*64-linux-gnu \ |
| 3612 | $cf_path/share \ |
| 3613 | $cf_path/lib64 \ |
| 3614 | $cf_path/lib32 \ |
| 3615 | $cf_path/lib" |
| 3616 | ;; |
| 3617 | (*) |
| 3618 | cf_search_path="\ |
| 3619 | $cf_path/lib/*-linux-gnu \ |
| 3620 | $cf_path/share \ |
| 3621 | $cf_path/lib32 \ |
| 3622 | $cf_path/lib \ |
| 3623 | $cf_path/libdata" |
| 3624 | ;; |
| 3625 | esac |
| 3626 | |
| 3627 | test -n "$verbose" && echo " list..." 1>&6 |
| 3628 | |
| 3629 | echo "${as_me:-configure}:3629: testing list... ..." 1>&5 |
| 3630 | |
| 3631 | for cf_config in $cf_search_path |
| 3632 | do |
| 3633 | test -n "$verbose" && echo " checking $cf_config/pkgconfig" 1>&6 |
| 3634 | |
| 3635 | echo "${as_me:-configure}:3635: testing checking $cf_config/pkgconfig ..." 1>&5 |
| 3636 | |
| 3637 | if test -d $cf_config/pkgconfig |
| 3638 | then |
| 3639 | PKG_CONFIG_LIBDIR=$cf_config/pkgconfig |
| 3640 | echo "$as_me:3640: checking done" >&5 |
| 3641 | echo $ECHO_N "checking done... $ECHO_C" >&6 |
| 3642 | break |
| 3643 | fi |
| 3644 | done |
| 3645 | ;; |
| 3646 | (*) |
| 3647 | ;; |
| 3648 | esac |
| 3649 | |
| 3650 | if test "x$PKG_CONFIG" != xnone ; then |
| 3651 | echo "$as_me:3651: result: $PKG_CONFIG_LIBDIR" >&5 |
| 3652 | echo "${ECHO_T}$PKG_CONFIG_LIBDIR" >&6 |
| 3653 | fi |
| 3654 | |
| 3655 | if test "x$PKG_CONFIG" != xnone |
| 3656 | then |
| 3657 | echo "$as_me:3657: checking if we should install .pc files for $PKG_CONFIG" >&5 |
| 3658 | echo $ECHO_N "checking if we should install .pc files for $PKG_CONFIG... $ECHO_C" >&6 |
| 3659 | else |
| 3660 | echo "$as_me:3660: checking if we should install .pc files" >&5 |
| 3661 | echo $ECHO_N "checking if we should install .pc files... $ECHO_C" >&6 |
| 3662 | fi |
| 3663 | |
| 3664 | # Check whether --enable-pc-files or --disable-pc-files was given. |
| 3665 | if test "${enable_pc_files+set}" = set; then |
| 3666 | enableval="$enable_pc_files" |
| 3667 | enable_pc_files=$enableval |
| 3668 | else |
| 3669 | enable_pc_files=no |
| 3670 | fi; |
| 3671 | echo "$as_me:3671: result: $enable_pc_files" >&5 |
| 3672 | echo "${ECHO_T}$enable_pc_files" >&6 |
| 3673 | |
| 3674 | if test "x$enable_pc_files" != xno |
| 3675 | then |
| 3676 | case "x$PKG_CONFIG_LIBDIR" in |
| 3677 | (xno|xyes) |
| 3678 | { echo "$as_me:3678: WARNING: no PKG_CONFIG_LIBDIR was found" >&5 |
| 3679 | echo "$as_me: WARNING: no PKG_CONFIG_LIBDIR was found" >&2;} |
| 3680 | MAKE_PC_FILES="#" |
| 3681 | ;; |
| 3682 | (*) |
| 3683 | |
| 3684 | if test "x$prefix" != xNONE; then |
| 3685 | cf_path_syntax="$prefix" |
| 3686 | else |
| 3687 | cf_path_syntax="$ac_default_prefix" |
| 3688 | fi |
| 3689 | |
| 3690 | case ".$PKG_CONFIG_LIBDIR" in |
| 3691 | (.\$\(*\)*|.\'*\'*) |
| 3692 | ;; |
| 3693 | (..|./*|.\\*) |
| 3694 | ;; |
| 3695 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 3696 | ;; |
| 3697 | (.\${*prefix}*|.\${*dir}*) |
| 3698 | eval PKG_CONFIG_LIBDIR="$PKG_CONFIG_LIBDIR" |
| 3699 | case ".$PKG_CONFIG_LIBDIR" in |
| 3700 | (.NONE/*) |
| 3701 | PKG_CONFIG_LIBDIR=`echo $PKG_CONFIG_LIBDIR | sed -e s%NONE%$cf_path_syntax%` |
| 3702 | ;; |
| 3703 | esac |
| 3704 | ;; |
| 3705 | (.no|.NONE/*) |
| 3706 | PKG_CONFIG_LIBDIR=`echo $PKG_CONFIG_LIBDIR | sed -e s%NONE%$cf_path_syntax%` |
| 3707 | ;; |
| 3708 | (*) |
| 3709 | { { echo "$as_me:3709: error: expected a pathname, not \"$PKG_CONFIG_LIBDIR\"" >&5 |
| 3710 | echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG_LIBDIR\"" >&2;} |
| 3711 | { (exit 1); exit 1; }; } |
| 3712 | ;; |
| 3713 | esac |
| 3714 | |
| 3715 | MAKE_PC_FILES= |
| 3716 | ;; |
| 3717 | esac |
| 3718 | else |
| 3719 | MAKE_PC_FILES="#" |
| 3720 | fi |
| 3721 | |
| 3722 | if test -z "$MAKE_PC_FILES" |
| 3723 | then |
| 3724 | echo "$as_me:3724: checking for suffix to add to pc-files" >&5 |
| 3725 | echo $ECHO_N "checking for suffix to add to pc-files... $ECHO_C" >&6 |
| 3726 | |
| 3727 | # Check whether --with-pc-suffix or --without-pc-suffix was given. |
| 3728 | if test "${with_pc_suffix+set}" = set; then |
| 3729 | withval="$with_pc_suffix" |
| 3730 | case "x$withval" in |
| 3731 | (xyes|xno) |
| 3732 | PC_MODULE_SUFFIX= |
| 3733 | ;; |
| 3734 | (*) PC_MODULE_SUFFIX="$withval" |
| 3735 | ;; |
| 3736 | esac |
| 3737 | fi; |
| 3738 | test -z "$PC_MODULE_SUFFIX" && PC_MODULE_SUFFIX=none |
| 3739 | echo "$as_me:3739: result: $PC_MODULE_SUFFIX" >&5 |
| 3740 | echo "${ECHO_T}$PC_MODULE_SUFFIX" >&6 |
| 3741 | test "$PC_MODULE_SUFFIX" = none && PC_MODULE_SUFFIX= |
| 3742 | |
| 3743 | fi |
| 3744 | |
| 3745 | echo "$as_me:3745: checking if we should assume mixed-case filenames" >&5 |
| 3746 | echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6 |
| 3747 | |
| 3748 | # Check whether --enable-mixed-case or --disable-mixed-case was given. |
| 3749 | if test "${enable_mixed_case+set}" = set; then |
| 3750 | enableval="$enable_mixed_case" |
| 3751 | enable_mixedcase=$enableval |
| 3752 | else |
| 3753 | enable_mixedcase=auto |
| 3754 | fi; |
| 3755 | echo "$as_me:3755: result: $enable_mixedcase" >&5 |
| 3756 | echo "${ECHO_T}$enable_mixedcase" >&6 |
| 3757 | if test "$enable_mixedcase" = "auto" ; then |
| 3758 | |
| 3759 | echo "$as_me:3759: checking if filesystem supports mixed-case filenames" >&5 |
| 3760 | echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6 |
| 3761 | if test "${cf_cv_mixedcase+set}" = set; then |
| 3762 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3763 | else |
| 3764 | |
| 3765 | if test "$cross_compiling" = yes ; then |
| 3766 | case $target_alias in |
| 3767 | (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*) |
| 3768 | cf_cv_mixedcase=no |
| 3769 | ;; |
| 3770 | (*) |
| 3771 | cf_cv_mixedcase=yes |
| 3772 | ;; |
| 3773 | esac |
| 3774 | else |
| 3775 | rm -f conftest CONFTEST |
| 3776 | echo test >conftest |
| 3777 | if test -f CONFTEST ; then |
| 3778 | cf_cv_mixedcase=no |
| 3779 | else |
| 3780 | cf_cv_mixedcase=yes |
| 3781 | fi |
| 3782 | rm -f conftest CONFTEST |
| 3783 | fi |
| 3784 | |
| 3785 | fi |
| 3786 | echo "$as_me:3786: result: $cf_cv_mixedcase" >&5 |
| 3787 | echo "${ECHO_T}$cf_cv_mixedcase" >&6 |
| 3788 | test "$cf_cv_mixedcase" = yes && |
| 3789 | cat >>confdefs.h <<\EOF |
| 3790 | #define MIXEDCASE_FILENAMES 1 |
| 3791 | EOF |
| 3792 | |
| 3793 | else |
| 3794 | cf_cv_mixedcase=$enable_mixedcase |
| 3795 | if test "x$enable_mixedcase" = "xyes" ; then |
| 3796 | |
| 3797 | cat >>confdefs.h <<\EOF |
| 3798 | #define MIXEDCASE_FILENAMES 1 |
| 3799 | EOF |
| 3800 | |
| 3801 | fi |
| 3802 | fi |
| 3803 | |
| 3804 | # do this after mixed-case option (tags/TAGS is not as important as tic). |
| 3805 | echo "$as_me:3805: checking whether ${MAKE-make} sets \${MAKE}" >&5 |
| 3806 | echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6 |
| 3807 | set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'` |
| 3808 | if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then |
| 3809 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3810 | else |
| 3811 | cat >conftest.make <<\EOF |
| 3812 | all: |
| 3813 | @echo 'ac_maketemp="${MAKE}"' |
| 3814 | EOF |
| 3815 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. |
| 3816 | eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=` |
| 3817 | if test -n "$ac_maketemp"; then |
| 3818 | eval ac_cv_prog_make_${ac_make}_set=yes |
| 3819 | else |
| 3820 | eval ac_cv_prog_make_${ac_make}_set=no |
| 3821 | fi |
| 3822 | rm -f conftest.make |
| 3823 | fi |
| 3824 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then |
| 3825 | echo "$as_me:3825: result: yes" >&5 |
| 3826 | echo "${ECHO_T}yes" >&6 |
| 3827 | SET_MAKE= |
| 3828 | else |
| 3829 | echo "$as_me:3829: result: no" >&5 |
| 3830 | echo "${ECHO_T}no" >&6 |
| 3831 | SET_MAKE="MAKE=${MAKE-make}" |
| 3832 | fi |
| 3833 | |
| 3834 | for ac_prog in exctags ctags |
| 3835 | do |
| 3836 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3837 | set dummy $ac_prog; ac_word=$2 |
| 3838 | echo "$as_me:3838: checking for $ac_word" >&5 |
| 3839 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3840 | if test "${ac_cv_prog_CTAGS+set}" = set; then |
| 3841 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3842 | else |
| 3843 | if test -n "$CTAGS"; then |
| 3844 | ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test. |
| 3845 | else |
| 3846 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3847 | ac_dummy="$PATH" |
| 3848 | for ac_dir in $ac_dummy; do |
| 3849 | IFS=$ac_save_IFS |
| 3850 | test -z "$ac_dir" && ac_dir=. |
| 3851 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 3852 | ac_cv_prog_CTAGS="$ac_prog" |
| 3853 | echo "$as_me:3853: found $ac_dir/$ac_word" >&5 |
| 3854 | break |
| 3855 | done |
| 3856 | |
| 3857 | fi |
| 3858 | fi |
| 3859 | CTAGS=$ac_cv_prog_CTAGS |
| 3860 | if test -n "$CTAGS"; then |
| 3861 | echo "$as_me:3861: result: $CTAGS" >&5 |
| 3862 | echo "${ECHO_T}$CTAGS" >&6 |
| 3863 | else |
| 3864 | echo "$as_me:3864: result: no" >&5 |
| 3865 | echo "${ECHO_T}no" >&6 |
| 3866 | fi |
| 3867 | |
| 3868 | test -n "$CTAGS" && break |
| 3869 | done |
| 3870 | |
| 3871 | for ac_prog in exetags etags |
| 3872 | do |
| 3873 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3874 | set dummy $ac_prog; ac_word=$2 |
| 3875 | echo "$as_me:3875: checking for $ac_word" >&5 |
| 3876 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3877 | if test "${ac_cv_prog_ETAGS+set}" = set; then |
| 3878 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3879 | else |
| 3880 | if test -n "$ETAGS"; then |
| 3881 | ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test. |
| 3882 | else |
| 3883 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3884 | ac_dummy="$PATH" |
| 3885 | for ac_dir in $ac_dummy; do |
| 3886 | IFS=$ac_save_IFS |
| 3887 | test -z "$ac_dir" && ac_dir=. |
| 3888 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 3889 | ac_cv_prog_ETAGS="$ac_prog" |
| 3890 | echo "$as_me:3890: found $ac_dir/$ac_word" >&5 |
| 3891 | break |
| 3892 | done |
| 3893 | |
| 3894 | fi |
| 3895 | fi |
| 3896 | ETAGS=$ac_cv_prog_ETAGS |
| 3897 | if test -n "$ETAGS"; then |
| 3898 | echo "$as_me:3898: result: $ETAGS" >&5 |
| 3899 | echo "${ECHO_T}$ETAGS" >&6 |
| 3900 | else |
| 3901 | echo "$as_me:3901: result: no" >&5 |
| 3902 | echo "${ECHO_T}no" >&6 |
| 3903 | fi |
| 3904 | |
| 3905 | test -n "$ETAGS" && break |
| 3906 | done |
| 3907 | |
| 3908 | # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args. |
| 3909 | set dummy ${CTAGS:-ctags}; ac_word=$2 |
| 3910 | echo "$as_me:3910: checking for $ac_word" >&5 |
| 3911 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3912 | if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then |
| 3913 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3914 | else |
| 3915 | if test -n "$MAKE_LOWER_TAGS"; then |
| 3916 | ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test. |
| 3917 | else |
| 3918 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3919 | ac_dummy="$PATH" |
| 3920 | for ac_dir in $ac_dummy; do |
| 3921 | IFS=$ac_save_IFS |
| 3922 | test -z "$ac_dir" && ac_dir=. |
| 3923 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 3924 | ac_cv_prog_MAKE_LOWER_TAGS="yes" |
| 3925 | echo "$as_me:3925: found $ac_dir/$ac_word" >&5 |
| 3926 | break |
| 3927 | done |
| 3928 | |
| 3929 | test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no" |
| 3930 | fi |
| 3931 | fi |
| 3932 | MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS |
| 3933 | if test -n "$MAKE_LOWER_TAGS"; then |
| 3934 | echo "$as_me:3934: result: $MAKE_LOWER_TAGS" >&5 |
| 3935 | echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6 |
| 3936 | else |
| 3937 | echo "$as_me:3937: result: no" >&5 |
| 3938 | echo "${ECHO_T}no" >&6 |
| 3939 | fi |
| 3940 | |
| 3941 | if test "$cf_cv_mixedcase" = yes ; then |
| 3942 | # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args. |
| 3943 | set dummy ${ETAGS:-etags}; ac_word=$2 |
| 3944 | echo "$as_me:3944: checking for $ac_word" >&5 |
| 3945 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 3946 | if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then |
| 3947 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3948 | else |
| 3949 | if test -n "$MAKE_UPPER_TAGS"; then |
| 3950 | ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test. |
| 3951 | else |
| 3952 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 3953 | ac_dummy="$PATH" |
| 3954 | for ac_dir in $ac_dummy; do |
| 3955 | IFS=$ac_save_IFS |
| 3956 | test -z "$ac_dir" && ac_dir=. |
| 3957 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 3958 | ac_cv_prog_MAKE_UPPER_TAGS="yes" |
| 3959 | echo "$as_me:3959: found $ac_dir/$ac_word" >&5 |
| 3960 | break |
| 3961 | done |
| 3962 | |
| 3963 | test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no" |
| 3964 | fi |
| 3965 | fi |
| 3966 | MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS |
| 3967 | if test -n "$MAKE_UPPER_TAGS"; then |
| 3968 | echo "$as_me:3968: result: $MAKE_UPPER_TAGS" >&5 |
| 3969 | echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6 |
| 3970 | else |
| 3971 | echo "$as_me:3971: result: no" >&5 |
| 3972 | echo "${ECHO_T}no" >&6 |
| 3973 | fi |
| 3974 | |
| 3975 | else |
| 3976 | MAKE_UPPER_TAGS=no |
| 3977 | fi |
| 3978 | |
| 3979 | if test "$MAKE_UPPER_TAGS" = yes ; then |
| 3980 | MAKE_UPPER_TAGS= |
| 3981 | else |
| 3982 | MAKE_UPPER_TAGS="#" |
| 3983 | fi |
| 3984 | |
| 3985 | if test "$MAKE_LOWER_TAGS" = yes ; then |
| 3986 | MAKE_LOWER_TAGS= |
| 3987 | else |
| 3988 | MAKE_LOWER_TAGS="#" |
| 3989 | fi |
| 3990 | |
| 3991 | echo "$as_me:3991: checking for makeflags variable" >&5 |
| 3992 | echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6 |
| 3993 | if test "${cf_cv_makeflags+set}" = set; then |
| 3994 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 3995 | else |
| 3996 | |
| 3997 | cf_cv_makeflags='' |
| 3998 | for cf_option in '-${MAKEFLAGS}' '${MFLAGS}' |
| 3999 | do |
| 4000 | cat >cf_makeflags.tmp <<CF_EOF |
| 4001 | SHELL = $SHELL |
| 4002 | all : |
| 4003 | @ echo '.$cf_option' |
| 4004 | CF_EOF |
| 4005 | cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | fgrep -v "ing directory" | sed -e 's,[ ]*$,,'` |
| 4006 | case "$cf_result" in |
| 4007 | (.*k|.*kw) |
| 4008 | cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null` |
| 4009 | case "$cf_result" in |
| 4010 | (.*CC=*) cf_cv_makeflags= |
| 4011 | ;; |
| 4012 | (*) cf_cv_makeflags=$cf_option |
| 4013 | ;; |
| 4014 | esac |
| 4015 | break |
| 4016 | ;; |
| 4017 | (.-) ;; |
| 4018 | (*) echo "given option \"$cf_option\", no match \"$cf_result\"" |
| 4019 | ;; |
| 4020 | esac |
| 4021 | done |
| 4022 | rm -f cf_makeflags.tmp |
| 4023 | |
| 4024 | fi |
| 4025 | echo "$as_me:4025: result: $cf_cv_makeflags" >&5 |
| 4026 | echo "${ECHO_T}$cf_cv_makeflags" >&6 |
| 4027 | |
| 4028 | if test -n "$ac_tool_prefix"; then |
| 4029 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
| 4030 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
| 4031 | echo "$as_me:4031: checking for $ac_word" >&5 |
| 4032 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4033 | if test "${ac_cv_prog_RANLIB+set}" = set; then |
| 4034 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4035 | else |
| 4036 | if test -n "$RANLIB"; then |
| 4037 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 4038 | else |
| 4039 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4040 | ac_dummy="$PATH" |
| 4041 | for ac_dir in $ac_dummy; do |
| 4042 | IFS=$ac_save_IFS |
| 4043 | test -z "$ac_dir" && ac_dir=. |
| 4044 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4045 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
| 4046 | echo "$as_me:4046: found $ac_dir/$ac_word" >&5 |
| 4047 | break |
| 4048 | done |
| 4049 | |
| 4050 | fi |
| 4051 | fi |
| 4052 | RANLIB=$ac_cv_prog_RANLIB |
| 4053 | if test -n "$RANLIB"; then |
| 4054 | echo "$as_me:4054: result: $RANLIB" >&5 |
| 4055 | echo "${ECHO_T}$RANLIB" >&6 |
| 4056 | else |
| 4057 | echo "$as_me:4057: result: no" >&5 |
| 4058 | echo "${ECHO_T}no" >&6 |
| 4059 | fi |
| 4060 | |
| 4061 | fi |
| 4062 | if test -z "$ac_cv_prog_RANLIB"; then |
| 4063 | ac_ct_RANLIB=$RANLIB |
| 4064 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 4065 | set dummy ranlib; ac_word=$2 |
| 4066 | echo "$as_me:4066: checking for $ac_word" >&5 |
| 4067 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4068 | if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then |
| 4069 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4070 | else |
| 4071 | if test -n "$ac_ct_RANLIB"; then |
| 4072 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. |
| 4073 | else |
| 4074 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4075 | ac_dummy="$PATH" |
| 4076 | for ac_dir in $ac_dummy; do |
| 4077 | IFS=$ac_save_IFS |
| 4078 | test -z "$ac_dir" && ac_dir=. |
| 4079 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4080 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
| 4081 | echo "$as_me:4081: found $ac_dir/$ac_word" >&5 |
| 4082 | break |
| 4083 | done |
| 4084 | |
| 4085 | test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB="':'" |
| 4086 | fi |
| 4087 | fi |
| 4088 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
| 4089 | if test -n "$ac_ct_RANLIB"; then |
| 4090 | echo "$as_me:4090: result: $ac_ct_RANLIB" >&5 |
| 4091 | echo "${ECHO_T}$ac_ct_RANLIB" >&6 |
| 4092 | else |
| 4093 | echo "$as_me:4093: result: no" >&5 |
| 4094 | echo "${ECHO_T}no" >&6 |
| 4095 | fi |
| 4096 | |
| 4097 | RANLIB=$ac_ct_RANLIB |
| 4098 | else |
| 4099 | RANLIB="$ac_cv_prog_RANLIB" |
| 4100 | fi |
| 4101 | |
| 4102 | if test -n "$ac_tool_prefix"; then |
| 4103 | # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args. |
| 4104 | set dummy ${ac_tool_prefix}ld; ac_word=$2 |
| 4105 | echo "$as_me:4105: checking for $ac_word" >&5 |
| 4106 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4107 | if test "${ac_cv_prog_LD+set}" = set; then |
| 4108 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4109 | else |
| 4110 | if test -n "$LD"; then |
| 4111 | ac_cv_prog_LD="$LD" # Let the user override the test. |
| 4112 | else |
| 4113 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4114 | ac_dummy="$PATH" |
| 4115 | for ac_dir in $ac_dummy; do |
| 4116 | IFS=$ac_save_IFS |
| 4117 | test -z "$ac_dir" && ac_dir=. |
| 4118 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4119 | ac_cv_prog_LD="${ac_tool_prefix}ld" |
| 4120 | echo "$as_me:4120: found $ac_dir/$ac_word" >&5 |
| 4121 | break |
| 4122 | done |
| 4123 | |
| 4124 | fi |
| 4125 | fi |
| 4126 | LD=$ac_cv_prog_LD |
| 4127 | if test -n "$LD"; then |
| 4128 | echo "$as_me:4128: result: $LD" >&5 |
| 4129 | echo "${ECHO_T}$LD" >&6 |
| 4130 | else |
| 4131 | echo "$as_me:4131: result: no" >&5 |
| 4132 | echo "${ECHO_T}no" >&6 |
| 4133 | fi |
| 4134 | |
| 4135 | fi |
| 4136 | if test -z "$ac_cv_prog_LD"; then |
| 4137 | ac_ct_LD=$LD |
| 4138 | # Extract the first word of "ld", so it can be a program name with args. |
| 4139 | set dummy ld; ac_word=$2 |
| 4140 | echo "$as_me:4140: checking for $ac_word" >&5 |
| 4141 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4142 | if test "${ac_cv_prog_ac_ct_LD+set}" = set; then |
| 4143 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4144 | else |
| 4145 | if test -n "$ac_ct_LD"; then |
| 4146 | ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test. |
| 4147 | else |
| 4148 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4149 | ac_dummy="$PATH" |
| 4150 | for ac_dir in $ac_dummy; do |
| 4151 | IFS=$ac_save_IFS |
| 4152 | test -z "$ac_dir" && ac_dir=. |
| 4153 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4154 | ac_cv_prog_ac_ct_LD="ld" |
| 4155 | echo "$as_me:4155: found $ac_dir/$ac_word" >&5 |
| 4156 | break |
| 4157 | done |
| 4158 | |
| 4159 | test -z "$ac_cv_prog_ac_ct_LD" && ac_cv_prog_ac_ct_LD="ld" |
| 4160 | fi |
| 4161 | fi |
| 4162 | ac_ct_LD=$ac_cv_prog_ac_ct_LD |
| 4163 | if test -n "$ac_ct_LD"; then |
| 4164 | echo "$as_me:4164: result: $ac_ct_LD" >&5 |
| 4165 | echo "${ECHO_T}$ac_ct_LD" >&6 |
| 4166 | else |
| 4167 | echo "$as_me:4167: result: no" >&5 |
| 4168 | echo "${ECHO_T}no" >&6 |
| 4169 | fi |
| 4170 | |
| 4171 | LD=$ac_ct_LD |
| 4172 | else |
| 4173 | LD="$ac_cv_prog_LD" |
| 4174 | fi |
| 4175 | |
| 4176 | if test -n "$ac_tool_prefix"; then |
| 4177 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. |
| 4178 | set dummy ${ac_tool_prefix}ar; ac_word=$2 |
| 4179 | echo "$as_me:4179: checking for $ac_word" >&5 |
| 4180 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4181 | if test "${ac_cv_prog_AR+set}" = set; then |
| 4182 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4183 | else |
| 4184 | if test -n "$AR"; then |
| 4185 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 4186 | else |
| 4187 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4188 | ac_dummy="$PATH" |
| 4189 | for ac_dir in $ac_dummy; do |
| 4190 | IFS=$ac_save_IFS |
| 4191 | test -z "$ac_dir" && ac_dir=. |
| 4192 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4193 | ac_cv_prog_AR="${ac_tool_prefix}ar" |
| 4194 | echo "$as_me:4194: found $ac_dir/$ac_word" >&5 |
| 4195 | break |
| 4196 | done |
| 4197 | |
| 4198 | fi |
| 4199 | fi |
| 4200 | AR=$ac_cv_prog_AR |
| 4201 | if test -n "$AR"; then |
| 4202 | echo "$as_me:4202: result: $AR" >&5 |
| 4203 | echo "${ECHO_T}$AR" >&6 |
| 4204 | else |
| 4205 | echo "$as_me:4205: result: no" >&5 |
| 4206 | echo "${ECHO_T}no" >&6 |
| 4207 | fi |
| 4208 | |
| 4209 | fi |
| 4210 | if test -z "$ac_cv_prog_AR"; then |
| 4211 | ac_ct_AR=$AR |
| 4212 | # Extract the first word of "ar", so it can be a program name with args. |
| 4213 | set dummy ar; ac_word=$2 |
| 4214 | echo "$as_me:4214: checking for $ac_word" >&5 |
| 4215 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4216 | if test "${ac_cv_prog_ac_ct_AR+set}" = set; then |
| 4217 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4218 | else |
| 4219 | if test -n "$ac_ct_AR"; then |
| 4220 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. |
| 4221 | else |
| 4222 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4223 | ac_dummy="$PATH" |
| 4224 | for ac_dir in $ac_dummy; do |
| 4225 | IFS=$ac_save_IFS |
| 4226 | test -z "$ac_dir" && ac_dir=. |
| 4227 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4228 | ac_cv_prog_ac_ct_AR="ar" |
| 4229 | echo "$as_me:4229: found $ac_dir/$ac_word" >&5 |
| 4230 | break |
| 4231 | done |
| 4232 | |
| 4233 | test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar" |
| 4234 | fi |
| 4235 | fi |
| 4236 | ac_ct_AR=$ac_cv_prog_ac_ct_AR |
| 4237 | if test -n "$ac_ct_AR"; then |
| 4238 | echo "$as_me:4238: result: $ac_ct_AR" >&5 |
| 4239 | echo "${ECHO_T}$ac_ct_AR" >&6 |
| 4240 | else |
| 4241 | echo "$as_me:4241: result: no" >&5 |
| 4242 | echo "${ECHO_T}no" >&6 |
| 4243 | fi |
| 4244 | |
| 4245 | AR=$ac_ct_AR |
| 4246 | else |
| 4247 | AR="$ac_cv_prog_AR" |
| 4248 | fi |
| 4249 | |
| 4250 | if test -n "$ac_tool_prefix"; then |
| 4251 | # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args. |
| 4252 | set dummy ${ac_tool_prefix}nm; ac_word=$2 |
| 4253 | echo "$as_me:4253: checking for $ac_word" >&5 |
| 4254 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4255 | if test "${ac_cv_prog_NM+set}" = set; then |
| 4256 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4257 | else |
| 4258 | if test -n "$NM"; then |
| 4259 | ac_cv_prog_NM="$NM" # Let the user override the test. |
| 4260 | else |
| 4261 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4262 | ac_dummy="$PATH" |
| 4263 | for ac_dir in $ac_dummy; do |
| 4264 | IFS=$ac_save_IFS |
| 4265 | test -z "$ac_dir" && ac_dir=. |
| 4266 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4267 | ac_cv_prog_NM="${ac_tool_prefix}nm" |
| 4268 | echo "$as_me:4268: found $ac_dir/$ac_word" >&5 |
| 4269 | break |
| 4270 | done |
| 4271 | |
| 4272 | fi |
| 4273 | fi |
| 4274 | NM=$ac_cv_prog_NM |
| 4275 | if test -n "$NM"; then |
| 4276 | echo "$as_me:4276: result: $NM" >&5 |
| 4277 | echo "${ECHO_T}$NM" >&6 |
| 4278 | else |
| 4279 | echo "$as_me:4279: result: no" >&5 |
| 4280 | echo "${ECHO_T}no" >&6 |
| 4281 | fi |
| 4282 | |
| 4283 | fi |
| 4284 | if test -z "$ac_cv_prog_NM"; then |
| 4285 | ac_ct_NM=$NM |
| 4286 | # Extract the first word of "nm", so it can be a program name with args. |
| 4287 | set dummy nm; ac_word=$2 |
| 4288 | echo "$as_me:4288: checking for $ac_word" >&5 |
| 4289 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4290 | if test "${ac_cv_prog_ac_ct_NM+set}" = set; then |
| 4291 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4292 | else |
| 4293 | if test -n "$ac_ct_NM"; then |
| 4294 | ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. |
| 4295 | else |
| 4296 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4297 | ac_dummy="$PATH" |
| 4298 | for ac_dir in $ac_dummy; do |
| 4299 | IFS=$ac_save_IFS |
| 4300 | test -z "$ac_dir" && ac_dir=. |
| 4301 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4302 | ac_cv_prog_ac_ct_NM="nm" |
| 4303 | echo "$as_me:4303: found $ac_dir/$ac_word" >&5 |
| 4304 | break |
| 4305 | done |
| 4306 | |
| 4307 | test -z "$ac_cv_prog_ac_ct_NM" && ac_cv_prog_ac_ct_NM="nm" |
| 4308 | fi |
| 4309 | fi |
| 4310 | ac_ct_NM=$ac_cv_prog_ac_ct_NM |
| 4311 | if test -n "$ac_ct_NM"; then |
| 4312 | echo "$as_me:4312: result: $ac_ct_NM" >&5 |
| 4313 | echo "${ECHO_T}$ac_ct_NM" >&6 |
| 4314 | else |
| 4315 | echo "$as_me:4315: result: no" >&5 |
| 4316 | echo "${ECHO_T}no" >&6 |
| 4317 | fi |
| 4318 | |
| 4319 | NM=$ac_ct_NM |
| 4320 | else |
| 4321 | NM="$ac_cv_prog_NM" |
| 4322 | fi |
| 4323 | |
| 4324 | if test -n "$ac_tool_prefix"; then |
| 4325 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. |
| 4326 | set dummy ${ac_tool_prefix}ar; ac_word=$2 |
| 4327 | echo "$as_me:4327: checking for $ac_word" >&5 |
| 4328 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4329 | if test "${ac_cv_prog_AR+set}" = set; then |
| 4330 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4331 | else |
| 4332 | if test -n "$AR"; then |
| 4333 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 4334 | else |
| 4335 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4336 | ac_dummy="$PATH" |
| 4337 | for ac_dir in $ac_dummy; do |
| 4338 | IFS=$ac_save_IFS |
| 4339 | test -z "$ac_dir" && ac_dir=. |
| 4340 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4341 | ac_cv_prog_AR="${ac_tool_prefix}ar" |
| 4342 | echo "$as_me:4342: found $ac_dir/$ac_word" >&5 |
| 4343 | break |
| 4344 | done |
| 4345 | |
| 4346 | fi |
| 4347 | fi |
| 4348 | AR=$ac_cv_prog_AR |
| 4349 | if test -n "$AR"; then |
| 4350 | echo "$as_me:4350: result: $AR" >&5 |
| 4351 | echo "${ECHO_T}$AR" >&6 |
| 4352 | else |
| 4353 | echo "$as_me:4353: result: no" >&5 |
| 4354 | echo "${ECHO_T}no" >&6 |
| 4355 | fi |
| 4356 | |
| 4357 | fi |
| 4358 | if test -z "$ac_cv_prog_AR"; then |
| 4359 | ac_ct_AR=$AR |
| 4360 | # Extract the first word of "ar", so it can be a program name with args. |
| 4361 | set dummy ar; ac_word=$2 |
| 4362 | echo "$as_me:4362: checking for $ac_word" >&5 |
| 4363 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4364 | if test "${ac_cv_prog_ac_ct_AR+set}" = set; then |
| 4365 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4366 | else |
| 4367 | if test -n "$ac_ct_AR"; then |
| 4368 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. |
| 4369 | else |
| 4370 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4371 | ac_dummy="$PATH" |
| 4372 | for ac_dir in $ac_dummy; do |
| 4373 | IFS=$ac_save_IFS |
| 4374 | test -z "$ac_dir" && ac_dir=. |
| 4375 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4376 | ac_cv_prog_ac_ct_AR="ar" |
| 4377 | echo "$as_me:4377: found $ac_dir/$ac_word" >&5 |
| 4378 | break |
| 4379 | done |
| 4380 | |
| 4381 | test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="ar" |
| 4382 | fi |
| 4383 | fi |
| 4384 | ac_ct_AR=$ac_cv_prog_ac_ct_AR |
| 4385 | if test -n "$ac_ct_AR"; then |
| 4386 | echo "$as_me:4386: result: $ac_ct_AR" >&5 |
| 4387 | echo "${ECHO_T}$ac_ct_AR" >&6 |
| 4388 | else |
| 4389 | echo "$as_me:4389: result: no" >&5 |
| 4390 | echo "${ECHO_T}no" >&6 |
| 4391 | fi |
| 4392 | |
| 4393 | AR=$ac_ct_AR |
| 4394 | else |
| 4395 | AR="$ac_cv_prog_AR" |
| 4396 | fi |
| 4397 | |
| 4398 | echo "$as_me:4398: checking for options to update archives" >&5 |
| 4399 | echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6 |
| 4400 | if test "${cf_cv_ar_flags+set}" = set; then |
| 4401 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4402 | else |
| 4403 | |
| 4404 | cf_cv_ar_flags=unknown |
| 4405 | for cf_ar_flags in -curv curv -crv crv -cqv cqv -rv rv |
| 4406 | do |
| 4407 | |
| 4408 | # check if $ARFLAGS already contains this choice |
| 4409 | if test "x$ARFLAGS" != "x" ; then |
| 4410 | cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"` |
| 4411 | if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then |
| 4412 | cf_cv_ar_flags= |
| 4413 | break |
| 4414 | fi |
| 4415 | fi |
| 4416 | |
| 4417 | rm -f conftest.$ac_cv_objext |
| 4418 | rm -f conftest.a |
| 4419 | |
| 4420 | cat >conftest.$ac_ext <<EOF |
| 4421 | #line 4421 "configure" |
| 4422 | int testdata[3] = { 123, 456, 789 }; |
| 4423 | EOF |
| 4424 | if { (eval echo "$as_me:4424: \"$ac_compile\"") >&5 |
| 4425 | (eval $ac_compile) 2>&5 |
| 4426 | ac_status=$? |
| 4427 | echo "$as_me:4427: \$? = $ac_status" >&5 |
| 4428 | (exit $ac_status); } ; then |
| 4429 | echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5 |
| 4430 | $AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null |
| 4431 | if test -f conftest.a ; then |
| 4432 | cf_cv_ar_flags=$cf_ar_flags |
| 4433 | break |
| 4434 | fi |
| 4435 | else |
| 4436 | test -n "$verbose" && echo " cannot compile test-program" 1>&6 |
| 4437 | |
| 4438 | echo "${as_me:-configure}:4438: testing cannot compile test-program ..." 1>&5 |
| 4439 | |
| 4440 | break |
| 4441 | fi |
| 4442 | done |
| 4443 | rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext |
| 4444 | |
| 4445 | fi |
| 4446 | echo "$as_me:4446: result: $cf_cv_ar_flags" >&5 |
| 4447 | echo "${ECHO_T}$cf_cv_ar_flags" >&6 |
| 4448 | |
| 4449 | if test -n "$ARFLAGS" ; then |
| 4450 | if test -n "$cf_cv_ar_flags" ; then |
| 4451 | ARFLAGS="$ARFLAGS $cf_cv_ar_flags" |
| 4452 | fi |
| 4453 | else |
| 4454 | ARFLAGS=$cf_cv_ar_flags |
| 4455 | fi |
| 4456 | |
| 4457 | echo "$as_me:4457: checking if you have specified an install-prefix" >&5 |
| 4458 | echo $ECHO_N "checking if you have specified an install-prefix... $ECHO_C" >&6 |
| 4459 | |
| 4460 | # Check whether --with-install-prefix or --without-install-prefix was given. |
| 4461 | if test "${with_install_prefix+set}" = set; then |
| 4462 | withval="$with_install_prefix" |
| 4463 | case "x$withval" in |
| 4464 | (xyes|xno) |
| 4465 | ;; |
| 4466 | (*) DESTDIR="$withval" |
| 4467 | ;; |
| 4468 | esac |
| 4469 | fi; |
| 4470 | echo "$as_me:4470: result: $DESTDIR" >&5 |
| 4471 | echo "${ECHO_T}$DESTDIR" >&6 |
| 4472 | |
| 4473 | ############################################################################### |
| 4474 | |
| 4475 | # If we're cross-compiling, allow the user to override the tools and their |
| 4476 | # options. The configure script is oriented toward identifying the host |
| 4477 | # compiler, etc., but we need a build compiler to generate parts of the source. |
| 4478 | |
| 4479 | if test "$cross_compiling" = yes ; then |
| 4480 | |
| 4481 | # defaults that we might want to override |
| 4482 | : ${BUILD_CFLAGS:=''} |
| 4483 | : ${BUILD_CPPFLAGS:=''} |
| 4484 | : ${BUILD_LDFLAGS:=''} |
| 4485 | : ${BUILD_LIBS:=''} |
| 4486 | : ${BUILD_EXEEXT:='$x'} |
| 4487 | : ${BUILD_OBJEXT:='o'} |
| 4488 | |
| 4489 | # Check whether --with-build-cc or --without-build-cc was given. |
| 4490 | if test "${with_build_cc+set}" = set; then |
| 4491 | withval="$with_build_cc" |
| 4492 | BUILD_CC="$withval" |
| 4493 | else |
| 4494 | for ac_prog in gcc cc cl |
| 4495 | do |
| 4496 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4497 | set dummy $ac_prog; ac_word=$2 |
| 4498 | echo "$as_me:4498: checking for $ac_word" >&5 |
| 4499 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4500 | if test "${ac_cv_prog_BUILD_CC+set}" = set; then |
| 4501 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4502 | else |
| 4503 | if test -n "$BUILD_CC"; then |
| 4504 | ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test. |
| 4505 | else |
| 4506 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4507 | ac_dummy="$PATH" |
| 4508 | for ac_dir in $ac_dummy; do |
| 4509 | IFS=$ac_save_IFS |
| 4510 | test -z "$ac_dir" && ac_dir=. |
| 4511 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4512 | ac_cv_prog_BUILD_CC="$ac_prog" |
| 4513 | echo "$as_me:4513: found $ac_dir/$ac_word" >&5 |
| 4514 | break |
| 4515 | done |
| 4516 | |
| 4517 | fi |
| 4518 | fi |
| 4519 | BUILD_CC=$ac_cv_prog_BUILD_CC |
| 4520 | if test -n "$BUILD_CC"; then |
| 4521 | echo "$as_me:4521: result: $BUILD_CC" >&5 |
| 4522 | echo "${ECHO_T}$BUILD_CC" >&6 |
| 4523 | else |
| 4524 | echo "$as_me:4524: result: no" >&5 |
| 4525 | echo "${ECHO_T}no" >&6 |
| 4526 | fi |
| 4527 | |
| 4528 | test -n "$BUILD_CC" && break |
| 4529 | done |
| 4530 | |
| 4531 | fi; |
| 4532 | echo "$as_me:4532: checking for native build C compiler" >&5 |
| 4533 | echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6 |
| 4534 | echo "$as_me:4534: result: $BUILD_CC" >&5 |
| 4535 | echo "${ECHO_T}$BUILD_CC" >&6 |
| 4536 | |
| 4537 | echo "$as_me:4537: checking for native build C preprocessor" >&5 |
| 4538 | echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6 |
| 4539 | |
| 4540 | # Check whether --with-build-cpp or --without-build-cpp was given. |
| 4541 | if test "${with_build_cpp+set}" = set; then |
| 4542 | withval="$with_build_cpp" |
| 4543 | BUILD_CPP="$withval" |
| 4544 | else |
| 4545 | BUILD_CPP='${BUILD_CC} -E' |
| 4546 | fi; |
| 4547 | echo "$as_me:4547: result: $BUILD_CPP" >&5 |
| 4548 | echo "${ECHO_T}$BUILD_CPP" >&6 |
| 4549 | |
| 4550 | echo "$as_me:4550: checking for native build C flags" >&5 |
| 4551 | echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6 |
| 4552 | |
| 4553 | # Check whether --with-build-cflags or --without-build-cflags was given. |
| 4554 | if test "${with_build_cflags+set}" = set; then |
| 4555 | withval="$with_build_cflags" |
| 4556 | BUILD_CFLAGS="$withval" |
| 4557 | fi; |
| 4558 | echo "$as_me:4558: result: $BUILD_CFLAGS" >&5 |
| 4559 | echo "${ECHO_T}$BUILD_CFLAGS" >&6 |
| 4560 | |
| 4561 | echo "$as_me:4561: checking for native build C preprocessor-flags" >&5 |
| 4562 | echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6 |
| 4563 | |
| 4564 | # Check whether --with-build-cppflags or --without-build-cppflags was given. |
| 4565 | if test "${with_build_cppflags+set}" = set; then |
| 4566 | withval="$with_build_cppflags" |
| 4567 | BUILD_CPPFLAGS="$withval" |
| 4568 | fi; |
| 4569 | echo "$as_me:4569: result: $BUILD_CPPFLAGS" >&5 |
| 4570 | echo "${ECHO_T}$BUILD_CPPFLAGS" >&6 |
| 4571 | |
| 4572 | echo "$as_me:4572: checking for native build linker-flags" >&5 |
| 4573 | echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6 |
| 4574 | |
| 4575 | # Check whether --with-build-ldflags or --without-build-ldflags was given. |
| 4576 | if test "${with_build_ldflags+set}" = set; then |
| 4577 | withval="$with_build_ldflags" |
| 4578 | BUILD_LDFLAGS="$withval" |
| 4579 | fi; |
| 4580 | echo "$as_me:4580: result: $BUILD_LDFLAGS" >&5 |
| 4581 | echo "${ECHO_T}$BUILD_LDFLAGS" >&6 |
| 4582 | |
| 4583 | echo "$as_me:4583: checking for native build linker-libraries" >&5 |
| 4584 | echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6 |
| 4585 | |
| 4586 | # Check whether --with-build-libs or --without-build-libs was given. |
| 4587 | if test "${with_build_libs+set}" = set; then |
| 4588 | withval="$with_build_libs" |
| 4589 | BUILD_LIBS="$withval" |
| 4590 | fi; |
| 4591 | echo "$as_me:4591: result: $BUILD_LIBS" >&5 |
| 4592 | echo "${ECHO_T}$BUILD_LIBS" >&6 |
| 4593 | |
| 4594 | # this assumes we're on Unix. |
| 4595 | BUILD_EXEEXT= |
| 4596 | BUILD_OBJEXT=o |
| 4597 | |
| 4598 | : ${BUILD_CC:='${CC}'} |
| 4599 | |
| 4600 | if ( test "$BUILD_CC" = "$CC" || test "$BUILD_CC" = '${CC}' ) ; then |
| 4601 | { { echo "$as_me:4601: error: Cross-build requires two compilers. |
| 4602 | Use --with-build-cc to specify the native compiler." >&5 |
| 4603 | echo "$as_me: error: Cross-build requires two compilers. |
| 4604 | Use --with-build-cc to specify the native compiler." >&2;} |
| 4605 | { (exit 1); exit 1; }; } |
| 4606 | fi |
| 4607 | |
| 4608 | else |
| 4609 | : ${BUILD_CC:='${CC}'} |
| 4610 | : ${BUILD_CPP:='${CPP}'} |
| 4611 | : ${BUILD_CFLAGS:='${CFLAGS}'} |
| 4612 | : ${BUILD_CPPFLAGS:='${CPPFLAGS}'} |
| 4613 | : ${BUILD_LDFLAGS:='${LDFLAGS}'} |
| 4614 | : ${BUILD_LIBS:='${LIBS}'} |
| 4615 | : ${BUILD_EXEEXT:='$x'} |
| 4616 | : ${BUILD_OBJEXT:='o'} |
| 4617 | fi |
| 4618 | |
| 4619 | ############################################################################### |
| 4620 | |
| 4621 | ### Options to allow the user to specify the set of libraries which are used. |
| 4622 | ### Use "--without-normal --with-shared" to allow the default model to be |
| 4623 | ### shared, for example. |
| 4624 | cf_list_models="" |
| 4625 | |
| 4626 | echo "$as_me:4626: checking if libtool -version-number should be used" >&5 |
| 4627 | echo $ECHO_N "checking if libtool -version-number should be used... $ECHO_C" >&6 |
| 4628 | |
| 4629 | # Check whether --enable-libtool-version or --disable-libtool-version was given. |
| 4630 | if test "${enable_libtool_version+set}" = set; then |
| 4631 | enableval="$enable_libtool_version" |
| 4632 | test "$enableval" != no && enableval=yes |
| 4633 | if test "$enableval" != "yes" ; then |
| 4634 | cf_libtool_version=no |
| 4635 | else |
| 4636 | cf_libtool_version=yes |
| 4637 | fi |
| 4638 | else |
| 4639 | enableval=yes |
| 4640 | cf_libtool_version=yes |
| 4641 | |
| 4642 | fi; |
| 4643 | echo "$as_me:4643: result: $cf_libtool_version" >&5 |
| 4644 | echo "${ECHO_T}$cf_libtool_version" >&6 |
| 4645 | |
| 4646 | if test "$cf_libtool_version" = yes ; then |
| 4647 | LIBTOOL_VERSION="-version-number" |
| 4648 | else |
| 4649 | LIBTOOL_VERSION="-version-info" |
| 4650 | case "x$VERSION" in |
| 4651 | (x) |
| 4652 | { echo "$as_me:4652: WARNING: VERSION was not set" >&5 |
| 4653 | echo "$as_me: WARNING: VERSION was not set" >&2;} |
| 4654 | ;; |
| 4655 | (x*.*.*) |
| 4656 | ABI_VERSION="$VERSION" |
| 4657 | test -n "$verbose" && echo " ABI_VERSION: $ABI_VERSION" 1>&6 |
| 4658 | |
| 4659 | echo "${as_me:-configure}:4659: testing ABI_VERSION: $ABI_VERSION ..." 1>&5 |
| 4660 | |
| 4661 | ;; |
| 4662 | (x*:*:*) |
| 4663 | ABI_VERSION=`echo "$VERSION" | sed -e 's/:/./g'` |
| 4664 | test -n "$verbose" && echo " ABI_VERSION: $ABI_VERSION" 1>&6 |
| 4665 | |
| 4666 | echo "${as_me:-configure}:4666: testing ABI_VERSION: $ABI_VERSION ..." 1>&5 |
| 4667 | |
| 4668 | ;; |
| 4669 | (*) |
| 4670 | { echo "$as_me:4670: WARNING: unexpected VERSION value: $VERSION" >&5 |
| 4671 | echo "$as_me: WARNING: unexpected VERSION value: $VERSION" >&2;} |
| 4672 | ;; |
| 4673 | esac |
| 4674 | fi |
| 4675 | |
| 4676 | LIBTOOL= |
| 4677 | |
| 4678 | # common library maintenance symbols that are convenient for libtool scripts: |
| 4679 | LIB_CREATE='${AR} -cr' |
| 4680 | LIB_OBJECT='${OBJECTS}' |
| 4681 | LIB_SUFFIX=.a |
| 4682 | LIB_PREP="$RANLIB" |
| 4683 | |
| 4684 | # symbols used to prop libtool up to enable it to determine what it should be |
| 4685 | # doing: |
| 4686 | LIB_CLEAN= |
| 4687 | LIB_COMPILE= |
| 4688 | LIB_LINK='${CC}' |
| 4689 | LIB_INSTALL= |
| 4690 | LIB_UNINSTALL= |
| 4691 | |
| 4692 | echo "$as_me:4692: checking if you want to build libraries with libtool" >&5 |
| 4693 | echo $ECHO_N "checking if you want to build libraries with libtool... $ECHO_C" >&6 |
| 4694 | |
| 4695 | # Check whether --with-libtool or --without-libtool was given. |
| 4696 | if test "${with_libtool+set}" = set; then |
| 4697 | withval="$with_libtool" |
| 4698 | with_libtool=$withval |
| 4699 | else |
| 4700 | with_libtool=no |
| 4701 | fi; |
| 4702 | echo "$as_me:4702: result: $with_libtool" >&5 |
| 4703 | echo "${ECHO_T}$with_libtool" >&6 |
| 4704 | if test "$with_libtool" != "no"; then |
| 4705 | |
| 4706 | if test "$with_libtool" != "yes" ; then |
| 4707 | |
| 4708 | if test "x$prefix" != xNONE; then |
| 4709 | cf_path_syntax="$prefix" |
| 4710 | else |
| 4711 | cf_path_syntax="$ac_default_prefix" |
| 4712 | fi |
| 4713 | |
| 4714 | case ".$with_libtool" in |
| 4715 | (.\$\(*\)*|.\'*\'*) |
| 4716 | ;; |
| 4717 | (..|./*|.\\*) |
| 4718 | ;; |
| 4719 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 4720 | ;; |
| 4721 | (.\${*prefix}*|.\${*dir}*) |
| 4722 | eval with_libtool="$with_libtool" |
| 4723 | case ".$with_libtool" in |
| 4724 | (.NONE/*) |
| 4725 | with_libtool=`echo $with_libtool | sed -e s%NONE%$cf_path_syntax%` |
| 4726 | ;; |
| 4727 | esac |
| 4728 | ;; |
| 4729 | (.no|.NONE/*) |
| 4730 | with_libtool=`echo $with_libtool | sed -e s%NONE%$cf_path_syntax%` |
| 4731 | ;; |
| 4732 | (*) |
| 4733 | { { echo "$as_me:4733: error: expected a pathname, not \"$with_libtool\"" >&5 |
| 4734 | echo "$as_me: error: expected a pathname, not \"$with_libtool\"" >&2;} |
| 4735 | { (exit 1); exit 1; }; } |
| 4736 | ;; |
| 4737 | esac |
| 4738 | |
| 4739 | LIBTOOL=$with_libtool |
| 4740 | else |
| 4741 | if test -n "$ac_tool_prefix"; then |
| 4742 | for ac_prog in libtool glibtool |
| 4743 | do |
| 4744 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 4745 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
| 4746 | echo "$as_me:4746: checking for $ac_word" >&5 |
| 4747 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4748 | if test "${ac_cv_prog_LIBTOOL+set}" = set; then |
| 4749 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4750 | else |
| 4751 | if test -n "$LIBTOOL"; then |
| 4752 | ac_cv_prog_LIBTOOL="$LIBTOOL" # Let the user override the test. |
| 4753 | else |
| 4754 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4755 | ac_dummy="$PATH" |
| 4756 | for ac_dir in $ac_dummy; do |
| 4757 | IFS=$ac_save_IFS |
| 4758 | test -z "$ac_dir" && ac_dir=. |
| 4759 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4760 | ac_cv_prog_LIBTOOL="$ac_tool_prefix$ac_prog" |
| 4761 | echo "$as_me:4761: found $ac_dir/$ac_word" >&5 |
| 4762 | break |
| 4763 | done |
| 4764 | |
| 4765 | fi |
| 4766 | fi |
| 4767 | LIBTOOL=$ac_cv_prog_LIBTOOL |
| 4768 | if test -n "$LIBTOOL"; then |
| 4769 | echo "$as_me:4769: result: $LIBTOOL" >&5 |
| 4770 | echo "${ECHO_T}$LIBTOOL" >&6 |
| 4771 | else |
| 4772 | echo "$as_me:4772: result: no" >&5 |
| 4773 | echo "${ECHO_T}no" >&6 |
| 4774 | fi |
| 4775 | |
| 4776 | test -n "$LIBTOOL" && break |
| 4777 | done |
| 4778 | fi |
| 4779 | if test -z "$LIBTOOL"; then |
| 4780 | ac_ct_LIBTOOL=$LIBTOOL |
| 4781 | for ac_prog in libtool glibtool |
| 4782 | do |
| 4783 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4784 | set dummy $ac_prog; ac_word=$2 |
| 4785 | echo "$as_me:4785: checking for $ac_word" >&5 |
| 4786 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4787 | if test "${ac_cv_prog_ac_ct_LIBTOOL+set}" = set; then |
| 4788 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4789 | else |
| 4790 | if test -n "$ac_ct_LIBTOOL"; then |
| 4791 | ac_cv_prog_ac_ct_LIBTOOL="$ac_ct_LIBTOOL" # Let the user override the test. |
| 4792 | else |
| 4793 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4794 | ac_dummy="$PATH" |
| 4795 | for ac_dir in $ac_dummy; do |
| 4796 | IFS=$ac_save_IFS |
| 4797 | test -z "$ac_dir" && ac_dir=. |
| 4798 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4799 | ac_cv_prog_ac_ct_LIBTOOL="$ac_prog" |
| 4800 | echo "$as_me:4800: found $ac_dir/$ac_word" >&5 |
| 4801 | break |
| 4802 | done |
| 4803 | |
| 4804 | fi |
| 4805 | fi |
| 4806 | ac_ct_LIBTOOL=$ac_cv_prog_ac_ct_LIBTOOL |
| 4807 | if test -n "$ac_ct_LIBTOOL"; then |
| 4808 | echo "$as_me:4808: result: $ac_ct_LIBTOOL" >&5 |
| 4809 | echo "${ECHO_T}$ac_ct_LIBTOOL" >&6 |
| 4810 | else |
| 4811 | echo "$as_me:4811: result: no" >&5 |
| 4812 | echo "${ECHO_T}no" >&6 |
| 4813 | fi |
| 4814 | |
| 4815 | test -n "$ac_ct_LIBTOOL" && break |
| 4816 | done |
| 4817 | test -n "$ac_ct_LIBTOOL" || ac_ct_LIBTOOL="none" |
| 4818 | |
| 4819 | LIBTOOL=$ac_ct_LIBTOOL |
| 4820 | fi |
| 4821 | |
| 4822 | if test -n "$LIBTOOL" && test "$LIBTOOL" != none |
| 4823 | then |
| 4824 | cf_cv_libtool_version=`$LIBTOOL --version 2>&1 | sed -e '/^$/d' |sed -e '2,$d' -e 's/([^)]*)//g' -e 's/^[^1-9]*//' -e 's/[^0-9.].*//'` |
| 4825 | else |
| 4826 | cf_cv_libtool_version= |
| 4827 | fi |
| 4828 | test -z "$cf_cv_libtool_version" && unset cf_cv_libtool_version |
| 4829 | |
| 4830 | if test -z "$cf_cv_libtool_version" && test "$LIBTOOL" = libtool |
| 4831 | then |
| 4832 | |
| 4833 | unset ac_cv_prog_ac_ct_LIBTOOL |
| 4834 | unset ac_ct_LIBTOOL |
| 4835 | unset LIBTOOL |
| 4836 | |
| 4837 | if test -n "$ac_tool_prefix"; then |
| 4838 | for ac_prog in glibtool |
| 4839 | do |
| 4840 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 4841 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
| 4842 | echo "$as_me:4842: checking for $ac_word" >&5 |
| 4843 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4844 | if test "${ac_cv_prog_LIBTOOL+set}" = set; then |
| 4845 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4846 | else |
| 4847 | if test -n "$LIBTOOL"; then |
| 4848 | ac_cv_prog_LIBTOOL="$LIBTOOL" # Let the user override the test. |
| 4849 | else |
| 4850 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4851 | ac_dummy="$PATH" |
| 4852 | for ac_dir in $ac_dummy; do |
| 4853 | IFS=$ac_save_IFS |
| 4854 | test -z "$ac_dir" && ac_dir=. |
| 4855 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4856 | ac_cv_prog_LIBTOOL="$ac_tool_prefix$ac_prog" |
| 4857 | echo "$as_me:4857: found $ac_dir/$ac_word" >&5 |
| 4858 | break |
| 4859 | done |
| 4860 | |
| 4861 | fi |
| 4862 | fi |
| 4863 | LIBTOOL=$ac_cv_prog_LIBTOOL |
| 4864 | if test -n "$LIBTOOL"; then |
| 4865 | echo "$as_me:4865: result: $LIBTOOL" >&5 |
| 4866 | echo "${ECHO_T}$LIBTOOL" >&6 |
| 4867 | else |
| 4868 | echo "$as_me:4868: result: no" >&5 |
| 4869 | echo "${ECHO_T}no" >&6 |
| 4870 | fi |
| 4871 | |
| 4872 | test -n "$LIBTOOL" && break |
| 4873 | done |
| 4874 | fi |
| 4875 | if test -z "$LIBTOOL"; then |
| 4876 | ac_ct_LIBTOOL=$LIBTOOL |
| 4877 | for ac_prog in glibtool |
| 4878 | do |
| 4879 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4880 | set dummy $ac_prog; ac_word=$2 |
| 4881 | echo "$as_me:4881: checking for $ac_word" >&5 |
| 4882 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 4883 | if test "${ac_cv_prog_ac_ct_LIBTOOL+set}" = set; then |
| 4884 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 4885 | else |
| 4886 | if test -n "$ac_ct_LIBTOOL"; then |
| 4887 | ac_cv_prog_ac_ct_LIBTOOL="$ac_ct_LIBTOOL" # Let the user override the test. |
| 4888 | else |
| 4889 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 4890 | ac_dummy="$PATH" |
| 4891 | for ac_dir in $ac_dummy; do |
| 4892 | IFS=$ac_save_IFS |
| 4893 | test -z "$ac_dir" && ac_dir=. |
| 4894 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 4895 | ac_cv_prog_ac_ct_LIBTOOL="$ac_prog" |
| 4896 | echo "$as_me:4896: found $ac_dir/$ac_word" >&5 |
| 4897 | break |
| 4898 | done |
| 4899 | |
| 4900 | fi |
| 4901 | fi |
| 4902 | ac_ct_LIBTOOL=$ac_cv_prog_ac_ct_LIBTOOL |
| 4903 | if test -n "$ac_ct_LIBTOOL"; then |
| 4904 | echo "$as_me:4904: result: $ac_ct_LIBTOOL" >&5 |
| 4905 | echo "${ECHO_T}$ac_ct_LIBTOOL" >&6 |
| 4906 | else |
| 4907 | echo "$as_me:4907: result: no" >&5 |
| 4908 | echo "${ECHO_T}no" >&6 |
| 4909 | fi |
| 4910 | |
| 4911 | test -n "$ac_ct_LIBTOOL" && break |
| 4912 | done |
| 4913 | test -n "$ac_ct_LIBTOOL" || ac_ct_LIBTOOL="none" |
| 4914 | |
| 4915 | LIBTOOL=$ac_ct_LIBTOOL |
| 4916 | fi |
| 4917 | |
| 4918 | if test -n "$LIBTOOL" && test "$LIBTOOL" != none |
| 4919 | then |
| 4920 | cf_cv_libtool_version=`$LIBTOOL --version 2>&1 | sed -e '/^$/d' |sed -e '2,$d' -e 's/([^)]*)//g' -e 's/^[^1-9]*//' -e 's/[^0-9.].*//'` |
| 4921 | else |
| 4922 | cf_cv_libtool_version= |
| 4923 | fi |
| 4924 | test -z "$cf_cv_libtool_version" && unset cf_cv_libtool_version |
| 4925 | |
| 4926 | fi |
| 4927 | fi |
| 4928 | if test -z "$LIBTOOL" ; then |
| 4929 | { { echo "$as_me:4929: error: Cannot find libtool" >&5 |
| 4930 | echo "$as_me: error: Cannot find libtool" >&2;} |
| 4931 | { (exit 1); exit 1; }; } |
| 4932 | fi |
| 4933 | LIB_CREATE='${LIBTOOL} --mode=link ${CC} -rpath ${DESTDIR}${libdir} ${LIBTOOL_VERSION} `cut -f1 ${top_srcdir}/VERSION` ${LIBTOOL_OPTS} ${LT_UNDEF} $(LIBS) -o' |
| 4934 | LIB_OBJECT='${OBJECTS:.o=.lo}' |
| 4935 | LIB_SUFFIX=.la |
| 4936 | LIB_CLEAN='${LIBTOOL} --mode=clean' |
| 4937 | LIB_COMPILE='${LIBTOOL} --mode=compile' |
| 4938 | LIB_LINK='${LIBTOOL} --mode=link ${CC} ${LIBTOOL_OPTS}' |
| 4939 | LIB_INSTALL='${LIBTOOL} --mode=install' |
| 4940 | LIB_UNINSTALL='${LIBTOOL} --mode=uninstall' |
| 4941 | LIB_PREP=: |
| 4942 | |
| 4943 | if test -n "$LIBTOOL" && test "$LIBTOOL" != none |
| 4944 | then |
| 4945 | echo "$as_me:4945: checking version of $LIBTOOL" >&5 |
| 4946 | echo $ECHO_N "checking version of $LIBTOOL... $ECHO_C" >&6 |
| 4947 | |
| 4948 | if test -n "$LIBTOOL" && test "$LIBTOOL" != none |
| 4949 | then |
| 4950 | cf_cv_libtool_version=`$LIBTOOL --version 2>&1 | sed -e '/^$/d' |sed -e '2,$d' -e 's/([^)]*)//g' -e 's/^[^1-9]*//' -e 's/[^0-9.].*//'` |
| 4951 | else |
| 4952 | cf_cv_libtool_version= |
| 4953 | fi |
| 4954 | test -z "$cf_cv_libtool_version" && unset cf_cv_libtool_version |
| 4955 | |
| 4956 | echo "$as_me:4956: result: $cf_cv_libtool_version" >&5 |
| 4957 | echo "${ECHO_T}$cf_cv_libtool_version" >&6 |
| 4958 | if test -z "$cf_cv_libtool_version" ; then |
| 4959 | { { echo "$as_me:4959: error: This is not GNU libtool" >&5 |
| 4960 | echo "$as_me: error: This is not GNU libtool" >&2;} |
| 4961 | { (exit 1); exit 1; }; } |
| 4962 | fi |
| 4963 | else |
| 4964 | { { echo "$as_me:4964: error: GNU libtool has not been found" >&5 |
| 4965 | echo "$as_me: error: GNU libtool has not been found" >&2;} |
| 4966 | { (exit 1); exit 1; }; } |
| 4967 | fi |
| 4968 | |
| 4969 | # special hack to add -no-undefined (which libtool should do for itself) |
| 4970 | LT_UNDEF= |
| 4971 | case "$cf_cv_system_name" in |
| 4972 | (cygwin*|msys*|mingw32*|uwin*|aix[4-7]) |
| 4973 | LT_UNDEF=-no-undefined |
| 4974 | ;; |
| 4975 | esac |
| 4976 | |
| 4977 | # special hack to add --tag option for C++ compiler |
| 4978 | case $cf_cv_libtool_version in |
| 4979 | (1.[5-9]*|[2-9].[0-9.a-z]*) |
| 4980 | LIBTOOL_CXX="$LIBTOOL --tag=CXX" |
| 4981 | LIBTOOL="$LIBTOOL --tag=CC" |
| 4982 | ;; |
| 4983 | (*) |
| 4984 | LIBTOOL_CXX="$LIBTOOL" |
| 4985 | ;; |
| 4986 | esac |
| 4987 | else |
| 4988 | LIBTOOL="" |
| 4989 | LIBTOOL_CXX="" |
| 4990 | fi |
| 4991 | |
| 4992 | test -z "$LIBTOOL" && ECHO_LT= |
| 4993 | |
| 4994 | if test "$with_libtool" != "no" ; then |
| 4995 | |
| 4996 | cf_list_models="$cf_list_models libtool" |
| 4997 | |
| 4998 | else |
| 4999 | |
| 5000 | echo "$as_me:5000: checking if you want to build shared libraries" >&5 |
| 5001 | echo $ECHO_N "checking if you want to build shared libraries... $ECHO_C" >&6 |
| 5002 | |
| 5003 | # Check whether --with-shared or --without-shared was given. |
| 5004 | if test "${with_shared+set}" = set; then |
| 5005 | withval="$with_shared" |
| 5006 | with_shared=$withval |
| 5007 | else |
| 5008 | with_shared=no |
| 5009 | fi; |
| 5010 | echo "$as_me:5010: result: $with_shared" >&5 |
| 5011 | echo "${ECHO_T}$with_shared" >&6 |
| 5012 | test "x$with_shared" = "xyes" && cf_list_models="$cf_list_models shared" |
| 5013 | |
| 5014 | echo "$as_me:5014: checking if you want to build static libraries" >&5 |
| 5015 | echo $ECHO_N "checking if you want to build static libraries... $ECHO_C" >&6 |
| 5016 | |
| 5017 | # Check whether --with-normal or --without-normal was given. |
| 5018 | if test "${with_normal+set}" = set; then |
| 5019 | withval="$with_normal" |
| 5020 | with_normal=$withval |
| 5021 | else |
| 5022 | with_normal=yes |
| 5023 | fi; |
| 5024 | echo "$as_me:5024: result: $with_normal" >&5 |
| 5025 | echo "${ECHO_T}$with_normal" >&6 |
| 5026 | test "x$with_normal" = "xyes" && cf_list_models="$cf_list_models normal" |
| 5027 | |
| 5028 | echo "$as_me:5028: checking if you want to build debug libraries" >&5 |
| 5029 | echo $ECHO_N "checking if you want to build debug libraries... $ECHO_C" >&6 |
| 5030 | |
| 5031 | # Check whether --with-debug or --without-debug was given. |
| 5032 | if test "${with_debug+set}" = set; then |
| 5033 | withval="$with_debug" |
| 5034 | with_debug=$withval |
| 5035 | else |
| 5036 | with_debug=yes |
| 5037 | fi; |
| 5038 | echo "$as_me:5038: result: $with_debug" >&5 |
| 5039 | echo "${ECHO_T}$with_debug" >&6 |
| 5040 | test "x$with_debug" = "xyes" && cf_list_models="$cf_list_models debug" |
| 5041 | |
| 5042 | echo "$as_me:5042: checking if you want to build profiling libraries" >&5 |
| 5043 | echo $ECHO_N "checking if you want to build profiling libraries... $ECHO_C" >&6 |
| 5044 | |
| 5045 | # Check whether --with-profile or --without-profile was given. |
| 5046 | if test "${with_profile+set}" = set; then |
| 5047 | withval="$with_profile" |
| 5048 | with_profile=$withval |
| 5049 | else |
| 5050 | with_profile=no |
| 5051 | fi; |
| 5052 | echo "$as_me:5052: result: $with_profile" >&5 |
| 5053 | echo "${ECHO_T}$with_profile" >&6 |
| 5054 | test "x$with_profile" = "xyes" && cf_list_models="$cf_list_models profile" |
| 5055 | |
| 5056 | fi |
| 5057 | |
| 5058 | if test "X$cf_with_cxx_binding" != Xno; then |
| 5059 | if test "x$with_shared" = "xyes"; then |
| 5060 | echo "$as_me:5060: checking if you want to build C++ shared libraries" >&5 |
| 5061 | echo $ECHO_N "checking if you want to build C++ shared libraries... $ECHO_C" >&6 |
| 5062 | |
| 5063 | # Check whether --with-cxx-shared or --without-cxx-shared was given. |
| 5064 | if test "${with_cxx_shared+set}" = set; then |
| 5065 | withval="$with_cxx_shared" |
| 5066 | with_shared_cxx=$withval |
| 5067 | else |
| 5068 | with_shared_cxx=no |
| 5069 | fi; |
| 5070 | echo "$as_me:5070: result: $with_shared_cxx" >&5 |
| 5071 | echo "${ECHO_T}$with_shared_cxx" >&6 |
| 5072 | fi |
| 5073 | fi |
| 5074 | |
| 5075 | ############################################################################### |
| 5076 | |
| 5077 | echo "$as_me:5077: checking for specified models" >&5 |
| 5078 | echo $ECHO_N "checking for specified models... $ECHO_C" >&6 |
| 5079 | test -z "$cf_list_models" && cf_list_models=normal |
| 5080 | test "$with_libtool" != "no" && cf_list_models=libtool |
| 5081 | echo "$as_me:5081: result: $cf_list_models" >&5 |
| 5082 | echo "${ECHO_T}$cf_list_models" >&6 |
| 5083 | |
| 5084 | ### Use the first model as the default, and save its suffix for use in building |
| 5085 | ### up test-applications. |
| 5086 | echo "$as_me:5086: checking for default model" >&5 |
| 5087 | echo $ECHO_N "checking for default model... $ECHO_C" >&6 |
| 5088 | DFT_LWR_MODEL=`echo "$cf_list_models" | $AWK '{print $1}'` |
| 5089 | echo "$as_me:5089: result: $DFT_LWR_MODEL" >&5 |
| 5090 | echo "${ECHO_T}$DFT_LWR_MODEL" >&6 |
| 5091 | |
| 5092 | DFT_UPR_MODEL=`echo "$DFT_LWR_MODEL" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 5093 | |
| 5094 | TICS_NAME=tic |
| 5095 | |
| 5096 | TINFO_NAME=tinfo |
| 5097 | |
| 5098 | LIB_NAME=ncurses |
| 5099 | |
| 5100 | LIB_DIR=../lib |
| 5101 | LIB_2ND=../../lib |
| 5102 | |
| 5103 | echo "$as_me:5103: checking if you want to have a library-prefix" >&5 |
| 5104 | echo $ECHO_N "checking if you want to have a library-prefix... $ECHO_C" >&6 |
| 5105 | |
| 5106 | # Check whether --with-lib-prefix or --without-lib-prefix was given. |
| 5107 | if test "${with_lib_prefix+set}" = set; then |
| 5108 | withval="$with_lib_prefix" |
| 5109 | with_lib_prefix=$withval |
| 5110 | else |
| 5111 | with_lib_prefix=auto |
| 5112 | fi; |
| 5113 | echo "$as_me:5113: result: $with_lib_prefix" >&5 |
| 5114 | echo "${ECHO_T}$with_lib_prefix" >&6 |
| 5115 | |
| 5116 | if test $with_lib_prefix = auto |
| 5117 | then |
| 5118 | |
| 5119 | case $cf_cv_system_name in |
| 5120 | (OS/2*|os2*) |
| 5121 | LIB_PREFIX='' |
| 5122 | ;; |
| 5123 | (*) LIB_PREFIX='lib' |
| 5124 | ;; |
| 5125 | esac |
| 5126 | cf_prefix=$LIB_PREFIX |
| 5127 | |
| 5128 | elif test $with_lib_prefix = no |
| 5129 | then |
| 5130 | LIB_PREFIX= |
| 5131 | else |
| 5132 | LIB_PREFIX=$with_lib_prefix |
| 5133 | fi |
| 5134 | |
| 5135 | LIB_SUFFIX= |
| 5136 | |
| 5137 | echo "$as_me:5137: checking for PATH separator" >&5 |
| 5138 | echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6 |
| 5139 | case $cf_cv_system_name in |
| 5140 | (os2*) PATH_SEPARATOR=';' ;; |
| 5141 | (*) ${PATH_SEPARATOR:=':'} ;; |
| 5142 | esac |
| 5143 | |
| 5144 | echo "$as_me:5144: result: $PATH_SEPARATOR" >&5 |
| 5145 | echo "${ECHO_T}$PATH_SEPARATOR" >&6 |
| 5146 | |
| 5147 | ############################################################################### |
| 5148 | |
| 5149 | echo "$as_me:5149: checking if you want to build a separate terminfo library" >&5 |
| 5150 | echo $ECHO_N "checking if you want to build a separate terminfo library... $ECHO_C" >&6 |
| 5151 | |
| 5152 | # Check whether --with-termlib or --without-termlib was given. |
| 5153 | if test "${with_termlib+set}" = set; then |
| 5154 | withval="$with_termlib" |
| 5155 | with_termlib=$withval |
| 5156 | else |
| 5157 | with_termlib=no |
| 5158 | fi; |
| 5159 | echo "$as_me:5159: result: $with_termlib" >&5 |
| 5160 | echo "${ECHO_T}$with_termlib" >&6 |
| 5161 | |
| 5162 | echo "$as_me:5162: checking if you want to build a separate tic library" >&5 |
| 5163 | echo $ECHO_N "checking if you want to build a separate tic library... $ECHO_C" >&6 |
| 5164 | |
| 5165 | # Check whether --with-ticlib or --without-ticlib was given. |
| 5166 | if test "${with_ticlib+set}" = set; then |
| 5167 | withval="$with_ticlib" |
| 5168 | with_ticlib=$withval |
| 5169 | else |
| 5170 | with_ticlib=no |
| 5171 | fi; |
| 5172 | echo "$as_me:5172: result: $with_ticlib" >&5 |
| 5173 | echo "${ECHO_T}$with_ticlib" >&6 |
| 5174 | |
| 5175 | ### Checks for special libraries, must be done up-front. |
| 5176 | SHLIB_LIST="" |
| 5177 | |
| 5178 | echo "$as_me:5178: checking if you want to link with the GPM mouse library" >&5 |
| 5179 | echo $ECHO_N "checking if you want to link with the GPM mouse library... $ECHO_C" >&6 |
| 5180 | |
| 5181 | # Check whether --with-gpm or --without-gpm was given. |
| 5182 | if test "${with_gpm+set}" = set; then |
| 5183 | withval="$with_gpm" |
| 5184 | with_gpm=$withval |
| 5185 | else |
| 5186 | with_gpm=maybe |
| 5187 | fi; |
| 5188 | echo "$as_me:5188: result: $with_gpm" >&5 |
| 5189 | echo "${ECHO_T}$with_gpm" >&6 |
| 5190 | |
| 5191 | if test "$with_gpm" != no ; then |
| 5192 | echo "$as_me:5192: checking for gpm.h" >&5 |
| 5193 | echo $ECHO_N "checking for gpm.h... $ECHO_C" >&6 |
| 5194 | if test "${ac_cv_header_gpm_h+set}" = set; then |
| 5195 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5196 | else |
| 5197 | cat >conftest.$ac_ext <<_ACEOF |
| 5198 | #line 5198 "configure" |
| 5199 | #include "confdefs.h" |
| 5200 | #include <gpm.h> |
| 5201 | _ACEOF |
| 5202 | if { (eval echo "$as_me:5202: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 5203 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 5204 | ac_status=$? |
| 5205 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 5206 | rm -f conftest.er1 |
| 5207 | cat conftest.err >&5 |
| 5208 | echo "$as_me:5208: \$? = $ac_status" >&5 |
| 5209 | (exit $ac_status); } >/dev/null; then |
| 5210 | if test -s conftest.err; then |
| 5211 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 5212 | else |
| 5213 | ac_cpp_err= |
| 5214 | fi |
| 5215 | else |
| 5216 | ac_cpp_err=yes |
| 5217 | fi |
| 5218 | if test -z "$ac_cpp_err"; then |
| 5219 | ac_cv_header_gpm_h=yes |
| 5220 | else |
| 5221 | echo "$as_me: failed program was:" >&5 |
| 5222 | cat conftest.$ac_ext >&5 |
| 5223 | ac_cv_header_gpm_h=no |
| 5224 | fi |
| 5225 | rm -f conftest.err conftest.$ac_ext |
| 5226 | fi |
| 5227 | echo "$as_me:5227: result: $ac_cv_header_gpm_h" >&5 |
| 5228 | echo "${ECHO_T}$ac_cv_header_gpm_h" >&6 |
| 5229 | if test $ac_cv_header_gpm_h = yes; then |
| 5230 | |
| 5231 | cat >>confdefs.h <<\EOF |
| 5232 | #define HAVE_GPM_H 1 |
| 5233 | EOF |
| 5234 | |
| 5235 | if test "$with_gpm" != yes && test "$with_gpm" != maybe ; then |
| 5236 | test -n "$verbose" && echo " assuming we really have GPM library" 1>&6 |
| 5237 | |
| 5238 | echo "${as_me:-configure}:5238: testing assuming we really have GPM library ..." 1>&5 |
| 5239 | |
| 5240 | cat >>confdefs.h <<\EOF |
| 5241 | #define HAVE_LIBGPM 1 |
| 5242 | EOF |
| 5243 | |
| 5244 | else |
| 5245 | echo "$as_me:5245: checking for Gpm_Open in -lgpm" >&5 |
| 5246 | echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6 |
| 5247 | if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then |
| 5248 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5249 | else |
| 5250 | ac_check_lib_save_LIBS=$LIBS |
| 5251 | LIBS="-lgpm $LIBS" |
| 5252 | cat >conftest.$ac_ext <<_ACEOF |
| 5253 | #line 5253 "configure" |
| 5254 | #include "confdefs.h" |
| 5255 | |
| 5256 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5257 | #ifdef __cplusplus |
| 5258 | extern "C" |
| 5259 | #endif |
| 5260 | /* We use char because int might match the return type of a gcc2 |
| 5261 | builtin and then its argument prototype would still apply. */ |
| 5262 | char Gpm_Open (); |
| 5263 | int |
| 5264 | main () |
| 5265 | { |
| 5266 | Gpm_Open (); |
| 5267 | ; |
| 5268 | return 0; |
| 5269 | } |
| 5270 | _ACEOF |
| 5271 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5272 | if { (eval echo "$as_me:5272: \"$ac_link\"") >&5 |
| 5273 | (eval $ac_link) 2>&5 |
| 5274 | ac_status=$? |
| 5275 | echo "$as_me:5275: \$? = $ac_status" >&5 |
| 5276 | (exit $ac_status); } && |
| 5277 | { ac_try='test -s conftest$ac_exeext' |
| 5278 | { (eval echo "$as_me:5278: \"$ac_try\"") >&5 |
| 5279 | (eval $ac_try) 2>&5 |
| 5280 | ac_status=$? |
| 5281 | echo "$as_me:5281: \$? = $ac_status" >&5 |
| 5282 | (exit $ac_status); }; }; then |
| 5283 | ac_cv_lib_gpm_Gpm_Open=yes |
| 5284 | else |
| 5285 | echo "$as_me: failed program was:" >&5 |
| 5286 | cat conftest.$ac_ext >&5 |
| 5287 | ac_cv_lib_gpm_Gpm_Open=no |
| 5288 | fi |
| 5289 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5290 | LIBS=$ac_check_lib_save_LIBS |
| 5291 | fi |
| 5292 | echo "$as_me:5292: result: $ac_cv_lib_gpm_Gpm_Open" >&5 |
| 5293 | echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6 |
| 5294 | if test $ac_cv_lib_gpm_Gpm_Open = yes; then |
| 5295 | : |
| 5296 | else |
| 5297 | |
| 5298 | { { echo "$as_me:5298: error: Cannot link with GPM library" >&5 |
| 5299 | echo "$as_me: error: Cannot link with GPM library" >&2;} |
| 5300 | { (exit 1); exit 1; }; } |
| 5301 | fi |
| 5302 | with_gpm=yes |
| 5303 | |
| 5304 | fi |
| 5305 | |
| 5306 | else |
| 5307 | |
| 5308 | test "$with_gpm" != maybe && { echo "$as_me:5308: WARNING: Cannot find GPM header" >&5 |
| 5309 | echo "$as_me: WARNING: Cannot find GPM header" >&2;} |
| 5310 | with_gpm=no |
| 5311 | |
| 5312 | fi |
| 5313 | |
| 5314 | fi |
| 5315 | |
| 5316 | if test "$with_gpm" != no ; then |
| 5317 | echo "$as_me:5317: checking if you want to load GPM dynamically" >&5 |
| 5318 | echo $ECHO_N "checking if you want to load GPM dynamically... $ECHO_C" >&6 |
| 5319 | |
| 5320 | # Check whether --with-dlsym or --without-dlsym was given. |
| 5321 | if test "${with_dlsym+set}" = set; then |
| 5322 | withval="$with_dlsym" |
| 5323 | with_dlsym=$withval |
| 5324 | else |
| 5325 | with_dlsym=yes |
| 5326 | fi; |
| 5327 | echo "$as_me:5327: result: $with_dlsym" >&5 |
| 5328 | echo "${ECHO_T}$with_dlsym" >&6 |
| 5329 | if test "x$with_dlsym" = xyes ; then |
| 5330 | |
| 5331 | cf_have_dlsym=no |
| 5332 | echo "$as_me:5332: checking for dlsym" >&5 |
| 5333 | echo $ECHO_N "checking for dlsym... $ECHO_C" >&6 |
| 5334 | if test "${ac_cv_func_dlsym+set}" = set; then |
| 5335 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5336 | else |
| 5337 | cat >conftest.$ac_ext <<_ACEOF |
| 5338 | #line 5338 "configure" |
| 5339 | #include "confdefs.h" |
| 5340 | /* System header to define __stub macros and hopefully few prototypes, |
| 5341 | which can conflict with char dlsym (); below. */ |
| 5342 | #include <assert.h> |
| 5343 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5344 | #ifdef __cplusplus |
| 5345 | extern "C" |
| 5346 | #endif |
| 5347 | /* We use char because int might match the return type of a gcc2 |
| 5348 | builtin and then its argument prototype would still apply. */ |
| 5349 | char dlsym (); |
| 5350 | char (*f) (); |
| 5351 | |
| 5352 | int |
| 5353 | main () |
| 5354 | { |
| 5355 | /* The GNU C library defines this for functions which it implements |
| 5356 | to always fail with ENOSYS. Some functions are actually named |
| 5357 | something starting with __ and the normal name is an alias. */ |
| 5358 | #if defined (__stub_dlsym) || defined (__stub___dlsym) |
| 5359 | choke me |
| 5360 | #else |
| 5361 | f = dlsym; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 5362 | #endif |
| 5363 | |
| 5364 | ; |
| 5365 | return 0; |
| 5366 | } |
| 5367 | _ACEOF |
| 5368 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5369 | if { (eval echo "$as_me:5369: \"$ac_link\"") >&5 |
| 5370 | (eval $ac_link) 2>&5 |
| 5371 | ac_status=$? |
| 5372 | echo "$as_me:5372: \$? = $ac_status" >&5 |
| 5373 | (exit $ac_status); } && |
| 5374 | { ac_try='test -s conftest$ac_exeext' |
| 5375 | { (eval echo "$as_me:5375: \"$ac_try\"") >&5 |
| 5376 | (eval $ac_try) 2>&5 |
| 5377 | ac_status=$? |
| 5378 | echo "$as_me:5378: \$? = $ac_status" >&5 |
| 5379 | (exit $ac_status); }; }; then |
| 5380 | ac_cv_func_dlsym=yes |
| 5381 | else |
| 5382 | echo "$as_me: failed program was:" >&5 |
| 5383 | cat conftest.$ac_ext >&5 |
| 5384 | ac_cv_func_dlsym=no |
| 5385 | fi |
| 5386 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5387 | fi |
| 5388 | echo "$as_me:5388: result: $ac_cv_func_dlsym" >&5 |
| 5389 | echo "${ECHO_T}$ac_cv_func_dlsym" >&6 |
| 5390 | if test $ac_cv_func_dlsym = yes; then |
| 5391 | cf_have_dlsym=yes |
| 5392 | else |
| 5393 | |
| 5394 | cf_have_libdl=no |
| 5395 | echo "$as_me:5395: checking for dlsym in -ldl" >&5 |
| 5396 | echo $ECHO_N "checking for dlsym in -ldl... $ECHO_C" >&6 |
| 5397 | if test "${ac_cv_lib_dl_dlsym+set}" = set; then |
| 5398 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5399 | else |
| 5400 | ac_check_lib_save_LIBS=$LIBS |
| 5401 | LIBS="-ldl $LIBS" |
| 5402 | cat >conftest.$ac_ext <<_ACEOF |
| 5403 | #line 5403 "configure" |
| 5404 | #include "confdefs.h" |
| 5405 | |
| 5406 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5407 | #ifdef __cplusplus |
| 5408 | extern "C" |
| 5409 | #endif |
| 5410 | /* We use char because int might match the return type of a gcc2 |
| 5411 | builtin and then its argument prototype would still apply. */ |
| 5412 | char dlsym (); |
| 5413 | int |
| 5414 | main () |
| 5415 | { |
| 5416 | dlsym (); |
| 5417 | ; |
| 5418 | return 0; |
| 5419 | } |
| 5420 | _ACEOF |
| 5421 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5422 | if { (eval echo "$as_me:5422: \"$ac_link\"") >&5 |
| 5423 | (eval $ac_link) 2>&5 |
| 5424 | ac_status=$? |
| 5425 | echo "$as_me:5425: \$? = $ac_status" >&5 |
| 5426 | (exit $ac_status); } && |
| 5427 | { ac_try='test -s conftest$ac_exeext' |
| 5428 | { (eval echo "$as_me:5428: \"$ac_try\"") >&5 |
| 5429 | (eval $ac_try) 2>&5 |
| 5430 | ac_status=$? |
| 5431 | echo "$as_me:5431: \$? = $ac_status" >&5 |
| 5432 | (exit $ac_status); }; }; then |
| 5433 | ac_cv_lib_dl_dlsym=yes |
| 5434 | else |
| 5435 | echo "$as_me: failed program was:" >&5 |
| 5436 | cat conftest.$ac_ext >&5 |
| 5437 | ac_cv_lib_dl_dlsym=no |
| 5438 | fi |
| 5439 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5440 | LIBS=$ac_check_lib_save_LIBS |
| 5441 | fi |
| 5442 | echo "$as_me:5442: result: $ac_cv_lib_dl_dlsym" >&5 |
| 5443 | echo "${ECHO_T}$ac_cv_lib_dl_dlsym" >&6 |
| 5444 | if test $ac_cv_lib_dl_dlsym = yes; then |
| 5445 | |
| 5446 | cf_have_dlsym=yes |
| 5447 | cf_have_libdl=yes |
| 5448 | fi |
| 5449 | |
| 5450 | fi |
| 5451 | |
| 5452 | if test "$cf_have_dlsym" = yes ; then |
| 5453 | test "$cf_have_libdl" = yes && |
| 5454 | cf_add_libs="-ldl" |
| 5455 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 5456 | for cf_add_1lib in $LIBS |
| 5457 | do |
| 5458 | for cf_add_2lib in $cf_add_libs |
| 5459 | do |
| 5460 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 5461 | then |
| 5462 | cf_add_1lib= |
| 5463 | break |
| 5464 | fi |
| 5465 | done |
| 5466 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 5467 | done |
| 5468 | LIBS="$cf_add_libs" |
| 5469 | |
| 5470 | echo "$as_me:5470: checking whether able to link to dl*() functions" >&5 |
| 5471 | echo $ECHO_N "checking whether able to link to dl*() functions... $ECHO_C" >&6 |
| 5472 | cat >conftest.$ac_ext <<_ACEOF |
| 5473 | #line 5473 "configure" |
| 5474 | #include "confdefs.h" |
| 5475 | #include <dlfcn.h> |
| 5476 | int |
| 5477 | main () |
| 5478 | { |
| 5479 | |
| 5480 | void *obj; |
| 5481 | if ((obj = dlopen("filename", 0)) != 0) { |
| 5482 | if (dlsym(obj, "symbolname") == 0) { |
| 5483 | dlclose(obj); |
| 5484 | } |
| 5485 | } |
| 5486 | ; |
| 5487 | return 0; |
| 5488 | } |
| 5489 | _ACEOF |
| 5490 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5491 | if { (eval echo "$as_me:5491: \"$ac_link\"") >&5 |
| 5492 | (eval $ac_link) 2>&5 |
| 5493 | ac_status=$? |
| 5494 | echo "$as_me:5494: \$? = $ac_status" >&5 |
| 5495 | (exit $ac_status); } && |
| 5496 | { ac_try='test -s conftest$ac_exeext' |
| 5497 | { (eval echo "$as_me:5497: \"$ac_try\"") >&5 |
| 5498 | (eval $ac_try) 2>&5 |
| 5499 | ac_status=$? |
| 5500 | echo "$as_me:5500: \$? = $ac_status" >&5 |
| 5501 | (exit $ac_status); }; }; then |
| 5502 | |
| 5503 | cat >>confdefs.h <<\EOF |
| 5504 | #define HAVE_LIBDL 1 |
| 5505 | EOF |
| 5506 | |
| 5507 | else |
| 5508 | echo "$as_me: failed program was:" >&5 |
| 5509 | cat conftest.$ac_ext >&5 |
| 5510 | |
| 5511 | { { echo "$as_me:5511: error: Cannot link test program for libdl" >&5 |
| 5512 | echo "$as_me: error: Cannot link test program for libdl" >&2;} |
| 5513 | { (exit 1); exit 1; }; } |
| 5514 | fi |
| 5515 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5516 | echo "$as_me:5516: result: ok" >&5 |
| 5517 | echo "${ECHO_T}ok" >&6 |
| 5518 | else |
| 5519 | { { echo "$as_me:5519: error: Cannot find dlsym function" >&5 |
| 5520 | echo "$as_me: error: Cannot find dlsym function" >&2;} |
| 5521 | { (exit 1); exit 1; }; } |
| 5522 | fi |
| 5523 | |
| 5524 | if test "x$with_gpm" != xyes ; then |
| 5525 | test -n "$verbose" && echo " assuming soname for gpm is $with_gpm" 1>&6 |
| 5526 | |
| 5527 | echo "${as_me:-configure}:5527: testing assuming soname for gpm is $with_gpm ..." 1>&5 |
| 5528 | |
| 5529 | cf_cv_gpm_soname="$with_gpm" |
| 5530 | else |
| 5531 | |
| 5532 | echo "$as_me:5532: checking for soname of gpm library" >&5 |
| 5533 | echo $ECHO_N "checking for soname of gpm library... $ECHO_C" >&6 |
| 5534 | if test "${cf_cv_gpm_soname+set}" = set; then |
| 5535 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5536 | else |
| 5537 | |
| 5538 | cf_cv_gpm_soname=unknown |
| 5539 | if test "$cross_compiling" != yes ; then |
| 5540 | cat >conftest.$ac_ext <<CF_EOF |
| 5541 | #include <gpm.h> |
| 5542 | int main() |
| 5543 | { |
| 5544 | if (Gpm_Open(0,0)) Gpm_Close(); |
| 5545 | ${cf_cv_main_return:-return}(0); |
| 5546 | } |
| 5547 | CF_EOF |
| 5548 | cf_save_LIBS="$LIBS" |
| 5549 | |
| 5550 | cf_add_libs="-lgpm" |
| 5551 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 5552 | for cf_add_1lib in $LIBS |
| 5553 | do |
| 5554 | for cf_add_2lib in $cf_add_libs |
| 5555 | do |
| 5556 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 5557 | then |
| 5558 | cf_add_1lib= |
| 5559 | break |
| 5560 | fi |
| 5561 | done |
| 5562 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 5563 | done |
| 5564 | LIBS="$cf_add_libs" |
| 5565 | |
| 5566 | if { (eval echo "$as_me:5566: \"$ac_compile\"") >&5 |
| 5567 | (eval $ac_compile) 2>&5 |
| 5568 | ac_status=$? |
| 5569 | echo "$as_me:5569: \$? = $ac_status" >&5 |
| 5570 | (exit $ac_status); } ; then |
| 5571 | if { (eval echo "$as_me:5571: \"$ac_link\"") >&5 |
| 5572 | (eval $ac_link) 2>&5 |
| 5573 | ac_status=$? |
| 5574 | echo "$as_me:5574: \$? = $ac_status" >&5 |
| 5575 | (exit $ac_status); } ; then |
| 5576 | cf_cv_gpm_soname=`ldd conftest$ac_exeext 2>/dev/null | sed -e 's,^.*/,,' -e 's, .*$,,' | fgrep libgpm.` |
| 5577 | test -z "$cf_cv_gpm_soname" && cf_cv_gpm_soname=unknown |
| 5578 | fi |
| 5579 | fi |
| 5580 | rm -rf conftest* |
| 5581 | LIBS="$cf_save_LIBS" |
| 5582 | fi |
| 5583 | |
| 5584 | fi |
| 5585 | echo "$as_me:5585: result: $cf_cv_gpm_soname" >&5 |
| 5586 | echo "${ECHO_T}$cf_cv_gpm_soname" >&6 |
| 5587 | |
| 5588 | fi |
| 5589 | test "$cf_cv_gpm_soname" != "unknown" && |
| 5590 | cat >>confdefs.h <<EOF |
| 5591 | #define LIBGPM_SONAME "$cf_cv_gpm_soname" |
| 5592 | EOF |
| 5593 | |
| 5594 | SHLIB_LIST="-ldl $SHLIB_LIST" |
| 5595 | else |
| 5596 | SHLIB_LIST="-lgpm $SHLIB_LIST" |
| 5597 | |
| 5598 | cf_add_libs="-lgpm" |
| 5599 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 5600 | for cf_add_1lib in $TEST_LIBS |
| 5601 | do |
| 5602 | for cf_add_2lib in $cf_add_libs |
| 5603 | do |
| 5604 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 5605 | then |
| 5606 | cf_add_1lib= |
| 5607 | break |
| 5608 | fi |
| 5609 | done |
| 5610 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 5611 | done |
| 5612 | TEST_LIBS="$cf_add_libs" |
| 5613 | |
| 5614 | fi |
| 5615 | |
| 5616 | cat >>confdefs.h <<\EOF |
| 5617 | #define HAVE_LIBGPM 1 |
| 5618 | EOF |
| 5619 | |
| 5620 | echo "$as_me:5620: checking for Gpm_Wgetch in -lgpm" >&5 |
| 5621 | echo $ECHO_N "checking for Gpm_Wgetch in -lgpm... $ECHO_C" >&6 |
| 5622 | if test "${ac_cv_lib_gpm_Gpm_Wgetch+set}" = set; then |
| 5623 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5624 | else |
| 5625 | ac_check_lib_save_LIBS=$LIBS |
| 5626 | LIBS="-lgpm $LIBS" |
| 5627 | cat >conftest.$ac_ext <<_ACEOF |
| 5628 | #line 5628 "configure" |
| 5629 | #include "confdefs.h" |
| 5630 | |
| 5631 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5632 | #ifdef __cplusplus |
| 5633 | extern "C" |
| 5634 | #endif |
| 5635 | /* We use char because int might match the return type of a gcc2 |
| 5636 | builtin and then its argument prototype would still apply. */ |
| 5637 | char Gpm_Wgetch (); |
| 5638 | int |
| 5639 | main () |
| 5640 | { |
| 5641 | Gpm_Wgetch (); |
| 5642 | ; |
| 5643 | return 0; |
| 5644 | } |
| 5645 | _ACEOF |
| 5646 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5647 | if { (eval echo "$as_me:5647: \"$ac_link\"") >&5 |
| 5648 | (eval $ac_link) 2>&5 |
| 5649 | ac_status=$? |
| 5650 | echo "$as_me:5650: \$? = $ac_status" >&5 |
| 5651 | (exit $ac_status); } && |
| 5652 | { ac_try='test -s conftest$ac_exeext' |
| 5653 | { (eval echo "$as_me:5653: \"$ac_try\"") >&5 |
| 5654 | (eval $ac_try) 2>&5 |
| 5655 | ac_status=$? |
| 5656 | echo "$as_me:5656: \$? = $ac_status" >&5 |
| 5657 | (exit $ac_status); }; }; then |
| 5658 | ac_cv_lib_gpm_Gpm_Wgetch=yes |
| 5659 | else |
| 5660 | echo "$as_me: failed program was:" >&5 |
| 5661 | cat conftest.$ac_ext >&5 |
| 5662 | ac_cv_lib_gpm_Gpm_Wgetch=no |
| 5663 | fi |
| 5664 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5665 | LIBS=$ac_check_lib_save_LIBS |
| 5666 | fi |
| 5667 | echo "$as_me:5667: result: $ac_cv_lib_gpm_Gpm_Wgetch" >&5 |
| 5668 | echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Wgetch" >&6 |
| 5669 | if test $ac_cv_lib_gpm_Gpm_Wgetch = yes; then |
| 5670 | |
| 5671 | echo "$as_me:5671: checking if GPM is weakly bound to curses library" >&5 |
| 5672 | echo $ECHO_N "checking if GPM is weakly bound to curses library... $ECHO_C" >&6 |
| 5673 | if test "${cf_cv_check_gpm_wgetch+set}" = set; then |
| 5674 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 5675 | else |
| 5676 | |
| 5677 | cf_cv_check_gpm_wgetch=unknown |
| 5678 | if test "$cross_compiling" != yes ; then |
| 5679 | |
| 5680 | cat >conftest.$ac_ext <<CF_EOF |
| 5681 | #include <gpm.h> |
| 5682 | int main() |
| 5683 | { |
| 5684 | Gpm_Wgetch(); |
| 5685 | ${cf_cv_main_return:-return}(0); |
| 5686 | } |
| 5687 | CF_EOF |
| 5688 | |
| 5689 | cf_save_LIBS="$LIBS" |
| 5690 | # This only works if we can look at the symbol table. If a shared |
| 5691 | # library is stripped for install, we cannot use that. So we're forced |
| 5692 | # to rely on the static library, noting that some packagers may not |
| 5693 | # include it. |
| 5694 | LIBS="-static -lgpm -dynamic $LIBS" |
| 5695 | if { (eval echo "$as_me:5695: \"$ac_compile\"") >&5 |
| 5696 | (eval $ac_compile) 2>&5 |
| 5697 | ac_status=$? |
| 5698 | echo "$as_me:5698: \$? = $ac_status" >&5 |
| 5699 | (exit $ac_status); } ; then |
| 5700 | if { (eval echo "$as_me:5700: \"$ac_link\"") >&5 |
| 5701 | (eval $ac_link) 2>&5 |
| 5702 | ac_status=$? |
| 5703 | echo "$as_me:5703: \$? = $ac_status" >&5 |
| 5704 | (exit $ac_status); } ; then |
| 5705 | cf_cv_check_gpm_wgetch=`nm conftest$ac_exeext | egrep '\<wgetch\>' | egrep '\<[vVwW]\>'` |
| 5706 | test -n "$cf_cv_check_gpm_wgetch" && cf_cv_check_gpm_wgetch=yes |
| 5707 | test -z "$cf_cv_check_gpm_wgetch" && cf_cv_check_gpm_wgetch=no |
| 5708 | fi |
| 5709 | fi |
| 5710 | rm -rf conftest* |
| 5711 | LIBS="$cf_save_LIBS" |
| 5712 | fi |
| 5713 | |
| 5714 | fi |
| 5715 | echo "$as_me:5715: result: $cf_cv_check_gpm_wgetch" >&5 |
| 5716 | echo "${ECHO_T}$cf_cv_check_gpm_wgetch" >&6 |
| 5717 | |
| 5718 | if test "$cf_cv_check_gpm_wgetch" != yes ; then |
| 5719 | { echo "$as_me:5719: WARNING: GPM library is already linked with curses - read the FAQ" >&5 |
| 5720 | echo "$as_me: WARNING: GPM library is already linked with curses - read the FAQ" >&2;} |
| 5721 | fi |
| 5722 | |
| 5723 | fi |
| 5724 | |
| 5725 | fi |
| 5726 | |
| 5727 | # not everyone has "test -c" |
| 5728 | if test -c /dev/sysmouse 2>/dev/null ; then |
| 5729 | echo "$as_me:5729: checking if you want to use sysmouse" >&5 |
| 5730 | echo $ECHO_N "checking if you want to use sysmouse... $ECHO_C" >&6 |
| 5731 | |
| 5732 | # Check whether --with-sysmouse or --without-sysmouse was given. |
| 5733 | if test "${with_sysmouse+set}" = set; then |
| 5734 | withval="$with_sysmouse" |
| 5735 | cf_with_sysmouse=$withval |
| 5736 | else |
| 5737 | cf_with_sysmouse=maybe |
| 5738 | fi; |
| 5739 | if test "$cf_with_sysmouse" != no ; then |
| 5740 | cat >conftest.$ac_ext <<_ACEOF |
| 5741 | #line 5741 "configure" |
| 5742 | #include "confdefs.h" |
| 5743 | |
| 5744 | #include <osreldate.h> |
| 5745 | #if (__FreeBSD_version >= 400017) |
| 5746 | #include <sys/consio.h> |
| 5747 | #include <sys/fbio.h> |
| 5748 | #else |
| 5749 | #include <machine/console.h> |
| 5750 | #endif |
| 5751 | |
| 5752 | int |
| 5753 | main () |
| 5754 | { |
| 5755 | |
| 5756 | struct mouse_info the_mouse; |
| 5757 | ioctl(0, CONS_MOUSECTL, &the_mouse); |
| 5758 | |
| 5759 | ; |
| 5760 | return 0; |
| 5761 | } |
| 5762 | _ACEOF |
| 5763 | rm -f conftest.$ac_objext |
| 5764 | if { (eval echo "$as_me:5764: \"$ac_compile\"") >&5 |
| 5765 | (eval $ac_compile) 2>&5 |
| 5766 | ac_status=$? |
| 5767 | echo "$as_me:5767: \$? = $ac_status" >&5 |
| 5768 | (exit $ac_status); } && |
| 5769 | { ac_try='test -s conftest.$ac_objext' |
| 5770 | { (eval echo "$as_me:5770: \"$ac_try\"") >&5 |
| 5771 | (eval $ac_try) 2>&5 |
| 5772 | ac_status=$? |
| 5773 | echo "$as_me:5773: \$? = $ac_status" >&5 |
| 5774 | (exit $ac_status); }; }; then |
| 5775 | cf_with_sysmouse=yes |
| 5776 | else |
| 5777 | echo "$as_me: failed program was:" >&5 |
| 5778 | cat conftest.$ac_ext >&5 |
| 5779 | cf_with_sysmouse=no |
| 5780 | fi |
| 5781 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 5782 | fi |
| 5783 | echo "$as_me:5783: result: $cf_with_sysmouse" >&5 |
| 5784 | echo "${ECHO_T}$cf_with_sysmouse" >&6 |
| 5785 | test "$cf_with_sysmouse" = yes && |
| 5786 | cat >>confdefs.h <<\EOF |
| 5787 | #define USE_SYSMOUSE 1 |
| 5788 | EOF |
| 5789 | |
| 5790 | fi |
| 5791 | |
| 5792 | if test X"$CC_G_OPT" = X"" ; then |
| 5793 | CC_G_OPT='-g' |
| 5794 | test -n "$GCC" && test "x${ac_cv_prog_cc_g}" != xyes && CC_G_OPT='' |
| 5795 | fi |
| 5796 | |
| 5797 | if test X"$CXX_G_OPT" = X"" ; then |
| 5798 | CXX_G_OPT='-g' |
| 5799 | test -n "$GXX" && test "x${ac_cv_prog_cxx_g}" != xyes && CXX_G_OPT='' |
| 5800 | fi |
| 5801 | |
| 5802 | echo "$as_me:5802: checking for default loader flags" >&5 |
| 5803 | echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6 |
| 5804 | case $DFT_LWR_MODEL in |
| 5805 | (libtool) LD_MODEL='' ;; |
| 5806 | (normal) LD_MODEL='' ;; |
| 5807 | (debug) LD_MODEL=$CC_G_OPT ;; |
| 5808 | (profile) LD_MODEL='-pg';; |
| 5809 | (shared) LD_MODEL='' ;; |
| 5810 | esac |
| 5811 | echo "$as_me:5811: result: $LD_MODEL" >&5 |
| 5812 | echo "${ECHO_T}$LD_MODEL" >&6 |
| 5813 | |
| 5814 | case $DFT_LWR_MODEL in |
| 5815 | (shared) |
| 5816 | |
| 5817 | echo "$as_me:5817: checking if rpath option should be used" >&5 |
| 5818 | echo $ECHO_N "checking if rpath option should be used... $ECHO_C" >&6 |
| 5819 | |
| 5820 | # Check whether --enable-rpath or --disable-rpath was given. |
| 5821 | if test "${enable_rpath+set}" = set; then |
| 5822 | enableval="$enable_rpath" |
| 5823 | cf_cv_enable_rpath=$enableval |
| 5824 | else |
| 5825 | cf_cv_enable_rpath=no |
| 5826 | fi; |
| 5827 | echo "$as_me:5827: result: $cf_cv_enable_rpath" >&5 |
| 5828 | echo "${ECHO_T}$cf_cv_enable_rpath" >&6 |
| 5829 | |
| 5830 | echo "$as_me:5830: checking if shared libraries should be relinked during install" >&5 |
| 5831 | echo $ECHO_N "checking if shared libraries should be relinked during install... $ECHO_C" >&6 |
| 5832 | |
| 5833 | # Check whether --enable-relink or --disable-relink was given. |
| 5834 | if test "${enable_relink+set}" = set; then |
| 5835 | enableval="$enable_relink" |
| 5836 | cf_cv_do_relink=$enableval |
| 5837 | else |
| 5838 | cf_cv_do_relink=yes |
| 5839 | fi; |
| 5840 | echo "$as_me:5840: result: $cf_cv_do_relink" >&5 |
| 5841 | echo "${ECHO_T}$cf_cv_do_relink" >&6 |
| 5842 | ;; |
| 5843 | esac |
| 5844 | |
| 5845 | # we will build libraries one-level down. |
| 5846 | rel_builddir=.. |
| 5847 | |
| 5848 | LD_RPATH_OPT= |
| 5849 | echo "$as_me:5849: checking for an rpath option" >&5 |
| 5850 | echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6 |
| 5851 | case $cf_cv_system_name in |
| 5852 | (irix*) |
| 5853 | if test "$GCC" = yes; then |
| 5854 | LD_RPATH_OPT="-Wl,-rpath," |
| 5855 | else |
| 5856 | LD_RPATH_OPT="-rpath " |
| 5857 | fi |
| 5858 | ;; |
| 5859 | (linux*|gnu*|k*bsd*-gnu) |
| 5860 | LD_RPATH_OPT="-Wl,-rpath," |
| 5861 | ;; |
| 5862 | (openbsd[2-9].*|mirbsd*) |
| 5863 | LD_RPATH_OPT="-Wl,-rpath," |
| 5864 | ;; |
| 5865 | (dragonfly*|freebsd*) |
| 5866 | LD_RPATH_OPT="-rpath " |
| 5867 | ;; |
| 5868 | (netbsd*) |
| 5869 | LD_RPATH_OPT="-Wl,-rpath," |
| 5870 | ;; |
| 5871 | (osf*|mls+*) |
| 5872 | LD_RPATH_OPT="-rpath " |
| 5873 | ;; |
| 5874 | (solaris2*) |
| 5875 | LD_RPATH_OPT="-R" |
| 5876 | ;; |
| 5877 | (*) |
| 5878 | ;; |
| 5879 | esac |
| 5880 | echo "$as_me:5880: result: $LD_RPATH_OPT" >&5 |
| 5881 | echo "${ECHO_T}$LD_RPATH_OPT" >&6 |
| 5882 | |
| 5883 | case "x$LD_RPATH_OPT" in |
| 5884 | (x-R*) |
| 5885 | echo "$as_me:5885: checking if we need a space after rpath option" >&5 |
| 5886 | echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6 |
| 5887 | cf_save_LIBS="$LIBS" |
| 5888 | |
| 5889 | cf_add_libs="${LD_RPATH_OPT}$libdir" |
| 5890 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 5891 | for cf_add_1lib in $LIBS |
| 5892 | do |
| 5893 | for cf_add_2lib in $cf_add_libs |
| 5894 | do |
| 5895 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 5896 | then |
| 5897 | cf_add_1lib= |
| 5898 | break |
| 5899 | fi |
| 5900 | done |
| 5901 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 5902 | done |
| 5903 | LIBS="$cf_add_libs" |
| 5904 | |
| 5905 | cat >conftest.$ac_ext <<_ACEOF |
| 5906 | #line 5906 "configure" |
| 5907 | #include "confdefs.h" |
| 5908 | |
| 5909 | int |
| 5910 | main () |
| 5911 | { |
| 5912 | |
| 5913 | ; |
| 5914 | return 0; |
| 5915 | } |
| 5916 | _ACEOF |
| 5917 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 5918 | if { (eval echo "$as_me:5918: \"$ac_link\"") >&5 |
| 5919 | (eval $ac_link) 2>&5 |
| 5920 | ac_status=$? |
| 5921 | echo "$as_me:5921: \$? = $ac_status" >&5 |
| 5922 | (exit $ac_status); } && |
| 5923 | { ac_try='test -s conftest$ac_exeext' |
| 5924 | { (eval echo "$as_me:5924: \"$ac_try\"") >&5 |
| 5925 | (eval $ac_try) 2>&5 |
| 5926 | ac_status=$? |
| 5927 | echo "$as_me:5927: \$? = $ac_status" >&5 |
| 5928 | (exit $ac_status); }; }; then |
| 5929 | cf_rpath_space=no |
| 5930 | else |
| 5931 | echo "$as_me: failed program was:" >&5 |
| 5932 | cat conftest.$ac_ext >&5 |
| 5933 | cf_rpath_space=yes |
| 5934 | fi |
| 5935 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 5936 | LIBS="$cf_save_LIBS" |
| 5937 | echo "$as_me:5937: result: $cf_rpath_space" >&5 |
| 5938 | echo "${ECHO_T}$cf_rpath_space" >&6 |
| 5939 | test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT " |
| 5940 | ;; |
| 5941 | esac |
| 5942 | |
| 5943 | RM_SHARED_OPTS= |
| 5944 | LOCAL_LDFLAGS= |
| 5945 | LOCAL_LDFLAGS2= |
| 5946 | LD_SHARED_OPTS= |
| 5947 | INSTALL_LIB="-m 644" |
| 5948 | : ${rel_builddir:=.} |
| 5949 | |
| 5950 | shlibdir=$libdir |
| 5951 | |
| 5952 | MAKE_DLLS="#" |
| 5953 | |
| 5954 | cf_cv_do_symlinks=no |
| 5955 | cf_ld_rpath_opt= |
| 5956 | test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT" |
| 5957 | |
| 5958 | echo "$as_me:5958: checking if release/abi version should be used for shared libs" >&5 |
| 5959 | echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6 |
| 5960 | |
| 5961 | # Check whether --with-shlib-version or --without-shlib-version was given. |
| 5962 | if test "${with_shlib_version+set}" = set; then |
| 5963 | withval="$with_shlib_version" |
| 5964 | test -z "$withval" && withval=auto |
| 5965 | case $withval in |
| 5966 | (yes) |
| 5967 | cf_cv_shlib_version=auto |
| 5968 | ;; |
| 5969 | (rel|abi|auto|no) |
| 5970 | cf_cv_shlib_version=$withval |
| 5971 | ;; |
| 5972 | (*) |
| 5973 | { { echo "$as_me:5973: error: option value must be one of: rel, abi, auto or no" >&5 |
| 5974 | echo "$as_me: error: option value must be one of: rel, abi, auto or no" >&2;} |
| 5975 | { (exit 1); exit 1; }; } |
| 5976 | ;; |
| 5977 | esac |
| 5978 | |
| 5979 | else |
| 5980 | cf_cv_shlib_version=auto |
| 5981 | fi; |
| 5982 | echo "$as_me:5982: result: $cf_cv_shlib_version" >&5 |
| 5983 | echo "${ECHO_T}$cf_cv_shlib_version" >&6 |
| 5984 | |
| 5985 | cf_cv_rm_so_locs=no |
| 5986 | cf_try_cflags= |
| 5987 | |
| 5988 | # Some less-capable ports of gcc support only -fpic |
| 5989 | CC_SHARED_OPTS= |
| 5990 | if test "$GCC" = yes |
| 5991 | then |
| 5992 | echo "$as_me:5992: checking which $CC option to use" >&5 |
| 5993 | echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6 |
| 5994 | cf_save_CFLAGS="$CFLAGS" |
| 5995 | for CC_SHARED_OPTS in -fPIC -fpic '' |
| 5996 | do |
| 5997 | CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS" |
| 5998 | cat >conftest.$ac_ext <<_ACEOF |
| 5999 | #line 5999 "configure" |
| 6000 | #include "confdefs.h" |
| 6001 | #include <stdio.h> |
| 6002 | int |
| 6003 | main () |
| 6004 | { |
| 6005 | int x = 1 |
| 6006 | ; |
| 6007 | return 0; |
| 6008 | } |
| 6009 | _ACEOF |
| 6010 | rm -f conftest.$ac_objext |
| 6011 | if { (eval echo "$as_me:6011: \"$ac_compile\"") >&5 |
| 6012 | (eval $ac_compile) 2>&5 |
| 6013 | ac_status=$? |
| 6014 | echo "$as_me:6014: \$? = $ac_status" >&5 |
| 6015 | (exit $ac_status); } && |
| 6016 | { ac_try='test -s conftest.$ac_objext' |
| 6017 | { (eval echo "$as_me:6017: \"$ac_try\"") >&5 |
| 6018 | (eval $ac_try) 2>&5 |
| 6019 | ac_status=$? |
| 6020 | echo "$as_me:6020: \$? = $ac_status" >&5 |
| 6021 | (exit $ac_status); }; }; then |
| 6022 | break |
| 6023 | else |
| 6024 | echo "$as_me: failed program was:" >&5 |
| 6025 | cat conftest.$ac_ext >&5 |
| 6026 | fi |
| 6027 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6028 | done |
| 6029 | echo "$as_me:6029: result: $CC_SHARED_OPTS" >&5 |
| 6030 | echo "${ECHO_T}$CC_SHARED_OPTS" >&6 |
| 6031 | CFLAGS="$cf_save_CFLAGS" |
| 6032 | fi |
| 6033 | |
| 6034 | cf_cv_shlib_version_infix=no |
| 6035 | |
| 6036 | case $cf_cv_system_name in |
| 6037 | (aix4.3-9*|aix[5-7]*) |
| 6038 | if test "$GCC" = yes; then |
| 6039 | CC_SHARED_OPTS='-Wl,-brtl' |
| 6040 | MK_SHARED_LIB='${CC} -shared -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@' |
| 6041 | else |
| 6042 | CC_SHARED_OPTS='-brtl' |
| 6043 | # as well as '-qpic=large -G' or perhaps "-bM:SRE -bnoentry -bexpall" |
| 6044 | MK_SHARED_LIB='${CC} -G -Wl,-brtl -Wl,-blibpath:${RPATH_LIST}:/usr/lib -o $@' |
| 6045 | fi |
| 6046 | ;; |
| 6047 | (beos*) |
| 6048 | MK_SHARED_LIB='${CC} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0' |
| 6049 | ;; |
| 6050 | (cygwin*) |
| 6051 | CC_SHARED_OPTS= |
| 6052 | MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}' |
| 6053 | RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a" |
| 6054 | cf_cv_shlib_version=cygdll |
| 6055 | cf_cv_shlib_version_infix=cygdll |
| 6056 | shlibdir=$bindir |
| 6057 | MAKE_DLLS= |
| 6058 | cat >mk_shared_lib.sh <<-CF_EOF |
| 6059 | #!$SHELL |
| 6060 | SHARED_LIB=\$1 |
| 6061 | IMPORT_LIB=\`echo "\$1" | sed -e 's/cyg/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\` |
| 6062 | shift |
| 6063 | cat <<-EOF |
| 6064 | Linking shared library |
| 6065 | ** SHARED_LIB \$SHARED_LIB |
| 6066 | ** IMPORT_LIB \$IMPORT_LIB |
| 6067 | EOF |
| 6068 | exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB} |
| 6069 | CF_EOF |
| 6070 | chmod +x mk_shared_lib.sh |
| 6071 | ;; |
| 6072 | (msys*) |
| 6073 | CC_SHARED_OPTS= |
| 6074 | MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}' |
| 6075 | RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a" |
| 6076 | cf_cv_shlib_version=msysdll |
| 6077 | cf_cv_shlib_version_infix=msysdll |
| 6078 | shlibdir=$bindir |
| 6079 | MAKE_DLLS= |
| 6080 | cat >mk_shared_lib.sh <<-CF_EOF |
| 6081 | #!$SHELL |
| 6082 | SHARED_LIB=\$1 |
| 6083 | IMPORT_LIB=\`echo "\$1" | sed -e 's/msys-/lib/' -e 's/[0-9]*\.dll$/.dll.a/'\` |
| 6084 | shift |
| 6085 | cat <<-EOF |
| 6086 | Linking shared library |
| 6087 | ** SHARED_LIB \$SHARED_LIB |
| 6088 | ** IMPORT_LIB \$IMPORT_LIB |
| 6089 | EOF |
| 6090 | exec \$* -shared -Wl,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB} |
| 6091 | CF_EOF |
| 6092 | chmod +x mk_shared_lib.sh |
| 6093 | ;; |
| 6094 | (darwin*) |
| 6095 | cf_try_cflags="no-cpp-precomp" |
| 6096 | CC_SHARED_OPTS="-dynamic" |
| 6097 | MK_SHARED_LIB='${CC} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@' |
| 6098 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi |
| 6099 | cf_cv_shlib_version_infix=yes |
| 6100 | echo "$as_me:6100: checking if ld -search_paths_first works" >&5 |
| 6101 | echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6 |
| 6102 | if test "${cf_cv_ldflags_search_paths_first+set}" = set; then |
| 6103 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6104 | else |
| 6105 | |
| 6106 | cf_save_LDFLAGS=$LDFLAGS |
| 6107 | LDFLAGS="$LDFLAGS -Wl,-search_paths_first" |
| 6108 | cat >conftest.$ac_ext <<_ACEOF |
| 6109 | #line 6109 "configure" |
| 6110 | #include "confdefs.h" |
| 6111 | |
| 6112 | int |
| 6113 | main () |
| 6114 | { |
| 6115 | int i; |
| 6116 | ; |
| 6117 | return 0; |
| 6118 | } |
| 6119 | _ACEOF |
| 6120 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 6121 | if { (eval echo "$as_me:6121: \"$ac_link\"") >&5 |
| 6122 | (eval $ac_link) 2>&5 |
| 6123 | ac_status=$? |
| 6124 | echo "$as_me:6124: \$? = $ac_status" >&5 |
| 6125 | (exit $ac_status); } && |
| 6126 | { ac_try='test -s conftest$ac_exeext' |
| 6127 | { (eval echo "$as_me:6127: \"$ac_try\"") >&5 |
| 6128 | (eval $ac_try) 2>&5 |
| 6129 | ac_status=$? |
| 6130 | echo "$as_me:6130: \$? = $ac_status" >&5 |
| 6131 | (exit $ac_status); }; }; then |
| 6132 | cf_cv_ldflags_search_paths_first=yes |
| 6133 | else |
| 6134 | echo "$as_me: failed program was:" >&5 |
| 6135 | cat conftest.$ac_ext >&5 |
| 6136 | cf_cv_ldflags_search_paths_first=no |
| 6137 | fi |
| 6138 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 6139 | LDFLAGS=$cf_save_LDFLAGS |
| 6140 | fi |
| 6141 | echo "$as_me:6141: result: $cf_cv_ldflags_search_paths_first" >&5 |
| 6142 | echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6 |
| 6143 | if test $cf_cv_ldflags_search_paths_first = yes; then |
| 6144 | LDFLAGS="$LDFLAGS -Wl,-search_paths_first" |
| 6145 | fi |
| 6146 | ;; |
| 6147 | (hpux[7-8]*) |
| 6148 | # HP-UX 8.07 ld lacks "+b" option used for libdir search-list |
| 6149 | if test "$GCC" != yes; then |
| 6150 | CC_SHARED_OPTS='+Z' |
| 6151 | fi |
| 6152 | MK_SHARED_LIB='${LD} -b -o $@' |
| 6153 | INSTALL_LIB="-m 555" |
| 6154 | ;; |
| 6155 | (hpux*) |
| 6156 | # (tested with gcc 2.7.2 -- I don't have c89) |
| 6157 | if test "$GCC" = yes; then |
| 6158 | LD_SHARED_OPTS='-Xlinker +b -Xlinker ${libdir}' |
| 6159 | else |
| 6160 | CC_SHARED_OPTS='+Z' |
| 6161 | LD_SHARED_OPTS='-Wl,+b,${libdir}' |
| 6162 | fi |
| 6163 | MK_SHARED_LIB='${LD} +b ${libdir} -b -o $@' |
| 6164 | # HP-UX shared libraries must be executable, and should be |
| 6165 | # readonly to exploit a quirk in the memory manager. |
| 6166 | INSTALL_LIB="-m 555" |
| 6167 | ;; |
| 6168 | (interix*) |
| 6169 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6170 | if test "$cf_cv_shlib_version" = rel; then |
| 6171 | cf_shared_soname='`basename .${REL_VERSION}`.${ABI_VERSION}' |
| 6172 | else |
| 6173 | cf_shared_soname='`basename `' |
| 6174 | fi |
| 6175 | CC_SHARED_OPTS= |
| 6176 | MK_SHARED_LIB='${CC} -shared -Wl,-rpath,${RPATH_LIST} -Wl,-h,'$cf_shared_soname' -o ' |
| 6177 | ;; |
| 6178 | (irix*) |
| 6179 | if test "$cf_cv_enable_rpath" = yes ; then |
| 6180 | EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS" |
| 6181 | fi |
| 6182 | # tested with IRIX 5.2 and 'cc'. |
| 6183 | if test "$GCC" != yes; then |
| 6184 | CC_SHARED_OPTS='-KPIC' |
| 6185 | MK_SHARED_LIB='${CC} -shared -rdata_shared -soname `basename $@` -o $@' |
| 6186 | else |
| 6187 | MK_SHARED_LIB='${CC} -shared -Wl,-soname,`basename $@` -o $@' |
| 6188 | fi |
| 6189 | cf_cv_rm_so_locs=yes |
| 6190 | ;; |
| 6191 | (linux*|gnu*|k*bsd*-gnu) |
| 6192 | if test "$DFT_LWR_MODEL" = "shared" ; then |
| 6193 | LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)" |
| 6194 | LOCAL_LDFLAGS2="$LOCAL_LDFLAGS" |
| 6195 | fi |
| 6196 | if test "$cf_cv_enable_rpath" = yes ; then |
| 6197 | EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS" |
| 6198 | fi |
| 6199 | |
| 6200 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6201 | if test "$cf_cv_shlib_version" = rel; then |
| 6202 | cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}' |
| 6203 | else |
| 6204 | cf_cv_shared_soname='`basename $@`' |
| 6205 | fi |
| 6206 | |
| 6207 | MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@' |
| 6208 | ;; |
| 6209 | (mingw*) |
| 6210 | cf_cv_shlib_version=mingw |
| 6211 | cf_cv_shlib_version_infix=mingw |
| 6212 | shlibdir=$bindir |
| 6213 | MAKE_DLLS= |
| 6214 | if test "$DFT_LWR_MODEL" = "shared" ; then |
| 6215 | LOCAL_LDFLAGS="-Wl,--enable-auto-import" |
| 6216 | LOCAL_LDFLAGS2="$LOCAL_LDFLAGS" |
| 6217 | EXTRA_LDFLAGS="-Wl,--enable-auto-import $EXTRA_LDFLAGS" |
| 6218 | fi |
| 6219 | CC_SHARED_OPTS= |
| 6220 | MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${CC} ${CFLAGS}' |
| 6221 | RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.a" |
| 6222 | cat >mk_shared_lib.sh <<-CF_EOF |
| 6223 | #!$SHELL |
| 6224 | SHARED_LIB=\$1 |
| 6225 | IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.a/'\` |
| 6226 | shift |
| 6227 | cat <<-EOF |
| 6228 | Linking shared library |
| 6229 | ** SHARED_LIB \$SHARED_LIB |
| 6230 | ** IMPORT_LIB \$IMPORT_LIB |
| 6231 | EOF |
| 6232 | exec \$* -shared -Wl,--enable-auto-import,--out-implib=\${IMPORT_LIB} -Wl,--export-all-symbols -o \${SHARED_LIB} |
| 6233 | CF_EOF |
| 6234 | chmod +x mk_shared_lib.sh |
| 6235 | ;; |
| 6236 | (openbsd[2-9].*|mirbsd*) |
| 6237 | if test "$DFT_LWR_MODEL" = "shared" ; then |
| 6238 | LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)" |
| 6239 | LOCAL_LDFLAGS2="$LOCAL_LDFLAGS" |
| 6240 | fi |
| 6241 | if test "$cf_cv_enable_rpath" = yes ; then |
| 6242 | EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS" |
| 6243 | fi |
| 6244 | CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC" |
| 6245 | |
| 6246 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6247 | if test "$cf_cv_shlib_version" = rel; then |
| 6248 | cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}' |
| 6249 | else |
| 6250 | cf_cv_shared_soname='`basename $@`' |
| 6251 | fi |
| 6252 | |
| 6253 | MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@' |
| 6254 | ;; |
| 6255 | (nto-qnx*|openbsd*|freebsd[12].*) |
| 6256 | CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC" |
| 6257 | MK_SHARED_LIB='${LD} -Bshareable -o $@' |
| 6258 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6259 | ;; |
| 6260 | (dragonfly*|freebsd*) |
| 6261 | CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC" |
| 6262 | if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then |
| 6263 | LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)" |
| 6264 | LOCAL_LDFLAGS2="${cf_ld_rpath_opt}\${RPATH_LIST} $LOCAL_LDFLAGS" |
| 6265 | EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS" |
| 6266 | fi |
| 6267 | |
| 6268 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6269 | if test "$cf_cv_shlib_version" = rel; then |
| 6270 | cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}' |
| 6271 | else |
| 6272 | cf_cv_shared_soname='`basename $@`' |
| 6273 | fi |
| 6274 | |
| 6275 | MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@' |
| 6276 | ;; |
| 6277 | (netbsd*) |
| 6278 | CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC" |
| 6279 | if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_enable_rpath" = yes ; then |
| 6280 | LOCAL_LDFLAGS="${cf_ld_rpath_opt}\$(LOCAL_LIBDIR)" |
| 6281 | LOCAL_LDFLAGS2="$LOCAL_LDFLAGS" |
| 6282 | EXTRA_LDFLAGS="${cf_ld_rpath_opt}\${RPATH_LIST} $EXTRA_LDFLAGS" |
| 6283 | if test "$cf_cv_shlib_version" = auto; then |
| 6284 | if test -f /usr/libexec/ld.elf_so; then |
| 6285 | cf_cv_shlib_version=abi |
| 6286 | else |
| 6287 | cf_cv_shlib_version=rel |
| 6288 | fi |
| 6289 | fi |
| 6290 | |
| 6291 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6292 | if test "$cf_cv_shlib_version" = rel; then |
| 6293 | cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}' |
| 6294 | else |
| 6295 | cf_cv_shared_soname='`basename $@`' |
| 6296 | fi |
| 6297 | |
| 6298 | MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@' |
| 6299 | else |
| 6300 | MK_SHARED_LIB='${CC} -Wl,-shared -Wl,-Bshareable -o $@' |
| 6301 | fi |
| 6302 | ;; |
| 6303 | (osf*|mls+*) |
| 6304 | # tested with OSF/1 V3.2 and 'cc' |
| 6305 | # tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't |
| 6306 | # link with shared libs). |
| 6307 | MK_SHARED_LIB='${LD} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`' |
| 6308 | case $host_os in |
| 6309 | (osf4*) |
| 6310 | MK_SHARED_LIB="${MK_SHARED_LIB} -msym" |
| 6311 | ;; |
| 6312 | esac |
| 6313 | MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@' |
| 6314 | if test "$DFT_LWR_MODEL" = "shared" ; then |
| 6315 | LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)" |
| 6316 | LOCAL_LDFLAGS2="$LOCAL_LDFLAGS" |
| 6317 | fi |
| 6318 | cf_cv_rm_so_locs=yes |
| 6319 | ;; |
| 6320 | (sco3.2v5*) # also uw2* and UW7: hops 13-Apr-98 |
| 6321 | # tested with osr5.0.5 |
| 6322 | if test "$GCC" != yes; then |
| 6323 | CC_SHARED_OPTS='-belf -KPIC' |
| 6324 | fi |
| 6325 | MK_SHARED_LIB='${LD} -dy -G -h `basename $@ .${REL_VERSION}`.${ABI_VERSION} -o $@' |
| 6326 | if test "$cf_cv_enable_rpath" = yes ; then |
| 6327 | # only way is to set LD_RUN_PATH but no switch for it |
| 6328 | RUN_PATH=$libdir |
| 6329 | fi |
| 6330 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6331 | LINK_PROGS='LD_RUN_PATH=${libdir}' |
| 6332 | LINK_TESTS='Pwd=`pwd`;LD_RUN_PATH=`dirname $${Pwd}`/lib' |
| 6333 | ;; |
| 6334 | (sunos4*) |
| 6335 | # tested with SunOS 4.1.1 and gcc 2.7.0 |
| 6336 | if test "$GCC" != yes; then |
| 6337 | CC_SHARED_OPTS='-KPIC' |
| 6338 | fi |
| 6339 | MK_SHARED_LIB='${LD} -assert pure-text -o $@' |
| 6340 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6341 | ;; |
| 6342 | (solaris2*) |
| 6343 | # tested with SunOS 5.5.1 (solaris 2.5.1) and gcc 2.7.2 |
| 6344 | # tested with SunOS 5.10 (solaris 10) and gcc 3.4.3 |
| 6345 | if test "$DFT_LWR_MODEL" = "shared" ; then |
| 6346 | LOCAL_LDFLAGS="-R \$(LOCAL_LIBDIR):\${libdir}" |
| 6347 | LOCAL_LDFLAGS2="$LOCAL_LDFLAGS" |
| 6348 | fi |
| 6349 | if test "$cf_cv_enable_rpath" = yes ; then |
| 6350 | EXTRA_LDFLAGS="-R \${libdir} $EXTRA_LDFLAGS" |
| 6351 | fi |
| 6352 | |
| 6353 | test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=rel |
| 6354 | if test "$cf_cv_shlib_version" = rel; then |
| 6355 | cf_cv_shared_soname='`basename $@ .${REL_VERSION}`.${ABI_VERSION}' |
| 6356 | else |
| 6357 | cf_cv_shared_soname='`basename $@`' |
| 6358 | fi |
| 6359 | |
| 6360 | if test "$GCC" != yes; then |
| 6361 | cf_save_CFLAGS="$CFLAGS" |
| 6362 | for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O |
| 6363 | do |
| 6364 | CFLAGS="$cf_shared_opts $cf_save_CFLAGS" |
| 6365 | cat >conftest.$ac_ext <<_ACEOF |
| 6366 | #line 6366 "configure" |
| 6367 | #include "confdefs.h" |
| 6368 | #include <stdio.h> |
| 6369 | int |
| 6370 | main () |
| 6371 | { |
| 6372 | printf("Hello\n"); |
| 6373 | ; |
| 6374 | return 0; |
| 6375 | } |
| 6376 | _ACEOF |
| 6377 | rm -f conftest.$ac_objext |
| 6378 | if { (eval echo "$as_me:6378: \"$ac_compile\"") >&5 |
| 6379 | (eval $ac_compile) 2>&5 |
| 6380 | ac_status=$? |
| 6381 | echo "$as_me:6381: \$? = $ac_status" >&5 |
| 6382 | (exit $ac_status); } && |
| 6383 | { ac_try='test -s conftest.$ac_objext' |
| 6384 | { (eval echo "$as_me:6384: \"$ac_try\"") >&5 |
| 6385 | (eval $ac_try) 2>&5 |
| 6386 | ac_status=$? |
| 6387 | echo "$as_me:6387: \$? = $ac_status" >&5 |
| 6388 | (exit $ac_status); }; }; then |
| 6389 | break |
| 6390 | else |
| 6391 | echo "$as_me: failed program was:" >&5 |
| 6392 | cat conftest.$ac_ext >&5 |
| 6393 | fi |
| 6394 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 6395 | done |
| 6396 | CFLAGS="$cf_save_CFLAGS" |
| 6397 | CC_SHARED_OPTS=$cf_shared_opts |
| 6398 | MK_SHARED_LIB='${CC} -dy -G -h '$cf_cv_shared_soname' -o $@' |
| 6399 | else |
| 6400 | MK_SHARED_LIB='${CC} -shared -dy -G -h '$cf_cv_shared_soname' -o $@' |
| 6401 | fi |
| 6402 | ;; |
| 6403 | (sysv5uw7*|unix_sv*) |
| 6404 | # tested with UnixWare 7.1.0 (gcc 2.95.2 and cc) |
| 6405 | if test "$GCC" != yes; then |
| 6406 | CC_SHARED_OPTS='-KPIC' |
| 6407 | fi |
| 6408 | MK_SHARED_LIB='${LD} -d y -G -o $@' |
| 6409 | ;; |
| 6410 | (*) |
| 6411 | CC_SHARED_OPTS='unknown' |
| 6412 | MK_SHARED_LIB='echo unknown' |
| 6413 | ;; |
| 6414 | esac |
| 6415 | |
| 6416 | # This works if the last tokens in $MK_SHARED_LIB are the -o target. |
| 6417 | case "$cf_cv_shlib_version" in |
| 6418 | (rel|abi) |
| 6419 | case "$MK_SHARED_LIB" in |
| 6420 | (*'-o $@') |
| 6421 | test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes |
| 6422 | ;; |
| 6423 | (*) |
| 6424 | { echo "$as_me:6424: WARNING: ignored --with-shlib-version" >&5 |
| 6425 | echo "$as_me: WARNING: ignored --with-shlib-version" >&2;} |
| 6426 | ;; |
| 6427 | esac |
| 6428 | ;; |
| 6429 | esac |
| 6430 | |
| 6431 | if test -n "$cf_try_cflags" |
| 6432 | then |
| 6433 | cat > conftest.$ac_ext <<EOF |
| 6434 | #line 6434 "${as_me:-configure}" |
| 6435 | #include <stdio.h> |
| 6436 | int main(int argc, char *argv[]) |
| 6437 | { |
| 6438 | printf("hello\n"); |
| 6439 | return (argv[argc-1] == 0) ; |
| 6440 | } |
| 6441 | EOF |
| 6442 | cf_save_CFLAGS="$CFLAGS" |
| 6443 | for cf_opt in $cf_try_cflags |
| 6444 | do |
| 6445 | CFLAGS="$cf_save_CFLAGS -$cf_opt" |
| 6446 | echo "$as_me:6446: checking if CFLAGS option -$cf_opt works" >&5 |
| 6447 | echo $ECHO_N "checking if CFLAGS option -$cf_opt works... $ECHO_C" >&6 |
| 6448 | if { (eval echo "$as_me:6448: \"$ac_compile\"") >&5 |
| 6449 | (eval $ac_compile) 2>&5 |
| 6450 | ac_status=$? |
| 6451 | echo "$as_me:6451: \$? = $ac_status" >&5 |
| 6452 | (exit $ac_status); }; then |
| 6453 | echo "$as_me:6453: result: yes" >&5 |
| 6454 | echo "${ECHO_T}yes" >&6 |
| 6455 | cf_save_CFLAGS="$CFLAGS" |
| 6456 | else |
| 6457 | echo "$as_me:6457: result: no" >&5 |
| 6458 | echo "${ECHO_T}no" >&6 |
| 6459 | fi |
| 6460 | done |
| 6461 | CFLAGS="$cf_save_CFLAGS" |
| 6462 | fi |
| 6463 | |
| 6464 | # RPATH_LIST is a colon-separated list of directories |
| 6465 | test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}" |
| 6466 | test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}" |
| 6467 | |
| 6468 | test $cf_cv_rm_so_locs = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations" |
| 6469 | |
| 6470 | test -n "$verbose" && echo " CC_SHARED_OPTS: $CC_SHARED_OPTS" 1>&6 |
| 6471 | |
| 6472 | echo "${as_me:-configure}:6472: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5 |
| 6473 | |
| 6474 | test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6 |
| 6475 | |
| 6476 | echo "${as_me:-configure}:6476: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5 |
| 6477 | |
| 6478 | for model in $cf_list_models; do |
| 6479 | case $model in |
| 6480 | (libtool) |
| 6481 | |
| 6482 | echo "$as_me:6482: checking for additional libtool options" >&5 |
| 6483 | echo $ECHO_N "checking for additional libtool options... $ECHO_C" >&6 |
| 6484 | |
| 6485 | # Check whether --with-libtool-opts or --without-libtool-opts was given. |
| 6486 | if test "${with_libtool_opts+set}" = set; then |
| 6487 | withval="$with_libtool_opts" |
| 6488 | with_libtool_opts=$withval |
| 6489 | else |
| 6490 | with_libtool_opts=no |
| 6491 | fi; |
| 6492 | echo "$as_me:6492: result: $with_libtool_opts" >&5 |
| 6493 | echo "${ECHO_T}$with_libtool_opts" >&6 |
| 6494 | |
| 6495 | case .$with_libtool_opts in |
| 6496 | (.yes|.no|.) |
| 6497 | ;; |
| 6498 | (*) |
| 6499 | LIBTOOL_OPTS="$LIBTOOL_OPTS $with_libtool_opts" |
| 6500 | ;; |
| 6501 | esac |
| 6502 | |
| 6503 | echo "$as_me:6503: checking if exported-symbols file should be used" >&5 |
| 6504 | echo $ECHO_N "checking if exported-symbols file should be used... $ECHO_C" >&6 |
| 6505 | |
| 6506 | # Check whether --with-export-syms or --without-export-syms was given. |
| 6507 | if test "${with_export_syms+set}" = set; then |
| 6508 | withval="$with_export_syms" |
| 6509 | with_export_syms=$withval |
| 6510 | else |
| 6511 | with_export_syms=no |
| 6512 | fi; |
| 6513 | if test "x$with_export_syms" = xyes |
| 6514 | then |
| 6515 | with_export_syms='${top_srcdir}/package/${PACKAGE}.sym' |
| 6516 | |
| 6517 | fi |
| 6518 | echo "$as_me:6518: result: $with_export_syms" >&5 |
| 6519 | echo "${ECHO_T}$with_export_syms" >&6 |
| 6520 | if test "x$with_export_syms" != xno |
| 6521 | then |
| 6522 | EXPORT_SYMS="-export-symbols $with_export_syms" |
| 6523 | |
| 6524 | fi |
| 6525 | |
| 6526 | ;; |
| 6527 | (shared) |
| 6528 | if test "$CC_SHARED_OPTS" = "unknown"; then |
| 6529 | { { echo "$as_me:6529: error: Shared libraries are not supported in this version" >&5 |
| 6530 | echo "$as_me: error: Shared libraries are not supported in this version" >&2;} |
| 6531 | { (exit 1); exit 1; }; } |
| 6532 | fi |
| 6533 | |
| 6534 | echo "$as_me:6534: checking if versioned-symbols file should be used" >&5 |
| 6535 | echo $ECHO_N "checking if versioned-symbols file should be used... $ECHO_C" >&6 |
| 6536 | |
| 6537 | # Check whether --with-versioned-syms or --without-versioned-syms was given. |
| 6538 | if test "${with_versioned_syms+set}" = set; then |
| 6539 | withval="$with_versioned_syms" |
| 6540 | with_versioned_syms=$withval |
| 6541 | else |
| 6542 | with_versioned_syms=no |
| 6543 | fi; |
| 6544 | if test "x$with_versioned_syms" = xyes |
| 6545 | then |
| 6546 | with_versioned_syms='${top_srcdir}/package/${PACKAGE}.map' |
| 6547 | |
| 6548 | fi |
| 6549 | echo "$as_me:6549: result: $with_versioned_syms" >&5 |
| 6550 | echo "${ECHO_T}$with_versioned_syms" >&6 |
| 6551 | |
| 6552 | RESULTING_SYMS= |
| 6553 | VERSIONED_SYMS= |
| 6554 | WILDCARD_SYMS= |
| 6555 | |
| 6556 | if test "x$with_versioned_syms" != xno |
| 6557 | then |
| 6558 | RESULTING_SYMS=$with_versioned_syms |
| 6559 | case "x$MK_SHARED_LIB" in |
| 6560 | (*-Wl,*) |
| 6561 | VERSIONED_SYMS="-Wl,--version-script,\${RESULTING_SYMS}" |
| 6562 | MK_SHARED_LIB=`echo "$MK_SHARED_LIB" | sed -e "s%-Wl,%\\${VERSIONED_SYMS} -Wl,%"` |
| 6563 | test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6 |
| 6564 | |
| 6565 | echo "${as_me:-configure}:6565: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5 |
| 6566 | |
| 6567 | ;; |
| 6568 | (*-dy\ *) |
| 6569 | VERSIONED_SYMS="-Wl,-M,\${RESULTING_SYMS}" |
| 6570 | MK_SHARED_LIB=`echo "$MK_SHARED_LIB" | sed -e "s%-dy%\\${VERSIONED_SYMS} -dy%"` |
| 6571 | test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6 |
| 6572 | |
| 6573 | echo "${as_me:-configure}:6573: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5 |
| 6574 | |
| 6575 | ;; |
| 6576 | (*) |
| 6577 | { echo "$as_me:6577: WARNING: this system does not support versioned-symbols" >&5 |
| 6578 | echo "$as_me: WARNING: this system does not support versioned-symbols" >&2;} |
| 6579 | ;; |
| 6580 | esac |
| 6581 | |
| 6582 | # Linux ld can selectively override scope, e.g., of symbols beginning with |
| 6583 | # "_" by first declaring some as global, and then using a wildcard to |
| 6584 | # declare the others as local. Some other loaders cannot do this. Check |
| 6585 | # by constructing a (very) simple shared library and inspecting its |
| 6586 | # symbols. |
| 6587 | if test "x$VERSIONED_SYMS" != "x" |
| 6588 | then |
| 6589 | echo "$as_me:6589: checking if wildcards can be used to selectively omit symbols" >&5 |
| 6590 | echo $ECHO_N "checking if wildcards can be used to selectively omit symbols... $ECHO_C" >&6 |
| 6591 | WILDCARD_SYMS=no |
| 6592 | |
| 6593 | # make sources |
| 6594 | rm -f conftest.* |
| 6595 | |
| 6596 | cat >conftest.ver <<EOF |
| 6597 | module_1.0 { |
| 6598 | global: |
| 6599 | globalf1; |
| 6600 | local: |
| 6601 | localf1; |
| 6602 | }; |
| 6603 | module_2.0 { |
| 6604 | global: |
| 6605 | globalf2; |
| 6606 | local: |
| 6607 | localf2; |
| 6608 | _*; |
| 6609 | } module_1.0; |
| 6610 | submodule_1.0 { |
| 6611 | global: |
| 6612 | subglobalf1; |
| 6613 | _ismissing; |
| 6614 | local: |
| 6615 | sublocalf1; |
| 6616 | }; |
| 6617 | submodule_2.0 { |
| 6618 | global: |
| 6619 | subglobalf2; |
| 6620 | local: |
| 6621 | sublocalf2; |
| 6622 | _*; |
| 6623 | } submodule_1.0; |
| 6624 | EOF |
| 6625 | cat >conftest.$ac_ext <<EOF |
| 6626 | #line 6626 "configure" |
| 6627 | int _ismissing(void) { return 1; } |
| 6628 | int _localf1(void) { return 1; } |
| 6629 | int _localf2(void) { return 2; } |
| 6630 | int globalf1(void) { return 1; } |
| 6631 | int globalf2(void) { return 2; } |
| 6632 | int _sublocalf1(void) { return 1; } |
| 6633 | int _sublocalf2(void) { return 2; } |
| 6634 | int subglobalf1(void) { return 1; } |
| 6635 | int subglobalf2(void) { return 2; } |
| 6636 | EOF |
| 6637 | cat >conftest.mk <<EOF |
| 6638 | CC=${CC} |
| 6639 | CFLAGS=${CFLAGS} |
| 6640 | CPPFLAGS=${CPPFLAGS} |
| 6641 | LDFLAGS=${LDFLAGS} |
| 6642 | LIBS=${LIBS} |
| 6643 | VERSIONED_SYMS=${VERSIONED_SYMS} |
| 6644 | RESULTING_SYMS=conftest.ver |
| 6645 | MK_SHARED_LIB=${MK_SHARED_LIB} |
| 6646 | conftest.so: conftest.$ac_cv_objext |
| 6647 | \$(MK_SHARED_LIB) conftest.$ac_cv_objext |
| 6648 | EOF |
| 6649 | |
| 6650 | # compile source, make library |
| 6651 | if make -f conftest.mk 2>&5 >/dev/null |
| 6652 | then |
| 6653 | # test for missing symbol |
| 6654 | cf_missing=`nm -P conftest.so 2>&5 |fgrep _ismissing | egrep '[ ]T[ ]'` |
| 6655 | test -n "$cf_missing" && WILDCARD_SYMS=yes |
| 6656 | fi |
| 6657 | echo "$as_me:6657: result: $WILDCARD_SYMS" >&5 |
| 6658 | echo "${ECHO_T}$WILDCARD_SYMS" >&6 |
| 6659 | rm -f conftest.* |
| 6660 | fi |
| 6661 | fi |
| 6662 | |
| 6663 | ;; |
| 6664 | esac |
| 6665 | done |
| 6666 | |
| 6667 | # pretend that ncurses==ncursesw==ncursest |
| 6668 | echo "$as_me:6668: checking if you want to disable library suffixes" >&5 |
| 6669 | echo $ECHO_N "checking if you want to disable library suffixes... $ECHO_C" >&6 |
| 6670 | |
| 6671 | # Check whether --enable-lib-suffixes or --disable-lib-suffixes was given. |
| 6672 | if test "${enable_lib_suffixes+set}" = set; then |
| 6673 | enableval="$enable_lib_suffixes" |
| 6674 | test "$enableval" != no && enableval=yes |
| 6675 | if test "$enableval" != "yes" ; then |
| 6676 | disable_lib_suffixes=yes |
| 6677 | else |
| 6678 | disable_lib_suffixes=no |
| 6679 | fi |
| 6680 | else |
| 6681 | enableval=yes |
| 6682 | disable_lib_suffixes=no |
| 6683 | |
| 6684 | fi; |
| 6685 | echo "$as_me:6685: result: $disable_lib_suffixes" >&5 |
| 6686 | echo "${ECHO_T}$disable_lib_suffixes" >&6 |
| 6687 | |
| 6688 | ### If we're building with rpath, try to link non-standard libs that way too. |
| 6689 | if test "$DFT_LWR_MODEL" = "shared"; then |
| 6690 | |
| 6691 | echo "$as_me:6691: checking if rpath-hack should be disabled" >&5 |
| 6692 | echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6 |
| 6693 | |
| 6694 | # Check whether --enable-rpath-hack or --disable-rpath-hack was given. |
| 6695 | if test "${enable_rpath_hack+set}" = set; then |
| 6696 | enableval="$enable_rpath_hack" |
| 6697 | test "$enableval" != no && enableval=yes |
| 6698 | if test "$enableval" != "yes" ; then |
| 6699 | cf_disable_rpath_hack=yes |
| 6700 | else |
| 6701 | cf_disable_rpath_hack=no |
| 6702 | fi |
| 6703 | else |
| 6704 | enableval=yes |
| 6705 | cf_disable_rpath_hack=no |
| 6706 | |
| 6707 | fi; |
| 6708 | echo "$as_me:6708: result: $cf_disable_rpath_hack" >&5 |
| 6709 | echo "${ECHO_T}$cf_disable_rpath_hack" >&6 |
| 6710 | if test "$cf_disable_rpath_hack" = no ; then |
| 6711 | |
| 6712 | echo "$as_me:6712: checking for updated LDFLAGS" >&5 |
| 6713 | echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6 |
| 6714 | if test -n "$LD_RPATH_OPT" ; then |
| 6715 | echo "$as_me:6715: result: maybe" >&5 |
| 6716 | echo "${ECHO_T}maybe" >&6 |
| 6717 | |
| 6718 | for ac_prog in ldd |
| 6719 | do |
| 6720 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 6721 | set dummy $ac_prog; ac_word=$2 |
| 6722 | echo "$as_me:6722: checking for $ac_word" >&5 |
| 6723 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 6724 | if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then |
| 6725 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 6726 | else |
| 6727 | if test -n "$cf_ldd_prog"; then |
| 6728 | ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test. |
| 6729 | else |
| 6730 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 6731 | ac_dummy="$PATH" |
| 6732 | for ac_dir in $ac_dummy; do |
| 6733 | IFS=$ac_save_IFS |
| 6734 | test -z "$ac_dir" && ac_dir=. |
| 6735 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 6736 | ac_cv_prog_cf_ldd_prog="$ac_prog" |
| 6737 | echo "$as_me:6737: found $ac_dir/$ac_word" >&5 |
| 6738 | break |
| 6739 | done |
| 6740 | |
| 6741 | fi |
| 6742 | fi |
| 6743 | cf_ldd_prog=$ac_cv_prog_cf_ldd_prog |
| 6744 | if test -n "$cf_ldd_prog"; then |
| 6745 | echo "$as_me:6745: result: $cf_ldd_prog" >&5 |
| 6746 | echo "${ECHO_T}$cf_ldd_prog" >&6 |
| 6747 | else |
| 6748 | echo "$as_me:6748: result: no" >&5 |
| 6749 | echo "${ECHO_T}no" >&6 |
| 6750 | fi |
| 6751 | |
| 6752 | test -n "$cf_ldd_prog" && break |
| 6753 | done |
| 6754 | test -n "$cf_ldd_prog" || cf_ldd_prog="no" |
| 6755 | |
| 6756 | cf_rpath_list="/usr/lib /lib" |
| 6757 | if test "$cf_ldd_prog" != no |
| 6758 | then |
| 6759 | cf_rpath_oops= |
| 6760 | |
| 6761 | cat >conftest.$ac_ext <<_ACEOF |
| 6762 | #line 6762 "configure" |
| 6763 | #include "confdefs.h" |
| 6764 | #include <stdio.h> |
| 6765 | int |
| 6766 | main () |
| 6767 | { |
| 6768 | printf("Hello"); |
| 6769 | ; |
| 6770 | return 0; |
| 6771 | } |
| 6772 | _ACEOF |
| 6773 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 6774 | if { (eval echo "$as_me:6774: \"$ac_link\"") >&5 |
| 6775 | (eval $ac_link) 2>&5 |
| 6776 | ac_status=$? |
| 6777 | echo "$as_me:6777: \$? = $ac_status" >&5 |
| 6778 | (exit $ac_status); } && |
| 6779 | { ac_try='test -s conftest$ac_exeext' |
| 6780 | { (eval echo "$as_me:6780: \"$ac_try\"") >&5 |
| 6781 | (eval $ac_try) 2>&5 |
| 6782 | ac_status=$? |
| 6783 | echo "$as_me:6783: \$? = $ac_status" >&5 |
| 6784 | (exit $ac_status); }; }; then |
| 6785 | cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq` |
| 6786 | cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq` |
| 6787 | else |
| 6788 | echo "$as_me: failed program was:" >&5 |
| 6789 | cat conftest.$ac_ext >&5 |
| 6790 | fi |
| 6791 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 6792 | |
| 6793 | # If we passed the link-test, but get a "not found" on a given library, |
| 6794 | # this could be due to inept reconfiguration of gcc to make it only |
| 6795 | # partly honor /usr/local/lib (or whatever). Sometimes this behavior |
| 6796 | # is intentional, e.g., installing gcc in /usr/bin and suppressing the |
| 6797 | # /usr/local libraries. |
| 6798 | if test -n "$cf_rpath_oops" |
| 6799 | then |
| 6800 | for cf_rpath_src in $cf_rpath_oops |
| 6801 | do |
| 6802 | for cf_rpath_dir in \ |
| 6803 | /usr/local \ |
| 6804 | /usr/pkg \ |
| 6805 | /opt/sfw |
| 6806 | do |
| 6807 | if test -f $cf_rpath_dir/lib/$cf_rpath_src |
| 6808 | then |
| 6809 | test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6 |
| 6810 | |
| 6811 | echo "${as_me:-configure}:6811: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5 |
| 6812 | |
| 6813 | LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib" |
| 6814 | break |
| 6815 | fi |
| 6816 | done |
| 6817 | done |
| 6818 | fi |
| 6819 | fi |
| 6820 | |
| 6821 | test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6 |
| 6822 | |
| 6823 | echo "${as_me:-configure}:6823: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5 |
| 6824 | |
| 6825 | test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6 |
| 6826 | |
| 6827 | echo "${as_me:-configure}:6827: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5 |
| 6828 | |
| 6829 | cf_rpath_dst= |
| 6830 | for cf_rpath_src in $LDFLAGS |
| 6831 | do |
| 6832 | case $cf_rpath_src in |
| 6833 | (-L*) |
| 6834 | |
| 6835 | # check if this refers to a directory which we will ignore |
| 6836 | cf_rpath_skip=no |
| 6837 | if test -n "$cf_rpath_list" |
| 6838 | then |
| 6839 | for cf_rpath_item in $cf_rpath_list |
| 6840 | do |
| 6841 | if test "x$cf_rpath_src" = "x-L$cf_rpath_item" |
| 6842 | then |
| 6843 | cf_rpath_skip=yes |
| 6844 | break |
| 6845 | fi |
| 6846 | done |
| 6847 | fi |
| 6848 | |
| 6849 | if test "$cf_rpath_skip" = no |
| 6850 | then |
| 6851 | # transform the option |
| 6852 | if test "$LD_RPATH_OPT" = "-R " ; then |
| 6853 | cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"` |
| 6854 | else |
| 6855 | cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"` |
| 6856 | fi |
| 6857 | |
| 6858 | # if we have not already added this, add it now |
| 6859 | cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"` |
| 6860 | if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS" |
| 6861 | then |
| 6862 | test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6 |
| 6863 | |
| 6864 | echo "${as_me:-configure}:6864: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5 |
| 6865 | |
| 6866 | EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS" |
| 6867 | fi |
| 6868 | fi |
| 6869 | ;; |
| 6870 | esac |
| 6871 | cf_rpath_dst="$cf_rpath_dst $cf_rpath_src" |
| 6872 | done |
| 6873 | LDFLAGS=$cf_rpath_dst |
| 6874 | |
| 6875 | test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6 |
| 6876 | |
| 6877 | echo "${as_me:-configure}:6877: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5 |
| 6878 | |
| 6879 | test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6 |
| 6880 | |
| 6881 | echo "${as_me:-configure}:6881: testing ...checking LIBS $LIBS ..." 1>&5 |
| 6882 | |
| 6883 | cf_rpath_dst= |
| 6884 | for cf_rpath_src in $LIBS |
| 6885 | do |
| 6886 | case $cf_rpath_src in |
| 6887 | (-L*) |
| 6888 | |
| 6889 | # check if this refers to a directory which we will ignore |
| 6890 | cf_rpath_skip=no |
| 6891 | if test -n "$cf_rpath_list" |
| 6892 | then |
| 6893 | for cf_rpath_item in $cf_rpath_list |
| 6894 | do |
| 6895 | if test "x$cf_rpath_src" = "x-L$cf_rpath_item" |
| 6896 | then |
| 6897 | cf_rpath_skip=yes |
| 6898 | break |
| 6899 | fi |
| 6900 | done |
| 6901 | fi |
| 6902 | |
| 6903 | if test "$cf_rpath_skip" = no |
| 6904 | then |
| 6905 | # transform the option |
| 6906 | if test "$LD_RPATH_OPT" = "-R " ; then |
| 6907 | cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"` |
| 6908 | else |
| 6909 | cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"` |
| 6910 | fi |
| 6911 | |
| 6912 | # if we have not already added this, add it now |
| 6913 | cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"` |
| 6914 | if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS" |
| 6915 | then |
| 6916 | test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6 |
| 6917 | |
| 6918 | echo "${as_me:-configure}:6918: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5 |
| 6919 | |
| 6920 | EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS" |
| 6921 | fi |
| 6922 | fi |
| 6923 | ;; |
| 6924 | esac |
| 6925 | cf_rpath_dst="$cf_rpath_dst $cf_rpath_src" |
| 6926 | done |
| 6927 | LIBS=$cf_rpath_dst |
| 6928 | |
| 6929 | test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6 |
| 6930 | |
| 6931 | echo "${as_me:-configure}:6931: testing ...checked LIBS $LIBS ..." 1>&5 |
| 6932 | |
| 6933 | test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6 |
| 6934 | |
| 6935 | echo "${as_me:-configure}:6935: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5 |
| 6936 | |
| 6937 | else |
| 6938 | echo "$as_me:6938: result: no" >&5 |
| 6939 | echo "${ECHO_T}no" >&6 |
| 6940 | fi |
| 6941 | |
| 6942 | fi |
| 6943 | |
| 6944 | fi |
| 6945 | |
| 6946 | ############################################################################### |
| 6947 | |
| 6948 | ### use option --with-extra-suffix to append suffix to headers and libraries |
| 6949 | echo "$as_me:6949: checking if you wish to append extra suffix to header/library paths" >&5 |
| 6950 | echo $ECHO_N "checking if you wish to append extra suffix to header/library paths... $ECHO_C" >&6 |
| 6951 | EXTRA_SUFFIX= |
| 6952 | |
| 6953 | # Check whether --with-extra-suffix or --without-extra-suffix was given. |
| 6954 | if test "${with_extra_suffix+set}" = set; then |
| 6955 | withval="$with_extra_suffix" |
| 6956 | case x$withval in |
| 6957 | (no) |
| 6958 | ;; |
| 6959 | (xyes|x) |
| 6960 | EXTRA_SUFFIX=$cf_cv_abi_version |
| 6961 | ;; |
| 6962 | (*) |
| 6963 | EXTRA_SUFFIX=$withval |
| 6964 | ;; |
| 6965 | esac |
| 6966 | |
| 6967 | fi; |
| 6968 | echo "$as_me:6968: result: $EXTRA_SUFFIX" >&5 |
| 6969 | echo "${ECHO_T}$EXTRA_SUFFIX" >&6 |
| 6970 | |
| 6971 | ### use option --disable-overwrite to leave out the link to -lcurses |
| 6972 | echo "$as_me:6972: checking if you wish to install ncurses overwriting curses" >&5 |
| 6973 | echo $ECHO_N "checking if you wish to install ncurses overwriting curses... $ECHO_C" >&6 |
| 6974 | |
| 6975 | # Check whether --enable-overwrite or --disable-overwrite was given. |
| 6976 | if test "${enable_overwrite+set}" = set; then |
| 6977 | enableval="$enable_overwrite" |
| 6978 | with_overwrite=$enableval |
| 6979 | else |
| 6980 | if test "$prefix" = "/usr" ; then with_overwrite=yes; else with_overwrite=no; fi |
| 6981 | fi; |
| 6982 | echo "$as_me:6982: result: $with_overwrite" >&5 |
| 6983 | echo "${ECHO_T}$with_overwrite" >&6 |
| 6984 | |
| 6985 | echo "$as_me:6985: checking if external terminfo-database is used" >&5 |
| 6986 | echo $ECHO_N "checking if external terminfo-database is used... $ECHO_C" >&6 |
| 6987 | |
| 6988 | # Check whether --enable-database or --disable-database was given. |
| 6989 | if test "${enable_database+set}" = set; then |
| 6990 | enableval="$enable_database" |
| 6991 | use_database=$enableval |
| 6992 | else |
| 6993 | use_database=yes |
| 6994 | fi; |
| 6995 | echo "$as_me:6995: result: $use_database" >&5 |
| 6996 | echo "${ECHO_T}$use_database" >&6 |
| 6997 | |
| 6998 | case $host_os in |
| 6999 | (os2*) |
| 7000 | TERMINFO_SRC='${top_srcdir}/misc/emx.src' |
| 7001 | ;; |
| 7002 | (*) |
| 7003 | TERMINFO_SRC='${top_srcdir}/misc/terminfo.src' |
| 7004 | ;; |
| 7005 | esac |
| 7006 | |
| 7007 | NCURSES_USE_DATABASE=0 |
| 7008 | if test "$use_database" != no ; then |
| 7009 | NCURSES_USE_DATABASE=1 |
| 7010 | |
| 7011 | echo "$as_me:7011: checking which terminfo source-file will be installed" >&5 |
| 7012 | echo $ECHO_N "checking which terminfo source-file will be installed... $ECHO_C" >&6 |
| 7013 | |
| 7014 | # Check whether --with-database or --without-database was given. |
| 7015 | if test "${with_database+set}" = set; then |
| 7016 | withval="$with_database" |
| 7017 | TERMINFO_SRC=$withval |
| 7018 | fi; |
| 7019 | echo "$as_me:7019: result: $TERMINFO_SRC" >&5 |
| 7020 | echo "${ECHO_T}$TERMINFO_SRC" >&6 |
| 7021 | |
| 7022 | echo "$as_me:7022: checking whether to use hashed database instead of directory/tree" >&5 |
| 7023 | echo $ECHO_N "checking whether to use hashed database instead of directory/tree... $ECHO_C" >&6 |
| 7024 | |
| 7025 | # Check whether --with-hashed-db or --without-hashed-db was given. |
| 7026 | if test "${with_hashed_db+set}" = set; then |
| 7027 | withval="$with_hashed_db" |
| 7028 | |
| 7029 | else |
| 7030 | with_hashed_db=no |
| 7031 | fi; |
| 7032 | echo "$as_me:7032: result: $with_hashed_db" >&5 |
| 7033 | echo "${ECHO_T}$with_hashed_db" >&6 |
| 7034 | else |
| 7035 | with_hashed_db=no |
| 7036 | fi |
| 7037 | |
| 7038 | echo "$as_me:7038: checking for list of fallback descriptions" >&5 |
| 7039 | echo $ECHO_N "checking for list of fallback descriptions... $ECHO_C" >&6 |
| 7040 | |
| 7041 | # Check whether --with-fallbacks or --without-fallbacks was given. |
| 7042 | if test "${with_fallbacks+set}" = set; then |
| 7043 | withval="$with_fallbacks" |
| 7044 | with_fallback=$withval |
| 7045 | else |
| 7046 | with_fallback= |
| 7047 | fi; |
| 7048 | echo "$as_me:7048: result: $with_fallback" >&5 |
| 7049 | echo "${ECHO_T}$with_fallback" >&6 |
| 7050 | FALLBACK_LIST=`echo "$with_fallback" | sed -e 's/,/ /g'` |
| 7051 | |
| 7052 | echo "$as_me:7052: checking if you want modern xterm or antique" >&5 |
| 7053 | echo $ECHO_N "checking if you want modern xterm or antique... $ECHO_C" >&6 |
| 7054 | |
| 7055 | # Check whether --with-xterm-new or --without-xterm-new was given. |
| 7056 | if test "${with_xterm_new+set}" = set; then |
| 7057 | withval="$with_xterm_new" |
| 7058 | with_xterm_new=$withval |
| 7059 | else |
| 7060 | with_xterm_new=yes |
| 7061 | fi; |
| 7062 | case $with_xterm_new in |
| 7063 | (no) with_xterm_new=xterm-old;; |
| 7064 | (*) with_xterm_new=xterm-new;; |
| 7065 | esac |
| 7066 | echo "$as_me:7066: result: $with_xterm_new" >&5 |
| 7067 | echo "${ECHO_T}$with_xterm_new" >&6 |
| 7068 | WHICH_XTERM=$with_xterm_new |
| 7069 | |
| 7070 | echo "$as_me:7070: checking if xterm backspace sends BS or DEL" >&5 |
| 7071 | echo $ECHO_N "checking if xterm backspace sends BS or DEL... $ECHO_C" >&6 |
| 7072 | |
| 7073 | # Check whether --with-xterm-kbs or --without-xterm-kbs was given. |
| 7074 | if test "${with_xterm_kbs+set}" = set; then |
| 7075 | withval="$with_xterm_kbs" |
| 7076 | with_xterm_kbs=$withval |
| 7077 | else |
| 7078 | with_xterm_kbs=BS |
| 7079 | fi; |
| 7080 | case x$with_xterm_kbs in |
| 7081 | (xyes|xno|xBS|xbs|x8) |
| 7082 | with_xterm_kbs=BS |
| 7083 | ;; |
| 7084 | (xDEL|xdel|x127) |
| 7085 | with_xterm_kbs=DEL |
| 7086 | ;; |
| 7087 | (*) |
| 7088 | with_xterm_kbs=$withval |
| 7089 | ;; |
| 7090 | esac |
| 7091 | echo "$as_me:7091: result: $with_xterm_kbs" >&5 |
| 7092 | echo "${ECHO_T}$with_xterm_kbs" >&6 |
| 7093 | XTERM_KBS=$with_xterm_kbs |
| 7094 | |
| 7095 | MAKE_TERMINFO= |
| 7096 | if test "$use_database" = no ; then |
| 7097 | TERMINFO="${datadir}/terminfo" |
| 7098 | MAKE_TERMINFO="#" |
| 7099 | else |
| 7100 | |
| 7101 | echo "$as_me:7101: checking for list of terminfo directories" >&5 |
| 7102 | echo $ECHO_N "checking for list of terminfo directories... $ECHO_C" >&6 |
| 7103 | |
| 7104 | # Check whether --with-terminfo-dirs or --without-terminfo-dirs was given. |
| 7105 | if test "${with_terminfo_dirs+set}" = set; then |
| 7106 | withval="$with_terminfo_dirs" |
| 7107 | |
| 7108 | else |
| 7109 | withval=${TERMINFO_DIRS:-${datadir}/terminfo} |
| 7110 | fi; |
| 7111 | IFS="${IFS:- }"; ac_save_ifs="$IFS"; IFS="${PATH_SEPARATOR}" |
| 7112 | cf_dst_path= |
| 7113 | for cf_src_path in $withval |
| 7114 | do |
| 7115 | |
| 7116 | if test "x$prefix" != xNONE; then |
| 7117 | cf_path_syntax="$prefix" |
| 7118 | else |
| 7119 | cf_path_syntax="$ac_default_prefix" |
| 7120 | fi |
| 7121 | |
| 7122 | case ".$cf_src_path" in |
| 7123 | (.\$\(*\)*|.\'*\'*) |
| 7124 | ;; |
| 7125 | (..|./*|.\\*) |
| 7126 | ;; |
| 7127 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 7128 | ;; |
| 7129 | (.\${*prefix}*|.\${*dir}*) |
| 7130 | eval cf_src_path="$cf_src_path" |
| 7131 | case ".$cf_src_path" in |
| 7132 | (.NONE/*) |
| 7133 | cf_src_path=`echo $cf_src_path | sed -e s%NONE%$cf_path_syntax%` |
| 7134 | ;; |
| 7135 | esac |
| 7136 | ;; |
| 7137 | (.no|.NONE/*) |
| 7138 | cf_src_path=`echo $cf_src_path | sed -e s%NONE%$cf_path_syntax%` |
| 7139 | ;; |
| 7140 | (*) |
| 7141 | { { echo "$as_me:7141: error: expected a pathname, not \"$cf_src_path\"" >&5 |
| 7142 | echo "$as_me: error: expected a pathname, not \"$cf_src_path\"" >&2;} |
| 7143 | { (exit 1); exit 1; }; } |
| 7144 | ;; |
| 7145 | esac |
| 7146 | |
| 7147 | test -n "$cf_dst_path" && cf_dst_path="${cf_dst_path}$PATH_SEPARATOR" |
| 7148 | cf_dst_path="${cf_dst_path}${cf_src_path}" |
| 7149 | done |
| 7150 | IFS="$ac_save_ifs" |
| 7151 | |
| 7152 | # This may use the prefix/exec_prefix symbols which will only yield "NONE" |
| 7153 | # so we have to check/work around. We do prefer the result of "eval"... |
| 7154 | eval cf_dst_eval="$cf_dst_path" |
| 7155 | case "x$cf_dst_eval" in |
| 7156 | (xNONE*) |
| 7157 | TERMINFO_DIRS=$cf_dst_path |
| 7158 | ;; |
| 7159 | (*) |
| 7160 | TERMINFO_DIRS="$cf_dst_eval" |
| 7161 | ;; |
| 7162 | esac |
| 7163 | |
| 7164 | echo "$as_me:7164: result: $TERMINFO_DIRS" >&5 |
| 7165 | echo "${ECHO_T}$TERMINFO_DIRS" >&6 |
| 7166 | test -n "$TERMINFO_DIRS" && |
| 7167 | cat >>confdefs.h <<EOF |
| 7168 | #define TERMINFO_DIRS "$TERMINFO_DIRS" |
| 7169 | EOF |
| 7170 | |
| 7171 | echo "$as_me:7171: checking for default terminfo directory" >&5 |
| 7172 | echo $ECHO_N "checking for default terminfo directory... $ECHO_C" >&6 |
| 7173 | |
| 7174 | # Check whether --with-default-terminfo-dir or --without-default-terminfo-dir was given. |
| 7175 | if test "${with_default_terminfo_dir+set}" = set; then |
| 7176 | withval="$with_default_terminfo_dir" |
| 7177 | |
| 7178 | else |
| 7179 | withval="${TERMINFO:-${datadir}/terminfo}" |
| 7180 | fi; if test -n "${datadir}/terminfo" ; then |
| 7181 | |
| 7182 | if test "x$prefix" != xNONE; then |
| 7183 | cf_path_syntax="$prefix" |
| 7184 | else |
| 7185 | cf_path_syntax="$ac_default_prefix" |
| 7186 | fi |
| 7187 | |
| 7188 | case ".$withval" in |
| 7189 | (.\$\(*\)*|.\'*\'*) |
| 7190 | ;; |
| 7191 | (..|./*|.\\*) |
| 7192 | ;; |
| 7193 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 7194 | ;; |
| 7195 | (.\${*prefix}*|.\${*dir}*) |
| 7196 | eval withval="$withval" |
| 7197 | case ".$withval" in |
| 7198 | (.NONE/*) |
| 7199 | withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` |
| 7200 | ;; |
| 7201 | esac |
| 7202 | ;; |
| 7203 | (.no|.NONE/*) |
| 7204 | withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` |
| 7205 | ;; |
| 7206 | (*) |
| 7207 | { { echo "$as_me:7207: error: expected a pathname, not \"$withval\"" >&5 |
| 7208 | echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;} |
| 7209 | { (exit 1); exit 1; }; } |
| 7210 | ;; |
| 7211 | esac |
| 7212 | |
| 7213 | fi |
| 7214 | eval TERMINFO="$withval" |
| 7215 | |
| 7216 | echo "$as_me:7216: result: $TERMINFO" >&5 |
| 7217 | echo "${ECHO_T}$TERMINFO" >&6 |
| 7218 | |
| 7219 | cat >>confdefs.h <<EOF |
| 7220 | #define TERMINFO "$TERMINFO" |
| 7221 | EOF |
| 7222 | |
| 7223 | fi |
| 7224 | |
| 7225 | ### use option --disable-big-core to make tic run on small machines |
| 7226 | ### We need 4Mb, check if we can allocate 50% more than that. |
| 7227 | echo "$as_me:7227: checking if big-core option selected" >&5 |
| 7228 | echo $ECHO_N "checking if big-core option selected... $ECHO_C" >&6 |
| 7229 | |
| 7230 | # Check whether --enable-big-core or --disable-big-core was given. |
| 7231 | if test "${enable_big_core+set}" = set; then |
| 7232 | enableval="$enable_big_core" |
| 7233 | with_big_core=$enableval |
| 7234 | else |
| 7235 | if test "$cross_compiling" = yes; then |
| 7236 | with_big_core=no |
| 7237 | else |
| 7238 | cat >conftest.$ac_ext <<_ACEOF |
| 7239 | #line 7239 "configure" |
| 7240 | #include "confdefs.h" |
| 7241 | |
| 7242 | #include <stdlib.h> |
| 7243 | #include <string.h> |
| 7244 | int main() { |
| 7245 | unsigned long n = 6000000L; |
| 7246 | char *s = malloc(n); |
| 7247 | if (s != 0) |
| 7248 | s[0] = s[n-1] = 0; |
| 7249 | ${cf_cv_main_return:-return}(s == 0); |
| 7250 | } |
| 7251 | _ACEOF |
| 7252 | rm -f conftest$ac_exeext |
| 7253 | if { (eval echo "$as_me:7253: \"$ac_link\"") >&5 |
| 7254 | (eval $ac_link) 2>&5 |
| 7255 | ac_status=$? |
| 7256 | echo "$as_me:7256: \$? = $ac_status" >&5 |
| 7257 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 7258 | { (eval echo "$as_me:7258: \"$ac_try\"") >&5 |
| 7259 | (eval $ac_try) 2>&5 |
| 7260 | ac_status=$? |
| 7261 | echo "$as_me:7261: \$? = $ac_status" >&5 |
| 7262 | (exit $ac_status); }; }; then |
| 7263 | with_big_core=yes |
| 7264 | else |
| 7265 | echo "$as_me: program exited with status $ac_status" >&5 |
| 7266 | echo "$as_me: failed program was:" >&5 |
| 7267 | cat conftest.$ac_ext >&5 |
| 7268 | with_big_core=no |
| 7269 | fi |
| 7270 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 7271 | fi |
| 7272 | fi; |
| 7273 | echo "$as_me:7273: result: $with_big_core" >&5 |
| 7274 | echo "${ECHO_T}$with_big_core" >&6 |
| 7275 | test "x$with_big_core" = "xyes" && |
| 7276 | cat >>confdefs.h <<\EOF |
| 7277 | #define HAVE_BIG_CORE 1 |
| 7278 | EOF |
| 7279 | |
| 7280 | ### ISO C only guarantees 512-char strings, we have tables which load faster |
| 7281 | ### when constructed using "big" strings. More than the C compiler, the awk |
| 7282 | ### program is a limit on most vendor UNIX systems. Check that we can build. |
| 7283 | echo "$as_me:7283: checking if big-strings option selected" >&5 |
| 7284 | echo $ECHO_N "checking if big-strings option selected... $ECHO_C" >&6 |
| 7285 | |
| 7286 | # Check whether --enable-big-strings or --disable-big-strings was given. |
| 7287 | if test "${enable_big_strings+set}" = set; then |
| 7288 | enableval="$enable_big_strings" |
| 7289 | with_big_strings=$enableval |
| 7290 | else |
| 7291 | |
| 7292 | case x$AWK in |
| 7293 | (x) |
| 7294 | eval with_big_strings=no |
| 7295 | ;; |
| 7296 | (*) |
| 7297 | if ( ${AWK} 'BEGIN { xx = "x"; while (length(xx) < 12000) { xx = xx "x"; }; printf("%s\n", xx); }' 2>/dev/null \ |
| 7298 | | $AWK '{ printf "%d\n", length($0); }' 2>/dev/null | $AWK 'BEGIN { eqls=0; recs=0; } { recs++; if ($0 == 12000) eqls++; } END { if (recs != 1 || eqls != 1) exit 1; }' 2>/dev/null >/dev/null ) ; then |
| 7299 | eval with_big_strings=yes |
| 7300 | else |
| 7301 | eval with_big_strings=no |
| 7302 | fi |
| 7303 | ;; |
| 7304 | esac |
| 7305 | |
| 7306 | fi; |
| 7307 | echo "$as_me:7307: result: $with_big_strings" >&5 |
| 7308 | echo "${ECHO_T}$with_big_strings" >&6 |
| 7309 | |
| 7310 | USE_BIG_STRINGS=0 |
| 7311 | test "x$with_big_strings" = "xyes" && USE_BIG_STRINGS=1 |
| 7312 | |
| 7313 | ### use option --enable-termcap to compile in the termcap fallback support |
| 7314 | echo "$as_me:7314: checking if you want termcap-fallback support" >&5 |
| 7315 | echo $ECHO_N "checking if you want termcap-fallback support... $ECHO_C" >&6 |
| 7316 | |
| 7317 | # Check whether --enable-termcap or --disable-termcap was given. |
| 7318 | if test "${enable_termcap+set}" = set; then |
| 7319 | enableval="$enable_termcap" |
| 7320 | with_termcap=$enableval |
| 7321 | else |
| 7322 | with_termcap=no |
| 7323 | fi; |
| 7324 | echo "$as_me:7324: result: $with_termcap" >&5 |
| 7325 | echo "${ECHO_T}$with_termcap" >&6 |
| 7326 | |
| 7327 | NCURSES_USE_TERMCAP=0 |
| 7328 | if test "x$with_termcap" != "xyes" ; then |
| 7329 | if test "$use_database" = no ; then |
| 7330 | if test -z "$with_fallback" ; then |
| 7331 | { { echo "$as_me:7331: error: You have disabled the database w/o specifying fallbacks" >&5 |
| 7332 | echo "$as_me: error: You have disabled the database w/o specifying fallbacks" >&2;} |
| 7333 | { (exit 1); exit 1; }; } |
| 7334 | fi |
| 7335 | fi |
| 7336 | |
| 7337 | cat >>confdefs.h <<\EOF |
| 7338 | #define PURE_TERMINFO 1 |
| 7339 | EOF |
| 7340 | |
| 7341 | else |
| 7342 | |
| 7343 | if test "$with_ticlib" != no ; then |
| 7344 | { { echo "$as_me:7344: error: Options --with-ticlib and --enable-termcap cannot be combined" >&5 |
| 7345 | echo "$as_me: error: Options --with-ticlib and --enable-termcap cannot be combined" >&2;} |
| 7346 | { (exit 1); exit 1; }; } |
| 7347 | fi |
| 7348 | |
| 7349 | NCURSES_USE_TERMCAP=1 |
| 7350 | echo "$as_me:7350: checking for list of termcap files" >&5 |
| 7351 | echo $ECHO_N "checking for list of termcap files... $ECHO_C" >&6 |
| 7352 | |
| 7353 | # Check whether --with-termpath or --without-termpath was given. |
| 7354 | if test "${with_termpath+set}" = set; then |
| 7355 | withval="$with_termpath" |
| 7356 | |
| 7357 | else |
| 7358 | withval=${TERMPATH:-/etc/termcap:/usr/share/misc/termcap} |
| 7359 | fi; |
| 7360 | IFS="${IFS:- }"; ac_save_ifs="$IFS"; IFS="${PATH_SEPARATOR}" |
| 7361 | cf_dst_path= |
| 7362 | for cf_src_path in $withval |
| 7363 | do |
| 7364 | |
| 7365 | if test "x$prefix" != xNONE; then |
| 7366 | cf_path_syntax="$prefix" |
| 7367 | else |
| 7368 | cf_path_syntax="$ac_default_prefix" |
| 7369 | fi |
| 7370 | |
| 7371 | case ".$cf_src_path" in |
| 7372 | (.\$\(*\)*|.\'*\'*) |
| 7373 | ;; |
| 7374 | (..|./*|.\\*) |
| 7375 | ;; |
| 7376 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 7377 | ;; |
| 7378 | (.\${*prefix}*|.\${*dir}*) |
| 7379 | eval cf_src_path="$cf_src_path" |
| 7380 | case ".$cf_src_path" in |
| 7381 | (.NONE/*) |
| 7382 | cf_src_path=`echo $cf_src_path | sed -e s%NONE%$cf_path_syntax%` |
| 7383 | ;; |
| 7384 | esac |
| 7385 | ;; |
| 7386 | (.no|.NONE/*) |
| 7387 | cf_src_path=`echo $cf_src_path | sed -e s%NONE%$cf_path_syntax%` |
| 7388 | ;; |
| 7389 | (*) |
| 7390 | { { echo "$as_me:7390: error: expected a pathname, not \"$cf_src_path\"" >&5 |
| 7391 | echo "$as_me: error: expected a pathname, not \"$cf_src_path\"" >&2;} |
| 7392 | { (exit 1); exit 1; }; } |
| 7393 | ;; |
| 7394 | esac |
| 7395 | |
| 7396 | test -n "$cf_dst_path" && cf_dst_path="${cf_dst_path}$PATH_SEPARATOR" |
| 7397 | cf_dst_path="${cf_dst_path}${cf_src_path}" |
| 7398 | done |
| 7399 | IFS="$ac_save_ifs" |
| 7400 | |
| 7401 | # This may use the prefix/exec_prefix symbols which will only yield "NONE" |
| 7402 | # so we have to check/work around. We do prefer the result of "eval"... |
| 7403 | eval cf_dst_eval="$cf_dst_path" |
| 7404 | case "x$cf_dst_eval" in |
| 7405 | (xNONE*) |
| 7406 | TERMPATH=$cf_dst_path |
| 7407 | ;; |
| 7408 | (*) |
| 7409 | TERMPATH="$cf_dst_eval" |
| 7410 | ;; |
| 7411 | esac |
| 7412 | |
| 7413 | echo "$as_me:7413: result: $TERMPATH" >&5 |
| 7414 | echo "${ECHO_T}$TERMPATH" >&6 |
| 7415 | test -n "$TERMPATH" && |
| 7416 | cat >>confdefs.h <<EOF |
| 7417 | #define TERMPATH "$TERMPATH" |
| 7418 | EOF |
| 7419 | |
| 7420 | ### use option --enable-getcap to use a hacked getcap for reading termcaps |
| 7421 | echo "$as_me:7421: checking if fast termcap-loader is needed" >&5 |
| 7422 | echo $ECHO_N "checking if fast termcap-loader is needed... $ECHO_C" >&6 |
| 7423 | |
| 7424 | # Check whether --enable-getcap or --disable-getcap was given. |
| 7425 | if test "${enable_getcap+set}" = set; then |
| 7426 | enableval="$enable_getcap" |
| 7427 | with_getcap=$enableval |
| 7428 | else |
| 7429 | with_getcap=no |
| 7430 | fi; |
| 7431 | echo "$as_me:7431: result: $with_getcap" >&5 |
| 7432 | echo "${ECHO_T}$with_getcap" >&6 |
| 7433 | test "x$with_getcap" = "xyes" && |
| 7434 | cat >>confdefs.h <<\EOF |
| 7435 | #define USE_GETCAP 1 |
| 7436 | EOF |
| 7437 | |
| 7438 | echo "$as_me:7438: checking if translated termcaps will be cached in ~/.terminfo" >&5 |
| 7439 | echo $ECHO_N "checking if translated termcaps will be cached in ~/.terminfo... $ECHO_C" >&6 |
| 7440 | |
| 7441 | # Check whether --enable-getcap-cache or --disable-getcap-cache was given. |
| 7442 | if test "${enable_getcap_cache+set}" = set; then |
| 7443 | enableval="$enable_getcap_cache" |
| 7444 | with_getcap_cache=$enableval |
| 7445 | else |
| 7446 | with_getcap_cache=no |
| 7447 | fi; |
| 7448 | echo "$as_me:7448: result: $with_getcap_cache" >&5 |
| 7449 | echo "${ECHO_T}$with_getcap_cache" >&6 |
| 7450 | test "x$with_getcap_cache" = "xyes" && |
| 7451 | cat >>confdefs.h <<\EOF |
| 7452 | #define USE_GETCAP_CACHE 1 |
| 7453 | EOF |
| 7454 | |
| 7455 | fi |
| 7456 | |
| 7457 | ### Use option --disable-home-terminfo to completely remove ~/.terminfo |
| 7458 | echo "$as_me:7458: checking if ~/.terminfo is wanted" >&5 |
| 7459 | echo $ECHO_N "checking if ~/.terminfo is wanted... $ECHO_C" >&6 |
| 7460 | |
| 7461 | # Check whether --enable-home-terminfo or --disable-home-terminfo was given. |
| 7462 | if test "${enable_home_terminfo+set}" = set; then |
| 7463 | enableval="$enable_home_terminfo" |
| 7464 | with_home_terminfo=$enableval |
| 7465 | else |
| 7466 | with_home_terminfo=yes |
| 7467 | fi; |
| 7468 | echo "$as_me:7468: result: $with_home_terminfo" >&5 |
| 7469 | echo "${ECHO_T}$with_home_terminfo" >&6 |
| 7470 | test "x$with_home_terminfo" = "xyes" && |
| 7471 | cat >>confdefs.h <<\EOF |
| 7472 | #define USE_HOME_TERMINFO 1 |
| 7473 | EOF |
| 7474 | |
| 7475 | echo "$as_me:7475: checking if you want to use restricted environment when running as root" >&5 |
| 7476 | echo $ECHO_N "checking if you want to use restricted environment when running as root... $ECHO_C" >&6 |
| 7477 | |
| 7478 | # Check whether --enable-root-environ or --disable-root-environ was given. |
| 7479 | if test "${enable_root_environ+set}" = set; then |
| 7480 | enableval="$enable_root_environ" |
| 7481 | with_root_environ=$enableval |
| 7482 | else |
| 7483 | with_root_environ=yes |
| 7484 | fi; |
| 7485 | echo "$as_me:7485: result: $with_root_environ" >&5 |
| 7486 | echo "${ECHO_T}$with_root_environ" >&6 |
| 7487 | test "x$with_root_environ" = xyes && |
| 7488 | cat >>confdefs.h <<\EOF |
| 7489 | #define USE_ROOT_ENVIRON 1 |
| 7490 | EOF |
| 7491 | |
| 7492 | ### Use option --enable-symlinks to make tic use symlinks, not hard links |
| 7493 | ### to reduce storage requirements for the terminfo database. |
| 7494 | |
| 7495 | for ac_func in \ |
| 7496 | remove \ |
| 7497 | unlink |
| 7498 | do |
| 7499 | as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 7500 | echo "$as_me:7500: checking for $ac_func" >&5 |
| 7501 | echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 |
| 7502 | if eval "test \"\${$as_ac_var+set}\" = set"; then |
| 7503 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7504 | else |
| 7505 | cat >conftest.$ac_ext <<_ACEOF |
| 7506 | #line 7506 "configure" |
| 7507 | #include "confdefs.h" |
| 7508 | /* System header to define __stub macros and hopefully few prototypes, |
| 7509 | which can conflict with char $ac_func (); below. */ |
| 7510 | #include <assert.h> |
| 7511 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 7512 | #ifdef __cplusplus |
| 7513 | extern "C" |
| 7514 | #endif |
| 7515 | /* We use char because int might match the return type of a gcc2 |
| 7516 | builtin and then its argument prototype would still apply. */ |
| 7517 | char $ac_func (); |
| 7518 | char (*f) (); |
| 7519 | |
| 7520 | int |
| 7521 | main () |
| 7522 | { |
| 7523 | /* The GNU C library defines this for functions which it implements |
| 7524 | to always fail with ENOSYS. Some functions are actually named |
| 7525 | something starting with __ and the normal name is an alias. */ |
| 7526 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 7527 | choke me |
| 7528 | #else |
| 7529 | f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 7530 | #endif |
| 7531 | |
| 7532 | ; |
| 7533 | return 0; |
| 7534 | } |
| 7535 | _ACEOF |
| 7536 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7537 | if { (eval echo "$as_me:7537: \"$ac_link\"") >&5 |
| 7538 | (eval $ac_link) 2>&5 |
| 7539 | ac_status=$? |
| 7540 | echo "$as_me:7540: \$? = $ac_status" >&5 |
| 7541 | (exit $ac_status); } && |
| 7542 | { ac_try='test -s conftest$ac_exeext' |
| 7543 | { (eval echo "$as_me:7543: \"$ac_try\"") >&5 |
| 7544 | (eval $ac_try) 2>&5 |
| 7545 | ac_status=$? |
| 7546 | echo "$as_me:7546: \$? = $ac_status" >&5 |
| 7547 | (exit $ac_status); }; }; then |
| 7548 | eval "$as_ac_var=yes" |
| 7549 | else |
| 7550 | echo "$as_me: failed program was:" >&5 |
| 7551 | cat conftest.$ac_ext >&5 |
| 7552 | eval "$as_ac_var=no" |
| 7553 | fi |
| 7554 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7555 | fi |
| 7556 | echo "$as_me:7556: result: `eval echo '${'$as_ac_var'}'`" >&5 |
| 7557 | echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 |
| 7558 | if test `eval echo '${'$as_ac_var'}'` = yes; then |
| 7559 | cat >>confdefs.h <<EOF |
| 7560 | #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 7561 | EOF |
| 7562 | |
| 7563 | fi |
| 7564 | done |
| 7565 | |
| 7566 | if test "$cross_compiling" = yes ; then |
| 7567 | |
| 7568 | for ac_func in \ |
| 7569 | link \ |
| 7570 | symlink |
| 7571 | do |
| 7572 | as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 7573 | echo "$as_me:7573: checking for $ac_func" >&5 |
| 7574 | echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 |
| 7575 | if eval "test \"\${$as_ac_var+set}\" = set"; then |
| 7576 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7577 | else |
| 7578 | cat >conftest.$ac_ext <<_ACEOF |
| 7579 | #line 7579 "configure" |
| 7580 | #include "confdefs.h" |
| 7581 | /* System header to define __stub macros and hopefully few prototypes, |
| 7582 | which can conflict with char $ac_func (); below. */ |
| 7583 | #include <assert.h> |
| 7584 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 7585 | #ifdef __cplusplus |
| 7586 | extern "C" |
| 7587 | #endif |
| 7588 | /* We use char because int might match the return type of a gcc2 |
| 7589 | builtin and then its argument prototype would still apply. */ |
| 7590 | char $ac_func (); |
| 7591 | char (*f) (); |
| 7592 | |
| 7593 | int |
| 7594 | main () |
| 7595 | { |
| 7596 | /* The GNU C library defines this for functions which it implements |
| 7597 | to always fail with ENOSYS. Some functions are actually named |
| 7598 | something starting with __ and the normal name is an alias. */ |
| 7599 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 7600 | choke me |
| 7601 | #else |
| 7602 | f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 7603 | #endif |
| 7604 | |
| 7605 | ; |
| 7606 | return 0; |
| 7607 | } |
| 7608 | _ACEOF |
| 7609 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 7610 | if { (eval echo "$as_me:7610: \"$ac_link\"") >&5 |
| 7611 | (eval $ac_link) 2>&5 |
| 7612 | ac_status=$? |
| 7613 | echo "$as_me:7613: \$? = $ac_status" >&5 |
| 7614 | (exit $ac_status); } && |
| 7615 | { ac_try='test -s conftest$ac_exeext' |
| 7616 | { (eval echo "$as_me:7616: \"$ac_try\"") >&5 |
| 7617 | (eval $ac_try) 2>&5 |
| 7618 | ac_status=$? |
| 7619 | echo "$as_me:7619: \$? = $ac_status" >&5 |
| 7620 | (exit $ac_status); }; }; then |
| 7621 | eval "$as_ac_var=yes" |
| 7622 | else |
| 7623 | echo "$as_me: failed program was:" >&5 |
| 7624 | cat conftest.$ac_ext >&5 |
| 7625 | eval "$as_ac_var=no" |
| 7626 | fi |
| 7627 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 7628 | fi |
| 7629 | echo "$as_me:7629: result: `eval echo '${'$as_ac_var'}'`" >&5 |
| 7630 | echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 |
| 7631 | if test `eval echo '${'$as_ac_var'}'` = yes; then |
| 7632 | cat >>confdefs.h <<EOF |
| 7633 | #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 7634 | EOF |
| 7635 | |
| 7636 | fi |
| 7637 | done |
| 7638 | |
| 7639 | else |
| 7640 | echo "$as_me:7640: checking if link/symlink functions work" >&5 |
| 7641 | echo $ECHO_N "checking if link/symlink functions work... $ECHO_C" >&6 |
| 7642 | if test "${cf_cv_link_funcs+set}" = set; then |
| 7643 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7644 | else |
| 7645 | |
| 7646 | cf_cv_link_funcs= |
| 7647 | for cf_func in link symlink ; do |
| 7648 | if test "$cross_compiling" = yes; then |
| 7649 | |
| 7650 | eval 'ac_cv_func_'$cf_func'=error' |
| 7651 | else |
| 7652 | cat >conftest.$ac_ext <<_ACEOF |
| 7653 | #line 7653 "configure" |
| 7654 | #include "confdefs.h" |
| 7655 | |
| 7656 | #include <sys/types.h> |
| 7657 | #include <sys/stat.h> |
| 7658 | #ifdef HAVE_UNISTD_H |
| 7659 | #include <unistd.h> |
| 7660 | #endif |
| 7661 | int main() |
| 7662 | { |
| 7663 | int fail = 0; |
| 7664 | char *src = "config.log"; |
| 7665 | char *dst = "conftest.chk"; |
| 7666 | struct stat src_sb; |
| 7667 | struct stat dst_sb; |
| 7668 | |
| 7669 | stat(src, &src_sb); |
| 7670 | fail = ($cf_func("config.log", "conftest.chk") < 0) |
| 7671 | || (stat(dst, &dst_sb) < 0) |
| 7672 | || (dst_sb.st_mtime != src_sb.st_mtime); |
| 7673 | #ifdef HAVE_UNLINK |
| 7674 | unlink(dst); |
| 7675 | #else |
| 7676 | remove(dst); |
| 7677 | #endif |
| 7678 | ${cf_cv_main_return:-return} (fail); |
| 7679 | } |
| 7680 | |
| 7681 | _ACEOF |
| 7682 | rm -f conftest$ac_exeext |
| 7683 | if { (eval echo "$as_me:7683: \"$ac_link\"") >&5 |
| 7684 | (eval $ac_link) 2>&5 |
| 7685 | ac_status=$? |
| 7686 | echo "$as_me:7686: \$? = $ac_status" >&5 |
| 7687 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 7688 | { (eval echo "$as_me:7688: \"$ac_try\"") >&5 |
| 7689 | (eval $ac_try) 2>&5 |
| 7690 | ac_status=$? |
| 7691 | echo "$as_me:7691: \$? = $ac_status" >&5 |
| 7692 | (exit $ac_status); }; }; then |
| 7693 | |
| 7694 | cf_cv_link_funcs="$cf_cv_link_funcs $cf_func" |
| 7695 | eval 'ac_cv_func_'$cf_func'=yes' |
| 7696 | else |
| 7697 | echo "$as_me: program exited with status $ac_status" >&5 |
| 7698 | echo "$as_me: failed program was:" >&5 |
| 7699 | cat conftest.$ac_ext >&5 |
| 7700 | |
| 7701 | eval 'ac_cv_func_'$cf_func'=no' |
| 7702 | fi |
| 7703 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 7704 | fi |
| 7705 | done |
| 7706 | test -z "$cf_cv_link_funcs" && cf_cv_link_funcs=no |
| 7707 | |
| 7708 | fi |
| 7709 | echo "$as_me:7709: result: $cf_cv_link_funcs" >&5 |
| 7710 | echo "${ECHO_T}$cf_cv_link_funcs" >&6 |
| 7711 | test "$ac_cv_func_link" = yes && |
| 7712 | cat >>confdefs.h <<\EOF |
| 7713 | #define HAVE_LINK 1 |
| 7714 | EOF |
| 7715 | |
| 7716 | test "$ac_cv_func_symlink" = yes && |
| 7717 | cat >>confdefs.h <<\EOF |
| 7718 | #define HAVE_SYMLINK 1 |
| 7719 | EOF |
| 7720 | |
| 7721 | fi |
| 7722 | |
| 7723 | with_links=no |
| 7724 | with_symlinks=no |
| 7725 | |
| 7726 | # soft links (symbolic links) are useful for some systems where hard links do |
| 7727 | # not work, or to make it simpler to copy terminfo trees around. |
| 7728 | if test "x$ac_cv_func_symlink" = xyes ; then |
| 7729 | echo "$as_me:7729: checking if tic should use symbolic links" >&5 |
| 7730 | echo $ECHO_N "checking if tic should use symbolic links... $ECHO_C" >&6 |
| 7731 | |
| 7732 | # Check whether --enable-symlinks or --disable-symlinks was given. |
| 7733 | if test "${enable_symlinks+set}" = set; then |
| 7734 | enableval="$enable_symlinks" |
| 7735 | with_symlinks=$enableval |
| 7736 | else |
| 7737 | with_symlinks=no |
| 7738 | fi; |
| 7739 | echo "$as_me:7739: result: $with_symlinks" >&5 |
| 7740 | echo "${ECHO_T}$with_symlinks" >&6 |
| 7741 | fi |
| 7742 | |
| 7743 | # If we have hard links and did not choose to use soft links instead, there is |
| 7744 | # no reason to make this choice optional - use the hard links. |
| 7745 | if test "$with_symlinks" = no ; then |
| 7746 | echo "$as_me:7746: checking if tic should use hard links" >&5 |
| 7747 | echo $ECHO_N "checking if tic should use hard links... $ECHO_C" >&6 |
| 7748 | if test "x$ac_cv_func_link" = xyes ; then |
| 7749 | with_links=yes |
| 7750 | else |
| 7751 | with_links=no |
| 7752 | fi |
| 7753 | echo "$as_me:7753: result: $with_links" >&5 |
| 7754 | echo "${ECHO_T}$with_links" >&6 |
| 7755 | fi |
| 7756 | |
| 7757 | test "x$with_links" = xyes && |
| 7758 | cat >>confdefs.h <<\EOF |
| 7759 | #define USE_LINKS 1 |
| 7760 | EOF |
| 7761 | |
| 7762 | test "x$with_symlinks" = xyes && |
| 7763 | cat >>confdefs.h <<\EOF |
| 7764 | #define USE_SYMLINKS 1 |
| 7765 | EOF |
| 7766 | |
| 7767 | ### use option --enable-broken-linker to force on use of broken-linker support |
| 7768 | echo "$as_me:7768: checking if you want broken-linker support code" >&5 |
| 7769 | echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6 |
| 7770 | |
| 7771 | # Check whether --enable-broken_linker or --disable-broken_linker was given. |
| 7772 | if test "${enable_broken_linker+set}" = set; then |
| 7773 | enableval="$enable_broken_linker" |
| 7774 | with_broken_linker=$enableval |
| 7775 | else |
| 7776 | with_broken_linker=${BROKEN_LINKER:-no} |
| 7777 | fi; |
| 7778 | echo "$as_me:7778: result: $with_broken_linker" >&5 |
| 7779 | echo "${ECHO_T}$with_broken_linker" >&6 |
| 7780 | |
| 7781 | BROKEN_LINKER=0 |
| 7782 | if test "x$with_broken_linker" = xyes ; then |
| 7783 | |
| 7784 | cat >>confdefs.h <<\EOF |
| 7785 | #define BROKEN_LINKER 1 |
| 7786 | EOF |
| 7787 | |
| 7788 | BROKEN_LINKER=1 |
| 7789 | elif test "$DFT_LWR_MODEL" = shared ; then |
| 7790 | case $cf_cv_system_name in |
| 7791 | (cygwin*) |
| 7792 | |
| 7793 | cat >>confdefs.h <<\EOF |
| 7794 | #define BROKEN_LINKER 1 |
| 7795 | EOF |
| 7796 | |
| 7797 | BROKEN_LINKER=1 |
| 7798 | test -n "$verbose" && echo " cygwin linker is broken anyway" 1>&6 |
| 7799 | |
| 7800 | echo "${as_me:-configure}:7800: testing cygwin linker is broken anyway ..." 1>&5 |
| 7801 | |
| 7802 | ;; |
| 7803 | esac |
| 7804 | fi |
| 7805 | |
| 7806 | ### use option --enable-bsdpad to have tputs process BSD-style prefix padding |
| 7807 | echo "$as_me:7807: checking if tputs should process BSD-style prefix padding" >&5 |
| 7808 | echo $ECHO_N "checking if tputs should process BSD-style prefix padding... $ECHO_C" >&6 |
| 7809 | |
| 7810 | # Check whether --enable-bsdpad or --disable-bsdpad was given. |
| 7811 | if test "${enable_bsdpad+set}" = set; then |
| 7812 | enableval="$enable_bsdpad" |
| 7813 | with_bsdpad=$enableval |
| 7814 | else |
| 7815 | with_bsdpad=no |
| 7816 | fi; |
| 7817 | echo "$as_me:7817: result: $with_bsdpad" >&5 |
| 7818 | echo "${ECHO_T}$with_bsdpad" >&6 |
| 7819 | test "x$with_bsdpad" = xyes && |
| 7820 | cat >>confdefs.h <<\EOF |
| 7821 | #define BSD_TPUTS 1 |
| 7822 | EOF |
| 7823 | |
| 7824 | ### use option --enable-widec to turn on use of wide-character support |
| 7825 | NCURSES_CH_T=chtype |
| 7826 | NCURSES_LIBUTF8=0 |
| 7827 | |
| 7828 | NEED_WCHAR_H=0 |
| 7829 | NCURSES_MBSTATE_T=0 |
| 7830 | NCURSES_WCHAR_T=0 |
| 7831 | NCURSES_WINT_T=0 |
| 7832 | |
| 7833 | # Check to define _XOPEN_SOURCE "automatically" |
| 7834 | CPPFLAGS_before_XOPEN="$CPPFLAGS" |
| 7835 | |
| 7836 | cf_XOPEN_SOURCE=500 |
| 7837 | cf_POSIX_C_SOURCE=199506L |
| 7838 | cf_xopen_source= |
| 7839 | |
| 7840 | case $host_os in |
| 7841 | (aix[4-7]*) |
| 7842 | cf_xopen_source="-D_ALL_SOURCE" |
| 7843 | ;; |
| 7844 | (cygwin|msys) |
| 7845 | cf_XOPEN_SOURCE=600 |
| 7846 | ;; |
| 7847 | (darwin[0-8].*) |
| 7848 | cf_xopen_source="-D_APPLE_C_SOURCE" |
| 7849 | ;; |
| 7850 | (darwin*) |
| 7851 | cf_xopen_source="-D_DARWIN_C_SOURCE" |
| 7852 | cf_XOPEN_SOURCE= |
| 7853 | ;; |
| 7854 | (freebsd*|dragonfly*) |
| 7855 | # 5.x headers associate |
| 7856 | # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L |
| 7857 | # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L |
| 7858 | cf_POSIX_C_SOURCE=200112L |
| 7859 | cf_XOPEN_SOURCE=600 |
| 7860 | cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" |
| 7861 | ;; |
| 7862 | (hpux11*) |
| 7863 | cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500" |
| 7864 | ;; |
| 7865 | (hpux*) |
| 7866 | cf_xopen_source="-D_HPUX_SOURCE" |
| 7867 | ;; |
| 7868 | (irix[56].*) |
| 7869 | cf_xopen_source="-D_SGI_SOURCE" |
| 7870 | cf_XOPEN_SOURCE= |
| 7871 | ;; |
| 7872 | (linux*|gnu*|mint*|k*bsd*-gnu) |
| 7873 | |
| 7874 | echo "$as_me:7874: checking if we must define _GNU_SOURCE" >&5 |
| 7875 | echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6 |
| 7876 | if test "${cf_cv_gnu_source+set}" = set; then |
| 7877 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7878 | else |
| 7879 | |
| 7880 | cat >conftest.$ac_ext <<_ACEOF |
| 7881 | #line 7881 "configure" |
| 7882 | #include "confdefs.h" |
| 7883 | #include <sys/types.h> |
| 7884 | int |
| 7885 | main () |
| 7886 | { |
| 7887 | |
| 7888 | #ifndef _XOPEN_SOURCE |
| 7889 | make an error |
| 7890 | #endif |
| 7891 | ; |
| 7892 | return 0; |
| 7893 | } |
| 7894 | _ACEOF |
| 7895 | rm -f conftest.$ac_objext |
| 7896 | if { (eval echo "$as_me:7896: \"$ac_compile\"") >&5 |
| 7897 | (eval $ac_compile) 2>&5 |
| 7898 | ac_status=$? |
| 7899 | echo "$as_me:7899: \$? = $ac_status" >&5 |
| 7900 | (exit $ac_status); } && |
| 7901 | { ac_try='test -s conftest.$ac_objext' |
| 7902 | { (eval echo "$as_me:7902: \"$ac_try\"") >&5 |
| 7903 | (eval $ac_try) 2>&5 |
| 7904 | ac_status=$? |
| 7905 | echo "$as_me:7905: \$? = $ac_status" >&5 |
| 7906 | (exit $ac_status); }; }; then |
| 7907 | cf_cv_gnu_source=no |
| 7908 | else |
| 7909 | echo "$as_me: failed program was:" >&5 |
| 7910 | cat conftest.$ac_ext >&5 |
| 7911 | cf_save="$CPPFLAGS" |
| 7912 | CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" |
| 7913 | cat >conftest.$ac_ext <<_ACEOF |
| 7914 | #line 7914 "configure" |
| 7915 | #include "confdefs.h" |
| 7916 | #include <sys/types.h> |
| 7917 | int |
| 7918 | main () |
| 7919 | { |
| 7920 | |
| 7921 | #ifdef _XOPEN_SOURCE |
| 7922 | make an error |
| 7923 | #endif |
| 7924 | ; |
| 7925 | return 0; |
| 7926 | } |
| 7927 | _ACEOF |
| 7928 | rm -f conftest.$ac_objext |
| 7929 | if { (eval echo "$as_me:7929: \"$ac_compile\"") >&5 |
| 7930 | (eval $ac_compile) 2>&5 |
| 7931 | ac_status=$? |
| 7932 | echo "$as_me:7932: \$? = $ac_status" >&5 |
| 7933 | (exit $ac_status); } && |
| 7934 | { ac_try='test -s conftest.$ac_objext' |
| 7935 | { (eval echo "$as_me:7935: \"$ac_try\"") >&5 |
| 7936 | (eval $ac_try) 2>&5 |
| 7937 | ac_status=$? |
| 7938 | echo "$as_me:7938: \$? = $ac_status" >&5 |
| 7939 | (exit $ac_status); }; }; then |
| 7940 | cf_cv_gnu_source=no |
| 7941 | else |
| 7942 | echo "$as_me: failed program was:" >&5 |
| 7943 | cat conftest.$ac_ext >&5 |
| 7944 | cf_cv_gnu_source=yes |
| 7945 | fi |
| 7946 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 7947 | CPPFLAGS="$cf_save" |
| 7948 | |
| 7949 | fi |
| 7950 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 7951 | |
| 7952 | fi |
| 7953 | echo "$as_me:7953: result: $cf_cv_gnu_source" >&5 |
| 7954 | echo "${ECHO_T}$cf_cv_gnu_source" >&6 |
| 7955 | test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" |
| 7956 | |
| 7957 | ;; |
| 7958 | (minix*) |
| 7959 | cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this... |
| 7960 | ;; |
| 7961 | (mirbsd*) |
| 7962 | # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types |
| 7963 | cf_XOPEN_SOURCE= |
| 7964 | |
| 7965 | cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE |
| 7966 | |
| 7967 | cf_save_CFLAGS="$CFLAGS" |
| 7968 | cf_save_CPPFLAGS="$CPPFLAGS" |
| 7969 | |
| 7970 | cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \ |
| 7971 | sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 7972 | -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 7973 | |
| 7974 | cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \ |
| 7975 | sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 7976 | -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 7977 | |
| 7978 | echo "$as_me:7978: checking if we should define _POSIX_C_SOURCE" >&5 |
| 7979 | echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6 |
| 7980 | if test "${cf_cv_posix_c_source+set}" = set; then |
| 7981 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 7982 | else |
| 7983 | |
| 7984 | echo "${as_me:-configure}:7984: testing if the symbol is already defined go no further ..." 1>&5 |
| 7985 | |
| 7986 | cat >conftest.$ac_ext <<_ACEOF |
| 7987 | #line 7987 "configure" |
| 7988 | #include "confdefs.h" |
| 7989 | #include <sys/types.h> |
| 7990 | int |
| 7991 | main () |
| 7992 | { |
| 7993 | |
| 7994 | #ifndef _POSIX_C_SOURCE |
| 7995 | make an error |
| 7996 | #endif |
| 7997 | ; |
| 7998 | return 0; |
| 7999 | } |
| 8000 | _ACEOF |
| 8001 | rm -f conftest.$ac_objext |
| 8002 | if { (eval echo "$as_me:8002: \"$ac_compile\"") >&5 |
| 8003 | (eval $ac_compile) 2>&5 |
| 8004 | ac_status=$? |
| 8005 | echo "$as_me:8005: \$? = $ac_status" >&5 |
| 8006 | (exit $ac_status); } && |
| 8007 | { ac_try='test -s conftest.$ac_objext' |
| 8008 | { (eval echo "$as_me:8008: \"$ac_try\"") >&5 |
| 8009 | (eval $ac_try) 2>&5 |
| 8010 | ac_status=$? |
| 8011 | echo "$as_me:8011: \$? = $ac_status" >&5 |
| 8012 | (exit $ac_status); }; }; then |
| 8013 | cf_cv_posix_c_source=no |
| 8014 | else |
| 8015 | echo "$as_me: failed program was:" >&5 |
| 8016 | cat conftest.$ac_ext >&5 |
| 8017 | cf_want_posix_source=no |
| 8018 | case .$cf_POSIX_C_SOURCE in |
| 8019 | (.[12]??*) |
| 8020 | cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" |
| 8021 | ;; |
| 8022 | (.2) |
| 8023 | cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" |
| 8024 | cf_want_posix_source=yes |
| 8025 | ;; |
| 8026 | (.*) |
| 8027 | cf_want_posix_source=yes |
| 8028 | ;; |
| 8029 | esac |
| 8030 | if test "$cf_want_posix_source" = yes ; then |
| 8031 | cat >conftest.$ac_ext <<_ACEOF |
| 8032 | #line 8032 "configure" |
| 8033 | #include "confdefs.h" |
| 8034 | #include <sys/types.h> |
| 8035 | int |
| 8036 | main () |
| 8037 | { |
| 8038 | |
| 8039 | #ifdef _POSIX_SOURCE |
| 8040 | make an error |
| 8041 | #endif |
| 8042 | ; |
| 8043 | return 0; |
| 8044 | } |
| 8045 | _ACEOF |
| 8046 | rm -f conftest.$ac_objext |
| 8047 | if { (eval echo "$as_me:8047: \"$ac_compile\"") >&5 |
| 8048 | (eval $ac_compile) 2>&5 |
| 8049 | ac_status=$? |
| 8050 | echo "$as_me:8050: \$? = $ac_status" >&5 |
| 8051 | (exit $ac_status); } && |
| 8052 | { ac_try='test -s conftest.$ac_objext' |
| 8053 | { (eval echo "$as_me:8053: \"$ac_try\"") >&5 |
| 8054 | (eval $ac_try) 2>&5 |
| 8055 | ac_status=$? |
| 8056 | echo "$as_me:8056: \$? = $ac_status" >&5 |
| 8057 | (exit $ac_status); }; }; then |
| 8058 | : |
| 8059 | else |
| 8060 | echo "$as_me: failed program was:" >&5 |
| 8061 | cat conftest.$ac_ext >&5 |
| 8062 | cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE" |
| 8063 | fi |
| 8064 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8065 | fi |
| 8066 | |
| 8067 | echo "${as_me:-configure}:8067: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5 |
| 8068 | |
| 8069 | CFLAGS="$cf_trim_CFLAGS" |
| 8070 | CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source" |
| 8071 | |
| 8072 | echo "${as_me:-configure}:8072: testing if the second compile does not leave our definition intact error ..." 1>&5 |
| 8073 | |
| 8074 | cat >conftest.$ac_ext <<_ACEOF |
| 8075 | #line 8075 "configure" |
| 8076 | #include "confdefs.h" |
| 8077 | #include <sys/types.h> |
| 8078 | int |
| 8079 | main () |
| 8080 | { |
| 8081 | |
| 8082 | #ifndef _POSIX_C_SOURCE |
| 8083 | make an error |
| 8084 | #endif |
| 8085 | ; |
| 8086 | return 0; |
| 8087 | } |
| 8088 | _ACEOF |
| 8089 | rm -f conftest.$ac_objext |
| 8090 | if { (eval echo "$as_me:8090: \"$ac_compile\"") >&5 |
| 8091 | (eval $ac_compile) 2>&5 |
| 8092 | ac_status=$? |
| 8093 | echo "$as_me:8093: \$? = $ac_status" >&5 |
| 8094 | (exit $ac_status); } && |
| 8095 | { ac_try='test -s conftest.$ac_objext' |
| 8096 | { (eval echo "$as_me:8096: \"$ac_try\"") >&5 |
| 8097 | (eval $ac_try) 2>&5 |
| 8098 | ac_status=$? |
| 8099 | echo "$as_me:8099: \$? = $ac_status" >&5 |
| 8100 | (exit $ac_status); }; }; then |
| 8101 | : |
| 8102 | else |
| 8103 | echo "$as_me: failed program was:" >&5 |
| 8104 | cat conftest.$ac_ext >&5 |
| 8105 | cf_cv_posix_c_source=no |
| 8106 | fi |
| 8107 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8108 | CFLAGS="$cf_save_CFLAGS" |
| 8109 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 8110 | |
| 8111 | fi |
| 8112 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8113 | |
| 8114 | fi |
| 8115 | echo "$as_me:8115: result: $cf_cv_posix_c_source" >&5 |
| 8116 | echo "${ECHO_T}$cf_cv_posix_c_source" >&6 |
| 8117 | |
| 8118 | if test "$cf_cv_posix_c_source" != no ; then |
| 8119 | CFLAGS="$cf_trim_CFLAGS" |
| 8120 | CPPFLAGS="$cf_trim_CPPFLAGS" |
| 8121 | |
| 8122 | cf_fix_cppflags=no |
| 8123 | cf_new_cflags= |
| 8124 | cf_new_cppflags= |
| 8125 | cf_new_extra_cppflags= |
| 8126 | |
| 8127 | for cf_add_cflags in $cf_cv_posix_c_source |
| 8128 | do |
| 8129 | case $cf_fix_cppflags in |
| 8130 | (no) |
| 8131 | case $cf_add_cflags in |
| 8132 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 8133 | case $cf_add_cflags in |
| 8134 | (-D*) |
| 8135 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 8136 | |
| 8137 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8138 | && test -z "${cf_tst_cflags}" \ |
| 8139 | && cf_fix_cppflags=yes |
| 8140 | |
| 8141 | if test $cf_fix_cppflags = yes ; then |
| 8142 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8143 | continue |
| 8144 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 8145 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8146 | continue |
| 8147 | fi |
| 8148 | ;; |
| 8149 | esac |
| 8150 | case "$CPPFLAGS" in |
| 8151 | (*$cf_add_cflags) |
| 8152 | ;; |
| 8153 | (*) |
| 8154 | case $cf_add_cflags in |
| 8155 | (-D*) |
| 8156 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 8157 | |
| 8158 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 8159 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8160 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 8161 | |
| 8162 | ;; |
| 8163 | esac |
| 8164 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 8165 | ;; |
| 8166 | esac |
| 8167 | ;; |
| 8168 | (*) |
| 8169 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 8170 | ;; |
| 8171 | esac |
| 8172 | ;; |
| 8173 | (yes) |
| 8174 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8175 | |
| 8176 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 8177 | |
| 8178 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8179 | && test -z "${cf_tst_cflags}" \ |
| 8180 | && cf_fix_cppflags=no |
| 8181 | ;; |
| 8182 | esac |
| 8183 | done |
| 8184 | |
| 8185 | if test -n "$cf_new_cflags" ; then |
| 8186 | |
| 8187 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 8188 | fi |
| 8189 | |
| 8190 | if test -n "$cf_new_cppflags" ; then |
| 8191 | |
| 8192 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 8193 | fi |
| 8194 | |
| 8195 | if test -n "$cf_new_extra_cppflags" ; then |
| 8196 | |
| 8197 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 8198 | fi |
| 8199 | |
| 8200 | fi |
| 8201 | |
| 8202 | ;; |
| 8203 | (netbsd*) |
| 8204 | cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw |
| 8205 | ;; |
| 8206 | (openbsd[4-9]*) |
| 8207 | # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw |
| 8208 | cf_xopen_source="-D_BSD_SOURCE" |
| 8209 | cf_XOPEN_SOURCE=600 |
| 8210 | ;; |
| 8211 | (openbsd*) |
| 8212 | # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw |
| 8213 | ;; |
| 8214 | (osf[45]*) |
| 8215 | cf_xopen_source="-D_OSF_SOURCE" |
| 8216 | ;; |
| 8217 | (nto-qnx*) |
| 8218 | cf_xopen_source="-D_QNX_SOURCE" |
| 8219 | ;; |
| 8220 | (sco*) |
| 8221 | # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer |
| 8222 | ;; |
| 8223 | (solaris2.*) |
| 8224 | cf_xopen_source="-D__EXTENSIONS__" |
| 8225 | cf_cv_xopen_source=broken |
| 8226 | ;; |
| 8227 | (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2) |
| 8228 | cf_XOPEN_SOURCE= |
| 8229 | cf_POSIX_C_SOURCE= |
| 8230 | ;; |
| 8231 | (*) |
| 8232 | |
| 8233 | echo "$as_me:8233: checking if we should define _XOPEN_SOURCE" >&5 |
| 8234 | echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6 |
| 8235 | if test "${cf_cv_xopen_source+set}" = set; then |
| 8236 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8237 | else |
| 8238 | |
| 8239 | cat >conftest.$ac_ext <<_ACEOF |
| 8240 | #line 8240 "configure" |
| 8241 | #include "confdefs.h" |
| 8242 | |
| 8243 | #include <stdlib.h> |
| 8244 | #include <string.h> |
| 8245 | #include <sys/types.h> |
| 8246 | |
| 8247 | int |
| 8248 | main () |
| 8249 | { |
| 8250 | |
| 8251 | #ifndef _XOPEN_SOURCE |
| 8252 | make an error |
| 8253 | #endif |
| 8254 | ; |
| 8255 | return 0; |
| 8256 | } |
| 8257 | _ACEOF |
| 8258 | rm -f conftest.$ac_objext |
| 8259 | if { (eval echo "$as_me:8259: \"$ac_compile\"") >&5 |
| 8260 | (eval $ac_compile) 2>&5 |
| 8261 | ac_status=$? |
| 8262 | echo "$as_me:8262: \$? = $ac_status" >&5 |
| 8263 | (exit $ac_status); } && |
| 8264 | { ac_try='test -s conftest.$ac_objext' |
| 8265 | { (eval echo "$as_me:8265: \"$ac_try\"") >&5 |
| 8266 | (eval $ac_try) 2>&5 |
| 8267 | ac_status=$? |
| 8268 | echo "$as_me:8268: \$? = $ac_status" >&5 |
| 8269 | (exit $ac_status); }; }; then |
| 8270 | cf_cv_xopen_source=no |
| 8271 | else |
| 8272 | echo "$as_me: failed program was:" >&5 |
| 8273 | cat conftest.$ac_ext >&5 |
| 8274 | cf_save="$CPPFLAGS" |
| 8275 | CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" |
| 8276 | cat >conftest.$ac_ext <<_ACEOF |
| 8277 | #line 8277 "configure" |
| 8278 | #include "confdefs.h" |
| 8279 | |
| 8280 | #include <stdlib.h> |
| 8281 | #include <string.h> |
| 8282 | #include <sys/types.h> |
| 8283 | |
| 8284 | int |
| 8285 | main () |
| 8286 | { |
| 8287 | |
| 8288 | #ifdef _XOPEN_SOURCE |
| 8289 | make an error |
| 8290 | #endif |
| 8291 | ; |
| 8292 | return 0; |
| 8293 | } |
| 8294 | _ACEOF |
| 8295 | rm -f conftest.$ac_objext |
| 8296 | if { (eval echo "$as_me:8296: \"$ac_compile\"") >&5 |
| 8297 | (eval $ac_compile) 2>&5 |
| 8298 | ac_status=$? |
| 8299 | echo "$as_me:8299: \$? = $ac_status" >&5 |
| 8300 | (exit $ac_status); } && |
| 8301 | { ac_try='test -s conftest.$ac_objext' |
| 8302 | { (eval echo "$as_me:8302: \"$ac_try\"") >&5 |
| 8303 | (eval $ac_try) 2>&5 |
| 8304 | ac_status=$? |
| 8305 | echo "$as_me:8305: \$? = $ac_status" >&5 |
| 8306 | (exit $ac_status); }; }; then |
| 8307 | cf_cv_xopen_source=no |
| 8308 | else |
| 8309 | echo "$as_me: failed program was:" >&5 |
| 8310 | cat conftest.$ac_ext >&5 |
| 8311 | cf_cv_xopen_source=$cf_XOPEN_SOURCE |
| 8312 | fi |
| 8313 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8314 | CPPFLAGS="$cf_save" |
| 8315 | |
| 8316 | fi |
| 8317 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8318 | |
| 8319 | fi |
| 8320 | echo "$as_me:8320: result: $cf_cv_xopen_source" >&5 |
| 8321 | echo "${ECHO_T}$cf_cv_xopen_source" >&6 |
| 8322 | |
| 8323 | if test "$cf_cv_xopen_source" != no ; then |
| 8324 | |
| 8325 | CFLAGS=`echo "$CFLAGS" | \ |
| 8326 | sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8327 | -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 8328 | |
| 8329 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 8330 | sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8331 | -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 8332 | |
| 8333 | cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source" |
| 8334 | |
| 8335 | cf_fix_cppflags=no |
| 8336 | cf_new_cflags= |
| 8337 | cf_new_cppflags= |
| 8338 | cf_new_extra_cppflags= |
| 8339 | |
| 8340 | for cf_add_cflags in $cf_temp_xopen_source |
| 8341 | do |
| 8342 | case $cf_fix_cppflags in |
| 8343 | (no) |
| 8344 | case $cf_add_cflags in |
| 8345 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 8346 | case $cf_add_cflags in |
| 8347 | (-D*) |
| 8348 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 8349 | |
| 8350 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8351 | && test -z "${cf_tst_cflags}" \ |
| 8352 | && cf_fix_cppflags=yes |
| 8353 | |
| 8354 | if test $cf_fix_cppflags = yes ; then |
| 8355 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8356 | continue |
| 8357 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 8358 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8359 | continue |
| 8360 | fi |
| 8361 | ;; |
| 8362 | esac |
| 8363 | case "$CPPFLAGS" in |
| 8364 | (*$cf_add_cflags) |
| 8365 | ;; |
| 8366 | (*) |
| 8367 | case $cf_add_cflags in |
| 8368 | (-D*) |
| 8369 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 8370 | |
| 8371 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 8372 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8373 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 8374 | |
| 8375 | ;; |
| 8376 | esac |
| 8377 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 8378 | ;; |
| 8379 | esac |
| 8380 | ;; |
| 8381 | (*) |
| 8382 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 8383 | ;; |
| 8384 | esac |
| 8385 | ;; |
| 8386 | (yes) |
| 8387 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8388 | |
| 8389 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 8390 | |
| 8391 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8392 | && test -z "${cf_tst_cflags}" \ |
| 8393 | && cf_fix_cppflags=no |
| 8394 | ;; |
| 8395 | esac |
| 8396 | done |
| 8397 | |
| 8398 | if test -n "$cf_new_cflags" ; then |
| 8399 | |
| 8400 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 8401 | fi |
| 8402 | |
| 8403 | if test -n "$cf_new_cppflags" ; then |
| 8404 | |
| 8405 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 8406 | fi |
| 8407 | |
| 8408 | if test -n "$cf_new_extra_cppflags" ; then |
| 8409 | |
| 8410 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 8411 | fi |
| 8412 | |
| 8413 | fi |
| 8414 | |
| 8415 | cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE |
| 8416 | |
| 8417 | cf_save_CFLAGS="$CFLAGS" |
| 8418 | cf_save_CPPFLAGS="$CPPFLAGS" |
| 8419 | |
| 8420 | cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \ |
| 8421 | sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8422 | -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 8423 | |
| 8424 | cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \ |
| 8425 | sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8426 | -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 8427 | |
| 8428 | echo "$as_me:8428: checking if we should define _POSIX_C_SOURCE" >&5 |
| 8429 | echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6 |
| 8430 | if test "${cf_cv_posix_c_source+set}" = set; then |
| 8431 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8432 | else |
| 8433 | |
| 8434 | echo "${as_me:-configure}:8434: testing if the symbol is already defined go no further ..." 1>&5 |
| 8435 | |
| 8436 | cat >conftest.$ac_ext <<_ACEOF |
| 8437 | #line 8437 "configure" |
| 8438 | #include "confdefs.h" |
| 8439 | #include <sys/types.h> |
| 8440 | int |
| 8441 | main () |
| 8442 | { |
| 8443 | |
| 8444 | #ifndef _POSIX_C_SOURCE |
| 8445 | make an error |
| 8446 | #endif |
| 8447 | ; |
| 8448 | return 0; |
| 8449 | } |
| 8450 | _ACEOF |
| 8451 | rm -f conftest.$ac_objext |
| 8452 | if { (eval echo "$as_me:8452: \"$ac_compile\"") >&5 |
| 8453 | (eval $ac_compile) 2>&5 |
| 8454 | ac_status=$? |
| 8455 | echo "$as_me:8455: \$? = $ac_status" >&5 |
| 8456 | (exit $ac_status); } && |
| 8457 | { ac_try='test -s conftest.$ac_objext' |
| 8458 | { (eval echo "$as_me:8458: \"$ac_try\"") >&5 |
| 8459 | (eval $ac_try) 2>&5 |
| 8460 | ac_status=$? |
| 8461 | echo "$as_me:8461: \$? = $ac_status" >&5 |
| 8462 | (exit $ac_status); }; }; then |
| 8463 | cf_cv_posix_c_source=no |
| 8464 | else |
| 8465 | echo "$as_me: failed program was:" >&5 |
| 8466 | cat conftest.$ac_ext >&5 |
| 8467 | cf_want_posix_source=no |
| 8468 | case .$cf_POSIX_C_SOURCE in |
| 8469 | (.[12]??*) |
| 8470 | cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" |
| 8471 | ;; |
| 8472 | (.2) |
| 8473 | cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE" |
| 8474 | cf_want_posix_source=yes |
| 8475 | ;; |
| 8476 | (.*) |
| 8477 | cf_want_posix_source=yes |
| 8478 | ;; |
| 8479 | esac |
| 8480 | if test "$cf_want_posix_source" = yes ; then |
| 8481 | cat >conftest.$ac_ext <<_ACEOF |
| 8482 | #line 8482 "configure" |
| 8483 | #include "confdefs.h" |
| 8484 | #include <sys/types.h> |
| 8485 | int |
| 8486 | main () |
| 8487 | { |
| 8488 | |
| 8489 | #ifdef _POSIX_SOURCE |
| 8490 | make an error |
| 8491 | #endif |
| 8492 | ; |
| 8493 | return 0; |
| 8494 | } |
| 8495 | _ACEOF |
| 8496 | rm -f conftest.$ac_objext |
| 8497 | if { (eval echo "$as_me:8497: \"$ac_compile\"") >&5 |
| 8498 | (eval $ac_compile) 2>&5 |
| 8499 | ac_status=$? |
| 8500 | echo "$as_me:8500: \$? = $ac_status" >&5 |
| 8501 | (exit $ac_status); } && |
| 8502 | { ac_try='test -s conftest.$ac_objext' |
| 8503 | { (eval echo "$as_me:8503: \"$ac_try\"") >&5 |
| 8504 | (eval $ac_try) 2>&5 |
| 8505 | ac_status=$? |
| 8506 | echo "$as_me:8506: \$? = $ac_status" >&5 |
| 8507 | (exit $ac_status); }; }; then |
| 8508 | : |
| 8509 | else |
| 8510 | echo "$as_me: failed program was:" >&5 |
| 8511 | cat conftest.$ac_ext >&5 |
| 8512 | cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE" |
| 8513 | fi |
| 8514 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8515 | fi |
| 8516 | |
| 8517 | echo "${as_me:-configure}:8517: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5 |
| 8518 | |
| 8519 | CFLAGS="$cf_trim_CFLAGS" |
| 8520 | CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source" |
| 8521 | |
| 8522 | echo "${as_me:-configure}:8522: testing if the second compile does not leave our definition intact error ..." 1>&5 |
| 8523 | |
| 8524 | cat >conftest.$ac_ext <<_ACEOF |
| 8525 | #line 8525 "configure" |
| 8526 | #include "confdefs.h" |
| 8527 | #include <sys/types.h> |
| 8528 | int |
| 8529 | main () |
| 8530 | { |
| 8531 | |
| 8532 | #ifndef _POSIX_C_SOURCE |
| 8533 | make an error |
| 8534 | #endif |
| 8535 | ; |
| 8536 | return 0; |
| 8537 | } |
| 8538 | _ACEOF |
| 8539 | rm -f conftest.$ac_objext |
| 8540 | if { (eval echo "$as_me:8540: \"$ac_compile\"") >&5 |
| 8541 | (eval $ac_compile) 2>&5 |
| 8542 | ac_status=$? |
| 8543 | echo "$as_me:8543: \$? = $ac_status" >&5 |
| 8544 | (exit $ac_status); } && |
| 8545 | { ac_try='test -s conftest.$ac_objext' |
| 8546 | { (eval echo "$as_me:8546: \"$ac_try\"") >&5 |
| 8547 | (eval $ac_try) 2>&5 |
| 8548 | ac_status=$? |
| 8549 | echo "$as_me:8549: \$? = $ac_status" >&5 |
| 8550 | (exit $ac_status); }; }; then |
| 8551 | : |
| 8552 | else |
| 8553 | echo "$as_me: failed program was:" >&5 |
| 8554 | cat conftest.$ac_ext >&5 |
| 8555 | cf_cv_posix_c_source=no |
| 8556 | fi |
| 8557 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8558 | CFLAGS="$cf_save_CFLAGS" |
| 8559 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 8560 | |
| 8561 | fi |
| 8562 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8563 | |
| 8564 | fi |
| 8565 | echo "$as_me:8565: result: $cf_cv_posix_c_source" >&5 |
| 8566 | echo "${ECHO_T}$cf_cv_posix_c_source" >&6 |
| 8567 | |
| 8568 | if test "$cf_cv_posix_c_source" != no ; then |
| 8569 | CFLAGS="$cf_trim_CFLAGS" |
| 8570 | CPPFLAGS="$cf_trim_CPPFLAGS" |
| 8571 | |
| 8572 | cf_fix_cppflags=no |
| 8573 | cf_new_cflags= |
| 8574 | cf_new_cppflags= |
| 8575 | cf_new_extra_cppflags= |
| 8576 | |
| 8577 | for cf_add_cflags in $cf_cv_posix_c_source |
| 8578 | do |
| 8579 | case $cf_fix_cppflags in |
| 8580 | (no) |
| 8581 | case $cf_add_cflags in |
| 8582 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 8583 | case $cf_add_cflags in |
| 8584 | (-D*) |
| 8585 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 8586 | |
| 8587 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8588 | && test -z "${cf_tst_cflags}" \ |
| 8589 | && cf_fix_cppflags=yes |
| 8590 | |
| 8591 | if test $cf_fix_cppflags = yes ; then |
| 8592 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8593 | continue |
| 8594 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 8595 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8596 | continue |
| 8597 | fi |
| 8598 | ;; |
| 8599 | esac |
| 8600 | case "$CPPFLAGS" in |
| 8601 | (*$cf_add_cflags) |
| 8602 | ;; |
| 8603 | (*) |
| 8604 | case $cf_add_cflags in |
| 8605 | (-D*) |
| 8606 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 8607 | |
| 8608 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 8609 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8610 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 8611 | |
| 8612 | ;; |
| 8613 | esac |
| 8614 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 8615 | ;; |
| 8616 | esac |
| 8617 | ;; |
| 8618 | (*) |
| 8619 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 8620 | ;; |
| 8621 | esac |
| 8622 | ;; |
| 8623 | (yes) |
| 8624 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8625 | |
| 8626 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 8627 | |
| 8628 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8629 | && test -z "${cf_tst_cflags}" \ |
| 8630 | && cf_fix_cppflags=no |
| 8631 | ;; |
| 8632 | esac |
| 8633 | done |
| 8634 | |
| 8635 | if test -n "$cf_new_cflags" ; then |
| 8636 | |
| 8637 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 8638 | fi |
| 8639 | |
| 8640 | if test -n "$cf_new_cppflags" ; then |
| 8641 | |
| 8642 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 8643 | fi |
| 8644 | |
| 8645 | if test -n "$cf_new_extra_cppflags" ; then |
| 8646 | |
| 8647 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 8648 | fi |
| 8649 | |
| 8650 | fi |
| 8651 | |
| 8652 | ;; |
| 8653 | esac |
| 8654 | |
| 8655 | if test -n "$cf_xopen_source" ; then |
| 8656 | |
| 8657 | cf_fix_cppflags=no |
| 8658 | cf_new_cflags= |
| 8659 | cf_new_cppflags= |
| 8660 | cf_new_extra_cppflags= |
| 8661 | |
| 8662 | for cf_add_cflags in $cf_xopen_source |
| 8663 | do |
| 8664 | case $cf_fix_cppflags in |
| 8665 | (no) |
| 8666 | case $cf_add_cflags in |
| 8667 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 8668 | case $cf_add_cflags in |
| 8669 | (-D*) |
| 8670 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 8671 | |
| 8672 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8673 | && test -z "${cf_tst_cflags}" \ |
| 8674 | && cf_fix_cppflags=yes |
| 8675 | |
| 8676 | if test $cf_fix_cppflags = yes ; then |
| 8677 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8678 | continue |
| 8679 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 8680 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8681 | continue |
| 8682 | fi |
| 8683 | ;; |
| 8684 | esac |
| 8685 | case "$CPPFLAGS" in |
| 8686 | (*$cf_add_cflags) |
| 8687 | ;; |
| 8688 | (*) |
| 8689 | case $cf_add_cflags in |
| 8690 | (-D*) |
| 8691 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 8692 | |
| 8693 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 8694 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8695 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 8696 | |
| 8697 | ;; |
| 8698 | esac |
| 8699 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 8700 | ;; |
| 8701 | esac |
| 8702 | ;; |
| 8703 | (*) |
| 8704 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 8705 | ;; |
| 8706 | esac |
| 8707 | ;; |
| 8708 | (yes) |
| 8709 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8710 | |
| 8711 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 8712 | |
| 8713 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8714 | && test -z "${cf_tst_cflags}" \ |
| 8715 | && cf_fix_cppflags=no |
| 8716 | ;; |
| 8717 | esac |
| 8718 | done |
| 8719 | |
| 8720 | if test -n "$cf_new_cflags" ; then |
| 8721 | test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6 |
| 8722 | |
| 8723 | echo "${as_me:-configure}:8723: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5 |
| 8724 | |
| 8725 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 8726 | fi |
| 8727 | |
| 8728 | if test -n "$cf_new_cppflags" ; then |
| 8729 | test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6 |
| 8730 | |
| 8731 | echo "${as_me:-configure}:8731: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5 |
| 8732 | |
| 8733 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 8734 | fi |
| 8735 | |
| 8736 | if test -n "$cf_new_extra_cppflags" ; then |
| 8737 | test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6 |
| 8738 | |
| 8739 | echo "${as_me:-configure}:8739: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5 |
| 8740 | |
| 8741 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 8742 | fi |
| 8743 | |
| 8744 | fi |
| 8745 | |
| 8746 | if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then |
| 8747 | echo "$as_me:8747: checking if _XOPEN_SOURCE really is set" >&5 |
| 8748 | echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6 |
| 8749 | cat >conftest.$ac_ext <<_ACEOF |
| 8750 | #line 8750 "configure" |
| 8751 | #include "confdefs.h" |
| 8752 | #include <stdlib.h> |
| 8753 | int |
| 8754 | main () |
| 8755 | { |
| 8756 | |
| 8757 | #ifndef _XOPEN_SOURCE |
| 8758 | make an error |
| 8759 | #endif |
| 8760 | ; |
| 8761 | return 0; |
| 8762 | } |
| 8763 | _ACEOF |
| 8764 | rm -f conftest.$ac_objext |
| 8765 | if { (eval echo "$as_me:8765: \"$ac_compile\"") >&5 |
| 8766 | (eval $ac_compile) 2>&5 |
| 8767 | ac_status=$? |
| 8768 | echo "$as_me:8768: \$? = $ac_status" >&5 |
| 8769 | (exit $ac_status); } && |
| 8770 | { ac_try='test -s conftest.$ac_objext' |
| 8771 | { (eval echo "$as_me:8771: \"$ac_try\"") >&5 |
| 8772 | (eval $ac_try) 2>&5 |
| 8773 | ac_status=$? |
| 8774 | echo "$as_me:8774: \$? = $ac_status" >&5 |
| 8775 | (exit $ac_status); }; }; then |
| 8776 | cf_XOPEN_SOURCE_set=yes |
| 8777 | else |
| 8778 | echo "$as_me: failed program was:" >&5 |
| 8779 | cat conftest.$ac_ext >&5 |
| 8780 | cf_XOPEN_SOURCE_set=no |
| 8781 | fi |
| 8782 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8783 | echo "$as_me:8783: result: $cf_XOPEN_SOURCE_set" >&5 |
| 8784 | echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6 |
| 8785 | if test $cf_XOPEN_SOURCE_set = yes |
| 8786 | then |
| 8787 | cat >conftest.$ac_ext <<_ACEOF |
| 8788 | #line 8788 "configure" |
| 8789 | #include "confdefs.h" |
| 8790 | #include <stdlib.h> |
| 8791 | int |
| 8792 | main () |
| 8793 | { |
| 8794 | |
| 8795 | #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE |
| 8796 | make an error |
| 8797 | #endif |
| 8798 | ; |
| 8799 | return 0; |
| 8800 | } |
| 8801 | _ACEOF |
| 8802 | rm -f conftest.$ac_objext |
| 8803 | if { (eval echo "$as_me:8803: \"$ac_compile\"") >&5 |
| 8804 | (eval $ac_compile) 2>&5 |
| 8805 | ac_status=$? |
| 8806 | echo "$as_me:8806: \$? = $ac_status" >&5 |
| 8807 | (exit $ac_status); } && |
| 8808 | { ac_try='test -s conftest.$ac_objext' |
| 8809 | { (eval echo "$as_me:8809: \"$ac_try\"") >&5 |
| 8810 | (eval $ac_try) 2>&5 |
| 8811 | ac_status=$? |
| 8812 | echo "$as_me:8812: \$? = $ac_status" >&5 |
| 8813 | (exit $ac_status); }; }; then |
| 8814 | cf_XOPEN_SOURCE_set_ok=yes |
| 8815 | else |
| 8816 | echo "$as_me: failed program was:" >&5 |
| 8817 | cat conftest.$ac_ext >&5 |
| 8818 | cf_XOPEN_SOURCE_set_ok=no |
| 8819 | fi |
| 8820 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8821 | if test $cf_XOPEN_SOURCE_set_ok = no |
| 8822 | then |
| 8823 | { echo "$as_me:8823: WARNING: _XOPEN_SOURCE is lower than requested" >&5 |
| 8824 | echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;} |
| 8825 | fi |
| 8826 | else |
| 8827 | |
| 8828 | echo "$as_me:8828: checking if we should define _XOPEN_SOURCE" >&5 |
| 8829 | echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6 |
| 8830 | if test "${cf_cv_xopen_source+set}" = set; then |
| 8831 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 8832 | else |
| 8833 | |
| 8834 | cat >conftest.$ac_ext <<_ACEOF |
| 8835 | #line 8835 "configure" |
| 8836 | #include "confdefs.h" |
| 8837 | |
| 8838 | #include <stdlib.h> |
| 8839 | #include <string.h> |
| 8840 | #include <sys/types.h> |
| 8841 | |
| 8842 | int |
| 8843 | main () |
| 8844 | { |
| 8845 | |
| 8846 | #ifndef _XOPEN_SOURCE |
| 8847 | make an error |
| 8848 | #endif |
| 8849 | ; |
| 8850 | return 0; |
| 8851 | } |
| 8852 | _ACEOF |
| 8853 | rm -f conftest.$ac_objext |
| 8854 | if { (eval echo "$as_me:8854: \"$ac_compile\"") >&5 |
| 8855 | (eval $ac_compile) 2>&5 |
| 8856 | ac_status=$? |
| 8857 | echo "$as_me:8857: \$? = $ac_status" >&5 |
| 8858 | (exit $ac_status); } && |
| 8859 | { ac_try='test -s conftest.$ac_objext' |
| 8860 | { (eval echo "$as_me:8860: \"$ac_try\"") >&5 |
| 8861 | (eval $ac_try) 2>&5 |
| 8862 | ac_status=$? |
| 8863 | echo "$as_me:8863: \$? = $ac_status" >&5 |
| 8864 | (exit $ac_status); }; }; then |
| 8865 | cf_cv_xopen_source=no |
| 8866 | else |
| 8867 | echo "$as_me: failed program was:" >&5 |
| 8868 | cat conftest.$ac_ext >&5 |
| 8869 | cf_save="$CPPFLAGS" |
| 8870 | CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE" |
| 8871 | cat >conftest.$ac_ext <<_ACEOF |
| 8872 | #line 8872 "configure" |
| 8873 | #include "confdefs.h" |
| 8874 | |
| 8875 | #include <stdlib.h> |
| 8876 | #include <string.h> |
| 8877 | #include <sys/types.h> |
| 8878 | |
| 8879 | int |
| 8880 | main () |
| 8881 | { |
| 8882 | |
| 8883 | #ifdef _XOPEN_SOURCE |
| 8884 | make an error |
| 8885 | #endif |
| 8886 | ; |
| 8887 | return 0; |
| 8888 | } |
| 8889 | _ACEOF |
| 8890 | rm -f conftest.$ac_objext |
| 8891 | if { (eval echo "$as_me:8891: \"$ac_compile\"") >&5 |
| 8892 | (eval $ac_compile) 2>&5 |
| 8893 | ac_status=$? |
| 8894 | echo "$as_me:8894: \$? = $ac_status" >&5 |
| 8895 | (exit $ac_status); } && |
| 8896 | { ac_try='test -s conftest.$ac_objext' |
| 8897 | { (eval echo "$as_me:8897: \"$ac_try\"") >&5 |
| 8898 | (eval $ac_try) 2>&5 |
| 8899 | ac_status=$? |
| 8900 | echo "$as_me:8900: \$? = $ac_status" >&5 |
| 8901 | (exit $ac_status); }; }; then |
| 8902 | cf_cv_xopen_source=no |
| 8903 | else |
| 8904 | echo "$as_me: failed program was:" >&5 |
| 8905 | cat conftest.$ac_ext >&5 |
| 8906 | cf_cv_xopen_source=$cf_XOPEN_SOURCE |
| 8907 | fi |
| 8908 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8909 | CPPFLAGS="$cf_save" |
| 8910 | |
| 8911 | fi |
| 8912 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 8913 | |
| 8914 | fi |
| 8915 | echo "$as_me:8915: result: $cf_cv_xopen_source" >&5 |
| 8916 | echo "${ECHO_T}$cf_cv_xopen_source" >&6 |
| 8917 | |
| 8918 | if test "$cf_cv_xopen_source" != no ; then |
| 8919 | |
| 8920 | CFLAGS=`echo "$CFLAGS" | \ |
| 8921 | sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8922 | -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 8923 | |
| 8924 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 8925 | sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8926 | -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'` |
| 8927 | |
| 8928 | cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source" |
| 8929 | |
| 8930 | cf_fix_cppflags=no |
| 8931 | cf_new_cflags= |
| 8932 | cf_new_cppflags= |
| 8933 | cf_new_extra_cppflags= |
| 8934 | |
| 8935 | for cf_add_cflags in $cf_temp_xopen_source |
| 8936 | do |
| 8937 | case $cf_fix_cppflags in |
| 8938 | (no) |
| 8939 | case $cf_add_cflags in |
| 8940 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 8941 | case $cf_add_cflags in |
| 8942 | (-D*) |
| 8943 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 8944 | |
| 8945 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8946 | && test -z "${cf_tst_cflags}" \ |
| 8947 | && cf_fix_cppflags=yes |
| 8948 | |
| 8949 | if test $cf_fix_cppflags = yes ; then |
| 8950 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8951 | continue |
| 8952 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 8953 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8954 | continue |
| 8955 | fi |
| 8956 | ;; |
| 8957 | esac |
| 8958 | case "$CPPFLAGS" in |
| 8959 | (*$cf_add_cflags) |
| 8960 | ;; |
| 8961 | (*) |
| 8962 | case $cf_add_cflags in |
| 8963 | (-D*) |
| 8964 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 8965 | |
| 8966 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 8967 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 8968 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 8969 | |
| 8970 | ;; |
| 8971 | esac |
| 8972 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 8973 | ;; |
| 8974 | esac |
| 8975 | ;; |
| 8976 | (*) |
| 8977 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 8978 | ;; |
| 8979 | esac |
| 8980 | ;; |
| 8981 | (yes) |
| 8982 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 8983 | |
| 8984 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 8985 | |
| 8986 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 8987 | && test -z "${cf_tst_cflags}" \ |
| 8988 | && cf_fix_cppflags=no |
| 8989 | ;; |
| 8990 | esac |
| 8991 | done |
| 8992 | |
| 8993 | if test -n "$cf_new_cflags" ; then |
| 8994 | |
| 8995 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 8996 | fi |
| 8997 | |
| 8998 | if test -n "$cf_new_cppflags" ; then |
| 8999 | |
| 9000 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 9001 | fi |
| 9002 | |
| 9003 | if test -n "$cf_new_extra_cppflags" ; then |
| 9004 | |
| 9005 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 9006 | fi |
| 9007 | |
| 9008 | fi |
| 9009 | |
| 9010 | fi |
| 9011 | fi |
| 9012 | |
| 9013 | CPPFLAGS_after_XOPEN="$CPPFLAGS" |
| 9014 | |
| 9015 | # Work around breakage on OS X |
| 9016 | |
| 9017 | echo "$as_me:9017: checking if SIGWINCH is defined" >&5 |
| 9018 | echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6 |
| 9019 | if test "${cf_cv_define_sigwinch+set}" = set; then |
| 9020 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9021 | else |
| 9022 | |
| 9023 | cat >conftest.$ac_ext <<_ACEOF |
| 9024 | #line 9024 "configure" |
| 9025 | #include "confdefs.h" |
| 9026 | |
| 9027 | #include <sys/types.h> |
| 9028 | #include <sys/signal.h> |
| 9029 | |
| 9030 | int |
| 9031 | main () |
| 9032 | { |
| 9033 | int x = SIGWINCH |
| 9034 | ; |
| 9035 | return 0; |
| 9036 | } |
| 9037 | _ACEOF |
| 9038 | rm -f conftest.$ac_objext |
| 9039 | if { (eval echo "$as_me:9039: \"$ac_compile\"") >&5 |
| 9040 | (eval $ac_compile) 2>&5 |
| 9041 | ac_status=$? |
| 9042 | echo "$as_me:9042: \$? = $ac_status" >&5 |
| 9043 | (exit $ac_status); } && |
| 9044 | { ac_try='test -s conftest.$ac_objext' |
| 9045 | { (eval echo "$as_me:9045: \"$ac_try\"") >&5 |
| 9046 | (eval $ac_try) 2>&5 |
| 9047 | ac_status=$? |
| 9048 | echo "$as_me:9048: \$? = $ac_status" >&5 |
| 9049 | (exit $ac_status); }; }; then |
| 9050 | cf_cv_define_sigwinch=yes |
| 9051 | else |
| 9052 | echo "$as_me: failed program was:" >&5 |
| 9053 | cat conftest.$ac_ext >&5 |
| 9054 | cat >conftest.$ac_ext <<_ACEOF |
| 9055 | #line 9055 "configure" |
| 9056 | #include "confdefs.h" |
| 9057 | |
| 9058 | #undef _XOPEN_SOURCE |
| 9059 | #undef _POSIX_SOURCE |
| 9060 | #undef _POSIX_C_SOURCE |
| 9061 | #include <sys/types.h> |
| 9062 | #include <sys/signal.h> |
| 9063 | |
| 9064 | int |
| 9065 | main () |
| 9066 | { |
| 9067 | int x = SIGWINCH |
| 9068 | ; |
| 9069 | return 0; |
| 9070 | } |
| 9071 | _ACEOF |
| 9072 | rm -f conftest.$ac_objext |
| 9073 | if { (eval echo "$as_me:9073: \"$ac_compile\"") >&5 |
| 9074 | (eval $ac_compile) 2>&5 |
| 9075 | ac_status=$? |
| 9076 | echo "$as_me:9076: \$? = $ac_status" >&5 |
| 9077 | (exit $ac_status); } && |
| 9078 | { ac_try='test -s conftest.$ac_objext' |
| 9079 | { (eval echo "$as_me:9079: \"$ac_try\"") >&5 |
| 9080 | (eval $ac_try) 2>&5 |
| 9081 | ac_status=$? |
| 9082 | echo "$as_me:9082: \$? = $ac_status" >&5 |
| 9083 | (exit $ac_status); }; }; then |
| 9084 | cf_cv_define_sigwinch=maybe |
| 9085 | else |
| 9086 | echo "$as_me: failed program was:" >&5 |
| 9087 | cat conftest.$ac_ext >&5 |
| 9088 | cf_cv_define_sigwinch=no |
| 9089 | fi |
| 9090 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 9091 | |
| 9092 | fi |
| 9093 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 9094 | |
| 9095 | fi |
| 9096 | echo "$as_me:9096: result: $cf_cv_define_sigwinch" >&5 |
| 9097 | echo "${ECHO_T}$cf_cv_define_sigwinch" >&6 |
| 9098 | |
| 9099 | if test "$cf_cv_define_sigwinch" = maybe ; then |
| 9100 | echo "$as_me:9100: checking for actual SIGWINCH definition" >&5 |
| 9101 | echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6 |
| 9102 | if test "${cf_cv_fixup_sigwinch+set}" = set; then |
| 9103 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9104 | else |
| 9105 | |
| 9106 | cf_cv_fixup_sigwinch=unknown |
| 9107 | cf_sigwinch=32 |
| 9108 | while test $cf_sigwinch != 1 |
| 9109 | do |
| 9110 | cat >conftest.$ac_ext <<_ACEOF |
| 9111 | #line 9111 "configure" |
| 9112 | #include "confdefs.h" |
| 9113 | |
| 9114 | #undef _XOPEN_SOURCE |
| 9115 | #undef _POSIX_SOURCE |
| 9116 | #undef _POSIX_C_SOURCE |
| 9117 | #include <sys/types.h> |
| 9118 | #include <sys/signal.h> |
| 9119 | |
| 9120 | int |
| 9121 | main () |
| 9122 | { |
| 9123 | |
| 9124 | #if SIGWINCH != $cf_sigwinch |
| 9125 | make an error |
| 9126 | #endif |
| 9127 | int x = SIGWINCH |
| 9128 | ; |
| 9129 | return 0; |
| 9130 | } |
| 9131 | _ACEOF |
| 9132 | rm -f conftest.$ac_objext |
| 9133 | if { (eval echo "$as_me:9133: \"$ac_compile\"") >&5 |
| 9134 | (eval $ac_compile) 2>&5 |
| 9135 | ac_status=$? |
| 9136 | echo "$as_me:9136: \$? = $ac_status" >&5 |
| 9137 | (exit $ac_status); } && |
| 9138 | { ac_try='test -s conftest.$ac_objext' |
| 9139 | { (eval echo "$as_me:9139: \"$ac_try\"") >&5 |
| 9140 | (eval $ac_try) 2>&5 |
| 9141 | ac_status=$? |
| 9142 | echo "$as_me:9142: \$? = $ac_status" >&5 |
| 9143 | (exit $ac_status); }; }; then |
| 9144 | cf_cv_fixup_sigwinch=$cf_sigwinch |
| 9145 | break |
| 9146 | else |
| 9147 | echo "$as_me: failed program was:" >&5 |
| 9148 | cat conftest.$ac_ext >&5 |
| 9149 | fi |
| 9150 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 9151 | |
| 9152 | cf_sigwinch=`expr $cf_sigwinch - 1` |
| 9153 | done |
| 9154 | |
| 9155 | fi |
| 9156 | echo "$as_me:9156: result: $cf_cv_fixup_sigwinch" >&5 |
| 9157 | echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6 |
| 9158 | |
| 9159 | if test "$cf_cv_fixup_sigwinch" != unknown ; then |
| 9160 | CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch" |
| 9161 | fi |
| 9162 | fi |
| 9163 | |
| 9164 | # Checks for CODESET support. |
| 9165 | |
| 9166 | echo "$as_me:9166: checking for nl_langinfo and CODESET" >&5 |
| 9167 | echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6 |
| 9168 | if test "${am_cv_langinfo_codeset+set}" = set; then |
| 9169 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9170 | else |
| 9171 | cat >conftest.$ac_ext <<_ACEOF |
| 9172 | #line 9172 "configure" |
| 9173 | #include "confdefs.h" |
| 9174 | #include <langinfo.h> |
| 9175 | int |
| 9176 | main () |
| 9177 | { |
| 9178 | char* cs = nl_langinfo(CODESET); |
| 9179 | ; |
| 9180 | return 0; |
| 9181 | } |
| 9182 | _ACEOF |
| 9183 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9184 | if { (eval echo "$as_me:9184: \"$ac_link\"") >&5 |
| 9185 | (eval $ac_link) 2>&5 |
| 9186 | ac_status=$? |
| 9187 | echo "$as_me:9187: \$? = $ac_status" >&5 |
| 9188 | (exit $ac_status); } && |
| 9189 | { ac_try='test -s conftest$ac_exeext' |
| 9190 | { (eval echo "$as_me:9190: \"$ac_try\"") >&5 |
| 9191 | (eval $ac_try) 2>&5 |
| 9192 | ac_status=$? |
| 9193 | echo "$as_me:9193: \$? = $ac_status" >&5 |
| 9194 | (exit $ac_status); }; }; then |
| 9195 | am_cv_langinfo_codeset=yes |
| 9196 | else |
| 9197 | echo "$as_me: failed program was:" >&5 |
| 9198 | cat conftest.$ac_ext >&5 |
| 9199 | am_cv_langinfo_codeset=no |
| 9200 | fi |
| 9201 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9202 | |
| 9203 | fi |
| 9204 | echo "$as_me:9204: result: $am_cv_langinfo_codeset" >&5 |
| 9205 | echo "${ECHO_T}$am_cv_langinfo_codeset" >&6 |
| 9206 | if test $am_cv_langinfo_codeset = yes; then |
| 9207 | |
| 9208 | cat >>confdefs.h <<\EOF |
| 9209 | #define HAVE_LANGINFO_CODESET 1 |
| 9210 | EOF |
| 9211 | |
| 9212 | fi |
| 9213 | |
| 9214 | # use these variables to work around a defect in gcc's fixincludes. |
| 9215 | NCURSES_OK_WCHAR_T= |
| 9216 | NCURSES_OK_WINT_T= |
| 9217 | |
| 9218 | echo "$as_me:9218: checking if you want wide-character code" >&5 |
| 9219 | echo $ECHO_N "checking if you want wide-character code... $ECHO_C" >&6 |
| 9220 | |
| 9221 | # Check whether --enable-widec or --disable-widec was given. |
| 9222 | if test "${enable_widec+set}" = set; then |
| 9223 | enableval="$enable_widec" |
| 9224 | with_widec=$enableval |
| 9225 | else |
| 9226 | with_widec=no |
| 9227 | fi; |
| 9228 | echo "$as_me:9228: result: $with_widec" >&5 |
| 9229 | echo "${ECHO_T}$with_widec" >&6 |
| 9230 | if test "x$with_widec" = xyes ; then |
| 9231 | if test "x$disable_lib_suffixes" = xno ; then |
| 9232 | LIB_SUFFIX="w${LIB_SUFFIX}" |
| 9233 | fi |
| 9234 | |
| 9235 | cat >>confdefs.h <<\EOF |
| 9236 | #define USE_WIDEC_SUPPORT 1 |
| 9237 | EOF |
| 9238 | |
| 9239 | cat >>confdefs.h <<\EOF |
| 9240 | #define NCURSES_WIDECHAR 1 |
| 9241 | EOF |
| 9242 | |
| 9243 | echo "$as_me:9243: checking if wchar.h can be used as is" >&5 |
| 9244 | echo $ECHO_N "checking if wchar.h can be used as is... $ECHO_C" >&6 |
| 9245 | if test "${cf_cv_wchar_h_okay+set}" = set; then |
| 9246 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9247 | else |
| 9248 | |
| 9249 | cat >conftest.$ac_ext <<_ACEOF |
| 9250 | #line 9250 "configure" |
| 9251 | #include "confdefs.h" |
| 9252 | |
| 9253 | #include <stdlib.h> |
| 9254 | #include <wchar.h> |
| 9255 | |
| 9256 | int |
| 9257 | main () |
| 9258 | { |
| 9259 | |
| 9260 | wint_t foo = 0; |
| 9261 | int bar = iswpunct(foo) |
| 9262 | ; |
| 9263 | return 0; |
| 9264 | } |
| 9265 | _ACEOF |
| 9266 | rm -f conftest.$ac_objext |
| 9267 | if { (eval echo "$as_me:9267: \"$ac_compile\"") >&5 |
| 9268 | (eval $ac_compile) 2>&5 |
| 9269 | ac_status=$? |
| 9270 | echo "$as_me:9270: \$? = $ac_status" >&5 |
| 9271 | (exit $ac_status); } && |
| 9272 | { ac_try='test -s conftest.$ac_objext' |
| 9273 | { (eval echo "$as_me:9273: \"$ac_try\"") >&5 |
| 9274 | (eval $ac_try) 2>&5 |
| 9275 | ac_status=$? |
| 9276 | echo "$as_me:9276: \$? = $ac_status" >&5 |
| 9277 | (exit $ac_status); }; }; then |
| 9278 | cf_cv_wchar_h_okay=yes |
| 9279 | else |
| 9280 | echo "$as_me: failed program was:" >&5 |
| 9281 | cat conftest.$ac_ext >&5 |
| 9282 | cf_cv_wchar_h_okay=no |
| 9283 | fi |
| 9284 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 9285 | fi |
| 9286 | echo "$as_me:9286: result: $cf_cv_wchar_h_okay" >&5 |
| 9287 | echo "${ECHO_T}$cf_cv_wchar_h_okay" >&6 |
| 9288 | |
| 9289 | if test $cf_cv_wchar_h_okay = no |
| 9290 | then |
| 9291 | |
| 9292 | echo "$as_me:9292: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5 |
| 9293 | echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6 |
| 9294 | cat >conftest.$ac_ext <<_ACEOF |
| 9295 | #line 9295 "configure" |
| 9296 | #include "confdefs.h" |
| 9297 | #include <sys/types.h> |
| 9298 | |
| 9299 | int |
| 9300 | main () |
| 9301 | { |
| 9302 | |
| 9303 | #ifndef _XOPEN_SOURCE_EXTENDED |
| 9304 | make an error |
| 9305 | #endif |
| 9306 | ; |
| 9307 | return 0; |
| 9308 | } |
| 9309 | _ACEOF |
| 9310 | rm -f conftest.$ac_objext |
| 9311 | if { (eval echo "$as_me:9311: \"$ac_compile\"") >&5 |
| 9312 | (eval $ac_compile) 2>&5 |
| 9313 | ac_status=$? |
| 9314 | echo "$as_me:9314: \$? = $ac_status" >&5 |
| 9315 | (exit $ac_status); } && |
| 9316 | { ac_try='test -s conftest.$ac_objext' |
| 9317 | { (eval echo "$as_me:9317: \"$ac_try\"") >&5 |
| 9318 | (eval $ac_try) 2>&5 |
| 9319 | ac_status=$? |
| 9320 | echo "$as_me:9320: \$? = $ac_status" >&5 |
| 9321 | (exit $ac_status); }; }; then |
| 9322 | cf_result=no |
| 9323 | else |
| 9324 | echo "$as_me: failed program was:" >&5 |
| 9325 | cat conftest.$ac_ext >&5 |
| 9326 | cf_result=yes |
| 9327 | fi |
| 9328 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 9329 | echo "$as_me:9329: result: $cf_result" >&5 |
| 9330 | echo "${ECHO_T}$cf_result" >&6 |
| 9331 | |
| 9332 | if test "$cf_result" = yes ; then |
| 9333 | CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED" |
| 9334 | elif test "x" != "x" ; then |
| 9335 | echo "$as_me:9335: checking checking for compatible value versus " >&5 |
| 9336 | echo $ECHO_N "checking checking for compatible value versus ... $ECHO_C" >&6 |
| 9337 | cat >conftest.$ac_ext <<_ACEOF |
| 9338 | #line 9338 "configure" |
| 9339 | #include "confdefs.h" |
| 9340 | #include <sys/types.h> |
| 9341 | |
| 9342 | int |
| 9343 | main () |
| 9344 | { |
| 9345 | |
| 9346 | #if _XOPEN_SOURCE_EXTENDED- < 0 |
| 9347 | make an error |
| 9348 | #endif |
| 9349 | ; |
| 9350 | return 0; |
| 9351 | } |
| 9352 | _ACEOF |
| 9353 | rm -f conftest.$ac_objext |
| 9354 | if { (eval echo "$as_me:9354: \"$ac_compile\"") >&5 |
| 9355 | (eval $ac_compile) 2>&5 |
| 9356 | ac_status=$? |
| 9357 | echo "$as_me:9357: \$? = $ac_status" >&5 |
| 9358 | (exit $ac_status); } && |
| 9359 | { ac_try='test -s conftest.$ac_objext' |
| 9360 | { (eval echo "$as_me:9360: \"$ac_try\"") >&5 |
| 9361 | (eval $ac_try) 2>&5 |
| 9362 | ac_status=$? |
| 9363 | echo "$as_me:9363: \$? = $ac_status" >&5 |
| 9364 | (exit $ac_status); }; }; then |
| 9365 | cf_result=yes |
| 9366 | else |
| 9367 | echo "$as_me: failed program was:" >&5 |
| 9368 | cat conftest.$ac_ext >&5 |
| 9369 | cf_result=no |
| 9370 | fi |
| 9371 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 9372 | echo "$as_me:9372: result: $cf_result" >&5 |
| 9373 | echo "${ECHO_T}$cf_result" >&6 |
| 9374 | if test "$cf_result" = no ; then |
| 9375 | # perhaps we can override it - try... |
| 9376 | CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED=" |
| 9377 | fi |
| 9378 | fi |
| 9379 | |
| 9380 | fi |
| 9381 | |
| 9382 | # with_overwrite=no |
| 9383 | NCURSES_CH_T=cchar_t |
| 9384 | |
| 9385 | for ac_func in putwc btowc wctob mbtowc wctomb mblen mbrlen mbrtowc wcsrtombs mbsrtowcs wcstombs mbstowcs |
| 9386 | do |
| 9387 | as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 9388 | echo "$as_me:9388: checking for $ac_func" >&5 |
| 9389 | echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 |
| 9390 | if eval "test \"\${$as_ac_var+set}\" = set"; then |
| 9391 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9392 | else |
| 9393 | cat >conftest.$ac_ext <<_ACEOF |
| 9394 | #line 9394 "configure" |
| 9395 | #include "confdefs.h" |
| 9396 | /* System header to define __stub macros and hopefully few prototypes, |
| 9397 | which can conflict with char $ac_func (); below. */ |
| 9398 | #include <assert.h> |
| 9399 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 9400 | #ifdef __cplusplus |
| 9401 | extern "C" |
| 9402 | #endif |
| 9403 | /* We use char because int might match the return type of a gcc2 |
| 9404 | builtin and then its argument prototype would still apply. */ |
| 9405 | char $ac_func (); |
| 9406 | char (*f) (); |
| 9407 | |
| 9408 | int |
| 9409 | main () |
| 9410 | { |
| 9411 | /* The GNU C library defines this for functions which it implements |
| 9412 | to always fail with ENOSYS. Some functions are actually named |
| 9413 | something starting with __ and the normal name is an alias. */ |
| 9414 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 9415 | choke me |
| 9416 | #else |
| 9417 | f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 9418 | #endif |
| 9419 | |
| 9420 | ; |
| 9421 | return 0; |
| 9422 | } |
| 9423 | _ACEOF |
| 9424 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9425 | if { (eval echo "$as_me:9425: \"$ac_link\"") >&5 |
| 9426 | (eval $ac_link) 2>&5 |
| 9427 | ac_status=$? |
| 9428 | echo "$as_me:9428: \$? = $ac_status" >&5 |
| 9429 | (exit $ac_status); } && |
| 9430 | { ac_try='test -s conftest$ac_exeext' |
| 9431 | { (eval echo "$as_me:9431: \"$ac_try\"") >&5 |
| 9432 | (eval $ac_try) 2>&5 |
| 9433 | ac_status=$? |
| 9434 | echo "$as_me:9434: \$? = $ac_status" >&5 |
| 9435 | (exit $ac_status); }; }; then |
| 9436 | eval "$as_ac_var=yes" |
| 9437 | else |
| 9438 | echo "$as_me: failed program was:" >&5 |
| 9439 | cat conftest.$ac_ext >&5 |
| 9440 | eval "$as_ac_var=no" |
| 9441 | fi |
| 9442 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9443 | fi |
| 9444 | echo "$as_me:9444: result: `eval echo '${'$as_ac_var'}'`" >&5 |
| 9445 | echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 |
| 9446 | if test `eval echo '${'$as_ac_var'}'` = yes; then |
| 9447 | cat >>confdefs.h <<EOF |
| 9448 | #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 9449 | EOF |
| 9450 | |
| 9451 | fi |
| 9452 | done |
| 9453 | |
| 9454 | if test "x$ac_cv_func_putwc" != xyes ; then |
| 9455 | |
| 9456 | echo "$as_me:9456: checking for multibyte character support" >&5 |
| 9457 | echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6 |
| 9458 | if test "${cf_cv_utf8_lib+set}" = set; then |
| 9459 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 9460 | else |
| 9461 | |
| 9462 | cf_save_LIBS="$LIBS" |
| 9463 | cat >conftest.$ac_ext <<_ACEOF |
| 9464 | #line 9464 "configure" |
| 9465 | #include "confdefs.h" |
| 9466 | |
| 9467 | #include <stdlib.h> |
| 9468 | int |
| 9469 | main () |
| 9470 | { |
| 9471 | putwc(0,0); |
| 9472 | ; |
| 9473 | return 0; |
| 9474 | } |
| 9475 | _ACEOF |
| 9476 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9477 | if { (eval echo "$as_me:9477: \"$ac_link\"") >&5 |
| 9478 | (eval $ac_link) 2>&5 |
| 9479 | ac_status=$? |
| 9480 | echo "$as_me:9480: \$? = $ac_status" >&5 |
| 9481 | (exit $ac_status); } && |
| 9482 | { ac_try='test -s conftest$ac_exeext' |
| 9483 | { (eval echo "$as_me:9483: \"$ac_try\"") >&5 |
| 9484 | (eval $ac_try) 2>&5 |
| 9485 | ac_status=$? |
| 9486 | echo "$as_me:9486: \$? = $ac_status" >&5 |
| 9487 | (exit $ac_status); }; }; then |
| 9488 | cf_cv_utf8_lib=yes |
| 9489 | else |
| 9490 | echo "$as_me: failed program was:" >&5 |
| 9491 | cat conftest.$ac_ext >&5 |
| 9492 | |
| 9493 | # If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these |
| 9494 | # will be set on completion of the AC_TRY_LINK below. |
| 9495 | cf_cv_header_path_utf8= |
| 9496 | cf_cv_library_path_utf8= |
| 9497 | |
| 9498 | echo "${as_me:-configure}:9498: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5 |
| 9499 | |
| 9500 | cf_save_LIBS="$LIBS" |
| 9501 | |
| 9502 | cat >conftest.$ac_ext <<_ACEOF |
| 9503 | #line 9503 "configure" |
| 9504 | #include "confdefs.h" |
| 9505 | |
| 9506 | #include <libutf8.h> |
| 9507 | int |
| 9508 | main () |
| 9509 | { |
| 9510 | putwc(0,0); |
| 9511 | ; |
| 9512 | return 0; |
| 9513 | } |
| 9514 | _ACEOF |
| 9515 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9516 | if { (eval echo "$as_me:9516: \"$ac_link\"") >&5 |
| 9517 | (eval $ac_link) 2>&5 |
| 9518 | ac_status=$? |
| 9519 | echo "$as_me:9519: \$? = $ac_status" >&5 |
| 9520 | (exit $ac_status); } && |
| 9521 | { ac_try='test -s conftest$ac_exeext' |
| 9522 | { (eval echo "$as_me:9522: \"$ac_try\"") >&5 |
| 9523 | (eval $ac_try) 2>&5 |
| 9524 | ac_status=$? |
| 9525 | echo "$as_me:9525: \$? = $ac_status" >&5 |
| 9526 | (exit $ac_status); }; }; then |
| 9527 | |
| 9528 | cf_cv_find_linkage_utf8=yes |
| 9529 | cf_cv_header_path_utf8=/usr/include |
| 9530 | cf_cv_library_path_utf8=/usr/lib |
| 9531 | |
| 9532 | else |
| 9533 | echo "$as_me: failed program was:" >&5 |
| 9534 | cat conftest.$ac_ext >&5 |
| 9535 | |
| 9536 | LIBS="-lutf8 $cf_save_LIBS" |
| 9537 | |
| 9538 | cat >conftest.$ac_ext <<_ACEOF |
| 9539 | #line 9539 "configure" |
| 9540 | #include "confdefs.h" |
| 9541 | |
| 9542 | #include <libutf8.h> |
| 9543 | int |
| 9544 | main () |
| 9545 | { |
| 9546 | putwc(0,0); |
| 9547 | ; |
| 9548 | return 0; |
| 9549 | } |
| 9550 | _ACEOF |
| 9551 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9552 | if { (eval echo "$as_me:9552: \"$ac_link\"") >&5 |
| 9553 | (eval $ac_link) 2>&5 |
| 9554 | ac_status=$? |
| 9555 | echo "$as_me:9555: \$? = $ac_status" >&5 |
| 9556 | (exit $ac_status); } && |
| 9557 | { ac_try='test -s conftest$ac_exeext' |
| 9558 | { (eval echo "$as_me:9558: \"$ac_try\"") >&5 |
| 9559 | (eval $ac_try) 2>&5 |
| 9560 | ac_status=$? |
| 9561 | echo "$as_me:9561: \$? = $ac_status" >&5 |
| 9562 | (exit $ac_status); }; }; then |
| 9563 | |
| 9564 | cf_cv_find_linkage_utf8=yes |
| 9565 | cf_cv_header_path_utf8=/usr/include |
| 9566 | cf_cv_library_path_utf8=/usr/lib |
| 9567 | cf_cv_library_file_utf8="-lutf8" |
| 9568 | |
| 9569 | else |
| 9570 | echo "$as_me: failed program was:" >&5 |
| 9571 | cat conftest.$ac_ext >&5 |
| 9572 | |
| 9573 | cf_cv_find_linkage_utf8=no |
| 9574 | LIBS="$cf_save_LIBS" |
| 9575 | |
| 9576 | test -n "$verbose" && echo " find linkage for utf8 library" 1>&6 |
| 9577 | |
| 9578 | echo "${as_me:-configure}:9578: testing find linkage for utf8 library ..." 1>&5 |
| 9579 | |
| 9580 | echo "${as_me:-configure}:9580: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5 |
| 9581 | |
| 9582 | cf_save_CPPFLAGS="$CPPFLAGS" |
| 9583 | cf_test_CPPFLAGS="$CPPFLAGS" |
| 9584 | |
| 9585 | cf_search= |
| 9586 | |
| 9587 | # collect the current set of include-directories from compiler flags |
| 9588 | cf_header_path_list="" |
| 9589 | if test -n "${CFLAGS}${CPPFLAGS}" ; then |
| 9590 | for cf_header_path in $CPPFLAGS $CFLAGS |
| 9591 | do |
| 9592 | case $cf_header_path in |
| 9593 | (-I*) |
| 9594 | cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'` |
| 9595 | |
| 9596 | test "x$cf_header_path" != "xNONE" && \ |
| 9597 | test -d "$cf_header_path" && \ |
| 9598 | { |
| 9599 | test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path" |
| 9600 | test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include" |
| 9601 | test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8" |
| 9602 | test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include" |
| 9603 | test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include" |
| 9604 | test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8" |
| 9605 | } |
| 9606 | |
| 9607 | cf_header_path_list="$cf_header_path_list $cf_search" |
| 9608 | ;; |
| 9609 | esac |
| 9610 | done |
| 9611 | fi |
| 9612 | |
| 9613 | # add the variations for the package we are looking for |
| 9614 | |
| 9615 | cf_search= |
| 9616 | |
| 9617 | test "x$prefix" != "xNONE" && \ |
| 9618 | test -d "$prefix" && \ |
| 9619 | { |
| 9620 | test -n "$verbose" && echo " ... testing for include-directories under $prefix" |
| 9621 | test -d $prefix/include && cf_search="$cf_search $prefix/include" |
| 9622 | test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8" |
| 9623 | test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include" |
| 9624 | test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include" |
| 9625 | test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8" |
| 9626 | } |
| 9627 | |
| 9628 | for cf_subdir_prefix in \ |
| 9629 | /usr \ |
| 9630 | /usr/local \ |
| 9631 | /usr/pkg \ |
| 9632 | /opt \ |
| 9633 | /opt/local \ |
| 9634 | $HOME |
| 9635 | do |
| 9636 | |
| 9637 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 9638 | test -d "$cf_subdir_prefix" && \ |
| 9639 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 9640 | test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix" |
| 9641 | test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include" |
| 9642 | test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8" |
| 9643 | test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include" |
| 9644 | test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include" |
| 9645 | test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8" |
| 9646 | } |
| 9647 | |
| 9648 | done |
| 9649 | |
| 9650 | test "$includedir" != NONE && \ |
| 9651 | test "$includedir" != "/usr/include" && \ |
| 9652 | test -d "$includedir" && { |
| 9653 | test -d $includedir && cf_search="$cf_search $includedir" |
| 9654 | test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8" |
| 9655 | } |
| 9656 | |
| 9657 | test "$oldincludedir" != NONE && \ |
| 9658 | test "$oldincludedir" != "/usr/include" && \ |
| 9659 | test -d "$oldincludedir" && { |
| 9660 | test -d $oldincludedir && cf_search="$cf_search $oldincludedir" |
| 9661 | test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8" |
| 9662 | } |
| 9663 | |
| 9664 | cf_search="$cf_search $cf_header_path_list" |
| 9665 | |
| 9666 | for cf_cv_header_path_utf8 in $cf_search |
| 9667 | do |
| 9668 | if test -d $cf_cv_header_path_utf8 ; then |
| 9669 | test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6 |
| 9670 | |
| 9671 | echo "${as_me:-configure}:9671: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5 |
| 9672 | |
| 9673 | CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8" |
| 9674 | cat >conftest.$ac_ext <<_ACEOF |
| 9675 | #line 9675 "configure" |
| 9676 | #include "confdefs.h" |
| 9677 | |
| 9678 | #include <libutf8.h> |
| 9679 | int |
| 9680 | main () |
| 9681 | { |
| 9682 | putwc(0,0); |
| 9683 | ; |
| 9684 | return 0; |
| 9685 | } |
| 9686 | _ACEOF |
| 9687 | rm -f conftest.$ac_objext |
| 9688 | if { (eval echo "$as_me:9688: \"$ac_compile\"") >&5 |
| 9689 | (eval $ac_compile) 2>&5 |
| 9690 | ac_status=$? |
| 9691 | echo "$as_me:9691: \$? = $ac_status" >&5 |
| 9692 | (exit $ac_status); } && |
| 9693 | { ac_try='test -s conftest.$ac_objext' |
| 9694 | { (eval echo "$as_me:9694: \"$ac_try\"") >&5 |
| 9695 | (eval $ac_try) 2>&5 |
| 9696 | ac_status=$? |
| 9697 | echo "$as_me:9697: \$? = $ac_status" >&5 |
| 9698 | (exit $ac_status); }; }; then |
| 9699 | |
| 9700 | test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6 |
| 9701 | |
| 9702 | echo "${as_me:-configure}:9702: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5 |
| 9703 | |
| 9704 | cf_cv_find_linkage_utf8=maybe |
| 9705 | cf_test_CPPFLAGS="$CPPFLAGS" |
| 9706 | break |
| 9707 | else |
| 9708 | echo "$as_me: failed program was:" >&5 |
| 9709 | cat conftest.$ac_ext >&5 |
| 9710 | |
| 9711 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 9712 | |
| 9713 | fi |
| 9714 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 9715 | fi |
| 9716 | done |
| 9717 | |
| 9718 | if test "$cf_cv_find_linkage_utf8" = maybe ; then |
| 9719 | |
| 9720 | echo "${as_me:-configure}:9720: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5 |
| 9721 | |
| 9722 | cf_save_LIBS="$LIBS" |
| 9723 | cf_save_LDFLAGS="$LDFLAGS" |
| 9724 | |
| 9725 | if test "$cf_cv_find_linkage_utf8" != yes ; then |
| 9726 | |
| 9727 | cf_search= |
| 9728 | cf_library_path_list="" |
| 9729 | if test -n "${LDFLAGS}${LIBS}" ; then |
| 9730 | for cf_library_path in $LDFLAGS $LIBS |
| 9731 | do |
| 9732 | case $cf_library_path in |
| 9733 | (-L*) |
| 9734 | cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'` |
| 9735 | |
| 9736 | test "x$cf_library_path" != "xNONE" && \ |
| 9737 | test -d "$cf_library_path" && \ |
| 9738 | { |
| 9739 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path" |
| 9740 | test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib" |
| 9741 | test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8" |
| 9742 | test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib" |
| 9743 | test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib" |
| 9744 | test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8" |
| 9745 | } |
| 9746 | |
| 9747 | cf_library_path_list="$cf_library_path_list $cf_search" |
| 9748 | ;; |
| 9749 | esac |
| 9750 | done |
| 9751 | fi |
| 9752 | |
| 9753 | cf_search= |
| 9754 | |
| 9755 | test "x$prefix" != "xNONE" && \ |
| 9756 | test -d "$prefix" && \ |
| 9757 | { |
| 9758 | test -n "$verbose" && echo " ... testing for lib-directories under $prefix" |
| 9759 | test -d $prefix/lib && cf_search="$cf_search $prefix/lib" |
| 9760 | test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8" |
| 9761 | test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib" |
| 9762 | test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib" |
| 9763 | test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8" |
| 9764 | } |
| 9765 | |
| 9766 | for cf_subdir_prefix in \ |
| 9767 | /usr \ |
| 9768 | /usr/local \ |
| 9769 | /usr/pkg \ |
| 9770 | /opt \ |
| 9771 | /opt/local \ |
| 9772 | $HOME |
| 9773 | do |
| 9774 | |
| 9775 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 9776 | test -d "$cf_subdir_prefix" && \ |
| 9777 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 9778 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix" |
| 9779 | test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib" |
| 9780 | test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8" |
| 9781 | test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib" |
| 9782 | test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib" |
| 9783 | test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8" |
| 9784 | } |
| 9785 | |
| 9786 | done |
| 9787 | |
| 9788 | cf_search="$cf_library_path_list $cf_search" |
| 9789 | |
| 9790 | for cf_cv_library_path_utf8 in $cf_search |
| 9791 | do |
| 9792 | if test -d $cf_cv_library_path_utf8 ; then |
| 9793 | test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6 |
| 9794 | |
| 9795 | echo "${as_me:-configure}:9795: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5 |
| 9796 | |
| 9797 | CPPFLAGS="$cf_test_CPPFLAGS" |
| 9798 | LIBS="-lutf8 $cf_save_LIBS" |
| 9799 | LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8" |
| 9800 | cat >conftest.$ac_ext <<_ACEOF |
| 9801 | #line 9801 "configure" |
| 9802 | #include "confdefs.h" |
| 9803 | |
| 9804 | #include <libutf8.h> |
| 9805 | int |
| 9806 | main () |
| 9807 | { |
| 9808 | putwc(0,0); |
| 9809 | ; |
| 9810 | return 0; |
| 9811 | } |
| 9812 | _ACEOF |
| 9813 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 9814 | if { (eval echo "$as_me:9814: \"$ac_link\"") >&5 |
| 9815 | (eval $ac_link) 2>&5 |
| 9816 | ac_status=$? |
| 9817 | echo "$as_me:9817: \$? = $ac_status" >&5 |
| 9818 | (exit $ac_status); } && |
| 9819 | { ac_try='test -s conftest$ac_exeext' |
| 9820 | { (eval echo "$as_me:9820: \"$ac_try\"") >&5 |
| 9821 | (eval $ac_try) 2>&5 |
| 9822 | ac_status=$? |
| 9823 | echo "$as_me:9823: \$? = $ac_status" >&5 |
| 9824 | (exit $ac_status); }; }; then |
| 9825 | |
| 9826 | test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6 |
| 9827 | |
| 9828 | echo "${as_me:-configure}:9828: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5 |
| 9829 | |
| 9830 | cf_cv_find_linkage_utf8=yes |
| 9831 | cf_cv_library_file_utf8="-lutf8" |
| 9832 | break |
| 9833 | else |
| 9834 | echo "$as_me: failed program was:" >&5 |
| 9835 | cat conftest.$ac_ext >&5 |
| 9836 | |
| 9837 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 9838 | LIBS="$cf_save_LIBS" |
| 9839 | LDFLAGS="$cf_save_LDFLAGS" |
| 9840 | |
| 9841 | fi |
| 9842 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9843 | fi |
| 9844 | done |
| 9845 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 9846 | LDFLAGS="$cf_save_LDFLAGS" |
| 9847 | fi |
| 9848 | |
| 9849 | else |
| 9850 | cf_cv_find_linkage_utf8=no |
| 9851 | fi |
| 9852 | |
| 9853 | fi |
| 9854 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9855 | |
| 9856 | fi |
| 9857 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9858 | |
| 9859 | LIBS="$cf_save_LIBS" |
| 9860 | |
| 9861 | if test "$cf_cv_find_linkage_utf8" = yes ; then |
| 9862 | cf_cv_utf8_lib=add-on |
| 9863 | else |
| 9864 | cf_cv_utf8_lib=no |
| 9865 | fi |
| 9866 | |
| 9867 | fi |
| 9868 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 9869 | fi |
| 9870 | echo "$as_me:9870: result: $cf_cv_utf8_lib" >&5 |
| 9871 | echo "${ECHO_T}$cf_cv_utf8_lib" >&6 |
| 9872 | |
| 9873 | # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between |
| 9874 | # ncurses/ncursesw: |
| 9875 | if test "$cf_cv_utf8_lib" = "add-on" ; then |
| 9876 | |
| 9877 | cat >>confdefs.h <<\EOF |
| 9878 | #define HAVE_LIBUTF8_H 1 |
| 9879 | EOF |
| 9880 | |
| 9881 | if test -n "$cf_cv_header_path_utf8" ; then |
| 9882 | for cf_add_incdir in $cf_cv_header_path_utf8 |
| 9883 | do |
| 9884 | while test $cf_add_incdir != /usr/include |
| 9885 | do |
| 9886 | if test -d $cf_add_incdir |
| 9887 | then |
| 9888 | cf_have_incdir=no |
| 9889 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 9890 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 9891 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 9892 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 9893 | cf_have_incdir=yes; break |
| 9894 | fi |
| 9895 | done |
| 9896 | fi |
| 9897 | |
| 9898 | if test "$cf_have_incdir" = no ; then |
| 9899 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 9900 | if test "$GCC" = yes |
| 9901 | then |
| 9902 | cf_save_CPPFLAGS=$CPPFLAGS |
| 9903 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 9904 | cat >conftest.$ac_ext <<_ACEOF |
| 9905 | #line 9905 "configure" |
| 9906 | #include "confdefs.h" |
| 9907 | #include <stdio.h> |
| 9908 | int |
| 9909 | main () |
| 9910 | { |
| 9911 | printf("Hello") |
| 9912 | ; |
| 9913 | return 0; |
| 9914 | } |
| 9915 | _ACEOF |
| 9916 | rm -f conftest.$ac_objext |
| 9917 | if { (eval echo "$as_me:9917: \"$ac_compile\"") >&5 |
| 9918 | (eval $ac_compile) 2>&5 |
| 9919 | ac_status=$? |
| 9920 | echo "$as_me:9920: \$? = $ac_status" >&5 |
| 9921 | (exit $ac_status); } && |
| 9922 | { ac_try='test -s conftest.$ac_objext' |
| 9923 | { (eval echo "$as_me:9923: \"$ac_try\"") >&5 |
| 9924 | (eval $ac_try) 2>&5 |
| 9925 | ac_status=$? |
| 9926 | echo "$as_me:9926: \$? = $ac_status" >&5 |
| 9927 | (exit $ac_status); }; }; then |
| 9928 | : |
| 9929 | else |
| 9930 | echo "$as_me: failed program was:" >&5 |
| 9931 | cat conftest.$ac_ext >&5 |
| 9932 | cf_have_incdir=yes |
| 9933 | fi |
| 9934 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 9935 | CPPFLAGS=$cf_save_CPPFLAGS |
| 9936 | fi |
| 9937 | fi |
| 9938 | fi |
| 9939 | |
| 9940 | if test "$cf_have_incdir" = no ; then |
| 9941 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 9942 | |
| 9943 | echo "${as_me:-configure}:9943: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 9944 | |
| 9945 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 9946 | |
| 9947 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 9948 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 9949 | cf_add_incdir="$cf_top_incdir" |
| 9950 | else |
| 9951 | break |
| 9952 | fi |
| 9953 | else |
| 9954 | break |
| 9955 | fi |
| 9956 | done |
| 9957 | done |
| 9958 | fi |
| 9959 | |
| 9960 | if test -n "$cf_cv_library_path_utf8" ; then |
| 9961 | for cf_add_libdir in $cf_cv_library_path_utf8 |
| 9962 | do |
| 9963 | if test $cf_add_libdir = /usr/lib ; then |
| 9964 | : |
| 9965 | elif test -d $cf_add_libdir |
| 9966 | then |
| 9967 | cf_have_libdir=no |
| 9968 | if test -n "$LDFLAGS$LIBS" ; then |
| 9969 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 9970 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 9971 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 9972 | cf_have_libdir=yes; break |
| 9973 | fi |
| 9974 | done |
| 9975 | fi |
| 9976 | if test "$cf_have_libdir" = no ; then |
| 9977 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 9978 | |
| 9979 | echo "${as_me:-configure}:9979: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 9980 | |
| 9981 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 9982 | fi |
| 9983 | fi |
| 9984 | done |
| 9985 | fi |
| 9986 | |
| 9987 | cf_add_libs="$cf_cv_library_file_utf8" |
| 9988 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 9989 | for cf_add_1lib in $LIBS |
| 9990 | do |
| 9991 | for cf_add_2lib in $cf_add_libs |
| 9992 | do |
| 9993 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 9994 | then |
| 9995 | cf_add_1lib= |
| 9996 | break |
| 9997 | fi |
| 9998 | done |
| 9999 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 10000 | done |
| 10001 | LIBS="$cf_add_libs" |
| 10002 | |
| 10003 | fi |
| 10004 | |
| 10005 | if test "$cf_cv_utf8_lib" != no ; then |
| 10006 | NCURSES_LIBUTF8=1 |
| 10007 | fi |
| 10008 | fi |
| 10009 | |
| 10010 | # This is needed on Tru64 5.0 to declare mbstate_t |
| 10011 | echo "$as_me:10011: checking if we must include wchar.h to declare mbstate_t" >&5 |
| 10012 | echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6 |
| 10013 | if test "${cf_cv_mbstate_t+set}" = set; then |
| 10014 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10015 | else |
| 10016 | |
| 10017 | cat >conftest.$ac_ext <<_ACEOF |
| 10018 | #line 10018 "configure" |
| 10019 | #include "confdefs.h" |
| 10020 | |
| 10021 | #include <stdlib.h> |
| 10022 | #include <stdarg.h> |
| 10023 | #include <stdio.h> |
| 10024 | #ifdef HAVE_LIBUTF8_H |
| 10025 | #include <libutf8.h> |
| 10026 | #endif |
| 10027 | int |
| 10028 | main () |
| 10029 | { |
| 10030 | mbstate_t state |
| 10031 | ; |
| 10032 | return 0; |
| 10033 | } |
| 10034 | _ACEOF |
| 10035 | rm -f conftest.$ac_objext |
| 10036 | if { (eval echo "$as_me:10036: \"$ac_compile\"") >&5 |
| 10037 | (eval $ac_compile) 2>&5 |
| 10038 | ac_status=$? |
| 10039 | echo "$as_me:10039: \$? = $ac_status" >&5 |
| 10040 | (exit $ac_status); } && |
| 10041 | { ac_try='test -s conftest.$ac_objext' |
| 10042 | { (eval echo "$as_me:10042: \"$ac_try\"") >&5 |
| 10043 | (eval $ac_try) 2>&5 |
| 10044 | ac_status=$? |
| 10045 | echo "$as_me:10045: \$? = $ac_status" >&5 |
| 10046 | (exit $ac_status); }; }; then |
| 10047 | cf_cv_mbstate_t=no |
| 10048 | else |
| 10049 | echo "$as_me: failed program was:" >&5 |
| 10050 | cat conftest.$ac_ext >&5 |
| 10051 | cat >conftest.$ac_ext <<_ACEOF |
| 10052 | #line 10052 "configure" |
| 10053 | #include "confdefs.h" |
| 10054 | |
| 10055 | #include <stdlib.h> |
| 10056 | #include <stdarg.h> |
| 10057 | #include <stdio.h> |
| 10058 | #include <wchar.h> |
| 10059 | #ifdef HAVE_LIBUTF8_H |
| 10060 | #include <libutf8.h> |
| 10061 | #endif |
| 10062 | int |
| 10063 | main () |
| 10064 | { |
| 10065 | mbstate_t value |
| 10066 | ; |
| 10067 | return 0; |
| 10068 | } |
| 10069 | _ACEOF |
| 10070 | rm -f conftest.$ac_objext |
| 10071 | if { (eval echo "$as_me:10071: \"$ac_compile\"") >&5 |
| 10072 | (eval $ac_compile) 2>&5 |
| 10073 | ac_status=$? |
| 10074 | echo "$as_me:10074: \$? = $ac_status" >&5 |
| 10075 | (exit $ac_status); } && |
| 10076 | { ac_try='test -s conftest.$ac_objext' |
| 10077 | { (eval echo "$as_me:10077: \"$ac_try\"") >&5 |
| 10078 | (eval $ac_try) 2>&5 |
| 10079 | ac_status=$? |
| 10080 | echo "$as_me:10080: \$? = $ac_status" >&5 |
| 10081 | (exit $ac_status); }; }; then |
| 10082 | cf_cv_mbstate_t=yes |
| 10083 | else |
| 10084 | echo "$as_me: failed program was:" >&5 |
| 10085 | cat conftest.$ac_ext >&5 |
| 10086 | cf_cv_mbstate_t=unknown |
| 10087 | fi |
| 10088 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10089 | fi |
| 10090 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10091 | fi |
| 10092 | echo "$as_me:10092: result: $cf_cv_mbstate_t" >&5 |
| 10093 | echo "${ECHO_T}$cf_cv_mbstate_t" >&6 |
| 10094 | |
| 10095 | if test "$cf_cv_mbstate_t" = yes ; then |
| 10096 | |
| 10097 | cat >>confdefs.h <<\EOF |
| 10098 | #define NEED_WCHAR_H 1 |
| 10099 | EOF |
| 10100 | |
| 10101 | NEED_WCHAR_H=1 |
| 10102 | fi |
| 10103 | |
| 10104 | # if we do not find mbstate_t in either place, use substitution to provide a fallback. |
| 10105 | if test "$cf_cv_mbstate_t" = unknown ; then |
| 10106 | NCURSES_MBSTATE_T=1 |
| 10107 | fi |
| 10108 | |
| 10109 | # This is needed on Tru64 5.0 to declare wchar_t |
| 10110 | echo "$as_me:10110: checking if we must include wchar.h to declare wchar_t" >&5 |
| 10111 | echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6 |
| 10112 | if test "${cf_cv_wchar_t+set}" = set; then |
| 10113 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10114 | else |
| 10115 | |
| 10116 | cat >conftest.$ac_ext <<_ACEOF |
| 10117 | #line 10117 "configure" |
| 10118 | #include "confdefs.h" |
| 10119 | |
| 10120 | #include <stdlib.h> |
| 10121 | #include <stdarg.h> |
| 10122 | #include <stdio.h> |
| 10123 | #ifdef HAVE_LIBUTF8_H |
| 10124 | #include <libutf8.h> |
| 10125 | #endif |
| 10126 | int |
| 10127 | main () |
| 10128 | { |
| 10129 | wchar_t state |
| 10130 | ; |
| 10131 | return 0; |
| 10132 | } |
| 10133 | _ACEOF |
| 10134 | rm -f conftest.$ac_objext |
| 10135 | if { (eval echo "$as_me:10135: \"$ac_compile\"") >&5 |
| 10136 | (eval $ac_compile) 2>&5 |
| 10137 | ac_status=$? |
| 10138 | echo "$as_me:10138: \$? = $ac_status" >&5 |
| 10139 | (exit $ac_status); } && |
| 10140 | { ac_try='test -s conftest.$ac_objext' |
| 10141 | { (eval echo "$as_me:10141: \"$ac_try\"") >&5 |
| 10142 | (eval $ac_try) 2>&5 |
| 10143 | ac_status=$? |
| 10144 | echo "$as_me:10144: \$? = $ac_status" >&5 |
| 10145 | (exit $ac_status); }; }; then |
| 10146 | cf_cv_wchar_t=no |
| 10147 | else |
| 10148 | echo "$as_me: failed program was:" >&5 |
| 10149 | cat conftest.$ac_ext >&5 |
| 10150 | cat >conftest.$ac_ext <<_ACEOF |
| 10151 | #line 10151 "configure" |
| 10152 | #include "confdefs.h" |
| 10153 | |
| 10154 | #include <stdlib.h> |
| 10155 | #include <stdarg.h> |
| 10156 | #include <stdio.h> |
| 10157 | #include <wchar.h> |
| 10158 | #ifdef HAVE_LIBUTF8_H |
| 10159 | #include <libutf8.h> |
| 10160 | #endif |
| 10161 | int |
| 10162 | main () |
| 10163 | { |
| 10164 | wchar_t value |
| 10165 | ; |
| 10166 | return 0; |
| 10167 | } |
| 10168 | _ACEOF |
| 10169 | rm -f conftest.$ac_objext |
| 10170 | if { (eval echo "$as_me:10170: \"$ac_compile\"") >&5 |
| 10171 | (eval $ac_compile) 2>&5 |
| 10172 | ac_status=$? |
| 10173 | echo "$as_me:10173: \$? = $ac_status" >&5 |
| 10174 | (exit $ac_status); } && |
| 10175 | { ac_try='test -s conftest.$ac_objext' |
| 10176 | { (eval echo "$as_me:10176: \"$ac_try\"") >&5 |
| 10177 | (eval $ac_try) 2>&5 |
| 10178 | ac_status=$? |
| 10179 | echo "$as_me:10179: \$? = $ac_status" >&5 |
| 10180 | (exit $ac_status); }; }; then |
| 10181 | cf_cv_wchar_t=yes |
| 10182 | else |
| 10183 | echo "$as_me: failed program was:" >&5 |
| 10184 | cat conftest.$ac_ext >&5 |
| 10185 | cf_cv_wchar_t=unknown |
| 10186 | fi |
| 10187 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10188 | fi |
| 10189 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10190 | fi |
| 10191 | echo "$as_me:10191: result: $cf_cv_wchar_t" >&5 |
| 10192 | echo "${ECHO_T}$cf_cv_wchar_t" >&6 |
| 10193 | |
| 10194 | if test "$cf_cv_wchar_t" = yes ; then |
| 10195 | |
| 10196 | cat >>confdefs.h <<\EOF |
| 10197 | #define NEED_WCHAR_H 1 |
| 10198 | EOF |
| 10199 | |
| 10200 | NEED_WCHAR_H=1 |
| 10201 | fi |
| 10202 | |
| 10203 | # if we do not find wchar_t in either place, use substitution to provide a fallback. |
| 10204 | if test "$cf_cv_wchar_t" = unknown ; then |
| 10205 | NCURSES_WCHAR_T=1 |
| 10206 | fi |
| 10207 | |
| 10208 | # if we find wchar_t in either place, use substitution to provide a fallback. |
| 10209 | if test "$cf_cv_wchar_t" != unknown ; then |
| 10210 | NCURSES_OK_WCHAR_T=1 |
| 10211 | fi |
| 10212 | |
| 10213 | # This is needed on Tru64 5.0 to declare wint_t |
| 10214 | echo "$as_me:10214: checking if we must include wchar.h to declare wint_t" >&5 |
| 10215 | echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6 |
| 10216 | if test "${cf_cv_wint_t+set}" = set; then |
| 10217 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10218 | else |
| 10219 | |
| 10220 | cat >conftest.$ac_ext <<_ACEOF |
| 10221 | #line 10221 "configure" |
| 10222 | #include "confdefs.h" |
| 10223 | |
| 10224 | #include <stdlib.h> |
| 10225 | #include <stdarg.h> |
| 10226 | #include <stdio.h> |
| 10227 | #ifdef HAVE_LIBUTF8_H |
| 10228 | #include <libutf8.h> |
| 10229 | #endif |
| 10230 | int |
| 10231 | main () |
| 10232 | { |
| 10233 | wint_t state |
| 10234 | ; |
| 10235 | return 0; |
| 10236 | } |
| 10237 | _ACEOF |
| 10238 | rm -f conftest.$ac_objext |
| 10239 | if { (eval echo "$as_me:10239: \"$ac_compile\"") >&5 |
| 10240 | (eval $ac_compile) 2>&5 |
| 10241 | ac_status=$? |
| 10242 | echo "$as_me:10242: \$? = $ac_status" >&5 |
| 10243 | (exit $ac_status); } && |
| 10244 | { ac_try='test -s conftest.$ac_objext' |
| 10245 | { (eval echo "$as_me:10245: \"$ac_try\"") >&5 |
| 10246 | (eval $ac_try) 2>&5 |
| 10247 | ac_status=$? |
| 10248 | echo "$as_me:10248: \$? = $ac_status" >&5 |
| 10249 | (exit $ac_status); }; }; then |
| 10250 | cf_cv_wint_t=no |
| 10251 | else |
| 10252 | echo "$as_me: failed program was:" >&5 |
| 10253 | cat conftest.$ac_ext >&5 |
| 10254 | cat >conftest.$ac_ext <<_ACEOF |
| 10255 | #line 10255 "configure" |
| 10256 | #include "confdefs.h" |
| 10257 | |
| 10258 | #include <stdlib.h> |
| 10259 | #include <stdarg.h> |
| 10260 | #include <stdio.h> |
| 10261 | #include <wchar.h> |
| 10262 | #ifdef HAVE_LIBUTF8_H |
| 10263 | #include <libutf8.h> |
| 10264 | #endif |
| 10265 | int |
| 10266 | main () |
| 10267 | { |
| 10268 | wint_t value |
| 10269 | ; |
| 10270 | return 0; |
| 10271 | } |
| 10272 | _ACEOF |
| 10273 | rm -f conftest.$ac_objext |
| 10274 | if { (eval echo "$as_me:10274: \"$ac_compile\"") >&5 |
| 10275 | (eval $ac_compile) 2>&5 |
| 10276 | ac_status=$? |
| 10277 | echo "$as_me:10277: \$? = $ac_status" >&5 |
| 10278 | (exit $ac_status); } && |
| 10279 | { ac_try='test -s conftest.$ac_objext' |
| 10280 | { (eval echo "$as_me:10280: \"$ac_try\"") >&5 |
| 10281 | (eval $ac_try) 2>&5 |
| 10282 | ac_status=$? |
| 10283 | echo "$as_me:10283: \$? = $ac_status" >&5 |
| 10284 | (exit $ac_status); }; }; then |
| 10285 | cf_cv_wint_t=yes |
| 10286 | else |
| 10287 | echo "$as_me: failed program was:" >&5 |
| 10288 | cat conftest.$ac_ext >&5 |
| 10289 | cf_cv_wint_t=unknown |
| 10290 | fi |
| 10291 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10292 | fi |
| 10293 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10294 | fi |
| 10295 | echo "$as_me:10295: result: $cf_cv_wint_t" >&5 |
| 10296 | echo "${ECHO_T}$cf_cv_wint_t" >&6 |
| 10297 | |
| 10298 | if test "$cf_cv_wint_t" = yes ; then |
| 10299 | |
| 10300 | cat >>confdefs.h <<\EOF |
| 10301 | #define NEED_WCHAR_H 1 |
| 10302 | EOF |
| 10303 | |
| 10304 | NEED_WCHAR_H=1 |
| 10305 | fi |
| 10306 | |
| 10307 | # if we do not find wint_t in either place, use substitution to provide a fallback. |
| 10308 | if test "$cf_cv_wint_t" = unknown ; then |
| 10309 | NCURSES_WINT_T=1 |
| 10310 | fi |
| 10311 | |
| 10312 | # if we find wint_t in either place, use substitution to provide a fallback. |
| 10313 | if test "$cf_cv_wint_t" != unknown ; then |
| 10314 | NCURSES_OK_WINT_T=1 |
| 10315 | fi |
| 10316 | |
| 10317 | if test "$NCURSES_MBSTATE_T" != 0; then |
| 10318 | |
| 10319 | cat >>confdefs.h <<\EOF |
| 10320 | #define NEED_MBSTATE_T_DEF 1 |
| 10321 | EOF |
| 10322 | |
| 10323 | fi |
| 10324 | fi |
| 10325 | |
| 10326 | ### use option --disable-lp64 to allow long chtype |
| 10327 | echo "$as_me:10327: checking whether to enable _LP64 definition in curses.h" >&5 |
| 10328 | echo $ECHO_N "checking whether to enable _LP64 definition in curses.h... $ECHO_C" >&6 |
| 10329 | |
| 10330 | # Check whether --enable-lp64 or --disable-lp64 was given. |
| 10331 | if test "${enable_lp64+set}" = set; then |
| 10332 | enableval="$enable_lp64" |
| 10333 | with_lp64=$enableval |
| 10334 | else |
| 10335 | with_lp64=$cf_dft_with_lp64 |
| 10336 | fi; |
| 10337 | echo "$as_me:10337: result: $with_lp64" >&5 |
| 10338 | echo "${ECHO_T}$with_lp64" >&6 |
| 10339 | |
| 10340 | if test "x$with_lp64" = xyes ; then |
| 10341 | cf_cv_enable_lp64=1 |
| 10342 | else |
| 10343 | cf_cv_enable_lp64=0 |
| 10344 | fi |
| 10345 | |
| 10346 | # Check whether --enable-largefile or --disable-largefile was given. |
| 10347 | if test "${enable_largefile+set}" = set; then |
| 10348 | enableval="$enable_largefile" |
| 10349 | |
| 10350 | fi; |
| 10351 | if test "$enable_largefile" != no; then |
| 10352 | |
| 10353 | echo "$as_me:10353: checking for special C compiler options needed for large files" >&5 |
| 10354 | echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6 |
| 10355 | if test "${ac_cv_sys_largefile_CC+set}" = set; then |
| 10356 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10357 | else |
| 10358 | ac_cv_sys_largefile_CC=no |
| 10359 | if test "$GCC" != yes; then |
| 10360 | ac_save_CC=$CC |
| 10361 | while :; do |
| 10362 | # IRIX 6.2 and later do not support large files by default, |
| 10363 | # so use the C compiler's -n32 option if that helps. |
| 10364 | cat >conftest.$ac_ext <<_ACEOF |
| 10365 | #line 10365 "configure" |
| 10366 | #include "confdefs.h" |
| 10367 | #include <sys/types.h> |
| 10368 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 10369 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 10370 | since some C++ compilers masquerading as C compilers |
| 10371 | incorrectly reject 9223372036854775807. */ |
| 10372 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 10373 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 10374 | && LARGE_OFF_T % 2147483647 == 1) |
| 10375 | ? 1 : -1]; |
| 10376 | int |
| 10377 | main () |
| 10378 | { |
| 10379 | |
| 10380 | ; |
| 10381 | return 0; |
| 10382 | } |
| 10383 | _ACEOF |
| 10384 | rm -f conftest.$ac_objext |
| 10385 | if { (eval echo "$as_me:10385: \"$ac_compile\"") >&5 |
| 10386 | (eval $ac_compile) 2>&5 |
| 10387 | ac_status=$? |
| 10388 | echo "$as_me:10388: \$? = $ac_status" >&5 |
| 10389 | (exit $ac_status); } && |
| 10390 | { ac_try='test -s conftest.$ac_objext' |
| 10391 | { (eval echo "$as_me:10391: \"$ac_try\"") >&5 |
| 10392 | (eval $ac_try) 2>&5 |
| 10393 | ac_status=$? |
| 10394 | echo "$as_me:10394: \$? = $ac_status" >&5 |
| 10395 | (exit $ac_status); }; }; then |
| 10396 | break |
| 10397 | else |
| 10398 | echo "$as_me: failed program was:" >&5 |
| 10399 | cat conftest.$ac_ext >&5 |
| 10400 | fi |
| 10401 | rm -f conftest.$ac_objext |
| 10402 | CC="$CC -n32" |
| 10403 | rm -f conftest.$ac_objext |
| 10404 | if { (eval echo "$as_me:10404: \"$ac_compile\"") >&5 |
| 10405 | (eval $ac_compile) 2>&5 |
| 10406 | ac_status=$? |
| 10407 | echo "$as_me:10407: \$? = $ac_status" >&5 |
| 10408 | (exit $ac_status); } && |
| 10409 | { ac_try='test -s conftest.$ac_objext' |
| 10410 | { (eval echo "$as_me:10410: \"$ac_try\"") >&5 |
| 10411 | (eval $ac_try) 2>&5 |
| 10412 | ac_status=$? |
| 10413 | echo "$as_me:10413: \$? = $ac_status" >&5 |
| 10414 | (exit $ac_status); }; }; then |
| 10415 | ac_cv_sys_largefile_CC=' -n32'; break |
| 10416 | else |
| 10417 | echo "$as_me: failed program was:" >&5 |
| 10418 | cat conftest.$ac_ext >&5 |
| 10419 | fi |
| 10420 | rm -f conftest.$ac_objext |
| 10421 | break |
| 10422 | done |
| 10423 | CC=$ac_save_CC |
| 10424 | rm -f conftest.$ac_ext |
| 10425 | fi |
| 10426 | fi |
| 10427 | echo "$as_me:10427: result: $ac_cv_sys_largefile_CC" >&5 |
| 10428 | echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6 |
| 10429 | if test "$ac_cv_sys_largefile_CC" != no; then |
| 10430 | CC=$CC$ac_cv_sys_largefile_CC |
| 10431 | fi |
| 10432 | |
| 10433 | echo "$as_me:10433: checking for _FILE_OFFSET_BITS value needed for large files" >&5 |
| 10434 | echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6 |
| 10435 | if test "${ac_cv_sys_file_offset_bits+set}" = set; then |
| 10436 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10437 | else |
| 10438 | while :; do |
| 10439 | ac_cv_sys_file_offset_bits=no |
| 10440 | cat >conftest.$ac_ext <<_ACEOF |
| 10441 | #line 10441 "configure" |
| 10442 | #include "confdefs.h" |
| 10443 | #include <sys/types.h> |
| 10444 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 10445 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 10446 | since some C++ compilers masquerading as C compilers |
| 10447 | incorrectly reject 9223372036854775807. */ |
| 10448 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 10449 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 10450 | && LARGE_OFF_T % 2147483647 == 1) |
| 10451 | ? 1 : -1]; |
| 10452 | int |
| 10453 | main () |
| 10454 | { |
| 10455 | |
| 10456 | ; |
| 10457 | return 0; |
| 10458 | } |
| 10459 | _ACEOF |
| 10460 | rm -f conftest.$ac_objext |
| 10461 | if { (eval echo "$as_me:10461: \"$ac_compile\"") >&5 |
| 10462 | (eval $ac_compile) 2>&5 |
| 10463 | ac_status=$? |
| 10464 | echo "$as_me:10464: \$? = $ac_status" >&5 |
| 10465 | (exit $ac_status); } && |
| 10466 | { ac_try='test -s conftest.$ac_objext' |
| 10467 | { (eval echo "$as_me:10467: \"$ac_try\"") >&5 |
| 10468 | (eval $ac_try) 2>&5 |
| 10469 | ac_status=$? |
| 10470 | echo "$as_me:10470: \$? = $ac_status" >&5 |
| 10471 | (exit $ac_status); }; }; then |
| 10472 | break |
| 10473 | else |
| 10474 | echo "$as_me: failed program was:" >&5 |
| 10475 | cat conftest.$ac_ext >&5 |
| 10476 | fi |
| 10477 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10478 | cat >conftest.$ac_ext <<_ACEOF |
| 10479 | #line 10479 "configure" |
| 10480 | #include "confdefs.h" |
| 10481 | #define _FILE_OFFSET_BITS 64 |
| 10482 | #include <sys/types.h> |
| 10483 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 10484 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 10485 | since some C++ compilers masquerading as C compilers |
| 10486 | incorrectly reject 9223372036854775807. */ |
| 10487 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 10488 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 10489 | && LARGE_OFF_T % 2147483647 == 1) |
| 10490 | ? 1 : -1]; |
| 10491 | int |
| 10492 | main () |
| 10493 | { |
| 10494 | |
| 10495 | ; |
| 10496 | return 0; |
| 10497 | } |
| 10498 | _ACEOF |
| 10499 | rm -f conftest.$ac_objext |
| 10500 | if { (eval echo "$as_me:10500: \"$ac_compile\"") >&5 |
| 10501 | (eval $ac_compile) 2>&5 |
| 10502 | ac_status=$? |
| 10503 | echo "$as_me:10503: \$? = $ac_status" >&5 |
| 10504 | (exit $ac_status); } && |
| 10505 | { ac_try='test -s conftest.$ac_objext' |
| 10506 | { (eval echo "$as_me:10506: \"$ac_try\"") >&5 |
| 10507 | (eval $ac_try) 2>&5 |
| 10508 | ac_status=$? |
| 10509 | echo "$as_me:10509: \$? = $ac_status" >&5 |
| 10510 | (exit $ac_status); }; }; then |
| 10511 | ac_cv_sys_file_offset_bits=64; break |
| 10512 | else |
| 10513 | echo "$as_me: failed program was:" >&5 |
| 10514 | cat conftest.$ac_ext >&5 |
| 10515 | fi |
| 10516 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10517 | break |
| 10518 | done |
| 10519 | fi |
| 10520 | echo "$as_me:10520: result: $ac_cv_sys_file_offset_bits" >&5 |
| 10521 | echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6 |
| 10522 | if test "$ac_cv_sys_file_offset_bits" != no; then |
| 10523 | |
| 10524 | cat >>confdefs.h <<EOF |
| 10525 | #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits |
| 10526 | EOF |
| 10527 | |
| 10528 | fi |
| 10529 | rm -rf conftest* |
| 10530 | echo "$as_me:10530: checking for _LARGE_FILES value needed for large files" >&5 |
| 10531 | echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6 |
| 10532 | if test "${ac_cv_sys_large_files+set}" = set; then |
| 10533 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10534 | else |
| 10535 | while :; do |
| 10536 | ac_cv_sys_large_files=no |
| 10537 | cat >conftest.$ac_ext <<_ACEOF |
| 10538 | #line 10538 "configure" |
| 10539 | #include "confdefs.h" |
| 10540 | #include <sys/types.h> |
| 10541 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 10542 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 10543 | since some C++ compilers masquerading as C compilers |
| 10544 | incorrectly reject 9223372036854775807. */ |
| 10545 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 10546 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 10547 | && LARGE_OFF_T % 2147483647 == 1) |
| 10548 | ? 1 : -1]; |
| 10549 | int |
| 10550 | main () |
| 10551 | { |
| 10552 | |
| 10553 | ; |
| 10554 | return 0; |
| 10555 | } |
| 10556 | _ACEOF |
| 10557 | rm -f conftest.$ac_objext |
| 10558 | if { (eval echo "$as_me:10558: \"$ac_compile\"") >&5 |
| 10559 | (eval $ac_compile) 2>&5 |
| 10560 | ac_status=$? |
| 10561 | echo "$as_me:10561: \$? = $ac_status" >&5 |
| 10562 | (exit $ac_status); } && |
| 10563 | { ac_try='test -s conftest.$ac_objext' |
| 10564 | { (eval echo "$as_me:10564: \"$ac_try\"") >&5 |
| 10565 | (eval $ac_try) 2>&5 |
| 10566 | ac_status=$? |
| 10567 | echo "$as_me:10567: \$? = $ac_status" >&5 |
| 10568 | (exit $ac_status); }; }; then |
| 10569 | break |
| 10570 | else |
| 10571 | echo "$as_me: failed program was:" >&5 |
| 10572 | cat conftest.$ac_ext >&5 |
| 10573 | fi |
| 10574 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10575 | cat >conftest.$ac_ext <<_ACEOF |
| 10576 | #line 10576 "configure" |
| 10577 | #include "confdefs.h" |
| 10578 | #define _LARGE_FILES 1 |
| 10579 | #include <sys/types.h> |
| 10580 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 10581 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 10582 | since some C++ compilers masquerading as C compilers |
| 10583 | incorrectly reject 9223372036854775807. */ |
| 10584 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 10585 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 10586 | && LARGE_OFF_T % 2147483647 == 1) |
| 10587 | ? 1 : -1]; |
| 10588 | int |
| 10589 | main () |
| 10590 | { |
| 10591 | |
| 10592 | ; |
| 10593 | return 0; |
| 10594 | } |
| 10595 | _ACEOF |
| 10596 | rm -f conftest.$ac_objext |
| 10597 | if { (eval echo "$as_me:10597: \"$ac_compile\"") >&5 |
| 10598 | (eval $ac_compile) 2>&5 |
| 10599 | ac_status=$? |
| 10600 | echo "$as_me:10600: \$? = $ac_status" >&5 |
| 10601 | (exit $ac_status); } && |
| 10602 | { ac_try='test -s conftest.$ac_objext' |
| 10603 | { (eval echo "$as_me:10603: \"$ac_try\"") >&5 |
| 10604 | (eval $ac_try) 2>&5 |
| 10605 | ac_status=$? |
| 10606 | echo "$as_me:10606: \$? = $ac_status" >&5 |
| 10607 | (exit $ac_status); }; }; then |
| 10608 | ac_cv_sys_large_files=1; break |
| 10609 | else |
| 10610 | echo "$as_me: failed program was:" >&5 |
| 10611 | cat conftest.$ac_ext >&5 |
| 10612 | fi |
| 10613 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10614 | break |
| 10615 | done |
| 10616 | fi |
| 10617 | echo "$as_me:10617: result: $ac_cv_sys_large_files" >&5 |
| 10618 | echo "${ECHO_T}$ac_cv_sys_large_files" >&6 |
| 10619 | if test "$ac_cv_sys_large_files" != no; then |
| 10620 | |
| 10621 | cat >>confdefs.h <<EOF |
| 10622 | #define _LARGE_FILES $ac_cv_sys_large_files |
| 10623 | EOF |
| 10624 | |
| 10625 | fi |
| 10626 | rm -rf conftest* |
| 10627 | fi |
| 10628 | |
| 10629 | if test "$enable_largefile" != no ; then |
| 10630 | echo "$as_me:10630: checking for _LARGEFILE_SOURCE value needed for large files" >&5 |
| 10631 | echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6 |
| 10632 | if test "${ac_cv_sys_largefile_source+set}" = set; then |
| 10633 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10634 | else |
| 10635 | while :; do |
| 10636 | ac_cv_sys_largefile_source=no |
| 10637 | cat >conftest.$ac_ext <<_ACEOF |
| 10638 | #line 10638 "configure" |
| 10639 | #include "confdefs.h" |
| 10640 | #include <stdio.h> |
| 10641 | int |
| 10642 | main () |
| 10643 | { |
| 10644 | return !fseeko; |
| 10645 | ; |
| 10646 | return 0; |
| 10647 | } |
| 10648 | _ACEOF |
| 10649 | rm -f conftest.$ac_objext |
| 10650 | if { (eval echo "$as_me:10650: \"$ac_compile\"") >&5 |
| 10651 | (eval $ac_compile) 2>&5 |
| 10652 | ac_status=$? |
| 10653 | echo "$as_me:10653: \$? = $ac_status" >&5 |
| 10654 | (exit $ac_status); } && |
| 10655 | { ac_try='test -s conftest.$ac_objext' |
| 10656 | { (eval echo "$as_me:10656: \"$ac_try\"") >&5 |
| 10657 | (eval $ac_try) 2>&5 |
| 10658 | ac_status=$? |
| 10659 | echo "$as_me:10659: \$? = $ac_status" >&5 |
| 10660 | (exit $ac_status); }; }; then |
| 10661 | break |
| 10662 | else |
| 10663 | echo "$as_me: failed program was:" >&5 |
| 10664 | cat conftest.$ac_ext >&5 |
| 10665 | fi |
| 10666 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10667 | cat >conftest.$ac_ext <<_ACEOF |
| 10668 | #line 10668 "configure" |
| 10669 | #include "confdefs.h" |
| 10670 | #define _LARGEFILE_SOURCE 1 |
| 10671 | #include <stdio.h> |
| 10672 | int |
| 10673 | main () |
| 10674 | { |
| 10675 | return !fseeko; |
| 10676 | ; |
| 10677 | return 0; |
| 10678 | } |
| 10679 | _ACEOF |
| 10680 | rm -f conftest.$ac_objext |
| 10681 | if { (eval echo "$as_me:10681: \"$ac_compile\"") >&5 |
| 10682 | (eval $ac_compile) 2>&5 |
| 10683 | ac_status=$? |
| 10684 | echo "$as_me:10684: \$? = $ac_status" >&5 |
| 10685 | (exit $ac_status); } && |
| 10686 | { ac_try='test -s conftest.$ac_objext' |
| 10687 | { (eval echo "$as_me:10687: \"$ac_try\"") >&5 |
| 10688 | (eval $ac_try) 2>&5 |
| 10689 | ac_status=$? |
| 10690 | echo "$as_me:10690: \$? = $ac_status" >&5 |
| 10691 | (exit $ac_status); }; }; then |
| 10692 | ac_cv_sys_largefile_source=1; break |
| 10693 | else |
| 10694 | echo "$as_me: failed program was:" >&5 |
| 10695 | cat conftest.$ac_ext >&5 |
| 10696 | fi |
| 10697 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10698 | break |
| 10699 | done |
| 10700 | fi |
| 10701 | echo "$as_me:10701: result: $ac_cv_sys_largefile_source" >&5 |
| 10702 | echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6 |
| 10703 | if test "$ac_cv_sys_largefile_source" != no; then |
| 10704 | |
| 10705 | cat >>confdefs.h <<EOF |
| 10706 | #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source |
| 10707 | EOF |
| 10708 | |
| 10709 | fi |
| 10710 | rm -rf conftest* |
| 10711 | |
| 10712 | # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug |
| 10713 | # in glibc 2.1.3, but that breaks too many other things. |
| 10714 | # If you want fseeko and ftello with glibc, upgrade to a fixed glibc. |
| 10715 | echo "$as_me:10715: checking for fseeko" >&5 |
| 10716 | echo $ECHO_N "checking for fseeko... $ECHO_C" >&6 |
| 10717 | if test "${ac_cv_func_fseeko+set}" = set; then |
| 10718 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10719 | else |
| 10720 | cat >conftest.$ac_ext <<_ACEOF |
| 10721 | #line 10721 "configure" |
| 10722 | #include "confdefs.h" |
| 10723 | #include <stdio.h> |
| 10724 | int |
| 10725 | main () |
| 10726 | { |
| 10727 | return fseeko && fseeko (stdin, 0, 0); |
| 10728 | ; |
| 10729 | return 0; |
| 10730 | } |
| 10731 | _ACEOF |
| 10732 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 10733 | if { (eval echo "$as_me:10733: \"$ac_link\"") >&5 |
| 10734 | (eval $ac_link) 2>&5 |
| 10735 | ac_status=$? |
| 10736 | echo "$as_me:10736: \$? = $ac_status" >&5 |
| 10737 | (exit $ac_status); } && |
| 10738 | { ac_try='test -s conftest$ac_exeext' |
| 10739 | { (eval echo "$as_me:10739: \"$ac_try\"") >&5 |
| 10740 | (eval $ac_try) 2>&5 |
| 10741 | ac_status=$? |
| 10742 | echo "$as_me:10742: \$? = $ac_status" >&5 |
| 10743 | (exit $ac_status); }; }; then |
| 10744 | ac_cv_func_fseeko=yes |
| 10745 | else |
| 10746 | echo "$as_me: failed program was:" >&5 |
| 10747 | cat conftest.$ac_ext >&5 |
| 10748 | ac_cv_func_fseeko=no |
| 10749 | fi |
| 10750 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 10751 | fi |
| 10752 | echo "$as_me:10752: result: $ac_cv_func_fseeko" >&5 |
| 10753 | echo "${ECHO_T}$ac_cv_func_fseeko" >&6 |
| 10754 | if test $ac_cv_func_fseeko = yes; then |
| 10755 | |
| 10756 | cat >>confdefs.h <<\EOF |
| 10757 | #define HAVE_FSEEKO 1 |
| 10758 | EOF |
| 10759 | |
| 10760 | fi |
| 10761 | |
| 10762 | # Normally we would collect these definitions in the config.h, |
| 10763 | # but (like _XOPEN_SOURCE), some environments rely on having these |
| 10764 | # defined before any of the system headers are included. Another |
| 10765 | # case comes up with C++, e.g., on AIX the compiler compiles the |
| 10766 | # header files by themselves before looking at the body files it is |
| 10767 | # told to compile. For ncurses, those header files do not include |
| 10768 | # the config.h |
| 10769 | test "$ac_cv_sys_large_files" != no && CPPFLAGS="$CPPFLAGS -D_LARGE_FILES " |
| 10770 | test "$ac_cv_sys_largefile_source" != no && CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE " |
| 10771 | test "$ac_cv_sys_file_offset_bits" != no && CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits " |
| 10772 | |
| 10773 | echo "$as_me:10773: checking whether to use struct dirent64" >&5 |
| 10774 | echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6 |
| 10775 | if test "${cf_cv_struct_dirent64+set}" = set; then |
| 10776 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 10777 | else |
| 10778 | |
| 10779 | cat >conftest.$ac_ext <<_ACEOF |
| 10780 | #line 10780 "configure" |
| 10781 | #include "confdefs.h" |
| 10782 | |
| 10783 | #include <sys/types.h> |
| 10784 | #include <dirent.h> |
| 10785 | |
| 10786 | int |
| 10787 | main () |
| 10788 | { |
| 10789 | |
| 10790 | /* if transitional largefile support is setup, this is true */ |
| 10791 | extern struct dirent64 * readdir(DIR *); |
| 10792 | struct dirent64 *x = readdir((DIR *)0); |
| 10793 | struct dirent *y = readdir((DIR *)0); |
| 10794 | int z = x - y; |
| 10795 | |
| 10796 | ; |
| 10797 | return 0; |
| 10798 | } |
| 10799 | _ACEOF |
| 10800 | rm -f conftest.$ac_objext |
| 10801 | if { (eval echo "$as_me:10801: \"$ac_compile\"") >&5 |
| 10802 | (eval $ac_compile) 2>&5 |
| 10803 | ac_status=$? |
| 10804 | echo "$as_me:10804: \$? = $ac_status" >&5 |
| 10805 | (exit $ac_status); } && |
| 10806 | { ac_try='test -s conftest.$ac_objext' |
| 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 | cf_cv_struct_dirent64=yes |
| 10813 | else |
| 10814 | echo "$as_me: failed program was:" >&5 |
| 10815 | cat conftest.$ac_ext >&5 |
| 10816 | cf_cv_struct_dirent64=no |
| 10817 | fi |
| 10818 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 10819 | |
| 10820 | fi |
| 10821 | echo "$as_me:10821: result: $cf_cv_struct_dirent64" >&5 |
| 10822 | echo "${ECHO_T}$cf_cv_struct_dirent64" >&6 |
| 10823 | test "$cf_cv_struct_dirent64" = yes && |
| 10824 | cat >>confdefs.h <<\EOF |
| 10825 | #define HAVE_STRUCT_DIRENT64 1 |
| 10826 | EOF |
| 10827 | |
| 10828 | fi |
| 10829 | |
| 10830 | ### use option --disable-tparm-varargs to make tparm() conform to X/Open |
| 10831 | echo "$as_me:10831: checking if you want tparm not to use X/Open fixed-parameter list" >&5 |
| 10832 | echo $ECHO_N "checking if you want tparm not to use X/Open fixed-parameter list... $ECHO_C" >&6 |
| 10833 | |
| 10834 | # Check whether --enable-tparm-varargs or --disable-tparm-varargs was given. |
| 10835 | if test "${enable_tparm_varargs+set}" = set; then |
| 10836 | enableval="$enable_tparm_varargs" |
| 10837 | with_tparm_varargs=$enableval |
| 10838 | else |
| 10839 | with_tparm_varargs=yes |
| 10840 | fi; |
| 10841 | echo "$as_me:10841: result: $with_tparm_varargs" >&5 |
| 10842 | echo "${ECHO_T}$with_tparm_varargs" >&6 |
| 10843 | NCURSES_TPARM_VARARGS=0 |
| 10844 | test "x$with_tparm_varargs" = xyes && NCURSES_TPARM_VARARGS=1 |
| 10845 | |
| 10846 | ### use option --disable-tic-depends to make libtic not explicitly depend on ncurses/ncursesw |
| 10847 | if test "$with_ticlib" != no ; then |
| 10848 | echo "$as_me:10848: checking if you want tic library to use explicit dependency on ncurses$LIB_SUFFIX library" >&5 |
| 10849 | echo $ECHO_N "checking if you want tic library to use explicit dependency on ncurses$LIB_SUFFIX library... $ECHO_C" >&6 |
| 10850 | |
| 10851 | # Check whether --enable-tic-depends or --disable-tic-depends was given. |
| 10852 | if test "${enable_tic_depends+set}" = set; then |
| 10853 | enableval="$enable_tic_depends" |
| 10854 | with_tic_depends=$enableval |
| 10855 | else |
| 10856 | with_tic_depends=yes |
| 10857 | fi; |
| 10858 | echo "$as_me:10858: result: $with_tic_depends" >&5 |
| 10859 | echo "${ECHO_T}$with_tic_depends" >&6 |
| 10860 | else |
| 10861 | with_tic_depends=no |
| 10862 | fi |
| 10863 | |
| 10864 | ### use option --with-bool to override bool's type |
| 10865 | echo "$as_me:10865: checking for type of bool" >&5 |
| 10866 | echo $ECHO_N "checking for type of bool... $ECHO_C" >&6 |
| 10867 | |
| 10868 | # Check whether --with-bool or --without-bool was given. |
| 10869 | if test "${with_bool+set}" = set; then |
| 10870 | withval="$with_bool" |
| 10871 | NCURSES_BOOL="$withval" |
| 10872 | else |
| 10873 | NCURSES_BOOL=auto |
| 10874 | fi; |
| 10875 | echo "$as_me:10875: result: $NCURSES_BOOL" >&5 |
| 10876 | echo "${ECHO_T}$NCURSES_BOOL" >&6 |
| 10877 | |
| 10878 | echo "$as_me:10878: checking for alternate terminal capabilities file" >&5 |
| 10879 | echo $ECHO_N "checking for alternate terminal capabilities file... $ECHO_C" >&6 |
| 10880 | |
| 10881 | # Check whether --with-caps or --without-caps was given. |
| 10882 | if test "${with_caps+set}" = set; then |
| 10883 | withval="$with_caps" |
| 10884 | TERMINFO_CAPS=Caps.$withval |
| 10885 | else |
| 10886 | TERMINFO_CAPS=Caps |
| 10887 | fi; |
| 10888 | test -f "${srcdir}/include/${TERMINFO_CAPS}" || TERMINFO_CAPS=Caps |
| 10889 | echo "$as_me:10889: result: $TERMINFO_CAPS" >&5 |
| 10890 | echo "${ECHO_T}$TERMINFO_CAPS" >&6 |
| 10891 | |
| 10892 | ### use option --with-chtype to override chtype's type |
| 10893 | echo "$as_me:10893: checking for type of chtype" >&5 |
| 10894 | echo $ECHO_N "checking for type of chtype... $ECHO_C" >&6 |
| 10895 | |
| 10896 | # Check whether --with-chtype or --without-chtype was given. |
| 10897 | if test "${with_chtype+set}" = set; then |
| 10898 | withval="$with_chtype" |
| 10899 | NCURSES_CHTYPE="$withval" |
| 10900 | else |
| 10901 | NCURSES_CHTYPE=$cf_dft_chtype |
| 10902 | fi; |
| 10903 | echo "$as_me:10903: result: $NCURSES_CHTYPE" >&5 |
| 10904 | echo "${ECHO_T}$NCURSES_CHTYPE" >&6 |
| 10905 | |
| 10906 | ### use option --with-ospeed to override ospeed's type |
| 10907 | echo "$as_me:10907: checking for type of ospeed" >&5 |
| 10908 | echo $ECHO_N "checking for type of ospeed... $ECHO_C" >&6 |
| 10909 | |
| 10910 | # Check whether --with-ospeed or --without-ospeed was given. |
| 10911 | if test "${with_ospeed+set}" = set; then |
| 10912 | withval="$with_ospeed" |
| 10913 | NCURSES_OSPEED="$withval" |
| 10914 | else |
| 10915 | NCURSES_OSPEED=short |
| 10916 | fi; |
| 10917 | echo "$as_me:10917: result: $NCURSES_OSPEED" >&5 |
| 10918 | echo "${ECHO_T}$NCURSES_OSPEED" >&6 |
| 10919 | |
| 10920 | ### use option --with-mmask-t to override mmask_t's type |
| 10921 | echo "$as_me:10921: checking for type of mmask_t" >&5 |
| 10922 | echo $ECHO_N "checking for type of mmask_t... $ECHO_C" >&6 |
| 10923 | |
| 10924 | # Check whether --with-mmask-t or --without-mmask-t was given. |
| 10925 | if test "${with_mmask_t+set}" = set; then |
| 10926 | withval="$with_mmask_t" |
| 10927 | NCURSES_MMASK_T="$withval" |
| 10928 | else |
| 10929 | NCURSES_MMASK_T=$cf_dft_mmask_t |
| 10930 | fi; |
| 10931 | echo "$as_me:10931: result: $NCURSES_MMASK_T" >&5 |
| 10932 | echo "${ECHO_T}$NCURSES_MMASK_T" >&6 |
| 10933 | |
| 10934 | ### use option --with-ccharw-max to override CCHARW_MAX size |
| 10935 | echo "$as_me:10935: checking for size CCHARW_MAX" >&5 |
| 10936 | echo $ECHO_N "checking for size CCHARW_MAX... $ECHO_C" >&6 |
| 10937 | |
| 10938 | # Check whether --with-ccharw-max or --without-ccharw-max was given. |
| 10939 | if test "${with_ccharw_max+set}" = set; then |
| 10940 | withval="$with_ccharw_max" |
| 10941 | NCURSES_CCHARW_MAX="$withval" |
| 10942 | else |
| 10943 | NCURSES_CCHARW_MAX=5 |
| 10944 | fi; |
| 10945 | echo "$as_me:10945: result: $NCURSES_CCHARW_MAX" >&5 |
| 10946 | echo "${ECHO_T}$NCURSES_CCHARW_MAX" >&6 |
| 10947 | |
| 10948 | ### use option --with-tparm-arg to override tparm's argument type |
| 10949 | echo "$as_me:10949: checking for type of tparm args" >&5 |
| 10950 | echo $ECHO_N "checking for type of tparm args... $ECHO_C" >&6 |
| 10951 | |
| 10952 | # Check whether --with-tparm-arg or --without-tparm-arg was given. |
| 10953 | if test "${with_tparm_arg+set}" = set; then |
| 10954 | withval="$with_tparm_arg" |
| 10955 | NCURSES_TPARM_ARG="$withval" |
| 10956 | else |
| 10957 | NCURSES_TPARM_ARG=$cf_dft_tparm_arg |
| 10958 | fi; |
| 10959 | echo "$as_me:10959: result: $NCURSES_TPARM_ARG" >&5 |
| 10960 | echo "${ECHO_T}$NCURSES_TPARM_ARG" >&6 |
| 10961 | |
| 10962 | ### Enable compiling-in rcs id's |
| 10963 | echo "$as_me:10963: checking if RCS identifiers should be compiled-in" >&5 |
| 10964 | echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6 |
| 10965 | |
| 10966 | # Check whether --with-rcs-ids or --without-rcs-ids was given. |
| 10967 | if test "${with_rcs_ids+set}" = set; then |
| 10968 | withval="$with_rcs_ids" |
| 10969 | with_rcs_ids=$withval |
| 10970 | else |
| 10971 | with_rcs_ids=no |
| 10972 | fi; |
| 10973 | echo "$as_me:10973: result: $with_rcs_ids" >&5 |
| 10974 | echo "${ECHO_T}$with_rcs_ids" >&6 |
| 10975 | test "x$with_rcs_ids" = xyes && |
| 10976 | cat >>confdefs.h <<\EOF |
| 10977 | #define USE_RCS_IDS 1 |
| 10978 | EOF |
| 10979 | |
| 10980 | ############################################################################### |
| 10981 | |
| 10982 | echo "$as_me:10982: checking format of man-pages" >&5 |
| 10983 | echo $ECHO_N "checking format of man-pages... $ECHO_C" >&6 |
| 10984 | |
| 10985 | # Check whether --with-manpage-format or --without-manpage-format was given. |
| 10986 | if test "${with_manpage_format+set}" = set; then |
| 10987 | withval="$with_manpage_format" |
| 10988 | MANPAGE_FORMAT=$withval |
| 10989 | else |
| 10990 | MANPAGE_FORMAT=unknown |
| 10991 | fi; |
| 10992 | |
| 10993 | test -z "$MANPAGE_FORMAT" && MANPAGE_FORMAT=unknown |
| 10994 | MANPAGE_FORMAT=`echo "$MANPAGE_FORMAT" | sed -e 's/,/ /g'` |
| 10995 | |
| 10996 | cf_unknown= |
| 10997 | |
| 10998 | case $MANPAGE_FORMAT in |
| 10999 | (unknown) |
| 11000 | if test -z "$MANPATH" ; then |
| 11001 | MANPATH="/usr/man:/usr/share/man" |
| 11002 | fi |
| 11003 | |
| 11004 | # look for the 'date' man-page (it's most likely to be installed!) |
| 11005 | MANPAGE_FORMAT= |
| 11006 | cf_preform=no |
| 11007 | cf_catonly=yes |
| 11008 | cf_example=date |
| 11009 | |
| 11010 | IFS="${IFS:- }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" |
| 11011 | for cf_dir in $MANPATH; do |
| 11012 | test -z "$cf_dir" && cf_dir=/usr/man |
| 11013 | for cf_name in $cf_dir/man*/$cf_example.[01]* $cf_dir/cat*/$cf_example.[01]* $cf_dir/man*/$cf_example $cf_dir/cat*/$cf_example |
| 11014 | do |
| 11015 | cf_test=`echo $cf_name | sed -e 's/*//'` |
| 11016 | if test "x$cf_test" = "x$cf_name" ; then |
| 11017 | |
| 11018 | case "$cf_name" in |
| 11019 | (*.gz) MANPAGE_FORMAT="$MANPAGE_FORMAT gzip";; |
| 11020 | (*.Z) MANPAGE_FORMAT="$MANPAGE_FORMAT compress";; |
| 11021 | (*.0) MANPAGE_FORMAT="$MANPAGE_FORMAT BSDI";; |
| 11022 | (*) MANPAGE_FORMAT="$MANPAGE_FORMAT normal";; |
| 11023 | esac |
| 11024 | |
| 11025 | case "$cf_name" in |
| 11026 | ($cf_dir/man*) |
| 11027 | cf_catonly=no |
| 11028 | ;; |
| 11029 | ($cf_dir/cat*) |
| 11030 | cf_preform=yes |
| 11031 | ;; |
| 11032 | esac |
| 11033 | break |
| 11034 | fi |
| 11035 | |
| 11036 | # if we found a match in either man* or cat*, stop looking |
| 11037 | if test -n "$MANPAGE_FORMAT" ; then |
| 11038 | cf_found=no |
| 11039 | test "$cf_preform" = yes && MANPAGE_FORMAT="$MANPAGE_FORMAT formatted" |
| 11040 | test "$cf_catonly" = yes && MANPAGE_FORMAT="$MANPAGE_FORMAT catonly" |
| 11041 | case "$cf_name" in |
| 11042 | ($cf_dir/cat*) |
| 11043 | cf_found=yes |
| 11044 | ;; |
| 11045 | esac |
| 11046 | test $cf_found=yes && break |
| 11047 | fi |
| 11048 | done |
| 11049 | # only check the first directory in $MANPATH where we find manpages |
| 11050 | if test -n "$MANPAGE_FORMAT" ; then |
| 11051 | break |
| 11052 | fi |
| 11053 | done |
| 11054 | # if we did not find the example, just assume it is normal |
| 11055 | test -z "$MANPAGE_FORMAT" && MANPAGE_FORMAT=normal |
| 11056 | IFS="$ac_save_ifs" |
| 11057 | ;; |
| 11058 | (*) |
| 11059 | for cf_option in $MANPAGE_FORMAT; do |
| 11060 | case $cf_option in |
| 11061 | (gzip|compress|BSDI|normal|formatted|catonly) |
| 11062 | ;; |
| 11063 | (*) |
| 11064 | cf_unknown="$cf_unknown $cf_option" |
| 11065 | ;; |
| 11066 | esac |
| 11067 | done |
| 11068 | ;; |
| 11069 | esac |
| 11070 | |
| 11071 | echo "$as_me:11071: result: $MANPAGE_FORMAT" >&5 |
| 11072 | echo "${ECHO_T}$MANPAGE_FORMAT" >&6 |
| 11073 | if test -n "$cf_unknown" ; then |
| 11074 | { echo "$as_me:11074: WARNING: Unexpected manpage-format $cf_unknown" >&5 |
| 11075 | echo "$as_me: WARNING: Unexpected manpage-format $cf_unknown" >&2;} |
| 11076 | fi |
| 11077 | |
| 11078 | echo "$as_me:11078: checking for manpage renaming" >&5 |
| 11079 | echo $ECHO_N "checking for manpage renaming... $ECHO_C" >&6 |
| 11080 | |
| 11081 | # Check whether --with-manpage-renames or --without-manpage-renames was given. |
| 11082 | if test "${with_manpage_renames+set}" = set; then |
| 11083 | withval="$with_manpage_renames" |
| 11084 | MANPAGE_RENAMES=$withval |
| 11085 | else |
| 11086 | MANPAGE_RENAMES=yes |
| 11087 | fi; |
| 11088 | |
| 11089 | case ".$MANPAGE_RENAMES" in |
| 11090 | (.no) |
| 11091 | ;; |
| 11092 | (.|.yes) |
| 11093 | # Debian 'man' program? |
| 11094 | if test -f /etc/debian_version ; then |
| 11095 | MANPAGE_RENAMES=`cd $srcdir && pwd`/man/man_db.renames |
| 11096 | else |
| 11097 | MANPAGE_RENAMES=no |
| 11098 | fi |
| 11099 | ;; |
| 11100 | esac |
| 11101 | |
| 11102 | if test "$MANPAGE_RENAMES" != no ; then |
| 11103 | if test -f $srcdir/man/$MANPAGE_RENAMES ; then |
| 11104 | MANPAGE_RENAMES=`cd $srcdir/man && pwd`/$MANPAGE_RENAMES |
| 11105 | elif test ! -f $MANPAGE_RENAMES ; then |
| 11106 | { { echo "$as_me:11106: error: not a filename: $MANPAGE_RENAMES" >&5 |
| 11107 | echo "$as_me: error: not a filename: $MANPAGE_RENAMES" >&2;} |
| 11108 | { (exit 1); exit 1; }; } |
| 11109 | fi |
| 11110 | |
| 11111 | test ! -d man && mkdir man |
| 11112 | |
| 11113 | # Construct a sed-script to perform renaming within man-pages |
| 11114 | if test -n "$MANPAGE_RENAMES" ; then |
| 11115 | test ! -d man && mkdir man |
| 11116 | $SHELL $srcdir/man/make_sed.sh $MANPAGE_RENAMES >./edit_man.sed |
| 11117 | fi |
| 11118 | fi |
| 11119 | |
| 11120 | echo "$as_me:11120: result: $MANPAGE_RENAMES" >&5 |
| 11121 | echo "${ECHO_T}$MANPAGE_RENAMES" >&6 |
| 11122 | |
| 11123 | echo "$as_me:11123: checking if manpage aliases will be installed" >&5 |
| 11124 | echo $ECHO_N "checking if manpage aliases will be installed... $ECHO_C" >&6 |
| 11125 | |
| 11126 | # Check whether --with-manpage-aliases or --without-manpage-aliases was given. |
| 11127 | if test "${with_manpage_aliases+set}" = set; then |
| 11128 | withval="$with_manpage_aliases" |
| 11129 | MANPAGE_ALIASES=$withval |
| 11130 | else |
| 11131 | MANPAGE_ALIASES=yes |
| 11132 | fi; |
| 11133 | |
| 11134 | echo "$as_me:11134: result: $MANPAGE_ALIASES" >&5 |
| 11135 | echo "${ECHO_T}$MANPAGE_ALIASES" >&6 |
| 11136 | |
| 11137 | case "x$LN_S" in |
| 11138 | (xln*) |
| 11139 | cf_use_symlinks=yes |
| 11140 | ;; |
| 11141 | (*) |
| 11142 | cf_use_symlinks=no |
| 11143 | ;; |
| 11144 | esac |
| 11145 | |
| 11146 | MANPAGE_SYMLINKS=no |
| 11147 | if test "$MANPAGE_ALIASES" = yes ; then |
| 11148 | echo "$as_me:11148: checking if manpage symlinks should be used" >&5 |
| 11149 | echo $ECHO_N "checking if manpage symlinks should be used... $ECHO_C" >&6 |
| 11150 | |
| 11151 | # Check whether --with-manpage-symlinks or --without-manpage-symlinks was given. |
| 11152 | if test "${with_manpage_symlinks+set}" = set; then |
| 11153 | withval="$with_manpage_symlinks" |
| 11154 | MANPAGE_SYMLINKS=$withval |
| 11155 | else |
| 11156 | MANPAGE_SYMLINKS=$cf_use_symlinks |
| 11157 | fi; |
| 11158 | |
| 11159 | if test "$$cf_use_symlinks" = no; then |
| 11160 | if test "$MANPAGE_SYMLINKS" = yes ; then |
| 11161 | { echo "$as_me:11161: WARNING: cannot make symlinks" >&5 |
| 11162 | echo "$as_me: WARNING: cannot make symlinks" >&2;} |
| 11163 | MANPAGE_SYMLINKS=no |
| 11164 | fi |
| 11165 | fi |
| 11166 | |
| 11167 | echo "$as_me:11167: result: $MANPAGE_SYMLINKS" >&5 |
| 11168 | echo "${ECHO_T}$MANPAGE_SYMLINKS" >&6 |
| 11169 | fi |
| 11170 | |
| 11171 | echo "$as_me:11171: checking for manpage tbl" >&5 |
| 11172 | echo $ECHO_N "checking for manpage tbl... $ECHO_C" >&6 |
| 11173 | |
| 11174 | # Check whether --with-manpage-tbl or --without-manpage-tbl was given. |
| 11175 | if test "${with_manpage_tbl+set}" = set; then |
| 11176 | withval="$with_manpage_tbl" |
| 11177 | MANPAGE_TBL=$withval |
| 11178 | else |
| 11179 | MANPAGE_TBL=no |
| 11180 | fi; |
| 11181 | |
| 11182 | echo "$as_me:11182: result: $MANPAGE_TBL" >&5 |
| 11183 | echo "${ECHO_T}$MANPAGE_TBL" >&6 |
| 11184 | |
| 11185 | if test "$prefix" = "NONE" ; then |
| 11186 | cf_prefix="$ac_default_prefix" |
| 11187 | else |
| 11188 | cf_prefix="$prefix" |
| 11189 | fi |
| 11190 | |
| 11191 | case "$MANPAGE_FORMAT" in |
| 11192 | (*catonly*) |
| 11193 | cf_format=yes |
| 11194 | cf_inboth=no |
| 11195 | ;; |
| 11196 | (*formatted*) |
| 11197 | cf_format=yes |
| 11198 | cf_inboth=yes |
| 11199 | ;; |
| 11200 | (*) |
| 11201 | cf_format=no |
| 11202 | cf_inboth=no |
| 11203 | ;; |
| 11204 | esac |
| 11205 | |
| 11206 | test ! -d man && mkdir man |
| 11207 | |
| 11208 | cf_so_strip= |
| 11209 | cf_compress= |
| 11210 | case "$MANPAGE_FORMAT" in |
| 11211 | (*compress*) |
| 11212 | cf_so_strip="Z" |
| 11213 | cf_compress=compress |
| 11214 | ;; |
| 11215 | (*gzip*) |
| 11216 | cf_so_strip="gz" |
| 11217 | cf_compress=gzip |
| 11218 | ;; |
| 11219 | esac |
| 11220 | |
| 11221 | cf_edit_man=./edit_man.sh |
| 11222 | cf_man_alias=`pwd`/man_alias.sed |
| 11223 | |
| 11224 | cat >$cf_edit_man <<CF_EOF |
| 11225 | #! $SHELL |
| 11226 | # this script is generated by the configure-script CF_MAN_PAGES macro. |
| 11227 | |
| 11228 | prefix="$cf_prefix" |
| 11229 | datarootdir="$datarootdir" |
| 11230 | datadir="$datadir" |
| 11231 | |
| 11232 | NCURSES_MAJOR="$NCURSES_MAJOR" |
| 11233 | NCURSES_MINOR="$NCURSES_MINOR" |
| 11234 | NCURSES_PATCH="$NCURSES_PATCH" |
| 11235 | |
| 11236 | NCURSES_OSPEED="$NCURSES_OSPEED" |
| 11237 | TERMINFO="$TERMINFO" |
| 11238 | |
| 11239 | INSTALL="$INSTALL" |
| 11240 | INSTALL_DATA="$INSTALL_DATA" |
| 11241 | |
| 11242 | transform="$program_transform_name" |
| 11243 | |
| 11244 | TMP=\${TMPDIR:=/tmp}/man\$\$ |
| 11245 | trap "rm -f \$TMP" 0 1 2 5 15 |
| 11246 | |
| 11247 | form=\$1 |
| 11248 | shift || exit 1 |
| 11249 | |
| 11250 | verb=\$1 |
| 11251 | shift || exit 1 |
| 11252 | |
| 11253 | mandir=\$1 |
| 11254 | shift || exit 1 |
| 11255 | |
| 11256 | srcdir=\$1 |
| 11257 | top_srcdir=\$srcdir/.. |
| 11258 | shift || exit 1 |
| 11259 | |
| 11260 | if test "\$form" = normal ; then |
| 11261 | if test "$cf_format" = yes ; then |
| 11262 | if test "$cf_inboth" = no ; then |
| 11263 | $SHELL \$0 format \$verb \$mandir \$srcdir \$* |
| 11264 | exit $? |
| 11265 | fi |
| 11266 | fi |
| 11267 | cf_subdir=\$mandir/man |
| 11268 | cf_tables=$MANPAGE_TBL |
| 11269 | else |
| 11270 | cf_subdir=\$mandir/cat |
| 11271 | cf_tables=yes |
| 11272 | fi |
| 11273 | |
| 11274 | # process the list of source-files |
| 11275 | for i in \$* ; do |
| 11276 | case \$i in |
| 11277 | (*.orig|*.rej) ;; |
| 11278 | (*.[0-9]*) |
| 11279 | section=\`expr "\$i" : '.*\\.\\([0-9]\\)[xm]*'\`; |
| 11280 | if test \$verb = installing ; then |
| 11281 | if test ! -d \$cf_subdir\${section} ; then |
| 11282 | mkdir -p \$cf_subdir\$section |
| 11283 | fi |
| 11284 | fi |
| 11285 | |
| 11286 | # replace variables in man page |
| 11287 | if test ! -f $cf_man_alias ; then |
| 11288 | cat >>$cf_man_alias <<-CF_EOF2 |
| 11289 | s,@DATADIR@,\$datadir,g |
| 11290 | s,@TERMINFO@,\${TERMINFO:="no default value"},g |
| 11291 | s,@TERMINFO_DIRS@,\${TERMINFO_DIRS:="no default value"},g |
| 11292 | s,@NCURSES_MAJOR@,\${NCURSES_MAJOR:="no default value"},g |
| 11293 | s,@NCURSES_MINOR@,\${NCURSES_MINOR:="no default value"},g |
| 11294 | s,@NCURSES_PATCH@,\${NCURSES_PATCH:="no default value"},g |
| 11295 | s,@NCURSES_OSPEED@,\${NCURSES_OSPEED:="no default value"},g |
| 11296 | CF_EOF |
| 11297 | |
| 11298 | for cf_name in captoinfo clear infocmp infotocap tabs tic toe tput tset |
| 11299 | do |
| 11300 | cf_NAME=`echo "$cf_name" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 11301 | cf_name=`echo $cf_name|sed "$program_transform_name"` |
| 11302 | cat >>$cf_edit_man <<-CF_EOF |
| 11303 | s,@$cf_NAME@,$cf_name,g |
| 11304 | CF_EOF |
| 11305 | done |
| 11306 | |
| 11307 | cat >>$cf_edit_man <<CF_EOF |
| 11308 | CF_EOF2 |
| 11309 | echo "...made $cf_man_alias" |
| 11310 | fi |
| 11311 | |
| 11312 | aliases= |
| 11313 | cf_source=\`basename \$i\` |
| 11314 | inalias=\$cf_source |
| 11315 | test ! -f \$inalias && inalias="\$srcdir/\$inalias" |
| 11316 | if test ! -f \$inalias ; then |
| 11317 | echo .. skipped \$cf_source |
| 11318 | continue |
| 11319 | fi |
| 11320 | CF_EOF |
| 11321 | |
| 11322 | if test "$MANPAGE_ALIASES" != no ; then |
| 11323 | cat >>$cf_edit_man <<CF_EOF |
| 11324 | nCurses=ignore.3x |
| 11325 | test $with_curses_h = yes && nCurses=ncurses.3x |
| 11326 | aliases=\`sed -f \$top_srcdir/man/manlinks.sed \$inalias |sed -f $cf_man_alias | sort -u; test \$inalias = \$nCurses && echo curses\` |
| 11327 | CF_EOF |
| 11328 | fi |
| 11329 | |
| 11330 | if test "$MANPAGE_RENAMES" = no ; then |
| 11331 | cat >>$cf_edit_man <<CF_EOF |
| 11332 | # perform program transformations for section 1 man pages |
| 11333 | if test \$section = 1 ; then |
| 11334 | cf_target=\$cf_subdir\${section}/\`echo \$cf_source|sed "\${transform}"\` |
| 11335 | else |
| 11336 | cf_target=\$cf_subdir\${section}/\$cf_source |
| 11337 | fi |
| 11338 | CF_EOF |
| 11339 | else |
| 11340 | cat >>$cf_edit_man <<CF_EOF |
| 11341 | cf_target=\`grep "^\$cf_source" $MANPAGE_RENAMES | $AWK '{print \$2}'\` |
| 11342 | if test -z "\$cf_target" ; then |
| 11343 | echo '? missing rename for '\$cf_source |
| 11344 | cf_target="\$cf_source" |
| 11345 | fi |
| 11346 | cf_target="\$cf_subdir\${section}/\${cf_target}" |
| 11347 | |
| 11348 | CF_EOF |
| 11349 | fi |
| 11350 | |
| 11351 | cat >>$cf_edit_man <<CF_EOF |
| 11352 | sed -f $cf_man_alias \\ |
| 11353 | CF_EOF |
| 11354 | |
| 11355 | if test -f $MANPAGE_RENAMES ; then |
| 11356 | cat >>$cf_edit_man <<CF_EOF |
| 11357 | < \$i | sed -f `pwd`/edit_man.sed >\$TMP |
| 11358 | CF_EOF |
| 11359 | else |
| 11360 | cat >>$cf_edit_man <<CF_EOF |
| 11361 | < \$i >\$TMP |
| 11362 | CF_EOF |
| 11363 | fi |
| 11364 | |
| 11365 | cat >>$cf_edit_man <<CF_EOF |
| 11366 | if test \$cf_tables = yes ; then |
| 11367 | tbl \$TMP >\$TMP.out |
| 11368 | mv \$TMP.out \$TMP |
| 11369 | fi |
| 11370 | CF_EOF |
| 11371 | |
| 11372 | if test $with_overwrite != yes ; then |
| 11373 | cat >>$cf_edit_man <<CF_EOF |
| 11374 | sed -e "/\#[ ]*include/s,<curses.h,<ncurses$LIB_SUFFIX/curses.h," < \$TMP >\$TMP.out |
| 11375 | mv \$TMP.out \$TMP |
| 11376 | CF_EOF |
| 11377 | fi |
| 11378 | |
| 11379 | if test $with_curses_h != yes ; then |
| 11380 | cat >>$cf_edit_man <<CF_EOF |
| 11381 | sed -e "/\#[ ]*include/s,curses.h,ncurses.h," < \$TMP >\$TMP.out |
| 11382 | mv \$TMP.out \$TMP |
| 11383 | CF_EOF |
| 11384 | fi |
| 11385 | |
| 11386 | cat >>$cf_edit_man <<CF_EOF |
| 11387 | if test \$form = format ; then |
| 11388 | nroff -man \$TMP >\$TMP.out |
| 11389 | mv \$TMP.out \$TMP |
| 11390 | fi |
| 11391 | CF_EOF |
| 11392 | |
| 11393 | if test -n "$cf_compress" ; then |
| 11394 | cat >>$cf_edit_man <<CF_EOF |
| 11395 | if test \$verb = installing ; then |
| 11396 | if ( $cf_compress -f \$TMP ) |
| 11397 | then |
| 11398 | mv \$TMP.$cf_so_strip \$TMP |
| 11399 | fi |
| 11400 | fi |
| 11401 | cf_target="\$cf_target.$cf_so_strip" |
| 11402 | CF_EOF |
| 11403 | fi |
| 11404 | |
| 11405 | case "$MANPAGE_FORMAT" in |
| 11406 | (*BSDI*) |
| 11407 | cat >>$cf_edit_man <<CF_EOF |
| 11408 | if test \$form = format ; then |
| 11409 | # BSDI installs only .0 suffixes in the cat directories |
| 11410 | cf_target="\`echo \$cf_target|sed -e 's/\.[1-9]\+[a-z]*/.0/'\`" |
| 11411 | fi |
| 11412 | CF_EOF |
| 11413 | ;; |
| 11414 | esac |
| 11415 | |
| 11416 | cat >>$cf_edit_man <<CF_EOF |
| 11417 | suffix=\`basename \$cf_target | sed -e 's%^[^.]*%%'\` |
| 11418 | if test \$verb = installing ; then |
| 11419 | echo \$verb \$cf_target |
| 11420 | \$INSTALL_DATA \$TMP \$cf_target |
| 11421 | test -d \$cf_subdir\${section} && |
| 11422 | test -n "\$aliases" && ( |
| 11423 | cd \$cf_subdir\${section} && ( |
| 11424 | cf_source=\`echo \$cf_target |sed -e 's%^.*/\([^/][^/]*/[^/][^/]*$\)%\1%'\` |
| 11425 | test -n "$cf_so_strip" && cf_source=\`echo \$cf_source |sed -e 's%\.$cf_so_strip\$%%'\` |
| 11426 | cf_target=\`basename \$cf_target\` |
| 11427 | for cf_alias in \$aliases |
| 11428 | do |
| 11429 | if test \$section = 1 ; then |
| 11430 | cf_alias=\`echo \$cf_alias|sed "\${transform}"\` |
| 11431 | fi |
| 11432 | |
| 11433 | if test "$MANPAGE_SYMLINKS" = yes ; then |
| 11434 | if test -f \$cf_alias\${suffix} ; then |
| 11435 | if ( cmp -s \$cf_target \$cf_alias\${suffix} ) |
| 11436 | then |
| 11437 | continue |
| 11438 | fi |
| 11439 | fi |
| 11440 | echo .. \$verb alias \$cf_alias\${suffix} |
| 11441 | CF_EOF |
| 11442 | case "x$LN_S" in |
| 11443 | (*-f) |
| 11444 | cat >>$cf_edit_man <<CF_EOF |
| 11445 | $LN_S \$cf_target \$cf_alias\${suffix} |
| 11446 | CF_EOF |
| 11447 | ;; |
| 11448 | (*) |
| 11449 | cat >>$cf_edit_man <<CF_EOF |
| 11450 | rm -f \$cf_alias\${suffix} |
| 11451 | $LN_S \$cf_target \$cf_alias\${suffix} |
| 11452 | CF_EOF |
| 11453 | ;; |
| 11454 | esac |
| 11455 | cat >>$cf_edit_man <<CF_EOF |
| 11456 | elif test "\$cf_target" != "\$cf_alias\${suffix}" ; then |
| 11457 | echo ".so \$cf_source" >\$TMP |
| 11458 | CF_EOF |
| 11459 | if test -n "$cf_compress" ; then |
| 11460 | cat >>$cf_edit_man <<CF_EOF |
| 11461 | if test -n "$cf_so_strip" ; then |
| 11462 | $cf_compress -f \$TMP |
| 11463 | mv \$TMP.$cf_so_strip \$TMP |
| 11464 | fi |
| 11465 | CF_EOF |
| 11466 | fi |
| 11467 | cat >>$cf_edit_man <<CF_EOF |
| 11468 | echo .. \$verb alias \$cf_alias\${suffix} |
| 11469 | rm -f \$cf_alias\${suffix} |
| 11470 | \$INSTALL_DATA \$TMP \$cf_alias\${suffix} |
| 11471 | fi |
| 11472 | done |
| 11473 | ) |
| 11474 | ) |
| 11475 | elif test \$verb = removing ; then |
| 11476 | test -f \$cf_target && ( |
| 11477 | echo \$verb \$cf_target |
| 11478 | rm -f \$cf_target |
| 11479 | ) |
| 11480 | test -d \$cf_subdir\${section} && |
| 11481 | test -n "\$aliases" && ( |
| 11482 | cd \$cf_subdir\${section} && ( |
| 11483 | for cf_alias in \$aliases |
| 11484 | do |
| 11485 | if test \$section = 1 ; then |
| 11486 | cf_alias=\`echo \$cf_alias|sed "\${transform}"\` |
| 11487 | fi |
| 11488 | |
| 11489 | echo .. \$verb alias \$cf_alias\${suffix} |
| 11490 | rm -f \$cf_alias\${suffix} |
| 11491 | done |
| 11492 | ) |
| 11493 | ) |
| 11494 | else |
| 11495 | # echo ".hy 0" |
| 11496 | cat \$TMP |
| 11497 | fi |
| 11498 | ;; |
| 11499 | esac |
| 11500 | done |
| 11501 | |
| 11502 | if test $cf_inboth = yes ; then |
| 11503 | if test \$form != format ; then |
| 11504 | $SHELL \$0 format \$verb \$mandir \$srcdir \$* |
| 11505 | fi |
| 11506 | fi |
| 11507 | |
| 11508 | exit 0 |
| 11509 | CF_EOF |
| 11510 | chmod 755 $cf_edit_man |
| 11511 | |
| 11512 | ############################################################################### |
| 11513 | |
| 11514 | ### Note that some functions (such as const) are normally disabled anyway. |
| 11515 | echo "$as_me:11515: checking if you want to build with function extensions" >&5 |
| 11516 | echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6 |
| 11517 | |
| 11518 | # Check whether --enable-ext-funcs or --disable-ext-funcs was given. |
| 11519 | if test "${enable_ext_funcs+set}" = set; then |
| 11520 | enableval="$enable_ext_funcs" |
| 11521 | with_ext_funcs=$enableval |
| 11522 | else |
| 11523 | with_ext_funcs=yes |
| 11524 | fi; |
| 11525 | echo "$as_me:11525: result: $with_ext_funcs" >&5 |
| 11526 | echo "${ECHO_T}$with_ext_funcs" >&6 |
| 11527 | if test "x$with_ext_funcs" = xyes ; then |
| 11528 | NCURSES_EXT_FUNCS=1 |
| 11529 | |
| 11530 | cat >>confdefs.h <<\EOF |
| 11531 | #define HAVE_ASSUME_DEFAULT_COLORS 1 |
| 11532 | EOF |
| 11533 | |
| 11534 | cat >>confdefs.h <<\EOF |
| 11535 | #define HAVE_CURSES_VERSION 1 |
| 11536 | EOF |
| 11537 | |
| 11538 | cat >>confdefs.h <<\EOF |
| 11539 | #define HAVE_HAS_KEY 1 |
| 11540 | EOF |
| 11541 | |
| 11542 | cat >>confdefs.h <<\EOF |
| 11543 | #define HAVE_RESIZETERM 1 |
| 11544 | EOF |
| 11545 | |
| 11546 | cat >>confdefs.h <<\EOF |
| 11547 | #define HAVE_RESIZE_TERM 1 |
| 11548 | EOF |
| 11549 | |
| 11550 | cat >>confdefs.h <<\EOF |
| 11551 | #define HAVE_TERM_ENTRY_H 1 |
| 11552 | EOF |
| 11553 | |
| 11554 | cat >>confdefs.h <<\EOF |
| 11555 | #define HAVE_USE_DEFAULT_COLORS 1 |
| 11556 | EOF |
| 11557 | |
| 11558 | cat >>confdefs.h <<\EOF |
| 11559 | #define HAVE_USE_SCREEN 1 |
| 11560 | EOF |
| 11561 | |
| 11562 | cat >>confdefs.h <<\EOF |
| 11563 | #define HAVE_USE_WINDOW 1 |
| 11564 | EOF |
| 11565 | |
| 11566 | cat >>confdefs.h <<\EOF |
| 11567 | #define HAVE_WRESIZE 1 |
| 11568 | EOF |
| 11569 | |
| 11570 | cat >>confdefs.h <<\EOF |
| 11571 | #define NCURSES_EXT_FUNCS 1 |
| 11572 | EOF |
| 11573 | |
| 11574 | GENERATED_EXT_FUNCS=generated |
| 11575 | else |
| 11576 | NCURSES_EXT_FUNCS=0 |
| 11577 | GENERATED_EXT_FUNCS= |
| 11578 | fi |
| 11579 | |
| 11580 | echo "$as_me:11580: checking if you want to build with SCREEN extensions" >&5 |
| 11581 | echo $ECHO_N "checking if you want to build with SCREEN extensions... $ECHO_C" >&6 |
| 11582 | |
| 11583 | # Check whether --enable-sp-funcs or --disable-sp-funcs was given. |
| 11584 | if test "${enable_sp_funcs+set}" = set; then |
| 11585 | enableval="$enable_sp_funcs" |
| 11586 | with_sp_funcs=$enableval |
| 11587 | else |
| 11588 | with_sp_funcs=$cf_dft_ext_spfuncs |
| 11589 | fi; |
| 11590 | echo "$as_me:11590: result: $with_sp_funcs" >&5 |
| 11591 | echo "${ECHO_T}$with_sp_funcs" >&6 |
| 11592 | if test "x$with_sp_funcs" = xyes ; then |
| 11593 | NCURSES_SP_FUNCS=1 |
| 11594 | |
| 11595 | cat >>confdefs.h <<\EOF |
| 11596 | #define NCURSES_SP_FUNCS 1 |
| 11597 | EOF |
| 11598 | |
| 11599 | GENERATED_SP_FUNCS=generated |
| 11600 | else |
| 11601 | NCURSES_SP_FUNCS=0 |
| 11602 | GENERATED_SP_FUNCS= |
| 11603 | fi |
| 11604 | |
| 11605 | echo "$as_me:11605: checking if you want to build with terminal-driver" >&5 |
| 11606 | echo $ECHO_N "checking if you want to build with terminal-driver... $ECHO_C" >&6 |
| 11607 | |
| 11608 | # Check whether --enable-term-driver or --disable-term-driver was given. |
| 11609 | if test "${enable_term_driver+set}" = set; then |
| 11610 | enableval="$enable_term_driver" |
| 11611 | with_term_driver=$enableval |
| 11612 | else |
| 11613 | with_term_driver=no |
| 11614 | fi; |
| 11615 | echo "$as_me:11615: result: $with_term_driver" >&5 |
| 11616 | echo "${ECHO_T}$with_term_driver" >&6 |
| 11617 | if test "x$with_term_driver" = xyes ; then |
| 11618 | |
| 11619 | cat >>confdefs.h <<\EOF |
| 11620 | #define USE_TERM_DRIVER 1 |
| 11621 | EOF |
| 11622 | |
| 11623 | if test "x$with_termlib" != xno ; then |
| 11624 | { { echo "$as_me:11624: error: The term-driver option conflicts with the termlib option" >&5 |
| 11625 | echo "$as_me: error: The term-driver option conflicts with the termlib option" >&2;} |
| 11626 | { (exit 1); exit 1; }; } |
| 11627 | fi |
| 11628 | if test "x$with_sp_funcs" != xyes ; then |
| 11629 | { { echo "$as_me:11629: error: The term-driver option relies upon sp-funcs" >&5 |
| 11630 | echo "$as_me: error: The term-driver option relies upon sp-funcs" >&2;} |
| 11631 | { (exit 1); exit 1; }; } |
| 11632 | fi |
| 11633 | fi |
| 11634 | |
| 11635 | ### use option --enable-const to turn on use of const beyond that in XSI. |
| 11636 | echo "$as_me:11636: checking for extended use of const keyword" >&5 |
| 11637 | echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6 |
| 11638 | |
| 11639 | # Check whether --enable-const or --disable-const was given. |
| 11640 | if test "${enable_const+set}" = set; then |
| 11641 | enableval="$enable_const" |
| 11642 | with_ext_const=$enableval |
| 11643 | else |
| 11644 | with_ext_const=$cf_dft_ext_const |
| 11645 | fi; |
| 11646 | echo "$as_me:11646: result: $with_ext_const" >&5 |
| 11647 | echo "${ECHO_T}$with_ext_const" >&6 |
| 11648 | NCURSES_CONST='/*nothing*/' |
| 11649 | if test "x$with_ext_const" = xyes ; then |
| 11650 | NCURSES_CONST=const |
| 11651 | fi |
| 11652 | |
| 11653 | ### use option --enable-ext-colors to turn on use of colors beyond 16. |
| 11654 | echo "$as_me:11654: checking if you want to use extended colors" >&5 |
| 11655 | echo $ECHO_N "checking if you want to use extended colors... $ECHO_C" >&6 |
| 11656 | |
| 11657 | # Check whether --enable-ext-colors or --disable-ext-colors was given. |
| 11658 | if test "${enable_ext_colors+set}" = set; then |
| 11659 | enableval="$enable_ext_colors" |
| 11660 | with_ext_colors=$enableval |
| 11661 | else |
| 11662 | with_ext_colors=$cf_dft_ext_colors |
| 11663 | fi; |
| 11664 | echo "$as_me:11664: result: $with_ext_colors" >&5 |
| 11665 | echo "${ECHO_T}$with_ext_colors" >&6 |
| 11666 | NCURSES_EXT_COLORS=0 |
| 11667 | if test "x$with_ext_colors" = xyes ; then |
| 11668 | if test "x$with_widec" != xyes ; then |
| 11669 | { echo "$as_me:11669: WARNING: This option applies only to wide-character library" >&5 |
| 11670 | echo "$as_me: WARNING: This option applies only to wide-character library" >&2;} |
| 11671 | else |
| 11672 | # cannot be ABI 5 since it changes sizeof(cchar_t) |
| 11673 | |
| 11674 | if test "${with_abi_version+set}" != set; then |
| 11675 | case $cf_cv_rel_version in |
| 11676 | (5.*) |
| 11677 | cf_cv_rel_version=6.0 |
| 11678 | cf_cv_abi_version=6 |
| 11679 | { echo "$as_me:11679: WARNING: overriding ABI version to $cf_cv_abi_version" >&5 |
| 11680 | echo "$as_me: WARNING: overriding ABI version to $cf_cv_abi_version" >&2;} |
| 11681 | ;; |
| 11682 | esac |
| 11683 | fi |
| 11684 | |
| 11685 | NCURSES_EXT_COLORS=1 |
| 11686 | |
| 11687 | cat >>confdefs.h <<\EOF |
| 11688 | #define NCURSES_EXT_COLORS 1 |
| 11689 | EOF |
| 11690 | |
| 11691 | fi |
| 11692 | fi |
| 11693 | |
| 11694 | ### use option --enable-ext-mouse to modify coding to support 5-button mice |
| 11695 | echo "$as_me:11695: checking if you want to use extended mouse encoding" >&5 |
| 11696 | echo $ECHO_N "checking if you want to use extended mouse encoding... $ECHO_C" >&6 |
| 11697 | |
| 11698 | # Check whether --enable-ext-mouse or --disable-ext-mouse was given. |
| 11699 | if test "${enable_ext_mouse+set}" = set; then |
| 11700 | enableval="$enable_ext_mouse" |
| 11701 | with_ext_mouse=$enableval |
| 11702 | else |
| 11703 | with_ext_mouse=$cf_dft_ext_mouse |
| 11704 | fi; |
| 11705 | echo "$as_me:11705: result: $with_ext_mouse" >&5 |
| 11706 | echo "${ECHO_T}$with_ext_mouse" >&6 |
| 11707 | NCURSES_MOUSE_VERSION=1 |
| 11708 | if test "x$with_ext_mouse" = xyes ; then |
| 11709 | NCURSES_MOUSE_VERSION=2 |
| 11710 | |
| 11711 | if test "${with_abi_version+set}" != set; then |
| 11712 | case $cf_cv_rel_version in |
| 11713 | (5.*) |
| 11714 | cf_cv_rel_version=6.0 |
| 11715 | cf_cv_abi_version=6 |
| 11716 | { echo "$as_me:11716: WARNING: overriding ABI version to $cf_cv_abi_version" >&5 |
| 11717 | echo "$as_me: WARNING: overriding ABI version to $cf_cv_abi_version" >&2;} |
| 11718 | ;; |
| 11719 | esac |
| 11720 | fi |
| 11721 | |
| 11722 | fi |
| 11723 | |
| 11724 | ### use option --enable-ext-putwin to turn on extended screendumps |
| 11725 | echo "$as_me:11725: checking if you want to use extended putwin/screendump" >&5 |
| 11726 | echo $ECHO_N "checking if you want to use extended putwin/screendump... $ECHO_C" >&6 |
| 11727 | |
| 11728 | # Check whether --enable-ext-putwin or --disable-ext-putwin was given. |
| 11729 | if test "${enable_ext_putwin+set}" = set; then |
| 11730 | enableval="$enable_ext_putwin" |
| 11731 | with_ext_putwin=$enableval |
| 11732 | else |
| 11733 | with_ext_putwin=$cf_dft_ext_putwin |
| 11734 | fi; |
| 11735 | echo "$as_me:11735: result: $with_ext_putwin" >&5 |
| 11736 | echo "${ECHO_T}$with_ext_putwin" >&6 |
| 11737 | if test "x$with_ext_putwin" = xyes ; then |
| 11738 | |
| 11739 | cat >>confdefs.h <<\EOF |
| 11740 | #define NCURSES_EXT_PUTWIN 1 |
| 11741 | EOF |
| 11742 | |
| 11743 | fi |
| 11744 | |
| 11745 | echo "$as_me:11745: checking if you want \$NCURSES_NO_PADDING code" >&5 |
| 11746 | echo $ECHO_N "checking if you want \$NCURSES_NO_PADDING code... $ECHO_C" >&6 |
| 11747 | |
| 11748 | # Check whether --enable-no-padding or --disable-no-padding was given. |
| 11749 | if test "${enable_no_padding+set}" = set; then |
| 11750 | enableval="$enable_no_padding" |
| 11751 | with_no_padding=$enableval |
| 11752 | else |
| 11753 | with_no_padding=$with_ext_funcs |
| 11754 | fi; |
| 11755 | echo "$as_me:11755: result: $with_no_padding" >&5 |
| 11756 | echo "${ECHO_T}$with_no_padding" >&6 |
| 11757 | test "x$with_no_padding" = xyes && |
| 11758 | cat >>confdefs.h <<\EOF |
| 11759 | #define NCURSES_NO_PADDING 1 |
| 11760 | EOF |
| 11761 | |
| 11762 | echo "$as_me:11762: checking for ANSI C header files" >&5 |
| 11763 | echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6 |
| 11764 | if test "${ac_cv_header_stdc+set}" = set; then |
| 11765 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 11766 | else |
| 11767 | cat >conftest.$ac_ext <<_ACEOF |
| 11768 | #line 11768 "configure" |
| 11769 | #include "confdefs.h" |
| 11770 | #include <stdlib.h> |
| 11771 | #include <stdarg.h> |
| 11772 | #include <string.h> |
| 11773 | #include <float.h> |
| 11774 | |
| 11775 | _ACEOF |
| 11776 | if { (eval echo "$as_me:11776: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 11777 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 11778 | ac_status=$? |
| 11779 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 11780 | rm -f conftest.er1 |
| 11781 | cat conftest.err >&5 |
| 11782 | echo "$as_me:11782: \$? = $ac_status" >&5 |
| 11783 | (exit $ac_status); } >/dev/null; then |
| 11784 | if test -s conftest.err; then |
| 11785 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 11786 | else |
| 11787 | ac_cpp_err= |
| 11788 | fi |
| 11789 | else |
| 11790 | ac_cpp_err=yes |
| 11791 | fi |
| 11792 | if test -z "$ac_cpp_err"; then |
| 11793 | ac_cv_header_stdc=yes |
| 11794 | else |
| 11795 | echo "$as_me: failed program was:" >&5 |
| 11796 | cat conftest.$ac_ext >&5 |
| 11797 | ac_cv_header_stdc=no |
| 11798 | fi |
| 11799 | rm -f conftest.err conftest.$ac_ext |
| 11800 | |
| 11801 | if test $ac_cv_header_stdc = yes; then |
| 11802 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 11803 | cat >conftest.$ac_ext <<_ACEOF |
| 11804 | #line 11804 "configure" |
| 11805 | #include "confdefs.h" |
| 11806 | #include <string.h> |
| 11807 | |
| 11808 | _ACEOF |
| 11809 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 11810 | egrep "memchr" >/dev/null 2>&1; then |
| 11811 | : |
| 11812 | else |
| 11813 | ac_cv_header_stdc=no |
| 11814 | fi |
| 11815 | rm -rf conftest* |
| 11816 | |
| 11817 | fi |
| 11818 | |
| 11819 | if test $ac_cv_header_stdc = yes; then |
| 11820 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 11821 | cat >conftest.$ac_ext <<_ACEOF |
| 11822 | #line 11822 "configure" |
| 11823 | #include "confdefs.h" |
| 11824 | #include <stdlib.h> |
| 11825 | |
| 11826 | _ACEOF |
| 11827 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 11828 | egrep "free" >/dev/null 2>&1; then |
| 11829 | : |
| 11830 | else |
| 11831 | ac_cv_header_stdc=no |
| 11832 | fi |
| 11833 | rm -rf conftest* |
| 11834 | |
| 11835 | fi |
| 11836 | |
| 11837 | if test $ac_cv_header_stdc = yes; then |
| 11838 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 11839 | if test "$cross_compiling" = yes; then |
| 11840 | : |
| 11841 | else |
| 11842 | cat >conftest.$ac_ext <<_ACEOF |
| 11843 | #line 11843 "configure" |
| 11844 | #include "confdefs.h" |
| 11845 | #include <ctype.h> |
| 11846 | #if ((' ' & 0x0FF) == 0x020) |
| 11847 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 11848 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 11849 | #else |
| 11850 | # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \ |
| 11851 | || ('j' <= (c) && (c) <= 'r') \ |
| 11852 | || ('s' <= (c) && (c) <= 'z')) |
| 11853 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 11854 | #endif |
| 11855 | |
| 11856 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 11857 | int |
| 11858 | main () |
| 11859 | { |
| 11860 | int i; |
| 11861 | for (i = 0; i < 256; i++) |
| 11862 | if (XOR (islower (i), ISLOWER (i)) |
| 11863 | || toupper (i) != TOUPPER (i)) |
| 11864 | $ac_main_return(2); |
| 11865 | $ac_main_return (0); |
| 11866 | } |
| 11867 | _ACEOF |
| 11868 | rm -f conftest$ac_exeext |
| 11869 | if { (eval echo "$as_me:11869: \"$ac_link\"") >&5 |
| 11870 | (eval $ac_link) 2>&5 |
| 11871 | ac_status=$? |
| 11872 | echo "$as_me:11872: \$? = $ac_status" >&5 |
| 11873 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 11874 | { (eval echo "$as_me:11874: \"$ac_try\"") >&5 |
| 11875 | (eval $ac_try) 2>&5 |
| 11876 | ac_status=$? |
| 11877 | echo "$as_me:11877: \$? = $ac_status" >&5 |
| 11878 | (exit $ac_status); }; }; then |
| 11879 | : |
| 11880 | else |
| 11881 | echo "$as_me: program exited with status $ac_status" >&5 |
| 11882 | echo "$as_me: failed program was:" >&5 |
| 11883 | cat conftest.$ac_ext >&5 |
| 11884 | ac_cv_header_stdc=no |
| 11885 | fi |
| 11886 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 11887 | fi |
| 11888 | fi |
| 11889 | fi |
| 11890 | echo "$as_me:11890: result: $ac_cv_header_stdc" >&5 |
| 11891 | echo "${ECHO_T}$ac_cv_header_stdc" >&6 |
| 11892 | if test $ac_cv_header_stdc = yes; then |
| 11893 | |
| 11894 | cat >>confdefs.h <<\EOF |
| 11895 | #define STDC_HEADERS 1 |
| 11896 | EOF |
| 11897 | |
| 11898 | fi |
| 11899 | |
| 11900 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
| 11901 | |
| 11902 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
| 11903 | inttypes.h stdint.h unistd.h |
| 11904 | do |
| 11905 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 11906 | echo "$as_me:11906: checking for $ac_header" >&5 |
| 11907 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 11908 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 11909 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 11910 | else |
| 11911 | cat >conftest.$ac_ext <<_ACEOF |
| 11912 | #line 11912 "configure" |
| 11913 | #include "confdefs.h" |
| 11914 | $ac_includes_default |
| 11915 | #include <$ac_header> |
| 11916 | _ACEOF |
| 11917 | rm -f conftest.$ac_objext |
| 11918 | if { (eval echo "$as_me:11918: \"$ac_compile\"") >&5 |
| 11919 | (eval $ac_compile) 2>&5 |
| 11920 | ac_status=$? |
| 11921 | echo "$as_me:11921: \$? = $ac_status" >&5 |
| 11922 | (exit $ac_status); } && |
| 11923 | { ac_try='test -s conftest.$ac_objext' |
| 11924 | { (eval echo "$as_me:11924: \"$ac_try\"") >&5 |
| 11925 | (eval $ac_try) 2>&5 |
| 11926 | ac_status=$? |
| 11927 | echo "$as_me:11927: \$? = $ac_status" >&5 |
| 11928 | (exit $ac_status); }; }; then |
| 11929 | eval "$as_ac_Header=yes" |
| 11930 | else |
| 11931 | echo "$as_me: failed program was:" >&5 |
| 11932 | cat conftest.$ac_ext >&5 |
| 11933 | eval "$as_ac_Header=no" |
| 11934 | fi |
| 11935 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 11936 | fi |
| 11937 | echo "$as_me:11937: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 11938 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 11939 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 11940 | cat >>confdefs.h <<EOF |
| 11941 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 11942 | EOF |
| 11943 | |
| 11944 | fi |
| 11945 | done |
| 11946 | |
| 11947 | echo "$as_me:11947: checking for signed char" >&5 |
| 11948 | echo $ECHO_N "checking for signed char... $ECHO_C" >&6 |
| 11949 | if test "${ac_cv_type_signed_char+set}" = set; then |
| 11950 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 11951 | else |
| 11952 | cat >conftest.$ac_ext <<_ACEOF |
| 11953 | #line 11953 "configure" |
| 11954 | #include "confdefs.h" |
| 11955 | $ac_includes_default |
| 11956 | int |
| 11957 | main () |
| 11958 | { |
| 11959 | if ((signed char *) 0) |
| 11960 | return 0; |
| 11961 | if (sizeof (signed char)) |
| 11962 | return 0; |
| 11963 | ; |
| 11964 | return 0; |
| 11965 | } |
| 11966 | _ACEOF |
| 11967 | rm -f conftest.$ac_objext |
| 11968 | if { (eval echo "$as_me:11968: \"$ac_compile\"") >&5 |
| 11969 | (eval $ac_compile) 2>&5 |
| 11970 | ac_status=$? |
| 11971 | echo "$as_me:11971: \$? = $ac_status" >&5 |
| 11972 | (exit $ac_status); } && |
| 11973 | { ac_try='test -s conftest.$ac_objext' |
| 11974 | { (eval echo "$as_me:11974: \"$ac_try\"") >&5 |
| 11975 | (eval $ac_try) 2>&5 |
| 11976 | ac_status=$? |
| 11977 | echo "$as_me:11977: \$? = $ac_status" >&5 |
| 11978 | (exit $ac_status); }; }; then |
| 11979 | ac_cv_type_signed_char=yes |
| 11980 | else |
| 11981 | echo "$as_me: failed program was:" >&5 |
| 11982 | cat conftest.$ac_ext >&5 |
| 11983 | ac_cv_type_signed_char=no |
| 11984 | fi |
| 11985 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 11986 | fi |
| 11987 | echo "$as_me:11987: result: $ac_cv_type_signed_char" >&5 |
| 11988 | echo "${ECHO_T}$ac_cv_type_signed_char" >&6 |
| 11989 | |
| 11990 | echo "$as_me:11990: checking size of signed char" >&5 |
| 11991 | echo $ECHO_N "checking size of signed char... $ECHO_C" >&6 |
| 11992 | if test "${ac_cv_sizeof_signed_char+set}" = set; then |
| 11993 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 11994 | else |
| 11995 | if test "$ac_cv_type_signed_char" = yes; then |
| 11996 | if test "$cross_compiling" = yes; then |
| 11997 | # Depending upon the size, compute the lo and hi bounds. |
| 11998 | cat >conftest.$ac_ext <<_ACEOF |
| 11999 | #line 11999 "configure" |
| 12000 | #include "confdefs.h" |
| 12001 | $ac_includes_default |
| 12002 | int |
| 12003 | main () |
| 12004 | { |
| 12005 | int _array_ [1 - 2 * !((sizeof (signed char)) >= 0)] |
| 12006 | ; |
| 12007 | return 0; |
| 12008 | } |
| 12009 | _ACEOF |
| 12010 | rm -f conftest.$ac_objext |
| 12011 | if { (eval echo "$as_me:12011: \"$ac_compile\"") >&5 |
| 12012 | (eval $ac_compile) 2>&5 |
| 12013 | ac_status=$? |
| 12014 | echo "$as_me:12014: \$? = $ac_status" >&5 |
| 12015 | (exit $ac_status); } && |
| 12016 | { ac_try='test -s conftest.$ac_objext' |
| 12017 | { (eval echo "$as_me:12017: \"$ac_try\"") >&5 |
| 12018 | (eval $ac_try) 2>&5 |
| 12019 | ac_status=$? |
| 12020 | echo "$as_me:12020: \$? = $ac_status" >&5 |
| 12021 | (exit $ac_status); }; }; then |
| 12022 | ac_lo=0 ac_mid=0 |
| 12023 | while :; do |
| 12024 | cat >conftest.$ac_ext <<_ACEOF |
| 12025 | #line 12025 "configure" |
| 12026 | #include "confdefs.h" |
| 12027 | $ac_includes_default |
| 12028 | int |
| 12029 | main () |
| 12030 | { |
| 12031 | int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)] |
| 12032 | ; |
| 12033 | return 0; |
| 12034 | } |
| 12035 | _ACEOF |
| 12036 | rm -f conftest.$ac_objext |
| 12037 | if { (eval echo "$as_me:12037: \"$ac_compile\"") >&5 |
| 12038 | (eval $ac_compile) 2>&5 |
| 12039 | ac_status=$? |
| 12040 | echo "$as_me:12040: \$? = $ac_status" >&5 |
| 12041 | (exit $ac_status); } && |
| 12042 | { ac_try='test -s conftest.$ac_objext' |
| 12043 | { (eval echo "$as_me:12043: \"$ac_try\"") >&5 |
| 12044 | (eval $ac_try) 2>&5 |
| 12045 | ac_status=$? |
| 12046 | echo "$as_me:12046: \$? = $ac_status" >&5 |
| 12047 | (exit $ac_status); }; }; then |
| 12048 | ac_hi=$ac_mid; break |
| 12049 | else |
| 12050 | echo "$as_me: failed program was:" >&5 |
| 12051 | cat conftest.$ac_ext >&5 |
| 12052 | ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1` |
| 12053 | fi |
| 12054 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 12055 | done |
| 12056 | else |
| 12057 | echo "$as_me: failed program was:" >&5 |
| 12058 | cat conftest.$ac_ext >&5 |
| 12059 | ac_hi=-1 ac_mid=-1 |
| 12060 | while :; do |
| 12061 | cat >conftest.$ac_ext <<_ACEOF |
| 12062 | #line 12062 "configure" |
| 12063 | #include "confdefs.h" |
| 12064 | $ac_includes_default |
| 12065 | int |
| 12066 | main () |
| 12067 | { |
| 12068 | int _array_ [1 - 2 * !((sizeof (signed char)) >= $ac_mid)] |
| 12069 | ; |
| 12070 | return 0; |
| 12071 | } |
| 12072 | _ACEOF |
| 12073 | rm -f conftest.$ac_objext |
| 12074 | if { (eval echo "$as_me:12074: \"$ac_compile\"") >&5 |
| 12075 | (eval $ac_compile) 2>&5 |
| 12076 | ac_status=$? |
| 12077 | echo "$as_me:12077: \$? = $ac_status" >&5 |
| 12078 | (exit $ac_status); } && |
| 12079 | { ac_try='test -s conftest.$ac_objext' |
| 12080 | { (eval echo "$as_me:12080: \"$ac_try\"") >&5 |
| 12081 | (eval $ac_try) 2>&5 |
| 12082 | ac_status=$? |
| 12083 | echo "$as_me:12083: \$? = $ac_status" >&5 |
| 12084 | (exit $ac_status); }; }; then |
| 12085 | ac_lo=$ac_mid; break |
| 12086 | else |
| 12087 | echo "$as_me: failed program was:" >&5 |
| 12088 | cat conftest.$ac_ext >&5 |
| 12089 | ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid` |
| 12090 | fi |
| 12091 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 12092 | done |
| 12093 | fi |
| 12094 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 12095 | # Binary search between lo and hi bounds. |
| 12096 | while test "x$ac_lo" != "x$ac_hi"; do |
| 12097 | ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` |
| 12098 | cat >conftest.$ac_ext <<_ACEOF |
| 12099 | #line 12099 "configure" |
| 12100 | #include "confdefs.h" |
| 12101 | $ac_includes_default |
| 12102 | int |
| 12103 | main () |
| 12104 | { |
| 12105 | int _array_ [1 - 2 * !((sizeof (signed char)) <= $ac_mid)] |
| 12106 | ; |
| 12107 | return 0; |
| 12108 | } |
| 12109 | _ACEOF |
| 12110 | rm -f conftest.$ac_objext |
| 12111 | if { (eval echo "$as_me:12111: \"$ac_compile\"") >&5 |
| 12112 | (eval $ac_compile) 2>&5 |
| 12113 | ac_status=$? |
| 12114 | echo "$as_me:12114: \$? = $ac_status" >&5 |
| 12115 | (exit $ac_status); } && |
| 12116 | { ac_try='test -s conftest.$ac_objext' |
| 12117 | { (eval echo "$as_me:12117: \"$ac_try\"") >&5 |
| 12118 | (eval $ac_try) 2>&5 |
| 12119 | ac_status=$? |
| 12120 | echo "$as_me:12120: \$? = $ac_status" >&5 |
| 12121 | (exit $ac_status); }; }; then |
| 12122 | ac_hi=$ac_mid |
| 12123 | else |
| 12124 | echo "$as_me: failed program was:" >&5 |
| 12125 | cat conftest.$ac_ext >&5 |
| 12126 | ac_lo=`expr $ac_mid + 1` |
| 12127 | fi |
| 12128 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 12129 | done |
| 12130 | ac_cv_sizeof_signed_char=$ac_lo |
| 12131 | else |
| 12132 | if test "$cross_compiling" = yes; then |
| 12133 | { { echo "$as_me:12133: error: cannot run test program while cross compiling" >&5 |
| 12134 | echo "$as_me: error: cannot run test program while cross compiling" >&2;} |
| 12135 | { (exit 1); exit 1; }; } |
| 12136 | else |
| 12137 | cat >conftest.$ac_ext <<_ACEOF |
| 12138 | #line 12138 "configure" |
| 12139 | #include "confdefs.h" |
| 12140 | $ac_includes_default |
| 12141 | int |
| 12142 | main () |
| 12143 | { |
| 12144 | FILE *f = fopen ("conftest.val", "w"); |
| 12145 | if (!f) |
| 12146 | $ac_main_return (1); |
| 12147 | fprintf (f, "%d", (sizeof (signed char))); |
| 12148 | fclose (f); |
| 12149 | ; |
| 12150 | return 0; |
| 12151 | } |
| 12152 | _ACEOF |
| 12153 | rm -f conftest$ac_exeext |
| 12154 | if { (eval echo "$as_me:12154: \"$ac_link\"") >&5 |
| 12155 | (eval $ac_link) 2>&5 |
| 12156 | ac_status=$? |
| 12157 | echo "$as_me:12157: \$? = $ac_status" >&5 |
| 12158 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 12159 | { (eval echo "$as_me:12159: \"$ac_try\"") >&5 |
| 12160 | (eval $ac_try) 2>&5 |
| 12161 | ac_status=$? |
| 12162 | echo "$as_me:12162: \$? = $ac_status" >&5 |
| 12163 | (exit $ac_status); }; }; then |
| 12164 | ac_cv_sizeof_signed_char=`cat conftest.val` |
| 12165 | else |
| 12166 | echo "$as_me: program exited with status $ac_status" >&5 |
| 12167 | echo "$as_me: failed program was:" >&5 |
| 12168 | cat conftest.$ac_ext >&5 |
| 12169 | fi |
| 12170 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 12171 | fi |
| 12172 | fi |
| 12173 | rm -f conftest.val |
| 12174 | else |
| 12175 | ac_cv_sizeof_signed_char=0 |
| 12176 | fi |
| 12177 | fi |
| 12178 | echo "$as_me:12178: result: $ac_cv_sizeof_signed_char" >&5 |
| 12179 | echo "${ECHO_T}$ac_cv_sizeof_signed_char" >&6 |
| 12180 | cat >>confdefs.h <<EOF |
| 12181 | #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char |
| 12182 | EOF |
| 12183 | |
| 12184 | if test "$ac_cv_sizeof_signed_char" = 1 ; then |
| 12185 | NCURSES_SBOOL="signed char" |
| 12186 | else |
| 12187 | NCURSES_SBOOL="char" |
| 12188 | fi |
| 12189 | echo "$as_me:12189: checking if you want to use signed Boolean array in term.h" >&5 |
| 12190 | echo $ECHO_N "checking if you want to use signed Boolean array in term.h... $ECHO_C" >&6 |
| 12191 | |
| 12192 | # Check whether --enable-signed-char or --disable-signed-char was given. |
| 12193 | if test "${enable_signed_char+set}" = set; then |
| 12194 | enableval="$enable_signed_char" |
| 12195 | with_signed_char=$enableval |
| 12196 | else |
| 12197 | with_signed_char=no |
| 12198 | fi; |
| 12199 | echo "$as_me:12199: result: $with_signed_char" >&5 |
| 12200 | echo "${ECHO_T}$with_signed_char" >&6 |
| 12201 | test "x$with_signed_char" != xyes && NCURSES_SBOOL="char" |
| 12202 | |
| 12203 | ### use option --enable-sigwinch to turn on use of SIGWINCH logic |
| 12204 | echo "$as_me:12204: checking if you want SIGWINCH handler" >&5 |
| 12205 | echo $ECHO_N "checking if you want SIGWINCH handler... $ECHO_C" >&6 |
| 12206 | |
| 12207 | # Check whether --enable-sigwinch or --disable-sigwinch was given. |
| 12208 | if test "${enable_sigwinch+set}" = set; then |
| 12209 | enableval="$enable_sigwinch" |
| 12210 | with_sigwinch=$enableval |
| 12211 | else |
| 12212 | with_sigwinch=$with_ext_funcs |
| 12213 | fi; |
| 12214 | echo "$as_me:12214: result: $with_sigwinch" >&5 |
| 12215 | echo "${ECHO_T}$with_sigwinch" >&6 |
| 12216 | test "x$with_sigwinch" = xyes && |
| 12217 | cat >>confdefs.h <<\EOF |
| 12218 | #define USE_SIGWINCH 1 |
| 12219 | EOF |
| 12220 | |
| 12221 | ### use option --enable-tcap-names to allow user to define new capabilities |
| 12222 | echo "$as_me:12222: checking if you want user-definable terminal capabilities like termcap" >&5 |
| 12223 | echo $ECHO_N "checking if you want user-definable terminal capabilities like termcap... $ECHO_C" >&6 |
| 12224 | |
| 12225 | # Check whether --enable-tcap-names or --disable-tcap-names was given. |
| 12226 | if test "${enable_tcap_names+set}" = set; then |
| 12227 | enableval="$enable_tcap_names" |
| 12228 | with_tcap_names=$enableval |
| 12229 | else |
| 12230 | with_tcap_names=$with_ext_funcs |
| 12231 | fi; |
| 12232 | echo "$as_me:12232: result: $with_tcap_names" >&5 |
| 12233 | echo "${ECHO_T}$with_tcap_names" >&6 |
| 12234 | NCURSES_XNAMES=0 |
| 12235 | test "x$with_tcap_names" = xyes && NCURSES_XNAMES=1 |
| 12236 | |
| 12237 | ############################################################################### |
| 12238 | # These options are relatively safe to experiment with. |
| 12239 | |
| 12240 | echo "$as_me:12240: checking if you want all development code" >&5 |
| 12241 | echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6 |
| 12242 | |
| 12243 | # Check whether --with-develop or --without-develop was given. |
| 12244 | if test "${with_develop+set}" = set; then |
| 12245 | withval="$with_develop" |
| 12246 | with_develop=$withval |
| 12247 | else |
| 12248 | with_develop=no |
| 12249 | fi; |
| 12250 | echo "$as_me:12250: result: $with_develop" >&5 |
| 12251 | echo "${ECHO_T}$with_develop" >&6 |
| 12252 | |
| 12253 | ### use option --enable-hard-tabs to turn on use of hard-tabs optimize |
| 12254 | echo "$as_me:12254: checking if you want hard-tabs code" >&5 |
| 12255 | echo $ECHO_N "checking if you want hard-tabs code... $ECHO_C" >&6 |
| 12256 | |
| 12257 | # Check whether --enable-hard-tabs or --disable-hard-tabs was given. |
| 12258 | if test "${enable_hard_tabs+set}" = set; then |
| 12259 | enableval="$enable_hard_tabs" |
| 12260 | |
| 12261 | else |
| 12262 | enable_hard_tabs=$with_develop |
| 12263 | fi; |
| 12264 | echo "$as_me:12264: result: $enable_hard_tabs" >&5 |
| 12265 | echo "${ECHO_T}$enable_hard_tabs" >&6 |
| 12266 | test "x$enable_hard_tabs" = xyes && |
| 12267 | cat >>confdefs.h <<\EOF |
| 12268 | #define USE_HARD_TABS 1 |
| 12269 | EOF |
| 12270 | |
| 12271 | ### use option --enable-xmc-glitch to turn on use of magic-cookie optimize |
| 12272 | echo "$as_me:12272: checking if you want limited support for xmc" >&5 |
| 12273 | echo $ECHO_N "checking if you want limited support for xmc... $ECHO_C" >&6 |
| 12274 | |
| 12275 | # Check whether --enable-xmc-glitch or --disable-xmc-glitch was given. |
| 12276 | if test "${enable_xmc_glitch+set}" = set; then |
| 12277 | enableval="$enable_xmc_glitch" |
| 12278 | |
| 12279 | else |
| 12280 | enable_xmc_glitch=$with_develop |
| 12281 | fi; |
| 12282 | echo "$as_me:12282: result: $enable_xmc_glitch" >&5 |
| 12283 | echo "${ECHO_T}$enable_xmc_glitch" >&6 |
| 12284 | test "x$enable_xmc_glitch" = xyes && |
| 12285 | cat >>confdefs.h <<\EOF |
| 12286 | #define USE_XMC_SUPPORT 1 |
| 12287 | EOF |
| 12288 | |
| 12289 | ############################################################################### |
| 12290 | # These are just experimental, probably should not be in a package: |
| 12291 | |
| 12292 | echo "$as_me:12292: checking if you do not want to assume colors are white-on-black" >&5 |
| 12293 | echo $ECHO_N "checking if you do not want to assume colors are white-on-black... $ECHO_C" >&6 |
| 12294 | |
| 12295 | # Check whether --enable-assumed-color or --disable-assumed-color was given. |
| 12296 | if test "${enable_assumed_color+set}" = set; then |
| 12297 | enableval="$enable_assumed_color" |
| 12298 | with_assumed_color=$enableval |
| 12299 | else |
| 12300 | with_assumed_color=yes |
| 12301 | fi; |
| 12302 | echo "$as_me:12302: result: $with_assumed_color" >&5 |
| 12303 | echo "${ECHO_T}$with_assumed_color" >&6 |
| 12304 | test "x$with_assumed_color" = xyes && |
| 12305 | cat >>confdefs.h <<\EOF |
| 12306 | #define USE_ASSUMED_COLOR 1 |
| 12307 | EOF |
| 12308 | |
| 12309 | ### use option --enable-hashmap to turn on use of hashmap scrolling logic |
| 12310 | echo "$as_me:12310: checking if you want hashmap scrolling-optimization code" >&5 |
| 12311 | echo $ECHO_N "checking if you want hashmap scrolling-optimization code... $ECHO_C" >&6 |
| 12312 | |
| 12313 | # Check whether --enable-hashmap or --disable-hashmap was given. |
| 12314 | if test "${enable_hashmap+set}" = set; then |
| 12315 | enableval="$enable_hashmap" |
| 12316 | with_hashmap=$enableval |
| 12317 | else |
| 12318 | with_hashmap=yes |
| 12319 | fi; |
| 12320 | echo "$as_me:12320: result: $with_hashmap" >&5 |
| 12321 | echo "${ECHO_T}$with_hashmap" >&6 |
| 12322 | test "x$with_hashmap" = xyes && |
| 12323 | cat >>confdefs.h <<\EOF |
| 12324 | #define USE_HASHMAP 1 |
| 12325 | EOF |
| 12326 | |
| 12327 | ### use option --enable-colorfgbg to turn on use of $COLORFGBG environment |
| 12328 | echo "$as_me:12328: checking if you want colorfgbg code" >&5 |
| 12329 | echo $ECHO_N "checking if you want colorfgbg code... $ECHO_C" >&6 |
| 12330 | |
| 12331 | # Check whether --enable-colorfgbg or --disable-colorfgbg was given. |
| 12332 | if test "${enable_colorfgbg+set}" = set; then |
| 12333 | enableval="$enable_colorfgbg" |
| 12334 | with_colorfgbg=$enableval |
| 12335 | else |
| 12336 | with_colorfgbg=no |
| 12337 | fi; |
| 12338 | echo "$as_me:12338: result: $with_colorfgbg" >&5 |
| 12339 | echo "${ECHO_T}$with_colorfgbg" >&6 |
| 12340 | test "x$with_colorfgbg" = xyes && |
| 12341 | cat >>confdefs.h <<\EOF |
| 12342 | #define USE_COLORFGBG 1 |
| 12343 | EOF |
| 12344 | |
| 12345 | ### use option --enable-interop to turn on use of bindings used for interop |
| 12346 | echo "$as_me:12346: checking if you want interop bindings" >&5 |
| 12347 | echo $ECHO_N "checking if you want interop bindings... $ECHO_C" >&6 |
| 12348 | |
| 12349 | # Check whether --enable-interop or --disable-interop was given. |
| 12350 | if test "${enable_interop+set}" = set; then |
| 12351 | enableval="$enable_interop" |
| 12352 | with_exp_interop=$enableval |
| 12353 | else |
| 12354 | with_exp_interop=$cf_dft_interop |
| 12355 | fi; |
| 12356 | echo "$as_me:12356: result: $with_exp_interop" >&5 |
| 12357 | echo "${ECHO_T}$with_exp_interop" >&6 |
| 12358 | |
| 12359 | NCURSES_INTEROP_FUNCS=0 |
| 12360 | test "x$with_exp_interop" = xyes && NCURSES_INTEROP_FUNCS=1 |
| 12361 | |
| 12362 | # This is still experimental (20080329), but should ultimately be moved to |
| 12363 | # the script-block --with-normal, etc. |
| 12364 | |
| 12365 | echo "$as_me:12365: checking if you want to link with the pthread library" >&5 |
| 12366 | echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6 |
| 12367 | |
| 12368 | # Check whether --with-pthread or --without-pthread was given. |
| 12369 | if test "${with_pthread+set}" = set; then |
| 12370 | withval="$with_pthread" |
| 12371 | with_pthread=$withval |
| 12372 | else |
| 12373 | with_pthread=no |
| 12374 | fi; |
| 12375 | echo "$as_me:12375: result: $with_pthread" >&5 |
| 12376 | echo "${ECHO_T}$with_pthread" >&6 |
| 12377 | |
| 12378 | if test "$with_pthread" != no ; then |
| 12379 | echo "$as_me:12379: checking for pthread.h" >&5 |
| 12380 | echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6 |
| 12381 | if test "${ac_cv_header_pthread_h+set}" = set; then |
| 12382 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12383 | else |
| 12384 | cat >conftest.$ac_ext <<_ACEOF |
| 12385 | #line 12385 "configure" |
| 12386 | #include "confdefs.h" |
| 12387 | #include <pthread.h> |
| 12388 | _ACEOF |
| 12389 | if { (eval echo "$as_me:12389: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 12390 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 12391 | ac_status=$? |
| 12392 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 12393 | rm -f conftest.er1 |
| 12394 | cat conftest.err >&5 |
| 12395 | echo "$as_me:12395: \$? = $ac_status" >&5 |
| 12396 | (exit $ac_status); } >/dev/null; then |
| 12397 | if test -s conftest.err; then |
| 12398 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 12399 | else |
| 12400 | ac_cpp_err= |
| 12401 | fi |
| 12402 | else |
| 12403 | ac_cpp_err=yes |
| 12404 | fi |
| 12405 | if test -z "$ac_cpp_err"; then |
| 12406 | ac_cv_header_pthread_h=yes |
| 12407 | else |
| 12408 | echo "$as_me: failed program was:" >&5 |
| 12409 | cat conftest.$ac_ext >&5 |
| 12410 | ac_cv_header_pthread_h=no |
| 12411 | fi |
| 12412 | rm -f conftest.err conftest.$ac_ext |
| 12413 | fi |
| 12414 | echo "$as_me:12414: result: $ac_cv_header_pthread_h" >&5 |
| 12415 | echo "${ECHO_T}$ac_cv_header_pthread_h" >&6 |
| 12416 | if test $ac_cv_header_pthread_h = yes; then |
| 12417 | |
| 12418 | cat >>confdefs.h <<\EOF |
| 12419 | #define HAVE_PTHREADS_H 1 |
| 12420 | EOF |
| 12421 | |
| 12422 | for cf_lib_pthread in pthread c_r |
| 12423 | do |
| 12424 | echo "$as_me:12424: checking if we can link with the $cf_lib_pthread library" >&5 |
| 12425 | echo $ECHO_N "checking if we can link with the $cf_lib_pthread library... $ECHO_C" >&6 |
| 12426 | cf_save_LIBS="$LIBS" |
| 12427 | |
| 12428 | cf_add_libs="-l$cf_lib_pthread" |
| 12429 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12430 | for cf_add_1lib in $LIBS |
| 12431 | do |
| 12432 | for cf_add_2lib in $cf_add_libs |
| 12433 | do |
| 12434 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12435 | then |
| 12436 | cf_add_1lib= |
| 12437 | break |
| 12438 | fi |
| 12439 | done |
| 12440 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12441 | done |
| 12442 | LIBS="$cf_add_libs" |
| 12443 | |
| 12444 | cat >conftest.$ac_ext <<_ACEOF |
| 12445 | #line 12445 "configure" |
| 12446 | #include "confdefs.h" |
| 12447 | |
| 12448 | #include <pthread.h> |
| 12449 | |
| 12450 | int |
| 12451 | main () |
| 12452 | { |
| 12453 | |
| 12454 | int rc = pthread_create(0,0,0,0); |
| 12455 | int r2 = pthread_mutexattr_settype(0, 0); |
| 12456 | |
| 12457 | ; |
| 12458 | return 0; |
| 12459 | } |
| 12460 | _ACEOF |
| 12461 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12462 | if { (eval echo "$as_me:12462: \"$ac_link\"") >&5 |
| 12463 | (eval $ac_link) 2>&5 |
| 12464 | ac_status=$? |
| 12465 | echo "$as_me:12465: \$? = $ac_status" >&5 |
| 12466 | (exit $ac_status); } && |
| 12467 | { ac_try='test -s conftest$ac_exeext' |
| 12468 | { (eval echo "$as_me:12468: \"$ac_try\"") >&5 |
| 12469 | (eval $ac_try) 2>&5 |
| 12470 | ac_status=$? |
| 12471 | echo "$as_me:12471: \$? = $ac_status" >&5 |
| 12472 | (exit $ac_status); }; }; then |
| 12473 | with_pthread=yes |
| 12474 | else |
| 12475 | echo "$as_me: failed program was:" >&5 |
| 12476 | cat conftest.$ac_ext >&5 |
| 12477 | with_pthread=no |
| 12478 | fi |
| 12479 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12480 | LIBS="$cf_save_LIBS" |
| 12481 | echo "$as_me:12481: result: $with_pthread" >&5 |
| 12482 | echo "${ECHO_T}$with_pthread" >&6 |
| 12483 | test "$with_pthread" = yes && break |
| 12484 | done |
| 12485 | |
| 12486 | if test "$with_pthread" = yes ; then |
| 12487 | |
| 12488 | cf_add_libs="-l$cf_lib_pthread" |
| 12489 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12490 | for cf_add_1lib in $LIBS |
| 12491 | do |
| 12492 | for cf_add_2lib in $cf_add_libs |
| 12493 | do |
| 12494 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12495 | then |
| 12496 | cf_add_1lib= |
| 12497 | break |
| 12498 | fi |
| 12499 | done |
| 12500 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12501 | done |
| 12502 | LIBS="$cf_add_libs" |
| 12503 | |
| 12504 | cat >>confdefs.h <<\EOF |
| 12505 | #define HAVE_LIBPTHREADS 1 |
| 12506 | EOF |
| 12507 | |
| 12508 | else |
| 12509 | { { echo "$as_me:12509: error: Cannot link with pthread library" >&5 |
| 12510 | echo "$as_me: error: Cannot link with pthread library" >&2;} |
| 12511 | { (exit 1); exit 1; }; } |
| 12512 | fi |
| 12513 | |
| 12514 | fi |
| 12515 | |
| 12516 | fi |
| 12517 | |
| 12518 | if test "x$with_pthread" != xno; then |
| 12519 | echo "$as_me:12519: checking for pthread_kill" >&5 |
| 12520 | echo $ECHO_N "checking for pthread_kill... $ECHO_C" >&6 |
| 12521 | if test "${ac_cv_func_pthread_kill+set}" = set; then |
| 12522 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12523 | else |
| 12524 | cat >conftest.$ac_ext <<_ACEOF |
| 12525 | #line 12525 "configure" |
| 12526 | #include "confdefs.h" |
| 12527 | /* System header to define __stub macros and hopefully few prototypes, |
| 12528 | which can conflict with char pthread_kill (); below. */ |
| 12529 | #include <assert.h> |
| 12530 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 12531 | #ifdef __cplusplus |
| 12532 | extern "C" |
| 12533 | #endif |
| 12534 | /* We use char because int might match the return type of a gcc2 |
| 12535 | builtin and then its argument prototype would still apply. */ |
| 12536 | char pthread_kill (); |
| 12537 | char (*f) (); |
| 12538 | |
| 12539 | int |
| 12540 | main () |
| 12541 | { |
| 12542 | /* The GNU C library defines this for functions which it implements |
| 12543 | to always fail with ENOSYS. Some functions are actually named |
| 12544 | something starting with __ and the normal name is an alias. */ |
| 12545 | #if defined (__stub_pthread_kill) || defined (__stub___pthread_kill) |
| 12546 | choke me |
| 12547 | #else |
| 12548 | f = pthread_kill; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 12549 | #endif |
| 12550 | |
| 12551 | ; |
| 12552 | return 0; |
| 12553 | } |
| 12554 | _ACEOF |
| 12555 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 12556 | if { (eval echo "$as_me:12556: \"$ac_link\"") >&5 |
| 12557 | (eval $ac_link) 2>&5 |
| 12558 | ac_status=$? |
| 12559 | echo "$as_me:12559: \$? = $ac_status" >&5 |
| 12560 | (exit $ac_status); } && |
| 12561 | { ac_try='test -s conftest$ac_exeext' |
| 12562 | { (eval echo "$as_me:12562: \"$ac_try\"") >&5 |
| 12563 | (eval $ac_try) 2>&5 |
| 12564 | ac_status=$? |
| 12565 | echo "$as_me:12565: \$? = $ac_status" >&5 |
| 12566 | (exit $ac_status); }; }; then |
| 12567 | ac_cv_func_pthread_kill=yes |
| 12568 | else |
| 12569 | echo "$as_me: failed program was:" >&5 |
| 12570 | cat conftest.$ac_ext >&5 |
| 12571 | ac_cv_func_pthread_kill=no |
| 12572 | fi |
| 12573 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 12574 | fi |
| 12575 | echo "$as_me:12575: result: $ac_cv_func_pthread_kill" >&5 |
| 12576 | echo "${ECHO_T}$ac_cv_func_pthread_kill" >&6 |
| 12577 | if test $ac_cv_func_pthread_kill = yes; then |
| 12578 | |
| 12579 | echo "$as_me:12579: checking if you want to allow EINTR in wgetch with pthreads" >&5 |
| 12580 | echo $ECHO_N "checking if you want to allow EINTR in wgetch with pthreads... $ECHO_C" >&6 |
| 12581 | |
| 12582 | # Check whether --enable-pthreads-eintr or --disable-pthreads-eintr was given. |
| 12583 | if test "${enable_pthreads_eintr+set}" = set; then |
| 12584 | enableval="$enable_pthreads_eintr" |
| 12585 | use_pthreads_eintr=$enableval |
| 12586 | else |
| 12587 | use_pthreads_eintr=no |
| 12588 | fi; |
| 12589 | echo "$as_me:12589: result: $use_pthreads_eintr" >&5 |
| 12590 | echo "${ECHO_T}$use_pthreads_eintr" >&6 |
| 12591 | if test "x$use_pthreads_eintr" = xyes ; then |
| 12592 | |
| 12593 | cat >>confdefs.h <<\EOF |
| 12594 | #define USE_PTHREADS_EINTR 1 |
| 12595 | EOF |
| 12596 | |
| 12597 | fi |
| 12598 | fi |
| 12599 | |
| 12600 | echo "$as_me:12600: checking if you want to use weak-symbols for pthreads" >&5 |
| 12601 | echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6 |
| 12602 | |
| 12603 | # Check whether --enable-weak-symbols or --disable-weak-symbols was given. |
| 12604 | if test "${enable_weak_symbols+set}" = set; then |
| 12605 | enableval="$enable_weak_symbols" |
| 12606 | use_weak_symbols=$enableval |
| 12607 | else |
| 12608 | use_weak_symbols=no |
| 12609 | fi; |
| 12610 | echo "$as_me:12610: result: $use_weak_symbols" >&5 |
| 12611 | echo "${ECHO_T}$use_weak_symbols" >&6 |
| 12612 | if test "x$use_weak_symbols" = xyes ; then |
| 12613 | |
| 12614 | echo "$as_me:12614: checking if $CC supports weak symbols" >&5 |
| 12615 | echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6 |
| 12616 | if test "${cf_cv_weak_symbols+set}" = set; then |
| 12617 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 12618 | else |
| 12619 | |
| 12620 | cat >conftest.$ac_ext <<_ACEOF |
| 12621 | #line 12621 "configure" |
| 12622 | #include "confdefs.h" |
| 12623 | |
| 12624 | #include <stdio.h> |
| 12625 | int |
| 12626 | main () |
| 12627 | { |
| 12628 | |
| 12629 | #if defined(__GNUC__) |
| 12630 | # if defined __USE_ISOC99 |
| 12631 | # define _cat_pragma(exp) _Pragma(#exp) |
| 12632 | # define _weak_pragma(exp) _cat_pragma(weak name) |
| 12633 | # else |
| 12634 | # define _weak_pragma(exp) |
| 12635 | # endif |
| 12636 | # define _declare(name) __extension__ extern __typeof__(name) name |
| 12637 | # define weak_symbol(name) _weak_pragma(name) _declare(name) __attribute__((weak)) |
| 12638 | #endif |
| 12639 | |
| 12640 | weak_symbol(fopen); |
| 12641 | |
| 12642 | ; |
| 12643 | return 0; |
| 12644 | } |
| 12645 | _ACEOF |
| 12646 | rm -f conftest.$ac_objext |
| 12647 | if { (eval echo "$as_me:12647: \"$ac_compile\"") >&5 |
| 12648 | (eval $ac_compile) 2>&5 |
| 12649 | ac_status=$? |
| 12650 | echo "$as_me:12650: \$? = $ac_status" >&5 |
| 12651 | (exit $ac_status); } && |
| 12652 | { ac_try='test -s conftest.$ac_objext' |
| 12653 | { (eval echo "$as_me:12653: \"$ac_try\"") >&5 |
| 12654 | (eval $ac_try) 2>&5 |
| 12655 | ac_status=$? |
| 12656 | echo "$as_me:12656: \$? = $ac_status" >&5 |
| 12657 | (exit $ac_status); }; }; then |
| 12658 | cf_cv_weak_symbols=yes |
| 12659 | else |
| 12660 | echo "$as_me: failed program was:" >&5 |
| 12661 | cat conftest.$ac_ext >&5 |
| 12662 | cf_cv_weak_symbols=no |
| 12663 | fi |
| 12664 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 12665 | |
| 12666 | fi |
| 12667 | echo "$as_me:12667: result: $cf_cv_weak_symbols" >&5 |
| 12668 | echo "${ECHO_T}$cf_cv_weak_symbols" >&6 |
| 12669 | |
| 12670 | else |
| 12671 | cf_cv_weak_symbols=no |
| 12672 | fi |
| 12673 | |
| 12674 | if test "x$cf_cv_weak_symbols" = xyes ; then |
| 12675 | |
| 12676 | cat >>confdefs.h <<\EOF |
| 12677 | #define USE_WEAK_SYMBOLS 1 |
| 12678 | EOF |
| 12679 | |
| 12680 | fi |
| 12681 | fi |
| 12682 | |
| 12683 | PTHREAD= |
| 12684 | if test "x$with_pthread" = "xyes" ; then |
| 12685 | |
| 12686 | cat >>confdefs.h <<\EOF |
| 12687 | #define USE_PTHREADS 1 |
| 12688 | EOF |
| 12689 | |
| 12690 | enable_reentrant=yes |
| 12691 | if test "x$cf_cv_weak_symbols" = xyes ; then |
| 12692 | PTHREAD=-lpthread |
| 12693 | fi |
| 12694 | fi |
| 12695 | |
| 12696 | # Reentrant code has to be opaque; there's little advantage to making ncurses |
| 12697 | # opaque outside of that, so there is no --enable-opaque option. We can use |
| 12698 | # this option without --with-pthreads, but this will be always set for |
| 12699 | # pthreads. |
| 12700 | echo "$as_me:12700: checking if you want reentrant code" >&5 |
| 12701 | echo $ECHO_N "checking if you want reentrant code... $ECHO_C" >&6 |
| 12702 | |
| 12703 | # Check whether --enable-reentrant or --disable-reentrant was given. |
| 12704 | if test "${enable_reentrant+set}" = set; then |
| 12705 | enableval="$enable_reentrant" |
| 12706 | with_reentrant=$enableval |
| 12707 | else |
| 12708 | with_reentrant=no |
| 12709 | fi; |
| 12710 | echo "$as_me:12710: result: $with_reentrant" >&5 |
| 12711 | echo "${ECHO_T}$with_reentrant" >&6 |
| 12712 | if test "x$with_reentrant" = xyes ; then |
| 12713 | cf_cv_enable_reentrant=1 |
| 12714 | cf_cv_enable_opaque="NCURSES_INTERNALS" |
| 12715 | NCURSES_OPAQUE=1 |
| 12716 | NCURSES_SIZE_T=int |
| 12717 | if test "x$cf_cv_weak_symbols" = xyes ; then |
| 12718 | |
| 12719 | # remove pthread library from $LIBS |
| 12720 | LIBS=`echo "$LIBS" | sed -e 's/-lpthread[ ]//g' -e 's/-lpthread$//'` |
| 12721 | |
| 12722 | cf_add_libs="-lpthread" |
| 12723 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12724 | for cf_add_1lib in $TEST_LIBS |
| 12725 | do |
| 12726 | for cf_add_2lib in $cf_add_libs |
| 12727 | do |
| 12728 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12729 | then |
| 12730 | cf_add_1lib= |
| 12731 | break |
| 12732 | fi |
| 12733 | done |
| 12734 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12735 | done |
| 12736 | TEST_LIBS="$cf_add_libs" |
| 12737 | |
| 12738 | cf_add_libs="-lpthread" |
| 12739 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 12740 | for cf_add_1lib in $TEST_LIBS2 |
| 12741 | do |
| 12742 | for cf_add_2lib in $cf_add_libs |
| 12743 | do |
| 12744 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 12745 | then |
| 12746 | cf_add_1lib= |
| 12747 | break |
| 12748 | fi |
| 12749 | done |
| 12750 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 12751 | done |
| 12752 | TEST_LIBS2="$cf_add_libs" |
| 12753 | |
| 12754 | else |
| 12755 | # when not using weak symbols but with_reentrant, |
| 12756 | # add 't' to the library suffix on all platforms |
| 12757 | # except cygwin, where we only do that if ALSO |
| 12758 | # compiling with full thread support. |
| 12759 | case "$host" in |
| 12760 | (*cygwin* | *msys*) |
| 12761 | if test "$with_pthread" = "yes" ; then |
| 12762 | if test "x$disable_lib_suffixes" = "xno" ; then |
| 12763 | LIB_SUFFIX="t${LIB_SUFFIX}" |
| 12764 | fi |
| 12765 | fi ;; |
| 12766 | (*) |
| 12767 | if test "x$disable_lib_suffixes" = "xno" ; then |
| 12768 | LIB_SUFFIX="t${LIB_SUFFIX}" |
| 12769 | fi |
| 12770 | ;; |
| 12771 | esac |
| 12772 | fi |
| 12773 | |
| 12774 | cat >>confdefs.h <<\EOF |
| 12775 | #define USE_REENTRANT 1 |
| 12776 | EOF |
| 12777 | |
| 12778 | if test "${with_abi_version+set}" != set; then |
| 12779 | case $cf_cv_rel_version in |
| 12780 | (5.*) |
| 12781 | cf_cv_rel_version=6.0 |
| 12782 | cf_cv_abi_version=6 |
| 12783 | { echo "$as_me:12783: WARNING: overriding ABI version to $cf_cv_abi_version" >&5 |
| 12784 | echo "$as_me: WARNING: overriding ABI version to $cf_cv_abi_version" >&2;} |
| 12785 | ;; |
| 12786 | esac |
| 12787 | fi |
| 12788 | |
| 12789 | else |
| 12790 | cf_cv_enable_reentrant=0 |
| 12791 | cf_cv_enable_opaque="NCURSES_OPAQUE" |
| 12792 | NCURSES_OPAQUE=0 |
| 12793 | NCURSES_SIZE_T=short |
| 12794 | fi |
| 12795 | |
| 12796 | ### Allow using a different wrap-prefix |
| 12797 | if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then |
| 12798 | echo "$as_me:12798: checking for prefix used to wrap public variables" >&5 |
| 12799 | echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6 |
| 12800 | |
| 12801 | # Check whether --with-wrap-prefix or --without-wrap-prefix was given. |
| 12802 | if test "${with_wrap_prefix+set}" = set; then |
| 12803 | withval="$with_wrap_prefix" |
| 12804 | NCURSES_WRAP_PREFIX=$withval |
| 12805 | else |
| 12806 | NCURSES_WRAP_PREFIX=_nc_ |
| 12807 | fi; |
| 12808 | echo "$as_me:12808: result: $NCURSES_WRAP_PREFIX" >&5 |
| 12809 | echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6 |
| 12810 | else |
| 12811 | NCURSES_WRAP_PREFIX=_nc_ |
| 12812 | fi |
| 12813 | |
| 12814 | cat >>confdefs.h <<EOF |
| 12815 | #define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX" |
| 12816 | EOF |
| 12817 | |
| 12818 | echo "$as_me:12818: checking if you want experimental safe-sprintf code" >&5 |
| 12819 | echo $ECHO_N "checking if you want experimental safe-sprintf code... $ECHO_C" >&6 |
| 12820 | |
| 12821 | # Check whether --enable-safe-sprintf or --disable-safe-sprintf was given. |
| 12822 | if test "${enable_safe_sprintf+set}" = set; then |
| 12823 | enableval="$enable_safe_sprintf" |
| 12824 | with_safe_sprintf=$enableval |
| 12825 | else |
| 12826 | with_safe_sprintf=no |
| 12827 | fi; |
| 12828 | echo "$as_me:12828: result: $with_safe_sprintf" >&5 |
| 12829 | echo "${ECHO_T}$with_safe_sprintf" >&6 |
| 12830 | test "x$with_safe_sprintf" = xyes && |
| 12831 | cat >>confdefs.h <<\EOF |
| 12832 | #define USE_SAFE_SPRINTF 1 |
| 12833 | EOF |
| 12834 | |
| 12835 | ### use option --disable-scroll-hints to turn off use of scroll-hints scrolling logic |
| 12836 | # when hashmap is used scroll hints are useless |
| 12837 | if test "$with_hashmap" = no ; then |
| 12838 | echo "$as_me:12838: checking if you want to experiment without scrolling-hints code" >&5 |
| 12839 | echo $ECHO_N "checking if you want to experiment without scrolling-hints code... $ECHO_C" >&6 |
| 12840 | |
| 12841 | # Check whether --enable-scroll-hints or --disable-scroll-hints was given. |
| 12842 | if test "${enable_scroll_hints+set}" = set; then |
| 12843 | enableval="$enable_scroll_hints" |
| 12844 | with_scroll_hints=$enableval |
| 12845 | else |
| 12846 | with_scroll_hints=yes |
| 12847 | fi; |
| 12848 | echo "$as_me:12848: result: $with_scroll_hints" >&5 |
| 12849 | echo "${ECHO_T}$with_scroll_hints" >&6 |
| 12850 | test "x$with_scroll_hints" = xyes && |
| 12851 | cat >>confdefs.h <<\EOF |
| 12852 | #define USE_SCROLL_HINTS 1 |
| 12853 | EOF |
| 12854 | |
| 12855 | fi |
| 12856 | |
| 12857 | echo "$as_me:12857: checking if you want wgetch-events code" >&5 |
| 12858 | echo $ECHO_N "checking if you want wgetch-events code... $ECHO_C" >&6 |
| 12859 | |
| 12860 | # Check whether --enable-wgetch-events or --disable-wgetch-events was given. |
| 12861 | if test "${enable_wgetch_events+set}" = set; then |
| 12862 | enableval="$enable_wgetch_events" |
| 12863 | with_wgetch_events=$enableval |
| 12864 | else |
| 12865 | with_wgetch_events=no |
| 12866 | fi; |
| 12867 | echo "$as_me:12867: result: $with_wgetch_events" >&5 |
| 12868 | echo "${ECHO_T}$with_wgetch_events" >&6 |
| 12869 | test "x$with_wgetch_events" = xyes && |
| 12870 | cat >>confdefs.h <<\EOF |
| 12871 | #define NCURSES_WGETCH_EVENTS 1 |
| 12872 | EOF |
| 12873 | |
| 12874 | ############################################################################### |
| 12875 | |
| 12876 | ### use option --disable-echo to suppress full display compiling commands |
| 12877 | |
| 12878 | echo "$as_me:12878: checking if you want to see long compiling messages" >&5 |
| 12879 | echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6 |
| 12880 | |
| 12881 | # Check whether --enable-echo or --disable-echo was given. |
| 12882 | if test "${enable_echo+set}" = set; then |
| 12883 | enableval="$enable_echo" |
| 12884 | test "$enableval" != no && enableval=yes |
| 12885 | if test "$enableval" != "yes" ; then |
| 12886 | |
| 12887 | ECHO_LT='--silent' |
| 12888 | ECHO_LD='@echo linking $@;' |
| 12889 | RULE_CC='@echo compiling $<' |
| 12890 | SHOW_CC='@echo compiling $@' |
| 12891 | ECHO_CC='@' |
| 12892 | |
| 12893 | else |
| 12894 | |
| 12895 | ECHO_LT='' |
| 12896 | ECHO_LD='' |
| 12897 | RULE_CC='' |
| 12898 | SHOW_CC='' |
| 12899 | ECHO_CC='' |
| 12900 | |
| 12901 | fi |
| 12902 | else |
| 12903 | enableval=yes |
| 12904 | |
| 12905 | ECHO_LT='' |
| 12906 | ECHO_LD='' |
| 12907 | RULE_CC='' |
| 12908 | SHOW_CC='' |
| 12909 | ECHO_CC='' |
| 12910 | |
| 12911 | fi; |
| 12912 | echo "$as_me:12912: result: $enableval" >&5 |
| 12913 | echo "${ECHO_T}$enableval" >&6 |
| 12914 | |
| 12915 | if test "x$enable_echo" = xyes; then |
| 12916 | ECHO_LINK= |
| 12917 | else |
| 12918 | ECHO_LINK='@ echo linking $@ ... ;' |
| 12919 | test -n "$LIBTOOL" && LIBTOOL="$LIBTOOL --silent" |
| 12920 | test -n "$LIBTOOL_CXX" && LIBTOOL_CXX="$LIBTOOL_CXX --silent" |
| 12921 | fi |
| 12922 | |
| 12923 | ### use option --enable-warnings to turn on all gcc warnings |
| 12924 | echo "$as_me:12924: checking if you want to see compiler warnings" >&5 |
| 12925 | echo $ECHO_N "checking if you want to see compiler warnings... $ECHO_C" >&6 |
| 12926 | |
| 12927 | # Check whether --enable-warnings or --disable-warnings was given. |
| 12928 | if test "${enable_warnings+set}" = set; then |
| 12929 | enableval="$enable_warnings" |
| 12930 | with_warnings=$enableval |
| 12931 | fi; |
| 12932 | echo "$as_me:12932: result: $with_warnings" >&5 |
| 12933 | echo "${ECHO_T}$with_warnings" >&6 |
| 12934 | |
| 12935 | if test "x$with_warnings" = "xyes"; then |
| 12936 | |
| 12937 | ADAFLAGS="$ADAFLAGS -gnatg" |
| 12938 | |
| 12939 | INTEL_COMPILER=no |
| 12940 | |
| 12941 | if test "$GCC" = yes ; then |
| 12942 | case $host_os in |
| 12943 | (linux*|gnu*) |
| 12944 | echo "$as_me:12944: checking if this is really Intel C compiler" >&5 |
| 12945 | echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6 |
| 12946 | cf_save_CFLAGS="$CFLAGS" |
| 12947 | CFLAGS="$CFLAGS -no-gcc" |
| 12948 | cat >conftest.$ac_ext <<_ACEOF |
| 12949 | #line 12949 "configure" |
| 12950 | #include "confdefs.h" |
| 12951 | |
| 12952 | int |
| 12953 | main () |
| 12954 | { |
| 12955 | |
| 12956 | #ifdef __INTEL_COMPILER |
| 12957 | #else |
| 12958 | make an error |
| 12959 | #endif |
| 12960 | |
| 12961 | ; |
| 12962 | return 0; |
| 12963 | } |
| 12964 | _ACEOF |
| 12965 | rm -f conftest.$ac_objext |
| 12966 | if { (eval echo "$as_me:12966: \"$ac_compile\"") >&5 |
| 12967 | (eval $ac_compile) 2>&5 |
| 12968 | ac_status=$? |
| 12969 | echo "$as_me:12969: \$? = $ac_status" >&5 |
| 12970 | (exit $ac_status); } && |
| 12971 | { ac_try='test -s conftest.$ac_objext' |
| 12972 | { (eval echo "$as_me:12972: \"$ac_try\"") >&5 |
| 12973 | (eval $ac_try) 2>&5 |
| 12974 | ac_status=$? |
| 12975 | echo "$as_me:12975: \$? = $ac_status" >&5 |
| 12976 | (exit $ac_status); }; }; then |
| 12977 | INTEL_COMPILER=yes |
| 12978 | cf_save_CFLAGS="$cf_save_CFLAGS -we147" |
| 12979 | |
| 12980 | else |
| 12981 | echo "$as_me: failed program was:" >&5 |
| 12982 | cat conftest.$ac_ext >&5 |
| 12983 | fi |
| 12984 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 12985 | CFLAGS="$cf_save_CFLAGS" |
| 12986 | echo "$as_me:12986: result: $INTEL_COMPILER" >&5 |
| 12987 | echo "${ECHO_T}$INTEL_COMPILER" >&6 |
| 12988 | ;; |
| 12989 | esac |
| 12990 | fi |
| 12991 | |
| 12992 | CLANG_COMPILER=no |
| 12993 | |
| 12994 | if test "$GCC" = yes ; then |
| 12995 | echo "$as_me:12995: checking if this is really Clang C compiler" >&5 |
| 12996 | echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6 |
| 12997 | cf_save_CFLAGS="$CFLAGS" |
| 12998 | CFLAGS="$CFLAGS -Qunused-arguments" |
| 12999 | cat >conftest.$ac_ext <<_ACEOF |
| 13000 | #line 13000 "configure" |
| 13001 | #include "confdefs.h" |
| 13002 | |
| 13003 | int |
| 13004 | main () |
| 13005 | { |
| 13006 | |
| 13007 | #ifdef __clang__ |
| 13008 | #else |
| 13009 | make an error |
| 13010 | #endif |
| 13011 | |
| 13012 | ; |
| 13013 | return 0; |
| 13014 | } |
| 13015 | _ACEOF |
| 13016 | rm -f conftest.$ac_objext |
| 13017 | if { (eval echo "$as_me:13017: \"$ac_compile\"") >&5 |
| 13018 | (eval $ac_compile) 2>&5 |
| 13019 | ac_status=$? |
| 13020 | echo "$as_me:13020: \$? = $ac_status" >&5 |
| 13021 | (exit $ac_status); } && |
| 13022 | { ac_try='test -s conftest.$ac_objext' |
| 13023 | { (eval echo "$as_me:13023: \"$ac_try\"") >&5 |
| 13024 | (eval $ac_try) 2>&5 |
| 13025 | ac_status=$? |
| 13026 | echo "$as_me:13026: \$? = $ac_status" >&5 |
| 13027 | (exit $ac_status); }; }; then |
| 13028 | CLANG_COMPILER=yes |
| 13029 | cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments" |
| 13030 | |
| 13031 | else |
| 13032 | echo "$as_me: failed program was:" >&5 |
| 13033 | cat conftest.$ac_ext >&5 |
| 13034 | fi |
| 13035 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 13036 | CFLAGS="$cf_save_CFLAGS" |
| 13037 | echo "$as_me:13037: result: $CLANG_COMPILER" >&5 |
| 13038 | echo "${ECHO_T}$CLANG_COMPILER" >&6 |
| 13039 | fi |
| 13040 | |
| 13041 | cat > conftest.$ac_ext <<EOF |
| 13042 | #line 13042 "${as_me:-configure}" |
| 13043 | int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; } |
| 13044 | EOF |
| 13045 | |
| 13046 | if test "$INTEL_COMPILER" = yes |
| 13047 | then |
| 13048 | # The "-wdXXX" options suppress warnings: |
| 13049 | # remark #1419: external declaration in primary source file |
| 13050 | # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem) |
| 13051 | # remark #1684: conversion from pointer to same-sized integral type (potential portability problem) |
| 13052 | # remark #193: zero used for undefined preprocessing identifier |
| 13053 | # remark #593: variable "curs_sb_left_arrow" was set but never used |
| 13054 | # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits |
| 13055 | # remark #869: parameter "tw" was never referenced |
| 13056 | # remark #981: operands are evaluated in unspecified order |
| 13057 | # warning #279: controlling expression is constant |
| 13058 | |
| 13059 | { echo "$as_me:13059: checking for $CC warning options..." >&5 |
| 13060 | echo "$as_me: checking for $CC warning options..." >&6;} |
| 13061 | cf_save_CFLAGS="$CFLAGS" |
| 13062 | EXTRA_CFLAGS="-Wall" |
| 13063 | for cf_opt in \ |
| 13064 | wd1419 \ |
| 13065 | wd1683 \ |
| 13066 | wd1684 \ |
| 13067 | wd193 \ |
| 13068 | wd593 \ |
| 13069 | wd279 \ |
| 13070 | wd810 \ |
| 13071 | wd869 \ |
| 13072 | wd981 |
| 13073 | do |
| 13074 | CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt" |
| 13075 | if { (eval echo "$as_me:13075: \"$ac_compile\"") >&5 |
| 13076 | (eval $ac_compile) 2>&5 |
| 13077 | ac_status=$? |
| 13078 | echo "$as_me:13078: \$? = $ac_status" >&5 |
| 13079 | (exit $ac_status); }; then |
| 13080 | test -n "$verbose" && echo "$as_me:13080: result: ... -$cf_opt" >&5 |
| 13081 | echo "${ECHO_T}... -$cf_opt" >&6 |
| 13082 | EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt" |
| 13083 | fi |
| 13084 | done |
| 13085 | CFLAGS="$cf_save_CFLAGS" |
| 13086 | |
| 13087 | elif test "$GCC" = yes |
| 13088 | then |
| 13089 | { echo "$as_me:13089: checking for $CC warning options..." >&5 |
| 13090 | echo "$as_me: checking for $CC warning options..." >&6;} |
| 13091 | cf_save_CFLAGS="$CFLAGS" |
| 13092 | EXTRA_CFLAGS= |
| 13093 | cf_warn_CONST="" |
| 13094 | test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings" |
| 13095 | cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs" |
| 13096 | test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings= |
| 13097 | for cf_opt in W Wall \ |
| 13098 | Wbad-function-cast \ |
| 13099 | Wcast-align \ |
| 13100 | Wcast-qual \ |
| 13101 | Wdeclaration-after-statement \ |
| 13102 | Wextra \ |
| 13103 | Winline \ |
| 13104 | Wmissing-declarations \ |
| 13105 | Wmissing-prototypes \ |
| 13106 | Wnested-externs \ |
| 13107 | Wpointer-arith \ |
| 13108 | Wshadow \ |
| 13109 | Wstrict-prototypes \ |
| 13110 | Wundef $cf_gcc_warnings $cf_warn_CONST Wno-unknown-pragmas Wswitch-enum |
| 13111 | do |
| 13112 | CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt" |
| 13113 | if { (eval echo "$as_me:13113: \"$ac_compile\"") >&5 |
| 13114 | (eval $ac_compile) 2>&5 |
| 13115 | ac_status=$? |
| 13116 | echo "$as_me:13116: \$? = $ac_status" >&5 |
| 13117 | (exit $ac_status); }; then |
| 13118 | test -n "$verbose" && echo "$as_me:13118: result: ... -$cf_opt" >&5 |
| 13119 | echo "${ECHO_T}... -$cf_opt" >&6 |
| 13120 | case $cf_opt in |
| 13121 | (Wcast-qual) |
| 13122 | CPPFLAGS="$CPPFLAGS -DXTSTRINGDEFINES" |
| 13123 | ;; |
| 13124 | (Winline) |
| 13125 | case $GCC_VERSION in |
| 13126 | ([34].*) |
| 13127 | test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6 |
| 13128 | |
| 13129 | echo "${as_me:-configure}:13129: testing feature is broken in gcc $GCC_VERSION ..." 1>&5 |
| 13130 | |
| 13131 | continue;; |
| 13132 | esac |
| 13133 | ;; |
| 13134 | (Wpointer-arith) |
| 13135 | case $GCC_VERSION in |
| 13136 | ([12].*) |
| 13137 | test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6 |
| 13138 | |
| 13139 | echo "${as_me:-configure}:13139: testing feature is broken in gcc $GCC_VERSION ..." 1>&5 |
| 13140 | |
| 13141 | continue;; |
| 13142 | esac |
| 13143 | ;; |
| 13144 | esac |
| 13145 | EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt" |
| 13146 | fi |
| 13147 | done |
| 13148 | CFLAGS="$cf_save_CFLAGS" |
| 13149 | fi |
| 13150 | rm -rf conftest* |
| 13151 | |
| 13152 | if test "x$cf_with_cxx" = xyes ; then |
| 13153 | |
| 13154 | INTEL_CPLUSPLUS=no |
| 13155 | |
| 13156 | if test "$GCC" = yes ; then |
| 13157 | case $host_os in |
| 13158 | (linux*|gnu*) |
| 13159 | echo "$as_me:13159: checking if this is really Intel C++ compiler" >&5 |
| 13160 | echo $ECHO_N "checking if this is really Intel C++ compiler... $ECHO_C" >&6 |
| 13161 | cf_save_CFLAGS="$CXXFLAGS" |
| 13162 | CXXFLAGS="$CXXFLAGS -no-gcc" |
| 13163 | cat >conftest.$ac_ext <<_ACEOF |
| 13164 | #line 13164 "configure" |
| 13165 | #include "confdefs.h" |
| 13166 | |
| 13167 | int |
| 13168 | main () |
| 13169 | { |
| 13170 | |
| 13171 | #ifdef __INTEL_COMPILER |
| 13172 | #else |
| 13173 | make an error |
| 13174 | #endif |
| 13175 | |
| 13176 | ; |
| 13177 | return 0; |
| 13178 | } |
| 13179 | _ACEOF |
| 13180 | rm -f conftest.$ac_objext |
| 13181 | if { (eval echo "$as_me:13181: \"$ac_compile\"") >&5 |
| 13182 | (eval $ac_compile) 2>&5 |
| 13183 | ac_status=$? |
| 13184 | echo "$as_me:13184: \$? = $ac_status" >&5 |
| 13185 | (exit $ac_status); } && |
| 13186 | { ac_try='test -s conftest.$ac_objext' |
| 13187 | { (eval echo "$as_me:13187: \"$ac_try\"") >&5 |
| 13188 | (eval $ac_try) 2>&5 |
| 13189 | ac_status=$? |
| 13190 | echo "$as_me:13190: \$? = $ac_status" >&5 |
| 13191 | (exit $ac_status); }; }; then |
| 13192 | INTEL_CPLUSPLUS=yes |
| 13193 | cf_save_CFLAGS="$cf_save_CFLAGS -we147" |
| 13194 | |
| 13195 | else |
| 13196 | echo "$as_me: failed program was:" >&5 |
| 13197 | cat conftest.$ac_ext >&5 |
| 13198 | fi |
| 13199 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 13200 | CXXFLAGS="$cf_save_CFLAGS" |
| 13201 | echo "$as_me:13201: result: $INTEL_CPLUSPLUS" >&5 |
| 13202 | echo "${ECHO_T}$INTEL_CPLUSPLUS" >&6 |
| 13203 | ;; |
| 13204 | esac |
| 13205 | fi |
| 13206 | |
| 13207 | CLANG_CPLUSPLUS=no |
| 13208 | |
| 13209 | if test "$GCC" = yes ; then |
| 13210 | echo "$as_me:13210: checking if this is really Clang C++ compiler" >&5 |
| 13211 | echo $ECHO_N "checking if this is really Clang C++ compiler... $ECHO_C" >&6 |
| 13212 | cf_save_CFLAGS="$CXXFLAGS" |
| 13213 | CXXFLAGS="$CXXFLAGS -Qunused-arguments" |
| 13214 | cat >conftest.$ac_ext <<_ACEOF |
| 13215 | #line 13215 "configure" |
| 13216 | #include "confdefs.h" |
| 13217 | |
| 13218 | int |
| 13219 | main () |
| 13220 | { |
| 13221 | |
| 13222 | #ifdef __clang__ |
| 13223 | #else |
| 13224 | make an error |
| 13225 | #endif |
| 13226 | |
| 13227 | ; |
| 13228 | return 0; |
| 13229 | } |
| 13230 | _ACEOF |
| 13231 | rm -f conftest.$ac_objext |
| 13232 | if { (eval echo "$as_me:13232: \"$ac_compile\"") >&5 |
| 13233 | (eval $ac_compile) 2>&5 |
| 13234 | ac_status=$? |
| 13235 | echo "$as_me:13235: \$? = $ac_status" >&5 |
| 13236 | (exit $ac_status); } && |
| 13237 | { ac_try='test -s conftest.$ac_objext' |
| 13238 | { (eval echo "$as_me:13238: \"$ac_try\"") >&5 |
| 13239 | (eval $ac_try) 2>&5 |
| 13240 | ac_status=$? |
| 13241 | echo "$as_me:13241: \$? = $ac_status" >&5 |
| 13242 | (exit $ac_status); }; }; then |
| 13243 | CLANG_CPLUSPLUS=yes |
| 13244 | cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments" |
| 13245 | |
| 13246 | else |
| 13247 | echo "$as_me: failed program was:" >&5 |
| 13248 | cat conftest.$ac_ext >&5 |
| 13249 | fi |
| 13250 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 13251 | CXXFLAGS="$cf_save_CFLAGS" |
| 13252 | echo "$as_me:13252: result: $CLANG_CPLUSPLUS" >&5 |
| 13253 | echo "${ECHO_T}$CLANG_CPLUSPLUS" >&6 |
| 13254 | fi |
| 13255 | |
| 13256 | ac_ext=cc |
| 13257 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 13258 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 13259 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 13260 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 13261 | ac_main_return=return |
| 13262 | |
| 13263 | cat > conftest.$ac_ext <<EOF |
| 13264 | #line 13264 "configure" |
| 13265 | int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; } |
| 13266 | EOF |
| 13267 | |
| 13268 | if test "$INTEL_CPLUSPLUS" = yes |
| 13269 | then |
| 13270 | # The "-wdXXX" options suppress warnings: |
| 13271 | # remark #1419: external declaration in primary source file |
| 13272 | # remark #1682: implicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem) |
| 13273 | # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem) |
| 13274 | # remark #1684: conversion from pointer to same-sized integral type (potential portability problem) |
| 13275 | # remark #193: zero used for undefined preprocessing identifier |
| 13276 | # remark #593: variable "curs_sb_left_arrow" was set but never used |
| 13277 | # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits |
| 13278 | # remark #869: parameter "tw" was never referenced |
| 13279 | # remark #981: operands are evaluated in unspecified order |
| 13280 | # warning #269: invalid format string conversion |
| 13281 | |
| 13282 | { echo "$as_me:13282: checking for $CC warning options..." >&5 |
| 13283 | echo "$as_me: checking for $CC warning options..." >&6;} |
| 13284 | cf_save_CXXFLAGS="$CXXFLAGS" |
| 13285 | EXTRA_CXXFLAGS="-Wall" |
| 13286 | for cf_opt in \ |
| 13287 | wd1419 \ |
| 13288 | wd1682 \ |
| 13289 | wd1683 \ |
| 13290 | wd1684 \ |
| 13291 | wd193 \ |
| 13292 | wd279 \ |
| 13293 | wd593 \ |
| 13294 | wd810 \ |
| 13295 | wd869 \ |
| 13296 | wd981 |
| 13297 | do |
| 13298 | CXXFLAGS="$cf_save_CXXFLAGS $EXTRA_CXXFLAGS -$cf_opt" |
| 13299 | if { (eval echo "$as_me:13299: \"$ac_compile\"") >&5 |
| 13300 | (eval $ac_compile) 2>&5 |
| 13301 | ac_status=$? |
| 13302 | echo "$as_me:13302: \$? = $ac_status" >&5 |
| 13303 | (exit $ac_status); }; then |
| 13304 | test -n "$verbose" && echo "$as_me:13304: result: ... -$cf_opt" >&5 |
| 13305 | echo "${ECHO_T}... -$cf_opt" >&6 |
| 13306 | EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -$cf_opt" |
| 13307 | fi |
| 13308 | done |
| 13309 | CXXFLAGS="$cf_save_CXXFLAGS" |
| 13310 | |
| 13311 | elif test "$GXX" = yes |
| 13312 | then |
| 13313 | { echo "$as_me:13313: checking for $CXX warning options..." >&5 |
| 13314 | echo "$as_me: checking for $CXX warning options..." >&6;} |
| 13315 | cf_save_CXXFLAGS="$CXXFLAGS" |
| 13316 | EXTRA_CXXFLAGS="-W -Wall" |
| 13317 | cf_gxx_extra_warnings="" |
| 13318 | test "$with_ext_const" = yes && cf_gxx_extra_warnings="Wwrite-strings" |
| 13319 | case "$GCC_VERSION" in |
| 13320 | ([1-2].*) |
| 13321 | ;; |
| 13322 | (*) |
| 13323 | cf_gxx_extra_warnings="$cf_gxx_extra_warnings Weffc++" |
| 13324 | ;; |
| 13325 | esac |
| 13326 | for cf_opt in \ |
| 13327 | Wabi \ |
| 13328 | fabi-version=0 \ |
| 13329 | Wextra \ |
| 13330 | Wignored-qualifiers \ |
| 13331 | Wlogical-op \ |
| 13332 | Woverloaded-virtual \ |
| 13333 | Wsign-promo \ |
| 13334 | Wsynth \ |
| 13335 | Wold-style-cast \ |
| 13336 | Wcast-align \ |
| 13337 | Wcast-qual \ |
| 13338 | Wpointer-arith \ |
| 13339 | Wshadow \ |
| 13340 | Wundef $cf_gxx_extra_warnings Wno-unused |
| 13341 | do |
| 13342 | CXXFLAGS="$cf_save_CXXFLAGS $EXTRA_CXXFLAGS -Werror -$cf_opt" |
| 13343 | if { (eval echo "$as_me:13343: \"$ac_compile\"") >&5 |
| 13344 | (eval $ac_compile) 2>&5 |
| 13345 | ac_status=$? |
| 13346 | echo "$as_me:13346: \$? = $ac_status" >&5 |
| 13347 | (exit $ac_status); }; then |
| 13348 | test -n "$verbose" && echo "$as_me:13348: result: ... -$cf_opt" >&5 |
| 13349 | echo "${ECHO_T}... -$cf_opt" >&6 |
| 13350 | EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -$cf_opt" |
| 13351 | else |
| 13352 | test -n "$verbose" && echo "$as_me:13352: result: ... no -$cf_opt" >&5 |
| 13353 | echo "${ECHO_T}... no -$cf_opt" >&6 |
| 13354 | fi |
| 13355 | done |
| 13356 | CXXFLAGS="$cf_save_CXXFLAGS" |
| 13357 | fi |
| 13358 | |
| 13359 | rm -rf conftest* |
| 13360 | ac_ext=c |
| 13361 | ac_cpp='$CPP $CPPFLAGS' |
| 13362 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 13363 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 13364 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 13365 | ac_main_return=return |
| 13366 | |
| 13367 | fi |
| 13368 | fi |
| 13369 | |
| 13370 | if test "$GCC" = yes |
| 13371 | then |
| 13372 | cat > conftest.i <<EOF |
| 13373 | #ifndef GCC_PRINTF |
| 13374 | #define GCC_PRINTF 0 |
| 13375 | #endif |
| 13376 | #ifndef GCC_SCANF |
| 13377 | #define GCC_SCANF 0 |
| 13378 | #endif |
| 13379 | #ifndef GCC_NORETURN |
| 13380 | #define GCC_NORETURN /* nothing */ |
| 13381 | #endif |
| 13382 | #ifndef GCC_UNUSED |
| 13383 | #define GCC_UNUSED /* nothing */ |
| 13384 | #endif |
| 13385 | EOF |
| 13386 | if test "$GCC" = yes |
| 13387 | then |
| 13388 | { echo "$as_me:13388: checking for $CC __attribute__ directives..." >&5 |
| 13389 | echo "$as_me: checking for $CC __attribute__ directives..." >&6;} |
| 13390 | cat > conftest.$ac_ext <<EOF |
| 13391 | #line 13391 "${as_me:-configure}" |
| 13392 | #include "confdefs.h" |
| 13393 | #include "conftest.h" |
| 13394 | #include "conftest.i" |
| 13395 | #if GCC_PRINTF |
| 13396 | #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var))) |
| 13397 | #else |
| 13398 | #define GCC_PRINTFLIKE(fmt,var) /*nothing*/ |
| 13399 | #endif |
| 13400 | #if GCC_SCANF |
| 13401 | #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var))) |
| 13402 | #else |
| 13403 | #define GCC_SCANFLIKE(fmt,var) /*nothing*/ |
| 13404 | #endif |
| 13405 | extern void wow(char *,...) GCC_SCANFLIKE(1,2); |
| 13406 | extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN; |
| 13407 | extern void foo(void) GCC_NORETURN; |
| 13408 | int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; } |
| 13409 | EOF |
| 13410 | cf_printf_attribute=no |
| 13411 | cf_scanf_attribute=no |
| 13412 | for cf_attribute in scanf printf unused noreturn |
| 13413 | do |
| 13414 | |
| 13415 | cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 13416 | |
| 13417 | cf_directive="__attribute__(($cf_attribute))" |
| 13418 | echo "checking for $CC $cf_directive" 1>&5 |
| 13419 | |
| 13420 | case $cf_attribute in |
| 13421 | (printf) |
| 13422 | cf_printf_attribute=yes |
| 13423 | cat >conftest.h <<EOF |
| 13424 | #define GCC_$cf_ATTRIBUTE 1 |
| 13425 | EOF |
| 13426 | ;; |
| 13427 | (scanf) |
| 13428 | cf_scanf_attribute=yes |
| 13429 | cat >conftest.h <<EOF |
| 13430 | #define GCC_$cf_ATTRIBUTE 1 |
| 13431 | EOF |
| 13432 | ;; |
| 13433 | (*) |
| 13434 | cat >conftest.h <<EOF |
| 13435 | #define GCC_$cf_ATTRIBUTE $cf_directive |
| 13436 | EOF |
| 13437 | ;; |
| 13438 | esac |
| 13439 | |
| 13440 | if { (eval echo "$as_me:13440: \"$ac_compile\"") >&5 |
| 13441 | (eval $ac_compile) 2>&5 |
| 13442 | ac_status=$? |
| 13443 | echo "$as_me:13443: \$? = $ac_status" >&5 |
| 13444 | (exit $ac_status); }; then |
| 13445 | test -n "$verbose" && echo "$as_me:13445: result: ... $cf_attribute" >&5 |
| 13446 | echo "${ECHO_T}... $cf_attribute" >&6 |
| 13447 | cat conftest.h >>confdefs.h |
| 13448 | case $cf_attribute in |
| 13449 | (noreturn) |
| 13450 | |
| 13451 | cat >>confdefs.h <<EOF |
| 13452 | #define GCC_NORETURN $cf_directive |
| 13453 | EOF |
| 13454 | |
| 13455 | ;; |
| 13456 | (printf) |
| 13457 | cf_value='/* nothing */' |
| 13458 | if test "$cf_printf_attribute" != no ; then |
| 13459 | cf_value='__attribute__((format(printf,fmt,var)))' |
| 13460 | |
| 13461 | cat >>confdefs.h <<\EOF |
| 13462 | #define GCC_PRINTF 1 |
| 13463 | EOF |
| 13464 | |
| 13465 | fi |
| 13466 | |
| 13467 | cat >>confdefs.h <<EOF |
| 13468 | #define GCC_PRINTFLIKE(fmt,var) $cf_value |
| 13469 | EOF |
| 13470 | |
| 13471 | ;; |
| 13472 | (scanf) |
| 13473 | cf_value='/* nothing */' |
| 13474 | if test "$cf_scanf_attribute" != no ; then |
| 13475 | cf_value='__attribute__((format(scanf,fmt,var)))' |
| 13476 | |
| 13477 | cat >>confdefs.h <<\EOF |
| 13478 | #define GCC_SCANF 1 |
| 13479 | EOF |
| 13480 | |
| 13481 | fi |
| 13482 | |
| 13483 | cat >>confdefs.h <<EOF |
| 13484 | #define GCC_SCANFLIKE(fmt,var) $cf_value |
| 13485 | EOF |
| 13486 | |
| 13487 | ;; |
| 13488 | (unused) |
| 13489 | |
| 13490 | cat >>confdefs.h <<EOF |
| 13491 | #define GCC_UNUSED $cf_directive |
| 13492 | EOF |
| 13493 | |
| 13494 | ;; |
| 13495 | esac |
| 13496 | fi |
| 13497 | done |
| 13498 | else |
| 13499 | fgrep define conftest.i >>confdefs.h |
| 13500 | fi |
| 13501 | rm -rf conftest* |
| 13502 | fi |
| 13503 | |
| 13504 | echo "$as_me:13504: checking if you want to work around bogus compiler/loader warnings" >&5 |
| 13505 | echo $ECHO_N "checking if you want to work around bogus compiler/loader warnings... $ECHO_C" >&6 |
| 13506 | |
| 13507 | # Check whether --enable-string-hacks or --disable-string-hacks was given. |
| 13508 | if test "${enable_string_hacks+set}" = set; then |
| 13509 | enableval="$enable_string_hacks" |
| 13510 | with_string_hacks=$enableval |
| 13511 | else |
| 13512 | with_string_hacks=no |
| 13513 | fi; |
| 13514 | echo "$as_me:13514: result: $with_string_hacks" >&5 |
| 13515 | echo "${ECHO_T}$with_string_hacks" >&6 |
| 13516 | |
| 13517 | if test "x$with_string_hacks" = "xyes"; then |
| 13518 | |
| 13519 | cat >>confdefs.h <<\EOF |
| 13520 | #define USE_STRING_HACKS 1 |
| 13521 | EOF |
| 13522 | |
| 13523 | { echo "$as_me:13523: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&5 |
| 13524 | echo "$as_me: WARNING: enabling string-hacks to work around bogus compiler/loader warnings" >&2;} |
| 13525 | |
| 13526 | for ac_func in strlcat strlcpy snprintf |
| 13527 | do |
| 13528 | as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 13529 | echo "$as_me:13529: checking for $ac_func" >&5 |
| 13530 | echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 |
| 13531 | if eval "test \"\${$as_ac_var+set}\" = set"; then |
| 13532 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13533 | else |
| 13534 | cat >conftest.$ac_ext <<_ACEOF |
| 13535 | #line 13535 "configure" |
| 13536 | #include "confdefs.h" |
| 13537 | /* System header to define __stub macros and hopefully few prototypes, |
| 13538 | which can conflict with char $ac_func (); below. */ |
| 13539 | #include <assert.h> |
| 13540 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 13541 | #ifdef __cplusplus |
| 13542 | extern "C" |
| 13543 | #endif |
| 13544 | /* We use char because int might match the return type of a gcc2 |
| 13545 | builtin and then its argument prototype would still apply. */ |
| 13546 | char $ac_func (); |
| 13547 | char (*f) (); |
| 13548 | |
| 13549 | int |
| 13550 | main () |
| 13551 | { |
| 13552 | /* The GNU C library defines this for functions which it implements |
| 13553 | to always fail with ENOSYS. Some functions are actually named |
| 13554 | something starting with __ and the normal name is an alias. */ |
| 13555 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 13556 | choke me |
| 13557 | #else |
| 13558 | f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 13559 | #endif |
| 13560 | |
| 13561 | ; |
| 13562 | return 0; |
| 13563 | } |
| 13564 | _ACEOF |
| 13565 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13566 | if { (eval echo "$as_me:13566: \"$ac_link\"") >&5 |
| 13567 | (eval $ac_link) 2>&5 |
| 13568 | ac_status=$? |
| 13569 | echo "$as_me:13569: \$? = $ac_status" >&5 |
| 13570 | (exit $ac_status); } && |
| 13571 | { ac_try='test -s conftest$ac_exeext' |
| 13572 | { (eval echo "$as_me:13572: \"$ac_try\"") >&5 |
| 13573 | (eval $ac_try) 2>&5 |
| 13574 | ac_status=$? |
| 13575 | echo "$as_me:13575: \$? = $ac_status" >&5 |
| 13576 | (exit $ac_status); }; }; then |
| 13577 | eval "$as_ac_var=yes" |
| 13578 | else |
| 13579 | echo "$as_me: failed program was:" >&5 |
| 13580 | cat conftest.$ac_ext >&5 |
| 13581 | eval "$as_ac_var=no" |
| 13582 | fi |
| 13583 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13584 | fi |
| 13585 | echo "$as_me:13585: result: `eval echo '${'$as_ac_var'}'`" >&5 |
| 13586 | echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 |
| 13587 | if test `eval echo '${'$as_ac_var'}'` = yes; then |
| 13588 | cat >>confdefs.h <<EOF |
| 13589 | #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 13590 | EOF |
| 13591 | |
| 13592 | fi |
| 13593 | done |
| 13594 | |
| 13595 | fi |
| 13596 | |
| 13597 | ### use option --enable-assertions to turn on generation of assertion code |
| 13598 | echo "$as_me:13598: checking if you want to enable runtime assertions" >&5 |
| 13599 | echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6 |
| 13600 | |
| 13601 | # Check whether --enable-assertions or --disable-assertions was given. |
| 13602 | if test "${enable_assertions+set}" = set; then |
| 13603 | enableval="$enable_assertions" |
| 13604 | with_assertions=$enableval |
| 13605 | else |
| 13606 | with_assertions=no |
| 13607 | fi; |
| 13608 | echo "$as_me:13608: result: $with_assertions" >&5 |
| 13609 | echo "${ECHO_T}$with_assertions" >&6 |
| 13610 | if test -n "$GCC" |
| 13611 | then |
| 13612 | if test "$with_assertions" = no |
| 13613 | then |
| 13614 | CPPFLAGS="$CPPFLAGS -DNDEBUG" |
| 13615 | else |
| 13616 | |
| 13617 | ADAFLAGS="$ADAFLAGS -gnata" |
| 13618 | |
| 13619 | fi |
| 13620 | fi |
| 13621 | |
| 13622 | ### use option --disable-leaks to suppress "permanent" leaks, for testing |
| 13623 | |
| 13624 | echo "$as_me:13624: checking if you want to use dmalloc for testing" >&5 |
| 13625 | echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6 |
| 13626 | |
| 13627 | # Check whether --with-dmalloc or --without-dmalloc was given. |
| 13628 | if test "${with_dmalloc+set}" = set; then |
| 13629 | withval="$with_dmalloc" |
| 13630 | |
| 13631 | cat >>confdefs.h <<EOF |
| 13632 | #define USE_DMALLOC 1 |
| 13633 | EOF |
| 13634 | |
| 13635 | : ${with_cflags:=-g} |
| 13636 | : ${with_no_leaks:=yes} |
| 13637 | with_dmalloc=yes |
| 13638 | else |
| 13639 | with_dmalloc= |
| 13640 | fi; |
| 13641 | echo "$as_me:13641: result: ${with_dmalloc:-no}" >&5 |
| 13642 | echo "${ECHO_T}${with_dmalloc:-no}" >&6 |
| 13643 | |
| 13644 | case .$with_cflags in |
| 13645 | (.*-g*) |
| 13646 | case .$CFLAGS in |
| 13647 | (.*-g*) |
| 13648 | ;; |
| 13649 | (*) |
| 13650 | |
| 13651 | cf_fix_cppflags=no |
| 13652 | cf_new_cflags= |
| 13653 | cf_new_cppflags= |
| 13654 | cf_new_extra_cppflags= |
| 13655 | |
| 13656 | for cf_add_cflags in -g |
| 13657 | do |
| 13658 | case $cf_fix_cppflags in |
| 13659 | (no) |
| 13660 | case $cf_add_cflags in |
| 13661 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 13662 | case $cf_add_cflags in |
| 13663 | (-D*) |
| 13664 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 13665 | |
| 13666 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 13667 | && test -z "${cf_tst_cflags}" \ |
| 13668 | && cf_fix_cppflags=yes |
| 13669 | |
| 13670 | if test $cf_fix_cppflags = yes ; then |
| 13671 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 13672 | continue |
| 13673 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 13674 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 13675 | continue |
| 13676 | fi |
| 13677 | ;; |
| 13678 | esac |
| 13679 | case "$CPPFLAGS" in |
| 13680 | (*$cf_add_cflags) |
| 13681 | ;; |
| 13682 | (*) |
| 13683 | case $cf_add_cflags in |
| 13684 | (-D*) |
| 13685 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 13686 | |
| 13687 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 13688 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 13689 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 13690 | |
| 13691 | ;; |
| 13692 | esac |
| 13693 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 13694 | ;; |
| 13695 | esac |
| 13696 | ;; |
| 13697 | (*) |
| 13698 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 13699 | ;; |
| 13700 | esac |
| 13701 | ;; |
| 13702 | (yes) |
| 13703 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 13704 | |
| 13705 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 13706 | |
| 13707 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 13708 | && test -z "${cf_tst_cflags}" \ |
| 13709 | && cf_fix_cppflags=no |
| 13710 | ;; |
| 13711 | esac |
| 13712 | done |
| 13713 | |
| 13714 | if test -n "$cf_new_cflags" ; then |
| 13715 | |
| 13716 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 13717 | fi |
| 13718 | |
| 13719 | if test -n "$cf_new_cppflags" ; then |
| 13720 | |
| 13721 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 13722 | fi |
| 13723 | |
| 13724 | if test -n "$cf_new_extra_cppflags" ; then |
| 13725 | |
| 13726 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 13727 | fi |
| 13728 | |
| 13729 | ;; |
| 13730 | esac |
| 13731 | ;; |
| 13732 | esac |
| 13733 | |
| 13734 | if test "$with_dmalloc" = yes ; then |
| 13735 | echo "$as_me:13735: checking for dmalloc.h" >&5 |
| 13736 | echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6 |
| 13737 | if test "${ac_cv_header_dmalloc_h+set}" = set; then |
| 13738 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13739 | else |
| 13740 | cat >conftest.$ac_ext <<_ACEOF |
| 13741 | #line 13741 "configure" |
| 13742 | #include "confdefs.h" |
| 13743 | #include <dmalloc.h> |
| 13744 | _ACEOF |
| 13745 | if { (eval echo "$as_me:13745: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 13746 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 13747 | ac_status=$? |
| 13748 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 13749 | rm -f conftest.er1 |
| 13750 | cat conftest.err >&5 |
| 13751 | echo "$as_me:13751: \$? = $ac_status" >&5 |
| 13752 | (exit $ac_status); } >/dev/null; then |
| 13753 | if test -s conftest.err; then |
| 13754 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 13755 | else |
| 13756 | ac_cpp_err= |
| 13757 | fi |
| 13758 | else |
| 13759 | ac_cpp_err=yes |
| 13760 | fi |
| 13761 | if test -z "$ac_cpp_err"; then |
| 13762 | ac_cv_header_dmalloc_h=yes |
| 13763 | else |
| 13764 | echo "$as_me: failed program was:" >&5 |
| 13765 | cat conftest.$ac_ext >&5 |
| 13766 | ac_cv_header_dmalloc_h=no |
| 13767 | fi |
| 13768 | rm -f conftest.err conftest.$ac_ext |
| 13769 | fi |
| 13770 | echo "$as_me:13770: result: $ac_cv_header_dmalloc_h" >&5 |
| 13771 | echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6 |
| 13772 | if test $ac_cv_header_dmalloc_h = yes; then |
| 13773 | |
| 13774 | echo "$as_me:13774: checking for dmalloc_debug in -ldmalloc" >&5 |
| 13775 | echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6 |
| 13776 | if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then |
| 13777 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13778 | else |
| 13779 | ac_check_lib_save_LIBS=$LIBS |
| 13780 | LIBS="-ldmalloc $LIBS" |
| 13781 | cat >conftest.$ac_ext <<_ACEOF |
| 13782 | #line 13782 "configure" |
| 13783 | #include "confdefs.h" |
| 13784 | |
| 13785 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 13786 | #ifdef __cplusplus |
| 13787 | extern "C" |
| 13788 | #endif |
| 13789 | /* We use char because int might match the return type of a gcc2 |
| 13790 | builtin and then its argument prototype would still apply. */ |
| 13791 | char dmalloc_debug (); |
| 13792 | int |
| 13793 | main () |
| 13794 | { |
| 13795 | dmalloc_debug (); |
| 13796 | ; |
| 13797 | return 0; |
| 13798 | } |
| 13799 | _ACEOF |
| 13800 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 13801 | if { (eval echo "$as_me:13801: \"$ac_link\"") >&5 |
| 13802 | (eval $ac_link) 2>&5 |
| 13803 | ac_status=$? |
| 13804 | echo "$as_me:13804: \$? = $ac_status" >&5 |
| 13805 | (exit $ac_status); } && |
| 13806 | { ac_try='test -s conftest$ac_exeext' |
| 13807 | { (eval echo "$as_me:13807: \"$ac_try\"") >&5 |
| 13808 | (eval $ac_try) 2>&5 |
| 13809 | ac_status=$? |
| 13810 | echo "$as_me:13810: \$? = $ac_status" >&5 |
| 13811 | (exit $ac_status); }; }; then |
| 13812 | ac_cv_lib_dmalloc_dmalloc_debug=yes |
| 13813 | else |
| 13814 | echo "$as_me: failed program was:" >&5 |
| 13815 | cat conftest.$ac_ext >&5 |
| 13816 | ac_cv_lib_dmalloc_dmalloc_debug=no |
| 13817 | fi |
| 13818 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 13819 | LIBS=$ac_check_lib_save_LIBS |
| 13820 | fi |
| 13821 | echo "$as_me:13821: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5 |
| 13822 | echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6 |
| 13823 | if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then |
| 13824 | cat >>confdefs.h <<EOF |
| 13825 | #define HAVE_LIBDMALLOC 1 |
| 13826 | EOF |
| 13827 | |
| 13828 | LIBS="-ldmalloc $LIBS" |
| 13829 | |
| 13830 | fi |
| 13831 | |
| 13832 | fi |
| 13833 | |
| 13834 | fi |
| 13835 | |
| 13836 | echo "$as_me:13836: checking if you want to use dbmalloc for testing" >&5 |
| 13837 | echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6 |
| 13838 | |
| 13839 | # Check whether --with-dbmalloc or --without-dbmalloc was given. |
| 13840 | if test "${with_dbmalloc+set}" = set; then |
| 13841 | withval="$with_dbmalloc" |
| 13842 | |
| 13843 | cat >>confdefs.h <<EOF |
| 13844 | #define USE_DBMALLOC 1 |
| 13845 | EOF |
| 13846 | |
| 13847 | : ${with_cflags:=-g} |
| 13848 | : ${with_no_leaks:=yes} |
| 13849 | with_dbmalloc=yes |
| 13850 | else |
| 13851 | with_dbmalloc= |
| 13852 | fi; |
| 13853 | echo "$as_me:13853: result: ${with_dbmalloc:-no}" >&5 |
| 13854 | echo "${ECHO_T}${with_dbmalloc:-no}" >&6 |
| 13855 | |
| 13856 | case .$with_cflags in |
| 13857 | (.*-g*) |
| 13858 | case .$CFLAGS in |
| 13859 | (.*-g*) |
| 13860 | ;; |
| 13861 | (*) |
| 13862 | |
| 13863 | cf_fix_cppflags=no |
| 13864 | cf_new_cflags= |
| 13865 | cf_new_cppflags= |
| 13866 | cf_new_extra_cppflags= |
| 13867 | |
| 13868 | for cf_add_cflags in -g |
| 13869 | do |
| 13870 | case $cf_fix_cppflags in |
| 13871 | (no) |
| 13872 | case $cf_add_cflags in |
| 13873 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 13874 | case $cf_add_cflags in |
| 13875 | (-D*) |
| 13876 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 13877 | |
| 13878 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 13879 | && test -z "${cf_tst_cflags}" \ |
| 13880 | && cf_fix_cppflags=yes |
| 13881 | |
| 13882 | if test $cf_fix_cppflags = yes ; then |
| 13883 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 13884 | continue |
| 13885 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 13886 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 13887 | continue |
| 13888 | fi |
| 13889 | ;; |
| 13890 | esac |
| 13891 | case "$CPPFLAGS" in |
| 13892 | (*$cf_add_cflags) |
| 13893 | ;; |
| 13894 | (*) |
| 13895 | case $cf_add_cflags in |
| 13896 | (-D*) |
| 13897 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 13898 | |
| 13899 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 13900 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 13901 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 13902 | |
| 13903 | ;; |
| 13904 | esac |
| 13905 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 13906 | ;; |
| 13907 | esac |
| 13908 | ;; |
| 13909 | (*) |
| 13910 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 13911 | ;; |
| 13912 | esac |
| 13913 | ;; |
| 13914 | (yes) |
| 13915 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 13916 | |
| 13917 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 13918 | |
| 13919 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 13920 | && test -z "${cf_tst_cflags}" \ |
| 13921 | && cf_fix_cppflags=no |
| 13922 | ;; |
| 13923 | esac |
| 13924 | done |
| 13925 | |
| 13926 | if test -n "$cf_new_cflags" ; then |
| 13927 | |
| 13928 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 13929 | fi |
| 13930 | |
| 13931 | if test -n "$cf_new_cppflags" ; then |
| 13932 | |
| 13933 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 13934 | fi |
| 13935 | |
| 13936 | if test -n "$cf_new_extra_cppflags" ; then |
| 13937 | |
| 13938 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 13939 | fi |
| 13940 | |
| 13941 | ;; |
| 13942 | esac |
| 13943 | ;; |
| 13944 | esac |
| 13945 | |
| 13946 | if test "$with_dbmalloc" = yes ; then |
| 13947 | echo "$as_me:13947: checking for dbmalloc.h" >&5 |
| 13948 | echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6 |
| 13949 | if test "${ac_cv_header_dbmalloc_h+set}" = set; then |
| 13950 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13951 | else |
| 13952 | cat >conftest.$ac_ext <<_ACEOF |
| 13953 | #line 13953 "configure" |
| 13954 | #include "confdefs.h" |
| 13955 | #include <dbmalloc.h> |
| 13956 | _ACEOF |
| 13957 | if { (eval echo "$as_me:13957: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 13958 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 13959 | ac_status=$? |
| 13960 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 13961 | rm -f conftest.er1 |
| 13962 | cat conftest.err >&5 |
| 13963 | echo "$as_me:13963: \$? = $ac_status" >&5 |
| 13964 | (exit $ac_status); } >/dev/null; then |
| 13965 | if test -s conftest.err; then |
| 13966 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 13967 | else |
| 13968 | ac_cpp_err= |
| 13969 | fi |
| 13970 | else |
| 13971 | ac_cpp_err=yes |
| 13972 | fi |
| 13973 | if test -z "$ac_cpp_err"; then |
| 13974 | ac_cv_header_dbmalloc_h=yes |
| 13975 | else |
| 13976 | echo "$as_me: failed program was:" >&5 |
| 13977 | cat conftest.$ac_ext >&5 |
| 13978 | ac_cv_header_dbmalloc_h=no |
| 13979 | fi |
| 13980 | rm -f conftest.err conftest.$ac_ext |
| 13981 | fi |
| 13982 | echo "$as_me:13982: result: $ac_cv_header_dbmalloc_h" >&5 |
| 13983 | echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6 |
| 13984 | if test $ac_cv_header_dbmalloc_h = yes; then |
| 13985 | |
| 13986 | echo "$as_me:13986: checking for debug_malloc in -ldbmalloc" >&5 |
| 13987 | echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6 |
| 13988 | if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then |
| 13989 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 13990 | else |
| 13991 | ac_check_lib_save_LIBS=$LIBS |
| 13992 | LIBS="-ldbmalloc $LIBS" |
| 13993 | cat >conftest.$ac_ext <<_ACEOF |
| 13994 | #line 13994 "configure" |
| 13995 | #include "confdefs.h" |
| 13996 | |
| 13997 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 13998 | #ifdef __cplusplus |
| 13999 | extern "C" |
| 14000 | #endif |
| 14001 | /* We use char because int might match the return type of a gcc2 |
| 14002 | builtin and then its argument prototype would still apply. */ |
| 14003 | char debug_malloc (); |
| 14004 | int |
| 14005 | main () |
| 14006 | { |
| 14007 | debug_malloc (); |
| 14008 | ; |
| 14009 | return 0; |
| 14010 | } |
| 14011 | _ACEOF |
| 14012 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14013 | if { (eval echo "$as_me:14013: \"$ac_link\"") >&5 |
| 14014 | (eval $ac_link) 2>&5 |
| 14015 | ac_status=$? |
| 14016 | echo "$as_me:14016: \$? = $ac_status" >&5 |
| 14017 | (exit $ac_status); } && |
| 14018 | { ac_try='test -s conftest$ac_exeext' |
| 14019 | { (eval echo "$as_me:14019: \"$ac_try\"") >&5 |
| 14020 | (eval $ac_try) 2>&5 |
| 14021 | ac_status=$? |
| 14022 | echo "$as_me:14022: \$? = $ac_status" >&5 |
| 14023 | (exit $ac_status); }; }; then |
| 14024 | ac_cv_lib_dbmalloc_debug_malloc=yes |
| 14025 | else |
| 14026 | echo "$as_me: failed program was:" >&5 |
| 14027 | cat conftest.$ac_ext >&5 |
| 14028 | ac_cv_lib_dbmalloc_debug_malloc=no |
| 14029 | fi |
| 14030 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14031 | LIBS=$ac_check_lib_save_LIBS |
| 14032 | fi |
| 14033 | echo "$as_me:14033: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5 |
| 14034 | echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6 |
| 14035 | if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then |
| 14036 | cat >>confdefs.h <<EOF |
| 14037 | #define HAVE_LIBDBMALLOC 1 |
| 14038 | EOF |
| 14039 | |
| 14040 | LIBS="-ldbmalloc $LIBS" |
| 14041 | |
| 14042 | fi |
| 14043 | |
| 14044 | fi |
| 14045 | |
| 14046 | fi |
| 14047 | |
| 14048 | echo "$as_me:14048: checking if you want to use valgrind for testing" >&5 |
| 14049 | echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6 |
| 14050 | |
| 14051 | # Check whether --with-valgrind or --without-valgrind was given. |
| 14052 | if test "${with_valgrind+set}" = set; then |
| 14053 | withval="$with_valgrind" |
| 14054 | |
| 14055 | cat >>confdefs.h <<EOF |
| 14056 | #define USE_VALGRIND 1 |
| 14057 | EOF |
| 14058 | |
| 14059 | : ${with_cflags:=-g} |
| 14060 | : ${with_no_leaks:=yes} |
| 14061 | with_valgrind=yes |
| 14062 | else |
| 14063 | with_valgrind= |
| 14064 | fi; |
| 14065 | echo "$as_me:14065: result: ${with_valgrind:-no}" >&5 |
| 14066 | echo "${ECHO_T}${with_valgrind:-no}" >&6 |
| 14067 | |
| 14068 | case .$with_cflags in |
| 14069 | (.*-g*) |
| 14070 | case .$CFLAGS in |
| 14071 | (.*-g*) |
| 14072 | ;; |
| 14073 | (*) |
| 14074 | |
| 14075 | cf_fix_cppflags=no |
| 14076 | cf_new_cflags= |
| 14077 | cf_new_cppflags= |
| 14078 | cf_new_extra_cppflags= |
| 14079 | |
| 14080 | for cf_add_cflags in -g |
| 14081 | do |
| 14082 | case $cf_fix_cppflags in |
| 14083 | (no) |
| 14084 | case $cf_add_cflags in |
| 14085 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 14086 | case $cf_add_cflags in |
| 14087 | (-D*) |
| 14088 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 14089 | |
| 14090 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 14091 | && test -z "${cf_tst_cflags}" \ |
| 14092 | && cf_fix_cppflags=yes |
| 14093 | |
| 14094 | if test $cf_fix_cppflags = yes ; then |
| 14095 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 14096 | continue |
| 14097 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 14098 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 14099 | continue |
| 14100 | fi |
| 14101 | ;; |
| 14102 | esac |
| 14103 | case "$CPPFLAGS" in |
| 14104 | (*$cf_add_cflags) |
| 14105 | ;; |
| 14106 | (*) |
| 14107 | case $cf_add_cflags in |
| 14108 | (-D*) |
| 14109 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 14110 | |
| 14111 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 14112 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 14113 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 14114 | |
| 14115 | ;; |
| 14116 | esac |
| 14117 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 14118 | ;; |
| 14119 | esac |
| 14120 | ;; |
| 14121 | (*) |
| 14122 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 14123 | ;; |
| 14124 | esac |
| 14125 | ;; |
| 14126 | (yes) |
| 14127 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 14128 | |
| 14129 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 14130 | |
| 14131 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 14132 | && test -z "${cf_tst_cflags}" \ |
| 14133 | && cf_fix_cppflags=no |
| 14134 | ;; |
| 14135 | esac |
| 14136 | done |
| 14137 | |
| 14138 | if test -n "$cf_new_cflags" ; then |
| 14139 | |
| 14140 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 14141 | fi |
| 14142 | |
| 14143 | if test -n "$cf_new_cppflags" ; then |
| 14144 | |
| 14145 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 14146 | fi |
| 14147 | |
| 14148 | if test -n "$cf_new_extra_cppflags" ; then |
| 14149 | |
| 14150 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 14151 | fi |
| 14152 | |
| 14153 | ;; |
| 14154 | esac |
| 14155 | ;; |
| 14156 | esac |
| 14157 | |
| 14158 | echo "$as_me:14158: checking if you want to perform memory-leak testing" >&5 |
| 14159 | echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6 |
| 14160 | |
| 14161 | # Check whether --enable-leaks or --disable-leaks was given. |
| 14162 | if test "${enable_leaks+set}" = set; then |
| 14163 | enableval="$enable_leaks" |
| 14164 | if test "x$enableval" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi |
| 14165 | else |
| 14166 | : ${with_no_leaks:=no} |
| 14167 | fi; |
| 14168 | echo "$as_me:14168: result: $with_no_leaks" >&5 |
| 14169 | echo "${ECHO_T}$with_no_leaks" >&6 |
| 14170 | |
| 14171 | if test "$with_no_leaks" = yes ; then |
| 14172 | |
| 14173 | cat >>confdefs.h <<\EOF |
| 14174 | #define NO_LEAKS 1 |
| 14175 | EOF |
| 14176 | |
| 14177 | cat >>confdefs.h <<\EOF |
| 14178 | #define YY_NO_LEAKS 1 |
| 14179 | EOF |
| 14180 | |
| 14181 | fi |
| 14182 | |
| 14183 | cat >>confdefs.h <<\EOF |
| 14184 | #define HAVE_NC_ALLOC_H 1 |
| 14185 | EOF |
| 14186 | |
| 14187 | ### use option --enable-expanded to generate certain macros as functions |
| 14188 | |
| 14189 | # Check whether --enable-expanded or --disable-expanded was given. |
| 14190 | if test "${enable_expanded+set}" = set; then |
| 14191 | enableval="$enable_expanded" |
| 14192 | test "x$enableval" = xyes && |
| 14193 | cat >>confdefs.h <<\EOF |
| 14194 | #define NCURSES_EXPANDED 1 |
| 14195 | EOF |
| 14196 | |
| 14197 | fi; |
| 14198 | |
| 14199 | ### use option --disable-macros to suppress macros in favor of functions |
| 14200 | |
| 14201 | # Check whether --enable-macros or --disable-macros was given. |
| 14202 | if test "${enable_macros+set}" = set; then |
| 14203 | enableval="$enable_macros" |
| 14204 | test "$enableval" = no && |
| 14205 | cat >>confdefs.h <<\EOF |
| 14206 | #define NCURSES_NOMACROS 1 |
| 14207 | EOF |
| 14208 | |
| 14209 | fi; |
| 14210 | |
| 14211 | # Normally we only add trace() to the debug-library. Allow this to be |
| 14212 | # extended to all models of the ncurses library: |
| 14213 | cf_all_traces=no |
| 14214 | case "$CFLAGS $CPPFLAGS" in |
| 14215 | (*-DTRACE*) |
| 14216 | cf_all_traces=yes |
| 14217 | ;; |
| 14218 | esac |
| 14219 | |
| 14220 | echo "$as_me:14220: checking whether to add trace feature to all models" >&5 |
| 14221 | echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6 |
| 14222 | |
| 14223 | # Check whether --with-trace or --without-trace was given. |
| 14224 | if test "${with_trace+set}" = set; then |
| 14225 | withval="$with_trace" |
| 14226 | cf_with_trace=$withval |
| 14227 | else |
| 14228 | cf_with_trace=$cf_all_traces |
| 14229 | fi; |
| 14230 | echo "$as_me:14230: result: $cf_with_trace" >&5 |
| 14231 | echo "${ECHO_T}$cf_with_trace" >&6 |
| 14232 | |
| 14233 | if test "x$cf_with_trace" = xyes ; then |
| 14234 | LIB_TRACING=all |
| 14235 | ADA_TRACE=TRUE |
| 14236 | |
| 14237 | cf_fix_cppflags=no |
| 14238 | cf_new_cflags= |
| 14239 | cf_new_cppflags= |
| 14240 | cf_new_extra_cppflags= |
| 14241 | |
| 14242 | for cf_add_cflags in -DTRACE |
| 14243 | do |
| 14244 | case $cf_fix_cppflags in |
| 14245 | (no) |
| 14246 | case $cf_add_cflags in |
| 14247 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
| 14248 | case $cf_add_cflags in |
| 14249 | (-D*) |
| 14250 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 14251 | |
| 14252 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 14253 | && test -z "${cf_tst_cflags}" \ |
| 14254 | && cf_fix_cppflags=yes |
| 14255 | |
| 14256 | if test $cf_fix_cppflags = yes ; then |
| 14257 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 14258 | continue |
| 14259 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 14260 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 14261 | continue |
| 14262 | fi |
| 14263 | ;; |
| 14264 | esac |
| 14265 | case "$CPPFLAGS" in |
| 14266 | (*$cf_add_cflags) |
| 14267 | ;; |
| 14268 | (*) |
| 14269 | case $cf_add_cflags in |
| 14270 | (-D*) |
| 14271 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 14272 | |
| 14273 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 14274 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 14275 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 14276 | |
| 14277 | ;; |
| 14278 | esac |
| 14279 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 14280 | ;; |
| 14281 | esac |
| 14282 | ;; |
| 14283 | (*) |
| 14284 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 14285 | ;; |
| 14286 | esac |
| 14287 | ;; |
| 14288 | (yes) |
| 14289 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 14290 | |
| 14291 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 14292 | |
| 14293 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 14294 | && test -z "${cf_tst_cflags}" \ |
| 14295 | && cf_fix_cppflags=no |
| 14296 | ;; |
| 14297 | esac |
| 14298 | done |
| 14299 | |
| 14300 | if test -n "$cf_new_cflags" ; then |
| 14301 | |
| 14302 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 14303 | fi |
| 14304 | |
| 14305 | if test -n "$cf_new_cppflags" ; then |
| 14306 | |
| 14307 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
| 14308 | fi |
| 14309 | |
| 14310 | if test -n "$cf_new_extra_cppflags" ; then |
| 14311 | |
| 14312 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 14313 | fi |
| 14314 | |
| 14315 | else |
| 14316 | LIB_TRACING=DEBUG |
| 14317 | ADA_TRACE=FALSE |
| 14318 | fi |
| 14319 | |
| 14320 | echo "$as_me:14320: checking if we want to use GNAT projects" >&5 |
| 14321 | echo $ECHO_N "checking if we want to use GNAT projects... $ECHO_C" >&6 |
| 14322 | |
| 14323 | # Check whether --enable-gnat-projects or --disable-gnat-projects was given. |
| 14324 | if test "${enable_gnat_projects+set}" = set; then |
| 14325 | enableval="$enable_gnat_projects" |
| 14326 | test "$enableval" != no && enableval=yes |
| 14327 | if test "$enableval" != "yes" ; then |
| 14328 | enable_gnat_projects=no |
| 14329 | else |
| 14330 | enable_gnat_projects=yes |
| 14331 | fi |
| 14332 | else |
| 14333 | enableval=yes |
| 14334 | enable_gnat_projects=yes |
| 14335 | |
| 14336 | fi; |
| 14337 | echo "$as_me:14337: result: $enable_gnat_projects" >&5 |
| 14338 | echo "${ECHO_T}$enable_gnat_projects" >&6 |
| 14339 | |
| 14340 | ### Checks for libraries. |
| 14341 | case $cf_cv_system_name in |
| 14342 | (*mingw32*|*mingw64*) |
| 14343 | CPPFLAGS="$CPPFLAGS -DWINVER=0x0501" |
| 14344 | LIBS=" -lpsapi $LIBS" |
| 14345 | ;; |
| 14346 | (*) |
| 14347 | echo "$as_me:14347: checking for gettimeofday" >&5 |
| 14348 | echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6 |
| 14349 | if test "${ac_cv_func_gettimeofday+set}" = set; then |
| 14350 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14351 | else |
| 14352 | cat >conftest.$ac_ext <<_ACEOF |
| 14353 | #line 14353 "configure" |
| 14354 | #include "confdefs.h" |
| 14355 | /* System header to define __stub macros and hopefully few prototypes, |
| 14356 | which can conflict with char gettimeofday (); below. */ |
| 14357 | #include <assert.h> |
| 14358 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 14359 | #ifdef __cplusplus |
| 14360 | extern "C" |
| 14361 | #endif |
| 14362 | /* We use char because int might match the return type of a gcc2 |
| 14363 | builtin and then its argument prototype would still apply. */ |
| 14364 | char gettimeofday (); |
| 14365 | char (*f) (); |
| 14366 | |
| 14367 | int |
| 14368 | main () |
| 14369 | { |
| 14370 | /* The GNU C library defines this for functions which it implements |
| 14371 | to always fail with ENOSYS. Some functions are actually named |
| 14372 | something starting with __ and the normal name is an alias. */ |
| 14373 | #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday) |
| 14374 | choke me |
| 14375 | #else |
| 14376 | f = gettimeofday; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 14377 | #endif |
| 14378 | |
| 14379 | ; |
| 14380 | return 0; |
| 14381 | } |
| 14382 | _ACEOF |
| 14383 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14384 | if { (eval echo "$as_me:14384: \"$ac_link\"") >&5 |
| 14385 | (eval $ac_link) 2>&5 |
| 14386 | ac_status=$? |
| 14387 | echo "$as_me:14387: \$? = $ac_status" >&5 |
| 14388 | (exit $ac_status); } && |
| 14389 | { ac_try='test -s conftest$ac_exeext' |
| 14390 | { (eval echo "$as_me:14390: \"$ac_try\"") >&5 |
| 14391 | (eval $ac_try) 2>&5 |
| 14392 | ac_status=$? |
| 14393 | echo "$as_me:14393: \$? = $ac_status" >&5 |
| 14394 | (exit $ac_status); }; }; then |
| 14395 | ac_cv_func_gettimeofday=yes |
| 14396 | else |
| 14397 | echo "$as_me: failed program was:" >&5 |
| 14398 | cat conftest.$ac_ext >&5 |
| 14399 | ac_cv_func_gettimeofday=no |
| 14400 | fi |
| 14401 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14402 | fi |
| 14403 | echo "$as_me:14403: result: $ac_cv_func_gettimeofday" >&5 |
| 14404 | echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6 |
| 14405 | if test $ac_cv_func_gettimeofday = yes; then |
| 14406 | |
| 14407 | cat >>confdefs.h <<\EOF |
| 14408 | #define HAVE_GETTIMEOFDAY 1 |
| 14409 | EOF |
| 14410 | |
| 14411 | else |
| 14412 | |
| 14413 | echo "$as_me:14413: checking for gettimeofday in -lbsd" >&5 |
| 14414 | echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6 |
| 14415 | if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then |
| 14416 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14417 | else |
| 14418 | ac_check_lib_save_LIBS=$LIBS |
| 14419 | LIBS="-lbsd $LIBS" |
| 14420 | cat >conftest.$ac_ext <<_ACEOF |
| 14421 | #line 14421 "configure" |
| 14422 | #include "confdefs.h" |
| 14423 | |
| 14424 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 14425 | #ifdef __cplusplus |
| 14426 | extern "C" |
| 14427 | #endif |
| 14428 | /* We use char because int might match the return type of a gcc2 |
| 14429 | builtin and then its argument prototype would still apply. */ |
| 14430 | char gettimeofday (); |
| 14431 | int |
| 14432 | main () |
| 14433 | { |
| 14434 | gettimeofday (); |
| 14435 | ; |
| 14436 | return 0; |
| 14437 | } |
| 14438 | _ACEOF |
| 14439 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14440 | if { (eval echo "$as_me:14440: \"$ac_link\"") >&5 |
| 14441 | (eval $ac_link) 2>&5 |
| 14442 | ac_status=$? |
| 14443 | echo "$as_me:14443: \$? = $ac_status" >&5 |
| 14444 | (exit $ac_status); } && |
| 14445 | { ac_try='test -s conftest$ac_exeext' |
| 14446 | { (eval echo "$as_me:14446: \"$ac_try\"") >&5 |
| 14447 | (eval $ac_try) 2>&5 |
| 14448 | ac_status=$? |
| 14449 | echo "$as_me:14449: \$? = $ac_status" >&5 |
| 14450 | (exit $ac_status); }; }; then |
| 14451 | ac_cv_lib_bsd_gettimeofday=yes |
| 14452 | else |
| 14453 | echo "$as_me: failed program was:" >&5 |
| 14454 | cat conftest.$ac_ext >&5 |
| 14455 | ac_cv_lib_bsd_gettimeofday=no |
| 14456 | fi |
| 14457 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14458 | LIBS=$ac_check_lib_save_LIBS |
| 14459 | fi |
| 14460 | echo "$as_me:14460: result: $ac_cv_lib_bsd_gettimeofday" >&5 |
| 14461 | echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6 |
| 14462 | if test $ac_cv_lib_bsd_gettimeofday = yes; then |
| 14463 | |
| 14464 | cat >>confdefs.h <<\EOF |
| 14465 | #define HAVE_GETTIMEOFDAY 1 |
| 14466 | EOF |
| 14467 | |
| 14468 | cf_add_libs="-lbsd" |
| 14469 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 14470 | for cf_add_1lib in $LIBS |
| 14471 | do |
| 14472 | for cf_add_2lib in $cf_add_libs |
| 14473 | do |
| 14474 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 14475 | then |
| 14476 | cf_add_1lib= |
| 14477 | break |
| 14478 | fi |
| 14479 | done |
| 14480 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 14481 | done |
| 14482 | LIBS="$cf_add_libs" |
| 14483 | |
| 14484 | fi |
| 14485 | |
| 14486 | fi |
| 14487 | ;; |
| 14488 | esac |
| 14489 | |
| 14490 | echo "$as_me:14490: checking if -lm needed for math functions" >&5 |
| 14491 | echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6 |
| 14492 | if test "${cf_cv_need_libm+set}" = set; then |
| 14493 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14494 | else |
| 14495 | |
| 14496 | cat >conftest.$ac_ext <<_ACEOF |
| 14497 | #line 14497 "configure" |
| 14498 | #include "confdefs.h" |
| 14499 | |
| 14500 | #include <stdio.h> |
| 14501 | #include <math.h> |
| 14502 | |
| 14503 | int |
| 14504 | main () |
| 14505 | { |
| 14506 | double x = rand(); printf("result = %g\n", pow(sin(x),x)) |
| 14507 | ; |
| 14508 | return 0; |
| 14509 | } |
| 14510 | _ACEOF |
| 14511 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14512 | if { (eval echo "$as_me:14512: \"$ac_link\"") >&5 |
| 14513 | (eval $ac_link) 2>&5 |
| 14514 | ac_status=$? |
| 14515 | echo "$as_me:14515: \$? = $ac_status" >&5 |
| 14516 | (exit $ac_status); } && |
| 14517 | { ac_try='test -s conftest$ac_exeext' |
| 14518 | { (eval echo "$as_me:14518: \"$ac_try\"") >&5 |
| 14519 | (eval $ac_try) 2>&5 |
| 14520 | ac_status=$? |
| 14521 | echo "$as_me:14521: \$? = $ac_status" >&5 |
| 14522 | (exit $ac_status); }; }; then |
| 14523 | cf_cv_need_libm=no |
| 14524 | else |
| 14525 | echo "$as_me: failed program was:" >&5 |
| 14526 | cat conftest.$ac_ext >&5 |
| 14527 | cf_cv_need_libm=yes |
| 14528 | fi |
| 14529 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14530 | fi |
| 14531 | echo "$as_me:14531: result: $cf_cv_need_libm" >&5 |
| 14532 | echo "${ECHO_T}$cf_cv_need_libm" >&6 |
| 14533 | if test "$cf_cv_need_libm" = yes |
| 14534 | then |
| 14535 | MATH_LIB=-lm |
| 14536 | fi |
| 14537 | |
| 14538 | ### Checks for header files. |
| 14539 | echo "$as_me:14539: checking for ANSI C header files" >&5 |
| 14540 | echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6 |
| 14541 | if test "${ac_cv_header_stdc+set}" = set; then |
| 14542 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14543 | else |
| 14544 | cat >conftest.$ac_ext <<_ACEOF |
| 14545 | #line 14545 "configure" |
| 14546 | #include "confdefs.h" |
| 14547 | #include <stdlib.h> |
| 14548 | #include <stdarg.h> |
| 14549 | #include <string.h> |
| 14550 | #include <float.h> |
| 14551 | |
| 14552 | _ACEOF |
| 14553 | if { (eval echo "$as_me:14553: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 14554 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 14555 | ac_status=$? |
| 14556 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 14557 | rm -f conftest.er1 |
| 14558 | cat conftest.err >&5 |
| 14559 | echo "$as_me:14559: \$? = $ac_status" >&5 |
| 14560 | (exit $ac_status); } >/dev/null; then |
| 14561 | if test -s conftest.err; then |
| 14562 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 14563 | else |
| 14564 | ac_cpp_err= |
| 14565 | fi |
| 14566 | else |
| 14567 | ac_cpp_err=yes |
| 14568 | fi |
| 14569 | if test -z "$ac_cpp_err"; then |
| 14570 | ac_cv_header_stdc=yes |
| 14571 | else |
| 14572 | echo "$as_me: failed program was:" >&5 |
| 14573 | cat conftest.$ac_ext >&5 |
| 14574 | ac_cv_header_stdc=no |
| 14575 | fi |
| 14576 | rm -f conftest.err conftest.$ac_ext |
| 14577 | |
| 14578 | if test $ac_cv_header_stdc = yes; then |
| 14579 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 14580 | cat >conftest.$ac_ext <<_ACEOF |
| 14581 | #line 14581 "configure" |
| 14582 | #include "confdefs.h" |
| 14583 | #include <string.h> |
| 14584 | |
| 14585 | _ACEOF |
| 14586 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 14587 | egrep "memchr" >/dev/null 2>&1; then |
| 14588 | : |
| 14589 | else |
| 14590 | ac_cv_header_stdc=no |
| 14591 | fi |
| 14592 | rm -rf conftest* |
| 14593 | |
| 14594 | fi |
| 14595 | |
| 14596 | if test $ac_cv_header_stdc = yes; then |
| 14597 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 14598 | cat >conftest.$ac_ext <<_ACEOF |
| 14599 | #line 14599 "configure" |
| 14600 | #include "confdefs.h" |
| 14601 | #include <stdlib.h> |
| 14602 | |
| 14603 | _ACEOF |
| 14604 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 14605 | egrep "free" >/dev/null 2>&1; then |
| 14606 | : |
| 14607 | else |
| 14608 | ac_cv_header_stdc=no |
| 14609 | fi |
| 14610 | rm -rf conftest* |
| 14611 | |
| 14612 | fi |
| 14613 | |
| 14614 | if test $ac_cv_header_stdc = yes; then |
| 14615 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 14616 | if test "$cross_compiling" = yes; then |
| 14617 | : |
| 14618 | else |
| 14619 | cat >conftest.$ac_ext <<_ACEOF |
| 14620 | #line 14620 "configure" |
| 14621 | #include "confdefs.h" |
| 14622 | #include <ctype.h> |
| 14623 | #if ((' ' & 0x0FF) == 0x020) |
| 14624 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 14625 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 14626 | #else |
| 14627 | # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \ |
| 14628 | || ('j' <= (c) && (c) <= 'r') \ |
| 14629 | || ('s' <= (c) && (c) <= 'z')) |
| 14630 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 14631 | #endif |
| 14632 | |
| 14633 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 14634 | int |
| 14635 | main () |
| 14636 | { |
| 14637 | int i; |
| 14638 | for (i = 0; i < 256; i++) |
| 14639 | if (XOR (islower (i), ISLOWER (i)) |
| 14640 | || toupper (i) != TOUPPER (i)) |
| 14641 | $ac_main_return(2); |
| 14642 | $ac_main_return (0); |
| 14643 | } |
| 14644 | _ACEOF |
| 14645 | rm -f conftest$ac_exeext |
| 14646 | if { (eval echo "$as_me:14646: \"$ac_link\"") >&5 |
| 14647 | (eval $ac_link) 2>&5 |
| 14648 | ac_status=$? |
| 14649 | echo "$as_me:14649: \$? = $ac_status" >&5 |
| 14650 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 14651 | { (eval echo "$as_me:14651: \"$ac_try\"") >&5 |
| 14652 | (eval $ac_try) 2>&5 |
| 14653 | ac_status=$? |
| 14654 | echo "$as_me:14654: \$? = $ac_status" >&5 |
| 14655 | (exit $ac_status); }; }; then |
| 14656 | : |
| 14657 | else |
| 14658 | echo "$as_me: program exited with status $ac_status" >&5 |
| 14659 | echo "$as_me: failed program was:" >&5 |
| 14660 | cat conftest.$ac_ext >&5 |
| 14661 | ac_cv_header_stdc=no |
| 14662 | fi |
| 14663 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 14664 | fi |
| 14665 | fi |
| 14666 | fi |
| 14667 | echo "$as_me:14667: result: $ac_cv_header_stdc" >&5 |
| 14668 | echo "${ECHO_T}$ac_cv_header_stdc" >&6 |
| 14669 | if test $ac_cv_header_stdc = yes; then |
| 14670 | |
| 14671 | cat >>confdefs.h <<\EOF |
| 14672 | #define STDC_HEADERS 1 |
| 14673 | EOF |
| 14674 | |
| 14675 | fi |
| 14676 | |
| 14677 | ac_header_dirent=no |
| 14678 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do |
| 14679 | as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` |
| 14680 | echo "$as_me:14680: checking for $ac_hdr that defines DIR" >&5 |
| 14681 | echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6 |
| 14682 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 14683 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14684 | else |
| 14685 | cat >conftest.$ac_ext <<_ACEOF |
| 14686 | #line 14686 "configure" |
| 14687 | #include "confdefs.h" |
| 14688 | #include <sys/types.h> |
| 14689 | #include <$ac_hdr> |
| 14690 | |
| 14691 | int |
| 14692 | main () |
| 14693 | { |
| 14694 | if ((DIR *) 0) |
| 14695 | return 0; |
| 14696 | ; |
| 14697 | return 0; |
| 14698 | } |
| 14699 | _ACEOF |
| 14700 | rm -f conftest.$ac_objext |
| 14701 | if { (eval echo "$as_me:14701: \"$ac_compile\"") >&5 |
| 14702 | (eval $ac_compile) 2>&5 |
| 14703 | ac_status=$? |
| 14704 | echo "$as_me:14704: \$? = $ac_status" >&5 |
| 14705 | (exit $ac_status); } && |
| 14706 | { ac_try='test -s conftest.$ac_objext' |
| 14707 | { (eval echo "$as_me:14707: \"$ac_try\"") >&5 |
| 14708 | (eval $ac_try) 2>&5 |
| 14709 | ac_status=$? |
| 14710 | echo "$as_me:14710: \$? = $ac_status" >&5 |
| 14711 | (exit $ac_status); }; }; then |
| 14712 | eval "$as_ac_Header=yes" |
| 14713 | else |
| 14714 | echo "$as_me: failed program was:" >&5 |
| 14715 | cat conftest.$ac_ext >&5 |
| 14716 | eval "$as_ac_Header=no" |
| 14717 | fi |
| 14718 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14719 | fi |
| 14720 | echo "$as_me:14720: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 14721 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 14722 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 14723 | cat >>confdefs.h <<EOF |
| 14724 | #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 |
| 14725 | EOF |
| 14726 | |
| 14727 | ac_header_dirent=$ac_hdr; break |
| 14728 | fi |
| 14729 | |
| 14730 | done |
| 14731 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 14732 | if test $ac_header_dirent = dirent.h; then |
| 14733 | echo "$as_me:14733: checking for opendir in -ldir" >&5 |
| 14734 | echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6 |
| 14735 | if test "${ac_cv_lib_dir_opendir+set}" = set; then |
| 14736 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14737 | else |
| 14738 | ac_check_lib_save_LIBS=$LIBS |
| 14739 | LIBS="-ldir $LIBS" |
| 14740 | cat >conftest.$ac_ext <<_ACEOF |
| 14741 | #line 14741 "configure" |
| 14742 | #include "confdefs.h" |
| 14743 | |
| 14744 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 14745 | #ifdef __cplusplus |
| 14746 | extern "C" |
| 14747 | #endif |
| 14748 | /* We use char because int might match the return type of a gcc2 |
| 14749 | builtin and then its argument prototype would still apply. */ |
| 14750 | char opendir (); |
| 14751 | int |
| 14752 | main () |
| 14753 | { |
| 14754 | opendir (); |
| 14755 | ; |
| 14756 | return 0; |
| 14757 | } |
| 14758 | _ACEOF |
| 14759 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14760 | if { (eval echo "$as_me:14760: \"$ac_link\"") >&5 |
| 14761 | (eval $ac_link) 2>&5 |
| 14762 | ac_status=$? |
| 14763 | echo "$as_me:14763: \$? = $ac_status" >&5 |
| 14764 | (exit $ac_status); } && |
| 14765 | { ac_try='test -s conftest$ac_exeext' |
| 14766 | { (eval echo "$as_me:14766: \"$ac_try\"") >&5 |
| 14767 | (eval $ac_try) 2>&5 |
| 14768 | ac_status=$? |
| 14769 | echo "$as_me:14769: \$? = $ac_status" >&5 |
| 14770 | (exit $ac_status); }; }; then |
| 14771 | ac_cv_lib_dir_opendir=yes |
| 14772 | else |
| 14773 | echo "$as_me: failed program was:" >&5 |
| 14774 | cat conftest.$ac_ext >&5 |
| 14775 | ac_cv_lib_dir_opendir=no |
| 14776 | fi |
| 14777 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14778 | LIBS=$ac_check_lib_save_LIBS |
| 14779 | fi |
| 14780 | echo "$as_me:14780: result: $ac_cv_lib_dir_opendir" >&5 |
| 14781 | echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6 |
| 14782 | if test $ac_cv_lib_dir_opendir = yes; then |
| 14783 | LIBS="$LIBS -ldir" |
| 14784 | fi |
| 14785 | |
| 14786 | else |
| 14787 | echo "$as_me:14787: checking for opendir in -lx" >&5 |
| 14788 | echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6 |
| 14789 | if test "${ac_cv_lib_x_opendir+set}" = set; then |
| 14790 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14791 | else |
| 14792 | ac_check_lib_save_LIBS=$LIBS |
| 14793 | LIBS="-lx $LIBS" |
| 14794 | cat >conftest.$ac_ext <<_ACEOF |
| 14795 | #line 14795 "configure" |
| 14796 | #include "confdefs.h" |
| 14797 | |
| 14798 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 14799 | #ifdef __cplusplus |
| 14800 | extern "C" |
| 14801 | #endif |
| 14802 | /* We use char because int might match the return type of a gcc2 |
| 14803 | builtin and then its argument prototype would still apply. */ |
| 14804 | char opendir (); |
| 14805 | int |
| 14806 | main () |
| 14807 | { |
| 14808 | opendir (); |
| 14809 | ; |
| 14810 | return 0; |
| 14811 | } |
| 14812 | _ACEOF |
| 14813 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14814 | if { (eval echo "$as_me:14814: \"$ac_link\"") >&5 |
| 14815 | (eval $ac_link) 2>&5 |
| 14816 | ac_status=$? |
| 14817 | echo "$as_me:14817: \$? = $ac_status" >&5 |
| 14818 | (exit $ac_status); } && |
| 14819 | { ac_try='test -s conftest$ac_exeext' |
| 14820 | { (eval echo "$as_me:14820: \"$ac_try\"") >&5 |
| 14821 | (eval $ac_try) 2>&5 |
| 14822 | ac_status=$? |
| 14823 | echo "$as_me:14823: \$? = $ac_status" >&5 |
| 14824 | (exit $ac_status); }; }; then |
| 14825 | ac_cv_lib_x_opendir=yes |
| 14826 | else |
| 14827 | echo "$as_me: failed program was:" >&5 |
| 14828 | cat conftest.$ac_ext >&5 |
| 14829 | ac_cv_lib_x_opendir=no |
| 14830 | fi |
| 14831 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14832 | LIBS=$ac_check_lib_save_LIBS |
| 14833 | fi |
| 14834 | echo "$as_me:14834: result: $ac_cv_lib_x_opendir" >&5 |
| 14835 | echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6 |
| 14836 | if test $ac_cv_lib_x_opendir = yes; then |
| 14837 | LIBS="$LIBS -lx" |
| 14838 | fi |
| 14839 | |
| 14840 | fi |
| 14841 | |
| 14842 | echo "$as_me:14842: checking whether time.h and sys/time.h may both be included" >&5 |
| 14843 | echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6 |
| 14844 | if test "${ac_cv_header_time+set}" = set; then |
| 14845 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14846 | else |
| 14847 | cat >conftest.$ac_ext <<_ACEOF |
| 14848 | #line 14848 "configure" |
| 14849 | #include "confdefs.h" |
| 14850 | #include <sys/types.h> |
| 14851 | #include <sys/time.h> |
| 14852 | #include <time.h> |
| 14853 | |
| 14854 | int |
| 14855 | main () |
| 14856 | { |
| 14857 | if ((struct tm *) 0) |
| 14858 | return 0; |
| 14859 | ; |
| 14860 | return 0; |
| 14861 | } |
| 14862 | _ACEOF |
| 14863 | rm -f conftest.$ac_objext |
| 14864 | if { (eval echo "$as_me:14864: \"$ac_compile\"") >&5 |
| 14865 | (eval $ac_compile) 2>&5 |
| 14866 | ac_status=$? |
| 14867 | echo "$as_me:14867: \$? = $ac_status" >&5 |
| 14868 | (exit $ac_status); } && |
| 14869 | { ac_try='test -s conftest.$ac_objext' |
| 14870 | { (eval echo "$as_me:14870: \"$ac_try\"") >&5 |
| 14871 | (eval $ac_try) 2>&5 |
| 14872 | ac_status=$? |
| 14873 | echo "$as_me:14873: \$? = $ac_status" >&5 |
| 14874 | (exit $ac_status); }; }; then |
| 14875 | ac_cv_header_time=yes |
| 14876 | else |
| 14877 | echo "$as_me: failed program was:" >&5 |
| 14878 | cat conftest.$ac_ext >&5 |
| 14879 | ac_cv_header_time=no |
| 14880 | fi |
| 14881 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 14882 | fi |
| 14883 | echo "$as_me:14883: result: $ac_cv_header_time" >&5 |
| 14884 | echo "${ECHO_T}$ac_cv_header_time" >&6 |
| 14885 | if test $ac_cv_header_time = yes; then |
| 14886 | |
| 14887 | cat >>confdefs.h <<\EOF |
| 14888 | #define TIME_WITH_SYS_TIME 1 |
| 14889 | EOF |
| 14890 | |
| 14891 | fi |
| 14892 | |
| 14893 | cf_regex_func=no |
| 14894 | |
| 14895 | cf_regex_libs="regex re" |
| 14896 | case $host_os in |
| 14897 | (mingw*) |
| 14898 | cf_regex_libs="gnurx $cf_regex_libs" |
| 14899 | ;; |
| 14900 | esac |
| 14901 | |
| 14902 | echo "$as_me:14902: checking for regcomp" >&5 |
| 14903 | echo $ECHO_N "checking for regcomp... $ECHO_C" >&6 |
| 14904 | if test "${ac_cv_func_regcomp+set}" = set; then |
| 14905 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14906 | else |
| 14907 | cat >conftest.$ac_ext <<_ACEOF |
| 14908 | #line 14908 "configure" |
| 14909 | #include "confdefs.h" |
| 14910 | /* System header to define __stub macros and hopefully few prototypes, |
| 14911 | which can conflict with char regcomp (); below. */ |
| 14912 | #include <assert.h> |
| 14913 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 14914 | #ifdef __cplusplus |
| 14915 | extern "C" |
| 14916 | #endif |
| 14917 | /* We use char because int might match the return type of a gcc2 |
| 14918 | builtin and then its argument prototype would still apply. */ |
| 14919 | char regcomp (); |
| 14920 | char (*f) (); |
| 14921 | |
| 14922 | int |
| 14923 | main () |
| 14924 | { |
| 14925 | /* The GNU C library defines this for functions which it implements |
| 14926 | to always fail with ENOSYS. Some functions are actually named |
| 14927 | something starting with __ and the normal name is an alias. */ |
| 14928 | #if defined (__stub_regcomp) || defined (__stub___regcomp) |
| 14929 | choke me |
| 14930 | #else |
| 14931 | f = regcomp; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 14932 | #endif |
| 14933 | |
| 14934 | ; |
| 14935 | return 0; |
| 14936 | } |
| 14937 | _ACEOF |
| 14938 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14939 | if { (eval echo "$as_me:14939: \"$ac_link\"") >&5 |
| 14940 | (eval $ac_link) 2>&5 |
| 14941 | ac_status=$? |
| 14942 | echo "$as_me:14942: \$? = $ac_status" >&5 |
| 14943 | (exit $ac_status); } && |
| 14944 | { ac_try='test -s conftest$ac_exeext' |
| 14945 | { (eval echo "$as_me:14945: \"$ac_try\"") >&5 |
| 14946 | (eval $ac_try) 2>&5 |
| 14947 | ac_status=$? |
| 14948 | echo "$as_me:14948: \$? = $ac_status" >&5 |
| 14949 | (exit $ac_status); }; }; then |
| 14950 | ac_cv_func_regcomp=yes |
| 14951 | else |
| 14952 | echo "$as_me: failed program was:" >&5 |
| 14953 | cat conftest.$ac_ext >&5 |
| 14954 | ac_cv_func_regcomp=no |
| 14955 | fi |
| 14956 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 14957 | fi |
| 14958 | echo "$as_me:14958: result: $ac_cv_func_regcomp" >&5 |
| 14959 | echo "${ECHO_T}$ac_cv_func_regcomp" >&6 |
| 14960 | if test $ac_cv_func_regcomp = yes; then |
| 14961 | cf_regex_func=regcomp |
| 14962 | else |
| 14963 | |
| 14964 | for cf_regex_lib in $cf_regex_libs |
| 14965 | do |
| 14966 | as_ac_Lib=`echo "ac_cv_lib_$cf_regex_lib''_regcomp" | $as_tr_sh` |
| 14967 | echo "$as_me:14967: checking for regcomp in -l$cf_regex_lib" >&5 |
| 14968 | echo $ECHO_N "checking for regcomp in -l$cf_regex_lib... $ECHO_C" >&6 |
| 14969 | if eval "test \"\${$as_ac_Lib+set}\" = set"; then |
| 14970 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 14971 | else |
| 14972 | ac_check_lib_save_LIBS=$LIBS |
| 14973 | LIBS="-l$cf_regex_lib $LIBS" |
| 14974 | cat >conftest.$ac_ext <<_ACEOF |
| 14975 | #line 14975 "configure" |
| 14976 | #include "confdefs.h" |
| 14977 | |
| 14978 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 14979 | #ifdef __cplusplus |
| 14980 | extern "C" |
| 14981 | #endif |
| 14982 | /* We use char because int might match the return type of a gcc2 |
| 14983 | builtin and then its argument prototype would still apply. */ |
| 14984 | char regcomp (); |
| 14985 | int |
| 14986 | main () |
| 14987 | { |
| 14988 | regcomp (); |
| 14989 | ; |
| 14990 | return 0; |
| 14991 | } |
| 14992 | _ACEOF |
| 14993 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 14994 | if { (eval echo "$as_me:14994: \"$ac_link\"") >&5 |
| 14995 | (eval $ac_link) 2>&5 |
| 14996 | ac_status=$? |
| 14997 | echo "$as_me:14997: \$? = $ac_status" >&5 |
| 14998 | (exit $ac_status); } && |
| 14999 | { ac_try='test -s conftest$ac_exeext' |
| 15000 | { (eval echo "$as_me:15000: \"$ac_try\"") >&5 |
| 15001 | (eval $ac_try) 2>&5 |
| 15002 | ac_status=$? |
| 15003 | echo "$as_me:15003: \$? = $ac_status" >&5 |
| 15004 | (exit $ac_status); }; }; then |
| 15005 | eval "$as_ac_Lib=yes" |
| 15006 | else |
| 15007 | echo "$as_me: failed program was:" >&5 |
| 15008 | cat conftest.$ac_ext >&5 |
| 15009 | eval "$as_ac_Lib=no" |
| 15010 | fi |
| 15011 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15012 | LIBS=$ac_check_lib_save_LIBS |
| 15013 | fi |
| 15014 | echo "$as_me:15014: result: `eval echo '${'$as_ac_Lib'}'`" >&5 |
| 15015 | echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 |
| 15016 | if test `eval echo '${'$as_ac_Lib'}'` = yes; then |
| 15017 | |
| 15018 | cf_add_libs="-l$cf_regex_lib" |
| 15019 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 15020 | for cf_add_1lib in $LIBS |
| 15021 | do |
| 15022 | for cf_add_2lib in $cf_add_libs |
| 15023 | do |
| 15024 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 15025 | then |
| 15026 | cf_add_1lib= |
| 15027 | break |
| 15028 | fi |
| 15029 | done |
| 15030 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 15031 | done |
| 15032 | LIBS="$cf_add_libs" |
| 15033 | |
| 15034 | cf_regex_func=regcomp |
| 15035 | break |
| 15036 | fi |
| 15037 | |
| 15038 | done |
| 15039 | |
| 15040 | fi |
| 15041 | |
| 15042 | if test "$cf_regex_func" = no ; then |
| 15043 | echo "$as_me:15043: checking for compile" >&5 |
| 15044 | echo $ECHO_N "checking for compile... $ECHO_C" >&6 |
| 15045 | if test "${ac_cv_func_compile+set}" = set; then |
| 15046 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15047 | else |
| 15048 | cat >conftest.$ac_ext <<_ACEOF |
| 15049 | #line 15049 "configure" |
| 15050 | #include "confdefs.h" |
| 15051 | /* System header to define __stub macros and hopefully few prototypes, |
| 15052 | which can conflict with char compile (); below. */ |
| 15053 | #include <assert.h> |
| 15054 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 15055 | #ifdef __cplusplus |
| 15056 | extern "C" |
| 15057 | #endif |
| 15058 | /* We use char because int might match the return type of a gcc2 |
| 15059 | builtin and then its argument prototype would still apply. */ |
| 15060 | char compile (); |
| 15061 | char (*f) (); |
| 15062 | |
| 15063 | int |
| 15064 | main () |
| 15065 | { |
| 15066 | /* The GNU C library defines this for functions which it implements |
| 15067 | to always fail with ENOSYS. Some functions are actually named |
| 15068 | something starting with __ and the normal name is an alias. */ |
| 15069 | #if defined (__stub_compile) || defined (__stub___compile) |
| 15070 | choke me |
| 15071 | #else |
| 15072 | f = compile; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 15073 | #endif |
| 15074 | |
| 15075 | ; |
| 15076 | return 0; |
| 15077 | } |
| 15078 | _ACEOF |
| 15079 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15080 | if { (eval echo "$as_me:15080: \"$ac_link\"") >&5 |
| 15081 | (eval $ac_link) 2>&5 |
| 15082 | ac_status=$? |
| 15083 | echo "$as_me:15083: \$? = $ac_status" >&5 |
| 15084 | (exit $ac_status); } && |
| 15085 | { ac_try='test -s conftest$ac_exeext' |
| 15086 | { (eval echo "$as_me:15086: \"$ac_try\"") >&5 |
| 15087 | (eval $ac_try) 2>&5 |
| 15088 | ac_status=$? |
| 15089 | echo "$as_me:15089: \$? = $ac_status" >&5 |
| 15090 | (exit $ac_status); }; }; then |
| 15091 | ac_cv_func_compile=yes |
| 15092 | else |
| 15093 | echo "$as_me: failed program was:" >&5 |
| 15094 | cat conftest.$ac_ext >&5 |
| 15095 | ac_cv_func_compile=no |
| 15096 | fi |
| 15097 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15098 | fi |
| 15099 | echo "$as_me:15099: result: $ac_cv_func_compile" >&5 |
| 15100 | echo "${ECHO_T}$ac_cv_func_compile" >&6 |
| 15101 | if test $ac_cv_func_compile = yes; then |
| 15102 | cf_regex_func=compile |
| 15103 | else |
| 15104 | |
| 15105 | echo "$as_me:15105: checking for compile in -lgen" >&5 |
| 15106 | echo $ECHO_N "checking for compile in -lgen... $ECHO_C" >&6 |
| 15107 | if test "${ac_cv_lib_gen_compile+set}" = set; then |
| 15108 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15109 | else |
| 15110 | ac_check_lib_save_LIBS=$LIBS |
| 15111 | LIBS="-lgen $LIBS" |
| 15112 | cat >conftest.$ac_ext <<_ACEOF |
| 15113 | #line 15113 "configure" |
| 15114 | #include "confdefs.h" |
| 15115 | |
| 15116 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 15117 | #ifdef __cplusplus |
| 15118 | extern "C" |
| 15119 | #endif |
| 15120 | /* We use char because int might match the return type of a gcc2 |
| 15121 | builtin and then its argument prototype would still apply. */ |
| 15122 | char compile (); |
| 15123 | int |
| 15124 | main () |
| 15125 | { |
| 15126 | compile (); |
| 15127 | ; |
| 15128 | return 0; |
| 15129 | } |
| 15130 | _ACEOF |
| 15131 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15132 | if { (eval echo "$as_me:15132: \"$ac_link\"") >&5 |
| 15133 | (eval $ac_link) 2>&5 |
| 15134 | ac_status=$? |
| 15135 | echo "$as_me:15135: \$? = $ac_status" >&5 |
| 15136 | (exit $ac_status); } && |
| 15137 | { ac_try='test -s conftest$ac_exeext' |
| 15138 | { (eval echo "$as_me:15138: \"$ac_try\"") >&5 |
| 15139 | (eval $ac_try) 2>&5 |
| 15140 | ac_status=$? |
| 15141 | echo "$as_me:15141: \$? = $ac_status" >&5 |
| 15142 | (exit $ac_status); }; }; then |
| 15143 | ac_cv_lib_gen_compile=yes |
| 15144 | else |
| 15145 | echo "$as_me: failed program was:" >&5 |
| 15146 | cat conftest.$ac_ext >&5 |
| 15147 | ac_cv_lib_gen_compile=no |
| 15148 | fi |
| 15149 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15150 | LIBS=$ac_check_lib_save_LIBS |
| 15151 | fi |
| 15152 | echo "$as_me:15152: result: $ac_cv_lib_gen_compile" >&5 |
| 15153 | echo "${ECHO_T}$ac_cv_lib_gen_compile" >&6 |
| 15154 | if test $ac_cv_lib_gen_compile = yes; then |
| 15155 | |
| 15156 | cf_add_libs="-lgen" |
| 15157 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 15158 | for cf_add_1lib in $LIBS |
| 15159 | do |
| 15160 | for cf_add_2lib in $cf_add_libs |
| 15161 | do |
| 15162 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 15163 | then |
| 15164 | cf_add_1lib= |
| 15165 | break |
| 15166 | fi |
| 15167 | done |
| 15168 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 15169 | done |
| 15170 | LIBS="$cf_add_libs" |
| 15171 | |
| 15172 | cf_regex_func=compile |
| 15173 | fi |
| 15174 | |
| 15175 | fi |
| 15176 | |
| 15177 | fi |
| 15178 | |
| 15179 | if test "$cf_regex_func" = no ; then |
| 15180 | { echo "$as_me:15180: WARNING: cannot find regular expression library" >&5 |
| 15181 | echo "$as_me: WARNING: cannot find regular expression library" >&2;} |
| 15182 | fi |
| 15183 | |
| 15184 | echo "$as_me:15184: checking for regular-expression headers" >&5 |
| 15185 | echo $ECHO_N "checking for regular-expression headers... $ECHO_C" >&6 |
| 15186 | if test "${cf_cv_regex_hdrs+set}" = set; then |
| 15187 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15188 | else |
| 15189 | |
| 15190 | cf_cv_regex_hdrs=no |
| 15191 | case $cf_regex_func in |
| 15192 | (compile) |
| 15193 | for cf_regex_hdr in regexp.h regexpr.h |
| 15194 | do |
| 15195 | cat >conftest.$ac_ext <<_ACEOF |
| 15196 | #line 15196 "configure" |
| 15197 | #include "confdefs.h" |
| 15198 | #include <$cf_regex_hdr> |
| 15199 | int |
| 15200 | main () |
| 15201 | { |
| 15202 | |
| 15203 | char *p = compile("", "", "", 0); |
| 15204 | int x = step("", ""); |
| 15205 | |
| 15206 | ; |
| 15207 | return 0; |
| 15208 | } |
| 15209 | _ACEOF |
| 15210 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15211 | if { (eval echo "$as_me:15211: \"$ac_link\"") >&5 |
| 15212 | (eval $ac_link) 2>&5 |
| 15213 | ac_status=$? |
| 15214 | echo "$as_me:15214: \$? = $ac_status" >&5 |
| 15215 | (exit $ac_status); } && |
| 15216 | { ac_try='test -s conftest$ac_exeext' |
| 15217 | { (eval echo "$as_me:15217: \"$ac_try\"") >&5 |
| 15218 | (eval $ac_try) 2>&5 |
| 15219 | ac_status=$? |
| 15220 | echo "$as_me:15220: \$? = $ac_status" >&5 |
| 15221 | (exit $ac_status); }; }; then |
| 15222 | |
| 15223 | cf_cv_regex_hdrs=$cf_regex_hdr |
| 15224 | break |
| 15225 | |
| 15226 | else |
| 15227 | echo "$as_me: failed program was:" >&5 |
| 15228 | cat conftest.$ac_ext >&5 |
| 15229 | fi |
| 15230 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15231 | done |
| 15232 | ;; |
| 15233 | (*) |
| 15234 | for cf_regex_hdr in regex.h |
| 15235 | do |
| 15236 | cat >conftest.$ac_ext <<_ACEOF |
| 15237 | #line 15237 "configure" |
| 15238 | #include "confdefs.h" |
| 15239 | #include <sys/types.h> |
| 15240 | #include <$cf_regex_hdr> |
| 15241 | int |
| 15242 | main () |
| 15243 | { |
| 15244 | |
| 15245 | regex_t *p; |
| 15246 | int x = regcomp(p, "", 0); |
| 15247 | int y = regexec(p, "", 0, 0, 0); |
| 15248 | regfree(p); |
| 15249 | |
| 15250 | ; |
| 15251 | return 0; |
| 15252 | } |
| 15253 | _ACEOF |
| 15254 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15255 | if { (eval echo "$as_me:15255: \"$ac_link\"") >&5 |
| 15256 | (eval $ac_link) 2>&5 |
| 15257 | ac_status=$? |
| 15258 | echo "$as_me:15258: \$? = $ac_status" >&5 |
| 15259 | (exit $ac_status); } && |
| 15260 | { ac_try='test -s conftest$ac_exeext' |
| 15261 | { (eval echo "$as_me:15261: \"$ac_try\"") >&5 |
| 15262 | (eval $ac_try) 2>&5 |
| 15263 | ac_status=$? |
| 15264 | echo "$as_me:15264: \$? = $ac_status" >&5 |
| 15265 | (exit $ac_status); }; }; then |
| 15266 | |
| 15267 | cf_cv_regex_hdrs=$cf_regex_hdr |
| 15268 | break |
| 15269 | |
| 15270 | else |
| 15271 | echo "$as_me: failed program was:" >&5 |
| 15272 | cat conftest.$ac_ext >&5 |
| 15273 | fi |
| 15274 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15275 | done |
| 15276 | ;; |
| 15277 | esac |
| 15278 | |
| 15279 | fi |
| 15280 | echo "$as_me:15280: result: $cf_cv_regex_hdrs" >&5 |
| 15281 | echo "${ECHO_T}$cf_cv_regex_hdrs" >&6 |
| 15282 | |
| 15283 | case $cf_cv_regex_hdrs in |
| 15284 | (no) { echo "$as_me:15284: WARNING: no regular expression header found" >&5 |
| 15285 | echo "$as_me: WARNING: no regular expression header found" >&2;} ;; |
| 15286 | (regex.h) |
| 15287 | cat >>confdefs.h <<\EOF |
| 15288 | #define HAVE_REGEX_H_FUNCS 1 |
| 15289 | EOF |
| 15290 | ;; |
| 15291 | (regexp.h) |
| 15292 | cat >>confdefs.h <<\EOF |
| 15293 | #define HAVE_REGEXP_H_FUNCS 1 |
| 15294 | EOF |
| 15295 | ;; |
| 15296 | (regexpr.h) |
| 15297 | cat >>confdefs.h <<\EOF |
| 15298 | #define HAVE_REGEXPR_H_FUNCS 1 |
| 15299 | EOF |
| 15300 | ;; |
| 15301 | esac |
| 15302 | |
| 15303 | for ac_header in \ |
| 15304 | fcntl.h \ |
| 15305 | getopt.h \ |
| 15306 | limits.h \ |
| 15307 | locale.h \ |
| 15308 | math.h \ |
| 15309 | poll.h \ |
| 15310 | sys/bsdtypes.h \ |
| 15311 | sys/ioctl.h \ |
| 15312 | sys/param.h \ |
| 15313 | sys/poll.h \ |
| 15314 | sys/select.h \ |
| 15315 | sys/time.h \ |
| 15316 | sys/times.h \ |
| 15317 | ttyent.h \ |
| 15318 | unistd.h \ |
| 15319 | wctype.h \ |
| 15320 | |
| 15321 | do |
| 15322 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 15323 | echo "$as_me:15323: checking for $ac_header" >&5 |
| 15324 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 15325 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 15326 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15327 | else |
| 15328 | cat >conftest.$ac_ext <<_ACEOF |
| 15329 | #line 15329 "configure" |
| 15330 | #include "confdefs.h" |
| 15331 | #include <$ac_header> |
| 15332 | _ACEOF |
| 15333 | if { (eval echo "$as_me:15333: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 15334 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 15335 | ac_status=$? |
| 15336 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 15337 | rm -f conftest.er1 |
| 15338 | cat conftest.err >&5 |
| 15339 | echo "$as_me:15339: \$? = $ac_status" >&5 |
| 15340 | (exit $ac_status); } >/dev/null; then |
| 15341 | if test -s conftest.err; then |
| 15342 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 15343 | else |
| 15344 | ac_cpp_err= |
| 15345 | fi |
| 15346 | else |
| 15347 | ac_cpp_err=yes |
| 15348 | fi |
| 15349 | if test -z "$ac_cpp_err"; then |
| 15350 | eval "$as_ac_Header=yes" |
| 15351 | else |
| 15352 | echo "$as_me: failed program was:" >&5 |
| 15353 | cat conftest.$ac_ext >&5 |
| 15354 | eval "$as_ac_Header=no" |
| 15355 | fi |
| 15356 | rm -f conftest.err conftest.$ac_ext |
| 15357 | fi |
| 15358 | echo "$as_me:15358: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 15359 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 15360 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 15361 | cat >>confdefs.h <<EOF |
| 15362 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 15363 | EOF |
| 15364 | |
| 15365 | fi |
| 15366 | done |
| 15367 | |
| 15368 | for ac_header in unistd.h getopt.h |
| 15369 | do |
| 15370 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 15371 | echo "$as_me:15371: checking for $ac_header" >&5 |
| 15372 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 15373 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 15374 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15375 | else |
| 15376 | cat >conftest.$ac_ext <<_ACEOF |
| 15377 | #line 15377 "configure" |
| 15378 | #include "confdefs.h" |
| 15379 | #include <$ac_header> |
| 15380 | _ACEOF |
| 15381 | if { (eval echo "$as_me:15381: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 15382 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 15383 | ac_status=$? |
| 15384 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 15385 | rm -f conftest.er1 |
| 15386 | cat conftest.err >&5 |
| 15387 | echo "$as_me:15387: \$? = $ac_status" >&5 |
| 15388 | (exit $ac_status); } >/dev/null; then |
| 15389 | if test -s conftest.err; then |
| 15390 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 15391 | else |
| 15392 | ac_cpp_err= |
| 15393 | fi |
| 15394 | else |
| 15395 | ac_cpp_err=yes |
| 15396 | fi |
| 15397 | if test -z "$ac_cpp_err"; then |
| 15398 | eval "$as_ac_Header=yes" |
| 15399 | else |
| 15400 | echo "$as_me: failed program was:" >&5 |
| 15401 | cat conftest.$ac_ext >&5 |
| 15402 | eval "$as_ac_Header=no" |
| 15403 | fi |
| 15404 | rm -f conftest.err conftest.$ac_ext |
| 15405 | fi |
| 15406 | echo "$as_me:15406: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 15407 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 15408 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 15409 | cat >>confdefs.h <<EOF |
| 15410 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 15411 | EOF |
| 15412 | |
| 15413 | fi |
| 15414 | done |
| 15415 | |
| 15416 | echo "$as_me:15416: checking for header declaring getopt variables" >&5 |
| 15417 | echo $ECHO_N "checking for header declaring getopt variables... $ECHO_C" >&6 |
| 15418 | if test "${cf_cv_getopt_header+set}" = set; then |
| 15419 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15420 | else |
| 15421 | |
| 15422 | cf_cv_getopt_header=none |
| 15423 | for cf_header in stdio.h stdlib.h unistd.h getopt.h |
| 15424 | do |
| 15425 | cat >conftest.$ac_ext <<_ACEOF |
| 15426 | #line 15426 "configure" |
| 15427 | #include "confdefs.h" |
| 15428 | |
| 15429 | #include <$cf_header> |
| 15430 | int |
| 15431 | main () |
| 15432 | { |
| 15433 | int x = optind; char *y = optarg |
| 15434 | ; |
| 15435 | return 0; |
| 15436 | } |
| 15437 | _ACEOF |
| 15438 | rm -f conftest.$ac_objext |
| 15439 | if { (eval echo "$as_me:15439: \"$ac_compile\"") >&5 |
| 15440 | (eval $ac_compile) 2>&5 |
| 15441 | ac_status=$? |
| 15442 | echo "$as_me:15442: \$? = $ac_status" >&5 |
| 15443 | (exit $ac_status); } && |
| 15444 | { ac_try='test -s conftest.$ac_objext' |
| 15445 | { (eval echo "$as_me:15445: \"$ac_try\"") >&5 |
| 15446 | (eval $ac_try) 2>&5 |
| 15447 | ac_status=$? |
| 15448 | echo "$as_me:15448: \$? = $ac_status" >&5 |
| 15449 | (exit $ac_status); }; }; then |
| 15450 | cf_cv_getopt_header=$cf_header |
| 15451 | break |
| 15452 | else |
| 15453 | echo "$as_me: failed program was:" >&5 |
| 15454 | cat conftest.$ac_ext >&5 |
| 15455 | fi |
| 15456 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15457 | done |
| 15458 | |
| 15459 | fi |
| 15460 | echo "$as_me:15460: result: $cf_cv_getopt_header" >&5 |
| 15461 | echo "${ECHO_T}$cf_cv_getopt_header" >&6 |
| 15462 | if test $cf_cv_getopt_header != none ; then |
| 15463 | |
| 15464 | cat >>confdefs.h <<\EOF |
| 15465 | #define HAVE_GETOPT_HEADER 1 |
| 15466 | EOF |
| 15467 | |
| 15468 | fi |
| 15469 | if test $cf_cv_getopt_header = getopt.h ; then |
| 15470 | |
| 15471 | cat >>confdefs.h <<\EOF |
| 15472 | #define NEED_GETOPT_H 1 |
| 15473 | EOF |
| 15474 | |
| 15475 | fi |
| 15476 | |
| 15477 | # check for ISC (this may also define _POSIX_SOURCE) |
| 15478 | # Note: even non-Posix ISC needs <sys/bsdtypes.h> to declare fd_set |
| 15479 | if test "x$ISC" = xyes ; then |
| 15480 | |
| 15481 | echo "$as_me:15481: checking for main in -lcposix" >&5 |
| 15482 | echo $ECHO_N "checking for main in -lcposix... $ECHO_C" >&6 |
| 15483 | if test "${ac_cv_lib_cposix_main+set}" = set; then |
| 15484 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15485 | else |
| 15486 | ac_check_lib_save_LIBS=$LIBS |
| 15487 | LIBS="-lcposix $LIBS" |
| 15488 | cat >conftest.$ac_ext <<_ACEOF |
| 15489 | #line 15489 "configure" |
| 15490 | #include "confdefs.h" |
| 15491 | |
| 15492 | int |
| 15493 | main () |
| 15494 | { |
| 15495 | main (); |
| 15496 | ; |
| 15497 | return 0; |
| 15498 | } |
| 15499 | _ACEOF |
| 15500 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15501 | if { (eval echo "$as_me:15501: \"$ac_link\"") >&5 |
| 15502 | (eval $ac_link) 2>&5 |
| 15503 | ac_status=$? |
| 15504 | echo "$as_me:15504: \$? = $ac_status" >&5 |
| 15505 | (exit $ac_status); } && |
| 15506 | { ac_try='test -s conftest$ac_exeext' |
| 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 | ac_cv_lib_cposix_main=yes |
| 15513 | else |
| 15514 | echo "$as_me: failed program was:" >&5 |
| 15515 | cat conftest.$ac_ext >&5 |
| 15516 | ac_cv_lib_cposix_main=no |
| 15517 | fi |
| 15518 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15519 | LIBS=$ac_check_lib_save_LIBS |
| 15520 | fi |
| 15521 | echo "$as_me:15521: result: $ac_cv_lib_cposix_main" >&5 |
| 15522 | echo "${ECHO_T}$ac_cv_lib_cposix_main" >&6 |
| 15523 | if test $ac_cv_lib_cposix_main = yes; then |
| 15524 | cat >>confdefs.h <<EOF |
| 15525 | #define HAVE_LIBCPOSIX 1 |
| 15526 | EOF |
| 15527 | |
| 15528 | LIBS="-lcposix $LIBS" |
| 15529 | |
| 15530 | fi |
| 15531 | |
| 15532 | echo "$as_me:15532: checking for bzero in -linet" >&5 |
| 15533 | echo $ECHO_N "checking for bzero in -linet... $ECHO_C" >&6 |
| 15534 | if test "${ac_cv_lib_inet_bzero+set}" = set; then |
| 15535 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15536 | else |
| 15537 | ac_check_lib_save_LIBS=$LIBS |
| 15538 | LIBS="-linet $LIBS" |
| 15539 | cat >conftest.$ac_ext <<_ACEOF |
| 15540 | #line 15540 "configure" |
| 15541 | #include "confdefs.h" |
| 15542 | |
| 15543 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 15544 | #ifdef __cplusplus |
| 15545 | extern "C" |
| 15546 | #endif |
| 15547 | /* We use char because int might match the return type of a gcc2 |
| 15548 | builtin and then its argument prototype would still apply. */ |
| 15549 | char bzero (); |
| 15550 | int |
| 15551 | main () |
| 15552 | { |
| 15553 | bzero (); |
| 15554 | ; |
| 15555 | return 0; |
| 15556 | } |
| 15557 | _ACEOF |
| 15558 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 15559 | if { (eval echo "$as_me:15559: \"$ac_link\"") >&5 |
| 15560 | (eval $ac_link) 2>&5 |
| 15561 | ac_status=$? |
| 15562 | echo "$as_me:15562: \$? = $ac_status" >&5 |
| 15563 | (exit $ac_status); } && |
| 15564 | { ac_try='test -s conftest$ac_exeext' |
| 15565 | { (eval echo "$as_me:15565: \"$ac_try\"") >&5 |
| 15566 | (eval $ac_try) 2>&5 |
| 15567 | ac_status=$? |
| 15568 | echo "$as_me:15568: \$? = $ac_status" >&5 |
| 15569 | (exit $ac_status); }; }; then |
| 15570 | ac_cv_lib_inet_bzero=yes |
| 15571 | else |
| 15572 | echo "$as_me: failed program was:" >&5 |
| 15573 | cat conftest.$ac_ext >&5 |
| 15574 | ac_cv_lib_inet_bzero=no |
| 15575 | fi |
| 15576 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 15577 | LIBS=$ac_check_lib_save_LIBS |
| 15578 | fi |
| 15579 | echo "$as_me:15579: result: $ac_cv_lib_inet_bzero" >&5 |
| 15580 | echo "${ECHO_T}$ac_cv_lib_inet_bzero" >&6 |
| 15581 | if test $ac_cv_lib_inet_bzero = yes; then |
| 15582 | |
| 15583 | cf_add_libs="-linet" |
| 15584 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 15585 | for cf_add_1lib in $LIBS |
| 15586 | do |
| 15587 | for cf_add_2lib in $cf_add_libs |
| 15588 | do |
| 15589 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 15590 | then |
| 15591 | cf_add_1lib= |
| 15592 | break |
| 15593 | fi |
| 15594 | done |
| 15595 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 15596 | done |
| 15597 | LIBS="$cf_add_libs" |
| 15598 | |
| 15599 | fi |
| 15600 | fi |
| 15601 | |
| 15602 | echo "$as_me:15602: checking if sys/time.h works with sys/select.h" >&5 |
| 15603 | echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6 |
| 15604 | if test "${cf_cv_sys_time_select+set}" = set; then |
| 15605 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15606 | else |
| 15607 | |
| 15608 | cat >conftest.$ac_ext <<_ACEOF |
| 15609 | #line 15609 "configure" |
| 15610 | #include "confdefs.h" |
| 15611 | |
| 15612 | #include <sys/types.h> |
| 15613 | #ifdef HAVE_SYS_TIME_H |
| 15614 | #include <sys/time.h> |
| 15615 | #endif |
| 15616 | #ifdef HAVE_SYS_SELECT_H |
| 15617 | #include <sys/select.h> |
| 15618 | #endif |
| 15619 | |
| 15620 | int |
| 15621 | main () |
| 15622 | { |
| 15623 | |
| 15624 | ; |
| 15625 | return 0; |
| 15626 | } |
| 15627 | _ACEOF |
| 15628 | rm -f conftest.$ac_objext |
| 15629 | if { (eval echo "$as_me:15629: \"$ac_compile\"") >&5 |
| 15630 | (eval $ac_compile) 2>&5 |
| 15631 | ac_status=$? |
| 15632 | echo "$as_me:15632: \$? = $ac_status" >&5 |
| 15633 | (exit $ac_status); } && |
| 15634 | { ac_try='test -s conftest.$ac_objext' |
| 15635 | { (eval echo "$as_me:15635: \"$ac_try\"") >&5 |
| 15636 | (eval $ac_try) 2>&5 |
| 15637 | ac_status=$? |
| 15638 | echo "$as_me:15638: \$? = $ac_status" >&5 |
| 15639 | (exit $ac_status); }; }; then |
| 15640 | cf_cv_sys_time_select=yes |
| 15641 | else |
| 15642 | echo "$as_me: failed program was:" >&5 |
| 15643 | cat conftest.$ac_ext >&5 |
| 15644 | cf_cv_sys_time_select=no |
| 15645 | fi |
| 15646 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15647 | |
| 15648 | fi |
| 15649 | |
| 15650 | echo "$as_me:15650: result: $cf_cv_sys_time_select" >&5 |
| 15651 | echo "${ECHO_T}$cf_cv_sys_time_select" >&6 |
| 15652 | test "$cf_cv_sys_time_select" = yes && |
| 15653 | cat >>confdefs.h <<\EOF |
| 15654 | #define HAVE_SYS_TIME_SELECT 1 |
| 15655 | EOF |
| 15656 | |
| 15657 | ### checks for compiler characteristics |
| 15658 | ac_ext=c |
| 15659 | ac_cpp='$CPP $CPPFLAGS' |
| 15660 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 15661 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 15662 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 15663 | ac_main_return=return |
| 15664 | |
| 15665 | echo "$as_me:15665: checking for an ANSI C-conforming const" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15666 | echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6 |
| 15667 | if test "${ac_cv_c_const+set}" = set; then |
| 15668 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15669 | else |
| 15670 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15671 | #line 15671 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15672 | #include "confdefs.h" |
| 15673 | |
| 15674 | int |
| 15675 | main () |
| 15676 | { |
| 15677 | /* FIXME: Include the comments suggested by Paul. */ |
| 15678 | #ifndef __cplusplus |
| 15679 | /* Ultrix mips cc rejects this. */ |
| 15680 | typedef int charset[2]; |
| 15681 | const charset x; |
| 15682 | /* SunOS 4.1.1 cc rejects this. */ |
| 15683 | char const *const *ccp; |
| 15684 | char **p; |
| 15685 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 15686 | struct point {int x, y;}; |
| 15687 | static struct point const zero = {0,0}; |
| 15688 | /* AIX XL C 1.02.0.0 rejects this. |
| 15689 | It does not let you subtract one const X* pointer from another in |
| 15690 | an arm of an if-expression whose if-part is not a constant |
| 15691 | expression */ |
| 15692 | const char *g = "string"; |
| 15693 | ccp = &g + (g ? g-g : 0); |
| 15694 | /* HPUX 7.0 cc rejects these. */ |
| 15695 | ++ccp; |
| 15696 | p = (char**) ccp; |
| 15697 | ccp = (char const *const *) p; |
| 15698 | { /* SCO 3.2v4 cc rejects this. */ |
| 15699 | char *t; |
| 15700 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 15701 | |
| 15702 | *t++ = 0; |
| 15703 | } |
| 15704 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
| 15705 | int x[] = {25, 17}; |
| 15706 | const int *foo = &x[0]; |
| 15707 | ++foo; |
| 15708 | } |
| 15709 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 15710 | typedef const int *iptr; |
| 15711 | iptr p = 0; |
| 15712 | ++p; |
| 15713 | } |
| 15714 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 15715 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 15716 | struct s { int j; const int *ap[3]; }; |
| 15717 | struct s *b; b->j = 5; |
| 15718 | } |
| 15719 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 15720 | const int foo = 10; |
| 15721 | } |
| 15722 | #endif |
| 15723 | |
| 15724 | ; |
| 15725 | return 0; |
| 15726 | } |
| 15727 | _ACEOF |
| 15728 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15729 | if { (eval echo "$as_me:15729: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15730 | (eval $ac_compile) 2>&5 |
| 15731 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15732 | echo "$as_me:15732: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15733 | (exit $ac_status); } && |
| 15734 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15735 | { (eval echo "$as_me:15735: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15736 | (eval $ac_try) 2>&5 |
| 15737 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15738 | echo "$as_me:15738: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15739 | (exit $ac_status); }; }; then |
| 15740 | ac_cv_c_const=yes |
| 15741 | else |
| 15742 | echo "$as_me: failed program was:" >&5 |
| 15743 | cat conftest.$ac_ext >&5 |
| 15744 | ac_cv_c_const=no |
| 15745 | fi |
| 15746 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15747 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15748 | echo "$as_me:15748: result: $ac_cv_c_const" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15749 | echo "${ECHO_T}$ac_cv_c_const" >&6 |
| 15750 | if test $ac_cv_c_const = no; then |
| 15751 | |
| 15752 | cat >>confdefs.h <<\EOF |
| 15753 | #define const |
| 15754 | EOF |
| 15755 | |
| 15756 | fi |
| 15757 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15758 | echo "$as_me:15758: checking for inline" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15759 | echo $ECHO_N "checking for inline... $ECHO_C" >&6 |
| 15760 | if test "${ac_cv_c_inline+set}" = set; then |
| 15761 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15762 | else |
| 15763 | ac_cv_c_inline=no |
| 15764 | for ac_kw in inline __inline__ __inline; do |
| 15765 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15766 | #line 15766 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15767 | #include "confdefs.h" |
| 15768 | #ifndef __cplusplus |
| 15769 | static $ac_kw int static_foo () {return 0; } |
| 15770 | $ac_kw int foo () {return 0; } |
| 15771 | #endif |
| 15772 | |
| 15773 | _ACEOF |
| 15774 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15775 | if { (eval echo "$as_me:15775: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15776 | (eval $ac_compile) 2>&5 |
| 15777 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15778 | echo "$as_me:15778: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15779 | (exit $ac_status); } && |
| 15780 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15781 | { (eval echo "$as_me:15781: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15782 | (eval $ac_try) 2>&5 |
| 15783 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15784 | echo "$as_me:15784: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15785 | (exit $ac_status); }; }; then |
| 15786 | ac_cv_c_inline=$ac_kw; break |
| 15787 | else |
| 15788 | echo "$as_me: failed program was:" >&5 |
| 15789 | cat conftest.$ac_ext >&5 |
| 15790 | fi |
| 15791 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 15792 | done |
| 15793 | |
| 15794 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15795 | echo "$as_me:15795: result: $ac_cv_c_inline" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15796 | echo "${ECHO_T}$ac_cv_c_inline" >&6 |
| 15797 | case $ac_cv_c_inline in |
| 15798 | inline | yes) ;; |
| 15799 | no) |
| 15800 | cat >>confdefs.h <<\EOF |
| 15801 | #define inline |
| 15802 | EOF |
| 15803 | ;; |
| 15804 | *) cat >>confdefs.h <<EOF |
| 15805 | #define inline $ac_cv_c_inline |
| 15806 | EOF |
| 15807 | ;; |
| 15808 | esac |
| 15809 | |
| 15810 | NCURSES_INLINE= |
| 15811 | if test "$ac_cv_c_inline" != no ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15812 | NCURSES_INLINE=inline |
| 15813 | if test "$INTEL_COMPILER" = yes |
| 15814 | then |
| 15815 | : |
| 15816 | elif test "$CLANG_COMPILER" = yes |
| 15817 | then |
| 15818 | : |
| 15819 | elif test "$GCC" = yes |
| 15820 | then |
| 15821 | echo "$as_me:15821: checking if $CC supports options to tune inlining" >&5 |
| 15822 | echo $ECHO_N "checking if $CC supports options to tune inlining... $ECHO_C" >&6 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15823 | if test "${cf_cv_gcc_inline+set}" = set; then |
| 15824 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15825 | else |
| 15826 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15827 | cf_save_CFLAGS=$CFLAGS |
| 15828 | CFLAGS="$CFLAGS --param max-inline-insns-single=1200" |
| 15829 | cat >conftest.$ac_ext <<_ACEOF |
| 15830 | #line 15830 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15831 | #include "confdefs.h" |
| 15832 | inline int foo(void) { return 1; } |
| 15833 | int |
| 15834 | main () |
| 15835 | { |
| 15836 | ${cf_cv_main_return:-return} foo() |
| 15837 | ; |
| 15838 | return 0; |
| 15839 | } |
| 15840 | _ACEOF |
| 15841 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15842 | if { (eval echo "$as_me:15842: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15843 | (eval $ac_compile) 2>&5 |
| 15844 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15845 | echo "$as_me:15845: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15846 | (exit $ac_status); } && |
| 15847 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15848 | { (eval echo "$as_me:15848: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15849 | (eval $ac_try) 2>&5 |
| 15850 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15851 | echo "$as_me:15851: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15852 | (exit $ac_status); }; }; then |
| 15853 | cf_cv_gcc_inline=yes |
| 15854 | else |
| 15855 | echo "$as_me: failed program was:" >&5 |
| 15856 | cat conftest.$ac_ext >&5 |
| 15857 | cf_cv_gcc_inline=no |
| 15858 | fi |
| 15859 | rm -f conftest.$ac_objext conftest.$ac_ext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15860 | CFLAGS=$cf_save_CFLAGS |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15861 | |
| 15862 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15863 | echo "$as_me:15863: result: $cf_cv_gcc_inline" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15864 | echo "${ECHO_T}$cf_cv_gcc_inline" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15865 | if test "$cf_cv_gcc_inline" = yes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15866 | |
| 15867 | cf_fix_cppflags=no |
| 15868 | cf_new_cflags= |
| 15869 | cf_new_cppflags= |
| 15870 | cf_new_extra_cppflags= |
| 15871 | |
| 15872 | for cf_add_cflags in --param max-inline-insns-single=1200 |
| 15873 | do |
| 15874 | case $cf_fix_cppflags in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15875 | (no) |
| 15876 | case $cf_add_cflags in |
| 15877 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15878 | case $cf_add_cflags in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15879 | (-D*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15880 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 15881 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15882 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 15883 | && test -z "${cf_tst_cflags}" \ |
| 15884 | && cf_fix_cppflags=yes |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15885 | |
| 15886 | if test $cf_fix_cppflags = yes ; then |
| 15887 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 15888 | continue |
| 15889 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 15890 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 15891 | continue |
| 15892 | fi |
| 15893 | ;; |
| 15894 | esac |
| 15895 | case "$CPPFLAGS" in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15896 | (*$cf_add_cflags) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15897 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15898 | (*) |
| 15899 | case $cf_add_cflags in |
| 15900 | (-D*) |
| 15901 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 15902 | |
| 15903 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 15904 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 15905 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 15906 | |
| 15907 | ;; |
| 15908 | esac |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15909 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 15910 | ;; |
| 15911 | esac |
| 15912 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15913 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15914 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 15915 | ;; |
| 15916 | esac |
| 15917 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15918 | (yes) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15919 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 15920 | |
| 15921 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 15922 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15923 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 15924 | && test -z "${cf_tst_cflags}" \ |
| 15925 | && cf_fix_cppflags=no |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15926 | ;; |
| 15927 | esac |
| 15928 | done |
| 15929 | |
| 15930 | if test -n "$cf_new_cflags" ; then |
| 15931 | |
| 15932 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 15933 | fi |
| 15934 | |
| 15935 | if test -n "$cf_new_cppflags" ; then |
| 15936 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15937 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15938 | fi |
| 15939 | |
| 15940 | if test -n "$cf_new_extra_cppflags" ; then |
| 15941 | |
| 15942 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 15943 | fi |
| 15944 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15945 | fi |
| 15946 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15947 | fi |
| 15948 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15949 | echo "$as_me:15949: checking for signal global datatype" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15950 | echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6 |
| 15951 | if test "${cf_cv_sig_atomic_t+set}" = set; then |
| 15952 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 15953 | else |
| 15954 | |
| 15955 | for cf_type in \ |
| 15956 | "volatile sig_atomic_t" \ |
| 15957 | "sig_atomic_t" \ |
| 15958 | "int" |
| 15959 | do |
| 15960 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15961 | #line 15961 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15962 | #include "confdefs.h" |
| 15963 | |
| 15964 | #include <sys/types.h> |
| 15965 | #include <signal.h> |
| 15966 | #include <stdio.h> |
| 15967 | |
| 15968 | extern $cf_type x; |
| 15969 | $cf_type x; |
| 15970 | static void handler(int sig) |
| 15971 | { |
| 15972 | x = 5; |
| 15973 | } |
| 15974 | int |
| 15975 | main () |
| 15976 | { |
| 15977 | signal(SIGINT, handler); |
| 15978 | x = 1 |
| 15979 | ; |
| 15980 | return 0; |
| 15981 | } |
| 15982 | _ACEOF |
| 15983 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15984 | if { (eval echo "$as_me:15984: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15985 | (eval $ac_compile) 2>&5 |
| 15986 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15987 | echo "$as_me:15987: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15988 | (exit $ac_status); } && |
| 15989 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15990 | { (eval echo "$as_me:15990: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15991 | (eval $ac_try) 2>&5 |
| 15992 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 15993 | echo "$as_me:15993: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 15994 | (exit $ac_status); }; }; then |
| 15995 | cf_cv_sig_atomic_t=$cf_type |
| 15996 | else |
| 15997 | echo "$as_me: failed program was:" >&5 |
| 15998 | cat conftest.$ac_ext >&5 |
| 15999 | cf_cv_sig_atomic_t=no |
| 16000 | fi |
| 16001 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 16002 | test "$cf_cv_sig_atomic_t" != no && break |
| 16003 | done |
| 16004 | |
| 16005 | fi |
| 16006 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16007 | echo "$as_me:16007: result: $cf_cv_sig_atomic_t" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16008 | echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16009 | test "$cf_cv_sig_atomic_t" != no && |
| 16010 | cat >>confdefs.h <<EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16011 | #define SIG_ATOMIC_T $cf_cv_sig_atomic_t |
| 16012 | EOF |
| 16013 | |
| 16014 | if test $NCURSES_CHTYPE = auto ; then |
| 16015 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16016 | echo "$as_me:16016: checking for type of chtype" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16017 | echo $ECHO_N "checking for type of chtype... $ECHO_C" >&6 |
| 16018 | if test "${cf_cv_typeof_chtype+set}" = set; then |
| 16019 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16020 | else |
| 16021 | |
| 16022 | if test "$cross_compiling" = yes; then |
| 16023 | cf_cv_typeof_chtype=long |
| 16024 | else |
| 16025 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16026 | #line 16026 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16027 | #include "confdefs.h" |
| 16028 | |
| 16029 | #define WANT_BITS 31 |
| 16030 | #include <stdio.h> |
| 16031 | int main() |
| 16032 | { |
| 16033 | FILE *fp = fopen("cf_test.out", "w"); |
| 16034 | if (fp != 0) { |
| 16035 | char *result = "long"; |
| 16036 | if (sizeof(unsigned long) > sizeof(unsigned int)) { |
| 16037 | int n; |
| 16038 | unsigned int x, y; |
| 16039 | for (n = 0; n < WANT_BITS; n++) { |
| 16040 | x = (1 << n); |
| 16041 | y = (x >> n); |
| 16042 | if (y != 1 || x == 0) { |
| 16043 | x = 0; |
| 16044 | break; |
| 16045 | } |
| 16046 | } |
| 16047 | /* |
| 16048 | * If x is nonzero, an int is big enough for the bits |
| 16049 | * that we want. |
| 16050 | */ |
| 16051 | result = (x != 0) ? "int" : "long"; |
| 16052 | } |
| 16053 | fputs(result, fp); |
| 16054 | fclose(fp); |
| 16055 | } |
| 16056 | ${cf_cv_main_return:-return}(0); |
| 16057 | } |
| 16058 | |
| 16059 | _ACEOF |
| 16060 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16061 | if { (eval echo "$as_me:16061: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16062 | (eval $ac_link) 2>&5 |
| 16063 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16064 | echo "$as_me:16064: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16065 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16066 | { (eval echo "$as_me:16066: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16067 | (eval $ac_try) 2>&5 |
| 16068 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16069 | echo "$as_me:16069: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16070 | (exit $ac_status); }; }; then |
| 16071 | cf_cv_typeof_chtype=`cat cf_test.out` |
| 16072 | else |
| 16073 | echo "$as_me: program exited with status $ac_status" >&5 |
| 16074 | echo "$as_me: failed program was:" >&5 |
| 16075 | cat conftest.$ac_ext >&5 |
| 16076 | cf_cv_typeof_chtype=long |
| 16077 | fi |
| 16078 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 16079 | fi |
| 16080 | rm -f cf_test.out |
| 16081 | |
| 16082 | fi |
| 16083 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16084 | echo "$as_me:16084: result: $cf_cv_typeof_chtype" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16085 | echo "${ECHO_T}$cf_cv_typeof_chtype" >&6 |
| 16086 | |
| 16087 | cat >>confdefs.h <<EOF |
| 16088 | #define TYPEOF_CHTYPE $cf_cv_typeof_chtype |
| 16089 | EOF |
| 16090 | |
| 16091 | else |
| 16092 | cf_cv_typeof_chtype=$NCURSES_CHTYPE |
| 16093 | fi |
| 16094 | test "$cf_cv_typeof_chtype" = unsigned && cf_cv_typeof_chtype="" |
| 16095 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16096 | echo "$as_me:16096: checking if unsigned literals are legal" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16097 | echo $ECHO_N "checking if unsigned literals are legal... $ECHO_C" >&6 |
| 16098 | if test "${cf_cv_unsigned_literals+set}" = set; then |
| 16099 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16100 | else |
| 16101 | |
| 16102 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16103 | #line 16103 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16104 | #include "confdefs.h" |
| 16105 | |
| 16106 | int |
| 16107 | main () |
| 16108 | { |
| 16109 | long x = 1L + 1UL + 1U + 1 |
| 16110 | ; |
| 16111 | return 0; |
| 16112 | } |
| 16113 | _ACEOF |
| 16114 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16115 | if { (eval echo "$as_me:16115: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16116 | (eval $ac_compile) 2>&5 |
| 16117 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16118 | echo "$as_me:16118: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16119 | (exit $ac_status); } && |
| 16120 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16121 | { (eval echo "$as_me:16121: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16122 | (eval $ac_try) 2>&5 |
| 16123 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16124 | echo "$as_me:16124: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16125 | (exit $ac_status); }; }; then |
| 16126 | cf_cv_unsigned_literals=yes |
| 16127 | else |
| 16128 | echo "$as_me: failed program was:" >&5 |
| 16129 | cat conftest.$ac_ext >&5 |
| 16130 | cf_cv_unsigned_literals=no |
| 16131 | fi |
| 16132 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 16133 | |
| 16134 | fi |
| 16135 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16136 | echo "$as_me:16136: result: $cf_cv_unsigned_literals" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16137 | echo "${ECHO_T}$cf_cv_unsigned_literals" >&6 |
| 16138 | |
| 16139 | cf_cv_1UL="1" |
| 16140 | test ".$cf_cv_unsigned_literals" = .yes && cf_cv_1UL="${cf_cv_1UL}U" |
| 16141 | test ".$cf_cv_typeof_chtype" = .long && cf_cv_1UL="${cf_cv_1UL}L" |
| 16142 | |
| 16143 | if test $NCURSES_MMASK_T = auto ; then |
| 16144 | cf_cv_typeof_mmask_t=long |
| 16145 | else |
| 16146 | cf_cv_typeof_mmask_t=$NCURSES_MMASK_T |
| 16147 | fi |
| 16148 | test "$cf_cv_typeof_mmask_t" = unsigned && cf_cv_typeof_mmask_t="" |
| 16149 | |
| 16150 | ### Checks for external-data |
| 16151 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16152 | echo "$as_me:16152: checking if external errno is declared" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16153 | echo $ECHO_N "checking if external errno is declared... $ECHO_C" >&6 |
| 16154 | if test "${cf_cv_dcl_errno+set}" = set; then |
| 16155 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16156 | else |
| 16157 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16158 | cat >conftest.$ac_ext <<_ACEOF |
| 16159 | #line 16159 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16160 | #include "confdefs.h" |
| 16161 | |
| 16162 | #ifdef HAVE_STDLIB_H |
| 16163 | #include <stdlib.h> |
| 16164 | #endif |
| 16165 | #include <stdio.h> |
| 16166 | #include <sys/types.h> |
| 16167 | #include <errno.h> |
| 16168 | int |
| 16169 | main () |
| 16170 | { |
| 16171 | int x = (int) errno |
| 16172 | ; |
| 16173 | return 0; |
| 16174 | } |
| 16175 | _ACEOF |
| 16176 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16177 | if { (eval echo "$as_me:16177: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16178 | (eval $ac_compile) 2>&5 |
| 16179 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16180 | echo "$as_me:16180: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16181 | (exit $ac_status); } && |
| 16182 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16183 | { (eval echo "$as_me:16183: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16184 | (eval $ac_try) 2>&5 |
| 16185 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16186 | echo "$as_me:16186: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16187 | (exit $ac_status); }; }; then |
| 16188 | cf_cv_dcl_errno=yes |
| 16189 | else |
| 16190 | echo "$as_me: failed program was:" >&5 |
| 16191 | cat conftest.$ac_ext >&5 |
| 16192 | cf_cv_dcl_errno=no |
| 16193 | fi |
| 16194 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 16195 | |
| 16196 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16197 | echo "$as_me:16197: result: $cf_cv_dcl_errno" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16198 | echo "${ECHO_T}$cf_cv_dcl_errno" >&6 |
| 16199 | |
| 16200 | if test "$cf_cv_dcl_errno" = no ; then |
| 16201 | |
| 16202 | cf_result=`echo "decl_errno" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 16203 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16204 | cat >>confdefs.h <<EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16205 | #define $cf_result 1 |
| 16206 | EOF |
| 16207 | |
| 16208 | fi |
| 16209 | |
| 16210 | # It's possible (for near-UNIX clones) that the data doesn't exist |
| 16211 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16212 | echo "$as_me:16212: checking if external errno exists" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16213 | echo $ECHO_N "checking if external errno exists... $ECHO_C" >&6 |
| 16214 | if test "${cf_cv_have_errno+set}" = set; then |
| 16215 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16216 | else |
| 16217 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16218 | cat >conftest.$ac_ext <<_ACEOF |
| 16219 | #line 16219 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16220 | #include "confdefs.h" |
| 16221 | |
| 16222 | #undef errno |
| 16223 | extern int errno; |
| 16224 | |
| 16225 | int |
| 16226 | main () |
| 16227 | { |
| 16228 | errno = 2 |
| 16229 | ; |
| 16230 | return 0; |
| 16231 | } |
| 16232 | _ACEOF |
| 16233 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16234 | if { (eval echo "$as_me:16234: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16235 | (eval $ac_link) 2>&5 |
| 16236 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16237 | echo "$as_me:16237: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16238 | (exit $ac_status); } && |
| 16239 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16240 | { (eval echo "$as_me:16240: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16241 | (eval $ac_try) 2>&5 |
| 16242 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16243 | echo "$as_me:16243: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16244 | (exit $ac_status); }; }; then |
| 16245 | cf_cv_have_errno=yes |
| 16246 | else |
| 16247 | echo "$as_me: failed program was:" >&5 |
| 16248 | cat conftest.$ac_ext >&5 |
| 16249 | cf_cv_have_errno=no |
| 16250 | fi |
| 16251 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 16252 | |
| 16253 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16254 | echo "$as_me:16254: result: $cf_cv_have_errno" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16255 | echo "${ECHO_T}$cf_cv_have_errno" >&6 |
| 16256 | |
| 16257 | if test "$cf_cv_have_errno" = yes ; then |
| 16258 | |
| 16259 | cf_result=`echo "have_errno" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 16260 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16261 | cat >>confdefs.h <<EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16262 | #define $cf_result 1 |
| 16263 | EOF |
| 16264 | |
| 16265 | fi |
| 16266 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16267 | echo "$as_me:16267: checking if data-only library module links" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16268 | echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6 |
| 16269 | if test "${cf_cv_link_dataonly+set}" = set; then |
| 16270 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16271 | else |
| 16272 | |
| 16273 | rm -f conftest.a |
| 16274 | cat >conftest.$ac_ext <<EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16275 | #line 16275 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16276 | int testdata[3] = { 123, 456, 789 }; |
| 16277 | EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16278 | if { (eval echo "$as_me:16278: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16279 | (eval $ac_compile) 2>&5 |
| 16280 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16281 | echo "$as_me:16281: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16282 | (exit $ac_status); } ; then |
| 16283 | mv conftest.o data.o && \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16284 | ( $AR $ARFLAGS conftest.a data.o ) 2>&5 1>/dev/null |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16285 | fi |
| 16286 | rm -f conftest.$ac_ext data.o |
| 16287 | cat >conftest.$ac_ext <<EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16288 | #line 16288 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16289 | int testfunc() |
| 16290 | { |
| 16291 | #if defined(NeXT) |
| 16292 | ${cf_cv_main_return:-return}(1); /* I'm told this linker is broken */ |
| 16293 | #else |
| 16294 | extern int testdata[3]; |
| 16295 | return testdata[0] == 123 |
| 16296 | && testdata[1] == 456 |
| 16297 | && testdata[2] == 789; |
| 16298 | #endif |
| 16299 | } |
| 16300 | EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16301 | if { (eval echo "$as_me:16301: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16302 | (eval $ac_compile) 2>&5 |
| 16303 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16304 | echo "$as_me:16304: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16305 | (exit $ac_status); }; then |
| 16306 | mv conftest.o func.o && \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16307 | ( $AR $ARFLAGS conftest.a func.o ) 2>&5 1>/dev/null |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16308 | fi |
| 16309 | rm -f conftest.$ac_ext func.o |
| 16310 | ( eval $RANLIB conftest.a ) 2>&5 >/dev/null |
| 16311 | cf_saveLIBS="$LIBS" |
| 16312 | LIBS="conftest.a $LIBS" |
| 16313 | if test "$cross_compiling" = yes; then |
| 16314 | cf_cv_link_dataonly=unknown |
| 16315 | else |
| 16316 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16317 | #line 16317 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16318 | #include "confdefs.h" |
| 16319 | |
| 16320 | int main() |
| 16321 | { |
| 16322 | extern int testfunc(); |
| 16323 | ${cf_cv_main_return:-return} (!testfunc()); |
| 16324 | } |
| 16325 | |
| 16326 | _ACEOF |
| 16327 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16328 | if { (eval echo "$as_me:16328: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16329 | (eval $ac_link) 2>&5 |
| 16330 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16331 | echo "$as_me:16331: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16332 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16333 | { (eval echo "$as_me:16333: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16334 | (eval $ac_try) 2>&5 |
| 16335 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16336 | echo "$as_me:16336: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16337 | (exit $ac_status); }; }; then |
| 16338 | cf_cv_link_dataonly=yes |
| 16339 | else |
| 16340 | echo "$as_me: program exited with status $ac_status" >&5 |
| 16341 | echo "$as_me: failed program was:" >&5 |
| 16342 | cat conftest.$ac_ext >&5 |
| 16343 | cf_cv_link_dataonly=no |
| 16344 | fi |
| 16345 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 16346 | fi |
| 16347 | LIBS="$cf_saveLIBS" |
| 16348 | |
| 16349 | fi |
| 16350 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16351 | echo "$as_me:16351: result: $cf_cv_link_dataonly" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16352 | echo "${ECHO_T}$cf_cv_link_dataonly" >&6 |
| 16353 | |
| 16354 | if test "$cf_cv_link_dataonly" = no ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16355 | |
| 16356 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16357 | #define BROKEN_LINKER 1 |
| 16358 | EOF |
| 16359 | |
| 16360 | BROKEN_LINKER=1 |
| 16361 | fi |
| 16362 | |
| 16363 | ### Checks for library functions. |
| 16364 | |
| 16365 | for ac_func in \ |
| 16366 | getcwd \ |
| 16367 | getegid \ |
| 16368 | geteuid \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16369 | getopt \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16370 | getttynam \ |
| 16371 | issetugid \ |
| 16372 | poll \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16373 | putenv \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16374 | remove \ |
| 16375 | select \ |
| 16376 | setbuf \ |
| 16377 | setbuffer \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16378 | setenv \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16379 | setvbuf \ |
| 16380 | sigaction \ |
| 16381 | sigvec \ |
| 16382 | strdup \ |
| 16383 | strstr \ |
| 16384 | tcgetpgrp \ |
| 16385 | times \ |
| 16386 | vsnprintf \ |
| 16387 | |
| 16388 | do |
| 16389 | as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16390 | echo "$as_me:16390: checking for $ac_func" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16391 | echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 |
| 16392 | if eval "test \"\${$as_ac_var+set}\" = set"; then |
| 16393 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16394 | else |
| 16395 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16396 | #line 16396 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16397 | #include "confdefs.h" |
| 16398 | /* System header to define __stub macros and hopefully few prototypes, |
| 16399 | which can conflict with char $ac_func (); below. */ |
| 16400 | #include <assert.h> |
| 16401 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 16402 | #ifdef __cplusplus |
| 16403 | extern "C" |
| 16404 | #endif |
| 16405 | /* We use char because int might match the return type of a gcc2 |
| 16406 | builtin and then its argument prototype would still apply. */ |
| 16407 | char $ac_func (); |
| 16408 | char (*f) (); |
| 16409 | |
| 16410 | int |
| 16411 | main () |
| 16412 | { |
| 16413 | /* The GNU C library defines this for functions which it implements |
| 16414 | to always fail with ENOSYS. Some functions are actually named |
| 16415 | something starting with __ and the normal name is an alias. */ |
| 16416 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 16417 | choke me |
| 16418 | #else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16419 | f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16420 | #endif |
| 16421 | |
| 16422 | ; |
| 16423 | return 0; |
| 16424 | } |
| 16425 | _ACEOF |
| 16426 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16427 | if { (eval echo "$as_me:16427: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16428 | (eval $ac_link) 2>&5 |
| 16429 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16430 | echo "$as_me:16430: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16431 | (exit $ac_status); } && |
| 16432 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16433 | { (eval echo "$as_me:16433: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16434 | (eval $ac_try) 2>&5 |
| 16435 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16436 | echo "$as_me:16436: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16437 | (exit $ac_status); }; }; then |
| 16438 | eval "$as_ac_var=yes" |
| 16439 | else |
| 16440 | echo "$as_me: failed program was:" >&5 |
| 16441 | cat conftest.$ac_ext >&5 |
| 16442 | eval "$as_ac_var=no" |
| 16443 | fi |
| 16444 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 16445 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16446 | echo "$as_me:16446: result: `eval echo '${'$as_ac_var'}'`" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16447 | echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 |
| 16448 | if test `eval echo '${'$as_ac_var'}'` = yes; then |
| 16449 | cat >>confdefs.h <<EOF |
| 16450 | #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 16451 | EOF |
| 16452 | |
| 16453 | fi |
| 16454 | done |
| 16455 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16456 | if test "x$ac_cv_func_getopt" = xno && |
| 16457 | test "x$cf_with_progs$cf_with_tests" != xnono; then |
| 16458 | { { echo "$as_me:16458: error: getopt is required for building programs" >&5 |
| 16459 | echo "$as_me: error: getopt is required for building programs" >&2;} |
| 16460 | { (exit 1); exit 1; }; } |
| 16461 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16462 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16463 | if test "x$with_getcap" = "xyes" ; then |
| 16464 | |
| 16465 | echo "$as_me:16465: checking for terminal-capability database functions" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16466 | echo $ECHO_N "checking for terminal-capability database functions... $ECHO_C" >&6 |
| 16467 | if test "${cf_cv_cgetent+set}" = set; then |
| 16468 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16469 | else |
| 16470 | |
| 16471 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16472 | #line 16472 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16473 | #include "confdefs.h" |
| 16474 | |
| 16475 | #include <stdlib.h> |
| 16476 | int |
| 16477 | main () |
| 16478 | { |
| 16479 | |
| 16480 | char temp[128]; |
| 16481 | char *buf = temp; |
| 16482 | char *db_array = temp; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16483 | cgetent(&buf, &db_array, "vt100"); |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16484 | cgetcap(buf, "tc", '='); |
| 16485 | cgetmatch(buf, "tc"); |
| 16486 | |
| 16487 | ; |
| 16488 | return 0; |
| 16489 | } |
| 16490 | _ACEOF |
| 16491 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16492 | if { (eval echo "$as_me:16492: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16493 | (eval $ac_link) 2>&5 |
| 16494 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16495 | echo "$as_me:16495: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16496 | (exit $ac_status); } && |
| 16497 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16498 | { (eval echo "$as_me:16498: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16499 | (eval $ac_try) 2>&5 |
| 16500 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16501 | echo "$as_me:16501: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16502 | (exit $ac_status); }; }; then |
| 16503 | cf_cv_cgetent=yes |
| 16504 | else |
| 16505 | echo "$as_me: failed program was:" >&5 |
| 16506 | cat conftest.$ac_ext >&5 |
| 16507 | cf_cv_cgetent=no |
| 16508 | fi |
| 16509 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 16510 | |
| 16511 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16512 | echo "$as_me:16512: result: $cf_cv_cgetent" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16513 | echo "${ECHO_T}$cf_cv_cgetent" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16514 | |
| 16515 | if test "$cf_cv_cgetent" = yes |
| 16516 | then |
| 16517 | |
| 16518 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16519 | #define HAVE_BSD_CGETENT 1 |
| 16520 | EOF |
| 16521 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16522 | echo "$as_me:16522: checking if cgetent uses const parameter" >&5 |
| 16523 | echo $ECHO_N "checking if cgetent uses const parameter... $ECHO_C" >&6 |
| 16524 | if test "${cf_cv_cgetent_const+set}" = set; then |
| 16525 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16526 | else |
| 16527 | |
| 16528 | cat >conftest.$ac_ext <<_ACEOF |
| 16529 | #line 16529 "configure" |
| 16530 | #include "confdefs.h" |
| 16531 | |
| 16532 | #include <stdlib.h> |
| 16533 | int |
| 16534 | main () |
| 16535 | { |
| 16536 | |
| 16537 | char temp[128]; |
| 16538 | char *buf = temp; |
| 16539 | #ifndef _NETBSD_SOURCE /* given, since April 2004 in stdlib.h */ |
| 16540 | const char *db_array = temp; |
| 16541 | cgetent(&buf, &db_array, "vt100"); |
| 16542 | #endif |
| 16543 | cgetcap(buf, "tc", '='); |
| 16544 | cgetmatch(buf, "tc"); |
| 16545 | |
| 16546 | ; |
| 16547 | return 0; |
| 16548 | } |
| 16549 | _ACEOF |
| 16550 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 16551 | if { (eval echo "$as_me:16551: \"$ac_link\"") >&5 |
| 16552 | (eval $ac_link) 2>&5 |
| 16553 | ac_status=$? |
| 16554 | echo "$as_me:16554: \$? = $ac_status" >&5 |
| 16555 | (exit $ac_status); } && |
| 16556 | { ac_try='test -s conftest$ac_exeext' |
| 16557 | { (eval echo "$as_me:16557: \"$ac_try\"") >&5 |
| 16558 | (eval $ac_try) 2>&5 |
| 16559 | ac_status=$? |
| 16560 | echo "$as_me:16560: \$? = $ac_status" >&5 |
| 16561 | (exit $ac_status); }; }; then |
| 16562 | cf_cv_cgetent_const=yes |
| 16563 | else |
| 16564 | echo "$as_me: failed program was:" >&5 |
| 16565 | cat conftest.$ac_ext >&5 |
| 16566 | cf_cv_cgetent_const=no |
| 16567 | fi |
| 16568 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 16569 | |
| 16570 | fi |
| 16571 | echo "$as_me:16571: result: $cf_cv_cgetent_const" >&5 |
| 16572 | echo "${ECHO_T}$cf_cv_cgetent_const" >&6 |
| 16573 | if test "$cf_cv_cgetent_const" = yes |
| 16574 | then |
| 16575 | |
| 16576 | cat >>confdefs.h <<EOF |
| 16577 | #define CGETENT_CONST const |
| 16578 | EOF |
| 16579 | |
| 16580 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16581 | fi |
| 16582 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16583 | fi |
| 16584 | |
| 16585 | echo "$as_me:16585: checking for isascii" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16586 | echo $ECHO_N "checking for isascii... $ECHO_C" >&6 |
| 16587 | if test "${cf_cv_have_isascii+set}" = set; then |
| 16588 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16589 | else |
| 16590 | |
| 16591 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16592 | #line 16592 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16593 | #include "confdefs.h" |
| 16594 | #include <ctype.h> |
| 16595 | int |
| 16596 | main () |
| 16597 | { |
| 16598 | int x = isascii(' ') |
| 16599 | ; |
| 16600 | return 0; |
| 16601 | } |
| 16602 | _ACEOF |
| 16603 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16604 | if { (eval echo "$as_me:16604: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16605 | (eval $ac_link) 2>&5 |
| 16606 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16607 | echo "$as_me:16607: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16608 | (exit $ac_status); } && |
| 16609 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16610 | { (eval echo "$as_me:16610: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16611 | (eval $ac_try) 2>&5 |
| 16612 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16613 | echo "$as_me:16613: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16614 | (exit $ac_status); }; }; then |
| 16615 | cf_cv_have_isascii=yes |
| 16616 | else |
| 16617 | echo "$as_me: failed program was:" >&5 |
| 16618 | cat conftest.$ac_ext >&5 |
| 16619 | cf_cv_have_isascii=no |
| 16620 | fi |
| 16621 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 16622 | |
| 16623 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16624 | echo "$as_me:16624: result: $cf_cv_have_isascii" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16625 | echo "${ECHO_T}$cf_cv_have_isascii" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16626 | test "$cf_cv_have_isascii" = yes && |
| 16627 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16628 | #define HAVE_ISASCII 1 |
| 16629 | EOF |
| 16630 | |
| 16631 | if test "$ac_cv_func_sigaction" = yes; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16632 | echo "$as_me:16632: checking whether sigaction needs _POSIX_SOURCE" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16633 | echo $ECHO_N "checking whether sigaction needs _POSIX_SOURCE... $ECHO_C" >&6 |
| 16634 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16635 | #line 16635 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16636 | #include "confdefs.h" |
| 16637 | |
| 16638 | #include <sys/types.h> |
| 16639 | #include <signal.h> |
| 16640 | int |
| 16641 | main () |
| 16642 | { |
| 16643 | struct sigaction act |
| 16644 | ; |
| 16645 | return 0; |
| 16646 | } |
| 16647 | _ACEOF |
| 16648 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16649 | if { (eval echo "$as_me:16649: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16650 | (eval $ac_compile) 2>&5 |
| 16651 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16652 | echo "$as_me:16652: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16653 | (exit $ac_status); } && |
| 16654 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16655 | { (eval echo "$as_me:16655: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16656 | (eval $ac_try) 2>&5 |
| 16657 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16658 | echo "$as_me:16658: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16659 | (exit $ac_status); }; }; then |
| 16660 | sigact_bad=no |
| 16661 | else |
| 16662 | echo "$as_me: failed program was:" >&5 |
| 16663 | cat conftest.$ac_ext >&5 |
| 16664 | |
| 16665 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16666 | #line 16666 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16667 | #include "confdefs.h" |
| 16668 | |
| 16669 | #define _POSIX_SOURCE |
| 16670 | #include <sys/types.h> |
| 16671 | #include <signal.h> |
| 16672 | int |
| 16673 | main () |
| 16674 | { |
| 16675 | struct sigaction act |
| 16676 | ; |
| 16677 | return 0; |
| 16678 | } |
| 16679 | _ACEOF |
| 16680 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16681 | if { (eval echo "$as_me:16681: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16682 | (eval $ac_compile) 2>&5 |
| 16683 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16684 | echo "$as_me:16684: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16685 | (exit $ac_status); } && |
| 16686 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16687 | { (eval echo "$as_me:16687: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16688 | (eval $ac_try) 2>&5 |
| 16689 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16690 | echo "$as_me:16690: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16691 | (exit $ac_status); }; }; then |
| 16692 | sigact_bad=yes |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16693 | |
| 16694 | cat >>confdefs.h <<\EOF |
| 16695 | #define _POSIX_SOURCE 1 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16696 | EOF |
| 16697 | |
| 16698 | else |
| 16699 | echo "$as_me: failed program was:" >&5 |
| 16700 | cat conftest.$ac_ext >&5 |
| 16701 | sigact_bad=unknown |
| 16702 | fi |
| 16703 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 16704 | fi |
| 16705 | rm -f conftest.$ac_objext conftest.$ac_ext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16706 | echo "$as_me:16706: result: $sigact_bad" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16707 | echo "${ECHO_T}$sigact_bad" >&6 |
| 16708 | fi |
| 16709 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16710 | echo "$as_me:16710: checking if nanosleep really works" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16711 | echo $ECHO_N "checking if nanosleep really works... $ECHO_C" >&6 |
| 16712 | if test "${cf_cv_func_nanosleep+set}" = set; then |
| 16713 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16714 | else |
| 16715 | |
| 16716 | if test "$cross_compiling" = yes; then |
| 16717 | cf_cv_func_nanosleep=unknown |
| 16718 | else |
| 16719 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16720 | #line 16720 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16721 | #include "confdefs.h" |
| 16722 | |
| 16723 | #include <stdio.h> |
| 16724 | #include <errno.h> |
| 16725 | #include <time.h> |
| 16726 | |
| 16727 | #ifdef HAVE_SYS_TIME_H |
| 16728 | #include <sys/time.h> |
| 16729 | #endif |
| 16730 | |
| 16731 | int main() { |
| 16732 | struct timespec ts1, ts2; |
| 16733 | int code; |
| 16734 | ts1.tv_sec = 0; |
| 16735 | ts1.tv_nsec = 750000000; |
| 16736 | ts2.tv_sec = 0; |
| 16737 | ts2.tv_nsec = 0; |
| 16738 | errno = 0; |
| 16739 | code = nanosleep(&ts1, &ts2); /* on failure errno is ENOSYS. */ |
| 16740 | ${cf_cv_main_return:-return}(code != 0); |
| 16741 | } |
| 16742 | |
| 16743 | _ACEOF |
| 16744 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16745 | if { (eval echo "$as_me:16745: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16746 | (eval $ac_link) 2>&5 |
| 16747 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16748 | echo "$as_me:16748: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16749 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16750 | { (eval echo "$as_me:16750: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16751 | (eval $ac_try) 2>&5 |
| 16752 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16753 | echo "$as_me:16753: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16754 | (exit $ac_status); }; }; then |
| 16755 | cf_cv_func_nanosleep=yes |
| 16756 | else |
| 16757 | echo "$as_me: program exited with status $ac_status" >&5 |
| 16758 | echo "$as_me: failed program was:" >&5 |
| 16759 | cat conftest.$ac_ext >&5 |
| 16760 | cf_cv_func_nanosleep=no |
| 16761 | fi |
| 16762 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 16763 | fi |
| 16764 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16765 | echo "$as_me:16765: result: $cf_cv_func_nanosleep" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16766 | echo "${ECHO_T}$cf_cv_func_nanosleep" >&6 |
| 16767 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16768 | test "$cf_cv_func_nanosleep" = "yes" && |
| 16769 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16770 | #define HAVE_NANOSLEEP 1 |
| 16771 | EOF |
| 16772 | |
| 16773 | for ac_header in \ |
| 16774 | termio.h \ |
| 16775 | termios.h \ |
| 16776 | unistd.h \ |
| 16777 | |
| 16778 | do |
| 16779 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16780 | echo "$as_me:16780: checking for $ac_header" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16781 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 16782 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 16783 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16784 | else |
| 16785 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16786 | #line 16786 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16787 | #include "confdefs.h" |
| 16788 | #include <$ac_header> |
| 16789 | _ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16790 | if { (eval echo "$as_me:16790: \"$ac_cpp conftest.$ac_ext\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16791 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 16792 | ac_status=$? |
| 16793 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 16794 | rm -f conftest.er1 |
| 16795 | cat conftest.err >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16796 | echo "$as_me:16796: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16797 | (exit $ac_status); } >/dev/null; then |
| 16798 | if test -s conftest.err; then |
| 16799 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 16800 | else |
| 16801 | ac_cpp_err= |
| 16802 | fi |
| 16803 | else |
| 16804 | ac_cpp_err=yes |
| 16805 | fi |
| 16806 | if test -z "$ac_cpp_err"; then |
| 16807 | eval "$as_ac_Header=yes" |
| 16808 | else |
| 16809 | echo "$as_me: failed program was:" >&5 |
| 16810 | cat conftest.$ac_ext >&5 |
| 16811 | eval "$as_ac_Header=no" |
| 16812 | fi |
| 16813 | rm -f conftest.err conftest.$ac_ext |
| 16814 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16815 | echo "$as_me:16815: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16816 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 16817 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 16818 | cat >>confdefs.h <<EOF |
| 16819 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 16820 | EOF |
| 16821 | |
| 16822 | fi |
| 16823 | done |
| 16824 | |
| 16825 | if test "$ISC" = yes ; then |
| 16826 | |
| 16827 | for ac_header in sys/termio.h |
| 16828 | do |
| 16829 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16830 | echo "$as_me:16830: checking for $ac_header" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16831 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 16832 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 16833 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16834 | else |
| 16835 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16836 | #line 16836 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16837 | #include "confdefs.h" |
| 16838 | #include <$ac_header> |
| 16839 | _ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16840 | if { (eval echo "$as_me:16840: \"$ac_cpp conftest.$ac_ext\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16841 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 16842 | ac_status=$? |
| 16843 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 16844 | rm -f conftest.er1 |
| 16845 | cat conftest.err >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16846 | echo "$as_me:16846: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16847 | (exit $ac_status); } >/dev/null; then |
| 16848 | if test -s conftest.err; then |
| 16849 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 16850 | else |
| 16851 | ac_cpp_err= |
| 16852 | fi |
| 16853 | else |
| 16854 | ac_cpp_err=yes |
| 16855 | fi |
| 16856 | if test -z "$ac_cpp_err"; then |
| 16857 | eval "$as_ac_Header=yes" |
| 16858 | else |
| 16859 | echo "$as_me: failed program was:" >&5 |
| 16860 | cat conftest.$ac_ext >&5 |
| 16861 | eval "$as_ac_Header=no" |
| 16862 | fi |
| 16863 | rm -f conftest.err conftest.$ac_ext |
| 16864 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16865 | echo "$as_me:16865: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16866 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 16867 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 16868 | cat >>confdefs.h <<EOF |
| 16869 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 16870 | EOF |
| 16871 | |
| 16872 | fi |
| 16873 | done |
| 16874 | |
| 16875 | fi |
| 16876 | if test "$ac_cv_header_termios_h" = yes ; then |
| 16877 | case "$CFLAGS $CPPFLAGS" in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16878 | (*-D_POSIX_SOURCE*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16879 | termios_bad=dunno ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16880 | (*) termios_bad=maybe ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16881 | esac |
| 16882 | if test "$termios_bad" = maybe ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16883 | echo "$as_me:16883: checking whether termios.h needs _POSIX_SOURCE" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16884 | echo $ECHO_N "checking whether termios.h needs _POSIX_SOURCE... $ECHO_C" >&6 |
| 16885 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16886 | #line 16886 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16887 | #include "confdefs.h" |
| 16888 | #include <termios.h> |
| 16889 | int |
| 16890 | main () |
| 16891 | { |
| 16892 | struct termios foo; int x = foo.c_iflag |
| 16893 | ; |
| 16894 | return 0; |
| 16895 | } |
| 16896 | _ACEOF |
| 16897 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16898 | if { (eval echo "$as_me:16898: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16899 | (eval $ac_compile) 2>&5 |
| 16900 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16901 | echo "$as_me:16901: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16902 | (exit $ac_status); } && |
| 16903 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16904 | { (eval echo "$as_me:16904: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16905 | (eval $ac_try) 2>&5 |
| 16906 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16907 | echo "$as_me:16907: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16908 | (exit $ac_status); }; }; then |
| 16909 | termios_bad=no |
| 16910 | else |
| 16911 | echo "$as_me: failed program was:" >&5 |
| 16912 | cat conftest.$ac_ext >&5 |
| 16913 | |
| 16914 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16915 | #line 16915 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16916 | #include "confdefs.h" |
| 16917 | |
| 16918 | #define _POSIX_SOURCE |
| 16919 | #include <termios.h> |
| 16920 | int |
| 16921 | main () |
| 16922 | { |
| 16923 | struct termios foo; int x = foo.c_iflag |
| 16924 | ; |
| 16925 | return 0; |
| 16926 | } |
| 16927 | _ACEOF |
| 16928 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16929 | if { (eval echo "$as_me:16929: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16930 | (eval $ac_compile) 2>&5 |
| 16931 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16932 | echo "$as_me:16932: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16933 | (exit $ac_status); } && |
| 16934 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16935 | { (eval echo "$as_me:16935: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16936 | (eval $ac_try) 2>&5 |
| 16937 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16938 | echo "$as_me:16938: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16939 | (exit $ac_status); }; }; then |
| 16940 | termios_bad=unknown |
| 16941 | else |
| 16942 | echo "$as_me: failed program was:" >&5 |
| 16943 | cat conftest.$ac_ext >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16944 | termios_bad=yes |
| 16945 | cat >>confdefs.h <<\EOF |
| 16946 | #define _POSIX_SOURCE 1 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16947 | EOF |
| 16948 | |
| 16949 | fi |
| 16950 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 16951 | |
| 16952 | fi |
| 16953 | rm -f conftest.$ac_objext conftest.$ac_ext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16954 | echo "$as_me:16954: result: $termios_bad" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16955 | echo "${ECHO_T}$termios_bad" >&6 |
| 16956 | fi |
| 16957 | fi |
| 16958 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16959 | echo "$as_me:16959: checking for tcgetattr" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16960 | echo $ECHO_N "checking for tcgetattr... $ECHO_C" >&6 |
| 16961 | if test "${cf_cv_have_tcgetattr+set}" = set; then |
| 16962 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 16963 | else |
| 16964 | |
| 16965 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16966 | #line 16966 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16967 | #include "confdefs.h" |
| 16968 | |
| 16969 | #include <sys/types.h> |
| 16970 | #ifdef HAVE_UNISTD_H |
| 16971 | #include <unistd.h> |
| 16972 | #endif |
| 16973 | #ifdef HAVE_TERMIOS_H |
| 16974 | #include <termios.h> |
| 16975 | #define TTY struct termios |
| 16976 | #else |
| 16977 | #ifdef HAVE_TERMIO_H |
| 16978 | #include <termio.h> |
| 16979 | #define TTY struct termio |
| 16980 | #endif |
| 16981 | #endif |
| 16982 | |
| 16983 | int |
| 16984 | main () |
| 16985 | { |
| 16986 | |
| 16987 | TTY foo; |
| 16988 | tcgetattr(1, &foo); |
| 16989 | ; |
| 16990 | return 0; |
| 16991 | } |
| 16992 | _ACEOF |
| 16993 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16994 | if { (eval echo "$as_me:16994: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16995 | (eval $ac_link) 2>&5 |
| 16996 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 16997 | echo "$as_me:16997: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 16998 | (exit $ac_status); } && |
| 16999 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17000 | { (eval echo "$as_me:17000: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17001 | (eval $ac_try) 2>&5 |
| 17002 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17003 | echo "$as_me:17003: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17004 | (exit $ac_status); }; }; then |
| 17005 | cf_cv_have_tcgetattr=yes |
| 17006 | else |
| 17007 | echo "$as_me: failed program was:" >&5 |
| 17008 | cat conftest.$ac_ext >&5 |
| 17009 | cf_cv_have_tcgetattr=no |
| 17010 | fi |
| 17011 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17012 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17013 | echo "$as_me:17013: result: $cf_cv_have_tcgetattr" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17014 | echo "${ECHO_T}$cf_cv_have_tcgetattr" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17015 | test "$cf_cv_have_tcgetattr" = yes && |
| 17016 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17017 | #define HAVE_TCGETATTR 1 |
| 17018 | EOF |
| 17019 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17020 | echo "$as_me:17020: checking for vsscanf function or workaround" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17021 | echo $ECHO_N "checking for vsscanf function or workaround... $ECHO_C" >&6 |
| 17022 | if test "${cf_cv_func_vsscanf+set}" = set; then |
| 17023 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17024 | else |
| 17025 | |
| 17026 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17027 | #line 17027 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17028 | #include "confdefs.h" |
| 17029 | |
| 17030 | #include <stdarg.h> |
| 17031 | #include <stdio.h> |
| 17032 | int |
| 17033 | main () |
| 17034 | { |
| 17035 | |
| 17036 | va_list ap; |
| 17037 | vsscanf("from", "%d", ap) |
| 17038 | ; |
| 17039 | return 0; |
| 17040 | } |
| 17041 | _ACEOF |
| 17042 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17043 | if { (eval echo "$as_me:17043: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17044 | (eval $ac_link) 2>&5 |
| 17045 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17046 | echo "$as_me:17046: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17047 | (exit $ac_status); } && |
| 17048 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17049 | { (eval echo "$as_me:17049: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17050 | (eval $ac_try) 2>&5 |
| 17051 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17052 | echo "$as_me:17052: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17053 | (exit $ac_status); }; }; then |
| 17054 | cf_cv_func_vsscanf=vsscanf |
| 17055 | else |
| 17056 | echo "$as_me: failed program was:" >&5 |
| 17057 | cat conftest.$ac_ext >&5 |
| 17058 | |
| 17059 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17060 | #line 17060 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17061 | #include "confdefs.h" |
| 17062 | |
| 17063 | #include <stdarg.h> |
| 17064 | #include <stdio.h> |
| 17065 | int |
| 17066 | main () |
| 17067 | { |
| 17068 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17069 | FILE strbuf; |
| 17070 | char *str = "from"; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17071 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17072 | strbuf._flag = _IOREAD; |
| 17073 | strbuf._ptr = strbuf._base = (unsigned char *) str; |
| 17074 | strbuf._cnt = strlen(str); |
| 17075 | strbuf._file = _NFILE; |
| 17076 | return (vfscanf(&strbuf, "%d", ap)) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17077 | ; |
| 17078 | return 0; |
| 17079 | } |
| 17080 | _ACEOF |
| 17081 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17082 | if { (eval echo "$as_me:17082: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17083 | (eval $ac_link) 2>&5 |
| 17084 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17085 | echo "$as_me:17085: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17086 | (exit $ac_status); } && |
| 17087 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17088 | { (eval echo "$as_me:17088: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17089 | (eval $ac_try) 2>&5 |
| 17090 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17091 | echo "$as_me:17091: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17092 | (exit $ac_status); }; }; then |
| 17093 | cf_cv_func_vsscanf=vfscanf |
| 17094 | else |
| 17095 | echo "$as_me: failed program was:" >&5 |
| 17096 | cat conftest.$ac_ext >&5 |
| 17097 | |
| 17098 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17099 | #line 17099 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17100 | #include "confdefs.h" |
| 17101 | |
| 17102 | #include <stdarg.h> |
| 17103 | #include <stdio.h> |
| 17104 | int |
| 17105 | main () |
| 17106 | { |
| 17107 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17108 | FILE strbuf; |
| 17109 | char *str = "from"; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17110 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17111 | strbuf._flag = _IOREAD; |
| 17112 | strbuf._ptr = strbuf._base = (unsigned char *) str; |
| 17113 | strbuf._cnt = strlen(str); |
| 17114 | strbuf._file = _NFILE; |
| 17115 | return (_doscan(&strbuf, "%d", ap)) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17116 | ; |
| 17117 | return 0; |
| 17118 | } |
| 17119 | _ACEOF |
| 17120 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17121 | if { (eval echo "$as_me:17121: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17122 | (eval $ac_link) 2>&5 |
| 17123 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17124 | echo "$as_me:17124: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17125 | (exit $ac_status); } && |
| 17126 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17127 | { (eval echo "$as_me:17127: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17128 | (eval $ac_try) 2>&5 |
| 17129 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17130 | echo "$as_me:17130: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17131 | (exit $ac_status); }; }; then |
| 17132 | cf_cv_func_vsscanf=_doscan |
| 17133 | else |
| 17134 | echo "$as_me: failed program was:" >&5 |
| 17135 | cat conftest.$ac_ext >&5 |
| 17136 | |
| 17137 | cf_cv_func_vsscanf=no |
| 17138 | fi |
| 17139 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17140 | fi |
| 17141 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17142 | fi |
| 17143 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17144 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17145 | echo "$as_me:17145: result: $cf_cv_func_vsscanf" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17146 | echo "${ECHO_T}$cf_cv_func_vsscanf" >&6 |
| 17147 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17148 | case $cf_cv_func_vsscanf in |
| 17149 | (vsscanf) |
| 17150 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17151 | #define HAVE_VSSCANF 1 |
| 17152 | EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17153 | ;; |
| 17154 | (vfscanf) |
| 17155 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17156 | #define HAVE_VFSCANF 1 |
| 17157 | EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17158 | ;; |
| 17159 | (_doscan) |
| 17160 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17161 | #define HAVE__DOSCAN 1 |
| 17162 | EOF |
| 17163 | ;; |
| 17164 | esac |
| 17165 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17166 | echo "$as_me:17166: checking for working mkstemp" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17167 | echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6 |
| 17168 | if test "${cf_cv_func_mkstemp+set}" = set; then |
| 17169 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17170 | else |
| 17171 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17172 | rm -rf conftest* |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17173 | if test "$cross_compiling" = yes; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17174 | cf_cv_func_mkstemp=maybe |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17175 | else |
| 17176 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17177 | #line 17177 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17178 | #include "confdefs.h" |
| 17179 | |
| 17180 | #include <sys/types.h> |
| 17181 | #include <stdlib.h> |
| 17182 | #include <stdio.h> |
| 17183 | #include <string.h> |
| 17184 | #include <sys/stat.h> |
| 17185 | int main() |
| 17186 | { |
| 17187 | char *tmpl = "conftestXXXXXX"; |
| 17188 | char name[2][80]; |
| 17189 | int n; |
| 17190 | int result = 0; |
| 17191 | int fd; |
| 17192 | struct stat sb; |
| 17193 | |
| 17194 | umask(077); |
| 17195 | for (n = 0; n < 2; ++n) { |
| 17196 | strcpy(name[n], tmpl); |
| 17197 | if ((fd = mkstemp(name[n])) >= 0) { |
| 17198 | if (!strcmp(name[n], tmpl) |
| 17199 | || stat(name[n], &sb) != 0 |
| 17200 | || (sb.st_mode & S_IFMT) != S_IFREG |
| 17201 | || (sb.st_mode & 077) != 0) { |
| 17202 | result = 1; |
| 17203 | } |
| 17204 | close(fd); |
| 17205 | } |
| 17206 | } |
| 17207 | if (result == 0 |
| 17208 | && !strcmp(name[0], name[1])) |
| 17209 | result = 1; |
| 17210 | ${cf_cv_main_return:-return}(result); |
| 17211 | } |
| 17212 | |
| 17213 | _ACEOF |
| 17214 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17215 | if { (eval echo "$as_me:17215: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17216 | (eval $ac_link) 2>&5 |
| 17217 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17218 | echo "$as_me:17218: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17219 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17220 | { (eval echo "$as_me:17220: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17221 | (eval $ac_try) 2>&5 |
| 17222 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17223 | echo "$as_me:17223: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17224 | (exit $ac_status); }; }; then |
| 17225 | cf_cv_func_mkstemp=yes |
| 17226 | |
| 17227 | else |
| 17228 | echo "$as_me: program exited with status $ac_status" >&5 |
| 17229 | echo "$as_me: failed program was:" >&5 |
| 17230 | cat conftest.$ac_ext >&5 |
| 17231 | cf_cv_func_mkstemp=no |
| 17232 | |
| 17233 | fi |
| 17234 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 17235 | fi |
| 17236 | |
| 17237 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17238 | echo "$as_me:17238: result: $cf_cv_func_mkstemp" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17239 | echo "${ECHO_T}$cf_cv_func_mkstemp" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17240 | if test "x$cf_cv_func_mkstemp" = xmaybe ; then |
| 17241 | echo "$as_me:17241: checking for mkstemp" >&5 |
| 17242 | echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6 |
| 17243 | if test "${ac_cv_func_mkstemp+set}" = set; then |
| 17244 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17245 | else |
| 17246 | cat >conftest.$ac_ext <<_ACEOF |
| 17247 | #line 17247 "configure" |
| 17248 | #include "confdefs.h" |
| 17249 | /* System header to define __stub macros and hopefully few prototypes, |
| 17250 | which can conflict with char mkstemp (); below. */ |
| 17251 | #include <assert.h> |
| 17252 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 17253 | #ifdef __cplusplus |
| 17254 | extern "C" |
| 17255 | #endif |
| 17256 | /* We use char because int might match the return type of a gcc2 |
| 17257 | builtin and then its argument prototype would still apply. */ |
| 17258 | char mkstemp (); |
| 17259 | char (*f) (); |
| 17260 | |
| 17261 | int |
| 17262 | main () |
| 17263 | { |
| 17264 | /* The GNU C library defines this for functions which it implements |
| 17265 | to always fail with ENOSYS. Some functions are actually named |
| 17266 | something starting with __ and the normal name is an alias. */ |
| 17267 | #if defined (__stub_mkstemp) || defined (__stub___mkstemp) |
| 17268 | choke me |
| 17269 | #else |
| 17270 | f = mkstemp; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 17271 | #endif |
| 17272 | |
| 17273 | ; |
| 17274 | return 0; |
| 17275 | } |
| 17276 | _ACEOF |
| 17277 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 17278 | if { (eval echo "$as_me:17278: \"$ac_link\"") >&5 |
| 17279 | (eval $ac_link) 2>&5 |
| 17280 | ac_status=$? |
| 17281 | echo "$as_me:17281: \$? = $ac_status" >&5 |
| 17282 | (exit $ac_status); } && |
| 17283 | { ac_try='test -s conftest$ac_exeext' |
| 17284 | { (eval echo "$as_me:17284: \"$ac_try\"") >&5 |
| 17285 | (eval $ac_try) 2>&5 |
| 17286 | ac_status=$? |
| 17287 | echo "$as_me:17287: \$? = $ac_status" >&5 |
| 17288 | (exit $ac_status); }; }; then |
| 17289 | ac_cv_func_mkstemp=yes |
| 17290 | else |
| 17291 | echo "$as_me: failed program was:" >&5 |
| 17292 | cat conftest.$ac_ext >&5 |
| 17293 | ac_cv_func_mkstemp=no |
| 17294 | fi |
| 17295 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17296 | fi |
| 17297 | echo "$as_me:17297: result: $ac_cv_func_mkstemp" >&5 |
| 17298 | echo "${ECHO_T}$ac_cv_func_mkstemp" >&6 |
| 17299 | |
| 17300 | fi |
| 17301 | if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then |
| 17302 | |
| 17303 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17304 | #define HAVE_MKSTEMP 1 |
| 17305 | EOF |
| 17306 | |
| 17307 | fi |
| 17308 | |
| 17309 | # setup for prototype of fallback for vsscanf() |
| 17310 | |
| 17311 | if test "$cf_cv_func_vsscanf" = vsscanf ; then |
| 17312 | HAVE_VSSCANF=1 |
| 17313 | else |
| 17314 | HAVE_VSSCANF=0 |
| 17315 | fi |
| 17316 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17317 | if test "x$cross_compiling" = xyes ; then |
| 17318 | { echo "$as_me:17318: WARNING: cross compiling: assume setvbuf params not reversed" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17319 | echo "$as_me: WARNING: cross compiling: assume setvbuf params not reversed" >&2;} |
| 17320 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17321 | echo "$as_me:17321: checking whether setvbuf arguments are reversed" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17322 | echo $ECHO_N "checking whether setvbuf arguments are reversed... $ECHO_C" >&6 |
| 17323 | if test "${ac_cv_func_setvbuf_reversed+set}" = set; then |
| 17324 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17325 | else |
| 17326 | if test "$cross_compiling" = yes; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17327 | { { echo "$as_me:17327: error: cannot run test program while cross compiling" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17328 | echo "$as_me: error: cannot run test program while cross compiling" >&2;} |
| 17329 | { (exit 1); exit 1; }; } |
| 17330 | else |
| 17331 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17332 | #line 17332 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17333 | #include "confdefs.h" |
| 17334 | #include <stdio.h> |
| 17335 | /* If setvbuf has the reversed format, exit 0. */ |
| 17336 | int |
| 17337 | main () |
| 17338 | { |
| 17339 | /* This call has the arguments reversed. |
| 17340 | A reversed system may check and see that the address of main |
| 17341 | is not _IOLBF, _IONBF, or _IOFBF, and return nonzero. */ |
| 17342 | if (setvbuf(stdout, _IOLBF, (char *) main, BUFSIZ) != 0) |
| 17343 | $ac_main_return(1); |
| 17344 | putc('\r', stdout); |
| 17345 | $ac_main_return(0); /* Non-reversed systems segv here. */ |
| 17346 | } |
| 17347 | _ACEOF |
| 17348 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17349 | if { (eval echo "$as_me:17349: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17350 | (eval $ac_link) 2>&5 |
| 17351 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17352 | echo "$as_me:17352: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17353 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17354 | { (eval echo "$as_me:17354: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17355 | (eval $ac_try) 2>&5 |
| 17356 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17357 | echo "$as_me:17357: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17358 | (exit $ac_status); }; }; then |
| 17359 | ac_cv_func_setvbuf_reversed=yes |
| 17360 | else |
| 17361 | echo "$as_me: program exited with status $ac_status" >&5 |
| 17362 | echo "$as_me: failed program was:" >&5 |
| 17363 | cat conftest.$ac_ext >&5 |
| 17364 | ac_cv_func_setvbuf_reversed=no |
| 17365 | fi |
| 17366 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 17367 | fi |
| 17368 | rm -f core core.* *.core |
| 17369 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17370 | echo "$as_me:17370: result: $ac_cv_func_setvbuf_reversed" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17371 | echo "${ECHO_T}$ac_cv_func_setvbuf_reversed" >&6 |
| 17372 | if test $ac_cv_func_setvbuf_reversed = yes; then |
| 17373 | |
| 17374 | cat >>confdefs.h <<\EOF |
| 17375 | #define SETVBUF_REVERSED 1 |
| 17376 | EOF |
| 17377 | |
| 17378 | fi |
| 17379 | |
| 17380 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17381 | echo "$as_me:17381: checking for intptr_t" >&5 |
| 17382 | echo $ECHO_N "checking for intptr_t... $ECHO_C" >&6 |
| 17383 | if test "${ac_cv_type_intptr_t+set}" = set; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17384 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17385 | else |
| 17386 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17387 | #line 17387 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17388 | #include "confdefs.h" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17389 | $ac_includes_default |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17390 | int |
| 17391 | main () |
| 17392 | { |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17393 | if ((intptr_t *) 0) |
| 17394 | return 0; |
| 17395 | if (sizeof (intptr_t)) |
| 17396 | return 0; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17397 | ; |
| 17398 | return 0; |
| 17399 | } |
| 17400 | _ACEOF |
| 17401 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17402 | if { (eval echo "$as_me:17402: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17403 | (eval $ac_compile) 2>&5 |
| 17404 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17405 | echo "$as_me:17405: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17406 | (exit $ac_status); } && |
| 17407 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17408 | { (eval echo "$as_me:17408: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17409 | (eval $ac_try) 2>&5 |
| 17410 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17411 | echo "$as_me:17411: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17412 | (exit $ac_status); }; }; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17413 | ac_cv_type_intptr_t=yes |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17414 | else |
| 17415 | echo "$as_me: failed program was:" >&5 |
| 17416 | cat conftest.$ac_ext >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17417 | ac_cv_type_intptr_t=no |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17418 | fi |
| 17419 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 17420 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17421 | echo "$as_me:17421: result: $ac_cv_type_intptr_t" >&5 |
| 17422 | echo "${ECHO_T}$ac_cv_type_intptr_t" >&6 |
| 17423 | if test $ac_cv_type_intptr_t = yes; then |
| 17424 | : |
| 17425 | else |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17426 | |
| 17427 | cat >>confdefs.h <<EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17428 | #define intptr_t long |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17429 | EOF |
| 17430 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17431 | fi |
| 17432 | |
| 17433 | echo "$as_me:17433: checking for ssize_t" >&5 |
| 17434 | echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6 |
| 17435 | if test "${ac_cv_type_ssize_t+set}" = set; then |
| 17436 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17437 | else |
| 17438 | cat >conftest.$ac_ext <<_ACEOF |
| 17439 | #line 17439 "configure" |
| 17440 | #include "confdefs.h" |
| 17441 | $ac_includes_default |
| 17442 | int |
| 17443 | main () |
| 17444 | { |
| 17445 | if ((ssize_t *) 0) |
| 17446 | return 0; |
| 17447 | if (sizeof (ssize_t)) |
| 17448 | return 0; |
| 17449 | ; |
| 17450 | return 0; |
| 17451 | } |
| 17452 | _ACEOF |
| 17453 | rm -f conftest.$ac_objext |
| 17454 | if { (eval echo "$as_me:17454: \"$ac_compile\"") >&5 |
| 17455 | (eval $ac_compile) 2>&5 |
| 17456 | ac_status=$? |
| 17457 | echo "$as_me:17457: \$? = $ac_status" >&5 |
| 17458 | (exit $ac_status); } && |
| 17459 | { ac_try='test -s conftest.$ac_objext' |
| 17460 | { (eval echo "$as_me:17460: \"$ac_try\"") >&5 |
| 17461 | (eval $ac_try) 2>&5 |
| 17462 | ac_status=$? |
| 17463 | echo "$as_me:17463: \$? = $ac_status" >&5 |
| 17464 | (exit $ac_status); }; }; then |
| 17465 | ac_cv_type_ssize_t=yes |
| 17466 | else |
| 17467 | echo "$as_me: failed program was:" >&5 |
| 17468 | cat conftest.$ac_ext >&5 |
| 17469 | ac_cv_type_ssize_t=no |
| 17470 | fi |
| 17471 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 17472 | fi |
| 17473 | echo "$as_me:17473: result: $ac_cv_type_ssize_t" >&5 |
| 17474 | echo "${ECHO_T}$ac_cv_type_ssize_t" >&6 |
| 17475 | if test $ac_cv_type_ssize_t = yes; then |
| 17476 | : |
| 17477 | else |
| 17478 | |
| 17479 | cat >>confdefs.h <<EOF |
| 17480 | #define ssize_t int |
| 17481 | EOF |
| 17482 | |
| 17483 | fi |
| 17484 | |
| 17485 | echo "$as_me:17485: checking for type sigaction_t" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17486 | echo $ECHO_N "checking for type sigaction_t... $ECHO_C" >&6 |
| 17487 | if test "${cf_cv_type_sigaction+set}" = set; then |
| 17488 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17489 | else |
| 17490 | |
| 17491 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17492 | #line 17492 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17493 | #include "confdefs.h" |
| 17494 | |
| 17495 | #include <signal.h> |
| 17496 | int |
| 17497 | main () |
| 17498 | { |
| 17499 | sigaction_t x |
| 17500 | ; |
| 17501 | return 0; |
| 17502 | } |
| 17503 | _ACEOF |
| 17504 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17505 | if { (eval echo "$as_me:17505: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17506 | (eval $ac_compile) 2>&5 |
| 17507 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17508 | echo "$as_me:17508: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17509 | (exit $ac_status); } && |
| 17510 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17511 | { (eval echo "$as_me:17511: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17512 | (eval $ac_try) 2>&5 |
| 17513 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17514 | echo "$as_me:17514: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17515 | (exit $ac_status); }; }; then |
| 17516 | cf_cv_type_sigaction=yes |
| 17517 | else |
| 17518 | echo "$as_me: failed program was:" >&5 |
| 17519 | cat conftest.$ac_ext >&5 |
| 17520 | cf_cv_type_sigaction=no |
| 17521 | fi |
| 17522 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 17523 | fi |
| 17524 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17525 | echo "$as_me:17525: result: $cf_cv_type_sigaction" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17526 | echo "${ECHO_T}$cf_cv_type_sigaction" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17527 | test "$cf_cv_type_sigaction" = yes && |
| 17528 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17529 | #define HAVE_TYPE_SIGACTION 1 |
| 17530 | EOF |
| 17531 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17532 | echo "$as_me:17532: checking declaration of size-change" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17533 | echo $ECHO_N "checking declaration of size-change... $ECHO_C" >&6 |
| 17534 | if test "${cf_cv_sizechange+set}" = set; then |
| 17535 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17536 | else |
| 17537 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17538 | cf_cv_sizechange=unknown |
| 17539 | cf_save_CPPFLAGS="$CPPFLAGS" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17540 | |
| 17541 | for cf_opts in "" "NEED_PTEM_H" |
| 17542 | do |
| 17543 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17544 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 17545 | test -n "$cf_opts" && CPPFLAGS="$CPPFLAGS -D$cf_opts" |
| 17546 | cat >conftest.$ac_ext <<_ACEOF |
| 17547 | #line 17547 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17548 | #include "confdefs.h" |
| 17549 | #include <sys/types.h> |
| 17550 | #ifdef HAVE_TERMIOS_H |
| 17551 | #include <termios.h> |
| 17552 | #else |
| 17553 | #ifdef HAVE_TERMIO_H |
| 17554 | #include <termio.h> |
| 17555 | #endif |
| 17556 | #endif |
| 17557 | #ifdef NEED_PTEM_H |
| 17558 | /* This is a workaround for SCO: they neglected to define struct winsize in |
| 17559 | * termios.h -- it's only in termio.h and ptem.h |
| 17560 | */ |
| 17561 | #include <sys/stream.h> |
| 17562 | #include <sys/ptem.h> |
| 17563 | #endif |
| 17564 | #if !defined(sun) || !defined(HAVE_TERMIOS_H) |
| 17565 | #include <sys/ioctl.h> |
| 17566 | #endif |
| 17567 | |
| 17568 | int |
| 17569 | main () |
| 17570 | { |
| 17571 | |
| 17572 | #ifdef TIOCGSIZE |
| 17573 | struct ttysize win; /* FIXME: what system is this? */ |
| 17574 | int y = win.ts_lines; |
| 17575 | int x = win.ts_cols; |
| 17576 | #else |
| 17577 | #ifdef TIOCGWINSZ |
| 17578 | struct winsize win; |
| 17579 | int y = win.ws_row; |
| 17580 | int x = win.ws_col; |
| 17581 | #else |
| 17582 | no TIOCGSIZE or TIOCGWINSZ |
| 17583 | #endif /* TIOCGWINSZ */ |
| 17584 | #endif /* TIOCGSIZE */ |
| 17585 | |
| 17586 | ; |
| 17587 | return 0; |
| 17588 | } |
| 17589 | _ACEOF |
| 17590 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17591 | if { (eval echo "$as_me:17591: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17592 | (eval $ac_compile) 2>&5 |
| 17593 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17594 | echo "$as_me:17594: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17595 | (exit $ac_status); } && |
| 17596 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17597 | { (eval echo "$as_me:17597: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17598 | (eval $ac_try) 2>&5 |
| 17599 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17600 | echo "$as_me:17600: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17601 | (exit $ac_status); }; }; then |
| 17602 | cf_cv_sizechange=yes |
| 17603 | else |
| 17604 | echo "$as_me: failed program was:" >&5 |
| 17605 | cat conftest.$ac_ext >&5 |
| 17606 | cf_cv_sizechange=no |
| 17607 | fi |
| 17608 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 17609 | |
| 17610 | CPPFLAGS="$cf_save_CPPFLAGS" |
| 17611 | if test "$cf_cv_sizechange" = yes ; then |
| 17612 | echo "size-change succeeded ($cf_opts)" >&5 |
| 17613 | test -n "$cf_opts" && cf_cv_sizechange="$cf_opts" |
| 17614 | break |
| 17615 | fi |
| 17616 | done |
| 17617 | |
| 17618 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17619 | echo "$as_me:17619: result: $cf_cv_sizechange" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17620 | echo "${ECHO_T}$cf_cv_sizechange" >&6 |
| 17621 | if test "$cf_cv_sizechange" != no ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17622 | |
| 17623 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17624 | #define HAVE_SIZECHANGE 1 |
| 17625 | EOF |
| 17626 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17627 | case $cf_cv_sizechange in |
| 17628 | (NEED*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17629 | cat >>confdefs.h <<EOF |
| 17630 | #define $cf_cv_sizechange 1 |
| 17631 | EOF |
| 17632 | |
| 17633 | ;; |
| 17634 | esac |
| 17635 | fi |
| 17636 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17637 | echo "$as_me:17637: checking for memmove" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17638 | echo $ECHO_N "checking for memmove... $ECHO_C" >&6 |
| 17639 | if test "${ac_cv_func_memmove+set}" = set; then |
| 17640 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17641 | else |
| 17642 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17643 | #line 17643 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17644 | #include "confdefs.h" |
| 17645 | /* System header to define __stub macros and hopefully few prototypes, |
| 17646 | which can conflict with char memmove (); below. */ |
| 17647 | #include <assert.h> |
| 17648 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 17649 | #ifdef __cplusplus |
| 17650 | extern "C" |
| 17651 | #endif |
| 17652 | /* We use char because int might match the return type of a gcc2 |
| 17653 | builtin and then its argument prototype would still apply. */ |
| 17654 | char memmove (); |
| 17655 | char (*f) (); |
| 17656 | |
| 17657 | int |
| 17658 | main () |
| 17659 | { |
| 17660 | /* The GNU C library defines this for functions which it implements |
| 17661 | to always fail with ENOSYS. Some functions are actually named |
| 17662 | something starting with __ and the normal name is an alias. */ |
| 17663 | #if defined (__stub_memmove) || defined (__stub___memmove) |
| 17664 | choke me |
| 17665 | #else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17666 | f = memmove; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17667 | #endif |
| 17668 | |
| 17669 | ; |
| 17670 | return 0; |
| 17671 | } |
| 17672 | _ACEOF |
| 17673 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17674 | if { (eval echo "$as_me:17674: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17675 | (eval $ac_link) 2>&5 |
| 17676 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17677 | echo "$as_me:17677: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17678 | (exit $ac_status); } && |
| 17679 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17680 | { (eval echo "$as_me:17680: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17681 | (eval $ac_try) 2>&5 |
| 17682 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17683 | echo "$as_me:17683: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17684 | (exit $ac_status); }; }; then |
| 17685 | ac_cv_func_memmove=yes |
| 17686 | else |
| 17687 | echo "$as_me: failed program was:" >&5 |
| 17688 | cat conftest.$ac_ext >&5 |
| 17689 | ac_cv_func_memmove=no |
| 17690 | fi |
| 17691 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17692 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17693 | echo "$as_me:17693: result: $ac_cv_func_memmove" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17694 | echo "${ECHO_T}$ac_cv_func_memmove" >&6 |
| 17695 | if test $ac_cv_func_memmove = yes; then |
| 17696 | : |
| 17697 | else |
| 17698 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17699 | echo "$as_me:17699: checking for bcopy" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17700 | echo $ECHO_N "checking for bcopy... $ECHO_C" >&6 |
| 17701 | if test "${ac_cv_func_bcopy+set}" = set; then |
| 17702 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17703 | else |
| 17704 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17705 | #line 17705 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17706 | #include "confdefs.h" |
| 17707 | /* System header to define __stub macros and hopefully few prototypes, |
| 17708 | which can conflict with char bcopy (); below. */ |
| 17709 | #include <assert.h> |
| 17710 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 17711 | #ifdef __cplusplus |
| 17712 | extern "C" |
| 17713 | #endif |
| 17714 | /* We use char because int might match the return type of a gcc2 |
| 17715 | builtin and then its argument prototype would still apply. */ |
| 17716 | char bcopy (); |
| 17717 | char (*f) (); |
| 17718 | |
| 17719 | int |
| 17720 | main () |
| 17721 | { |
| 17722 | /* The GNU C library defines this for functions which it implements |
| 17723 | to always fail with ENOSYS. Some functions are actually named |
| 17724 | something starting with __ and the normal name is an alias. */ |
| 17725 | #if defined (__stub_bcopy) || defined (__stub___bcopy) |
| 17726 | choke me |
| 17727 | #else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17728 | f = bcopy; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17729 | #endif |
| 17730 | |
| 17731 | ; |
| 17732 | return 0; |
| 17733 | } |
| 17734 | _ACEOF |
| 17735 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17736 | if { (eval echo "$as_me:17736: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17737 | (eval $ac_link) 2>&5 |
| 17738 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17739 | echo "$as_me:17739: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17740 | (exit $ac_status); } && |
| 17741 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17742 | { (eval echo "$as_me:17742: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17743 | (eval $ac_try) 2>&5 |
| 17744 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17745 | echo "$as_me:17745: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17746 | (exit $ac_status); }; }; then |
| 17747 | ac_cv_func_bcopy=yes |
| 17748 | else |
| 17749 | echo "$as_me: failed program was:" >&5 |
| 17750 | cat conftest.$ac_ext >&5 |
| 17751 | ac_cv_func_bcopy=no |
| 17752 | fi |
| 17753 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17754 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17755 | echo "$as_me:17755: result: $ac_cv_func_bcopy" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17756 | echo "${ECHO_T}$ac_cv_func_bcopy" >&6 |
| 17757 | if test $ac_cv_func_bcopy = yes; then |
| 17758 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17759 | echo "$as_me:17759: checking if bcopy does overlapping moves" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17760 | echo $ECHO_N "checking if bcopy does overlapping moves... $ECHO_C" >&6 |
| 17761 | if test "${cf_cv_good_bcopy+set}" = set; then |
| 17762 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17763 | else |
| 17764 | |
| 17765 | if test "$cross_compiling" = yes; then |
| 17766 | cf_cv_good_bcopy=unknown |
| 17767 | else |
| 17768 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17769 | #line 17769 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17770 | #include "confdefs.h" |
| 17771 | |
| 17772 | int main() { |
| 17773 | static char data[] = "abcdefghijklmnopqrstuwwxyz"; |
| 17774 | char temp[40]; |
| 17775 | bcopy(data, temp, sizeof(data)); |
| 17776 | bcopy(temp+10, temp, 15); |
| 17777 | bcopy(temp+5, temp+15, 10); |
| 17778 | ${cf_cv_main_return:-return} (strcmp(temp, "klmnopqrstuwwxypqrstuwwxyz")); |
| 17779 | } |
| 17780 | |
| 17781 | _ACEOF |
| 17782 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17783 | if { (eval echo "$as_me:17783: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17784 | (eval $ac_link) 2>&5 |
| 17785 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17786 | echo "$as_me:17786: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17787 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17788 | { (eval echo "$as_me:17788: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17789 | (eval $ac_try) 2>&5 |
| 17790 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17791 | echo "$as_me:17791: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17792 | (exit $ac_status); }; }; then |
| 17793 | cf_cv_good_bcopy=yes |
| 17794 | else |
| 17795 | echo "$as_me: program exited with status $ac_status" >&5 |
| 17796 | echo "$as_me: failed program was:" >&5 |
| 17797 | cat conftest.$ac_ext >&5 |
| 17798 | cf_cv_good_bcopy=no |
| 17799 | fi |
| 17800 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 17801 | fi |
| 17802 | |
| 17803 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17804 | echo "$as_me:17804: result: $cf_cv_good_bcopy" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17805 | echo "${ECHO_T}$cf_cv_good_bcopy" >&6 |
| 17806 | |
| 17807 | else |
| 17808 | cf_cv_good_bcopy=no |
| 17809 | fi |
| 17810 | |
| 17811 | if test "$cf_cv_good_bcopy" = yes ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17812 | |
| 17813 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17814 | #define USE_OK_BCOPY 1 |
| 17815 | EOF |
| 17816 | |
| 17817 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17818 | |
| 17819 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17820 | #define USE_MY_MEMMOVE 1 |
| 17821 | EOF |
| 17822 | |
| 17823 | fi |
| 17824 | |
| 17825 | fi |
| 17826 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17827 | echo "$as_me:17827: checking if poll really works" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17828 | echo $ECHO_N "checking if poll really works... $ECHO_C" >&6 |
| 17829 | if test "${cf_cv_working_poll+set}" = set; then |
| 17830 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17831 | else |
| 17832 | |
| 17833 | if test "$cross_compiling" = yes; then |
| 17834 | cf_cv_working_poll=unknown |
| 17835 | else |
| 17836 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17837 | #line 17837 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17838 | #include "confdefs.h" |
| 17839 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17840 | #include <stdlib.h> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17841 | #include <stdio.h> |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17842 | #include <unistd.h> |
| 17843 | #include <fcntl.h> |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17844 | #ifdef HAVE_POLL_H |
| 17845 | #include <poll.h> |
| 17846 | #else |
| 17847 | #include <sys/poll.h> |
| 17848 | #endif |
| 17849 | int main() { |
| 17850 | struct pollfd myfds; |
| 17851 | int ret; |
| 17852 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17853 | /* check for Darwin bug with respect to "devices" */ |
| 17854 | myfds.fd = open("/dev/null", 1); /* O_WRONLY */ |
| 17855 | if (myfds.fd < 0) |
| 17856 | myfds.fd = 0; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17857 | myfds.events = POLLIN; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17858 | myfds.revents = 0; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17859 | |
| 17860 | ret = poll(&myfds, 1, 100); |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17861 | |
| 17862 | if (ret < 0 || (myfds.revents & POLLNVAL)) { |
| 17863 | ret = -1; |
| 17864 | } else { |
| 17865 | int fd = 0; |
| 17866 | if (!isatty(fd)) { |
| 17867 | fd = open("/dev/tty", 2); /* O_RDWR */ |
| 17868 | } |
| 17869 | |
| 17870 | if (fd >= 0) { |
| 17871 | /* also check with standard input */ |
| 17872 | myfds.fd = fd; |
| 17873 | myfds.events = POLLIN; |
| 17874 | myfds.revents = 0; |
| 17875 | ret = poll(&myfds, 1, 100); |
| 17876 | } else { |
| 17877 | ret = -1; |
| 17878 | } |
| 17879 | } |
| 17880 | ${cf_cv_main_return:-return}(ret < 0); |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17881 | } |
| 17882 | _ACEOF |
| 17883 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17884 | if { (eval echo "$as_me:17884: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17885 | (eval $ac_link) 2>&5 |
| 17886 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17887 | echo "$as_me:17887: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17888 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17889 | { (eval echo "$as_me:17889: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17890 | (eval $ac_try) 2>&5 |
| 17891 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17892 | echo "$as_me:17892: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17893 | (exit $ac_status); }; }; then |
| 17894 | cf_cv_working_poll=yes |
| 17895 | else |
| 17896 | echo "$as_me: program exited with status $ac_status" >&5 |
| 17897 | echo "$as_me: failed program was:" >&5 |
| 17898 | cat conftest.$ac_ext >&5 |
| 17899 | cf_cv_working_poll=no |
| 17900 | fi |
| 17901 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 17902 | fi |
| 17903 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17904 | echo "$as_me:17904: result: $cf_cv_working_poll" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17905 | echo "${ECHO_T}$cf_cv_working_poll" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17906 | test "$cf_cv_working_poll" = "yes" && |
| 17907 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 17908 | #define HAVE_WORKING_POLL 1 |
| 17909 | EOF |
| 17910 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 17911 | echo "$as_me:17911: checking for va_copy" >&5 |
| 17912 | echo $ECHO_N "checking for va_copy... $ECHO_C" >&6 |
| 17913 | if test "${cf_cv_have_va_copy+set}" = set; then |
| 17914 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17915 | else |
| 17916 | |
| 17917 | cat >conftest.$ac_ext <<_ACEOF |
| 17918 | #line 17918 "configure" |
| 17919 | #include "confdefs.h" |
| 17920 | |
| 17921 | #include <stdarg.h> |
| 17922 | |
| 17923 | int |
| 17924 | main () |
| 17925 | { |
| 17926 | |
| 17927 | static va_list dst; |
| 17928 | static va_list src; |
| 17929 | va_copy(dst, src) |
| 17930 | ; |
| 17931 | return 0; |
| 17932 | } |
| 17933 | _ACEOF |
| 17934 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 17935 | if { (eval echo "$as_me:17935: \"$ac_link\"") >&5 |
| 17936 | (eval $ac_link) 2>&5 |
| 17937 | ac_status=$? |
| 17938 | echo "$as_me:17938: \$? = $ac_status" >&5 |
| 17939 | (exit $ac_status); } && |
| 17940 | { ac_try='test -s conftest$ac_exeext' |
| 17941 | { (eval echo "$as_me:17941: \"$ac_try\"") >&5 |
| 17942 | (eval $ac_try) 2>&5 |
| 17943 | ac_status=$? |
| 17944 | echo "$as_me:17944: \$? = $ac_status" >&5 |
| 17945 | (exit $ac_status); }; }; then |
| 17946 | cf_cv_have_va_copy=yes |
| 17947 | else |
| 17948 | echo "$as_me: failed program was:" >&5 |
| 17949 | cat conftest.$ac_ext >&5 |
| 17950 | cf_cv_have_va_copy=no |
| 17951 | fi |
| 17952 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 17953 | fi |
| 17954 | echo "$as_me:17954: result: $cf_cv_have_va_copy" >&5 |
| 17955 | echo "${ECHO_T}$cf_cv_have_va_copy" >&6 |
| 17956 | |
| 17957 | test "$cf_cv_have_va_copy" = yes && |
| 17958 | cat >>confdefs.h <<\EOF |
| 17959 | #define HAVE_VA_COPY 1 |
| 17960 | EOF |
| 17961 | |
| 17962 | echo "$as_me:17962: checking for __va_copy" >&5 |
| 17963 | echo $ECHO_N "checking for __va_copy... $ECHO_C" >&6 |
| 17964 | if test "${cf_cv_have___va_copy+set}" = set; then |
| 17965 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 17966 | else |
| 17967 | |
| 17968 | cat >conftest.$ac_ext <<_ACEOF |
| 17969 | #line 17969 "configure" |
| 17970 | #include "confdefs.h" |
| 17971 | |
| 17972 | #include <stdarg.h> |
| 17973 | |
| 17974 | int |
| 17975 | main () |
| 17976 | { |
| 17977 | |
| 17978 | static va_list dst; |
| 17979 | static va_list src; |
| 17980 | __va_copy(dst, src) |
| 17981 | ; |
| 17982 | return 0; |
| 17983 | } |
| 17984 | _ACEOF |
| 17985 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 17986 | if { (eval echo "$as_me:17986: \"$ac_link\"") >&5 |
| 17987 | (eval $ac_link) 2>&5 |
| 17988 | ac_status=$? |
| 17989 | echo "$as_me:17989: \$? = $ac_status" >&5 |
| 17990 | (exit $ac_status); } && |
| 17991 | { ac_try='test -s conftest$ac_exeext' |
| 17992 | { (eval echo "$as_me:17992: \"$ac_try\"") >&5 |
| 17993 | (eval $ac_try) 2>&5 |
| 17994 | ac_status=$? |
| 17995 | echo "$as_me:17995: \$? = $ac_status" >&5 |
| 17996 | (exit $ac_status); }; }; then |
| 17997 | cf_cv_have___va_copy=yes |
| 17998 | else |
| 17999 | echo "$as_me: failed program was:" >&5 |
| 18000 | cat conftest.$ac_ext >&5 |
| 18001 | cf_cv_have___va_copy=no |
| 18002 | fi |
| 18003 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 18004 | fi |
| 18005 | echo "$as_me:18005: result: $cf_cv_have___va_copy" >&5 |
| 18006 | echo "${ECHO_T}$cf_cv_have___va_copy" >&6 |
| 18007 | |
| 18008 | test "$cf_cv_have___va_copy" = yes && |
| 18009 | cat >>confdefs.h <<\EOF |
| 18010 | #define HAVE___VA_COPY 1 |
| 18011 | EOF |
| 18012 | |
| 18013 | echo "$as_me:18013: checking for pid_t" >&5 |
| 18014 | echo $ECHO_N "checking for pid_t... $ECHO_C" >&6 |
| 18015 | if test "${ac_cv_type_pid_t+set}" = set; then |
| 18016 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18017 | else |
| 18018 | cat >conftest.$ac_ext <<_ACEOF |
| 18019 | #line 18019 "configure" |
| 18020 | #include "confdefs.h" |
| 18021 | $ac_includes_default |
| 18022 | int |
| 18023 | main () |
| 18024 | { |
| 18025 | if ((pid_t *) 0) |
| 18026 | return 0; |
| 18027 | if (sizeof (pid_t)) |
| 18028 | return 0; |
| 18029 | ; |
| 18030 | return 0; |
| 18031 | } |
| 18032 | _ACEOF |
| 18033 | rm -f conftest.$ac_objext |
| 18034 | if { (eval echo "$as_me:18034: \"$ac_compile\"") >&5 |
| 18035 | (eval $ac_compile) 2>&5 |
| 18036 | ac_status=$? |
| 18037 | echo "$as_me:18037: \$? = $ac_status" >&5 |
| 18038 | (exit $ac_status); } && |
| 18039 | { ac_try='test -s conftest.$ac_objext' |
| 18040 | { (eval echo "$as_me:18040: \"$ac_try\"") >&5 |
| 18041 | (eval $ac_try) 2>&5 |
| 18042 | ac_status=$? |
| 18043 | echo "$as_me:18043: \$? = $ac_status" >&5 |
| 18044 | (exit $ac_status); }; }; then |
| 18045 | ac_cv_type_pid_t=yes |
| 18046 | else |
| 18047 | echo "$as_me: failed program was:" >&5 |
| 18048 | cat conftest.$ac_ext >&5 |
| 18049 | ac_cv_type_pid_t=no |
| 18050 | fi |
| 18051 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 18052 | fi |
| 18053 | echo "$as_me:18053: result: $ac_cv_type_pid_t" >&5 |
| 18054 | echo "${ECHO_T}$ac_cv_type_pid_t" >&6 |
| 18055 | if test $ac_cv_type_pid_t = yes; then |
| 18056 | : |
| 18057 | else |
| 18058 | |
| 18059 | cat >>confdefs.h <<EOF |
| 18060 | #define pid_t int |
| 18061 | EOF |
| 18062 | |
| 18063 | fi |
| 18064 | |
| 18065 | for ac_header in unistd.h vfork.h |
| 18066 | do |
| 18067 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 18068 | echo "$as_me:18068: checking for $ac_header" >&5 |
| 18069 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 18070 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 18071 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18072 | else |
| 18073 | cat >conftest.$ac_ext <<_ACEOF |
| 18074 | #line 18074 "configure" |
| 18075 | #include "confdefs.h" |
| 18076 | #include <$ac_header> |
| 18077 | _ACEOF |
| 18078 | if { (eval echo "$as_me:18078: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 18079 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 18080 | ac_status=$? |
| 18081 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 18082 | rm -f conftest.er1 |
| 18083 | cat conftest.err >&5 |
| 18084 | echo "$as_me:18084: \$? = $ac_status" >&5 |
| 18085 | (exit $ac_status); } >/dev/null; then |
| 18086 | if test -s conftest.err; then |
| 18087 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 18088 | else |
| 18089 | ac_cpp_err= |
| 18090 | fi |
| 18091 | else |
| 18092 | ac_cpp_err=yes |
| 18093 | fi |
| 18094 | if test -z "$ac_cpp_err"; then |
| 18095 | eval "$as_ac_Header=yes" |
| 18096 | else |
| 18097 | echo "$as_me: failed program was:" >&5 |
| 18098 | cat conftest.$ac_ext >&5 |
| 18099 | eval "$as_ac_Header=no" |
| 18100 | fi |
| 18101 | rm -f conftest.err conftest.$ac_ext |
| 18102 | fi |
| 18103 | echo "$as_me:18103: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 18104 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 18105 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 18106 | cat >>confdefs.h <<EOF |
| 18107 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 18108 | EOF |
| 18109 | |
| 18110 | fi |
| 18111 | done |
| 18112 | |
| 18113 | for ac_func in fork vfork |
| 18114 | do |
| 18115 | as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 18116 | echo "$as_me:18116: checking for $ac_func" >&5 |
| 18117 | echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 |
| 18118 | if eval "test \"\${$as_ac_var+set}\" = set"; then |
| 18119 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18120 | else |
| 18121 | cat >conftest.$ac_ext <<_ACEOF |
| 18122 | #line 18122 "configure" |
| 18123 | #include "confdefs.h" |
| 18124 | /* System header to define __stub macros and hopefully few prototypes, |
| 18125 | which can conflict with char $ac_func (); below. */ |
| 18126 | #include <assert.h> |
| 18127 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 18128 | #ifdef __cplusplus |
| 18129 | extern "C" |
| 18130 | #endif |
| 18131 | /* We use char because int might match the return type of a gcc2 |
| 18132 | builtin and then its argument prototype would still apply. */ |
| 18133 | char $ac_func (); |
| 18134 | char (*f) (); |
| 18135 | |
| 18136 | int |
| 18137 | main () |
| 18138 | { |
| 18139 | /* The GNU C library defines this for functions which it implements |
| 18140 | to always fail with ENOSYS. Some functions are actually named |
| 18141 | something starting with __ and the normal name is an alias. */ |
| 18142 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 18143 | choke me |
| 18144 | #else |
| 18145 | f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1; |
| 18146 | #endif |
| 18147 | |
| 18148 | ; |
| 18149 | return 0; |
| 18150 | } |
| 18151 | _ACEOF |
| 18152 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 18153 | if { (eval echo "$as_me:18153: \"$ac_link\"") >&5 |
| 18154 | (eval $ac_link) 2>&5 |
| 18155 | ac_status=$? |
| 18156 | echo "$as_me:18156: \$? = $ac_status" >&5 |
| 18157 | (exit $ac_status); } && |
| 18158 | { ac_try='test -s conftest$ac_exeext' |
| 18159 | { (eval echo "$as_me:18159: \"$ac_try\"") >&5 |
| 18160 | (eval $ac_try) 2>&5 |
| 18161 | ac_status=$? |
| 18162 | echo "$as_me:18162: \$? = $ac_status" >&5 |
| 18163 | (exit $ac_status); }; }; then |
| 18164 | eval "$as_ac_var=yes" |
| 18165 | else |
| 18166 | echo "$as_me: failed program was:" >&5 |
| 18167 | cat conftest.$ac_ext >&5 |
| 18168 | eval "$as_ac_var=no" |
| 18169 | fi |
| 18170 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 18171 | fi |
| 18172 | echo "$as_me:18172: result: `eval echo '${'$as_ac_var'}'`" >&5 |
| 18173 | echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 |
| 18174 | if test `eval echo '${'$as_ac_var'}'` = yes; then |
| 18175 | cat >>confdefs.h <<EOF |
| 18176 | #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 18177 | EOF |
| 18178 | |
| 18179 | fi |
| 18180 | done |
| 18181 | |
| 18182 | ac_cv_func_fork_works=$ac_cv_func_fork |
| 18183 | if test "x$ac_cv_func_fork" = xyes; then |
| 18184 | echo "$as_me:18184: checking for working fork" >&5 |
| 18185 | echo $ECHO_N "checking for working fork... $ECHO_C" >&6 |
| 18186 | if test "${ac_cv_func_fork_works+set}" = set; then |
| 18187 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18188 | else |
| 18189 | if test "$cross_compiling" = yes; then |
| 18190 | ac_cv_func_fork_works=cross |
| 18191 | else |
| 18192 | cat >conftest.$ac_ext <<_ACEOF |
| 18193 | /* By Rüdiger Kuhlmann. */ |
| 18194 | #include <sys/types.h> |
| 18195 | #if HAVE_UNISTD_H |
| 18196 | # include <unistd.h> |
| 18197 | #endif |
| 18198 | /* Some systems only have a dummy stub for fork() */ |
| 18199 | int main () |
| 18200 | { |
| 18201 | if (fork() < 0) |
| 18202 | $ac_main_return (1); |
| 18203 | $ac_main_return (0); |
| 18204 | } |
| 18205 | _ACEOF |
| 18206 | rm -f conftest$ac_exeext |
| 18207 | if { (eval echo "$as_me:18207: \"$ac_link\"") >&5 |
| 18208 | (eval $ac_link) 2>&5 |
| 18209 | ac_status=$? |
| 18210 | echo "$as_me:18210: \$? = $ac_status" >&5 |
| 18211 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 18212 | { (eval echo "$as_me:18212: \"$ac_try\"") >&5 |
| 18213 | (eval $ac_try) 2>&5 |
| 18214 | ac_status=$? |
| 18215 | echo "$as_me:18215: \$? = $ac_status" >&5 |
| 18216 | (exit $ac_status); }; }; then |
| 18217 | ac_cv_func_fork_works=yes |
| 18218 | else |
| 18219 | echo "$as_me: program exited with status $ac_status" >&5 |
| 18220 | echo "$as_me: failed program was:" >&5 |
| 18221 | cat conftest.$ac_ext >&5 |
| 18222 | ac_cv_func_fork_works=no |
| 18223 | fi |
| 18224 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 18225 | fi |
| 18226 | fi |
| 18227 | echo "$as_me:18227: result: $ac_cv_func_fork_works" >&5 |
| 18228 | echo "${ECHO_T}$ac_cv_func_fork_works" >&6 |
| 18229 | |
| 18230 | fi |
| 18231 | if test "x$ac_cv_func_fork_works" = xcross; then |
| 18232 | case $host in |
| 18233 | *-*-amigaos* | *-*-msdosdjgpp*) |
| 18234 | # Override, as these systems have only a dummy fork() stub |
| 18235 | ac_cv_func_fork_works=no |
| 18236 | ;; |
| 18237 | *) |
| 18238 | ac_cv_func_fork_works=yes |
| 18239 | ;; |
| 18240 | esac |
| 18241 | { echo "$as_me:18241: WARNING: CROSS: Result $ac_cv_func_fork_works guessed due to cross-compiling." >&5 |
| 18242 | echo "$as_me: WARNING: CROSS: Result $ac_cv_func_fork_works guessed due to cross-compiling." >&2;} |
| 18243 | fi |
| 18244 | ac_cv_func_vfork_works=$ac_cv_func_vfork |
| 18245 | if test "x$ac_cv_func_vfork" = xyes; then |
| 18246 | echo "$as_me:18246: checking for working vfork" >&5 |
| 18247 | echo $ECHO_N "checking for working vfork... $ECHO_C" >&6 |
| 18248 | if test "${ac_cv_func_vfork_works+set}" = set; then |
| 18249 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18250 | else |
| 18251 | if test "$cross_compiling" = yes; then |
| 18252 | ac_cv_func_vfork_works=cross |
| 18253 | else |
| 18254 | cat >conftest.$ac_ext <<_ACEOF |
| 18255 | #line 18255 "configure" |
| 18256 | #include "confdefs.h" |
| 18257 | /* Thanks to Paul Eggert for this test. */ |
| 18258 | #include <stdio.h> |
| 18259 | #include <sys/types.h> |
| 18260 | #include <sys/stat.h> |
| 18261 | #if HAVE_UNISTD_H |
| 18262 | # include <unistd.h> |
| 18263 | #endif |
| 18264 | #if HAVE_VFORK_H |
| 18265 | # include <vfork.h> |
| 18266 | #endif |
| 18267 | /* On some sparc systems, changes by the child to local and incoming |
| 18268 | argument registers are propagated back to the parent. The compiler |
| 18269 | is told about this with #include <vfork.h>, but some compilers |
| 18270 | (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a |
| 18271 | static variable whose address is put into a register that is |
| 18272 | clobbered by the vfork. */ |
| 18273 | static |
| 18274 | #ifdef __cplusplus |
| 18275 | sparc_address_test (int arg) |
| 18276 | # else |
| 18277 | sparc_address_test (arg) int arg; |
| 18278 | #endif |
| 18279 | { |
| 18280 | static pid_t child; |
| 18281 | if (!child) { |
| 18282 | child = vfork (); |
| 18283 | if (child < 0) { |
| 18284 | perror ("vfork"); |
| 18285 | _exit(2); |
| 18286 | } |
| 18287 | if (!child) { |
| 18288 | arg = getpid(); |
| 18289 | write(-1, "", 0); |
| 18290 | _exit (arg); |
| 18291 | } |
| 18292 | } |
| 18293 | } |
| 18294 | |
| 18295 | int |
| 18296 | main () |
| 18297 | { |
| 18298 | pid_t parent = getpid (); |
| 18299 | pid_t child; |
| 18300 | |
| 18301 | sparc_address_test (); |
| 18302 | |
| 18303 | child = vfork (); |
| 18304 | |
| 18305 | if (child == 0) { |
| 18306 | /* Here is another test for sparc vfork register problems. This |
| 18307 | test uses lots of local variables, at least as many local |
| 18308 | variables as main has allocated so far including compiler |
| 18309 | temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris |
| 18310 | 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should |
| 18311 | reuse the register of parent for one of the local variables, |
| 18312 | since it will think that parent can't possibly be used any more |
| 18313 | in this routine. Assigning to the local variable will thus |
| 18314 | munge parent in the parent process. */ |
| 18315 | pid_t |
| 18316 | p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), |
| 18317 | p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); |
| 18318 | /* Convince the compiler that p..p7 are live; otherwise, it might |
| 18319 | use the same hardware register for all 8 local variables. */ |
| 18320 | if (p != p1 || p != p2 || p != p3 || p != p4 |
| 18321 | || p != p5 || p != p6 || p != p7) |
| 18322 | _exit(1); |
| 18323 | |
| 18324 | /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent |
| 18325 | from child file descriptors. If the child closes a descriptor |
| 18326 | before it execs or exits, this munges the parent's descriptor |
| 18327 | as well. Test for this by closing stdout in the child. */ |
| 18328 | _exit(close(fileno(stdout)) != 0); |
| 18329 | } else { |
| 18330 | int status; |
| 18331 | struct stat st; |
| 18332 | |
| 18333 | while (wait(&status) != child) |
| 18334 | ; |
| 18335 | $ac_main_return( |
| 18336 | /* Was there some problem with vforking? */ |
| 18337 | child < 0 |
| 18338 | |
| 18339 | /* Did the child fail? (This shouldn't happen.) */ |
| 18340 | || status |
| 18341 | |
| 18342 | /* Did the vfork/compiler bug occur? */ |
| 18343 | || parent != getpid() |
| 18344 | |
| 18345 | /* Did the file descriptor bug occur? */ |
| 18346 | || fstat(fileno(stdout), &st) != 0 |
| 18347 | ); |
| 18348 | } |
| 18349 | } |
| 18350 | _ACEOF |
| 18351 | rm -f conftest$ac_exeext |
| 18352 | if { (eval echo "$as_me:18352: \"$ac_link\"") >&5 |
| 18353 | (eval $ac_link) 2>&5 |
| 18354 | ac_status=$? |
| 18355 | echo "$as_me:18355: \$? = $ac_status" >&5 |
| 18356 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 18357 | { (eval echo "$as_me:18357: \"$ac_try\"") >&5 |
| 18358 | (eval $ac_try) 2>&5 |
| 18359 | ac_status=$? |
| 18360 | echo "$as_me:18360: \$? = $ac_status" >&5 |
| 18361 | (exit $ac_status); }; }; then |
| 18362 | ac_cv_func_vfork_works=yes |
| 18363 | else |
| 18364 | echo "$as_me: program exited with status $ac_status" >&5 |
| 18365 | echo "$as_me: failed program was:" >&5 |
| 18366 | cat conftest.$ac_ext >&5 |
| 18367 | ac_cv_func_vfork_works=no |
| 18368 | fi |
| 18369 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 18370 | fi |
| 18371 | fi |
| 18372 | echo "$as_me:18372: result: $ac_cv_func_vfork_works" >&5 |
| 18373 | echo "${ECHO_T}$ac_cv_func_vfork_works" >&6 |
| 18374 | |
| 18375 | fi; |
| 18376 | if test "x$ac_cv_func_fork_works" = xcross; then |
| 18377 | ac_cv_func_vfork_works=ac_cv_func_vfork |
| 18378 | { echo "$as_me:18378: WARNING: CROSS: Result $ac_cv_func_vfork_works guessed due to cross-compiling." >&5 |
| 18379 | echo "$as_me: WARNING: CROSS: Result $ac_cv_func_vfork_works guessed due to cross-compiling." >&2;} |
| 18380 | fi |
| 18381 | |
| 18382 | if test "x$ac_cv_func_vfork_works" = xyes; then |
| 18383 | |
| 18384 | cat >>confdefs.h <<\EOF |
| 18385 | #define HAVE_WORKING_VFORK 1 |
| 18386 | EOF |
| 18387 | |
| 18388 | else |
| 18389 | |
| 18390 | cat >>confdefs.h <<\EOF |
| 18391 | #define vfork fork |
| 18392 | EOF |
| 18393 | |
| 18394 | fi |
| 18395 | if test "x$ac_cv_func_fork_works" = xyes; then |
| 18396 | |
| 18397 | cat >>confdefs.h <<\EOF |
| 18398 | #define HAVE_WORKING_FORK 1 |
| 18399 | EOF |
| 18400 | |
| 18401 | fi |
| 18402 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18403 | # special check for test/ditto.c |
| 18404 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18405 | echo "$as_me:18405: checking for openpty in -lutil" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18406 | echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6 |
| 18407 | if test "${ac_cv_lib_util_openpty+set}" = set; then |
| 18408 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18409 | else |
| 18410 | ac_check_lib_save_LIBS=$LIBS |
| 18411 | LIBS="-lutil $LIBS" |
| 18412 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18413 | #line 18413 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18414 | #include "confdefs.h" |
| 18415 | |
| 18416 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 18417 | #ifdef __cplusplus |
| 18418 | extern "C" |
| 18419 | #endif |
| 18420 | /* We use char because int might match the return type of a gcc2 |
| 18421 | builtin and then its argument prototype would still apply. */ |
| 18422 | char openpty (); |
| 18423 | int |
| 18424 | main () |
| 18425 | { |
| 18426 | openpty (); |
| 18427 | ; |
| 18428 | return 0; |
| 18429 | } |
| 18430 | _ACEOF |
| 18431 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18432 | if { (eval echo "$as_me:18432: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18433 | (eval $ac_link) 2>&5 |
| 18434 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18435 | echo "$as_me:18435: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18436 | (exit $ac_status); } && |
| 18437 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18438 | { (eval echo "$as_me:18438: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18439 | (eval $ac_try) 2>&5 |
| 18440 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18441 | echo "$as_me:18441: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18442 | (exit $ac_status); }; }; then |
| 18443 | ac_cv_lib_util_openpty=yes |
| 18444 | else |
| 18445 | echo "$as_me: failed program was:" >&5 |
| 18446 | cat conftest.$ac_ext >&5 |
| 18447 | ac_cv_lib_util_openpty=no |
| 18448 | fi |
| 18449 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 18450 | LIBS=$ac_check_lib_save_LIBS |
| 18451 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18452 | echo "$as_me:18452: result: $ac_cv_lib_util_openpty" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18453 | echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6 |
| 18454 | if test $ac_cv_lib_util_openpty = yes; then |
| 18455 | cf_cv_lib_util=yes |
| 18456 | else |
| 18457 | cf_cv_lib_util=no |
| 18458 | fi |
| 18459 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18460 | echo "$as_me:18460: checking for openpty header" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18461 | echo $ECHO_N "checking for openpty header... $ECHO_C" >&6 |
| 18462 | if test "${cf_cv_func_openpty+set}" = set; then |
| 18463 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18464 | else |
| 18465 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18466 | cf_save_LIBS="$LIBS" |
| 18467 | test $cf_cv_lib_util = yes && |
| 18468 | cf_add_libs="-lutil" |
| 18469 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 18470 | for cf_add_1lib in $LIBS |
| 18471 | do |
| 18472 | for cf_add_2lib in $cf_add_libs |
| 18473 | do |
| 18474 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 18475 | then |
| 18476 | cf_add_1lib= |
| 18477 | break |
| 18478 | fi |
| 18479 | done |
| 18480 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 18481 | done |
| 18482 | LIBS="$cf_add_libs" |
| 18483 | |
| 18484 | for cf_header in pty.h libutil.h util.h |
| 18485 | do |
| 18486 | cat >conftest.$ac_ext <<_ACEOF |
| 18487 | #line 18487 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18488 | #include "confdefs.h" |
| 18489 | |
| 18490 | #include <$cf_header> |
| 18491 | |
| 18492 | int |
| 18493 | main () |
| 18494 | { |
| 18495 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18496 | int x = openpty((int *)0, (int *)0, (char *)0, |
| 18497 | (struct termios *)0, (struct winsize *)0); |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18498 | |
| 18499 | ; |
| 18500 | return 0; |
| 18501 | } |
| 18502 | _ACEOF |
| 18503 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18504 | if { (eval echo "$as_me:18504: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18505 | (eval $ac_link) 2>&5 |
| 18506 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18507 | echo "$as_me:18507: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18508 | (exit $ac_status); } && |
| 18509 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18510 | { (eval echo "$as_me:18510: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18511 | (eval $ac_try) 2>&5 |
| 18512 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18513 | echo "$as_me:18513: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18514 | (exit $ac_status); }; }; then |
| 18515 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18516 | cf_cv_func_openpty=$cf_header |
| 18517 | break |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18518 | |
| 18519 | else |
| 18520 | echo "$as_me: failed program was:" >&5 |
| 18521 | cat conftest.$ac_ext >&5 |
| 18522 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18523 | cf_cv_func_openpty=no |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18524 | |
| 18525 | fi |
| 18526 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18527 | done |
| 18528 | LIBS="$cf_save_LIBS" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18529 | |
| 18530 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18531 | echo "$as_me:18531: result: $cf_cv_func_openpty" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18532 | echo "${ECHO_T}$cf_cv_func_openpty" >&6 |
| 18533 | |
| 18534 | if test "$cf_cv_func_openpty" != no ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18535 | |
| 18536 | cat >>confdefs.h <<EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18537 | #define USE_OPENPTY_HEADER <$cf_cv_func_openpty> |
| 18538 | EOF |
| 18539 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18540 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18541 | #define USE_XTERM_PTY 1 |
| 18542 | EOF |
| 18543 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18544 | if test "x$cf_cv_lib_util" = xyes ; then |
| 18545 | |
| 18546 | cf_add_libs="-lutil" |
| 18547 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 18548 | for cf_add_1lib in $TEST_LIBS |
| 18549 | do |
| 18550 | for cf_add_2lib in $cf_add_libs |
| 18551 | do |
| 18552 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 18553 | then |
| 18554 | cf_add_1lib= |
| 18555 | break |
| 18556 | fi |
| 18557 | done |
| 18558 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 18559 | done |
| 18560 | TEST_LIBS="$cf_add_libs" |
| 18561 | |
| 18562 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18563 | fi |
| 18564 | |
| 18565 | if test "$with_hashed_db" != no ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18566 | |
| 18567 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18568 | #define USE_HASHED_DB 1 |
| 18569 | EOF |
| 18570 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18571 | case $with_hashed_db in |
| 18572 | (yes|*able*) |
| 18573 | ;; |
| 18574 | (*) |
| 18575 | if test -d "$with_hashed_db" ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18576 | |
| 18577 | if test -n "$with_hashed_db/include" ; then |
| 18578 | for cf_add_incdir in $with_hashed_db/include |
| 18579 | do |
| 18580 | while test $cf_add_incdir != /usr/include |
| 18581 | do |
| 18582 | if test -d $cf_add_incdir |
| 18583 | then |
| 18584 | cf_have_incdir=no |
| 18585 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 18586 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 18587 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 18588 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 18589 | cf_have_incdir=yes; break |
| 18590 | fi |
| 18591 | done |
| 18592 | fi |
| 18593 | |
| 18594 | if test "$cf_have_incdir" = no ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18595 | if test "$cf_add_incdir" = /usr/local/include ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18596 | if test "$GCC" = yes |
| 18597 | then |
| 18598 | cf_save_CPPFLAGS=$CPPFLAGS |
| 18599 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 18600 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18601 | #line 18601 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18602 | #include "confdefs.h" |
| 18603 | #include <stdio.h> |
| 18604 | int |
| 18605 | main () |
| 18606 | { |
| 18607 | printf("Hello") |
| 18608 | ; |
| 18609 | return 0; |
| 18610 | } |
| 18611 | _ACEOF |
| 18612 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18613 | if { (eval echo "$as_me:18613: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18614 | (eval $ac_compile) 2>&5 |
| 18615 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18616 | echo "$as_me:18616: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18617 | (exit $ac_status); } && |
| 18618 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18619 | { (eval echo "$as_me:18619: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18620 | (eval $ac_try) 2>&5 |
| 18621 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18622 | echo "$as_me:18622: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18623 | (exit $ac_status); }; }; then |
| 18624 | : |
| 18625 | else |
| 18626 | echo "$as_me: failed program was:" >&5 |
| 18627 | cat conftest.$ac_ext >&5 |
| 18628 | cf_have_incdir=yes |
| 18629 | fi |
| 18630 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 18631 | CPPFLAGS=$cf_save_CPPFLAGS |
| 18632 | fi |
| 18633 | fi |
| 18634 | fi |
| 18635 | |
| 18636 | if test "$cf_have_incdir" = no ; then |
| 18637 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 18638 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18639 | echo "${as_me:-configure}:18639: testing adding $cf_add_incdir to include-path ..." 1>&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18640 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18641 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18642 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18643 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 18644 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 18645 | cf_add_incdir="$cf_top_incdir" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18646 | else |
| 18647 | break |
| 18648 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18649 | else |
| 18650 | break |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18651 | fi |
| 18652 | done |
| 18653 | done |
| 18654 | fi |
| 18655 | |
| 18656 | if test -n "$with_hashed_db/lib" ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18657 | for cf_add_libdir in $with_hashed_db/lib |
| 18658 | do |
| 18659 | if test $cf_add_libdir = /usr/lib ; then |
| 18660 | : |
| 18661 | elif test -d $cf_add_libdir |
| 18662 | then |
| 18663 | cf_have_libdir=no |
| 18664 | if test -n "$LDFLAGS$LIBS" ; then |
| 18665 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 18666 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 18667 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 18668 | cf_have_libdir=yes; break |
| 18669 | fi |
| 18670 | done |
| 18671 | fi |
| 18672 | if test "$cf_have_libdir" = no ; then |
| 18673 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 18674 | |
| 18675 | echo "${as_me:-configure}:18675: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 18676 | |
| 18677 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 18678 | fi |
| 18679 | fi |
| 18680 | done |
| 18681 | fi |
| 18682 | |
| 18683 | else |
| 18684 | case "$with_hashed_db" in |
| 18685 | (./*|../*|/*) |
| 18686 | { echo "$as_me:18686: WARNING: no such directory $with_hashed_db" >&5 |
| 18687 | echo "$as_me: WARNING: no such directory $with_hashed_db" >&2;} |
| 18688 | ;; |
| 18689 | (*) |
| 18690 | |
| 18691 | cf_search= |
| 18692 | |
| 18693 | test "x$prefix" != "xNONE" && \ |
| 18694 | test -d "$prefix" && \ |
| 18695 | { |
| 18696 | test -n "$verbose" && echo " ... testing for include-directories under $prefix" |
| 18697 | test -d $prefix/include && cf_search="$cf_search $prefix/include" |
| 18698 | test -d $prefix/include/$with_hashed_db && cf_search="$cf_search $prefix/include/$with_hashed_db" |
| 18699 | test -d $prefix/include/$with_hashed_db/include && cf_search="$cf_search $prefix/include/$with_hashed_db/include" |
| 18700 | test -d $prefix/$with_hashed_db/include && cf_search="$cf_search $prefix/$with_hashed_db/include" |
| 18701 | test -d $prefix/$with_hashed_db/include/$with_hashed_db && cf_search="$cf_search $prefix/$with_hashed_db/include/$with_hashed_db" |
| 18702 | } |
| 18703 | |
| 18704 | for cf_subdir_prefix in \ |
| 18705 | /usr \ |
| 18706 | /usr/local \ |
| 18707 | /usr/pkg \ |
| 18708 | /opt \ |
| 18709 | /opt/local \ |
| 18710 | $HOME |
| 18711 | do |
| 18712 | |
| 18713 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 18714 | test -d "$cf_subdir_prefix" && \ |
| 18715 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 18716 | test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix" |
| 18717 | test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include" |
| 18718 | test -d $cf_subdir_prefix/include/$with_hashed_db && cf_search="$cf_search $cf_subdir_prefix/include/$with_hashed_db" |
| 18719 | test -d $cf_subdir_prefix/include/$with_hashed_db/include && cf_search="$cf_search $cf_subdir_prefix/include/$with_hashed_db/include" |
| 18720 | test -d $cf_subdir_prefix/$with_hashed_db/include && cf_search="$cf_search $cf_subdir_prefix/$with_hashed_db/include" |
| 18721 | test -d $cf_subdir_prefix/$with_hashed_db/include/$with_hashed_db && cf_search="$cf_search $cf_subdir_prefix/$with_hashed_db/include/$with_hashed_db" |
| 18722 | } |
| 18723 | |
| 18724 | done |
| 18725 | |
| 18726 | for cf_item in $cf_search |
| 18727 | do |
| 18728 | case $cf_item in |
| 18729 | (*/$with_hashed_db) |
| 18730 | |
| 18731 | if test -n "$cf_item" ; then |
| 18732 | for cf_add_incdir in $cf_item |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18733 | do |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18734 | while test $cf_add_incdir != /usr/include |
| 18735 | do |
| 18736 | if test -d $cf_add_incdir |
| 18737 | then |
| 18738 | cf_have_incdir=no |
| 18739 | if test -n "$CFLAGS$CPPFLAGS" ; then |
| 18740 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 18741 | for cf_test_incdir in $CFLAGS $CPPFLAGS ; do |
| 18742 | if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then |
| 18743 | cf_have_incdir=yes; break |
| 18744 | fi |
| 18745 | done |
| 18746 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18747 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18748 | if test "$cf_have_incdir" = no ; then |
| 18749 | if test "$cf_add_incdir" = /usr/local/include ; then |
| 18750 | if test "$GCC" = yes |
| 18751 | then |
| 18752 | cf_save_CPPFLAGS=$CPPFLAGS |
| 18753 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 18754 | cat >conftest.$ac_ext <<_ACEOF |
| 18755 | #line 18755 "configure" |
| 18756 | #include "confdefs.h" |
| 18757 | #include <stdio.h> |
| 18758 | int |
| 18759 | main () |
| 18760 | { |
| 18761 | printf("Hello") |
| 18762 | ; |
| 18763 | return 0; |
| 18764 | } |
| 18765 | _ACEOF |
| 18766 | rm -f conftest.$ac_objext |
| 18767 | if { (eval echo "$as_me:18767: \"$ac_compile\"") >&5 |
| 18768 | (eval $ac_compile) 2>&5 |
| 18769 | ac_status=$? |
| 18770 | echo "$as_me:18770: \$? = $ac_status" >&5 |
| 18771 | (exit $ac_status); } && |
| 18772 | { ac_try='test -s conftest.$ac_objext' |
| 18773 | { (eval echo "$as_me:18773: \"$ac_try\"") >&5 |
| 18774 | (eval $ac_try) 2>&5 |
| 18775 | ac_status=$? |
| 18776 | echo "$as_me:18776: \$? = $ac_status" >&5 |
| 18777 | (exit $ac_status); }; }; then |
| 18778 | : |
| 18779 | else |
| 18780 | echo "$as_me: failed program was:" >&5 |
| 18781 | cat conftest.$ac_ext >&5 |
| 18782 | cf_have_incdir=yes |
| 18783 | fi |
| 18784 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 18785 | CPPFLAGS=$cf_save_CPPFLAGS |
| 18786 | fi |
| 18787 | fi |
| 18788 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18789 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18790 | if test "$cf_have_incdir" = no ; then |
| 18791 | test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6 |
| 18792 | |
| 18793 | echo "${as_me:-configure}:18793: testing adding $cf_add_incdir to include-path ..." 1>&5 |
| 18794 | |
| 18795 | CPPFLAGS="$CPPFLAGS -I$cf_add_incdir" |
| 18796 | |
| 18797 | cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'` |
| 18798 | test "$cf_top_incdir" = "$cf_add_incdir" && break |
| 18799 | cf_add_incdir="$cf_top_incdir" |
| 18800 | else |
| 18801 | break |
| 18802 | fi |
| 18803 | else |
| 18804 | break |
| 18805 | fi |
| 18806 | done |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18807 | done |
| 18808 | fi |
| 18809 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18810 | ;; |
| 18811 | esac |
| 18812 | done |
| 18813 | |
| 18814 | cf_search= |
| 18815 | |
| 18816 | test "x$prefix" != "xNONE" && \ |
| 18817 | test -d "$prefix" && \ |
| 18818 | { |
| 18819 | test -n "$verbose" && echo " ... testing for lib-directories under $prefix" |
| 18820 | test -d $prefix/lib && cf_search="$cf_search $prefix/lib" |
| 18821 | test -d $prefix/lib/$with_hashed_db && cf_search="$cf_search $prefix/lib/$with_hashed_db" |
| 18822 | test -d $prefix/lib/$with_hashed_db/lib && cf_search="$cf_search $prefix/lib/$with_hashed_db/lib" |
| 18823 | test -d $prefix/$with_hashed_db/lib && cf_search="$cf_search $prefix/$with_hashed_db/lib" |
| 18824 | test -d $prefix/$with_hashed_db/lib/$with_hashed_db && cf_search="$cf_search $prefix/$with_hashed_db/lib/$with_hashed_db" |
| 18825 | } |
| 18826 | |
| 18827 | for cf_subdir_prefix in \ |
| 18828 | /usr \ |
| 18829 | /usr/local \ |
| 18830 | /usr/pkg \ |
| 18831 | /opt \ |
| 18832 | /opt/local \ |
| 18833 | $HOME |
| 18834 | do |
| 18835 | |
| 18836 | test "x$cf_subdir_prefix" != "x$prefix" && \ |
| 18837 | test -d "$cf_subdir_prefix" && \ |
| 18838 | (test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && { |
| 18839 | test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix" |
| 18840 | test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib" |
| 18841 | test -d $cf_subdir_prefix/lib/$with_hashed_db && cf_search="$cf_search $cf_subdir_prefix/lib/$with_hashed_db" |
| 18842 | test -d $cf_subdir_prefix/lib/$with_hashed_db/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$with_hashed_db/lib" |
| 18843 | test -d $cf_subdir_prefix/$with_hashed_db/lib && cf_search="$cf_search $cf_subdir_prefix/$with_hashed_db/lib" |
| 18844 | test -d $cf_subdir_prefix/$with_hashed_db/lib/$with_hashed_db && cf_search="$cf_search $cf_subdir_prefix/$with_hashed_db/lib/$with_hashed_db" |
| 18845 | } |
| 18846 | |
| 18847 | done |
| 18848 | |
| 18849 | for cf_item in $cf_search |
| 18850 | do |
| 18851 | case $cf_item in |
| 18852 | (*/$with_hashed_db) |
| 18853 | |
| 18854 | if test -n "$cf_item" ; then |
| 18855 | for cf_add_libdir in $cf_item |
| 18856 | do |
| 18857 | if test $cf_add_libdir = /usr/lib ; then |
| 18858 | : |
| 18859 | elif test -d $cf_add_libdir |
| 18860 | then |
| 18861 | cf_have_libdir=no |
| 18862 | if test -n "$LDFLAGS$LIBS" ; then |
| 18863 | # a loop is needed to ensure we can add subdirs of existing dirs |
| 18864 | for cf_test_libdir in $LDFLAGS $LIBS ; do |
| 18865 | if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then |
| 18866 | cf_have_libdir=yes; break |
| 18867 | fi |
| 18868 | done |
| 18869 | fi |
| 18870 | if test "$cf_have_libdir" = no ; then |
| 18871 | test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6 |
| 18872 | |
| 18873 | echo "${as_me:-configure}:18873: testing adding $cf_add_libdir to library-path ..." 1>&5 |
| 18874 | |
| 18875 | LDFLAGS="-L$cf_add_libdir $LDFLAGS" |
| 18876 | fi |
| 18877 | fi |
| 18878 | done |
| 18879 | fi |
| 18880 | |
| 18881 | ;; |
| 18882 | esac |
| 18883 | done |
| 18884 | |
| 18885 | ;; |
| 18886 | esac |
| 18887 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18888 | esac |
| 18889 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18890 | echo "$as_me:18890: checking for db.h" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18891 | echo $ECHO_N "checking for db.h... $ECHO_C" >&6 |
| 18892 | if test "${ac_cv_header_db_h+set}" = set; then |
| 18893 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18894 | else |
| 18895 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18896 | #line 18896 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18897 | #include "confdefs.h" |
| 18898 | #include <db.h> |
| 18899 | _ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18900 | if { (eval echo "$as_me:18900: \"$ac_cpp conftest.$ac_ext\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18901 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 18902 | ac_status=$? |
| 18903 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 18904 | rm -f conftest.er1 |
| 18905 | cat conftest.err >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18906 | echo "$as_me:18906: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18907 | (exit $ac_status); } >/dev/null; then |
| 18908 | if test -s conftest.err; then |
| 18909 | ac_cpp_err=$ac_c_preproc_warn_flag |
| 18910 | else |
| 18911 | ac_cpp_err= |
| 18912 | fi |
| 18913 | else |
| 18914 | ac_cpp_err=yes |
| 18915 | fi |
| 18916 | if test -z "$ac_cpp_err"; then |
| 18917 | ac_cv_header_db_h=yes |
| 18918 | else |
| 18919 | echo "$as_me: failed program was:" >&5 |
| 18920 | cat conftest.$ac_ext >&5 |
| 18921 | ac_cv_header_db_h=no |
| 18922 | fi |
| 18923 | rm -f conftest.err conftest.$ac_ext |
| 18924 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18925 | echo "$as_me:18925: result: $ac_cv_header_db_h" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18926 | echo "${ECHO_T}$ac_cv_header_db_h" >&6 |
| 18927 | if test $ac_cv_header_db_h = yes; then |
| 18928 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18929 | echo "$as_me:18929: checking for version of db" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18930 | echo $ECHO_N "checking for version of db... $ECHO_C" >&6 |
| 18931 | if test "${cf_cv_hashed_db_version+set}" = set; then |
| 18932 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 18933 | else |
| 18934 | |
| 18935 | cf_cv_hashed_db_version=unknown |
| 18936 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18937 | for cf_db_version in 1 2 3 4 5 6 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18938 | do |
| 18939 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18940 | echo "${as_me:-configure}:18940: testing checking for db version $cf_db_version ..." 1>&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18941 | |
| 18942 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18943 | #line 18943 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18944 | #include "confdefs.h" |
| 18945 | |
| 18946 | $ac_includes_default |
| 18947 | #include <db.h> |
| 18948 | |
| 18949 | #ifdef DB_VERSION_MAJOR |
| 18950 | /* db2 (DB_VERSION_MAJOR=2) has also DB_VERSION_MINOR, tested with 7 */ |
| 18951 | #if $cf_db_version == DB_VERSION_MAJOR |
| 18952 | /* ok */ |
| 18953 | #else |
| 18954 | make an error |
| 18955 | #endif |
| 18956 | #else |
| 18957 | #if $cf_db_version == 1 |
| 18958 | /* ok: assuming this is DB 1.8.5 */ |
| 18959 | #else |
| 18960 | make an error |
| 18961 | #endif |
| 18962 | #endif |
| 18963 | |
| 18964 | int |
| 18965 | main () |
| 18966 | { |
| 18967 | DBT *foo = 0 |
| 18968 | ; |
| 18969 | return 0; |
| 18970 | } |
| 18971 | _ACEOF |
| 18972 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18973 | if { (eval echo "$as_me:18973: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18974 | (eval $ac_compile) 2>&5 |
| 18975 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18976 | echo "$as_me:18976: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18977 | (exit $ac_status); } && |
| 18978 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18979 | { (eval echo "$as_me:18979: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18980 | (eval $ac_try) 2>&5 |
| 18981 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18982 | echo "$as_me:18982: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18983 | (exit $ac_status); }; }; then |
| 18984 | |
| 18985 | cf_cv_hashed_db_version=$cf_db_version |
| 18986 | break |
| 18987 | |
| 18988 | else |
| 18989 | echo "$as_me: failed program was:" >&5 |
| 18990 | cat conftest.$ac_ext >&5 |
| 18991 | fi |
| 18992 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 18993 | done |
| 18994 | |
| 18995 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 18996 | echo "$as_me:18996: result: $cf_cv_hashed_db_version" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 18997 | echo "${ECHO_T}$cf_cv_hashed_db_version" >&6 |
| 18998 | |
| 18999 | if test "$cf_cv_hashed_db_version" = unknown ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19000 | { { echo "$as_me:19000: error: Cannot determine version of db" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19001 | echo "$as_me: error: Cannot determine version of db" >&2;} |
| 19002 | { (exit 1); exit 1; }; } |
| 19003 | else |
| 19004 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19005 | echo "$as_me:19005: checking for db libraries" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19006 | echo $ECHO_N "checking for db libraries... $ECHO_C" >&6 |
| 19007 | if test "${cf_cv_hashed_db_libs+set}" = set; then |
| 19008 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19009 | else |
| 19010 | |
| 19011 | cf_cv_hashed_db_libs=unknown |
| 19012 | for cf_db_libs in "" db$cf_cv_hashed_db_version db-$cf_cv_hashed_db_version db '' |
| 19013 | do |
| 19014 | cf_save_libs="$LIBS" |
| 19015 | if test -n "$cf_db_libs"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19016 | |
| 19017 | cf_add_libs="-l$cf_db_libs" |
| 19018 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 19019 | for cf_add_1lib in $LIBS |
| 19020 | do |
| 19021 | for cf_add_2lib in $cf_add_libs |
| 19022 | do |
| 19023 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 19024 | then |
| 19025 | cf_add_1lib= |
| 19026 | break |
| 19027 | fi |
| 19028 | done |
| 19029 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 19030 | done |
| 19031 | LIBS="$cf_add_libs" |
| 19032 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19033 | fi |
| 19034 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19035 | echo "${as_me:-configure}:19035: testing checking for library "$cf_db_libs" ..." 1>&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19036 | |
| 19037 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19038 | #line 19038 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19039 | #include "confdefs.h" |
| 19040 | |
| 19041 | $ac_includes_default |
| 19042 | #include <db.h> |
| 19043 | |
| 19044 | int |
| 19045 | main () |
| 19046 | { |
| 19047 | |
| 19048 | char *path = "/tmp/foo"; |
| 19049 | #ifdef DB_VERSION_MAJOR |
| 19050 | #if DB_VERSION_MAJOR >= 4 |
| 19051 | DB *result = 0; |
| 19052 | db_create(&result, NULL, 0); |
| 19053 | result->open(result, |
| 19054 | NULL, |
| 19055 | path, |
| 19056 | path, |
| 19057 | DB_HASH, |
| 19058 | DB_CREATE, |
| 19059 | 0644); |
| 19060 | #elif DB_VERSION_MAJOR >= 3 |
| 19061 | DB *result = 0; |
| 19062 | db_create(&result, NULL, 0); |
| 19063 | result->open(result, |
| 19064 | path, |
| 19065 | path, |
| 19066 | DB_HASH, |
| 19067 | DB_CREATE, |
| 19068 | 0644); |
| 19069 | #elif DB_VERSION_MAJOR >= 2 |
| 19070 | DB *result = 0; |
| 19071 | db_open(path, |
| 19072 | DB_HASH, |
| 19073 | DB_CREATE, |
| 19074 | 0644, |
| 19075 | (DB_ENV *) 0, |
| 19076 | (DB_INFO *) 0, |
| 19077 | &result); |
| 19078 | #endif /* DB_VERSION_MAJOR */ |
| 19079 | #else |
| 19080 | DB *result = dbopen(path, |
| 19081 | 2, |
| 19082 | 0644, |
| 19083 | DB_HASH, |
| 19084 | 0); |
| 19085 | #endif |
| 19086 | ${cf_cv_main_return:-return}(result != 0) |
| 19087 | |
| 19088 | ; |
| 19089 | return 0; |
| 19090 | } |
| 19091 | _ACEOF |
| 19092 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19093 | if { (eval echo "$as_me:19093: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19094 | (eval $ac_link) 2>&5 |
| 19095 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19096 | echo "$as_me:19096: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19097 | (exit $ac_status); } && |
| 19098 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19099 | { (eval echo "$as_me:19099: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19100 | (eval $ac_try) 2>&5 |
| 19101 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19102 | echo "$as_me:19102: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19103 | (exit $ac_status); }; }; then |
| 19104 | |
| 19105 | if test -n "$cf_db_libs" ; then |
| 19106 | cf_cv_hashed_db_libs=$cf_db_libs |
| 19107 | else |
| 19108 | cf_cv_hashed_db_libs=default |
| 19109 | fi |
| 19110 | LIBS="$cf_save_libs" |
| 19111 | break |
| 19112 | |
| 19113 | else |
| 19114 | echo "$as_me: failed program was:" >&5 |
| 19115 | cat conftest.$ac_ext >&5 |
| 19116 | fi |
| 19117 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 19118 | LIBS="$cf_save_libs" |
| 19119 | done |
| 19120 | |
| 19121 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19122 | echo "$as_me:19122: result: $cf_cv_hashed_db_libs" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19123 | echo "${ECHO_T}$cf_cv_hashed_db_libs" >&6 |
| 19124 | |
| 19125 | if test "$cf_cv_hashed_db_libs" = unknown ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19126 | { { echo "$as_me:19126: error: Cannot determine library for db" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19127 | echo "$as_me: error: Cannot determine library for db" >&2;} |
| 19128 | { (exit 1); exit 1; }; } |
| 19129 | elif test "$cf_cv_hashed_db_libs" != default ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19130 | |
| 19131 | cf_add_libs="-l$cf_cv_hashed_db_libs" |
| 19132 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 19133 | for cf_add_1lib in $LIBS |
| 19134 | do |
| 19135 | for cf_add_2lib in $cf_add_libs |
| 19136 | do |
| 19137 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 19138 | then |
| 19139 | cf_add_1lib= |
| 19140 | break |
| 19141 | fi |
| 19142 | done |
| 19143 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 19144 | done |
| 19145 | LIBS="$cf_add_libs" |
| 19146 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19147 | fi |
| 19148 | fi |
| 19149 | |
| 19150 | else |
| 19151 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19152 | { { echo "$as_me:19152: error: Cannot find db.h" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19153 | echo "$as_me: error: Cannot find db.h" >&2;} |
| 19154 | { (exit 1); exit 1; }; } |
| 19155 | |
| 19156 | fi |
| 19157 | |
| 19158 | fi |
| 19159 | |
| 19160 | if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then |
| 19161 | CFLAGS=`echo ${CFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'` |
| 19162 | CXXFLAGS=`echo ${CXXFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'` |
| 19163 | fi |
| 19164 | |
| 19165 | # Just in case, check if the C compiler has a bool type. |
| 19166 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19167 | echo "$as_me:19167: checking if we should include stdbool.h" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19168 | echo $ECHO_N "checking if we should include stdbool.h... $ECHO_C" >&6 |
| 19169 | |
| 19170 | if test "${cf_cv_header_stdbool_h+set}" = set; then |
| 19171 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19172 | else |
| 19173 | |
| 19174 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19175 | #line 19175 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19176 | #include "confdefs.h" |
| 19177 | |
| 19178 | int |
| 19179 | main () |
| 19180 | { |
| 19181 | bool foo = false |
| 19182 | ; |
| 19183 | return 0; |
| 19184 | } |
| 19185 | _ACEOF |
| 19186 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19187 | if { (eval echo "$as_me:19187: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19188 | (eval $ac_compile) 2>&5 |
| 19189 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19190 | echo "$as_me:19190: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19191 | (exit $ac_status); } && |
| 19192 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19193 | { (eval echo "$as_me:19193: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19194 | (eval $ac_try) 2>&5 |
| 19195 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19196 | echo "$as_me:19196: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19197 | (exit $ac_status); }; }; then |
| 19198 | cf_cv_header_stdbool_h=0 |
| 19199 | else |
| 19200 | echo "$as_me: failed program was:" >&5 |
| 19201 | cat conftest.$ac_ext >&5 |
| 19202 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19203 | #line 19203 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19204 | #include "confdefs.h" |
| 19205 | |
| 19206 | #ifndef __BEOS__ |
| 19207 | #include <stdbool.h> |
| 19208 | #endif |
| 19209 | |
| 19210 | int |
| 19211 | main () |
| 19212 | { |
| 19213 | bool foo = false |
| 19214 | ; |
| 19215 | return 0; |
| 19216 | } |
| 19217 | _ACEOF |
| 19218 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19219 | if { (eval echo "$as_me:19219: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19220 | (eval $ac_compile) 2>&5 |
| 19221 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19222 | echo "$as_me:19222: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19223 | (exit $ac_status); } && |
| 19224 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19225 | { (eval echo "$as_me:19225: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19226 | (eval $ac_try) 2>&5 |
| 19227 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19228 | echo "$as_me:19228: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19229 | (exit $ac_status); }; }; then |
| 19230 | cf_cv_header_stdbool_h=1 |
| 19231 | else |
| 19232 | echo "$as_me: failed program was:" >&5 |
| 19233 | cat conftest.$ac_ext >&5 |
| 19234 | cf_cv_header_stdbool_h=0 |
| 19235 | fi |
| 19236 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 19237 | fi |
| 19238 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 19239 | fi |
| 19240 | |
| 19241 | if test "$cf_cv_header_stdbool_h" = 1 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19242 | then echo "$as_me:19242: result: yes" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19243 | echo "${ECHO_T}yes" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19244 | else echo "$as_me:19244: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19245 | echo "${ECHO_T}no" >&6 |
| 19246 | fi |
| 19247 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19248 | echo "$as_me:19248: checking for builtin bool type" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19249 | echo $ECHO_N "checking for builtin bool type... $ECHO_C" >&6 |
| 19250 | |
| 19251 | if test "${cf_cv_cc_bool_type+set}" = set; then |
| 19252 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19253 | else |
| 19254 | |
| 19255 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19256 | #line 19256 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19257 | #include "confdefs.h" |
| 19258 | |
| 19259 | #include <stdio.h> |
| 19260 | #include <sys/types.h> |
| 19261 | |
| 19262 | int |
| 19263 | main () |
| 19264 | { |
| 19265 | bool x = false |
| 19266 | ; |
| 19267 | return 0; |
| 19268 | } |
| 19269 | _ACEOF |
| 19270 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19271 | if { (eval echo "$as_me:19271: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19272 | (eval $ac_compile) 2>&5 |
| 19273 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19274 | echo "$as_me:19274: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19275 | (exit $ac_status); } && |
| 19276 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19277 | { (eval echo "$as_me:19277: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19278 | (eval $ac_try) 2>&5 |
| 19279 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19280 | echo "$as_me:19280: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19281 | (exit $ac_status); }; }; then |
| 19282 | cf_cv_cc_bool_type=1 |
| 19283 | else |
| 19284 | echo "$as_me: failed program was:" >&5 |
| 19285 | cat conftest.$ac_ext >&5 |
| 19286 | cf_cv_cc_bool_type=0 |
| 19287 | fi |
| 19288 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 19289 | |
| 19290 | fi |
| 19291 | |
| 19292 | if test "$cf_cv_cc_bool_type" = 1 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19293 | then echo "$as_me:19293: result: yes" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19294 | echo "${ECHO_T}yes" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19295 | else echo "$as_me:19295: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19296 | echo "${ECHO_T}no" >&6 |
| 19297 | fi |
| 19298 | |
| 19299 | # Check for C++ compiler characteristics (and ensure that it's there!) |
| 19300 | if test -n "$CXX" ; then |
| 19301 | ac_ext=cc |
| 19302 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 19303 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 19304 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 19305 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 19306 | ac_main_return=return |
| 19307 | |
| 19308 | if test -n "$GXX" ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19309 | case $cf_cv_system_name in |
| 19310 | (os2*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19311 | cf_stdcpp_libname=stdcpp |
| 19312 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19313 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19314 | cf_stdcpp_libname=stdc++ |
| 19315 | ;; |
| 19316 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19317 | echo "$as_me:19317: checking for library $cf_stdcpp_libname" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19318 | echo $ECHO_N "checking for library $cf_stdcpp_libname... $ECHO_C" >&6 |
| 19319 | if test "${cf_cv_libstdcpp+set}" = set; then |
| 19320 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19321 | else |
| 19322 | |
| 19323 | cf_save="$LIBS" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19324 | |
| 19325 | cf_add_libs="-l$cf_stdcpp_libname" |
| 19326 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 19327 | for cf_add_1lib in $LIBS |
| 19328 | do |
| 19329 | for cf_add_2lib in $cf_add_libs |
| 19330 | do |
| 19331 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 19332 | then |
| 19333 | cf_add_1lib= |
| 19334 | break |
| 19335 | fi |
| 19336 | done |
| 19337 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 19338 | done |
| 19339 | LIBS="$cf_add_libs" |
| 19340 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19341 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19342 | #line 19342 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19343 | #include "confdefs.h" |
| 19344 | |
| 19345 | #include <strstream.h> |
| 19346 | int |
| 19347 | main () |
| 19348 | { |
| 19349 | |
| 19350 | char buf[80]; |
| 19351 | strstreambuf foo(buf, sizeof(buf)) |
| 19352 | |
| 19353 | ; |
| 19354 | return 0; |
| 19355 | } |
| 19356 | _ACEOF |
| 19357 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19358 | if { (eval echo "$as_me:19358: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19359 | (eval $ac_link) 2>&5 |
| 19360 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19361 | echo "$as_me:19361: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19362 | (exit $ac_status); } && |
| 19363 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19364 | { (eval echo "$as_me:19364: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19365 | (eval $ac_try) 2>&5 |
| 19366 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19367 | echo "$as_me:19367: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19368 | (exit $ac_status); }; }; then |
| 19369 | cf_cv_libstdcpp=yes |
| 19370 | else |
| 19371 | echo "$as_me: failed program was:" >&5 |
| 19372 | cat conftest.$ac_ext >&5 |
| 19373 | cf_cv_libstdcpp=no |
| 19374 | fi |
| 19375 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 19376 | LIBS="$cf_save" |
| 19377 | |
| 19378 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19379 | echo "$as_me:19379: result: $cf_cv_libstdcpp" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19380 | echo "${ECHO_T}$cf_cv_libstdcpp" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19381 | test "$cf_cv_libstdcpp" = yes && |
| 19382 | cf_add_libs="-l$cf_stdcpp_libname" |
| 19383 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 19384 | for cf_add_1lib in $CXXLIBS |
| 19385 | do |
| 19386 | for cf_add_2lib in $cf_add_libs |
| 19387 | do |
| 19388 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 19389 | then |
| 19390 | cf_add_1lib= |
| 19391 | break |
| 19392 | fi |
| 19393 | done |
| 19394 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 19395 | done |
| 19396 | CXXLIBS="$cf_add_libs" |
| 19397 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19398 | fi |
| 19399 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19400 | echo "$as_me:19400: checking whether $CXX understands -c and -o together" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19401 | echo $ECHO_N "checking whether $CXX understands -c and -o together... $ECHO_C" >&6 |
| 19402 | if test "${cf_cv_prog_CXX_c_o+set}" = set; then |
| 19403 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19404 | else |
| 19405 | |
| 19406 | cat > conftest.$ac_ext <<CF_EOF |
| 19407 | #include <stdio.h> |
| 19408 | int main() |
| 19409 | { |
| 19410 | ${cf_cv_main_return:-return}(0); |
| 19411 | } |
| 19412 | CF_EOF |
| 19413 | # We do the test twice because some compilers refuse to overwrite an |
| 19414 | # existing .o file with -o, though they will create one. |
| 19415 | ac_try='$CXX -c conftest.$ac_ext -o conftest2.$ac_objext >&5' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19416 | if { (eval echo "$as_me:19416: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19417 | (eval $ac_try) 2>&5 |
| 19418 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19419 | echo "$as_me:19419: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19420 | (exit $ac_status); } && |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19421 | test -f conftest2.$ac_objext && { (eval echo "$as_me:19421: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19422 | (eval $ac_try) 2>&5 |
| 19423 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19424 | echo "$as_me:19424: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19425 | (exit $ac_status); }; |
| 19426 | then |
| 19427 | eval cf_cv_prog_CXX_c_o=yes |
| 19428 | else |
| 19429 | eval cf_cv_prog_CXX_c_o=no |
| 19430 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19431 | rm -rf conftest* |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19432 | |
| 19433 | fi |
| 19434 | if test $cf_cv_prog_CXX_c_o = yes; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19435 | echo "$as_me:19435: result: yes" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19436 | echo "${ECHO_T}yes" >&6 |
| 19437 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19438 | echo "$as_me:19438: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19439 | echo "${ECHO_T}no" >&6 |
| 19440 | fi |
| 19441 | |
| 19442 | case $GXX_VERSION in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19443 | (1*|2.0-6*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19444 | cf_cxx_library=yes |
| 19445 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19446 | (*-2.7*|2.7*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19447 | |
| 19448 | cf_cxx_library=unknown |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19449 | case $cf_cv_system_name in |
| 19450 | (os2*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19451 | cf_gpp_libname=gpp |
| 19452 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19453 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19454 | cf_gpp_libname=g++ |
| 19455 | ;; |
| 19456 | esac |
| 19457 | if test "$GXX" = yes; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19458 | echo "$as_me:19458: checking for lib$cf_gpp_libname" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19459 | echo $ECHO_N "checking for lib$cf_gpp_libname... $ECHO_C" >&6 |
| 19460 | cf_save="$LIBS" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19461 | |
| 19462 | cf_add_libs="-l$cf_gpp_libname" |
| 19463 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 19464 | for cf_add_1lib in $LIBS |
| 19465 | do |
| 19466 | for cf_add_2lib in $cf_add_libs |
| 19467 | do |
| 19468 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 19469 | then |
| 19470 | cf_add_1lib= |
| 19471 | break |
| 19472 | fi |
| 19473 | done |
| 19474 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 19475 | done |
| 19476 | LIBS="$cf_add_libs" |
| 19477 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19478 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19479 | #line 19479 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19480 | #include "confdefs.h" |
| 19481 | |
| 19482 | #include <$cf_gpp_libname/builtin.h> |
| 19483 | |
| 19484 | int |
| 19485 | main () |
| 19486 | { |
| 19487 | two_arg_error_handler_t foo2 = lib_error_handler |
| 19488 | ; |
| 19489 | return 0; |
| 19490 | } |
| 19491 | _ACEOF |
| 19492 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19493 | if { (eval echo "$as_me:19493: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19494 | (eval $ac_link) 2>&5 |
| 19495 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19496 | echo "$as_me:19496: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19497 | (exit $ac_status); } && |
| 19498 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19499 | { (eval echo "$as_me:19499: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19500 | (eval $ac_try) 2>&5 |
| 19501 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19502 | echo "$as_me:19502: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19503 | (exit $ac_status); }; }; then |
| 19504 | cf_cxx_library=yes |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19505 | |
| 19506 | cf_add_libs="-l$cf_gpp_libname" |
| 19507 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 19508 | for cf_add_1lib in $CXXLIBS |
| 19509 | do |
| 19510 | for cf_add_2lib in $cf_add_libs |
| 19511 | do |
| 19512 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 19513 | then |
| 19514 | cf_add_1lib= |
| 19515 | break |
| 19516 | fi |
| 19517 | done |
| 19518 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 19519 | done |
| 19520 | CXXLIBS="$cf_add_libs" |
| 19521 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19522 | if test "$cf_gpp_libname" = cpp ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19523 | |
| 19524 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19525 | #define HAVE_GPP_BUILTIN_H 1 |
| 19526 | EOF |
| 19527 | |
| 19528 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19529 | |
| 19530 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19531 | #define HAVE_GXX_BUILTIN_H 1 |
| 19532 | EOF |
| 19533 | |
| 19534 | fi |
| 19535 | else |
| 19536 | echo "$as_me: failed program was:" >&5 |
| 19537 | cat conftest.$ac_ext >&5 |
| 19538 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19539 | #line 19539 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19540 | #include "confdefs.h" |
| 19541 | |
| 19542 | #include <builtin.h> |
| 19543 | |
| 19544 | int |
| 19545 | main () |
| 19546 | { |
| 19547 | two_arg_error_handler_t foo2 = lib_error_handler |
| 19548 | ; |
| 19549 | return 0; |
| 19550 | } |
| 19551 | _ACEOF |
| 19552 | rm -f conftest.$ac_objext conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19553 | if { (eval echo "$as_me:19553: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19554 | (eval $ac_link) 2>&5 |
| 19555 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19556 | echo "$as_me:19556: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19557 | (exit $ac_status); } && |
| 19558 | { ac_try='test -s conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19559 | { (eval echo "$as_me:19559: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19560 | (eval $ac_try) 2>&5 |
| 19561 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19562 | echo "$as_me:19562: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19563 | (exit $ac_status); }; }; then |
| 19564 | cf_cxx_library=yes |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19565 | |
| 19566 | cf_add_libs="-l$cf_gpp_libname" |
| 19567 | # Filter out duplicates - this happens with badly-designed ".pc" files... |
| 19568 | for cf_add_1lib in $CXXLIBS |
| 19569 | do |
| 19570 | for cf_add_2lib in $cf_add_libs |
| 19571 | do |
| 19572 | if test "x$cf_add_1lib" = "x$cf_add_2lib" |
| 19573 | then |
| 19574 | cf_add_1lib= |
| 19575 | break |
| 19576 | fi |
| 19577 | done |
| 19578 | test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib" |
| 19579 | done |
| 19580 | CXXLIBS="$cf_add_libs" |
| 19581 | |
| 19582 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19583 | #define HAVE_BUILTIN_H 1 |
| 19584 | EOF |
| 19585 | |
| 19586 | else |
| 19587 | echo "$as_me: failed program was:" >&5 |
| 19588 | cat conftest.$ac_ext >&5 |
| 19589 | cf_cxx_library=no |
| 19590 | fi |
| 19591 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 19592 | fi |
| 19593 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 19594 | LIBS="$cf_save" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19595 | echo "$as_me:19595: result: $cf_cxx_library" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19596 | echo "${ECHO_T}$cf_cxx_library" >&6 |
| 19597 | fi |
| 19598 | |
| 19599 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19600 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19601 | cf_cxx_library=no |
| 19602 | ;; |
| 19603 | esac |
| 19604 | |
| 19605 | ac_ext=cc |
| 19606 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 19607 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 19608 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 19609 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 19610 | ac_main_return=return |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19611 | echo "$as_me:19611: checking how to run the C++ preprocessor" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19612 | echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6 |
| 19613 | if test -z "$CXXCPP"; then |
| 19614 | if test "${ac_cv_prog_CXXCPP+set}" = set; then |
| 19615 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19616 | else |
| 19617 | # Double quotes because CXXCPP needs to be expanded |
| 19618 | for CXXCPP in "$CXX -E" "/lib/cpp" |
| 19619 | do |
| 19620 | ac_preproc_ok=false |
| 19621 | for ac_cxx_preproc_warn_flag in '' yes |
| 19622 | do |
| 19623 | # Use a header file that comes with gcc, so configuring glibc |
| 19624 | # with a fresh cross-compiler works. |
| 19625 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 19626 | # not just through cpp. "Syntax error" is here to catch this case. |
| 19627 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19628 | #line 19628 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19629 | #include "confdefs.h" |
| 19630 | #include <assert.h> |
| 19631 | Syntax error |
| 19632 | _ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19633 | if { (eval echo "$as_me:19633: \"$ac_cpp conftest.$ac_ext\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19634 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 19635 | ac_status=$? |
| 19636 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 19637 | rm -f conftest.er1 |
| 19638 | cat conftest.err >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19639 | echo "$as_me:19639: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19640 | (exit $ac_status); } >/dev/null; then |
| 19641 | if test -s conftest.err; then |
| 19642 | ac_cpp_err=$ac_cxx_preproc_warn_flag |
| 19643 | else |
| 19644 | ac_cpp_err= |
| 19645 | fi |
| 19646 | else |
| 19647 | ac_cpp_err=yes |
| 19648 | fi |
| 19649 | if test -z "$ac_cpp_err"; then |
| 19650 | : |
| 19651 | else |
| 19652 | echo "$as_me: failed program was:" >&5 |
| 19653 | cat conftest.$ac_ext >&5 |
| 19654 | # Broken: fails on valid input. |
| 19655 | continue |
| 19656 | fi |
| 19657 | rm -f conftest.err conftest.$ac_ext |
| 19658 | |
| 19659 | # OK, works on sane cases. Now check whether non-existent headers |
| 19660 | # can be detected and how. |
| 19661 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19662 | #line 19662 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19663 | #include "confdefs.h" |
| 19664 | #include <ac_nonexistent.h> |
| 19665 | _ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19666 | if { (eval echo "$as_me:19666: \"$ac_cpp conftest.$ac_ext\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19667 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 19668 | ac_status=$? |
| 19669 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 19670 | rm -f conftest.er1 |
| 19671 | cat conftest.err >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19672 | echo "$as_me:19672: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19673 | (exit $ac_status); } >/dev/null; then |
| 19674 | if test -s conftest.err; then |
| 19675 | ac_cpp_err=$ac_cxx_preproc_warn_flag |
| 19676 | else |
| 19677 | ac_cpp_err= |
| 19678 | fi |
| 19679 | else |
| 19680 | ac_cpp_err=yes |
| 19681 | fi |
| 19682 | if test -z "$ac_cpp_err"; then |
| 19683 | # Broken: success on invalid input. |
| 19684 | continue |
| 19685 | else |
| 19686 | echo "$as_me: failed program was:" >&5 |
| 19687 | cat conftest.$ac_ext >&5 |
| 19688 | # Passes both tests. |
| 19689 | ac_preproc_ok=: |
| 19690 | break |
| 19691 | fi |
| 19692 | rm -f conftest.err conftest.$ac_ext |
| 19693 | |
| 19694 | done |
| 19695 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
| 19696 | rm -f conftest.err conftest.$ac_ext |
| 19697 | if $ac_preproc_ok; then |
| 19698 | break |
| 19699 | fi |
| 19700 | |
| 19701 | done |
| 19702 | ac_cv_prog_CXXCPP=$CXXCPP |
| 19703 | |
| 19704 | fi |
| 19705 | CXXCPP=$ac_cv_prog_CXXCPP |
| 19706 | else |
| 19707 | ac_cv_prog_CXXCPP=$CXXCPP |
| 19708 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19709 | echo "$as_me:19709: result: $CXXCPP" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19710 | echo "${ECHO_T}$CXXCPP" >&6 |
| 19711 | ac_preproc_ok=false |
| 19712 | for ac_cxx_preproc_warn_flag in '' yes |
| 19713 | do |
| 19714 | # Use a header file that comes with gcc, so configuring glibc |
| 19715 | # with a fresh cross-compiler works. |
| 19716 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 19717 | # not just through cpp. "Syntax error" is here to catch this case. |
| 19718 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19719 | #line 19719 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19720 | #include "confdefs.h" |
| 19721 | #include <assert.h> |
| 19722 | Syntax error |
| 19723 | _ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19724 | if { (eval echo "$as_me:19724: \"$ac_cpp conftest.$ac_ext\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19725 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 19726 | ac_status=$? |
| 19727 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 19728 | rm -f conftest.er1 |
| 19729 | cat conftest.err >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19730 | echo "$as_me:19730: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19731 | (exit $ac_status); } >/dev/null; then |
| 19732 | if test -s conftest.err; then |
| 19733 | ac_cpp_err=$ac_cxx_preproc_warn_flag |
| 19734 | else |
| 19735 | ac_cpp_err= |
| 19736 | fi |
| 19737 | else |
| 19738 | ac_cpp_err=yes |
| 19739 | fi |
| 19740 | if test -z "$ac_cpp_err"; then |
| 19741 | : |
| 19742 | else |
| 19743 | echo "$as_me: failed program was:" >&5 |
| 19744 | cat conftest.$ac_ext >&5 |
| 19745 | # Broken: fails on valid input. |
| 19746 | continue |
| 19747 | fi |
| 19748 | rm -f conftest.err conftest.$ac_ext |
| 19749 | |
| 19750 | # OK, works on sane cases. Now check whether non-existent headers |
| 19751 | # can be detected and how. |
| 19752 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19753 | #line 19753 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19754 | #include "confdefs.h" |
| 19755 | #include <ac_nonexistent.h> |
| 19756 | _ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19757 | if { (eval echo "$as_me:19757: \"$ac_cpp conftest.$ac_ext\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19758 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 19759 | ac_status=$? |
| 19760 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 19761 | rm -f conftest.er1 |
| 19762 | cat conftest.err >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19763 | echo "$as_me:19763: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19764 | (exit $ac_status); } >/dev/null; then |
| 19765 | if test -s conftest.err; then |
| 19766 | ac_cpp_err=$ac_cxx_preproc_warn_flag |
| 19767 | else |
| 19768 | ac_cpp_err= |
| 19769 | fi |
| 19770 | else |
| 19771 | ac_cpp_err=yes |
| 19772 | fi |
| 19773 | if test -z "$ac_cpp_err"; then |
| 19774 | # Broken: success on invalid input. |
| 19775 | continue |
| 19776 | else |
| 19777 | echo "$as_me: failed program was:" >&5 |
| 19778 | cat conftest.$ac_ext >&5 |
| 19779 | # Passes both tests. |
| 19780 | ac_preproc_ok=: |
| 19781 | break |
| 19782 | fi |
| 19783 | rm -f conftest.err conftest.$ac_ext |
| 19784 | |
| 19785 | done |
| 19786 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
| 19787 | rm -f conftest.err conftest.$ac_ext |
| 19788 | if $ac_preproc_ok; then |
| 19789 | : |
| 19790 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19791 | { { echo "$as_me:19791: error: C++ preprocessor \"$CXXCPP\" fails sanity check" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19792 | echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check" >&2;} |
| 19793 | { (exit 1); exit 1; }; } |
| 19794 | fi |
| 19795 | |
| 19796 | ac_ext=cc |
| 19797 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 19798 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 19799 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 19800 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 19801 | ac_main_return=return |
| 19802 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19803 | for ac_header in typeinfo |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19804 | do |
| 19805 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19806 | echo "$as_me:19806: checking for $ac_header" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19807 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 19808 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 19809 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19810 | else |
| 19811 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19812 | #line 19812 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19813 | #include "confdefs.h" |
| 19814 | #include <$ac_header> |
| 19815 | _ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19816 | if { (eval echo "$as_me:19816: \"$ac_cpp conftest.$ac_ext\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19817 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 19818 | ac_status=$? |
| 19819 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 19820 | rm -f conftest.er1 |
| 19821 | cat conftest.err >&5 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19822 | echo "$as_me:19822: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19823 | (exit $ac_status); } >/dev/null; then |
| 19824 | if test -s conftest.err; then |
| 19825 | ac_cpp_err=$ac_cxx_preproc_warn_flag |
| 19826 | else |
| 19827 | ac_cpp_err= |
| 19828 | fi |
| 19829 | else |
| 19830 | ac_cpp_err=yes |
| 19831 | fi |
| 19832 | if test -z "$ac_cpp_err"; then |
| 19833 | eval "$as_ac_Header=yes" |
| 19834 | else |
| 19835 | echo "$as_me: failed program was:" >&5 |
| 19836 | cat conftest.$ac_ext >&5 |
| 19837 | eval "$as_ac_Header=no" |
| 19838 | fi |
| 19839 | rm -f conftest.err conftest.$ac_ext |
| 19840 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19841 | echo "$as_me:19841: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19842 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 19843 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 19844 | cat >>confdefs.h <<EOF |
| 19845 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 19846 | EOF |
| 19847 | |
| 19848 | fi |
| 19849 | done |
| 19850 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19851 | for ac_header in iostream |
| 19852 | do |
| 19853 | as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 19854 | echo "$as_me:19854: checking for $ac_header" >&5 |
| 19855 | echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 |
| 19856 | if eval "test \"\${$as_ac_Header+set}\" = set"; then |
| 19857 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19858 | else |
| 19859 | cat >conftest.$ac_ext <<_ACEOF |
| 19860 | #line 19860 "configure" |
| 19861 | #include "confdefs.h" |
| 19862 | #include <$ac_header> |
| 19863 | _ACEOF |
| 19864 | if { (eval echo "$as_me:19864: \"$ac_cpp conftest.$ac_ext\"") >&5 |
| 19865 | (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 |
| 19866 | ac_status=$? |
| 19867 | egrep -v '^ *\+' conftest.er1 >conftest.err |
| 19868 | rm -f conftest.er1 |
| 19869 | cat conftest.err >&5 |
| 19870 | echo "$as_me:19870: \$? = $ac_status" >&5 |
| 19871 | (exit $ac_status); } >/dev/null; then |
| 19872 | if test -s conftest.err; then |
| 19873 | ac_cpp_err=$ac_cxx_preproc_warn_flag |
| 19874 | else |
| 19875 | ac_cpp_err= |
| 19876 | fi |
| 19877 | else |
| 19878 | ac_cpp_err=yes |
| 19879 | fi |
| 19880 | if test -z "$ac_cpp_err"; then |
| 19881 | eval "$as_ac_Header=yes" |
| 19882 | else |
| 19883 | echo "$as_me: failed program was:" >&5 |
| 19884 | cat conftest.$ac_ext >&5 |
| 19885 | eval "$as_ac_Header=no" |
| 19886 | fi |
| 19887 | rm -f conftest.err conftest.$ac_ext |
| 19888 | fi |
| 19889 | echo "$as_me:19889: result: `eval echo '${'$as_ac_Header'}'`" >&5 |
| 19890 | echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 |
| 19891 | if test `eval echo '${'$as_ac_Header'}'` = yes; then |
| 19892 | cat >>confdefs.h <<EOF |
| 19893 | #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 19894 | EOF |
| 19895 | |
| 19896 | fi |
| 19897 | done |
| 19898 | |
| 19899 | if test x"$ac_cv_header_iostream" = xyes ; then |
| 19900 | echo "$as_me:19900: checking if iostream uses std-namespace" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19901 | echo $ECHO_N "checking if iostream uses std-namespace... $ECHO_C" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19902 | cat >conftest.$ac_ext <<_ACEOF |
| 19903 | #line 19903 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19904 | #include "confdefs.h" |
| 19905 | |
| 19906 | #include <iostream> |
| 19907 | using std::endl; |
| 19908 | using std::cerr; |
| 19909 | int |
| 19910 | main () |
| 19911 | { |
| 19912 | |
| 19913 | cerr << "testing" << endl; |
| 19914 | |
| 19915 | ; |
| 19916 | return 0; |
| 19917 | } |
| 19918 | _ACEOF |
| 19919 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19920 | if { (eval echo "$as_me:19920: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19921 | (eval $ac_compile) 2>&5 |
| 19922 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19923 | echo "$as_me:19923: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19924 | (exit $ac_status); } && |
| 19925 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19926 | { (eval echo "$as_me:19926: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19927 | (eval $ac_try) 2>&5 |
| 19928 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19929 | echo "$as_me:19929: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19930 | (exit $ac_status); }; }; then |
| 19931 | cf_iostream_namespace=yes |
| 19932 | else |
| 19933 | echo "$as_me: failed program was:" >&5 |
| 19934 | cat conftest.$ac_ext >&5 |
| 19935 | cf_iostream_namespace=no |
| 19936 | fi |
| 19937 | rm -f conftest.$ac_objext conftest.$ac_ext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19938 | echo "$as_me:19938: result: $cf_iostream_namespace" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19939 | echo "${ECHO_T}$cf_iostream_namespace" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19940 | if test "$cf_iostream_namespace" = yes ; then |
| 19941 | |
| 19942 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19943 | #define IOSTREAM_NAMESPACE 1 |
| 19944 | EOF |
| 19945 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19946 | fi |
| 19947 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19948 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19949 | echo "$as_me:19949: checking if we should include stdbool.h" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19950 | echo $ECHO_N "checking if we should include stdbool.h... $ECHO_C" >&6 |
| 19951 | |
| 19952 | if test "${cf_cv_header_stdbool_h+set}" = set; then |
| 19953 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 19954 | else |
| 19955 | |
| 19956 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19957 | #line 19957 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19958 | #include "confdefs.h" |
| 19959 | |
| 19960 | int |
| 19961 | main () |
| 19962 | { |
| 19963 | bool foo = false |
| 19964 | ; |
| 19965 | return 0; |
| 19966 | } |
| 19967 | _ACEOF |
| 19968 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19969 | if { (eval echo "$as_me:19969: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19970 | (eval $ac_compile) 2>&5 |
| 19971 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19972 | echo "$as_me:19972: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19973 | (exit $ac_status); } && |
| 19974 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19975 | { (eval echo "$as_me:19975: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19976 | (eval $ac_try) 2>&5 |
| 19977 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19978 | echo "$as_me:19978: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19979 | (exit $ac_status); }; }; then |
| 19980 | cf_cv_header_stdbool_h=0 |
| 19981 | else |
| 19982 | echo "$as_me: failed program was:" >&5 |
| 19983 | cat conftest.$ac_ext >&5 |
| 19984 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 19985 | #line 19985 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 19986 | #include "confdefs.h" |
| 19987 | |
| 19988 | #ifndef __BEOS__ |
| 19989 | #include <stdbool.h> |
| 19990 | #endif |
| 19991 | |
| 19992 | int |
| 19993 | main () |
| 19994 | { |
| 19995 | bool foo = false |
| 19996 | ; |
| 19997 | return 0; |
| 19998 | } |
| 19999 | _ACEOF |
| 20000 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20001 | if { (eval echo "$as_me:20001: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20002 | (eval $ac_compile) 2>&5 |
| 20003 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20004 | echo "$as_me:20004: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20005 | (exit $ac_status); } && |
| 20006 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20007 | { (eval echo "$as_me:20007: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20008 | (eval $ac_try) 2>&5 |
| 20009 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20010 | echo "$as_me:20010: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20011 | (exit $ac_status); }; }; then |
| 20012 | cf_cv_header_stdbool_h=1 |
| 20013 | else |
| 20014 | echo "$as_me: failed program was:" >&5 |
| 20015 | cat conftest.$ac_ext >&5 |
| 20016 | cf_cv_header_stdbool_h=0 |
| 20017 | fi |
| 20018 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 20019 | fi |
| 20020 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 20021 | fi |
| 20022 | |
| 20023 | if test "$cf_cv_header_stdbool_h" = 1 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20024 | then echo "$as_me:20024: result: yes" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20025 | echo "${ECHO_T}yes" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20026 | else echo "$as_me:20026: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20027 | echo "${ECHO_T}no" >&6 |
| 20028 | fi |
| 20029 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20030 | echo "$as_me:20030: checking for builtin bool type" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20031 | echo $ECHO_N "checking for builtin bool type... $ECHO_C" >&6 |
| 20032 | |
| 20033 | if test "${cf_cv_builtin_bool+set}" = set; then |
| 20034 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20035 | else |
| 20036 | |
| 20037 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20038 | #line 20038 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20039 | #include "confdefs.h" |
| 20040 | |
| 20041 | #include <stdio.h> |
| 20042 | #include <sys/types.h> |
| 20043 | |
| 20044 | int |
| 20045 | main () |
| 20046 | { |
| 20047 | bool x = false |
| 20048 | ; |
| 20049 | return 0; |
| 20050 | } |
| 20051 | _ACEOF |
| 20052 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20053 | if { (eval echo "$as_me:20053: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20054 | (eval $ac_compile) 2>&5 |
| 20055 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20056 | echo "$as_me:20056: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20057 | (exit $ac_status); } && |
| 20058 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20059 | { (eval echo "$as_me:20059: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20060 | (eval $ac_try) 2>&5 |
| 20061 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20062 | echo "$as_me:20062: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20063 | (exit $ac_status); }; }; then |
| 20064 | cf_cv_builtin_bool=1 |
| 20065 | else |
| 20066 | echo "$as_me: failed program was:" >&5 |
| 20067 | cat conftest.$ac_ext >&5 |
| 20068 | cf_cv_builtin_bool=0 |
| 20069 | fi |
| 20070 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 20071 | |
| 20072 | fi |
| 20073 | |
| 20074 | if test "$cf_cv_builtin_bool" = 1 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20075 | then echo "$as_me:20075: result: yes" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20076 | echo "${ECHO_T}yes" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20077 | else echo "$as_me:20077: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20078 | echo "${ECHO_T}no" >&6 |
| 20079 | fi |
| 20080 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20081 | echo "$as_me:20081: checking for size of bool" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20082 | echo $ECHO_N "checking for size of bool... $ECHO_C" >&6 |
| 20083 | if test "${cf_cv_type_of_bool+set}" = set; then |
| 20084 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20085 | else |
| 20086 | |
| 20087 | rm -f cf_test.out |
| 20088 | if test "$cross_compiling" = yes; then |
| 20089 | cf_cv_type_of_bool=unknown |
| 20090 | else |
| 20091 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20092 | #line 20092 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20093 | #include "confdefs.h" |
| 20094 | |
| 20095 | #include <stdlib.h> |
| 20096 | #include <stdio.h> |
| 20097 | |
| 20098 | #if defined(__cplusplus) |
| 20099 | |
| 20100 | #ifdef HAVE_GXX_BUILTIN_H |
| 20101 | #include <g++/builtin.h> |
| 20102 | #elif HAVE_GPP_BUILTIN_H |
| 20103 | #include <gpp/builtin.h> |
| 20104 | #elif HAVE_BUILTIN_H |
| 20105 | #include <builtin.h> |
| 20106 | #endif |
| 20107 | |
| 20108 | #else |
| 20109 | |
| 20110 | #if $cf_cv_header_stdbool_h |
| 20111 | #include <stdbool.h> |
| 20112 | #endif |
| 20113 | |
| 20114 | #endif |
| 20115 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20116 | int main() |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20117 | { |
| 20118 | FILE *fp = fopen("cf_test.out", "w"); |
| 20119 | if (fp != 0) { |
| 20120 | bool x = true; |
| 20121 | if ((bool)(-x) >= 0) |
| 20122 | fputs("unsigned ", fp); |
| 20123 | if (sizeof(x) == sizeof(int)) fputs("int", fp); |
| 20124 | else if (sizeof(x) == sizeof(char)) fputs("char", fp); |
| 20125 | else if (sizeof(x) == sizeof(short))fputs("short",fp); |
| 20126 | else if (sizeof(x) == sizeof(long)) fputs("long", fp); |
| 20127 | fclose(fp); |
| 20128 | } |
| 20129 | ${cf_cv_main_return:-return}(0); |
| 20130 | } |
| 20131 | |
| 20132 | _ACEOF |
| 20133 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20134 | if { (eval echo "$as_me:20134: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20135 | (eval $ac_link) 2>&5 |
| 20136 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20137 | echo "$as_me:20137: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20138 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20139 | { (eval echo "$as_me:20139: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20140 | (eval $ac_try) 2>&5 |
| 20141 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20142 | echo "$as_me:20142: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20143 | (exit $ac_status); }; }; then |
| 20144 | cf_cv_type_of_bool=`cat cf_test.out` |
| 20145 | if test -z "$cf_cv_type_of_bool"; then |
| 20146 | cf_cv_type_of_bool=unknown |
| 20147 | fi |
| 20148 | else |
| 20149 | echo "$as_me: program exited with status $ac_status" >&5 |
| 20150 | echo "$as_me: failed program was:" >&5 |
| 20151 | cat conftest.$ac_ext >&5 |
| 20152 | cf_cv_type_of_bool=unknown |
| 20153 | fi |
| 20154 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 20155 | fi |
| 20156 | |
| 20157 | fi |
| 20158 | |
| 20159 | rm -f cf_test.out |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20160 | echo "$as_me:20160: result: $cf_cv_type_of_bool" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20161 | echo "${ECHO_T}$cf_cv_type_of_bool" >&6 |
| 20162 | if test "$cf_cv_type_of_bool" = unknown ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20163 | case .$NCURSES_BOOL in |
| 20164 | (.auto|.) NCURSES_BOOL=unsigned;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20165 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20166 | { echo "$as_me:20166: WARNING: Assuming $NCURSES_BOOL for type of bool" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20167 | echo "$as_me: WARNING: Assuming $NCURSES_BOOL for type of bool" >&2;} |
| 20168 | cf_cv_type_of_bool=$NCURSES_BOOL |
| 20169 | fi |
| 20170 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20171 | echo "$as_me:20171: checking for special defines needed for etip.h" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20172 | echo $ECHO_N "checking for special defines needed for etip.h... $ECHO_C" >&6 |
| 20173 | cf_save_CXXFLAGS="$CXXFLAGS" |
| 20174 | cf_result="none" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20175 | |
| 20176 | # etip.h includes ncurses.h which includes ncurses_dll.h |
| 20177 | # But ncurses_dll.h is generated - fix here. |
| 20178 | test -d include || mkdir include |
| 20179 | test -f include/ncurses_dll.h || sed -e 's/@NCURSES_WRAP_PREFIX@/'$NCURSES_WRAP_PREFIX'/g' ${srcdir}/include/ncurses_dll.h.in >include/ncurses_dll.h |
| 20180 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20181 | for cf_math in "" MATH_H |
| 20182 | do |
| 20183 | for cf_excp in "" MATH_EXCEPTION |
| 20184 | do |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20185 | CXXFLAGS="$cf_save_CXXFLAGS -I${srcdir}/c++ -I${srcdir}/menu -Iinclude -I${srcdir}/include" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20186 | test -n "$cf_math" && CXXFLAGS="$CXXFLAGS -DETIP_NEEDS_${cf_math}" |
| 20187 | test -n "$cf_excp" && CXXFLAGS="$CXXFLAGS -DETIP_NEEDS_${cf_excp}" |
| 20188 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20189 | #line 20189 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20190 | #include "confdefs.h" |
| 20191 | |
| 20192 | #include <etip.h.in> |
| 20193 | |
| 20194 | int |
| 20195 | main () |
| 20196 | { |
| 20197 | |
| 20198 | ; |
| 20199 | return 0; |
| 20200 | } |
| 20201 | _ACEOF |
| 20202 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20203 | if { (eval echo "$as_me:20203: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20204 | (eval $ac_compile) 2>&5 |
| 20205 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20206 | echo "$as_me:20206: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20207 | (exit $ac_status); } && |
| 20208 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20209 | { (eval echo "$as_me:20209: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20210 | (eval $ac_try) 2>&5 |
| 20211 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20212 | echo "$as_me:20212: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20213 | (exit $ac_status); }; }; then |
| 20214 | |
| 20215 | test -n "$cf_math" && cat >>confdefs.h <<EOF |
| 20216 | #define ETIP_NEEDS_${cf_math} 1 |
| 20217 | EOF |
| 20218 | |
| 20219 | test -n "$cf_excp" && cat >>confdefs.h <<EOF |
| 20220 | #define ETIP_NEEDS_${cf_excp} 1 |
| 20221 | EOF |
| 20222 | |
| 20223 | cf_result="$cf_math $cf_excp" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20224 | break 2 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20225 | |
| 20226 | else |
| 20227 | echo "$as_me: failed program was:" >&5 |
| 20228 | cat conftest.$ac_ext >&5 |
| 20229 | fi |
| 20230 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 20231 | done |
| 20232 | done |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20233 | echo "$as_me:20233: result: $cf_result" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20234 | echo "${ECHO_T}$cf_result" >&6 |
| 20235 | CXXFLAGS="$cf_save_CXXFLAGS" |
| 20236 | |
| 20237 | if test -n "$CXX"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20238 | echo "$as_me:20238: checking if $CXX accepts parameter initialization" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20239 | echo $ECHO_N "checking if $CXX accepts parameter initialization... $ECHO_C" >&6 |
| 20240 | if test "${cf_cv_cpp_param_init+set}" = set; then |
| 20241 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20242 | else |
| 20243 | |
| 20244 | ac_ext=cc |
| 20245 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 20246 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 20247 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 20248 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 20249 | ac_main_return=return |
| 20250 | |
| 20251 | if test "$cross_compiling" = yes; then |
| 20252 | cf_cv_cpp_param_init=unknown |
| 20253 | else |
| 20254 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20255 | #line 20255 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20256 | #include "confdefs.h" |
| 20257 | |
| 20258 | class TEST { |
| 20259 | private: |
| 20260 | int value; |
| 20261 | public: |
| 20262 | TEST(int x = 1); |
| 20263 | ~TEST(); |
| 20264 | }; |
| 20265 | |
| 20266 | TEST::TEST(int x = 1) // some compilers do not like second initializer |
| 20267 | { |
| 20268 | value = x; |
| 20269 | } |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20270 | int main() { } |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20271 | |
| 20272 | _ACEOF |
| 20273 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20274 | if { (eval echo "$as_me:20274: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20275 | (eval $ac_link) 2>&5 |
| 20276 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20277 | echo "$as_me:20277: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20278 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20279 | { (eval echo "$as_me:20279: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20280 | (eval $ac_try) 2>&5 |
| 20281 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20282 | echo "$as_me:20282: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20283 | (exit $ac_status); }; }; then |
| 20284 | cf_cv_cpp_param_init=yes |
| 20285 | else |
| 20286 | echo "$as_me: program exited with status $ac_status" >&5 |
| 20287 | echo "$as_me: failed program was:" >&5 |
| 20288 | cat conftest.$ac_ext >&5 |
| 20289 | cf_cv_cpp_param_init=no |
| 20290 | fi |
| 20291 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 20292 | fi |
| 20293 | ac_ext=cc |
| 20294 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 20295 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 20296 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 20297 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 20298 | ac_main_return=return |
| 20299 | |
| 20300 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20301 | echo "$as_me:20301: result: $cf_cv_cpp_param_init" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20302 | echo "${ECHO_T}$cf_cv_cpp_param_init" >&6 |
| 20303 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20304 | test "$cf_cv_cpp_param_init" = yes && |
| 20305 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20306 | #define CPP_HAS_PARAM_INIT 1 |
| 20307 | EOF |
| 20308 | |
| 20309 | if test -n "$CXX"; then |
| 20310 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20311 | echo "$as_me:20311: checking if $CXX accepts static_cast" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20312 | echo $ECHO_N "checking if $CXX accepts static_cast... $ECHO_C" >&6 |
| 20313 | if test "${cf_cv_cpp_static_cast+set}" = set; then |
| 20314 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20315 | else |
| 20316 | |
| 20317 | ac_ext=cc |
| 20318 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 20319 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 20320 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 20321 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 20322 | ac_main_return=return |
| 20323 | |
| 20324 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20325 | #line 20325 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20326 | #include "confdefs.h" |
| 20327 | |
| 20328 | class NCursesPanel |
| 20329 | { |
| 20330 | public: |
| 20331 | NCursesPanel(int nlines, |
| 20332 | int ncols, |
| 20333 | int begin_y = 0, |
| 20334 | int begin_x = 0) |
| 20335 | { |
| 20336 | } |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20337 | NCursesPanel(); |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20338 | ~NCursesPanel(); |
| 20339 | }; |
| 20340 | |
| 20341 | template<class T> class NCursesUserPanel : public NCursesPanel |
| 20342 | { |
| 20343 | public: |
| 20344 | NCursesUserPanel (int nlines, |
| 20345 | int ncols, |
| 20346 | int begin_y = 0, |
| 20347 | int begin_x = 0, |
| 20348 | const T* p_UserData = static_cast<T*>(0)) |
| 20349 | : NCursesPanel (nlines, ncols, begin_y, begin_x) |
| 20350 | { |
| 20351 | }; |
| 20352 | NCursesUserPanel(const T* p_UserData = static_cast<T*>(0)) : NCursesPanel() |
| 20353 | { |
| 20354 | }; |
| 20355 | |
| 20356 | virtual ~NCursesUserPanel() {}; |
| 20357 | }; |
| 20358 | |
| 20359 | int |
| 20360 | main () |
| 20361 | { |
| 20362 | |
| 20363 | const char* p_UserData = static_cast<char*>(0) |
| 20364 | ; |
| 20365 | return 0; |
| 20366 | } |
| 20367 | _ACEOF |
| 20368 | rm -f conftest.$ac_objext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20369 | if { (eval echo "$as_me:20369: \"$ac_compile\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20370 | (eval $ac_compile) 2>&5 |
| 20371 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20372 | echo "$as_me:20372: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20373 | (exit $ac_status); } && |
| 20374 | { ac_try='test -s conftest.$ac_objext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20375 | { (eval echo "$as_me:20375: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20376 | (eval $ac_try) 2>&5 |
| 20377 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20378 | echo "$as_me:20378: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20379 | (exit $ac_status); }; }; then |
| 20380 | cf_cv_cpp_static_cast=yes |
| 20381 | else |
| 20382 | echo "$as_me: failed program was:" >&5 |
| 20383 | cat conftest.$ac_ext >&5 |
| 20384 | cf_cv_cpp_static_cast=no |
| 20385 | fi |
| 20386 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 20387 | |
| 20388 | ac_ext=cc |
| 20389 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 20390 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 20391 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 20392 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
| 20393 | ac_main_return=return |
| 20394 | |
| 20395 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20396 | echo "$as_me:20396: result: $cf_cv_cpp_static_cast" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20397 | echo "${ECHO_T}$cf_cv_cpp_static_cast" >&6 |
| 20398 | |
| 20399 | fi |
| 20400 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20401 | test "$cf_cv_cpp_static_cast" = yes && |
| 20402 | cat >>confdefs.h <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20403 | #define CPP_HAS_STATIC_CAST 1 |
| 20404 | EOF |
| 20405 | |
| 20406 | CXX_AR='$(AR)' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20407 | CXX_ARFLAGS='$(ARFLAGS)' |
| 20408 | case $cf_cv_system_name in |
| 20409 | (irix*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20410 | if test "$GXX" != yes ; then |
| 20411 | CXX_AR='$(CXX)' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20412 | CXX_ARFLAGS='-ar -o' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20413 | fi |
| 20414 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20415 | (sco3.2v5*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20416 | CXXLDFLAGS="-u main" |
| 20417 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20418 | (solaris2*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20419 | if test "$GXX" != yes ; then |
| 20420 | CXX_AR='$(CXX)' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20421 | CXX_ARFLAGS='-xar -o' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20422 | fi |
| 20423 | ;; |
| 20424 | esac |
| 20425 | |
| 20426 | else |
| 20427 | cf_cxx_library=no |
| 20428 | cf_cv_builtin_bool=1 |
| 20429 | |
| 20430 | # Just because we are not configuring against C++ right now does not |
| 20431 | # mean that a user will not want to use C++. Some distributors disable |
| 20432 | # the C++ portion of this configuration as a shortcut (or just to avoid |
| 20433 | # compiling the demo in the c++ directory). So we need a reasonable |
| 20434 | # default for the 'bool' type. |
| 20435 | # |
| 20436 | # Caveat: since the storage of the bool type is not standardized, it |
| 20437 | # may change. |
| 20438 | |
| 20439 | if test "$NCURSES_BOOL" != auto ; then |
| 20440 | cf_cv_type_of_bool=$NCURSES_BOOL |
| 20441 | cf_cv_header_stdbool_h=0 |
| 20442 | else |
| 20443 | if test "$cf_cv_header_stdbool_h" = 1 ; then |
| 20444 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20445 | echo "$as_me:20445: checking for size of bool" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20446 | echo $ECHO_N "checking for size of bool... $ECHO_C" >&6 |
| 20447 | if test "${cf_cv_type_of_bool+set}" = set; then |
| 20448 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20449 | else |
| 20450 | |
| 20451 | rm -f cf_test.out |
| 20452 | if test "$cross_compiling" = yes; then |
| 20453 | cf_cv_type_of_bool=unknown |
| 20454 | else |
| 20455 | cat >conftest.$ac_ext <<_ACEOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20456 | #line 20456 "configure" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20457 | #include "confdefs.h" |
| 20458 | |
| 20459 | #include <stdlib.h> |
| 20460 | #include <stdio.h> |
| 20461 | |
| 20462 | #if defined(__cplusplus) |
| 20463 | |
| 20464 | #ifdef HAVE_GXX_BUILTIN_H |
| 20465 | #include <g++/builtin.h> |
| 20466 | #elif HAVE_GPP_BUILTIN_H |
| 20467 | #include <gpp/builtin.h> |
| 20468 | #elif HAVE_BUILTIN_H |
| 20469 | #include <builtin.h> |
| 20470 | #endif |
| 20471 | |
| 20472 | #else |
| 20473 | |
| 20474 | #if $cf_cv_header_stdbool_h |
| 20475 | #include <stdbool.h> |
| 20476 | #endif |
| 20477 | |
| 20478 | #endif |
| 20479 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20480 | int main() |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20481 | { |
| 20482 | FILE *fp = fopen("cf_test.out", "w"); |
| 20483 | if (fp != 0) { |
| 20484 | bool x = true; |
| 20485 | if ((bool)(-x) >= 0) |
| 20486 | fputs("unsigned ", fp); |
| 20487 | if (sizeof(x) == sizeof(int)) fputs("int", fp); |
| 20488 | else if (sizeof(x) == sizeof(char)) fputs("char", fp); |
| 20489 | else if (sizeof(x) == sizeof(short))fputs("short",fp); |
| 20490 | else if (sizeof(x) == sizeof(long)) fputs("long", fp); |
| 20491 | fclose(fp); |
| 20492 | } |
| 20493 | ${cf_cv_main_return:-return}(0); |
| 20494 | } |
| 20495 | |
| 20496 | _ACEOF |
| 20497 | rm -f conftest$ac_exeext |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20498 | if { (eval echo "$as_me:20498: \"$ac_link\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20499 | (eval $ac_link) 2>&5 |
| 20500 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20501 | echo "$as_me:20501: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20502 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20503 | { (eval echo "$as_me:20503: \"$ac_try\"") >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20504 | (eval $ac_try) 2>&5 |
| 20505 | ac_status=$? |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20506 | echo "$as_me:20506: \$? = $ac_status" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20507 | (exit $ac_status); }; }; then |
| 20508 | cf_cv_type_of_bool=`cat cf_test.out` |
| 20509 | if test -z "$cf_cv_type_of_bool"; then |
| 20510 | cf_cv_type_of_bool=unknown |
| 20511 | fi |
| 20512 | else |
| 20513 | echo "$as_me: program exited with status $ac_status" >&5 |
| 20514 | echo "$as_me: failed program was:" >&5 |
| 20515 | cat conftest.$ac_ext >&5 |
| 20516 | cf_cv_type_of_bool=unknown |
| 20517 | fi |
| 20518 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 20519 | fi |
| 20520 | |
| 20521 | fi |
| 20522 | |
| 20523 | rm -f cf_test.out |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20524 | echo "$as_me:20524: result: $cf_cv_type_of_bool" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20525 | echo "${ECHO_T}$cf_cv_type_of_bool" >&6 |
| 20526 | if test "$cf_cv_type_of_bool" = unknown ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20527 | case .$NCURSES_BOOL in |
| 20528 | (.auto|.) NCURSES_BOOL=unsigned;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20529 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20530 | { echo "$as_me:20530: WARNING: Assuming $NCURSES_BOOL for type of bool" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20531 | echo "$as_me: WARNING: Assuming $NCURSES_BOOL for type of bool" >&2;} |
| 20532 | cf_cv_type_of_bool=$NCURSES_BOOL |
| 20533 | fi |
| 20534 | |
| 20535 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20536 | echo "$as_me:20536: checking for fallback type of bool" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20537 | echo $ECHO_N "checking for fallback type of bool... $ECHO_C" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20538 | case "$host_cpu" in |
| 20539 | (i?86) cf_cv_type_of_bool=char ;; |
| 20540 | (*) cf_cv_type_of_bool=int ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20541 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20542 | echo "$as_me:20542: result: $cf_cv_type_of_bool" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20543 | echo "${ECHO_T}$cf_cv_type_of_bool" >&6 |
| 20544 | fi |
| 20545 | fi |
| 20546 | fi |
| 20547 | |
| 20548 | # If the C compiler did not declare bool, and we did not determine that the C++ |
| 20549 | # compiler does not declare bool, turn on an ifdef in curses.h that makes the |
| 20550 | # ncurses library use the same type as C++ bool. Note that this allows one to |
| 20551 | # specify the type of bool in a configure-script option and postpone |
| 20552 | # integration with the C++ compiler provided that the types are compatible. |
| 20553 | USE_CXX_BOOL=1 |
| 20554 | if test $cf_cv_cc_bool_type = 1 |
| 20555 | then |
| 20556 | # oops: C has a bool. Unlikely, but C++ could differ. |
| 20557 | USE_CXX_BOOL=0 |
| 20558 | elif test $cf_cv_builtin_bool = 0 |
| 20559 | then |
| 20560 | # C++ has no bool |
| 20561 | USE_CXX_BOOL=0 |
| 20562 | else |
| 20563 | # this is the normal case |
| 20564 | USE_CXX_BOOL='defined(__cplusplus)' |
| 20565 | fi |
| 20566 | |
| 20567 | if test -f "${srcdir}/Ada95/Makefile.in" ; then |
| 20568 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20569 | if test "$cf_with_ada" != "no" ; then |
| 20570 | if test "$with_libtool" != "no"; then |
| 20571 | { echo "$as_me:20571: WARNING: libtool does not support Ada - disabling feature" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20572 | echo "$as_me: WARNING: libtool does not support Ada - disabling feature" >&2;} |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20573 | cf_with_ada=no |
| 20574 | fi |
| 20575 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20576 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20577 | if test "$cf_with_ada" != "no" ; then |
| 20578 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20579 | cf_ada_make=gnatmake |
| 20580 | # Extract the first word of "$cf_ada_make", so it can be a program name with args. |
| 20581 | set dummy $cf_ada_make; ac_word=$2 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20582 | echo "$as_me:20582: checking for $ac_word" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20583 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 20584 | if test "${ac_cv_prog_gnat_exists+set}" = set; then |
| 20585 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20586 | else |
| 20587 | if test -n "$gnat_exists"; then |
| 20588 | ac_cv_prog_gnat_exists="$gnat_exists" # Let the user override the test. |
| 20589 | else |
| 20590 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 20591 | ac_dummy="$PATH" |
| 20592 | for ac_dir in $ac_dummy; do |
| 20593 | IFS=$ac_save_IFS |
| 20594 | test -z "$ac_dir" && ac_dir=. |
| 20595 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 20596 | ac_cv_prog_gnat_exists="yes" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20597 | echo "$as_me:20597: found $ac_dir/$ac_word" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20598 | break |
| 20599 | done |
| 20600 | |
| 20601 | test -z "$ac_cv_prog_gnat_exists" && ac_cv_prog_gnat_exists="no" |
| 20602 | fi |
| 20603 | fi |
| 20604 | gnat_exists=$ac_cv_prog_gnat_exists |
| 20605 | if test -n "$gnat_exists"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20606 | echo "$as_me:20606: result: $gnat_exists" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20607 | echo "${ECHO_T}$gnat_exists" >&6 |
| 20608 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20609 | echo "$as_me:20609: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20610 | echo "${ECHO_T}no" >&6 |
| 20611 | fi |
| 20612 | |
| 20613 | if test "$ac_cv_prog_gnat_exists" = no; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20614 | cf_ada_make= |
| 20615 | cf_cv_prog_gnat_correct=no |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20616 | else |
| 20617 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20618 | echo "$as_me:20618: checking for gnat version" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20619 | echo $ECHO_N "checking for gnat version... $ECHO_C" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20620 | cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | \ |
| 20621 | grep '[0-9].[0-9][0-9]*' |\ |
| 20622 | sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'` |
| 20623 | echo "$as_me:20623: result: $cf_gnat_version" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20624 | echo "${ECHO_T}$cf_gnat_version" >&6 |
| 20625 | |
| 20626 | case $cf_gnat_version in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20627 | (3.1[1-9]*|3.[2-9]*|[4-9].*|20[0-9][0-9]) |
| 20628 | cf_cv_prog_gnat_correct=yes |
| 20629 | ;; |
| 20630 | (*) |
| 20631 | { echo "$as_me:20631: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5 |
| 20632 | echo "$as_me: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;} |
| 20633 | cf_cv_prog_gnat_correct=no |
| 20634 | ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20635 | esac |
| 20636 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20637 | # Extract the first word of "m4", so it can be a program name with args. |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20638 | set dummy m4; ac_word=$2 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20639 | echo "$as_me:20639: checking for $ac_word" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20640 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 20641 | if test "${ac_cv_prog_M4_exists+set}" = set; then |
| 20642 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20643 | else |
| 20644 | if test -n "$M4_exists"; then |
| 20645 | ac_cv_prog_M4_exists="$M4_exists" # Let the user override the test. |
| 20646 | else |
| 20647 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 20648 | ac_dummy="$PATH" |
| 20649 | for ac_dir in $ac_dummy; do |
| 20650 | IFS=$ac_save_IFS |
| 20651 | test -z "$ac_dir" && ac_dir=. |
| 20652 | $as_executable_p "$ac_dir/$ac_word" || continue |
| 20653 | ac_cv_prog_M4_exists="yes" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20654 | echo "$as_me:20654: found $ac_dir/$ac_word" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20655 | break |
| 20656 | done |
| 20657 | |
| 20658 | test -z "$ac_cv_prog_M4_exists" && ac_cv_prog_M4_exists="no" |
| 20659 | fi |
| 20660 | fi |
| 20661 | M4_exists=$ac_cv_prog_M4_exists |
| 20662 | if test -n "$M4_exists"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20663 | echo "$as_me:20663: result: $M4_exists" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20664 | echo "${ECHO_T}$M4_exists" >&6 |
| 20665 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20666 | echo "$as_me:20666: result: no" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20667 | echo "${ECHO_T}no" >&6 |
| 20668 | fi |
| 20669 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20670 | if test "$ac_cv_prog_M4_exists" = no; then |
| 20671 | cf_cv_prog_gnat_correct=no |
| 20672 | echo Ada95 binding required program m4 not found. Ada95 binding disabled. |
| 20673 | fi |
| 20674 | if test "$cf_cv_prog_gnat_correct" = yes; then |
| 20675 | echo "$as_me:20675: checking if GNAT works" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20676 | echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6 |
| 20677 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20678 | rm -rf conftest* *~conftest* |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20679 | cat >>conftest.ads <<CF_EOF |
| 20680 | procedure conftest; |
| 20681 | CF_EOF |
| 20682 | cat >>conftest.adb <<CF_EOF |
| 20683 | with Text_IO; |
| 20684 | with GNAT.OS_Lib; |
| 20685 | procedure conftest is |
| 20686 | begin |
| 20687 | Text_IO.Put ("Hello World"); |
| 20688 | Text_IO.New_Line; |
| 20689 | GNAT.OS_Lib.OS_Exit (0); |
| 20690 | end conftest; |
| 20691 | CF_EOF |
| 20692 | if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then |
| 20693 | if ( ./conftest 1>&5 2>&1 ) ; then |
| 20694 | cf_cv_prog_gnat_correct=yes |
| 20695 | else |
| 20696 | cf_cv_prog_gnat_correct=no |
| 20697 | fi |
| 20698 | else |
| 20699 | cf_cv_prog_gnat_correct=no |
| 20700 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20701 | rm -rf conftest* *~conftest* |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20702 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20703 | echo "$as_me:20703: result: $cf_cv_prog_gnat_correct" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20704 | echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20705 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20706 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20707 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20708 | if test "x$cf_cv_prog_gnat_correct" = xyes; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20709 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20710 | ADAFLAGS="$ADAFLAGS -gnatpn" |
| 20711 | |
| 20712 | echo "$as_me:20712: checking optimization options for ADAFLAGS" >&5 |
| 20713 | echo $ECHO_N "checking optimization options for ADAFLAGS... $ECHO_C" >&6 |
| 20714 | case "$CFLAGS" in |
| 20715 | (*-g*) |
| 20716 | |
| 20717 | ADAFLAGS="$ADAFLAGS -g" |
| 20718 | |
| 20719 | ;; |
| 20720 | esac |
| 20721 | case "$CFLAGS" in |
| 20722 | (*-O*) |
| 20723 | cf_O_flag=`echo "$CFLAGS" |sed -e 's/^.*-O/-O/' -e 's/[ ].*//'` |
| 20724 | |
| 20725 | ADAFLAGS="$ADAFLAGS $cf_O_flag" |
| 20726 | |
| 20727 | ;; |
| 20728 | esac |
| 20729 | echo "$as_me:20729: result: $ADAFLAGS" >&5 |
| 20730 | echo "${ECHO_T}$ADAFLAGS" >&6 |
| 20731 | |
| 20732 | echo "$as_me:20732: checking if GNATPREP supports -T option" >&5 |
| 20733 | echo $ECHO_N "checking if GNATPREP supports -T option... $ECHO_C" >&6 |
| 20734 | if test "${cf_cv_gnatprep_opt_t+set}" = set; then |
| 20735 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20736 | else |
| 20737 | |
| 20738 | cf_cv_gnatprep_opt_t=no |
| 20739 | gnatprep -T 2>/dev/null >/dev/null && cf_cv_gnatprep_opt_t=yes |
| 20740 | |
| 20741 | fi |
| 20742 | echo "$as_me:20742: result: $cf_cv_gnatprep_opt_t" >&5 |
| 20743 | echo "${ECHO_T}$cf_cv_gnatprep_opt_t" >&6 |
| 20744 | test "$cf_cv_gnatprep_opt_t" = yes && GNATPREP_OPTS="-T $GNATPREP_OPTS" |
| 20745 | |
| 20746 | echo "$as_me:20746: checking if GNAT supports generics" >&5 |
| 20747 | echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6 |
| 20748 | case $cf_gnat_version in |
| 20749 | (3.[1-9]*|[4-9].*) |
| 20750 | cf_gnat_generics=yes |
| 20751 | ;; |
| 20752 | (*) |
| 20753 | cf_gnat_generics=no |
| 20754 | ;; |
| 20755 | esac |
| 20756 | echo "$as_me:20756: result: $cf_gnat_generics" >&5 |
| 20757 | echo "${ECHO_T}$cf_gnat_generics" >&6 |
| 20758 | |
| 20759 | if test "$cf_gnat_generics" = yes |
| 20760 | then |
| 20761 | cf_compile_generics=generics |
| 20762 | cf_generic_objects="\${GENOBJS}" |
| 20763 | else |
| 20764 | cf_compile_generics= |
| 20765 | cf_generic_objects= |
| 20766 | fi |
| 20767 | |
| 20768 | echo "$as_me:20768: checking if GNAT supports SIGINT" >&5 |
| 20769 | echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6 |
| 20770 | if test "${cf_cv_gnat_sigint+set}" = set; then |
| 20771 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 20772 | else |
| 20773 | |
| 20774 | rm -rf conftest* *~conftest* |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20775 | cat >>conftest.ads <<CF_EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20776 | with Ada.Interrupts.Names; |
| 20777 | |
| 20778 | package ConfTest is |
| 20779 | |
| 20780 | pragma Warnings (Off); -- the next pragma exists since 3.11p |
| 20781 | pragma Unreserve_All_Interrupts; |
| 20782 | pragma Warnings (On); |
| 20783 | |
| 20784 | protected Process is |
| 20785 | procedure Stop; |
| 20786 | function Continue return Boolean; |
| 20787 | pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT); |
| 20788 | private |
| 20789 | Done : Boolean := False; |
| 20790 | end Process; |
| 20791 | |
| 20792 | end ConfTest; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20793 | CF_EOF |
| 20794 | cat >>conftest.adb <<CF_EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20795 | package body ConfTest is |
| 20796 | protected body Process is |
| 20797 | procedure Stop is |
| 20798 | begin |
| 20799 | Done := True; |
| 20800 | end Stop; |
| 20801 | function Continue return Boolean is |
| 20802 | begin |
| 20803 | return not Done; |
| 20804 | end Continue; |
| 20805 | end Process; |
| 20806 | end ConfTest; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20807 | CF_EOF |
| 20808 | if ( $cf_ada_make $ADAFLAGS conftest 1>&5 2>&1 ) ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20809 | cf_cv_gnat_sigint=yes |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20810 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20811 | cf_cv_gnat_sigint=no |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20812 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20813 | rm -rf conftest* *~conftest* |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20814 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20815 | fi |
| 20816 | echo "$as_me:20816: result: $cf_cv_gnat_sigint" >&5 |
| 20817 | echo "${ECHO_T}$cf_cv_gnat_sigint" >&6 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20818 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20819 | if test $cf_cv_gnat_sigint = yes ; then |
| 20820 | USE_GNAT_SIGINT="" |
| 20821 | else |
| 20822 | USE_GNAT_SIGINT="#" |
| 20823 | fi |
| 20824 | |
| 20825 | cf_gnat_libraries=no |
| 20826 | cf_gnat_projects=no |
| 20827 | |
| 20828 | if test "$enable_gnat_projects" != no ; then |
| 20829 | echo "$as_me:20829: checking if GNAT supports project files" >&5 |
| 20830 | echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6 |
| 20831 | case $cf_gnat_version in |
| 20832 | (3.[0-9]*) |
| 20833 | ;; |
| 20834 | (*) |
| 20835 | case $cf_cv_system_name in |
| 20836 | (cygwin*|msys*) |
| 20837 | ;; |
| 20838 | (*) |
| 20839 | mkdir conftest.src conftest.bin conftest.lib |
| 20840 | cd conftest.src |
| 20841 | rm -rf conftest* *~conftest* |
| 20842 | cat >>library.gpr <<CF_EOF |
| 20843 | project Library is |
| 20844 | Kind := External ("LIB_KIND"); |
| 20845 | for Library_Name use "ConfTest"; |
| 20846 | for Object_Dir use "."; |
| 20847 | for Library_ALI_Dir use External("LIBRARY_DIR"); |
| 20848 | for Library_Version use External ("SONAME"); |
| 20849 | for Library_Kind use Kind; |
| 20850 | for Library_Dir use External("BUILD_DIR"); |
| 20851 | Source_Dir := External ("SOURCE_DIR"); |
| 20852 | for Source_Dirs use (Source_Dir); |
| 20853 | end Library; |
| 20854 | CF_EOF |
| 20855 | cat >>confpackage.ads <<CF_EOF |
| 20856 | package ConfPackage is |
| 20857 | procedure conftest; |
| 20858 | end ConfPackage; |
| 20859 | CF_EOF |
| 20860 | cat >>confpackage.adb <<CF_EOF |
| 20861 | with Text_IO; |
| 20862 | package body ConfPackage is |
| 20863 | procedure conftest is |
| 20864 | begin |
| 20865 | Text_IO.Put ("Hello World"); |
| 20866 | Text_IO.New_Line; |
| 20867 | end conftest; |
| 20868 | end ConfPackage; |
| 20869 | CF_EOF |
| 20870 | if ( $cf_ada_make $ADAFLAGS \ |
| 20871 | -Plibrary.gpr \ |
| 20872 | -XBUILD_DIR=`cd ../conftest.bin;pwd` \ |
| 20873 | -XLIBRARY_DIR=`cd ../conftest.lib;pwd` \ |
| 20874 | -XSOURCE_DIR=`pwd` \ |
| 20875 | -XSONAME=libConfTest.so.1 \ |
| 20876 | -XLIB_KIND=static 1>&5 2>&1 ) ; then |
| 20877 | cf_gnat_projects=yes |
| 20878 | fi |
| 20879 | cd .. |
| 20880 | if test -f conftest.lib/confpackage.ali |
| 20881 | then |
| 20882 | cf_gnat_libraries=yes |
| 20883 | fi |
| 20884 | rm -rf conftest* *~conftest* |
| 20885 | ;; |
| 20886 | esac |
| 20887 | ;; |
| 20888 | esac |
| 20889 | echo "$as_me:20889: result: $cf_gnat_projects" >&5 |
| 20890 | echo "${ECHO_T}$cf_gnat_projects" >&6 |
| 20891 | fi # enable_gnat_projects |
| 20892 | |
| 20893 | if test $cf_gnat_projects = yes |
| 20894 | then |
| 20895 | echo "$as_me:20895: checking if GNAT supports libraries" >&5 |
| 20896 | echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6 |
| 20897 | echo "$as_me:20897: result: $cf_gnat_libraries" >&5 |
| 20898 | echo "${ECHO_T}$cf_gnat_libraries" >&6 |
| 20899 | fi |
| 20900 | |
| 20901 | if test "$cf_gnat_projects" = yes |
| 20902 | then |
| 20903 | USE_OLD_MAKERULES="#" |
| 20904 | USE_GNAT_PROJECTS="" |
| 20905 | else |
| 20906 | USE_OLD_MAKERULES="" |
| 20907 | USE_GNAT_PROJECTS="#" |
| 20908 | fi |
| 20909 | |
| 20910 | if test "$cf_gnat_libraries" = yes |
| 20911 | then |
| 20912 | USE_GNAT_LIBRARIES="" |
| 20913 | else |
| 20914 | USE_GNAT_LIBRARIES="#" |
| 20915 | fi |
| 20916 | |
| 20917 | echo "$as_me:20917: checking for ada-compiler" >&5 |
| 20918 | echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20919 | |
| 20920 | # Check whether --with-ada-compiler or --without-ada-compiler was given. |
| 20921 | if test "${with_ada_compiler+set}" = set; then |
| 20922 | withval="$with_ada_compiler" |
| 20923 | cf_ada_compiler=$withval |
| 20924 | else |
| 20925 | cf_ada_compiler=gnatmake |
| 20926 | fi; |
| 20927 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20928 | echo "$as_me:20928: result: $cf_ada_compiler" >&5 |
| 20929 | echo "${ECHO_T}$cf_ada_compiler" >&6 |
| 20930 | |
| 20931 | cf_ada_package=terminal_interface |
| 20932 | |
| 20933 | echo "$as_me:20933: checking for ada-include" >&5 |
| 20934 | echo $ECHO_N "checking for ada-include... $ECHO_C" >&6 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20935 | |
| 20936 | # Check whether --with-ada-include or --without-ada-include was given. |
| 20937 | if test "${with_ada_include+set}" = set; then |
| 20938 | withval="$with_ada_include" |
| 20939 | |
| 20940 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20941 | withval="${ADA_INCLUDE:-$prefix/share/ada/adainclude}" |
| 20942 | fi; if test -n "$prefix/share/ada/adainclude" ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20943 | |
| 20944 | if test "x$prefix" != xNONE; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20945 | cf_path_syntax="$prefix" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20946 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20947 | cf_path_syntax="$ac_default_prefix" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20948 | fi |
| 20949 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20950 | case ".$withval" in |
| 20951 | (.\$\(*\)*|.\'*\'*) |
| 20952 | ;; |
| 20953 | (..|./*|.\\*) |
| 20954 | ;; |
| 20955 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 20956 | ;; |
| 20957 | (.\${*prefix}*|.\${*dir}*) |
| 20958 | eval withval="$withval" |
| 20959 | case ".$withval" in |
| 20960 | (.NONE/*) |
| 20961 | withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` |
| 20962 | ;; |
| 20963 | esac |
| 20964 | ;; |
| 20965 | (.no|.NONE/*) |
| 20966 | withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` |
| 20967 | ;; |
| 20968 | (*) |
| 20969 | { { echo "$as_me:20969: error: expected a pathname, not \"$withval\"" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20970 | echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;} |
| 20971 | { (exit 1); exit 1; }; } |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20972 | ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20973 | esac |
| 20974 | |
| 20975 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20976 | eval ADA_INCLUDE="$withval" |
| 20977 | |
| 20978 | echo "$as_me:20978: result: $ADA_INCLUDE" >&5 |
| 20979 | echo "${ECHO_T}$ADA_INCLUDE" >&6 |
| 20980 | |
| 20981 | echo "$as_me:20981: checking for ada-objects" >&5 |
| 20982 | echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20983 | |
| 20984 | # Check whether --with-ada-objects or --without-ada-objects was given. |
| 20985 | if test "${with_ada_objects+set}" = set; then |
| 20986 | withval="$with_ada_objects" |
| 20987 | |
| 20988 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20989 | withval="${ADA_OBJECTS:-$prefix/lib/ada/adalib}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20990 | fi; if test -n "$prefix/lib/ada/adalib" ; then |
| 20991 | |
| 20992 | if test "x$prefix" != xNONE; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20993 | cf_path_syntax="$prefix" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20994 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20995 | cf_path_syntax="$ac_default_prefix" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 20996 | fi |
| 20997 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 20998 | case ".$withval" in |
| 20999 | (.\$\(*\)*|.\'*\'*) |
| 21000 | ;; |
| 21001 | (..|./*|.\\*) |
| 21002 | ;; |
| 21003 | (.[a-zA-Z]:[\\/]*) # OS/2 EMX |
| 21004 | ;; |
| 21005 | (.\${*prefix}*|.\${*dir}*) |
| 21006 | eval withval="$withval" |
| 21007 | case ".$withval" in |
| 21008 | (.NONE/*) |
| 21009 | withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` |
| 21010 | ;; |
| 21011 | esac |
| 21012 | ;; |
| 21013 | (.no|.NONE/*) |
| 21014 | withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%` |
| 21015 | ;; |
| 21016 | (*) |
| 21017 | { { echo "$as_me:21017: error: expected a pathname, not \"$withval\"" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21018 | echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;} |
| 21019 | { (exit 1); exit 1; }; } |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21020 | ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21021 | esac |
| 21022 | |
| 21023 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21024 | eval ADA_OBJECTS="$withval" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21025 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21026 | echo "$as_me:21026: result: $ADA_OBJECTS" >&5 |
| 21027 | echo "${ECHO_T}$ADA_OBJECTS" >&6 |
| 21028 | |
| 21029 | echo "$as_me:21029: checking if an Ada95 shared-library should be built" >&5 |
| 21030 | echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6 |
| 21031 | |
| 21032 | # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given. |
| 21033 | if test "${with_ada_sharedlib+set}" = set; then |
| 21034 | withval="$with_ada_sharedlib" |
| 21035 | with_ada_sharedlib=$withval |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21036 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21037 | with_ada_sharedlib=no |
| 21038 | fi; |
| 21039 | echo "$as_me:21039: result: $with_ada_sharedlib" >&5 |
| 21040 | echo "${ECHO_T}$with_ada_sharedlib" >&6 |
| 21041 | |
| 21042 | ADA_SHAREDLIB='lib$(LIB_NAME).so.1' |
| 21043 | MAKE_ADA_SHAREDLIB="#" |
| 21044 | |
| 21045 | if test "x$with_ada_sharedlib" != xno |
| 21046 | then |
| 21047 | MAKE_ADA_SHAREDLIB= |
| 21048 | if test "x$with_ada_sharedlib" != xyes |
| 21049 | then |
| 21050 | ADA_SHAREDLIB="$with_ada_sharedlib" |
| 21051 | fi |
| 21052 | fi |
| 21053 | |
| 21054 | fi |
| 21055 | fi |
| 21056 | else |
| 21057 | cf_with_ada=no |
| 21058 | fi |
| 21059 | |
| 21060 | # do this "late" to avoid conflict with header-checks |
| 21061 | if test "x$with_widec" = xyes ; then |
| 21062 | echo "$as_me:21062: checking for wchar_t" >&5 |
| 21063 | echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6 |
| 21064 | if test "${ac_cv_type_wchar_t+set}" = set; then |
| 21065 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 21066 | else |
| 21067 | cat >conftest.$ac_ext <<_ACEOF |
| 21068 | #line 21068 "configure" |
| 21069 | #include "confdefs.h" |
| 21070 | $ac_includes_default |
| 21071 | int |
| 21072 | main () |
| 21073 | { |
| 21074 | if ((wchar_t *) 0) |
| 21075 | return 0; |
| 21076 | if (sizeof (wchar_t)) |
| 21077 | return 0; |
| 21078 | ; |
| 21079 | return 0; |
| 21080 | } |
| 21081 | _ACEOF |
| 21082 | rm -f conftest.$ac_objext |
| 21083 | if { (eval echo "$as_me:21083: \"$ac_compile\"") >&5 |
| 21084 | (eval $ac_compile) 2>&5 |
| 21085 | ac_status=$? |
| 21086 | echo "$as_me:21086: \$? = $ac_status" >&5 |
| 21087 | (exit $ac_status); } && |
| 21088 | { ac_try='test -s conftest.$ac_objext' |
| 21089 | { (eval echo "$as_me:21089: \"$ac_try\"") >&5 |
| 21090 | (eval $ac_try) 2>&5 |
| 21091 | ac_status=$? |
| 21092 | echo "$as_me:21092: \$? = $ac_status" >&5 |
| 21093 | (exit $ac_status); }; }; then |
| 21094 | ac_cv_type_wchar_t=yes |
| 21095 | else |
| 21096 | echo "$as_me: failed program was:" >&5 |
| 21097 | cat conftest.$ac_ext >&5 |
| 21098 | ac_cv_type_wchar_t=no |
| 21099 | fi |
| 21100 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 21101 | fi |
| 21102 | echo "$as_me:21102: result: $ac_cv_type_wchar_t" >&5 |
| 21103 | echo "${ECHO_T}$ac_cv_type_wchar_t" >&6 |
| 21104 | |
| 21105 | echo "$as_me:21105: checking size of wchar_t" >&5 |
| 21106 | echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6 |
| 21107 | if test "${ac_cv_sizeof_wchar_t+set}" = set; then |
| 21108 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 21109 | else |
| 21110 | if test "$ac_cv_type_wchar_t" = yes; then |
| 21111 | if test "$cross_compiling" = yes; then |
| 21112 | # Depending upon the size, compute the lo and hi bounds. |
| 21113 | cat >conftest.$ac_ext <<_ACEOF |
| 21114 | #line 21114 "configure" |
| 21115 | #include "confdefs.h" |
| 21116 | $ac_includes_default |
| 21117 | int |
| 21118 | main () |
| 21119 | { |
| 21120 | int _array_ [1 - 2 * !((sizeof (wchar_t)) >= 0)] |
| 21121 | ; |
| 21122 | return 0; |
| 21123 | } |
| 21124 | _ACEOF |
| 21125 | rm -f conftest.$ac_objext |
| 21126 | if { (eval echo "$as_me:21126: \"$ac_compile\"") >&5 |
| 21127 | (eval $ac_compile) 2>&5 |
| 21128 | ac_status=$? |
| 21129 | echo "$as_me:21129: \$? = $ac_status" >&5 |
| 21130 | (exit $ac_status); } && |
| 21131 | { ac_try='test -s conftest.$ac_objext' |
| 21132 | { (eval echo "$as_me:21132: \"$ac_try\"") >&5 |
| 21133 | (eval $ac_try) 2>&5 |
| 21134 | ac_status=$? |
| 21135 | echo "$as_me:21135: \$? = $ac_status" >&5 |
| 21136 | (exit $ac_status); }; }; then |
| 21137 | ac_lo=0 ac_mid=0 |
| 21138 | while :; do |
| 21139 | cat >conftest.$ac_ext <<_ACEOF |
| 21140 | #line 21140 "configure" |
| 21141 | #include "confdefs.h" |
| 21142 | $ac_includes_default |
| 21143 | int |
| 21144 | main () |
| 21145 | { |
| 21146 | int _array_ [1 - 2 * !((sizeof (wchar_t)) <= $ac_mid)] |
| 21147 | ; |
| 21148 | return 0; |
| 21149 | } |
| 21150 | _ACEOF |
| 21151 | rm -f conftest.$ac_objext |
| 21152 | if { (eval echo "$as_me:21152: \"$ac_compile\"") >&5 |
| 21153 | (eval $ac_compile) 2>&5 |
| 21154 | ac_status=$? |
| 21155 | echo "$as_me:21155: \$? = $ac_status" >&5 |
| 21156 | (exit $ac_status); } && |
| 21157 | { ac_try='test -s conftest.$ac_objext' |
| 21158 | { (eval echo "$as_me:21158: \"$ac_try\"") >&5 |
| 21159 | (eval $ac_try) 2>&5 |
| 21160 | ac_status=$? |
| 21161 | echo "$as_me:21161: \$? = $ac_status" >&5 |
| 21162 | (exit $ac_status); }; }; then |
| 21163 | ac_hi=$ac_mid; break |
| 21164 | else |
| 21165 | echo "$as_me: failed program was:" >&5 |
| 21166 | cat conftest.$ac_ext >&5 |
| 21167 | ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1` |
| 21168 | fi |
| 21169 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 21170 | done |
| 21171 | else |
| 21172 | echo "$as_me: failed program was:" >&5 |
| 21173 | cat conftest.$ac_ext >&5 |
| 21174 | ac_hi=-1 ac_mid=-1 |
| 21175 | while :; do |
| 21176 | cat >conftest.$ac_ext <<_ACEOF |
| 21177 | #line 21177 "configure" |
| 21178 | #include "confdefs.h" |
| 21179 | $ac_includes_default |
| 21180 | int |
| 21181 | main () |
| 21182 | { |
| 21183 | int _array_ [1 - 2 * !((sizeof (wchar_t)) >= $ac_mid)] |
| 21184 | ; |
| 21185 | return 0; |
| 21186 | } |
| 21187 | _ACEOF |
| 21188 | rm -f conftest.$ac_objext |
| 21189 | if { (eval echo "$as_me:21189: \"$ac_compile\"") >&5 |
| 21190 | (eval $ac_compile) 2>&5 |
| 21191 | ac_status=$? |
| 21192 | echo "$as_me:21192: \$? = $ac_status" >&5 |
| 21193 | (exit $ac_status); } && |
| 21194 | { ac_try='test -s conftest.$ac_objext' |
| 21195 | { (eval echo "$as_me:21195: \"$ac_try\"") >&5 |
| 21196 | (eval $ac_try) 2>&5 |
| 21197 | ac_status=$? |
| 21198 | echo "$as_me:21198: \$? = $ac_status" >&5 |
| 21199 | (exit $ac_status); }; }; then |
| 21200 | ac_lo=$ac_mid; break |
| 21201 | else |
| 21202 | echo "$as_me: failed program was:" >&5 |
| 21203 | cat conftest.$ac_ext >&5 |
| 21204 | ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid` |
| 21205 | fi |
| 21206 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 21207 | done |
| 21208 | fi |
| 21209 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 21210 | # Binary search between lo and hi bounds. |
| 21211 | while test "x$ac_lo" != "x$ac_hi"; do |
| 21212 | ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` |
| 21213 | cat >conftest.$ac_ext <<_ACEOF |
| 21214 | #line 21214 "configure" |
| 21215 | #include "confdefs.h" |
| 21216 | $ac_includes_default |
| 21217 | int |
| 21218 | main () |
| 21219 | { |
| 21220 | int _array_ [1 - 2 * !((sizeof (wchar_t)) <= $ac_mid)] |
| 21221 | ; |
| 21222 | return 0; |
| 21223 | } |
| 21224 | _ACEOF |
| 21225 | rm -f conftest.$ac_objext |
| 21226 | if { (eval echo "$as_me:21226: \"$ac_compile\"") >&5 |
| 21227 | (eval $ac_compile) 2>&5 |
| 21228 | ac_status=$? |
| 21229 | echo "$as_me:21229: \$? = $ac_status" >&5 |
| 21230 | (exit $ac_status); } && |
| 21231 | { ac_try='test -s conftest.$ac_objext' |
| 21232 | { (eval echo "$as_me:21232: \"$ac_try\"") >&5 |
| 21233 | (eval $ac_try) 2>&5 |
| 21234 | ac_status=$? |
| 21235 | echo "$as_me:21235: \$? = $ac_status" >&5 |
| 21236 | (exit $ac_status); }; }; then |
| 21237 | ac_hi=$ac_mid |
| 21238 | else |
| 21239 | echo "$as_me: failed program was:" >&5 |
| 21240 | cat conftest.$ac_ext >&5 |
| 21241 | ac_lo=`expr $ac_mid + 1` |
| 21242 | fi |
| 21243 | rm -f conftest.$ac_objext conftest.$ac_ext |
| 21244 | done |
| 21245 | ac_cv_sizeof_wchar_t=$ac_lo |
| 21246 | else |
| 21247 | if test "$cross_compiling" = yes; then |
| 21248 | { { echo "$as_me:21248: error: cannot run test program while cross compiling" >&5 |
| 21249 | echo "$as_me: error: cannot run test program while cross compiling" >&2;} |
| 21250 | { (exit 1); exit 1; }; } |
| 21251 | else |
| 21252 | cat >conftest.$ac_ext <<_ACEOF |
| 21253 | #line 21253 "configure" |
| 21254 | #include "confdefs.h" |
| 21255 | $ac_includes_default |
| 21256 | int |
| 21257 | main () |
| 21258 | { |
| 21259 | FILE *f = fopen ("conftest.val", "w"); |
| 21260 | if (!f) |
| 21261 | $ac_main_return (1); |
| 21262 | fprintf (f, "%d", (sizeof (wchar_t))); |
| 21263 | fclose (f); |
| 21264 | ; |
| 21265 | return 0; |
| 21266 | } |
| 21267 | _ACEOF |
| 21268 | rm -f conftest$ac_exeext |
| 21269 | if { (eval echo "$as_me:21269: \"$ac_link\"") >&5 |
| 21270 | (eval $ac_link) 2>&5 |
| 21271 | ac_status=$? |
| 21272 | echo "$as_me:21272: \$? = $ac_status" >&5 |
| 21273 | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
| 21274 | { (eval echo "$as_me:21274: \"$ac_try\"") >&5 |
| 21275 | (eval $ac_try) 2>&5 |
| 21276 | ac_status=$? |
| 21277 | echo "$as_me:21277: \$? = $ac_status" >&5 |
| 21278 | (exit $ac_status); }; }; then |
| 21279 | ac_cv_sizeof_wchar_t=`cat conftest.val` |
| 21280 | else |
| 21281 | echo "$as_me: program exited with status $ac_status" >&5 |
| 21282 | echo "$as_me: failed program was:" >&5 |
| 21283 | cat conftest.$ac_ext >&5 |
| 21284 | fi |
| 21285 | rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
| 21286 | fi |
| 21287 | fi |
| 21288 | rm -f conftest.val |
| 21289 | else |
| 21290 | ac_cv_sizeof_wchar_t=0 |
| 21291 | fi |
| 21292 | fi |
| 21293 | echo "$as_me:21293: result: $ac_cv_sizeof_wchar_t" >&5 |
| 21294 | echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6 |
| 21295 | cat >>confdefs.h <<EOF |
| 21296 | #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t |
| 21297 | EOF |
| 21298 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21299 | fi |
| 21300 | |
| 21301 | ### Construct the ncurses library-subsets, if any, from this set of keywords: |
| 21302 | ### none, base, ext_funcs, ext_tinfo, ticlib, termlib, widechar |
| 21303 | ### |
| 21304 | ### ticlib modules may be a separate library, otherwise contained in termlib. |
| 21305 | ### termlib modules may be a separate library, otherwise contained in ncurses. |
| 21306 | ### |
| 21307 | ### The of "+" or " " between the tokens controls the way the script |
| 21308 | ### chooses to split module lists into libraries. |
| 21309 | ### |
| 21310 | ### (see CF_LIB_RULES). |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21311 | echo "$as_me:21311: checking for library subsets" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21312 | echo $ECHO_N "checking for library subsets... $ECHO_C" >&6 |
| 21313 | LIB_SUBSETS= |
| 21314 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21315 | if test "x$cf_with_progs" = xyes || test "$with_ticlib" != no || test "$with_termcap" != no; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21316 | LIB_SUBSETS="${LIB_SUBSETS}ticlib" |
| 21317 | if test "$with_ticlib" != no ; then |
| 21318 | LIB_SUBSETS="${LIB_SUBSETS} " |
| 21319 | else |
| 21320 | LIB_SUBSETS="${LIB_SUBSETS}+" |
| 21321 | fi |
| 21322 | fi |
| 21323 | |
| 21324 | LIB_SUBSETS="${LIB_SUBSETS}termlib" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21325 | test "x$with_ext_funcs" = xyes && LIB_SUBSETS="${LIB_SUBSETS}+ext_tinfo" |
| 21326 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21327 | if test "$with_termlib" != no ; then |
| 21328 | LIB_SUBSETS="${LIB_SUBSETS} " |
| 21329 | else |
| 21330 | LIB_SUBSETS="${LIB_SUBSETS}+" |
| 21331 | fi |
| 21332 | |
| 21333 | LIB_SUBSETS="${LIB_SUBSETS}base" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21334 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21335 | # Most term-driver calls are to tinfo, but some like init_pair are to the |
| 21336 | # base library (so it resides in base). |
| 21337 | if test "$with_term_driver" != no ; then |
| 21338 | LIB_SUBSETS="${LIB_SUBSETS}+port_drivers" |
| 21339 | case $cf_cv_system_name in |
| 21340 | (*mingw32*|*mingw64*) |
| 21341 | LIB_SUBSETS="${LIB_SUBSETS}+port_tinfo+port_win32con" |
| 21342 | CPPFLAGS="$CPPFLAGS -DUSE_WIN32CON_DRIVER" |
| 21343 | ;; |
| 21344 | (*) |
| 21345 | LIB_SUBSETS="${LIB_SUBSETS}+port_tinfo" |
| 21346 | ;; |
| 21347 | esac |
| 21348 | fi |
| 21349 | |
| 21350 | test "x$with_widec" = xyes && LIB_SUBSETS="${LIB_SUBSETS}+widechar" |
| 21351 | test "x$with_ext_funcs" = xyes && LIB_SUBSETS="${LIB_SUBSETS}+ext_funcs" |
| 21352 | |
| 21353 | echo "$as_me:21353: result: $LIB_SUBSETS" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21354 | echo "${ECHO_T}$LIB_SUBSETS" >&6 |
| 21355 | |
| 21356 | ### Construct the list of include-directories to be generated |
| 21357 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21358 | if test "$srcdir" != "."; then |
| 21359 | CPPFLAGS="-I\${srcdir}/../include $CPPFLAGS" |
| 21360 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21361 | CPPFLAGS="-I../include $CPPFLAGS" |
| 21362 | if test "$srcdir" != "."; then |
| 21363 | CPPFLAGS="-I\${srcdir} $CPPFLAGS" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21364 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21365 | CPPFLAGS="-I. $CPPFLAGS" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21366 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21367 | ACPPFLAGS="-I. -I../include -I../../include $ACPPFLAGS" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21368 | if test "$srcdir" != "."; then |
| 21369 | ACPPFLAGS="-I\${srcdir}/../../include $ACPPFLAGS" |
| 21370 | fi |
| 21371 | if test "$GCC" != yes; then |
| 21372 | ACPPFLAGS="$ACPPFLAGS -I\${includedir}" |
| 21373 | elif test "$includedir" != "/usr/include"; then |
| 21374 | if test "$includedir" = '${prefix}/include' ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21375 | if test x$prefix != x/usr ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21376 | ACPPFLAGS="$ACPPFLAGS -I\${includedir}" |
| 21377 | fi |
| 21378 | else |
| 21379 | ACPPFLAGS="$ACPPFLAGS -I\${includedir}" |
| 21380 | fi |
| 21381 | fi |
| 21382 | |
| 21383 | ### Build up pieces for makefile rules |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21384 | echo "$as_me:21384: checking default library suffix" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21385 | echo $ECHO_N "checking default library suffix... $ECHO_C" >&6 |
| 21386 | |
| 21387 | case $DFT_LWR_MODEL in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21388 | (libtool) DFT_ARG_SUFFIX='' ;; |
| 21389 | (normal) DFT_ARG_SUFFIX='' ;; |
| 21390 | (debug) DFT_ARG_SUFFIX='_g' ;; |
| 21391 | (profile) DFT_ARG_SUFFIX='_p' ;; |
| 21392 | (shared) DFT_ARG_SUFFIX='' ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21393 | esac |
| 21394 | test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21395 | echo "$as_me:21395: result: $DFT_ARG_SUFFIX" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21396 | echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6 |
| 21397 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21398 | echo "$as_me:21398: checking default library-dependency suffix" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21399 | echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6 |
| 21400 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21401 | case X$DFT_LWR_MODEL in |
| 21402 | (Xlibtool) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21403 | DFT_LIB_SUFFIX='.la' |
| 21404 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21405 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21406 | (Xdebug) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21407 | DFT_LIB_SUFFIX='_g.a' |
| 21408 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21409 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21410 | (Xprofile) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21411 | DFT_LIB_SUFFIX='_p.a' |
| 21412 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21413 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21414 | (Xshared) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21415 | case $cf_cv_system_name in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21416 | (aix[5-7]*) |
| 21417 | DFT_LIB_SUFFIX='.so' |
| 21418 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21419 | ;; |
| 21420 | (cygwin*|msys*|mingw*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21421 | DFT_LIB_SUFFIX='.dll' |
| 21422 | DFT_DEP_SUFFIX='.dll.a' |
| 21423 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21424 | (darwin*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21425 | DFT_LIB_SUFFIX='.dylib' |
| 21426 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21427 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21428 | (hpux*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21429 | case $target in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21430 | (ia64*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21431 | DFT_LIB_SUFFIX='.so' |
| 21432 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21433 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21434 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21435 | DFT_LIB_SUFFIX='.sl' |
| 21436 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21437 | ;; |
| 21438 | esac |
| 21439 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21440 | (*) |
| 21441 | DFT_LIB_SUFFIX='.so' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21442 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21443 | ;; |
| 21444 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21445 | ;; |
| 21446 | (*) |
| 21447 | DFT_LIB_SUFFIX='.a' |
| 21448 | DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX |
| 21449 | ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21450 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21451 | if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}" |
| 21452 | then |
| 21453 | DFT_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_LIB_SUFFIX}" |
| 21454 | DFT_DEP_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${DFT_DEP_SUFFIX}" |
| 21455 | fi |
| 21456 | echo "$as_me:21456: result: $DFT_DEP_SUFFIX" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21457 | echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6 |
| 21458 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21459 | echo "$as_me:21459: checking default object directory" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21460 | echo $ECHO_N "checking default object directory... $ECHO_C" >&6 |
| 21461 | |
| 21462 | case $DFT_LWR_MODEL in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21463 | (libtool) DFT_OBJ_SUBDIR='obj_lo' ;; |
| 21464 | (normal) DFT_OBJ_SUBDIR='objects' ;; |
| 21465 | (debug) DFT_OBJ_SUBDIR='obj_g' ;; |
| 21466 | (profile) DFT_OBJ_SUBDIR='obj_p' ;; |
| 21467 | (shared) |
| 21468 | case $cf_cv_system_name in |
| 21469 | (cygwin|msys) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21470 | DFT_OBJ_SUBDIR='objects' ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21471 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21472 | DFT_OBJ_SUBDIR='obj_s' ;; |
| 21473 | esac |
| 21474 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21475 | echo "$as_me:21475: result: $DFT_OBJ_SUBDIR" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21476 | echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6 |
| 21477 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21478 | if test "x$cf_with_cxx" = xyes ; then |
| 21479 | echo "$as_me:21479: checking c++ library-dependency suffix" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21480 | echo $ECHO_N "checking c++ library-dependency suffix... $ECHO_C" >&6 |
| 21481 | if test "$with_libtool" != "no"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21482 | # libtool thinks it can make c++ shared libraries (perhaps only g++) |
| 21483 | CXX_LIB_SUFFIX=$DFT_DEP_SUFFIX |
| 21484 | elif test "$with_shared_cxx" != "no"; then |
| 21485 | # also for g++ users... |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21486 | CXX_LIB_SUFFIX=$DFT_DEP_SUFFIX |
| 21487 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21488 | # we normally make a static library because C/C++ library rules differ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21489 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21490 | case Xnormal in |
| 21491 | (Xlibtool) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21492 | CXX_LIB_SUFFIX='.la' |
| 21493 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21494 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21495 | (Xdebug) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21496 | CXX_LIB_SUFFIX='_g.a' |
| 21497 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21498 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21499 | (Xprofile) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21500 | CXX_LIB_SUFFIX='_p.a' |
| 21501 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21502 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21503 | (Xshared) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21504 | case $cf_cv_system_name in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21505 | (aix[5-7]*) |
| 21506 | CXX_LIB_SUFFIX='.so' |
| 21507 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21508 | ;; |
| 21509 | (cygwin*|msys*|mingw*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21510 | CXX_LIB_SUFFIX='.dll' |
| 21511 | CXX_DEP_SUFFIX='.dll.a' |
| 21512 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21513 | (darwin*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21514 | CXX_LIB_SUFFIX='.dylib' |
| 21515 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21516 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21517 | (hpux*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21518 | case $target in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21519 | (ia64*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21520 | CXX_LIB_SUFFIX='.so' |
| 21521 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21522 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21523 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21524 | CXX_LIB_SUFFIX='.sl' |
| 21525 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21526 | ;; |
| 21527 | esac |
| 21528 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21529 | (*) |
| 21530 | CXX_LIB_SUFFIX='.so' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21531 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21532 | ;; |
| 21533 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21534 | ;; |
| 21535 | (*) |
| 21536 | CXX_LIB_SUFFIX='.a' |
| 21537 | CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX |
| 21538 | ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21539 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21540 | if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}" |
| 21541 | then |
| 21542 | CXX_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${CXX_LIB_SUFFIX}" |
| 21543 | CXX_DEP_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}${CXX_DEP_SUFFIX}" |
| 21544 | fi |
| 21545 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21546 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21547 | echo "$as_me:21547: result: $CXX_LIB_SUFFIX" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21548 | echo "${ECHO_T}$CXX_LIB_SUFFIX" >&6 |
| 21549 | |
| 21550 | fi |
| 21551 | |
| 21552 | # do not want -ldl in build except as needed for -lncurses dependency |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21553 | if test "x$with_dlsym" = xyes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21554 | if test $DFT_LWR_MODEL = shared || \ |
| 21555 | test $DFT_LWR_MODEL = libtool ; then |
| 21556 | |
| 21557 | # remove dl library from $LIBS |
| 21558 | LIBS=`echo "$LIBS" | sed -e 's/-ldl[ ]//g' -e 's/-ldl$//'` |
| 21559 | |
| 21560 | fi |
| 21561 | fi |
| 21562 | ### Set up low-level terminfo dependencies for makefiles. |
| 21563 | |
| 21564 | # TICS_LIST and TINFO_LIST are needed to build libtic.so and libterm.so, but |
| 21565 | # do not need libdl |
| 21566 | TICS_LIST= |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21567 | if test "x$with_dlsym" = xyes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21568 | |
| 21569 | # remove dl library from $SHLIB_LIST |
| 21570 | TINFO_LIST=`echo "$SHLIB_LIST" | sed -e 's/-ldl[ ]//g' -e 's/-ldl$//'` |
| 21571 | |
| 21572 | fi |
| 21573 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21574 | USE_ARG_SUFFIX="${DFT_ARG_SUFFIX}${EXTRA_SUFFIX}" |
| 21575 | USE_LIB_SUFFIX="${LIB_SUFFIX}${EXTRA_SUFFIX}" |
| 21576 | USE_CFG_SUFFIX=${DFT_ARG_SUFFIX}${cf_cv_abi_version} |
| 21577 | if test -n "$EXTRA_SUFFIX" && test "x$EXTRA_SUFFIX" != "x${cf_cv_abi_version}" |
| 21578 | then |
| 21579 | USE_CFG_SUFFIX="${USE_CFG_SUFFIX}${EXTRA_SUFFIX}" |
| 21580 | fi |
| 21581 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21582 | if test "$with_ticlib" != no ; then |
| 21583 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21584 | if test "x$with_ticlib" != xyes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21585 | TICS_NAME=$with_ticlib |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21586 | TICS_ARG_SUFFIX="${with_ticlib}`echo ${USE_ARG_SUFFIX}|sed -e "s/^${LIB_SUFFIX}//"`" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21587 | TICS_DEP_SUFFIX="${with_ticlib}`echo ${DFT_DEP_SUFFIX}|sed -e "s/^${LIB_SUFFIX}//"`" |
| 21588 | TICS_LIB_SUFFIX="${with_ticlib}" |
| 21589 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21590 | TICS_ARG_SUFFIX="${TICS_NAME}${USE_ARG_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21591 | TICS_DEP_SUFFIX="${TICS_NAME}${DFT_DEP_SUFFIX}" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21592 | TICS_LIB_SUFFIX="${TICS_NAME}${USE_LIB_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21593 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21594 | TICS_LDFLAGS="-L${LIB_DIR}" |
| 21595 | TICS_LIBS="-l${TICS_LIB_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21596 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21597 | TICS_LDFLAGS="-L${LIB_DIR}" |
| 21598 | TICS_LIBS="-l${LIB_NAME}${USE_ARG_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21599 | fi |
| 21600 | |
| 21601 | if test "$with_termlib" != no ; then |
| 21602 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21603 | if test "x$with_termlib" != xyes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21604 | TINFO_NAME=$with_termlib |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21605 | TINFO_SUFFIX="`echo ${DFT_LIB_SUFFIX}|sed -e "s/^${USE_LIB_SUFFIX}//"`" |
| 21606 | TINFO_ARG_SUFFIX="${with_termlib}`echo ${USE_ARG_SUFFIX}|sed -e "s/^${LIB_SUFFIX}//"`" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21607 | TINFO_DEP_SUFFIX="${with_termlib}`echo ${DFT_DEP_SUFFIX}|sed -e "s/^${LIB_SUFFIX}//"`" |
| 21608 | TINFO_LIB_SUFFIX="${with_termlib}" |
| 21609 | else |
| 21610 | TINFO_SUFFIX=${DFT_LIB_SUFFIX} |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21611 | TINFO_ARG_SUFFIX="${TINFO_NAME}${USE_ARG_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21612 | TINFO_DEP_SUFFIX="${TINFO_NAME}${DFT_DEP_SUFFIX}" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21613 | TINFO_LIB_SUFFIX="${TINFO_NAME}${USE_LIB_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21614 | fi |
| 21615 | |
| 21616 | TEST_DEPS="${LIB_DIR}/${LIB_PREFIX}${TINFO_DEP_SUFFIX}" |
| 21617 | TEST_DEP2="${LIB_2ND}/${LIB_PREFIX}${TINFO_DEP_SUFFIX}" |
| 21618 | if test "$DFT_LWR_MODEL" = "libtool"; then |
| 21619 | TEST_ARGS="${TEST_DEPS}" |
| 21620 | TEST_ARG2="${TEST_DEP2}" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21621 | TINFO_LDFLAGS="-L${LIB_DIR}" |
| 21622 | TINFO_LIBS="$TEST_ARGS" |
| 21623 | TICS_LIST="$SHLIB_LIST $TEST_ARGS" |
| 21624 | SHLIB_LIST="${SHLIB_LIST} $TEST_ARGS" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21625 | else |
| 21626 | TEST_ARGS="-l${TINFO_ARG_SUFFIX}" |
| 21627 | TEST_ARG2="-l${TINFO_ARG_SUFFIX}" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21628 | if test "x$with_term_driver" != xno ; then |
| 21629 | TICS_LIST="$SHLIB_LIST -l${LIB_NAME}${USE_ARG_SUFFIX}" |
| 21630 | TICS_LIBS="$TICS_LIBS -l${LIB_NAME}${USE_ARG_SUFFIX}" |
| 21631 | TINFO_LIBS="-l${LIB_NAME}${USE_ARG_SUFFIX} $TEST_ARGS" |
| 21632 | else |
| 21633 | TICS_LIST="$SHLIB_LIST -l${TINFO_LIB_SUFFIX}" |
| 21634 | TINFO_LIBS="$TEST_ARGS" |
| 21635 | fi |
| 21636 | TINFO_LDFLAGS="-L${LIB_DIR}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21637 | SHLIB_LIST="$SHLIB_LIST -l${TINFO_LIB_SUFFIX}" |
| 21638 | fi |
| 21639 | else |
| 21640 | # the next lines are needed for linking libtic over libncurses |
| 21641 | TINFO_NAME=${LIB_NAME} |
| 21642 | TINFO_SUFFIX=${DFT_LIB_SUFFIX} |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21643 | TINFO_ARG_SUFFIX=${LIB_NAME}${USE_ARG_SUFFIX} |
| 21644 | if test "x$with_tic_depends" = xyes ; then |
| 21645 | TICS_LIST="$SHLIB_LIST -l${LIB_NAME}${USE_ARG_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21646 | else |
| 21647 | TICS_LIST="$SHLIB_LIST" |
| 21648 | fi |
| 21649 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21650 | TINFO_LDFLAGS="-L${LIB_DIR}" |
| 21651 | TINFO_LIBS="-l${LIB_NAME}${USE_ARG_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21652 | fi |
| 21653 | |
| 21654 | if test "$DFT_LWR_MODEL" = shared ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21655 | case $cf_cv_system_name in |
| 21656 | (cygwin*|msys*) |
| 21657 | # "lib" files have ".dll.a" suffix, "cyg"or "msys-" files have ".dll" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21658 | TINFO_SUFFIX=.dll |
| 21659 | ;; |
| 21660 | esac |
| 21661 | fi |
| 21662 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21663 | if test "x$with_dlsym" = xyes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21664 | |
| 21665 | # remove dl library from $TICS_LIST |
| 21666 | TICS_LIST=`echo "$TICS_LIST" | sed -e 's/-ldl[ ]//g' -e 's/-ldl$//'` |
| 21667 | |
| 21668 | fi |
| 21669 | |
| 21670 | if test "$DFT_LWR_MODEL" = "libtool"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21671 | OBJEXT=lo |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21672 | fi |
| 21673 | |
| 21674 | # needed for Ada95 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21675 | TINFO_LDFLAGS2=`echo "$TINFO_LDFLAGS" | sed -e 's,-L\.\./,-L../../,'` |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21676 | |
| 21677 | case $DFT_LWR_MODEL in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21678 | (normal|debug|profile) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21679 | |
| 21680 | if test "$GCC" = yes ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21681 | case $cf_cv_system_name in |
| 21682 | (OS/2*|os2*|aix[4]*|solaris2.1[0-9]|darwin*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21683 | LDFLAGS_STATIC= |
| 21684 | LDFLAGS_SHARED= |
| 21685 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21686 | (*) # normally, except when broken |
| 21687 | LDFLAGS_STATIC=-static |
| 21688 | LDFLAGS_SHARED=-dynamic |
| 21689 | ;; |
| 21690 | esac |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21691 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21692 | case $cf_cv_system_name in |
| 21693 | (aix[4-7]*) # from ld manpage |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21694 | LDFLAGS_STATIC=-bstatic |
| 21695 | LDFLAGS_SHARED=-bdynamic |
| 21696 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21697 | (hpux*) # from ld manpage for hpux10.20, hpux11.11 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21698 | # We could also use just "archive" and "shared". |
| 21699 | LDFLAGS_STATIC=-Wl,-a,archive_shared |
| 21700 | LDFLAGS_SHARED=-Wl,-a,shared_archive |
| 21701 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21702 | (irix*) # from ld manpage IRIX64 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21703 | LDFLAGS_STATIC=-Bstatic |
| 21704 | LDFLAGS_SHARED=-Bdynamic |
| 21705 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21706 | (osf[45]*) # from ld manpage osf4.0d, osf5.1 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21707 | # alternative "-oldstyle_liblookup" (not in cc manpage) |
| 21708 | LDFLAGS_STATIC=-noso |
| 21709 | LDFLAGS_SHARED=-so_archive |
| 21710 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21711 | (solaris2*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21712 | LDFLAGS_STATIC=-Bstatic |
| 21713 | LDFLAGS_SHARED=-Bdynamic |
| 21714 | ;; |
| 21715 | esac |
| 21716 | fi |
| 21717 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21718 | if test -n "$LDFLAGS_STATIC" && test -n "$LDFLAGS_SHARED" |
| 21719 | then |
| 21720 | echo "$as_me:21720: checking if linker supports switching between static/dynamic" >&5 |
| 21721 | echo $ECHO_N "checking if linker supports switching between static/dynamic... $ECHO_C" >&6 |
| 21722 | |
| 21723 | rm -f libconftest.a |
| 21724 | cat >conftest.$ac_ext <<EOF |
| 21725 | #line 21725 "configure" |
| 21726 | #include <stdio.h> |
| 21727 | int cf_ldflags_static(FILE *fp) { return fflush(fp); } |
| 21728 | EOF |
| 21729 | if { (eval echo "$as_me:21729: \"$ac_compile\"") >&5 |
| 21730 | (eval $ac_compile) 2>&5 |
| 21731 | ac_status=$? |
| 21732 | echo "$as_me:21732: \$? = $ac_status" >&5 |
| 21733 | (exit $ac_status); } ; then |
| 21734 | ( $AR $ARFLAGS libconftest.a conftest.o ) 2>&5 1>/dev/null |
| 21735 | ( eval $RANLIB libconftest.a ) 2>&5 >/dev/null |
| 21736 | fi |
| 21737 | rm -f conftest.* |
| 21738 | |
| 21739 | cf_save_LIBS="$LIBS" |
| 21740 | |
| 21741 | LIBS="$LDFLAGS_STATIC -L`pwd` -lconftest $LDFLAGS_DYNAMIC $LIBS" |
| 21742 | cat >conftest.$ac_ext <<_ACEOF |
| 21743 | #line 21743 "configure" |
| 21744 | #include "confdefs.h" |
| 21745 | |
| 21746 | #line 21746 "configure" |
| 21747 | #include <stdio.h> |
| 21748 | int cf_ldflags_static(FILE *fp); |
| 21749 | |
| 21750 | int |
| 21751 | main () |
| 21752 | { |
| 21753 | |
| 21754 | return cf_ldflags_static(stdin); |
| 21755 | |
| 21756 | ; |
| 21757 | return 0; |
| 21758 | } |
| 21759 | _ACEOF |
| 21760 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 21761 | if { (eval echo "$as_me:21761: \"$ac_link\"") >&5 |
| 21762 | (eval $ac_link) 2>&5 |
| 21763 | ac_status=$? |
| 21764 | echo "$as_me:21764: \$? = $ac_status" >&5 |
| 21765 | (exit $ac_status); } && |
| 21766 | { ac_try='test -s conftest$ac_exeext' |
| 21767 | { (eval echo "$as_me:21767: \"$ac_try\"") >&5 |
| 21768 | (eval $ac_try) 2>&5 |
| 21769 | ac_status=$? |
| 21770 | echo "$as_me:21770: \$? = $ac_status" >&5 |
| 21771 | (exit $ac_status); }; }; then |
| 21772 | |
| 21773 | # some linkers simply ignore the -dynamic |
| 21774 | case x`file conftest$ac_exeext 2>/dev/null` in |
| 21775 | (*static*) |
| 21776 | cf_ldflags_static=no |
| 21777 | ;; |
| 21778 | (*) |
| 21779 | cf_ldflags_static=yes |
| 21780 | ;; |
| 21781 | esac |
| 21782 | |
| 21783 | else |
| 21784 | echo "$as_me: failed program was:" >&5 |
| 21785 | cat conftest.$ac_ext >&5 |
| 21786 | cf_ldflags_static=no |
| 21787 | fi |
| 21788 | rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext |
| 21789 | |
| 21790 | rm -f libconftest.* |
| 21791 | LIBS="$cf_save_LIBS" |
| 21792 | |
| 21793 | echo "$as_me:21793: result: $cf_ldflags_static" >&5 |
| 21794 | echo "${ECHO_T}$cf_ldflags_static" >&6 |
| 21795 | |
| 21796 | if test $cf_ldflags_static != yes |
| 21797 | then |
| 21798 | LDFLAGS_STATIC= |
| 21799 | LDFLAGS_SHARED= |
| 21800 | fi |
| 21801 | else |
| 21802 | LDFLAGS_STATIC= |
| 21803 | LDFLAGS_SHARED= |
| 21804 | fi |
| 21805 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21806 | ;; |
| 21807 | esac |
| 21808 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21809 | echo "$as_me:21809: checking where we will install curses.h" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21810 | echo $ECHO_N "checking where we will install curses.h... $ECHO_C" >&6 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21811 | |
| 21812 | includesubdir= |
| 21813 | if test "$with_overwrite" = no && \ |
| 21814 | ( test "x$includedir" = 'x${prefix}/include' || \ |
| 21815 | test "x$includedir" = "x${prefix}/include" ) |
| 21816 | then |
| 21817 | includesubdir="/ncurses${USE_LIB_SUFFIX}" |
| 21818 | fi |
| 21819 | echo "$as_me:21819: result: ${includedir}${includesubdir}" >&5 |
| 21820 | echo "${ECHO_T}${includedir}${includesubdir}" >&6 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21821 | |
| 21822 | ### Resolve a conflict between normal and wide-curses by forcing applications |
| 21823 | ### that will need libutf8 to add it to their configure script. |
| 21824 | if test "$with_overwrite" != no ; then |
| 21825 | if test "$NCURSES_LIBUTF8" = 1 ; then |
| 21826 | NCURSES_LIBUTF8='defined(HAVE_LIBUTF8_H)' |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21827 | { echo "$as_me:21827: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21828 | echo "$as_me: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&2;} |
| 21829 | fi |
| 21830 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21831 | WITH_OVERWRITE=$with_overwrite |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21832 | |
| 21833 | # used to separate tack out of the tree |
| 21834 | NCURSES_TREE= |
| 21835 | |
| 21836 | ### predefined stuff for the test programs |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21837 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21838 | cat >>confdefs.h <<\EOF |
| 21839 | #define HAVE_SLK_COLOR 1 |
| 21840 | EOF |
| 21841 | |
| 21842 | ### Construct the list of subdirectories for which we'll customize makefiles |
| 21843 | ### with the appropriate compile-rules. |
| 21844 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21845 | echo "$as_me:21845: checking for src modules" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21846 | echo $ECHO_N "checking for src modules... $ECHO_C" >&6 |
| 21847 | |
| 21848 | # dependencies and linker-arguments for test-programs |
| 21849 | TEST_DEPS="${LIB_DIR}/${LIB_PREFIX}${LIB_NAME}${DFT_DEP_SUFFIX} $TEST_DEPS" |
| 21850 | TEST_DEP2="${LIB_2ND}/${LIB_PREFIX}${LIB_NAME}${DFT_DEP_SUFFIX} $TEST_DEP2" |
| 21851 | if test "$DFT_LWR_MODEL" = "libtool"; then |
| 21852 | TEST_ARGS="${TEST_DEPS}" |
| 21853 | TEST_ARG2="${TEST_DEP2}" |
| 21854 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21855 | TEST_ARGS="-l${LIB_NAME}${USE_ARG_SUFFIX} $TEST_ARGS" |
| 21856 | TEST_ARG2="-l${LIB_NAME}${USE_ARG_SUFFIX} $TEST_ARG2" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21857 | fi |
| 21858 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21859 | PC_MODULES_TO_MAKE="ncurses${USE_ARG_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21860 | cf_cv_src_modules= |
| 21861 | for cf_dir in $modules_to_build |
| 21862 | do |
| 21863 | if test -f $srcdir/$cf_dir/modules; then |
| 21864 | |
| 21865 | # We may/may not have tack in the distribution, though the |
| 21866 | # makefile is. |
| 21867 | if test $cf_dir = tack ; then |
| 21868 | if test ! -f $srcdir/${cf_dir}/${cf_dir}.h; then |
| 21869 | continue |
| 21870 | fi |
| 21871 | fi |
| 21872 | |
| 21873 | if test -z "$cf_cv_src_modules"; then |
| 21874 | cf_cv_src_modules=$cf_dir |
| 21875 | else |
| 21876 | cf_cv_src_modules="$cf_cv_src_modules $cf_dir" |
| 21877 | fi |
| 21878 | |
| 21879 | # Make the ncurses_cfg.h file record the library interface files as |
| 21880 | # well. These are header files that are the same name as their |
| 21881 | # directory. Ncurses is the only library that does not follow |
| 21882 | # that pattern. |
| 21883 | if test $cf_dir = tack ; then |
| 21884 | continue |
| 21885 | elif test -f $srcdir/${cf_dir}/${cf_dir}.h; then |
| 21886 | |
| 21887 | cf_have_include=`echo "$cf_dir" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 21888 | |
| 21889 | cat >>confdefs.h <<EOF |
| 21890 | #define HAVE_${cf_have_include}_H 1 |
| 21891 | EOF |
| 21892 | |
| 21893 | cat >>confdefs.h <<EOF |
| 21894 | #define HAVE_LIB${cf_have_include} 1 |
| 21895 | EOF |
| 21896 | |
| 21897 | TEST_DEPS="${LIB_DIR}/${LIB_PREFIX}${cf_dir}${DFT_DEP_SUFFIX} $TEST_DEPS" |
| 21898 | TEST_DEP2="${LIB_2ND}/${LIB_PREFIX}${cf_dir}${DFT_DEP_SUFFIX} $TEST_DEP2" |
| 21899 | if test "$DFT_LWR_MODEL" = "libtool"; then |
| 21900 | TEST_ARGS="${TEST_DEPS}" |
| 21901 | TEST_ARG2="${TEST_DEP2}" |
| 21902 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21903 | TEST_ARGS="-l${cf_dir}${USE_ARG_SUFFIX} $TEST_ARGS" |
| 21904 | TEST_ARG2="-l${cf_dir}${USE_ARG_SUFFIX} $TEST_ARG2" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21905 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21906 | PC_MODULES_TO_MAKE="${PC_MODULES_TO_MAKE} ${cf_dir}${USE_ARG_SUFFIX}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21907 | fi |
| 21908 | fi |
| 21909 | done |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21910 | echo "$as_me:21910: result: $cf_cv_src_modules" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21911 | echo "${ECHO_T}$cf_cv_src_modules" >&6 |
| 21912 | |
| 21913 | TEST_ARGS="-L${LIB_DIR} $TEST_ARGS" |
| 21914 | TEST_ARG2="-L${LIB_2ND} $TEST_ARG2" |
| 21915 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21916 | SRC_SUBDIRS= |
| 21917 | if test "x$cf_with_manpages" != xno ; then |
| 21918 | SRC_SUBDIRS="$SRC_SUBDIRS man" |
| 21919 | fi |
| 21920 | SRC_SUBDIRS="$SRC_SUBDIRS include" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21921 | for cf_dir in $cf_cv_src_modules |
| 21922 | do |
| 21923 | SRC_SUBDIRS="$SRC_SUBDIRS $cf_dir" |
| 21924 | done |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21925 | if test "x$cf_with_tests" != "xno" ; then |
| 21926 | SRC_SUBDIRS="$SRC_SUBDIRS test" |
| 21927 | fi |
| 21928 | # always make this, to install the ncurses-config script |
| 21929 | SRC_SUBDIRS="$SRC_SUBDIRS misc" |
| 21930 | if test "$cf_with_cxx_binding" != no; then |
| 21931 | PC_MODULES_TO_MAKE="${PC_MODULES_TO_MAKE} ncurses++${USE_ARG_SUFFIX}" |
| 21932 | SRC_SUBDIRS="$SRC_SUBDIRS c++" |
| 21933 | fi |
| 21934 | |
| 21935 | test "x$with_termlib" != xno && PC_MODULES_TO_MAKE="$PC_MODULES_TO_MAKE $TINFO_ARG_SUFFIX" |
| 21936 | test "x$with_ticlib" != xno && PC_MODULES_TO_MAKE="$PC_MODULES_TO_MAKE $TICS_ARG_SUFFIX" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21937 | |
| 21938 | ADA_SUBDIRS= |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21939 | if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = xyes && test -f $srcdir/Ada95/Makefile.in; then |
| 21940 | SRC_SUBDIRS="$SRC_SUBDIRS Ada95" |
| 21941 | ADA_SUBDIRS="gen src" |
| 21942 | if test "x$cf_with_tests" != "xno" ; then |
| 21943 | ADA_SUBDIRS="$ADA_SUBDIRS samples" |
| 21944 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21945 | fi |
| 21946 | |
| 21947 | SUB_MAKEFILES= |
| 21948 | for cf_dir in $SRC_SUBDIRS |
| 21949 | do |
| 21950 | SUB_MAKEFILES="$SUB_MAKEFILES $cf_dir/Makefile" |
| 21951 | done |
| 21952 | |
| 21953 | if test -n "$ADA_SUBDIRS"; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21954 | for cf_dir in $ADA_SUBDIRS |
| 21955 | do |
| 21956 | SUB_MAKEFILES="$SUB_MAKEFILES Ada95/$cf_dir/Makefile" |
| 21957 | done |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21958 | |
| 21959 | fi |
| 21960 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21961 | if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = "xyes"; then |
| 21962 | SUB_MAKEFILES="$SUB_MAKEFILES Ada95/gen/adacurses${USE_CFG_SUFFIX}-config:Ada95/gen/adacurses-config.in" |
| 21963 | SUB_MAKEFILES="$SUB_MAKEFILES man/adacurses${USE_CFG_SUFFIX}-config.1:man/MKada_config.in" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21964 | fi |
| 21965 | |
| 21966 | DIRS_TO_MAKE="lib" |
| 21967 | for cf_item in $cf_list_models |
| 21968 | do |
| 21969 | |
| 21970 | case $cf_item in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21971 | (libtool) cf_subdir='obj_lo' ;; |
| 21972 | (normal) cf_subdir='objects' ;; |
| 21973 | (debug) cf_subdir='obj_g' ;; |
| 21974 | (profile) cf_subdir='obj_p' ;; |
| 21975 | (shared) |
| 21976 | case $cf_cv_system_name in |
| 21977 | (cygwin|msys) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21978 | cf_subdir='objects' ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21979 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 21980 | cf_subdir='obj_s' ;; |
| 21981 | esac |
| 21982 | esac |
| 21983 | |
| 21984 | for cf_item2 in $DIRS_TO_MAKE |
| 21985 | do |
| 21986 | test $cf_item2 = $cf_subdir && break |
| 21987 | done |
| 21988 | test ".$cf_item2" != ".$cf_subdir" && DIRS_TO_MAKE="$DIRS_TO_MAKE $cf_subdir" |
| 21989 | done |
| 21990 | for cf_dir in $DIRS_TO_MAKE |
| 21991 | do |
| 21992 | test ! -d $cf_dir && mkdir $cf_dir |
| 21993 | done |
| 21994 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 21995 | # symbols that differ when compiling Ada95 by itself. |
| 21996 | NCURSES_SHLIB2=$SHELL' $(top_srcdir)/misc/shlib' |
| 21997 | |
| 21998 | # values to use as strings |
| 21999 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22000 | cat >>confdefs.h <<EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22001 | #define NCURSES_PATHSEP '$PATH_SEPARATOR' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22002 | EOF |
| 22003 | |
| 22004 | cat >>confdefs.h <<EOF |
| 22005 | #define NCURSES_VERSION_STRING "${NCURSES_MAJOR}.${NCURSES_MINOR}.${NCURSES_PATCH}" |
| 22006 | EOF |
| 22007 | |
| 22008 | ### Now that we're done running tests, add the compiler-warnings, if any |
| 22009 | |
| 22010 | cf_fix_cppflags=no |
| 22011 | cf_new_cflags= |
| 22012 | cf_new_cppflags= |
| 22013 | cf_new_extra_cppflags= |
| 22014 | |
| 22015 | for cf_add_cflags in $EXTRA_CFLAGS |
| 22016 | do |
| 22017 | case $cf_fix_cppflags in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22018 | (no) |
| 22019 | case $cf_add_cflags in |
| 22020 | (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22021 | case $cf_add_cflags in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22022 | (-D*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22023 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'` |
| 22024 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22025 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 22026 | && test -z "${cf_tst_cflags}" \ |
| 22027 | && cf_fix_cppflags=yes |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22028 | |
| 22029 | if test $cf_fix_cppflags = yes ; then |
| 22030 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 22031 | continue |
| 22032 | elif test "${cf_tst_cflags}" = "\"'" ; then |
| 22033 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 22034 | continue |
| 22035 | fi |
| 22036 | ;; |
| 22037 | esac |
| 22038 | case "$CPPFLAGS" in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22039 | (*$cf_add_cflags) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22040 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22041 | (*) |
| 22042 | case $cf_add_cflags in |
| 22043 | (-D*) |
| 22044 | cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'` |
| 22045 | |
| 22046 | CPPFLAGS=`echo "$CPPFLAGS" | \ |
| 22047 | sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \ |
| 22048 | -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'` |
| 22049 | |
| 22050 | ;; |
| 22051 | esac |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22052 | cf_new_cppflags="$cf_new_cppflags $cf_add_cflags" |
| 22053 | ;; |
| 22054 | esac |
| 22055 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22056 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22057 | cf_new_cflags="$cf_new_cflags $cf_add_cflags" |
| 22058 | ;; |
| 22059 | esac |
| 22060 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22061 | (yes) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22062 | cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags" |
| 22063 | |
| 22064 | cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'` |
| 22065 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22066 | test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \ |
| 22067 | && test -z "${cf_tst_cflags}" \ |
| 22068 | && cf_fix_cppflags=no |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22069 | ;; |
| 22070 | esac |
| 22071 | done |
| 22072 | |
| 22073 | if test -n "$cf_new_cflags" ; then |
| 22074 | |
| 22075 | CFLAGS="$CFLAGS $cf_new_cflags" |
| 22076 | fi |
| 22077 | |
| 22078 | if test -n "$cf_new_cppflags" ; then |
| 22079 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22080 | CPPFLAGS="$CPPFLAGS $cf_new_cppflags" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22081 | fi |
| 22082 | |
| 22083 | if test -n "$cf_new_extra_cppflags" ; then |
| 22084 | |
| 22085 | EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS" |
| 22086 | fi |
| 22087 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22088 | ### Define substitutions for header files to avoid name-pollution |
| 22089 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22090 | if test "x$cf_cv_have_tcgetattr" = xyes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22091 | HAVE_TCGETATTR=1 |
| 22092 | else |
| 22093 | HAVE_TCGETATTR=0 |
| 22094 | fi |
| 22095 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22096 | if test "x$ac_cv_header_stdint_h" = xyes ; then |
| 22097 | HAVE_STDINT_H=1 |
| 22098 | else |
| 22099 | HAVE_STDINT_H=0 |
| 22100 | fi |
| 22101 | |
| 22102 | if test "x$ac_cv_header_termio_h" = xyes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22103 | HAVE_TERMIO_H=1 |
| 22104 | else |
| 22105 | HAVE_TERMIO_H=0 |
| 22106 | fi |
| 22107 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22108 | if test "x$ac_cv_header_termios_h" = xyes ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22109 | HAVE_TERMIOS_H=1 |
| 22110 | else |
| 22111 | HAVE_TERMIOS_H=0 |
| 22112 | fi |
| 22113 | |
| 22114 | ################################################################################ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22115 | test "x$use_database" = xyes && \ |
| 22116 | SUB_MAKEFILES="$SUB_MAKEFILES misc/run_tic.sh:misc/run_tic.in" |
| 22117 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22118 | SUB_MAKEFILES="$SUB_MAKEFILES misc/ncurses-config:misc/ncurses-config.in" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22119 | SUB_MAKEFILES="$SUB_MAKEFILES man/ncurses${USE_CFG_SUFFIX}-config.1:man/MKncu_config.in" |
| 22120 | |
| 22121 | if test "x$enable_pc_files" = xyes ; then \ |
| 22122 | SUB_MAKEFILES="$SUB_MAKEFILES misc/gen-pkgconfig:misc/gen-pkgconfig.in" |
| 22123 | MAKE_PC_FILES= |
| 22124 | else |
| 22125 | MAKE_PC_FILES="#" |
| 22126 | fi |
| 22127 | |
| 22128 | # Extract the first word of "tic", so it can be a program name with args. |
| 22129 | set dummy tic; ac_word=$2 |
| 22130 | echo "$as_me:22130: checking for $ac_word" >&5 |
| 22131 | echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 |
| 22132 | if test "${ac_cv_path_TIC_PATH+set}" = set; then |
| 22133 | echo $ECHO_N "(cached) $ECHO_C" >&6 |
| 22134 | else |
| 22135 | case $TIC_PATH in |
| 22136 | [\\/]* | ?:[\\/]*) |
| 22137 | ac_cv_path_TIC_PATH="$TIC_PATH" # Let the user override the test with a path. |
| 22138 | ;; |
| 22139 | *) |
| 22140 | ac_save_IFS=$IFS; IFS=$ac_path_separator |
| 22141 | ac_dummy="$PATH:/usr/local/ncurses/bin" |
| 22142 | for ac_dir in $ac_dummy; do |
| 22143 | IFS=$ac_save_IFS |
| 22144 | test -z "$ac_dir" && ac_dir=. |
| 22145 | if $as_executable_p "$ac_dir/$ac_word"; then |
| 22146 | ac_cv_path_TIC_PATH="$ac_dir/$ac_word" |
| 22147 | echo "$as_me:22147: found $ac_dir/$ac_word" >&5 |
| 22148 | break |
| 22149 | fi |
| 22150 | done |
| 22151 | |
| 22152 | test -z "$ac_cv_path_TIC_PATH" && ac_cv_path_TIC_PATH="unknown" |
| 22153 | ;; |
| 22154 | esac |
| 22155 | fi |
| 22156 | TIC_PATH=$ac_cv_path_TIC_PATH |
| 22157 | |
| 22158 | if test -n "$TIC_PATH"; then |
| 22159 | echo "$as_me:22159: result: $TIC_PATH" >&5 |
| 22160 | echo "${ECHO_T}$TIC_PATH" >&6 |
| 22161 | else |
| 22162 | echo "$as_me:22162: result: no" >&5 |
| 22163 | echo "${ECHO_T}no" >&6 |
| 22164 | fi |
| 22165 | |
| 22166 | if test -n "$FALLBACK_LIST" |
| 22167 | then |
| 22168 | if test "$TIC_PATH" = unknown |
| 22169 | then |
| 22170 | { echo "$as_me:22170: WARNING: no tic program found for fallbacks" >&5 |
| 22171 | echo "$as_me: WARNING: no tic program found for fallbacks" >&2;} |
| 22172 | fi |
| 22173 | fi |
| 22174 | |
| 22175 | if test "x$cf_with_tests" != xno ; then |
| 22176 | MAKE_TESTS= |
| 22177 | else |
| 22178 | MAKE_TESTS="#" |
| 22179 | fi |
| 22180 | |
| 22181 | ADAHTML_DIR=../../doc/html/ada |
| 22182 | |
| 22183 | # these could be configurable, but are not currently |
| 22184 | PANEL_NAME=panel |
| 22185 | MENU_NAME=menu |
| 22186 | FORM_NAME=form |
| 22187 | CXX_NAME=ncurses++ |
| 22188 | |
| 22189 | # workaround for g++ versus Solaris (20131116) |
| 22190 | case $cf_cv_system_name in |
| 22191 | (solaris2*) |
| 22192 | case "x$CPPFLAGS" in |
| 22193 | (*-D_XOPEN_SOURCE_EXTENDED*) |
| 22194 | test -n "$verbose" && echo " moving _XOPEN_SOURCE_EXTENDED to work around g++ problem" 1>&6 |
| 22195 | |
| 22196 | echo "${as_me:-configure}:22196: testing moving _XOPEN_SOURCE_EXTENDED to work around g++ problem ..." 1>&5 |
| 22197 | |
| 22198 | CFLAGS="$CFLAGS -D_XOPEN_SOURCE_EXTENDED" |
| 22199 | CPPFLAGS=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/-D_XOPEN_SOURCE_EXTENDED//'` |
| 22200 | ;; |
| 22201 | esac |
| 22202 | ;; |
| 22203 | esac |
| 22204 | |
| 22205 | # Help to automatically enable the extended curses features when using either |
| 22206 | # the *-config or the ".pc" files by adding defines. |
| 22207 | echo "$as_me:22207: checking for defines to add to ncurses${USE_CFG_SUFFIX}-config script" >&5 |
| 22208 | echo $ECHO_N "checking for defines to add to ncurses${USE_CFG_SUFFIX}-config script... $ECHO_C" >&6 |
| 22209 | PKG_CFLAGS= |
| 22210 | for cf_loop1 in $CPPFLAGS_after_XOPEN |
| 22211 | do |
| 22212 | cf_found=no |
| 22213 | for cf_loop2 in $CPPFLAGS_before_XOPEN |
| 22214 | do |
| 22215 | if test "x$cf_loop1" = "x$cf_loop2" |
| 22216 | then |
| 22217 | cf_found=yes |
| 22218 | break |
| 22219 | fi |
| 22220 | done |
| 22221 | test "$cf_found" = no && PKG_CFLAGS="$PKG_CFLAGS $cf_loop1" |
| 22222 | done |
| 22223 | echo "$as_me:22223: result: $PKG_CFLAGS" >&5 |
| 22224 | echo "${ECHO_T}$PKG_CFLAGS" >&6 |
| 22225 | |
| 22226 | # AC_CHECK_SIZEOF demands a literal parameter, no variables. So we do this. |
| 22227 | case "x$NCURSES_OSPEED" in |
| 22228 | (*short*) |
| 22229 | cf_compatible=1 |
| 22230 | ;; |
| 22231 | (*) |
| 22232 | cf_compatible=0 |
| 22233 | ;; |
| 22234 | esac |
| 22235 | |
| 22236 | cat >>confdefs.h <<EOF |
| 22237 | #define NCURSES_OSPEED_COMPAT $cf_compatible |
| 22238 | EOF |
| 22239 | |
| 22240 | case "x$cf_cv_typeof_chtype" in |
| 22241 | (xshort|xint|xlong) |
| 22242 | cf_cv_typeof_chtype="unsigned $cf_cv_typeof_chtype" |
| 22243 | ;; |
| 22244 | esac |
| 22245 | |
| 22246 | case "x$cf_cv_typeof_mmask_t" in |
| 22247 | (xshort|xint|xlong) |
| 22248 | cf_cv_typeof_mmask_t="unsigned $cf_cv_typeof_mmask_t" |
| 22249 | ;; |
| 22250 | esac |
| 22251 | |
| 22252 | # substitute into misc/Makefile to suppress |
| 22253 | # (un)install.data from the |
| 22254 | # (un)install rules. |
| 22255 | if test "x$cf_with_db_install" = "xno"; then |
| 22256 | MISC_INSTALL_DATA= |
| 22257 | MISC_UNINSTALL_DATA= |
| 22258 | else |
| 22259 | MISC_INSTALL_DATA=install.data |
| 22260 | MISC_UNINSTALL_DATA=uninstall.data |
| 22261 | fi |
| 22262 | |
| 22263 | SUB_SCRIPTS= |
| 22264 | |
| 22265 | if test -n "$PACKAGE" |
| 22266 | then |
| 22267 | PACKAGE="${PACKAGE}${DFT_ARG_SUFFIX}" |
| 22268 | export PACKAGE |
| 22269 | echo "package: $PACKAGE" |
| 22270 | fi |
| 22271 | |
| 22272 | UNALTERED_SYMS= |
| 22273 | cf_filter_syms=no |
| 22274 | |
| 22275 | if test -n "$RESULTING_SYMS" |
| 22276 | then |
| 22277 | cf_filter_syms=$cf_dft_filter_syms |
| 22278 | test -n "$verbose" && echo " will map symbols to ABI=$cf_cv_abi_version" 1>&6 |
| 22279 | |
| 22280 | echo "${as_me:-configure}:22280: testing will map symbols to ABI=$cf_cv_abi_version ..." 1>&5 |
| 22281 | |
| 22282 | fi |
| 22283 | |
| 22284 | if test "x$WILDCARD_SYMS" = xno |
| 22285 | then |
| 22286 | cf_filter_syms=yes |
| 22287 | fi |
| 22288 | |
| 22289 | UNALTERED_SYMS=`echo "$RESULTING_SYMS" | sed -e 's/\\$/\\\\$/g'` |
| 22290 | if test $cf_filter_syms = yes |
| 22291 | then |
| 22292 | RESULTING_SYMS=resulting.map |
| 22293 | fi |
| 22294 | |
| 22295 | if test "x$cross_compiling" = xyes ; then |
| 22296 | ADAGEN_LDFLAGS='$(CROSS_LDFLAGS)' |
| 22297 | else |
| 22298 | ADAGEN_LDFLAGS='$(NATIVE_LDFLAGS)' |
| 22299 | fi |
| 22300 | |
| 22301 | ac_config_files="$ac_config_files include/MKterm.h.awk include/curses.head:include/curses.h.in include/ncurses_dll.h include/termcap.h include/unctrl.h $SUB_SCRIPTS $SUB_MAKEFILES Makefile" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22302 | ac_config_commands="$ac_config_commands default" |
| 22303 | cat >confcache <<\_ACEOF |
| 22304 | # This file is a shell script that caches the results of configure |
| 22305 | # tests run on this system so they can be shared between configure |
| 22306 | # scripts and configure runs, see configure's option --config-cache. |
| 22307 | # It is not useful on other systems. If it contains results you don't |
| 22308 | # want to keep, you may remove or edit it. |
| 22309 | # |
| 22310 | # config.status only pays attention to the cache file if you give it |
| 22311 | # the --recheck option to rerun configure. |
| 22312 | # |
| 22313 | # `ac_cv_env_foo' variables (set or unset) will be overriden when |
| 22314 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 22315 | # following values. |
| 22316 | |
| 22317 | _ACEOF |
| 22318 | |
| 22319 | # The following way of writing the cache mishandles newlines in values, |
| 22320 | # but we know of no workaround that is simple, portable, and efficient. |
| 22321 | # So, don't put newlines in cache variables' values. |
| 22322 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 22323 | # and sets the high bit in the cache file unless we assign to the vars. |
| 22324 | { |
| 22325 | (set) 2>&1 | |
| 22326 | case `(ac_space=' '; set | grep ac_space) 2>&1` in |
| 22327 | *ac_space=\ *) |
| 22328 | # `set' does not quote correctly, so add quotes (double-quote |
| 22329 | # substitution turns \\\\ into \\, and sed turns \\ into \). |
| 22330 | sed -n \ |
| 22331 | "s/'/'\\\\''/g; |
| 22332 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" |
| 22333 | ;; |
| 22334 | *) |
| 22335 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 22336 | sed -n \ |
| 22337 | "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" |
| 22338 | ;; |
| 22339 | esac; |
| 22340 | } | |
| 22341 | sed ' |
| 22342 | t clear |
| 22343 | : clear |
| 22344 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 22345 | t end |
| 22346 | /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 22347 | : end' >>confcache |
| 22348 | if cmp -s $cache_file confcache; then :; else |
| 22349 | if test -w $cache_file; then |
| 22350 | test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file" |
| 22351 | cat confcache >$cache_file |
| 22352 | else |
| 22353 | echo "not updating unwritable cache $cache_file" |
| 22354 | fi |
| 22355 | fi |
| 22356 | rm -f confcache |
| 22357 | |
| 22358 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 22359 | # Let make expand exec_prefix. |
| 22360 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
| 22361 | |
| 22362 | # VPATH may cause trouble with some makes, so we remove $(srcdir), |
| 22363 | # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and |
| 22364 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 22365 | # (actually we leave an empty line to preserve line numbers). |
| 22366 | if test "x$srcdir" = x.; then |
| 22367 | ac_vpsub='/^[ ]*VPATH[ ]*=/{ |
| 22368 | s/:*\$(srcdir):*/:/; |
| 22369 | s/:*\${srcdir}:*/:/; |
| 22370 | s/:*@srcdir@:*/:/; |
| 22371 | s/^\([^=]*=[ ]*\):*/\1/; |
| 22372 | s/:*$//; |
| 22373 | s/^[^=]*=[ ]*$//; |
| 22374 | }' |
| 22375 | fi |
| 22376 | |
| 22377 | DEFS=-DHAVE_CONFIG_H |
| 22378 | |
| 22379 | : ${CONFIG_STATUS=./config.status} |
| 22380 | ac_clean_files_save=$ac_clean_files |
| 22381 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22382 | { echo "$as_me:22382: creating $CONFIG_STATUS" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22383 | echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 22384 | cat >$CONFIG_STATUS <<_ACEOF |
| 22385 | #! $SHELL |
| 22386 | # Generated automatically by configure. |
| 22387 | # Run this file to recreate the current configuration. |
| 22388 | # Compiler output produced by configure, useful for debugging |
| 22389 | # configure, is in config.log if it exists. |
| 22390 | |
| 22391 | debug=false |
| 22392 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 22393 | ac_cs_invocation="\$0 \$@" |
| 22394 | |
| 22395 | _ACEOF |
| 22396 | |
| 22397 | cat >>$CONFIG_STATUS <<\_ACEOF |
| 22398 | # Be Bourne compatible |
| 22399 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then |
| 22400 | emulate sh |
| 22401 | NULLCMD=: |
| 22402 | elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then |
| 22403 | set -o posix |
| 22404 | fi |
| 22405 | |
| 22406 | # Name of the executable. |
| 22407 | as_me=`echo "$0" |sed 's,.*[\\/],,'` |
| 22408 | |
| 22409 | if expr a : '\(a\)' >/dev/null 2>&1; then |
| 22410 | as_expr=expr |
| 22411 | else |
| 22412 | as_expr=false |
| 22413 | fi |
| 22414 | |
| 22415 | rm -f conf$$ conf$$.exe conf$$.file |
| 22416 | echo >conf$$.file |
| 22417 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 22418 | # We could just check for DJGPP; but this test a) works b) is more generic |
| 22419 | # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). |
| 22420 | if test -f conf$$.exe; then |
| 22421 | # Don't use ln at all; we don't have any links |
| 22422 | as_ln_s='cp -p' |
| 22423 | else |
| 22424 | as_ln_s='ln -s' |
| 22425 | fi |
| 22426 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 22427 | as_ln_s=ln |
| 22428 | else |
| 22429 | as_ln_s='cp -p' |
| 22430 | fi |
| 22431 | rm -f conf$$ conf$$.exe conf$$.file |
| 22432 | |
| 22433 | as_executable_p="test -f" |
| 22434 | |
| 22435 | # Support unset when possible. |
| 22436 | if (FOO=FOO; unset FOO) >/dev/null 2>&1; then |
| 22437 | as_unset=unset |
| 22438 | else |
| 22439 | as_unset=false |
| 22440 | fi |
| 22441 | |
| 22442 | # NLS nuisances. |
| 22443 | $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; } |
| 22444 | $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; } |
| 22445 | $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; } |
| 22446 | $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; } |
| 22447 | $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; } |
| 22448 | $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; } |
| 22449 | $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; } |
| 22450 | $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; } |
| 22451 | |
| 22452 | # IFS |
| 22453 | # We need space, tab and new line, in precisely that order. |
| 22454 | as_nl=' |
| 22455 | ' |
| 22456 | IFS=" $as_nl" |
| 22457 | |
| 22458 | # CDPATH. |
| 22459 | $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; } |
| 22460 | |
| 22461 | exec 6>&1 |
| 22462 | |
| 22463 | _ACEOF |
| 22464 | |
| 22465 | # Files that config.status was made for. |
| 22466 | if test -n "$ac_config_files"; then |
| 22467 | echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS |
| 22468 | fi |
| 22469 | |
| 22470 | if test -n "$ac_config_headers"; then |
| 22471 | echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS |
| 22472 | fi |
| 22473 | |
| 22474 | if test -n "$ac_config_links"; then |
| 22475 | echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS |
| 22476 | fi |
| 22477 | |
| 22478 | if test -n "$ac_config_commands"; then |
| 22479 | echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS |
| 22480 | fi |
| 22481 | |
| 22482 | cat >>$CONFIG_STATUS <<\EOF |
| 22483 | |
| 22484 | ac_cs_usage="\ |
| 22485 | \`$as_me' instantiates files from templates according to the |
| 22486 | current configuration. |
| 22487 | |
| 22488 | Usage: $0 [OPTIONS] [FILE]... |
| 22489 | |
| 22490 | -h, --help print this help, then exit |
| 22491 | -V, --version print version number, then exit |
| 22492 | -d, --debug don't remove temporary files |
| 22493 | --recheck update $as_me by reconfiguring in the same conditions |
| 22494 | --file=FILE[:TEMPLATE] |
| 22495 | instantiate the configuration file FILE |
| 22496 | --header=FILE[:TEMPLATE] |
| 22497 | instantiate the configuration header FILE |
| 22498 | |
| 22499 | Configuration files: |
| 22500 | $config_files |
| 22501 | |
| 22502 | Configuration headers: |
| 22503 | $config_headers |
| 22504 | |
| 22505 | Configuration commands: |
| 22506 | $config_commands |
| 22507 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22508 | Report bugs to <dickey@invisible-island.net>." |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22509 | EOF |
| 22510 | |
| 22511 | cat >>$CONFIG_STATUS <<EOF |
| 22512 | ac_cs_version="\\ |
| 22513 | config.status |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22514 | configured by $0, generated by GNU Autoconf 2.52.20141204, |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22515 | with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\" |
| 22516 | |
| 22517 | Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001 |
| 22518 | Free Software Foundation, Inc. |
| 22519 | This config.status script is free software; the Free Software Foundation |
| 22520 | gives unlimited permission to copy, distribute and modify it." |
| 22521 | srcdir=$srcdir |
| 22522 | INSTALL="$INSTALL" |
| 22523 | EOF |
| 22524 | |
| 22525 | cat >>$CONFIG_STATUS <<\EOF |
| 22526 | # If no file are specified by the user, then we need to provide default |
| 22527 | # value. By we need to know if files were specified by the user. |
| 22528 | ac_need_defaults=: |
| 22529 | while test $# != 0 |
| 22530 | do |
| 22531 | case $1 in |
| 22532 | --*=*) |
| 22533 | ac_option=`expr "x$1" : 'x\([^=]*\)='` |
| 22534 | ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'` |
| 22535 | shift |
| 22536 | set dummy "$ac_option" "$ac_optarg" ${1+"$@"} |
| 22537 | shift |
| 22538 | ;; |
| 22539 | -*);; |
| 22540 | *) # This is not an option, so the user has probably given explicit |
| 22541 | # arguments. |
| 22542 | ac_need_defaults=false;; |
| 22543 | esac |
| 22544 | |
| 22545 | case $1 in |
| 22546 | # Handling of the options. |
| 22547 | EOF |
| 22548 | cat >>$CONFIG_STATUS <<EOF |
| 22549 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 22550 | echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion" |
| 22551 | exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;; |
| 22552 | EOF |
| 22553 | cat >>$CONFIG_STATUS <<\EOF |
| 22554 | --version | --vers* | -V ) |
| 22555 | echo "$ac_cs_version"; exit 0 ;; |
| 22556 | --he | --h) |
| 22557 | # Conflict between --help and --header |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22558 | { { echo "$as_me:22558: error: ambiguous option: $1 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22559 | Try \`$0 --help' for more information." >&5 |
| 22560 | echo "$as_me: error: ambiguous option: $1 |
| 22561 | Try \`$0 --help' for more information." >&2;} |
| 22562 | { (exit 1); exit 1; }; };; |
| 22563 | --help | --hel | -h ) |
| 22564 | echo "$ac_cs_usage"; exit 0 ;; |
| 22565 | --debug | --d* | -d ) |
| 22566 | debug=: ;; |
| 22567 | --file | --fil | --fi | --f ) |
| 22568 | shift |
| 22569 | CONFIG_FILES="$CONFIG_FILES $1" |
| 22570 | ac_need_defaults=false;; |
| 22571 | --header | --heade | --head | --hea ) |
| 22572 | shift |
| 22573 | CONFIG_HEADERS="$CONFIG_HEADERS $1" |
| 22574 | ac_need_defaults=false;; |
| 22575 | |
| 22576 | # This is an error. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22577 | -*) { { echo "$as_me:22577: error: unrecognized option: $1 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22578 | Try \`$0 --help' for more information." >&5 |
| 22579 | echo "$as_me: error: unrecognized option: $1 |
| 22580 | Try \`$0 --help' for more information." >&2;} |
| 22581 | { (exit 1); exit 1; }; } ;; |
| 22582 | |
| 22583 | *) ac_config_targets="$ac_config_targets $1" ;; |
| 22584 | |
| 22585 | esac |
| 22586 | shift |
| 22587 | done |
| 22588 | |
| 22589 | exec 5>>config.log |
| 22590 | cat >&5 << _ACEOF |
| 22591 | |
| 22592 | ## ----------------------- ## |
| 22593 | ## Running config.status. ## |
| 22594 | ## ----------------------- ## |
| 22595 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22596 | This file was extended by $as_me 2.52.20141204, executed with |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22597 | CONFIG_FILES = $CONFIG_FILES |
| 22598 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 22599 | CONFIG_LINKS = $CONFIG_LINKS |
| 22600 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 22601 | > $ac_cs_invocation |
| 22602 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 22603 | |
| 22604 | _ACEOF |
| 22605 | EOF |
| 22606 | |
| 22607 | cat >>$CONFIG_STATUS <<EOF |
| 22608 | # |
| 22609 | # INIT-COMMANDS section. |
| 22610 | # |
| 22611 | |
| 22612 | ### Special initialization commands, used to pass information from the |
| 22613 | ### configuration-run into config.status |
| 22614 | |
| 22615 | AWK="$AWK" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22616 | ALTERNATE_SYMS="$ALTERNATE_SYMS" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22617 | DFT_ARG_SUFFIX="$DFT_ARG_SUFFIX" |
| 22618 | DFT_LWR_MODEL="$DFT_LWR_MODEL" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22619 | ECHO_LD="$ECHO_LD" |
| 22620 | EXTRA_SUFFIX="$EXTRA_SUFFIX" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22621 | LDCONFIG="$LDCONFIG" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22622 | LIBTOOL_VERSION="$LIBTOOL_VERSION" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22623 | LIB_NAME="$LIB_NAME" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22624 | LIB_PREFIX="$LIB_PREFIX" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22625 | LIB_SUBSETS="$LIB_SUBSETS" |
| 22626 | LIB_SUFFIX="$LIB_SUFFIX" |
| 22627 | LIB_TRACING="$LIB_TRACING" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22628 | LN_S="$LN_S" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22629 | MAKE_TERMINFO="$MAKE_TERMINFO" |
| 22630 | NCURSES_MAJOR="$NCURSES_MAJOR" |
| 22631 | NCURSES_MINOR="$NCURSES_MINOR" |
| 22632 | NCURSES_OSPEED="$NCURSES_OSPEED" |
| 22633 | NCURSES_PATCH="$NCURSES_PATCH" |
| 22634 | SRC_SUBDIRS="$SRC_SUBDIRS" |
| 22635 | TERMINFO="$TERMINFO" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22636 | TICS_ARG_SUFFIX="$TICS_ARG_SUFFIX" |
| 22637 | TICS_LIB_SUFFIX="$TICS_LIB_SUFFIX" |
| 22638 | TICS_NAME="$TICS_NAME" |
| 22639 | TIC_PATH="$TIC_PATH" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22640 | TINFO_ARG_SUFFIX="$TINFO_ARG_SUFFIX" |
| 22641 | TINFO_LIB_SUFFIX="$TINFO_LIB_SUFFIX" |
| 22642 | TINFO_NAME="$TINFO_NAME" |
| 22643 | TINFO_SUFFIX="$TINFO_SUFFIX" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22644 | UNALTERED_SYMS="$UNALTERED_SYMS" |
| 22645 | USE_ARG_SUFFIX="$USE_ARG_SUFFIX" |
| 22646 | USE_CFG_SUFFIX="$USE_CFG_SUFFIX" |
| 22647 | USE_LIB_SUFFIX="$USE_LIB_SUFFIX" |
| 22648 | USE_OLD_MAKERULES="$USE_OLD_MAKERULES" |
| 22649 | WILDCARD_SYMS="$WILDCARD_SYMS" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22650 | WITH_CURSES_H="$with_curses_h" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22651 | WITH_ECHO="${enable_echo:=yes}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22652 | WITH_OVERWRITE="$with_overwrite" |
| 22653 | cf_LIST_MODELS="$cf_list_models" |
| 22654 | cf_cv_abi_version="$cf_cv_abi_version" |
| 22655 | cf_cv_do_relink="$cf_cv_do_relink" |
| 22656 | cf_cv_do_symlinks="$cf_cv_do_symlinks" |
| 22657 | cf_cv_enable_lp64="$cf_cv_enable_lp64" |
| 22658 | cf_cv_enable_opaque="$cf_cv_enable_opaque" |
| 22659 | cf_cv_prog_CC_c_o=$cf_cv_prog_CC_c_o |
| 22660 | cf_cv_prog_CXX_c_o=$cf_cv_prog_CXX_c_o |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22661 | cf_cv_prog_gnat_correct=$cf_cv_prog_gnat_correct |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22662 | cf_cv_rel_version="$cf_cv_rel_version" |
| 22663 | cf_cv_rm_so_locs="$cf_cv_rm_so_locs" |
| 22664 | cf_cv_shared_soname='$cf_cv_shared_soname' |
| 22665 | cf_cv_shlib_version="$cf_cv_shlib_version" |
| 22666 | cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix" |
| 22667 | cf_cv_system_name="$cf_cv_system_name" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22668 | cf_cv_term_driver="$with_term_driver" |
| 22669 | cf_with_ada="$cf_with_ada" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22670 | cf_with_cxx_binding="$cf_with_cxx_binding" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22671 | cf_with_db_install="$cf_with_db_install" |
| 22672 | cf_with_manpages="$cf_with_manpages" |
| 22673 | cf_with_tests="$cf_with_tests" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22674 | host="$host" |
| 22675 | target="$target" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22676 | with_shared_cxx="$with_shared_cxx" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22677 | |
| 22678 | EOF |
| 22679 | |
| 22680 | cat >>$CONFIG_STATUS <<\EOF |
| 22681 | for ac_config_target in $ac_config_targets |
| 22682 | do |
| 22683 | case "$ac_config_target" in |
| 22684 | # Handling of arguments. |
| 22685 | "include/MKterm.h.awk" ) CONFIG_FILES="$CONFIG_FILES include/MKterm.h.awk" ;; |
| 22686 | "include/curses.head" ) CONFIG_FILES="$CONFIG_FILES include/curses.head:include/curses.h.in" ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22687 | "include/ncurses_dll.h" ) CONFIG_FILES="$CONFIG_FILES include/ncurses_dll.h" ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22688 | "include/termcap.h" ) CONFIG_FILES="$CONFIG_FILES include/termcap.h" ;; |
| 22689 | "include/unctrl.h" ) CONFIG_FILES="$CONFIG_FILES include/unctrl.h" ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22690 | "$SUB_SCRIPTS" ) CONFIG_FILES="$CONFIG_FILES $SUB_SCRIPTS" ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22691 | "$SUB_MAKEFILES" ) CONFIG_FILES="$CONFIG_FILES $SUB_MAKEFILES" ;; |
| 22692 | "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;; |
| 22693 | "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; |
| 22694 | "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22695 | *) { { echo "$as_me:22695: error: invalid argument: $ac_config_target" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22696 | echo "$as_me: error: invalid argument: $ac_config_target" >&2;} |
| 22697 | { (exit 1); exit 1; }; };; |
| 22698 | esac |
| 22699 | done |
| 22700 | |
| 22701 | # If the user did not use the arguments to specify the items to instantiate, |
| 22702 | # then the envvar interface is used. Set only those that are not. |
| 22703 | # We use the long form for the default assignment because of an extremely |
| 22704 | # bizarre bug on SunOS 4.1.3. |
| 22705 | if $ac_need_defaults; then |
| 22706 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 22707 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 22708 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands |
| 22709 | fi |
| 22710 | |
| 22711 | # Create a temporary directory, and hook for its removal unless debugging. |
| 22712 | $debug || |
| 22713 | { |
| 22714 | trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0 |
| 22715 | trap '{ (exit 1); exit 1; }' 1 2 13 15 |
| 22716 | } |
| 22717 | |
| 22718 | # Create a (secure) tmp directory for tmp files. |
| 22719 | : ${TMPDIR=/tmp} |
| 22720 | { |
| 22721 | tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` && |
| 22722 | test -n "$tmp" && test -d "$tmp" |
| 22723 | } || |
| 22724 | { |
| 22725 | tmp=$TMPDIR/cs$$-$RANDOM |
| 22726 | (umask 077 && mkdir $tmp) |
| 22727 | } || |
| 22728 | { |
| 22729 | echo "$me: cannot create a temporary directory in $TMPDIR" >&2 |
| 22730 | { (exit 1); exit 1; } |
| 22731 | } |
| 22732 | |
| 22733 | EOF |
| 22734 | |
| 22735 | cat >>$CONFIG_STATUS <<EOF |
| 22736 | |
| 22737 | # |
| 22738 | # CONFIG_FILES section. |
| 22739 | # |
| 22740 | |
| 22741 | # No need to generate the scripts if there are no CONFIG_FILES. |
| 22742 | # This happens for instance when ./config.status config.h |
| 22743 | if test -n "\$CONFIG_FILES"; then |
| 22744 | # Protect against being on the right side of a sed subst in config.status. |
| 22745 | sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g; |
| 22746 | s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF |
| 22747 | s,@SHELL@,$SHELL,;t t |
| 22748 | s,@exec_prefix@,$exec_prefix,;t t |
| 22749 | s,@prefix@,$prefix,;t t |
| 22750 | s,@program_transform_name@,$program_transform_name,;t t |
| 22751 | s,@bindir@,$bindir,;t t |
| 22752 | s,@sbindir@,$sbindir,;t t |
| 22753 | s,@libexecdir@,$libexecdir,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22754 | s,@datarootdir@,$datarootdir,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22755 | s,@datadir@,$datadir,;t t |
| 22756 | s,@sysconfdir@,$sysconfdir,;t t |
| 22757 | s,@sharedstatedir@,$sharedstatedir,;t t |
| 22758 | s,@localstatedir@,$localstatedir,;t t |
| 22759 | s,@libdir@,$libdir,;t t |
| 22760 | s,@includedir@,$includedir,;t t |
| 22761 | s,@oldincludedir@,$oldincludedir,;t t |
| 22762 | s,@infodir@,$infodir,;t t |
| 22763 | s,@mandir@,$mandir,;t t |
| 22764 | s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t |
| 22765 | s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t |
| 22766 | s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t |
| 22767 | s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t |
| 22768 | s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t |
| 22769 | s,@build_alias@,$build_alias,;t t |
| 22770 | s,@host_alias@,$host_alias,;t t |
| 22771 | s,@target_alias@,$target_alias,;t t |
| 22772 | s,@ECHO_C@,$ECHO_C,;t t |
| 22773 | s,@ECHO_N@,$ECHO_N,;t t |
| 22774 | s,@ECHO_T@,$ECHO_T,;t t |
| 22775 | s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t |
| 22776 | s,@DEFS@,$DEFS,;t t |
| 22777 | s,@LIBS@,$LIBS,;t t |
| 22778 | s,@top_builddir@,$top_builddir,;t t |
| 22779 | s,@EGREP@,$EGREP,;t t |
| 22780 | s,@NCURSES_MAJOR@,$NCURSES_MAJOR,;t t |
| 22781 | s,@NCURSES_MINOR@,$NCURSES_MINOR,;t t |
| 22782 | s,@NCURSES_PATCH@,$NCURSES_PATCH,;t t |
| 22783 | s,@cf_cv_rel_version@,$cf_cv_rel_version,;t t |
| 22784 | s,@cf_cv_abi_version@,$cf_cv_abi_version,;t t |
| 22785 | s,@cf_cv_builtin_bool@,$cf_cv_builtin_bool,;t t |
| 22786 | s,@cf_cv_header_stdbool_h@,$cf_cv_header_stdbool_h,;t t |
| 22787 | s,@cf_cv_type_of_bool@,$cf_cv_type_of_bool,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22788 | s,@VERSION@,$VERSION,;t t |
| 22789 | s,@VERSION_MAJOR@,$VERSION_MAJOR,;t t |
| 22790 | s,@VERSION_MINOR@,$VERSION_MINOR,;t t |
| 22791 | s,@VERSION_PATCH@,$VERSION_PATCH,;t t |
| 22792 | s,@PACKAGE@,$PACKAGE,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22793 | s,@build@,$build,;t t |
| 22794 | s,@build_cpu@,$build_cpu,;t t |
| 22795 | s,@build_vendor@,$build_vendor,;t t |
| 22796 | s,@build_os@,$build_os,;t t |
| 22797 | s,@host@,$host,;t t |
| 22798 | s,@host_cpu@,$host_cpu,;t t |
| 22799 | s,@host_vendor@,$host_vendor,;t t |
| 22800 | s,@host_os@,$host_os,;t t |
| 22801 | s,@target@,$target,;t t |
| 22802 | s,@target_cpu@,$target_cpu,;t t |
| 22803 | s,@target_vendor@,$target_vendor,;t t |
| 22804 | s,@target_os@,$target_os,;t t |
| 22805 | s,@CC@,$CC,;t t |
| 22806 | s,@CFLAGS@,$CFLAGS,;t t |
| 22807 | s,@LDFLAGS@,$LDFLAGS,;t t |
| 22808 | s,@CPPFLAGS@,$CPPFLAGS,;t t |
| 22809 | s,@ac_ct_CC@,$ac_ct_CC,;t t |
| 22810 | s,@EXEEXT@,$EXEEXT,;t t |
| 22811 | s,@OBJEXT@,$OBJEXT,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22812 | s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22813 | s,@CPP@,$CPP,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22814 | s,@LDCONFIG@,$LDCONFIG,;t t |
| 22815 | s,@CXX@,$CXX,;t t |
| 22816 | s,@CXXFLAGS@,$CXXFLAGS,;t t |
| 22817 | s,@ac_ct_CXX@,$ac_ct_CXX,;t t |
| 22818 | s,@AWK@,$AWK,;t t |
| 22819 | s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t |
| 22820 | s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t |
| 22821 | s,@INSTALL_DATA@,$INSTALL_DATA,;t t |
| 22822 | s,@LINT@,$LINT,;t t |
| 22823 | s,@LINT_OPTS@,$LINT_OPTS,;t t |
| 22824 | s,@LN_S@,$LN_S,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22825 | s,@PKG_CONFIG@,$PKG_CONFIG,;t t |
| 22826 | s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t |
| 22827 | s,@PKG_CONFIG_LIBDIR@,$PKG_CONFIG_LIBDIR,;t t |
| 22828 | s,@MAKE_PC_FILES@,$MAKE_PC_FILES,;t t |
| 22829 | s,@PC_MODULE_SUFFIX@,$PC_MODULE_SUFFIX,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22830 | s,@SET_MAKE@,$SET_MAKE,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22831 | s,@CTAGS@,$CTAGS,;t t |
| 22832 | s,@ETAGS@,$ETAGS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22833 | s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t |
| 22834 | s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t |
| 22835 | s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t |
| 22836 | s,@RANLIB@,$RANLIB,;t t |
| 22837 | s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t |
| 22838 | s,@LD@,$LD,;t t |
| 22839 | s,@ac_ct_LD@,$ac_ct_LD,;t t |
| 22840 | s,@AR@,$AR,;t t |
| 22841 | s,@ac_ct_AR@,$ac_ct_AR,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22842 | s,@NM@,$NM,;t t |
| 22843 | s,@ac_ct_NM@,$ac_ct_NM,;t t |
| 22844 | s,@ARFLAGS@,$ARFLAGS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22845 | s,@DESTDIR@,$DESTDIR,;t t |
| 22846 | s,@BUILD_CC@,$BUILD_CC,;t t |
| 22847 | s,@BUILD_CPP@,$BUILD_CPP,;t t |
| 22848 | s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t |
| 22849 | s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t |
| 22850 | s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t |
| 22851 | s,@BUILD_LIBS@,$BUILD_LIBS,;t t |
| 22852 | s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t |
| 22853 | s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t |
| 22854 | s,@cf_list_models@,$cf_list_models,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22855 | s,@ABI_VERSION@,$ABI_VERSION,;t t |
| 22856 | s,@LIBTOOL_VERSION@,$LIBTOOL_VERSION,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22857 | s,@LIBTOOL@,$LIBTOOL,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22858 | s,@ac_ct_LIBTOOL@,$ac_ct_LIBTOOL,;t t |
| 22859 | s,@LT_UNDEF@,$LT_UNDEF,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22860 | s,@LIBTOOL_CXX@,$LIBTOOL_CXX,;t t |
| 22861 | s,@LIBTOOL_OPTS@,$LIBTOOL_OPTS,;t t |
| 22862 | s,@LIB_CREATE@,$LIB_CREATE,;t t |
| 22863 | s,@LIB_OBJECT@,$LIB_OBJECT,;t t |
| 22864 | s,@LIB_SUFFIX@,$LIB_SUFFIX,;t t |
| 22865 | s,@LIB_PREP@,$LIB_PREP,;t t |
| 22866 | s,@LIB_CLEAN@,$LIB_CLEAN,;t t |
| 22867 | s,@LIB_COMPILE@,$LIB_COMPILE,;t t |
| 22868 | s,@LIB_LINK@,$LIB_LINK,;t t |
| 22869 | s,@LIB_INSTALL@,$LIB_INSTALL,;t t |
| 22870 | s,@LIB_UNINSTALL@,$LIB_UNINSTALL,;t t |
| 22871 | s,@DFT_LWR_MODEL@,$DFT_LWR_MODEL,;t t |
| 22872 | s,@DFT_UPR_MODEL@,$DFT_UPR_MODEL,;t t |
| 22873 | s,@TICS_NAME@,$TICS_NAME,;t t |
| 22874 | s,@TINFO_NAME@,$TINFO_NAME,;t t |
| 22875 | s,@LIB_NAME@,$LIB_NAME,;t t |
| 22876 | s,@LIB_PREFIX@,$LIB_PREFIX,;t t |
| 22877 | s,@CC_G_OPT@,$CC_G_OPT,;t t |
| 22878 | s,@CXX_G_OPT@,$CXX_G_OPT,;t t |
| 22879 | s,@LD_MODEL@,$LD_MODEL,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22880 | s,@shlibdir@,$shlibdir,;t t |
| 22881 | s,@MAKE_DLLS@,$MAKE_DLLS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22882 | s,@CC_SHARED_OPTS@,$CC_SHARED_OPTS,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22883 | s,@LD_RPATH_OPT@,$LD_RPATH_OPT,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22884 | s,@LD_SHARED_OPTS@,$LD_SHARED_OPTS,;t t |
| 22885 | s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22886 | s,@RM_SHARED_OPTS@,$RM_SHARED_OPTS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22887 | s,@LINK_PROGS@,$LINK_PROGS,;t t |
| 22888 | s,@LINK_TESTS@,$LINK_TESTS,;t t |
| 22889 | s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t |
| 22890 | s,@LOCAL_LDFLAGS@,$LOCAL_LDFLAGS,;t t |
| 22891 | s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t |
| 22892 | s,@INSTALL_LIB@,$INSTALL_LIB,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22893 | s,@RPATH_LIST@,$RPATH_LIST,;t t |
| 22894 | s,@EXPORT_SYMS@,$EXPORT_SYMS,;t t |
| 22895 | s,@RESULTING_SYMS@,$RESULTING_SYMS,;t t |
| 22896 | s,@VERSIONED_SYMS@,$VERSIONED_SYMS,;t t |
| 22897 | s,@WILDCARD_SYMS@,$WILDCARD_SYMS,;t t |
| 22898 | s,@cf_ldd_prog@,$cf_ldd_prog,;t t |
| 22899 | s,@EXTRA_SUFFIX@,$EXTRA_SUFFIX,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22900 | s,@TERMINFO_SRC@,$TERMINFO_SRC,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22901 | s,@NCURSES_USE_DATABASE@,$NCURSES_USE_DATABASE,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22902 | s,@FALLBACK_LIST@,$FALLBACK_LIST,;t t |
| 22903 | s,@WHICH_XTERM@,$WHICH_XTERM,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22904 | s,@XTERM_KBS@,$XTERM_KBS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22905 | s,@TERMINFO_DIRS@,$TERMINFO_DIRS,;t t |
| 22906 | s,@TERMINFO@,$TERMINFO,;t t |
| 22907 | s,@MAKE_TERMINFO@,$MAKE_TERMINFO,;t t |
| 22908 | s,@USE_BIG_STRINGS@,$USE_BIG_STRINGS,;t t |
| 22909 | s,@TERMPATH@,$TERMPATH,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22910 | s,@NCURSES_USE_TERMCAP@,$NCURSES_USE_TERMCAP,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22911 | s,@BROKEN_LINKER@,$BROKEN_LINKER,;t t |
| 22912 | s,@NCURSES_CH_T@,$NCURSES_CH_T,;t t |
| 22913 | s,@NCURSES_LIBUTF8@,$NCURSES_LIBUTF8,;t t |
| 22914 | s,@NEED_WCHAR_H@,$NEED_WCHAR_H,;t t |
| 22915 | s,@NCURSES_MBSTATE_T@,$NCURSES_MBSTATE_T,;t t |
| 22916 | s,@NCURSES_WCHAR_T@,$NCURSES_WCHAR_T,;t t |
| 22917 | s,@NCURSES_WINT_T@,$NCURSES_WINT_T,;t t |
| 22918 | s,@NCURSES_OK_WCHAR_T@,$NCURSES_OK_WCHAR_T,;t t |
| 22919 | s,@NCURSES_OK_WINT_T@,$NCURSES_OK_WINT_T,;t t |
| 22920 | s,@cf_cv_enable_lp64@,$cf_cv_enable_lp64,;t t |
| 22921 | s,@NCURSES_TPARM_VARARGS@,$NCURSES_TPARM_VARARGS,;t t |
| 22922 | s,@NCURSES_BOOL@,$NCURSES_BOOL,;t t |
| 22923 | s,@TERMINFO_CAPS@,$TERMINFO_CAPS,;t t |
| 22924 | s,@NCURSES_OSPEED@,$NCURSES_OSPEED,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22925 | s,@NCURSES_CCHARW_MAX@,$NCURSES_CCHARW_MAX,;t t |
| 22926 | s,@NCURSES_TPARM_ARG@,$NCURSES_TPARM_ARG,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22927 | s,@MANPAGE_RENAMES@,$MANPAGE_RENAMES,;t t |
| 22928 | s,@NCURSES_EXT_FUNCS@,$NCURSES_EXT_FUNCS,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22929 | s,@GENERATED_EXT_FUNCS@,$GENERATED_EXT_FUNCS,;t t |
| 22930 | s,@NCURSES_SP_FUNCS@,$NCURSES_SP_FUNCS,;t t |
| 22931 | s,@GENERATED_SP_FUNCS@,$GENERATED_SP_FUNCS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22932 | s,@NCURSES_CONST@,$NCURSES_CONST,;t t |
| 22933 | s,@NCURSES_EXT_COLORS@,$NCURSES_EXT_COLORS,;t t |
| 22934 | s,@NCURSES_MOUSE_VERSION@,$NCURSES_MOUSE_VERSION,;t t |
| 22935 | s,@NCURSES_SBOOL@,$NCURSES_SBOOL,;t t |
| 22936 | s,@NCURSES_XNAMES@,$NCURSES_XNAMES,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22937 | s,@NCURSES_INTEROP_FUNCS@,$NCURSES_INTEROP_FUNCS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22938 | s,@PTHREAD@,$PTHREAD,;t t |
| 22939 | s,@cf_cv_enable_reentrant@,$cf_cv_enable_reentrant,;t t |
| 22940 | s,@cf_cv_enable_opaque@,$cf_cv_enable_opaque,;t t |
| 22941 | s,@NCURSES_OPAQUE@,$NCURSES_OPAQUE,;t t |
| 22942 | s,@NCURSES_SIZE_T@,$NCURSES_SIZE_T,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22943 | s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t |
| 22944 | s,@ECHO_LT@,$ECHO_LT,;t t |
| 22945 | s,@ECHO_LD@,$ECHO_LD,;t t |
| 22946 | s,@RULE_CC@,$RULE_CC,;t t |
| 22947 | s,@SHOW_CC@,$SHOW_CC,;t t |
| 22948 | s,@ECHO_CC@,$ECHO_CC,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22949 | s,@ECHO_LINK@,$ECHO_LINK,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22950 | s,@ADAFLAGS@,$ADAFLAGS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22951 | s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t |
| 22952 | s,@EXTRA_CXXFLAGS@,$EXTRA_CXXFLAGS,;t t |
| 22953 | s,@ADA_TRACE@,$ADA_TRACE,;t t |
| 22954 | s,@MATH_LIB@,$MATH_LIB,;t t |
| 22955 | s,@NCURSES_INLINE@,$NCURSES_INLINE,;t t |
| 22956 | s,@cf_cv_typeof_chtype@,$cf_cv_typeof_chtype,;t t |
| 22957 | s,@cf_cv_1UL@,$cf_cv_1UL,;t t |
| 22958 | s,@cf_cv_typeof_mmask_t@,$cf_cv_typeof_mmask_t,;t t |
| 22959 | s,@HAVE_VSSCANF@,$HAVE_VSSCANF,;t t |
| 22960 | s,@TEST_LIBS@,$TEST_LIBS,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22961 | s,@TEST_LIBS2@,$TEST_LIBS2,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22962 | s,@CXXCPP@,$CXXCPP,;t t |
| 22963 | s,@CXXLDFLAGS@,$CXXLDFLAGS,;t t |
| 22964 | s,@CXX_AR@,$CXX_AR,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22965 | s,@CXX_ARFLAGS@,$CXX_ARFLAGS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22966 | s,@CXXLIBS@,$CXXLIBS,;t t |
| 22967 | s,@USE_CXX_BOOL@,$USE_CXX_BOOL,;t t |
| 22968 | s,@gnat_exists@,$gnat_exists,;t t |
| 22969 | s,@M4_exists@,$M4_exists,;t t |
| 22970 | s,@cf_ada_make@,$cf_ada_make,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22971 | s,@GNATPREP_OPTS@,$GNATPREP_OPTS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22972 | s,@cf_compile_generics@,$cf_compile_generics,;t t |
| 22973 | s,@cf_generic_objects@,$cf_generic_objects,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22974 | s,@USE_GNAT_SIGINT@,$USE_GNAT_SIGINT,;t t |
| 22975 | s,@USE_OLD_MAKERULES@,$USE_OLD_MAKERULES,;t t |
| 22976 | s,@USE_GNAT_PROJECTS@,$USE_GNAT_PROJECTS,;t t |
| 22977 | s,@USE_GNAT_LIBRARIES@,$USE_GNAT_LIBRARIES,;t t |
| 22978 | s,@cf_ada_compiler@,$cf_ada_compiler,;t t |
| 22979 | s,@cf_ada_package@,$cf_ada_package,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22980 | s,@ADA_INCLUDE@,$ADA_INCLUDE,;t t |
| 22981 | s,@ADA_OBJECTS@,$ADA_OBJECTS,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22982 | s,@ADA_SHAREDLIB@,$ADA_SHAREDLIB,;t t |
| 22983 | s,@MAKE_ADA_SHAREDLIB@,$MAKE_ADA_SHAREDLIB,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22984 | s,@ACPPFLAGS@,$ACPPFLAGS,;t t |
| 22985 | s,@DFT_ARG_SUFFIX@,$DFT_ARG_SUFFIX,;t t |
| 22986 | s,@DFT_DEP_SUFFIX@,$DFT_DEP_SUFFIX,;t t |
| 22987 | s,@DFT_OBJ_SUBDIR@,$DFT_OBJ_SUBDIR,;t t |
| 22988 | s,@CXX_LIB_SUFFIX@,$CXX_LIB_SUFFIX,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22989 | s,@USE_ARG_SUFFIX@,$USE_ARG_SUFFIX,;t t |
| 22990 | s,@USE_CFG_SUFFIX@,$USE_CFG_SUFFIX,;t t |
| 22991 | s,@USE_LIB_SUFFIX@,$USE_LIB_SUFFIX,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22992 | s,@TICS_ARG_SUFFIX@,$TICS_ARG_SUFFIX,;t t |
| 22993 | s,@TICS_DEP_SUFFIX@,$TICS_DEP_SUFFIX,;t t |
| 22994 | s,@TICS_LIB_SUFFIX@,$TICS_LIB_SUFFIX,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 22995 | s,@TICS_LDFLAGS@,$TICS_LDFLAGS,;t t |
| 22996 | s,@TICS_LIBS@,$TICS_LIBS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 22997 | s,@TINFO_ARG_SUFFIX@,$TINFO_ARG_SUFFIX,;t t |
| 22998 | s,@TINFO_DEP_SUFFIX@,$TINFO_DEP_SUFFIX,;t t |
| 22999 | s,@TINFO_LIB_SUFFIX@,$TINFO_LIB_SUFFIX,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23000 | s,@TINFO_LDFLAGS@,$TINFO_LDFLAGS,;t t |
| 23001 | s,@TINFO_LIBS@,$TINFO_LIBS,;t t |
| 23002 | s,@TINFO_LDFLAGS2@,$TINFO_LDFLAGS2,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23003 | s,@LDFLAGS_STATIC@,$LDFLAGS_STATIC,;t t |
| 23004 | s,@LDFLAGS_SHARED@,$LDFLAGS_SHARED,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23005 | s,@includesubdir@,$includesubdir,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23006 | s,@WITH_OVERWRITE@,$WITH_OVERWRITE,;t t |
| 23007 | s,@TICS_LIST@,$TICS_LIST,;t t |
| 23008 | s,@TINFO_LIST@,$TINFO_LIST,;t t |
| 23009 | s,@SHLIB_LIST@,$SHLIB_LIST,;t t |
| 23010 | s,@NCURSES_TREE@,$NCURSES_TREE,;t t |
| 23011 | s,@TEST_ARGS@,$TEST_ARGS,;t t |
| 23012 | s,@TEST_DEPS@,$TEST_DEPS,;t t |
| 23013 | s,@TEST_ARG2@,$TEST_ARG2,;t t |
| 23014 | s,@TEST_DEP2@,$TEST_DEP2,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23015 | s,@PC_MODULES_TO_MAKE@,$PC_MODULES_TO_MAKE,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23016 | s,@ADA_SUBDIRS@,$ADA_SUBDIRS,;t t |
| 23017 | s,@DIRS_TO_MAKE@,$DIRS_TO_MAKE,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23018 | s,@NCURSES_SHLIB2@,$NCURSES_SHLIB2,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23019 | s,@HAVE_TCGETATTR@,$HAVE_TCGETATTR,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23020 | s,@HAVE_STDINT_H@,$HAVE_STDINT_H,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23021 | s,@HAVE_TERMIO_H@,$HAVE_TERMIO_H,;t t |
| 23022 | s,@HAVE_TERMIOS_H@,$HAVE_TERMIOS_H,;t t |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23023 | s,@cross_compiling@,$cross_compiling,;t t |
| 23024 | s,@TIC_PATH@,$TIC_PATH,;t t |
| 23025 | s,@MAKE_TESTS@,$MAKE_TESTS,;t t |
| 23026 | s,@ADAHTML_DIR@,$ADAHTML_DIR,;t t |
| 23027 | s,@PANEL_NAME@,$PANEL_NAME,;t t |
| 23028 | s,@MENU_NAME@,$MENU_NAME,;t t |
| 23029 | s,@FORM_NAME@,$FORM_NAME,;t t |
| 23030 | s,@CXX_NAME@,$CXX_NAME,;t t |
| 23031 | s,@PKG_CFLAGS@,$PKG_CFLAGS,;t t |
| 23032 | s,@MISC_INSTALL_DATA@,$MISC_INSTALL_DATA,;t t |
| 23033 | s,@MISC_UNINSTALL_DATA@,$MISC_UNINSTALL_DATA,;t t |
| 23034 | s,@UNALTERED_SYMS@,$UNALTERED_SYMS,;t t |
| 23035 | s,@ADAGEN_LDFLAGS@,$ADAGEN_LDFLAGS,;t t |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23036 | CEOF |
| 23037 | |
| 23038 | EOF |
| 23039 | |
| 23040 | cat >>$CONFIG_STATUS <<\EOF |
| 23041 | # Split the substitutions into bite-sized pieces for seds with |
| 23042 | # small command number limits, like on Digital OSF/1 and HP-UX. |
| 23043 | ac_max_sed_lines=48 |
| 23044 | ac_sed_frag=1 # Number of current file. |
| 23045 | ac_beg=1 # First line for current file. |
| 23046 | ac_end=$ac_max_sed_lines # Line after last line for current file. |
| 23047 | ac_more_lines=: |
| 23048 | ac_sed_cmds= |
| 23049 | while $ac_more_lines; do |
| 23050 | if test $ac_beg -gt 1; then |
| 23051 | sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag |
| 23052 | else |
| 23053 | sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag |
| 23054 | fi |
| 23055 | if test ! -s $tmp/subs.frag; then |
| 23056 | ac_more_lines=false |
| 23057 | else |
| 23058 | # The purpose of the label and of the branching condition is to |
| 23059 | # speed up the sed processing (if there are no `@' at all, there |
| 23060 | # is no need to browse any of the substitutions). |
| 23061 | # These are the two extra sed commands mentioned above. |
| 23062 | (echo ':t |
| 23063 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed |
| 23064 | if test -z "$ac_sed_cmds"; then |
| 23065 | ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed" |
| 23066 | else |
| 23067 | ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed" |
| 23068 | fi |
| 23069 | ac_sed_frag=`expr $ac_sed_frag + 1` |
| 23070 | ac_beg=$ac_end |
| 23071 | ac_end=`expr $ac_end + $ac_max_sed_lines` |
| 23072 | fi |
| 23073 | done |
| 23074 | if test -z "$ac_sed_cmds"; then |
| 23075 | ac_sed_cmds=cat |
| 23076 | fi |
| 23077 | fi # test -n "$CONFIG_FILES" |
| 23078 | |
| 23079 | EOF |
| 23080 | cat >>$CONFIG_STATUS <<\EOF |
| 23081 | for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue |
| 23082 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
| 23083 | case $ac_file in |
| 23084 | - | *:- | *:-:* ) # input from stdin |
| 23085 | cat >$tmp/stdin |
| 23086 | ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 23087 | ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; |
| 23088 | *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 23089 | ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; |
| 23090 | * ) ac_file_in=$ac_file.in ;; |
| 23091 | esac |
| 23092 | |
| 23093 | # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories. |
| 23094 | ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 23095 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 23096 | X"$ac_file" : 'X\(//\)$' \| \ |
| 23097 | X"$ac_file" : 'X\(/\)' \| \ |
| 23098 | . : '\(.\)' 2>/dev/null || |
| 23099 | echo X"$ac_file" | |
| 23100 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } |
| 23101 | /^X\(\/\/\)[^/].*/{ s//\1/; q; } |
| 23102 | /^X\(\/\/\)$/{ s//\1/; q; } |
| 23103 | /^X\(\/\).*/{ s//\1/; q; } |
| 23104 | s/.*/./; q'` |
| 23105 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 23106 | { case "$ac_dir" in |
| 23107 | [\\/]* | ?:[\\/]* ) as_incr_dir=;; |
| 23108 | *) as_incr_dir=.;; |
| 23109 | esac |
| 23110 | as_dummy="$ac_dir" |
| 23111 | for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do |
| 23112 | case $as_mkdir_dir in |
| 23113 | # Skip DOS drivespec |
| 23114 | ?:) as_incr_dir=$as_mkdir_dir ;; |
| 23115 | *) |
| 23116 | as_incr_dir=$as_incr_dir/$as_mkdir_dir |
| 23117 | test -d "$as_incr_dir" || mkdir "$as_incr_dir" |
| 23118 | ;; |
| 23119 | esac |
| 23120 | done; } |
| 23121 | |
| 23122 | ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`" |
| 23123 | # A "../" for each directory in $ac_dir_suffix. |
| 23124 | ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'` |
| 23125 | else |
| 23126 | ac_dir_suffix= ac_dots= |
| 23127 | fi |
| 23128 | |
| 23129 | case $srcdir in |
| 23130 | .) ac_srcdir=. |
| 23131 | if test -z "$ac_dots"; then |
| 23132 | ac_top_srcdir=. |
| 23133 | else |
| 23134 | ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'` |
| 23135 | fi ;; |
| 23136 | [\\/]* | ?:[\\/]* ) |
| 23137 | ac_srcdir=$srcdir$ac_dir_suffix; |
| 23138 | ac_top_srcdir=$srcdir ;; |
| 23139 | *) # Relative path. |
| 23140 | ac_srcdir=$ac_dots$srcdir$ac_dir_suffix |
| 23141 | ac_top_srcdir=$ac_dots$srcdir ;; |
| 23142 | esac |
| 23143 | |
| 23144 | case $INSTALL in |
| 23145 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
| 23146 | *) ac_INSTALL=$ac_dots$INSTALL ;; |
| 23147 | esac |
| 23148 | |
| 23149 | if test x"$ac_file" != x-; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23150 | { echo "$as_me:23150: creating $ac_file" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23151 | echo "$as_me: creating $ac_file" >&6;} |
| 23152 | rm -f "$ac_file" |
| 23153 | fi |
| 23154 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 23155 | # use $as_me), people would be surprised to read: |
| 23156 | # /* config.h. Generated automatically by config.status. */ |
| 23157 | configure_input="Generated automatically from `echo $ac_file_in | |
| 23158 | sed 's,.*/,,'` by configure." |
| 23159 | |
| 23160 | # First look for the input files in the build tree, otherwise in the |
| 23161 | # src tree. |
| 23162 | ac_file_inputs=`IFS=: |
| 23163 | for f in $ac_file_in; do |
| 23164 | case $f in |
| 23165 | -) echo $tmp/stdin ;; |
| 23166 | [\\/$]*) |
| 23167 | # Absolute (can't be DOS-style, as IFS=:) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23168 | test -f "$f" || { { echo "$as_me:23168: error: cannot find input file: $f" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23169 | echo "$as_me: error: cannot find input file: $f" >&2;} |
| 23170 | { (exit 1); exit 1; }; } |
| 23171 | echo $f;; |
| 23172 | *) # Relative |
| 23173 | if test -f "$f"; then |
| 23174 | # Build tree |
| 23175 | echo $f |
| 23176 | elif test -f "$srcdir/$f"; then |
| 23177 | # Source tree |
| 23178 | echo $srcdir/$f |
| 23179 | else |
| 23180 | # /dev/null tree |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23181 | { { echo "$as_me:23181: error: cannot find input file: $f" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23182 | echo "$as_me: error: cannot find input file: $f" >&2;} |
| 23183 | { (exit 1); exit 1; }; } |
| 23184 | fi;; |
| 23185 | esac |
| 23186 | done` || { (exit 1); exit 1; } |
| 23187 | EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23188 | cat >>$CONFIG_STATUS <<\EOF |
| 23189 | ac_warn_datarootdir=no |
| 23190 | if test x"$ac_file" != x-; then |
| 23191 | for ac_item in $ac_file_inputs |
| 23192 | do |
| 23193 | ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item` |
| 23194 | if test -n "$ac_seen"; then |
| 23195 | ac_used=`grep '@datarootdir@' $ac_item` |
| 23196 | if test -z "$ac_used"; then |
| 23197 | { echo "$as_me:23197: WARNING: datarootdir was used implicitly but not set: |
| 23198 | $ac_seen" >&5 |
| 23199 | echo "$as_me: WARNING: datarootdir was used implicitly but not set: |
| 23200 | $ac_seen" >&2;} |
| 23201 | ac_warn_datarootdir=yes |
| 23202 | fi |
| 23203 | fi |
| 23204 | ac_seen=`grep '${datarootdir}' $ac_item` |
| 23205 | if test -n "$ac_seen"; then |
| 23206 | { echo "$as_me:23206: WARNING: datarootdir was used explicitly but not set: |
| 23207 | $ac_seen" >&5 |
| 23208 | echo "$as_me: WARNING: datarootdir was used explicitly but not set: |
| 23209 | $ac_seen" >&2;} |
| 23210 | ac_warn_datarootdir=yes |
| 23211 | fi |
| 23212 | done |
| 23213 | fi |
| 23214 | |
| 23215 | if test "x$ac_warn_datarootdir" = xyes; then |
| 23216 | ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'" |
| 23217 | fi |
| 23218 | |
| 23219 | EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23220 | cat >>$CONFIG_STATUS <<EOF |
| 23221 | sed "$ac_vpsub |
| 23222 | $extrasub |
| 23223 | EOF |
| 23224 | cat >>$CONFIG_STATUS <<\EOF |
| 23225 | :t |
| 23226 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
| 23227 | s,@configure_input@,$configure_input,;t t |
| 23228 | s,@srcdir@,$ac_srcdir,;t t |
| 23229 | s,@top_srcdir@,$ac_top_srcdir,;t t |
| 23230 | s,@INSTALL@,$ac_INSTALL,;t t |
| 23231 | " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out |
| 23232 | rm -f $tmp/stdin |
| 23233 | if test x"$ac_file" != x-; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23234 | cp $tmp/out $ac_file |
| 23235 | |
| 23236 | for ac_name in prefix exec_prefix datarootdir |
| 23237 | do |
| 23238 | ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file` |
| 23239 | if test -n "$ac_seen"; then |
| 23240 | ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file` |
| 23241 | if test -z "$ac_init"; then |
| 23242 | ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'` |
| 23243 | { echo "$as_me:23243: WARNING: Variable $ac_name is used but was not set: |
| 23244 | $ac_seen" >&5 |
| 23245 | echo "$as_me: WARNING: Variable $ac_name is used but was not set: |
| 23246 | $ac_seen" >&2;} |
| 23247 | fi |
| 23248 | fi |
| 23249 | done |
| 23250 | egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out |
| 23251 | egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out |
| 23252 | if test -s $tmp/out; then |
| 23253 | ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out` |
| 23254 | { echo "$as_me:23254: WARNING: Some variables may not be substituted: |
| 23255 | $ac_seen" >&5 |
| 23256 | echo "$as_me: WARNING: Some variables may not be substituted: |
| 23257 | $ac_seen" >&2;} |
| 23258 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23259 | else |
| 23260 | cat $tmp/out |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23261 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23262 | rm -f $tmp/out |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23263 | |
| 23264 | done |
| 23265 | EOF |
| 23266 | cat >>$CONFIG_STATUS <<\EOF |
| 23267 | |
| 23268 | # |
| 23269 | # CONFIG_HEADER section. |
| 23270 | # |
| 23271 | |
| 23272 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 23273 | # NAME is the cpp macro being defined and VALUE is the value it is being given. |
| 23274 | # |
| 23275 | # ac_d sets the value in "#define NAME VALUE" lines. |
| 23276 | ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 23277 | ac_dB='[ ].*$,\1#\2' |
| 23278 | ac_dC=' ' |
| 23279 | ac_dD=',;t' |
| 23280 | # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE". |
| 23281 | ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 23282 | ac_iB='\([ ]\),\1#\2define\3' |
| 23283 | ac_iC=' ' |
| 23284 | ac_iD='\4,;t' |
| 23285 | # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE". |
| 23286 | ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 23287 | ac_uB='$,\1#\2define\3' |
| 23288 | ac_uC=' ' |
| 23289 | ac_uD=',;t' |
| 23290 | |
| 23291 | for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue |
| 23292 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
| 23293 | case $ac_file in |
| 23294 | - | *:- | *:-:* ) # input from stdin |
| 23295 | cat >$tmp/stdin |
| 23296 | ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 23297 | ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; |
| 23298 | *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 23299 | ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; |
| 23300 | * ) ac_file_in=$ac_file.in ;; |
| 23301 | esac |
| 23302 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23303 | test x"$ac_file" != x- && { echo "$as_me:23303: creating $ac_file" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23304 | echo "$as_me: creating $ac_file" >&6;} |
| 23305 | |
| 23306 | # First look for the input files in the build tree, otherwise in the |
| 23307 | # src tree. |
| 23308 | ac_file_inputs=`IFS=: |
| 23309 | for f in $ac_file_in; do |
| 23310 | case $f in |
| 23311 | -) echo $tmp/stdin ;; |
| 23312 | [\\/$]*) |
| 23313 | # Absolute (can't be DOS-style, as IFS=:) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23314 | test -f "$f" || { { echo "$as_me:23314: error: cannot find input file: $f" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23315 | echo "$as_me: error: cannot find input file: $f" >&2;} |
| 23316 | { (exit 1); exit 1; }; } |
| 23317 | echo $f;; |
| 23318 | *) # Relative |
| 23319 | if test -f "$f"; then |
| 23320 | # Build tree |
| 23321 | echo $f |
| 23322 | elif test -f "$srcdir/$f"; then |
| 23323 | # Source tree |
| 23324 | echo $srcdir/$f |
| 23325 | else |
| 23326 | # /dev/null tree |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23327 | { { echo "$as_me:23327: error: cannot find input file: $f" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23328 | echo "$as_me: error: cannot find input file: $f" >&2;} |
| 23329 | { (exit 1); exit 1; }; } |
| 23330 | fi;; |
| 23331 | esac |
| 23332 | done` || { (exit 1); exit 1; } |
| 23333 | # Remove the trailing spaces. |
| 23334 | sed 's/[ ]*$//' $ac_file_inputs >$tmp/in |
| 23335 | |
| 23336 | EOF |
| 23337 | |
| 23338 | # Transform confdefs.h into a list of #define's. We won't use it as a sed |
| 23339 | # script, but as data to insert where we see @DEFS@. We expect AC_SAVE_DEFS to |
| 23340 | # be either 'cat' or 'sort'. |
| 23341 | cat confdefs.h | uniq >conftest.vals |
| 23342 | |
| 23343 | # Break up conftest.vals because some shells have a limit on |
| 23344 | # the size of here documents, and old seds have small limits too. |
| 23345 | |
| 23346 | rm -f conftest.tail |
| 23347 | echo ' rm -f conftest.frag' >> $CONFIG_STATUS |
| 23348 | while grep . conftest.vals >/dev/null |
| 23349 | do |
| 23350 | # Write chunks of a limited-size here document to conftest.frag. |
| 23351 | echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 23352 | sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS |
| 23353 | echo 'CEOF' >> $CONFIG_STATUS |
| 23354 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 23355 | rm -f conftest.vals |
| 23356 | mv conftest.tail conftest.vals |
| 23357 | done |
| 23358 | rm -f conftest.vals |
| 23359 | |
| 23360 | # Run sed to substitute the contents of conftest.frag into $tmp/in at the |
| 23361 | # marker @DEFS@. |
| 23362 | echo ' cat >> conftest.edit <<CEOF |
| 23363 | /@DEFS@/r conftest.frag |
| 23364 | /@DEFS@/d |
| 23365 | CEOF |
| 23366 | sed -f conftest.edit $tmp/in > $tmp/out |
| 23367 | rm -f $tmp/in |
| 23368 | mv $tmp/out $tmp/in |
| 23369 | rm -f conftest.edit conftest.frag |
| 23370 | ' >> $CONFIG_STATUS |
| 23371 | |
| 23372 | cat >>$CONFIG_STATUS <<\EOF |
| 23373 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 23374 | # use $as_me), people would be surprised to read: |
| 23375 | # /* config.h. Generated automatically by config.status. */ |
| 23376 | if test x"$ac_file" = x-; then |
| 23377 | echo "/* Generated automatically by configure. */" >$tmp/config.h |
| 23378 | else |
| 23379 | echo "/* $ac_file. Generated automatically by configure. */" >$tmp/config.h |
| 23380 | fi |
| 23381 | cat $tmp/in >>$tmp/config.h |
| 23382 | rm -f $tmp/in |
| 23383 | if test x"$ac_file" != x-; then |
| 23384 | if cmp -s $ac_file $tmp/config.h 2>/dev/null; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23385 | { echo "$as_me:23385: $ac_file is unchanged" >&5 |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23386 | echo "$as_me: $ac_file is unchanged" >&6;} |
| 23387 | else |
| 23388 | ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 23389 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 23390 | X"$ac_file" : 'X\(//\)$' \| \ |
| 23391 | X"$ac_file" : 'X\(/\)' \| \ |
| 23392 | . : '\(.\)' 2>/dev/null || |
| 23393 | echo X"$ac_file" | |
| 23394 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } |
| 23395 | /^X\(\/\/\)[^/].*/{ s//\1/; q; } |
| 23396 | /^X\(\/\/\)$/{ s//\1/; q; } |
| 23397 | /^X\(\/\).*/{ s//\1/; q; } |
| 23398 | s/.*/./; q'` |
| 23399 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 23400 | { case "$ac_dir" in |
| 23401 | [\\/]* | ?:[\\/]* ) as_incr_dir=;; |
| 23402 | *) as_incr_dir=.;; |
| 23403 | esac |
| 23404 | as_dummy="$ac_dir" |
| 23405 | for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do |
| 23406 | case $as_mkdir_dir in |
| 23407 | # Skip DOS drivespec |
| 23408 | ?:) as_incr_dir=$as_mkdir_dir ;; |
| 23409 | *) |
| 23410 | as_incr_dir=$as_incr_dir/$as_mkdir_dir |
| 23411 | test -d "$as_incr_dir" || mkdir "$as_incr_dir" |
| 23412 | ;; |
| 23413 | esac |
| 23414 | done; } |
| 23415 | |
| 23416 | fi |
| 23417 | rm -f $ac_file |
| 23418 | mv $tmp/config.h $ac_file |
| 23419 | fi |
| 23420 | else |
| 23421 | cat $tmp/config.h |
| 23422 | rm -f $tmp/config.h |
| 23423 | fi |
| 23424 | done |
| 23425 | EOF |
| 23426 | cat >>$CONFIG_STATUS <<\EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23427 | # |
| 23428 | # CONFIG_COMMANDS section. |
| 23429 | # |
| 23430 | for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue |
| 23431 | ac_dest=`echo "$ac_file" | sed 's,:.*,,'` |
| 23432 | ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'` |
| 23433 | |
| 23434 | case $ac_dest in |
| 23435 | default ) |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23436 | if test "x$cf_with_tests" != xno ; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23437 | |
| 23438 | for cf_dir in test |
| 23439 | do |
| 23440 | if test ! -d $srcdir/$cf_dir; then |
| 23441 | continue |
| 23442 | elif test -f $srcdir/$cf_dir/programs; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23443 | $AWK -f $srcdir/test/mk-test.awk INSTALL=no ECHO_LINK="$ECHO_LD" $srcdir/$cf_dir/programs >>$cf_dir/Makefile |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23444 | fi |
| 23445 | done |
| 23446 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23447 | fi |
| 23448 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23449 | cf_prefix=$LIB_PREFIX |
| 23450 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23451 | case $cf_cv_shlib_version in |
| 23452 | (cygdll|msysdll|mingw) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23453 | TINFO_NAME=$TINFO_ARG_SUFFIX |
| 23454 | TINFO_SUFFIX=.dll |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23455 | ;; |
| 23456 | esac |
| 23457 | |
| 23458 | if test -n "$TINFO_SUFFIX" ; then |
| 23459 | case $TINFO_SUFFIX in |
| 23460 | (tw*) |
| 23461 | TINFO_NAME="${TINFO_NAME}tw${EXTRA_SUFFIX}" |
| 23462 | TINFO_SUFFIX=`echo $TINFO_SUFFIX | sed 's/^tw'$EXTRA_SUFFIX'//'` |
| 23463 | ;; |
| 23464 | (t*) |
| 23465 | TINFO_NAME="${TINFO_NAME}t${EXTRA_SUFFIX}" |
| 23466 | TINFO_SUFFIX=`echo $TINFO_SUFFIX | sed 's/^t'$EXTRA_SUFFIX'//'` |
| 23467 | ;; |
| 23468 | (w*) |
| 23469 | TINFO_NAME="${TINFO_NAME}w${EXTRA_SUFFIX}" |
| 23470 | TINFO_SUFFIX=`echo $TINFO_SUFFIX | sed 's/^w'$EXTRA_SUFFIX'//'` |
| 23471 | ;; |
| 23472 | esac |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23473 | fi |
| 23474 | |
| 23475 | for cf_dir in $SRC_SUBDIRS |
| 23476 | do |
| 23477 | if test ! -d $srcdir/$cf_dir ; then |
| 23478 | continue |
| 23479 | elif test -f $srcdir/$cf_dir/modules; then |
| 23480 | |
| 23481 | SHARED_LIB= |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23482 | Libs_To_Make= |
| 23483 | |
| 23484 | cf_sed_options= |
| 23485 | if test -n "${cf_cv_abi_version}" && test "x${cf_cv_abi_version}" != "x5" |
| 23486 | then |
| 23487 | cf_sed_options="$cf_sed_options -e \"s/NCURSES\\([WT]\\+\\)\?_/NCURSES\\1${cf_cv_abi_version}_/g\"" |
| 23488 | cf_sed_options="$cf_sed_options -e \"/deprecated in ABI${cf_cv_abi_version}/d\"" |
| 23489 | fi |
| 23490 | |
| 23491 | if test "x$WILDCARD_SYMS" = xno |
| 23492 | then |
| 23493 | cf_sed_options="$cf_sed_options -e \"s/_\*;//g\"" |
| 23494 | fi |
| 23495 | |
| 23496 | if test "x$cf_sed_options" != "x" |
| 23497 | then |
| 23498 | cat >>$cf_dir/Makefile <<CF_EOF |
| 23499 | |
| 23500 | # Generated by CF_LIB_RULES |
| 23501 | resulting.map: $UNALTERED_SYMS |
| 23502 | sed $cf_sed_options < $UNALTERED_SYMS >\$@ |
| 23503 | |
| 23504 | clean:: |
| 23505 | rm -f resulting.map |
| 23506 | CF_EOF |
| 23507 | fi |
| 23508 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23509 | for cf_item in $cf_LIST_MODELS |
| 23510 | do |
| 23511 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23512 | case X$cf_item in |
| 23513 | (Xlibtool) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23514 | cf_suffix='.la' |
| 23515 | cf_depsuf=$cf_suffix |
| 23516 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23517 | (Xdebug) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23518 | cf_suffix='_g.a' |
| 23519 | cf_depsuf=$cf_suffix |
| 23520 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23521 | (Xprofile) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23522 | cf_suffix='_p.a' |
| 23523 | cf_depsuf=$cf_suffix |
| 23524 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23525 | (Xshared) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23526 | case $cf_cv_system_name in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23527 | (aix[5-7]*) |
| 23528 | cf_suffix='.so' |
| 23529 | cf_depsuf=$cf_suffix |
| 23530 | ;; |
| 23531 | (cygwin*|msys*|mingw*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23532 | cf_suffix='.dll' |
| 23533 | cf_depsuf='.dll.a' |
| 23534 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23535 | (darwin*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23536 | cf_suffix='.dylib' |
| 23537 | cf_depsuf=$cf_suffix |
| 23538 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23539 | (hpux*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23540 | case $target in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23541 | (ia64*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23542 | cf_suffix='.so' |
| 23543 | cf_depsuf=$cf_suffix |
| 23544 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23545 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23546 | cf_suffix='.sl' |
| 23547 | cf_depsuf=$cf_suffix |
| 23548 | ;; |
| 23549 | esac |
| 23550 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23551 | (*) |
| 23552 | cf_suffix='.so' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23553 | cf_depsuf=$cf_suffix |
| 23554 | ;; |
| 23555 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23556 | ;; |
| 23557 | (*) |
| 23558 | cf_suffix='.a' |
| 23559 | cf_depsuf=$cf_suffix |
| 23560 | ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23561 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23562 | if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}" |
| 23563 | then |
| 23564 | cf_suffix="${LIB_SUFFIX}${EXTRA_SUFFIX}${cf_suffix}" |
| 23565 | cf_depsuf="${LIB_SUFFIX}${EXTRA_SUFFIX}${cf_depsuf}" |
| 23566 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23567 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23568 | cf_libname=$cf_dir |
| 23569 | test "$cf_dir" = c++ && cf_libname=ncurses++ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23570 | if test $cf_item = shared ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23571 | if test -n "${LIB_SUFFIX}" |
| 23572 | then |
| 23573 | cf_shared_suffix=`echo "$cf_suffix" | sed 's/^'"${USE_LIB_SUFFIX}"'//'` |
| 23574 | else |
| 23575 | cf_shared_suffix="$cf_suffix" |
| 23576 | fi |
| 23577 | if test "$cf_cv_do_symlinks" = yes ; then |
| 23578 | cf_version_name= |
| 23579 | |
| 23580 | case "$cf_cv_shlib_version" in |
| 23581 | (rel) |
| 23582 | cf_version_name=REL_VERSION |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23583 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23584 | (abi) |
| 23585 | cf_version_name=ABI_VERSION |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23586 | ;; |
| 23587 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23588 | |
| 23589 | if test -n "$cf_version_name" |
| 23590 | then |
| 23591 | case "$cf_cv_system_name" in |
| 23592 | (darwin*) |
| 23593 | # "w", etc? |
| 23594 | cf_suffix="${USE_LIB_SUFFIX}"'.${'$cf_version_name'}'"$cf_shared_suffix" |
| 23595 | ;; |
| 23596 | (*) |
| 23597 | cf_suffix="$cf_suffix"'.${'$cf_version_name'}' |
| 23598 | ;; |
| 23599 | esac |
| 23600 | fi |
| 23601 | if test -n "${USE_LIB_SUFFIX}" |
| 23602 | then |
| 23603 | cf_shared_suffix=`echo "$cf_suffix" | sed 's/^'"${USE_LIB_SUFFIX}"'//'` |
| 23604 | else |
| 23605 | cf_shared_suffix="$cf_suffix" |
| 23606 | fi |
| 23607 | fi |
| 23608 | # cygwin needs import library, and has unique naming convention |
| 23609 | # use autodetected ${cf_prefix} for import lib and static lib, but |
| 23610 | # use 'cyg' prefix for shared lib. |
| 23611 | case $cf_cv_shlib_version in |
| 23612 | (cygdll) |
| 23613 | cf_cygsuf=`echo "$cf_suffix" | sed -e 's/\.dll/\${ABI_VERSION}.dll/'` |
| 23614 | cf_add_lib="../lib/cyg${cf_libname}${cf_cygsuf}" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23615 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23616 | (msysdll) |
| 23617 | cf_cygsuf=`echo "$cf_suffix" | sed -e 's/\.dll/\${ABI_VERSION}.dll/'` |
| 23618 | cf_add_lib="../lib/msys-${cf_libname}${cf_cygsuf}" |
| 23619 | ;; |
| 23620 | (mingw) |
| 23621 | cf_cygsuf=`echo "$cf_suffix" | sed -e 's/\.dll/\${ABI_VERSION}.dll/'` |
| 23622 | cf_add_lib="../lib/lib${cf_libname}${cf_cygsuf}" |
| 23623 | ;; |
| 23624 | (*) |
| 23625 | cf_add_lib= |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23626 | ;; |
| 23627 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23628 | if test -n "$cf_add_lib" |
| 23629 | then |
| 23630 | Libs_To_Make="$Libs_To_Make $cf_add_lib" |
| 23631 | continue |
| 23632 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23633 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23634 | cf_add_lib="../lib/${cf_prefix}${cf_libname}${cf_suffix}" |
| 23635 | Libs_To_Make="$Libs_To_Make $cf_add_lib" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23636 | done |
| 23637 | |
| 23638 | if test $cf_dir = ncurses ; then |
| 23639 | cf_subsets="$LIB_SUBSETS" |
| 23640 | cf_r_parts="$cf_subsets" |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23641 | cf_liblist="$Libs_To_Make" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23642 | |
| 23643 | while test -n "$cf_r_parts" |
| 23644 | do |
| 23645 | cf_l_parts=`echo "$cf_r_parts" |sed -e 's/ .*$//'` |
| 23646 | cf_r_parts=`echo "$cf_r_parts" |sed -e 's/^[^ ]* //'` |
| 23647 | if test "$cf_l_parts" != "$cf_r_parts" ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23648 | cf_add_lib= |
| 23649 | case $cf_l_parts in |
| 23650 | (*termlib*) |
| 23651 | cf_add_lib=`echo $cf_liblist |sed -e s%${LIB_NAME}${USE_LIB_SUFFIX}%${TINFO_LIB_SUFFIX}%g` |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23652 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23653 | (*ticlib*) |
| 23654 | cf_add_lib=`echo $cf_liblist |sed -e s%${LIB_NAME}${USE_LIB_SUFFIX}%${TICS_LIB_SUFFIX}%g` |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23655 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23656 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23657 | break |
| 23658 | ;; |
| 23659 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23660 | if test -n "$cf_add_lib"; then |
| 23661 | Libs_To_Make="$cf_add_lib $Libs_To_Make" |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23662 | fi |
| 23663 | else |
| 23664 | break |
| 23665 | fi |
| 23666 | done |
| 23667 | else |
| 23668 | cf_subsets=`echo "$LIB_SUBSETS" | sed -e 's/^termlib.* //'` |
| 23669 | fi |
| 23670 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23671 | if test $cf_dir = c++; then |
| 23672 | if test "x$with_shared_cxx" != xyes && test -n "$cf_shared_suffix"; then |
| 23673 | cf_list= |
| 23674 | for cf_item in $Libs_To_Make |
| 23675 | do |
| 23676 | case $cf_item in |
| 23677 | (*.a) |
| 23678 | ;; |
| 23679 | (*) |
| 23680 | cf_item=`echo "$cf_item" | sed -e "s,"$cf_shared_suffix",.a,"` |
| 23681 | ;; |
| 23682 | esac |
| 23683 | for cf_test in $cf_list |
| 23684 | do |
| 23685 | if test "$cf_test" = "$cf_item" |
| 23686 | then |
| 23687 | cf_LIST_MODELS=`echo "$cf_LIST_MODELS" | sed -e 's/normal//'` |
| 23688 | cf_item= |
| 23689 | break |
| 23690 | fi |
| 23691 | done |
| 23692 | test -n "$cf_item" && cf_list="$cf_list $cf_item" |
| 23693 | done |
| 23694 | Libs_To_Make="$cf_list" |
| 23695 | fi |
| 23696 | fi |
| 23697 | |
| 23698 | sed -e "s%@Libs_To_Make@%$Libs_To_Make%" \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23699 | -e "s%@SHARED_LIB@%$SHARED_LIB%" \ |
| 23700 | $cf_dir/Makefile >$cf_dir/Makefile.out |
| 23701 | mv $cf_dir/Makefile.out $cf_dir/Makefile |
| 23702 | |
| 23703 | $AWK -f $srcdir/mk-0th.awk \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23704 | libname="${cf_dir}${LIB_SUFFIX}" subsets="$LIB_SUBSETS" ticlib="$TICS_LIB_SUFFIX" termlib="$TINFO_LIB_SUFFIX" \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23705 | $srcdir/$cf_dir/modules >>$cf_dir/Makefile |
| 23706 | |
| 23707 | for cf_subset in $cf_subsets |
| 23708 | do |
| 23709 | cf_subdirs= |
| 23710 | for cf_item in $cf_LIST_MODELS |
| 23711 | do |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23712 | |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23713 | echo "Appending rules for ${cf_item} model (${cf_dir}: ${cf_subset})" |
| 23714 | |
| 23715 | cf_ITEM=`echo "$cf_item" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` |
| 23716 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23717 | CXX_MODEL=$cf_ITEM |
| 23718 | if test "$CXX_MODEL" = SHARED; then |
| 23719 | case $cf_cv_shlib_version in |
| 23720 | (cygdll|msysdll|mingw) |
| 23721 | test "x$with_shared_cxx" = xno && test -n "$verbose" && echo " overriding CXX_MODEL to SHARED" 1>&6 |
| 23722 | |
| 23723 | echo "${as_me:-configure}:23723: testing overriding CXX_MODEL to SHARED ..." 1>&5 |
| 23724 | |
| 23725 | with_shared_cxx=yes |
| 23726 | ;; |
| 23727 | (*) |
| 23728 | test "x$with_shared_cxx" = xno && CXX_MODEL=NORMAL |
| 23729 | ;; |
| 23730 | esac |
| 23731 | fi |
| 23732 | |
| 23733 | case X$cf_item in |
| 23734 | (Xlibtool) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23735 | cf_suffix='.la' |
| 23736 | cf_depsuf=$cf_suffix |
| 23737 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23738 | (Xdebug) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23739 | cf_suffix='_g.a' |
| 23740 | cf_depsuf=$cf_suffix |
| 23741 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23742 | (Xprofile) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23743 | cf_suffix='_p.a' |
| 23744 | cf_depsuf=$cf_suffix |
| 23745 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23746 | (Xshared) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23747 | case $cf_cv_system_name in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23748 | (aix[5-7]*) |
| 23749 | cf_suffix='.so' |
| 23750 | cf_depsuf=$cf_suffix |
| 23751 | ;; |
| 23752 | (cygwin*|msys*|mingw*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23753 | cf_suffix='.dll' |
| 23754 | cf_depsuf='.dll.a' |
| 23755 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23756 | (darwin*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23757 | cf_suffix='.dylib' |
| 23758 | cf_depsuf=$cf_suffix |
| 23759 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23760 | (hpux*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23761 | case $target in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23762 | (ia64*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23763 | cf_suffix='.so' |
| 23764 | cf_depsuf=$cf_suffix |
| 23765 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23766 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23767 | cf_suffix='.sl' |
| 23768 | cf_depsuf=$cf_suffix |
| 23769 | ;; |
| 23770 | esac |
| 23771 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23772 | (*) |
| 23773 | cf_suffix='.so' |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23774 | cf_depsuf=$cf_suffix |
| 23775 | ;; |
| 23776 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23777 | ;; |
| 23778 | (*) |
| 23779 | cf_suffix='.a' |
| 23780 | cf_depsuf=$cf_suffix |
| 23781 | ;; |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23782 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23783 | if test -n "${LIB_SUFFIX}${EXTRA_SUFFIX}" |
| 23784 | then |
| 23785 | cf_suffix="${LIB_SUFFIX}${EXTRA_SUFFIX}${cf_suffix}" |
| 23786 | cf_depsuf="${LIB_SUFFIX}${EXTRA_SUFFIX}${cf_depsuf}" |
| 23787 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23788 | |
| 23789 | case $cf_item in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23790 | (libtool) cf_subdir='obj_lo' ;; |
| 23791 | (normal) cf_subdir='objects' ;; |
| 23792 | (debug) cf_subdir='obj_g' ;; |
| 23793 | (profile) cf_subdir='obj_p' ;; |
| 23794 | (shared) |
| 23795 | case $cf_cv_system_name in |
| 23796 | (cygwin|msys) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23797 | cf_subdir='objects' ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23798 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23799 | cf_subdir='obj_s' ;; |
| 23800 | esac |
| 23801 | esac |
| 23802 | |
| 23803 | # Test for case where we build libtinfo with a different name. |
| 23804 | cf_libname=$cf_dir |
| 23805 | if test $cf_dir = ncurses ; then |
| 23806 | case $cf_subset in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23807 | (*base*) |
| 23808 | cf_libname=${cf_libname}$USE_LIB_SUFFIX |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23809 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23810 | (*termlib*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23811 | cf_libname=$TINFO_LIB_SUFFIX |
| 23812 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23813 | (ticlib*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23814 | cf_libname=$TICS_LIB_SUFFIX |
| 23815 | ;; |
| 23816 | esac |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23817 | elif test $cf_dir = c++ ; then |
| 23818 | cf_libname=ncurses++$USE_LIB_SUFFIX |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23819 | else |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23820 | cf_libname=${cf_libname}$USE_LIB_SUFFIX |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23821 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23822 | if test -n "${USE_ARG_SUFFIX}" ; then |
| 23823 | # undo $USE_LIB_SUFFIX add-on in CF_LIB_SUFFIX |
| 23824 | cf_suffix=`echo $cf_suffix |sed -e "s%^${USE_LIB_SUFFIX}%%"` |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23825 | fi |
| 23826 | |
| 23827 | # These dependencies really are for development, not |
| 23828 | # builds, but they are useful in porting, too. |
| 23829 | cf_depend="../include/ncurses_cfg.h" |
| 23830 | if test "$srcdir" = "."; then |
| 23831 | cf_reldir="." |
| 23832 | else |
| 23833 | cf_reldir="\${srcdir}" |
| 23834 | fi |
| 23835 | |
| 23836 | if test -f $srcdir/$cf_dir/$cf_dir.priv.h; then |
| 23837 | cf_depend="$cf_depend $cf_reldir/$cf_dir.priv.h" |
| 23838 | elif test -f $srcdir/$cf_dir/curses.priv.h; then |
| 23839 | cf_depend="$cf_depend $cf_reldir/curses.priv.h" |
| 23840 | fi |
| 23841 | |
| 23842 | cf_dir_suffix= |
| 23843 | old_cf_suffix="$cf_suffix" |
| 23844 | if test "$cf_cv_shlib_version_infix" = yes ; then |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23845 | if test -n "$USE_LIB_SUFFIX" ; then |
| 23846 | case $USE_LIB_SUFFIX in |
| 23847 | (tw*) |
| 23848 | cf_libname=`echo $cf_libname | sed 's/tw'$EXTRA_SUFFIX'$//'` |
| 23849 | cf_suffix=`echo $cf_suffix | sed 's/^tw'$EXTRA_SUFFIX'//'` |
| 23850 | cf_dir_suffix=tw$EXTRA_SUFFIX |
| 23851 | ;; |
| 23852 | (t*) |
| 23853 | cf_libname=`echo $cf_libname | sed 's/t'$EXTRA_SUFFIX'$//'` |
| 23854 | cf_suffix=`echo $cf_suffix | sed 's/^t'$EXTRA_SUFFIX'//'` |
| 23855 | cf_dir_suffix=t$EXTRA_SUFFIX |
| 23856 | ;; |
| 23857 | (w*) |
| 23858 | cf_libname=`echo $cf_libname | sed 's/w'$EXTRA_SUFFIX'$//'` |
| 23859 | cf_suffix=`echo $cf_suffix | sed 's/^w'$EXTRA_SUFFIX'//'` |
| 23860 | cf_dir_suffix=w$EXTRA_SUFFIX |
| 23861 | ;; |
| 23862 | (*) |
| 23863 | cf_libname=`echo $cf_libname | sed 's/'$EXTRA_SUFFIX'$//'` |
| 23864 | cf_suffix=`echo $cf_suffix | sed 's/^'$EXTRA_SUFFIX'//'` |
| 23865 | cf_dir_suffix=$EXTRA_SUFFIX |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23866 | ;; |
| 23867 | esac |
| 23868 | fi |
| 23869 | fi |
| 23870 | |
| 23871 | $AWK -f $srcdir/mk-1st.awk \ |
| 23872 | name=${cf_libname}${cf_dir_suffix} \ |
| 23873 | traces=$LIB_TRACING \ |
| 23874 | MODEL=$cf_ITEM \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23875 | CXX_MODEL=$CXX_MODEL \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23876 | model=$cf_subdir \ |
| 23877 | prefix=$cf_prefix \ |
| 23878 | suffix=$cf_suffix \ |
| 23879 | subset=$cf_subset \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23880 | driver=$cf_cv_term_driver \ |
| 23881 | SymLink="$LN_S" \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23882 | TermlibRoot=$TINFO_NAME \ |
| 23883 | TermlibSuffix=$TINFO_SUFFIX \ |
| 23884 | ShlibVer=$cf_cv_shlib_version \ |
| 23885 | ShlibVerInfix=$cf_cv_shlib_version_infix \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23886 | ReLink=${cf_cv_do_relink:-no} \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23887 | DoLinks=$cf_cv_do_symlinks \ |
| 23888 | rmSoLocs=$cf_cv_rm_so_locs \ |
| 23889 | ldconfig="$LDCONFIG" \ |
| 23890 | overwrite=$WITH_OVERWRITE \ |
| 23891 | depend="$cf_depend" \ |
| 23892 | host="$host" \ |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23893 | libtool_version="$LIBTOOL_VERSION" \ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23894 | $srcdir/$cf_dir/modules >>$cf_dir/Makefile |
| 23895 | |
| 23896 | cf_suffix="$old_cf_suffix" |
| 23897 | |
| 23898 | for cf_subdir2 in $cf_subdirs lib |
| 23899 | do |
| 23900 | test $cf_subdir = $cf_subdir2 && break |
| 23901 | done |
| 23902 | test "${cf_subset}.${cf_subdir2}" != "${cf_subset}.${cf_subdir}" && \ |
| 23903 | $AWK -f $srcdir/mk-2nd.awk \ |
| 23904 | name=$cf_dir \ |
| 23905 | traces=$LIB_TRACING \ |
| 23906 | MODEL=$cf_ITEM \ |
| 23907 | model=$cf_subdir \ |
| 23908 | subset=$cf_subset \ |
| 23909 | srcdir=$srcdir \ |
| 23910 | echo=$WITH_ECHO \ |
| 23911 | crenames=$cf_cv_prog_CC_c_o \ |
| 23912 | cxxrenames=$cf_cv_prog_CXX_c_o \ |
| 23913 | $srcdir/$cf_dir/modules >>$cf_dir/Makefile |
| 23914 | cf_subdirs="$cf_subdirs $cf_subdir" |
| 23915 | done |
| 23916 | done |
| 23917 | fi |
| 23918 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23919 | echo ' cd '$cf_dir' && ${MAKE} ${TOP_MFLAGS} $@' >>Makefile |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23920 | done |
| 23921 | |
| 23922 | for cf_dir in $SRC_SUBDIRS |
| 23923 | do |
| 23924 | if test ! -d $srcdir/$cf_dir ; then |
| 23925 | continue |
| 23926 | fi |
| 23927 | |
| 23928 | if test -f $cf_dir/Makefile ; then |
| 23929 | case "$cf_dir" in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23930 | (Ada95) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23931 | echo 'libs \' >> Makefile |
| 23932 | echo 'install.libs \' >> Makefile |
| 23933 | echo 'uninstall.libs ::' >> Makefile |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23934 | echo ' cd '$cf_dir' && ${MAKE} ${TOP_MFLAGS} $@' >> Makefile |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23935 | ;; |
| 23936 | esac |
| 23937 | fi |
| 23938 | |
| 23939 | if test -f $srcdir/$cf_dir/modules; then |
| 23940 | echo >> Makefile |
| 23941 | if test -f $srcdir/$cf_dir/headers; then |
| 23942 | cat >> Makefile <<CF_EOF |
| 23943 | install.includes \\ |
| 23944 | uninstall.includes \\ |
| 23945 | CF_EOF |
| 23946 | fi |
| 23947 | if test "$cf_dir" != "c++" ; then |
| 23948 | echo 'lint \' >> Makefile |
| 23949 | fi |
| 23950 | cat >> Makefile <<CF_EOF |
| 23951 | libs \\ |
| 23952 | lintlib \\ |
| 23953 | install.libs \\ |
| 23954 | uninstall.libs \\ |
| 23955 | install.$cf_dir \\ |
| 23956 | uninstall.$cf_dir :: |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23957 | cd $cf_dir && \${MAKE} \${TOP_MFLAGS} \$@ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23958 | CF_EOF |
| 23959 | elif test -f $srcdir/$cf_dir/headers; then |
| 23960 | cat >> Makefile <<CF_EOF |
| 23961 | |
| 23962 | libs \\ |
| 23963 | install.libs \\ |
| 23964 | uninstall.libs \\ |
| 23965 | install.includes \\ |
| 23966 | uninstall.includes :: |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23967 | cd $cf_dir && \${MAKE} \${TOP_MFLAGS} \$@ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23968 | CF_EOF |
| 23969 | fi |
| 23970 | done |
| 23971 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23972 | if test "x$cf_with_db_install" = xyes; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23973 | cat >> Makefile <<CF_EOF |
| 23974 | |
| 23975 | install.libs uninstall.libs \\ |
| 23976 | install.data uninstall.data :: |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23977 | $MAKE_TERMINFO cd misc && \${MAKE} \${TOP_MFLAGS} \$@ |
| 23978 | CF_EOF |
| 23979 | else |
| 23980 | cat >> Makefile <<CF_EOF |
| 23981 | |
| 23982 | install.libs uninstall.libs :: |
| 23983 | cd misc && \${MAKE} \${TOP_MFLAGS} \$@ |
| 23984 | CF_EOF |
| 23985 | fi |
| 23986 | |
| 23987 | if test "x$cf_with_manpages" = xyes; then |
| 23988 | cat >> Makefile <<CF_EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23989 | |
| 23990 | install.man \\ |
| 23991 | uninstall.man :: |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 23992 | cd man && \${MAKE} \${TOP_MFLAGS} \$@ |
| 23993 | CF_EOF |
| 23994 | fi |
| 23995 | |
| 23996 | cat >> Makefile <<CF_EOF |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 23997 | |
| 23998 | distclean :: |
| 23999 | rm -f config.cache config.log config.status Makefile include/ncurses_cfg.h |
| 24000 | rm -f headers.sh headers.sed mk_shared_lib.sh |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24001 | rm -f edit_man.* man_alias.* |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24002 | rm -rf \${DIRS_TO_MAKE} |
| 24003 | CF_EOF |
| 24004 | |
| 24005 | # Special case: tack's manpage lives in its own directory. |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24006 | if test "x$cf_with_manpages" = xyes; then |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24007 | if test -d tack ; then |
| 24008 | if test -f $srcdir/$tack.h; then |
| 24009 | cat >> Makefile <<CF_EOF |
| 24010 | |
| 24011 | install.man \\ |
| 24012 | uninstall.man :: |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24013 | cd tack && \${MAKE} \${TOP_MFLAGS} \$@ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24014 | CF_EOF |
| 24015 | fi |
| 24016 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24017 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24018 | |
| 24019 | rm -f headers.sed headers.sh |
| 24020 | |
| 24021 | echo creating headers.sh |
| 24022 | cat >headers.sh <<CF_EOF |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24023 | #! $SHELL |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24024 | # This shell script is generated by the 'configure' script. It is invoked in a |
| 24025 | # subdirectory of the build tree. It generates a sed-script in the parent |
| 24026 | # directory that is used to adjust includes for header files that reside in a |
| 24027 | # subdirectory of /usr/include, etc. |
| 24028 | PRG="" |
| 24029 | while test \$# != 3 |
| 24030 | do |
| 24031 | PRG="\$PRG \$1"; shift |
| 24032 | done |
| 24033 | DST=\$1 |
| 24034 | REF=\$2 |
| 24035 | SRC=\$3 |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24036 | TMPSRC=\${TMPDIR:-/tmp}/\`basename \$SRC\`\$\$ |
| 24037 | TMPSED=\${TMPDIR:-/tmp}/headers.sed\$\$ |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24038 | echo installing \$SRC in \$DST |
| 24039 | CF_EOF |
| 24040 | |
| 24041 | if test $WITH_CURSES_H = yes; then |
| 24042 | cat >>headers.sh <<CF_EOF |
| 24043 | case \$DST in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24044 | (/*/include/*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24045 | END=\`basename \$DST\` |
| 24046 | for i in \`cat \$REF/../*/headers |fgrep -v "#"\` |
| 24047 | do |
| 24048 | NAME=\`basename \$i\` |
| 24049 | echo "s/<\$NAME>/<\$END\/\$NAME>/" >> \$TMPSED |
| 24050 | done |
| 24051 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24052 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24053 | echo "" >> \$TMPSED |
| 24054 | ;; |
| 24055 | esac |
| 24056 | CF_EOF |
| 24057 | |
| 24058 | else |
| 24059 | cat >>headers.sh <<CF_EOF |
| 24060 | case \$DST in |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24061 | (/*/include/*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24062 | END=\`basename \$DST\` |
| 24063 | for i in \`cat \$REF/../*/headers |fgrep -v "#"\` |
| 24064 | do |
| 24065 | NAME=\`basename \$i\` |
| 24066 | if test "\$NAME" = "curses.h" |
| 24067 | then |
| 24068 | echo "s/<curses.h>/<ncurses.h>/" >> \$TMPSED |
| 24069 | NAME=ncurses.h |
| 24070 | fi |
| 24071 | echo "s/<\$NAME>/<\$END\/\$NAME>/" >> \$TMPSED |
| 24072 | done |
| 24073 | ;; |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24074 | (*) |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24075 | echo "s/<curses.h>/<ncurses.h>/" >> \$TMPSED |
| 24076 | ;; |
| 24077 | esac |
| 24078 | CF_EOF |
| 24079 | fi |
| 24080 | cat >>headers.sh <<CF_EOF |
| 24081 | rm -f \$TMPSRC |
| 24082 | sed -f \$TMPSED \$SRC > \$TMPSRC |
| 24083 | NAME=\`basename \$SRC\` |
| 24084 | CF_EOF |
| 24085 | if test $WITH_CURSES_H != yes; then |
| 24086 | cat >>headers.sh <<CF_EOF |
| 24087 | test "\$NAME" = "curses.h" && NAME=ncurses.h |
| 24088 | CF_EOF |
| 24089 | fi |
| 24090 | cat >>headers.sh <<CF_EOF |
| 24091 | # Just in case someone gzip'd manpages, remove the conflicting copy. |
| 24092 | test -f \$DST/\$NAME.gz && rm -f \$DST/\$NAME.gz |
| 24093 | |
| 24094 | eval \$PRG \$TMPSRC \$DST/\$NAME |
| 24095 | rm -f \$TMPSRC \$TMPSED |
| 24096 | CF_EOF |
| 24097 | |
| 24098 | chmod 0755 headers.sh |
| 24099 | |
| 24100 | for cf_dir in $SRC_SUBDIRS |
| 24101 | do |
| 24102 | if test ! -d $srcdir/$cf_dir ; then |
| 24103 | continue |
| 24104 | fi |
| 24105 | |
| 24106 | if test -f $srcdir/$cf_dir/headers; then |
| 24107 | $AWK -f $srcdir/mk-hdr.awk \ |
| 24108 | subset="$LIB_SUBSETS" \ |
| 24109 | compat="$WITH_CURSES_H" \ |
| 24110 | $srcdir/$cf_dir/headers >>$cf_dir/Makefile |
| 24111 | fi |
| 24112 | |
| 24113 | if test -f $srcdir/$cf_dir/modules; then |
| 24114 | if test "$cf_dir" != "c++" ; then |
| 24115 | cat >>$cf_dir/Makefile <<"CF_EOF" |
| 24116 | depend : ${AUTO_SRC} |
| 24117 | makedepend -- ${CPPFLAGS} -- ${C_SRC} |
| 24118 | |
| 24119 | # DO NOT DELETE THIS LINE -- make depend depends on it. |
| 24120 | CF_EOF |
| 24121 | fi |
| 24122 | fi |
| 24123 | done |
| 24124 | |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24125 | if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = "xyes"; then |
| 24126 | if test -z "$USE_OLD_MAKERULES" ; then |
| 24127 | $AWK -f $srcdir/Ada95/mk-1st.awk <$srcdir/Ada95/src/modules >>Ada95/src/Makefile |
| 24128 | fi |
| 24129 | fi |
Amit Daniel Kachhap | e6a01f5 | 2011-07-20 11:45:59 +0530 | [diff] [blame] | 24130 | ;; |
| 24131 | esac |
| 24132 | done |
| 24133 | EOF |
| 24134 | |
| 24135 | cat >>$CONFIG_STATUS <<\EOF |
| 24136 | |
| 24137 | { (exit 0); exit 0; } |
| 24138 | EOF |
| 24139 | chmod +x $CONFIG_STATUS |
| 24140 | ac_clean_files=$ac_clean_files_save |
| 24141 | |
| 24142 | # configure is writing to config.log, and then calls config.status. |
| 24143 | # config.status does its own redirection, appending to config.log. |
| 24144 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 24145 | # by configure, so config.status won't be able to write to it; its |
| 24146 | # output is simply discarded. So we exec the FD to /dev/null, |
| 24147 | # effectively closing config.log, so it can be properly (re)opened and |
| 24148 | # appended to by config.status. When coming back to configure, we |
| 24149 | # need to make the FD available again. |
| 24150 | if test "$no_create" != yes; then |
| 24151 | ac_cs_success=: |
| 24152 | exec 5>/dev/null |
| 24153 | $SHELL $CONFIG_STATUS || ac_cs_success=false |
| 24154 | exec 5>>config.log |
| 24155 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 24156 | # would make configure fail if this is the last instruction. |
| 24157 | $ac_cs_success || { (exit 1); exit 1; } |
| 24158 | fi |
Steve Kondik | ae271bc | 2015-11-15 02:50:53 +0100 | [diff] [blame] | 24159 | ${MAKE:-make} preinstall |