PageRenderTime 64ms CodeModel.GetById 19ms RepoModel.GetById 0ms app.codeStats 2ms

/configure

https://github.com/OpenWebGlobe/mapcache
Shell | 16681 lines | 13107 code | 2228 blank | 1346 comment | 1598 complexity | 73bdf3fedc81a2340d07afcb744842c3 MD5 | raw file
  1. #! /bin/sh
  2. # Guess values for system-dependent variables and create Makefiles.
  3. # Generated by GNU Autoconf 2.69.
  4. #
  5. #
  6. # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
  7. #
  8. #
  9. # This configure script is free software; the Free Software Foundation
  10. # gives unlimited permission to copy, distribute and modify it.
  11. ## -------------------- ##
  12. ## M4sh Initialization. ##
  13. ## -------------------- ##
  14. # Be more Bourne compatible
  15. DUALCASE=1; export DUALCASE # for MKS sh
  16. if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
  17. emulate sh
  18. NULLCMD=:
  19. # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  20. # is contrary to our usage. Disable this feature.
  21. alias -g '${1+"$@"}'='"$@"'
  22. setopt NO_GLOB_SUBST
  23. else
  24. case `(set -o) 2>/dev/null` in #(
  25. *posix*) :
  26. set -o posix ;; #(
  27. *) :
  28. ;;
  29. esac
  30. fi
  31. as_nl='
  32. '
  33. export as_nl
  34. # Printing a long string crashes Solaris 7 /usr/bin/printf.
  35. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  36. as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
  37. as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
  38. # Prefer a ksh shell builtin over an external printf program on Solaris,
  39. # but without wasting forks for bash or zsh.
  40. if test -z "$BASH_VERSION$ZSH_VERSION" \
  41. && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
  42. as_echo='print -r --'
  43. as_echo_n='print -rn --'
  44. elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
  45. as_echo='printf %s\n'
  46. as_echo_n='printf %s'
  47. else
  48. if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
  49. as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
  50. as_echo_n='/usr/ucb/echo -n'
  51. else
  52. as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
  53. as_echo_n_body='eval
  54. arg=$1;
  55. case $arg in #(
  56. *"$as_nl"*)
  57. expr "X$arg" : "X\\(.*\\)$as_nl";
  58. arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
  59. esac;
  60. expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
  61. '
  62. export as_echo_n_body
  63. as_echo_n='sh -c $as_echo_n_body as_echo'
  64. fi
  65. export as_echo_body
  66. as_echo='sh -c $as_echo_body as_echo'
  67. fi
  68. # The user is always right.
  69. if test "${PATH_SEPARATOR+set}" != set; then
  70. PATH_SEPARATOR=:
  71. (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
  72. (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
  73. PATH_SEPARATOR=';'
  74. }
  75. fi
  76. # IFS
  77. # We need space, tab and new line, in precisely that order. Quoting is
  78. # there to prevent editors from complaining about space-tab.
  79. # (If _AS_PATH_WALK were called with IFS unset, it would disable word
  80. # splitting by setting IFS to empty value.)
  81. IFS=" "" $as_nl"
  82. # Find who we are. Look in the path if we contain no directory separator.
  83. as_myself=
  84. case $0 in #((
  85. *[\\/]* ) as_myself=$0 ;;
  86. *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  87. for as_dir in $PATH
  88. do
  89. IFS=$as_save_IFS
  90. test -z "$as_dir" && as_dir=.
  91. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
  92. done
  93. IFS=$as_save_IFS
  94. ;;
  95. esac
  96. # We did not find ourselves, most probably we were run as `sh COMMAND'
  97. # in which case we are not to be found in the path.
  98. if test "x$as_myself" = x; then
  99. as_myself=$0
  100. fi
  101. if test ! -f "$as_myself"; then
  102. $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
  103. exit 1
  104. fi
  105. # Unset variables that we do not need and which cause bugs (e.g. in
  106. # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
  107. # suppresses any "Segmentation fault" message there. '((' could
  108. # trigger a bug in pdksh 5.2.14.
  109. for as_var in BASH_ENV ENV MAIL MAILPATH
  110. do eval test x\${$as_var+set} = xset \
  111. && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
  112. done
  113. PS1='$ '
  114. PS2='> '
  115. PS4='+ '
  116. # NLS nuisances.
  117. LC_ALL=C
  118. export LC_ALL
  119. LANGUAGE=C
  120. export LANGUAGE
  121. # CDPATH.
  122. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
  123. # Use a proper internal environment variable to ensure we don't fall
  124. # into an infinite loop, continuously re-executing ourselves.
  125. if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
  126. _as_can_reexec=no; export _as_can_reexec;
  127. # We cannot yet assume a decent shell, so we have to provide a
  128. # neutralization value for shells without unset; and this also
  129. # works around shells that cannot unset nonexistent variables.
  130. # Preserve -v and -x to the replacement shell.
  131. BASH_ENV=/dev/null
  132. ENV=/dev/null
  133. (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
  134. case $- in # ((((
  135. *v*x* | *x*v* ) as_opts=-vx ;;
  136. *v* ) as_opts=-v ;;
  137. *x* ) as_opts=-x ;;
  138. * ) as_opts= ;;
  139. esac
  140. exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
  141. # Admittedly, this is quite paranoid, since all the known shells bail
  142. # out after a failed `exec'.
  143. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
  144. as_fn_exit 255
  145. fi
  146. # We don't want this to propagate to other subprocesses.
  147. { _as_can_reexec=; unset _as_can_reexec;}
  148. if test "x$CONFIG_SHELL" = x; then
  149. as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
  150. emulate sh
  151. NULLCMD=:
  152. # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
  153. # is contrary to our usage. Disable this feature.
  154. alias -g '\${1+\"\$@\"}'='\"\$@\"'
  155. setopt NO_GLOB_SUBST
  156. else
  157. case \`(set -o) 2>/dev/null\` in #(
  158. *posix*) :
  159. set -o posix ;; #(
  160. *) :
  161. ;;
  162. esac
  163. fi
  164. "
  165. as_required="as_fn_return () { (exit \$1); }
  166. as_fn_success () { as_fn_return 0; }
  167. as_fn_failure () { as_fn_return 1; }
  168. as_fn_ret_success () { return 0; }
  169. as_fn_ret_failure () { return 1; }
  170. exitcode=0
  171. as_fn_success || { exitcode=1; echo as_fn_success failed.; }
  172. as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
  173. as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
  174. as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
  175. if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
  176. else
  177. exitcode=1; echo positional parameters were not saved.
  178. fi
  179. test x\$exitcode = x0 || exit 1
  180. test -x / || exit 1"
  181. as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
  182. as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
  183. eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
  184. test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
  185. test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
  186. ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  187. ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
  188. ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
  189. PATH=/empty FPATH=/empty; export PATH FPATH
  190. test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
  191. || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1
  192. test \$(( 1 + 1 )) = 2 || exit 1"
  193. if (eval "$as_required") 2>/dev/null; then :
  194. as_have_required=yes
  195. else
  196. as_have_required=no
  197. fi
  198. if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
  199. else
  200. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  201. as_found=false
  202. for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
  203. do
  204. IFS=$as_save_IFS
  205. test -z "$as_dir" && as_dir=.
  206. as_found=:
  207. case $as_dir in #(
  208. /*)
  209. for as_base in sh bash ksh sh5; do
  210. # Try only shells that exist, to save several forks.
  211. as_shell=$as_dir/$as_base
  212. if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
  213. { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
  214. CONFIG_SHELL=$as_shell as_have_required=yes
  215. if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
  216. break 2
  217. fi
  218. fi
  219. done;;
  220. esac
  221. as_found=false
  222. done
  223. $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
  224. { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
  225. CONFIG_SHELL=$SHELL as_have_required=yes
  226. fi; }
  227. IFS=$as_save_IFS
  228. if test "x$CONFIG_SHELL" != x; then :
  229. export CONFIG_SHELL
  230. # We cannot yet assume a decent shell, so we have to provide a
  231. # neutralization value for shells without unset; and this also
  232. # works around shells that cannot unset nonexistent variables.
  233. # Preserve -v and -x to the replacement shell.
  234. BASH_ENV=/dev/null
  235. ENV=/dev/null
  236. (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
  237. case $- in # ((((
  238. *v*x* | *x*v* ) as_opts=-vx ;;
  239. *v* ) as_opts=-v ;;
  240. *x* ) as_opts=-x ;;
  241. * ) as_opts= ;;
  242. esac
  243. exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
  244. # Admittedly, this is quite paranoid, since all the known shells bail
  245. # out after a failed `exec'.
  246. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
  247. exit 255
  248. fi
  249. if test x$as_have_required = xno; then :
  250. $as_echo "$0: This script requires a shell more modern than all"
  251. $as_echo "$0: the shells that I found on your system."
  252. if test x${ZSH_VERSION+set} = xset ; then
  253. $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
  254. $as_echo "$0: be upgraded to zsh 4.3.4 or later."
  255. else
  256. $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
  257. $0: including any error possibly output before this
  258. $0: message. Then install a modern shell, or manually run
  259. $0: the script under such a shell if you do have one."
  260. fi
  261. exit 1
  262. fi
  263. fi
  264. fi
  265. SHELL=${CONFIG_SHELL-/bin/sh}
  266. export SHELL
  267. # Unset more variables known to interfere with behavior of common tools.
  268. CLICOLOR_FORCE= GREP_OPTIONS=
  269. unset CLICOLOR_FORCE GREP_OPTIONS
  270. ## --------------------- ##
  271. ## M4sh Shell Functions. ##
  272. ## --------------------- ##
  273. # as_fn_unset VAR
  274. # ---------------
  275. # Portably unset VAR.
  276. as_fn_unset ()
  277. {
  278. { eval $1=; unset $1;}
  279. }
  280. as_unset=as_fn_unset
  281. # as_fn_set_status STATUS
  282. # -----------------------
  283. # Set $? to STATUS, without forking.
  284. as_fn_set_status ()
  285. {
  286. return $1
  287. } # as_fn_set_status
  288. # as_fn_exit STATUS
  289. # -----------------
  290. # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
  291. as_fn_exit ()
  292. {
  293. set +e
  294. as_fn_set_status $1
  295. exit $1
  296. } # as_fn_exit
  297. # as_fn_mkdir_p
  298. # -------------
  299. # Create "$as_dir" as a directory, including parents if necessary.
  300. as_fn_mkdir_p ()
  301. {
  302. case $as_dir in #(
  303. -*) as_dir=./$as_dir;;
  304. esac
  305. test -d "$as_dir" || eval $as_mkdir_p || {
  306. as_dirs=
  307. while :; do
  308. case $as_dir in #(
  309. *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
  310. *) as_qdir=$as_dir;;
  311. esac
  312. as_dirs="'$as_qdir' $as_dirs"
  313. as_dir=`$as_dirname -- "$as_dir" ||
  314. $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  315. X"$as_dir" : 'X\(//\)[^/]' \| \
  316. X"$as_dir" : 'X\(//\)$' \| \
  317. X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
  318. $as_echo X"$as_dir" |
  319. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  320. s//\1/
  321. q
  322. }
  323. /^X\(\/\/\)[^/].*/{
  324. s//\1/
  325. q
  326. }
  327. /^X\(\/\/\)$/{
  328. s//\1/
  329. q
  330. }
  331. /^X\(\/\).*/{
  332. s//\1/
  333. q
  334. }
  335. s/.*/./; q'`
  336. test -d "$as_dir" && break
  337. done
  338. test -z "$as_dirs" || eval "mkdir $as_dirs"
  339. } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
  340. } # as_fn_mkdir_p
  341. # as_fn_executable_p FILE
  342. # -----------------------
  343. # Test if FILE is an executable regular file.
  344. as_fn_executable_p ()
  345. {
  346. test -f "$1" && test -x "$1"
  347. } # as_fn_executable_p
  348. # as_fn_append VAR VALUE
  349. # ----------------------
  350. # Append the text in VALUE to the end of the definition contained in VAR. Take
  351. # advantage of any shell optimizations that allow amortized linear growth over
  352. # repeated appends, instead of the typical quadratic growth present in naive
  353. # implementations.
  354. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
  355. eval 'as_fn_append ()
  356. {
  357. eval $1+=\$2
  358. }'
  359. else
  360. as_fn_append ()
  361. {
  362. eval $1=\$$1\$2
  363. }
  364. fi # as_fn_append
  365. # as_fn_arith ARG...
  366. # ------------------
  367. # Perform arithmetic evaluation on the ARGs, and store the result in the
  368. # global $as_val. Take advantage of shells that can avoid forks. The arguments
  369. # must be portable across $(()) and expr.
  370. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
  371. eval 'as_fn_arith ()
  372. {
  373. as_val=$(( $* ))
  374. }'
  375. else
  376. as_fn_arith ()
  377. {
  378. as_val=`expr "$@" || test $? -eq 1`
  379. }
  380. fi # as_fn_arith
  381. # as_fn_error STATUS ERROR [LINENO LOG_FD]
  382. # ----------------------------------------
  383. # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
  384. # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
  385. # script with STATUS, using 1 if that was 0.
  386. as_fn_error ()
  387. {
  388. as_status=$1; test $as_status -eq 0 && as_status=1
  389. if test "$4"; then
  390. as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  391. $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
  392. fi
  393. $as_echo "$as_me: error: $2" >&2
  394. as_fn_exit $as_status
  395. } # as_fn_error
  396. if expr a : '\(a\)' >/dev/null 2>&1 &&
  397. test "X`expr 00001 : '.*\(...\)'`" = X001; then
  398. as_expr=expr
  399. else
  400. as_expr=false
  401. fi
  402. if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
  403. as_basename=basename
  404. else
  405. as_basename=false
  406. fi
  407. if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
  408. as_dirname=dirname
  409. else
  410. as_dirname=false
  411. fi
  412. as_me=`$as_basename -- "$0" ||
  413. $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
  414. X"$0" : 'X\(//\)$' \| \
  415. X"$0" : 'X\(/\)' \| . 2>/dev/null ||
  416. $as_echo X/"$0" |
  417. sed '/^.*\/\([^/][^/]*\)\/*$/{
  418. s//\1/
  419. q
  420. }
  421. /^X\/\(\/\/\)$/{
  422. s//\1/
  423. q
  424. }
  425. /^X\/\(\/\).*/{
  426. s//\1/
  427. q
  428. }
  429. s/.*/./; q'`
  430. # Avoid depending upon Character Ranges.
  431. as_cr_letters='abcdefghijklmnopqrstuvwxyz'
  432. as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
  433. as_cr_Letters=$as_cr_letters$as_cr_LETTERS
  434. as_cr_digits='0123456789'
  435. as_cr_alnum=$as_cr_Letters$as_cr_digits
  436. as_lineno_1=$LINENO as_lineno_1a=$LINENO
  437. as_lineno_2=$LINENO as_lineno_2a=$LINENO
  438. eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
  439. test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
  440. # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
  441. sed -n '
  442. p
  443. /[$]LINENO/=
  444. ' <$as_myself |
  445. sed '
  446. s/[$]LINENO.*/&-/
  447. t lineno
  448. b
  449. :lineno
  450. N
  451. :loop
  452. s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
  453. t loop
  454. s/-\n.*//
  455. ' >$as_me.lineno &&
  456. chmod +x "$as_me.lineno" ||
  457. { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
  458. # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
  459. # already done that, so ensure we don't try to do so again and fall
  460. # in an infinite loop. This has already happened in practice.
  461. _as_can_reexec=no; export _as_can_reexec
  462. # Don't try to exec as it changes $[0], causing all sort of problems
  463. # (the dirname of $[0] is not the place where we might find the
  464. # original and so on. Autoconf is especially sensitive to this).
  465. . "./$as_me.lineno"
  466. # Exit status is that of the last command.
  467. exit
  468. }
  469. ECHO_C= ECHO_N= ECHO_T=
  470. case `echo -n x` in #(((((
  471. -n*)
  472. case `echo 'xy\c'` in
  473. *c*) ECHO_T=' ';; # ECHO_T is single tab character.
  474. xy) ECHO_C='\c';;
  475. *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
  476. ECHO_T=' ';;
  477. esac;;
  478. *)
  479. ECHO_N='-n';;
  480. esac
  481. rm -f conf$$ conf$$.exe conf$$.file
  482. if test -d conf$$.dir; then
  483. rm -f conf$$.dir/conf$$.file
  484. else
  485. rm -f conf$$.dir
  486. mkdir conf$$.dir 2>/dev/null
  487. fi
  488. if (echo >conf$$.file) 2>/dev/null; then
  489. if ln -s conf$$.file conf$$ 2>/dev/null; then
  490. as_ln_s='ln -s'
  491. # ... but there are two gotchas:
  492. # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
  493. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
  494. # In both cases, we have to default to `cp -pR'.
  495. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
  496. as_ln_s='cp -pR'
  497. elif ln conf$$.file conf$$ 2>/dev/null; then
  498. as_ln_s=ln
  499. else
  500. as_ln_s='cp -pR'
  501. fi
  502. else
  503. as_ln_s='cp -pR'
  504. fi
  505. rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
  506. rmdir conf$$.dir 2>/dev/null
  507. if mkdir -p . 2>/dev/null; then
  508. as_mkdir_p='mkdir -p "$as_dir"'
  509. else
  510. test -d ./-p && rmdir ./-p
  511. as_mkdir_p=false
  512. fi
  513. as_test_x='test -x'
  514. as_executable_p=as_fn_executable_p
  515. # Sed expression to map a string onto a valid CPP name.
  516. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
  517. # Sed expression to map a string onto a valid variable name.
  518. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
  519. SHELL=${CONFIG_SHELL-/bin/sh}
  520. test -n "$DJDIR" || exec 7<&0 </dev/null
  521. exec 6>&1
  522. # Name of the host.
  523. # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
  524. # so uname gets run too.
  525. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
  526. #
  527. # Initializations.
  528. #
  529. ac_default_prefix=/usr/local
  530. ac_clean_files=
  531. ac_config_libobj_dir=.
  532. LIBOBJS=
  533. cross_compiling=no
  534. subdirs=
  535. MFLAGS=
  536. MAKEFLAGS=
  537. # Identity of this package.
  538. PACKAGE_NAME=
  539. PACKAGE_TARNAME=
  540. PACKAGE_VERSION=
  541. PACKAGE_STRING=
  542. PACKAGE_BUGREPORT=
  543. PACKAGE_URL=
  544. ac_unique_file="Makefile.inc.in"
  545. # Factoring default headers for most tests.
  546. ac_includes_default="\
  547. #include <stdio.h>
  548. #ifdef HAVE_SYS_TYPES_H
  549. # include <sys/types.h>
  550. #endif
  551. #ifdef HAVE_SYS_STAT_H
  552. # include <sys/stat.h>
  553. #endif
  554. #ifdef STDC_HEADERS
  555. # include <stdlib.h>
  556. # include <stddef.h>
  557. #else
  558. # ifdef HAVE_STDLIB_H
  559. # include <stdlib.h>
  560. # endif
  561. #endif
  562. #ifdef HAVE_STRING_H
  563. # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
  564. # include <memory.h>
  565. # endif
  566. # include <string.h>
  567. #endif
  568. #ifdef HAVE_STRINGS_H
  569. # include <strings.h>
  570. #endif
  571. #ifdef HAVE_INTTYPES_H
  572. # include <inttypes.h>
  573. #endif
  574. #ifdef HAVE_STDINT_H
  575. # include <stdint.h>
  576. #endif
  577. #ifdef HAVE_UNISTD_H
  578. # include <unistd.h>
  579. #endif"
  580. ac_subst_vars='LTLIBOBJS
  581. LIBOBJS
  582. S3_INC
  583. S3_LIB
  584. S3_ENABLED
  585. TC_LIB
  586. TC_INC
  587. TC_ENABLED
  588. MISC_ENABLED
  589. CURL_LIBS
  590. CURL_CFLAGS
  591. CURLCONFIG
  592. BDB_INC
  593. BDB_LIB
  594. BDB_ENABLED
  595. MAPSERVER_LIB
  596. MAPSERVER_INC
  597. MAPSERVER_DEFS
  598. MAPSERVER_ENABLED
  599. GEOS_LIB
  600. GEOS_INC
  601. GEOS_ENABLED
  602. GEOSCONFIG
  603. GDAL_LIB
  604. GDAL_INC
  605. GDAL_ENABLED
  606. OGR_ENABLED
  607. GDALCONFIG
  608. PCRE_CFLAGS
  609. PCRE_LIBS
  610. PCRE_ENABLED
  611. GEOTIFF_LIB
  612. GEOTIFF_INC
  613. GEOTIFF_ENABLED
  614. TIFF_ENABLED
  615. TIFF_LIB
  616. TIFF_INC
  617. JPEG_LIB
  618. JPEG_INC
  619. PNG_LIB
  620. PNG_INC
  621. PIXMAN_LIB
  622. PIXMAN_INC
  623. PIXMAN_ENABLED
  624. PKGCONFIG
  625. SQLITE_ENABLED
  626. SQLITE_LIB
  627. SQLITE_INC
  628. APU_LDLIBS
  629. APU_LIBS
  630. APU_INCDIR
  631. APU_INC
  632. MEMCACHE_ENABLED
  633. APUCONFIG
  634. APR_LDLIBS
  635. APR_LIBS
  636. APR_INCDIR
  637. APR_INC
  638. APR_CFLAGS
  639. APRCONFIG
  640. FASTCGI_ENABLED
  641. FASTCGI_LIB
  642. FASTCGI_INC
  643. MODULE_TARGET
  644. HTTPD
  645. APXS_LDFLAGS
  646. APXS_LIBS
  647. APXS_INC
  648. APACHECTL
  649. APACHE_BINDIR
  650. APACHE_SBINDIR
  651. APXS
  652. INSTALL_DATA
  653. INSTALL_SCRIPT
  654. INSTALL_PROGRAM
  655. CPP
  656. OTOOL64
  657. OTOOL
  658. LIPO
  659. NMEDIT
  660. DSYMUTIL
  661. MANIFEST_TOOL
  662. AWK
  663. RANLIB
  664. STRIP
  665. ac_ct_AR
  666. AR
  667. DLLTOOL
  668. OBJDUMP
  669. LN_S
  670. NM
  671. ac_ct_DUMPBIN
  672. DUMPBIN
  673. LD
  674. FGREP
  675. EGREP
  676. GREP
  677. SED
  678. OBJEXT
  679. EXEEXT
  680. ac_ct_CC
  681. CPPFLAGS
  682. LDFLAGS
  683. CFLAGS
  684. CC
  685. host_os
  686. host_vendor
  687. host_cpu
  688. host
  689. build_os
  690. build_vendor
  691. build_cpu
  692. build
  693. LIBTOOL
  694. target_alias
  695. host_alias
  696. build_alias
  697. LIBS
  698. ECHO_T
  699. ECHO_N
  700. ECHO_C
  701. DEFS
  702. mandir
  703. localedir
  704. libdir
  705. psdir
  706. pdfdir
  707. dvidir
  708. htmldir
  709. infodir
  710. docdir
  711. oldincludedir
  712. includedir
  713. localstatedir
  714. sharedstatedir
  715. sysconfdir
  716. datadir
  717. datarootdir
  718. libexecdir
  719. sbindir
  720. bindir
  721. program_transform_name
  722. prefix
  723. exec_prefix
  724. PACKAGE_URL
  725. PACKAGE_BUGREPORT
  726. PACKAGE_STRING
  727. PACKAGE_VERSION
  728. PACKAGE_TARNAME
  729. PACKAGE_NAME
  730. PATH_SEPARATOR
  731. SHELL'
  732. ac_subst_files=''
  733. ac_user_opts='
  734. enable_option_checking
  735. enable_static
  736. enable_shared
  737. with_pic
  738. enable_fast_install
  739. with_gnu_ld
  740. with_sysroot
  741. enable_libtool_lock
  742. enable_debug
  743. enable_version_string
  744. enable_module
  745. with_apxs
  746. with_fastcgi
  747. with_apr_config
  748. with_apu_config
  749. enable_memcache
  750. with_sqlite
  751. with_pkg_config
  752. with_pixman
  753. with_png
  754. with_jpeg
  755. with_tiff
  756. enable_tiff_write_support
  757. with_geotiff
  758. with_pcre
  759. with_gdal
  760. with_geos
  761. with_mapserver
  762. with_bdb
  763. with_bdb_dir
  764. with_curl_config
  765. with_tokyo_cabinet
  766. with_s3
  767. '
  768. ac_precious_vars='build_alias
  769. host_alias
  770. target_alias
  771. CC
  772. CFLAGS
  773. LDFLAGS
  774. LIBS
  775. CPPFLAGS
  776. CPP'
  777. # Initialize some variables set by options.
  778. ac_init_help=
  779. ac_init_version=false
  780. ac_unrecognized_opts=
  781. ac_unrecognized_sep=
  782. # The variables have the same names as the options, with
  783. # dashes changed to underlines.
  784. cache_file=/dev/null
  785. exec_prefix=NONE
  786. no_create=
  787. no_recursion=
  788. prefix=NONE
  789. program_prefix=NONE
  790. program_suffix=NONE
  791. program_transform_name=s,x,x,
  792. silent=
  793. site=
  794. srcdir=
  795. verbose=
  796. x_includes=NONE
  797. x_libraries=NONE
  798. # Installation directory options.
  799. # These are left unexpanded so users can "make install exec_prefix=/foo"
  800. # and all the variables that are supposed to be based on exec_prefix
  801. # by default will actually change.
  802. # Use braces instead of parens because sh, perl, etc. also accept them.
  803. # (The list follows the same order as the GNU Coding Standards.)
  804. bindir='${exec_prefix}/bin'
  805. sbindir='${exec_prefix}/sbin'
  806. libexecdir='${exec_prefix}/libexec'
  807. datarootdir='${prefix}/share'
  808. datadir='${datarootdir}'
  809. sysconfdir='${prefix}/etc'
  810. sharedstatedir='${prefix}/com'
  811. localstatedir='${prefix}/var'
  812. includedir='${prefix}/include'
  813. oldincludedir='/usr/include'
  814. docdir='${datarootdir}/doc/${PACKAGE}'
  815. infodir='${datarootdir}/info'
  816. htmldir='${docdir}'
  817. dvidir='${docdir}'
  818. pdfdir='${docdir}'
  819. psdir='${docdir}'
  820. libdir='${exec_prefix}/lib'
  821. localedir='${datarootdir}/locale'
  822. mandir='${datarootdir}/man'
  823. ac_prev=
  824. ac_dashdash=
  825. for ac_option
  826. do
  827. # If the previous option needs an argument, assign it.
  828. if test -n "$ac_prev"; then
  829. eval $ac_prev=\$ac_option
  830. ac_prev=
  831. continue
  832. fi
  833. case $ac_option in
  834. *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
  835. *=) ac_optarg= ;;
  836. *) ac_optarg=yes ;;
  837. esac
  838. # Accept the important Cygnus configure options, so we can diagnose typos.
  839. case $ac_dashdash$ac_option in
  840. --)
  841. ac_dashdash=yes ;;
  842. -bindir | --bindir | --bindi | --bind | --bin | --bi)
  843. ac_prev=bindir ;;
  844. -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
  845. bindir=$ac_optarg ;;
  846. -build | --build | --buil | --bui | --bu)
  847. ac_prev=build_alias ;;
  848. -build=* | --build=* | --buil=* | --bui=* | --bu=*)
  849. build_alias=$ac_optarg ;;
  850. -cache-file | --cache-file | --cache-fil | --cache-fi \
  851. | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  852. ac_prev=cache_file ;;
  853. -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  854. | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  855. cache_file=$ac_optarg ;;
  856. --config-cache | -C)
  857. cache_file=config.cache ;;
  858. -datadir | --datadir | --datadi | --datad)
  859. ac_prev=datadir ;;
  860. -datadir=* | --datadir=* | --datadi=* | --datad=*)
  861. datadir=$ac_optarg ;;
  862. -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
  863. | --dataroo | --dataro | --datar)
  864. ac_prev=datarootdir ;;
  865. -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
  866. | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
  867. datarootdir=$ac_optarg ;;
  868. -disable-* | --disable-*)
  869. ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
  870. # Reject names that are not valid shell variable names.
  871. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  872. as_fn_error $? "invalid feature name: $ac_useropt"
  873. ac_useropt_orig=$ac_useropt
  874. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  875. case $ac_user_opts in
  876. *"
  877. "enable_$ac_useropt"
  878. "*) ;;
  879. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
  880. ac_unrecognized_sep=', ';;
  881. esac
  882. eval enable_$ac_useropt=no ;;
  883. -docdir | --docdir | --docdi | --doc | --do)
  884. ac_prev=docdir ;;
  885. -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
  886. docdir=$ac_optarg ;;
  887. -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
  888. ac_prev=dvidir ;;
  889. -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
  890. dvidir=$ac_optarg ;;
  891. -enable-* | --enable-*)
  892. ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
  893. # Reject names that are not valid shell variable names.
  894. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  895. as_fn_error $? "invalid feature name: $ac_useropt"
  896. ac_useropt_orig=$ac_useropt
  897. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  898. case $ac_user_opts in
  899. *"
  900. "enable_$ac_useropt"
  901. "*) ;;
  902. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
  903. ac_unrecognized_sep=', ';;
  904. esac
  905. eval enable_$ac_useropt=\$ac_optarg ;;
  906. -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  907. | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  908. | --exec | --exe | --ex)
  909. ac_prev=exec_prefix ;;
  910. -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  911. | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  912. | --exec=* | --exe=* | --ex=*)
  913. exec_prefix=$ac_optarg ;;
  914. -gas | --gas | --ga | --g)
  915. # Obsolete; use --with-gas.
  916. with_gas=yes ;;
  917. -help | --help | --hel | --he | -h)
  918. ac_init_help=long ;;
  919. -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
  920. ac_init_help=recursive ;;
  921. -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
  922. ac_init_help=short ;;
  923. -host | --host | --hos | --ho)
  924. ac_prev=host_alias ;;
  925. -host=* | --host=* | --hos=* | --ho=*)
  926. host_alias=$ac_optarg ;;
  927. -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
  928. ac_prev=htmldir ;;
  929. -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
  930. | --ht=*)
  931. htmldir=$ac_optarg ;;
  932. -includedir | --includedir | --includedi | --included | --include \
  933. | --includ | --inclu | --incl | --inc)
  934. ac_prev=includedir ;;
  935. -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  936. | --includ=* | --inclu=* | --incl=* | --inc=*)
  937. includedir=$ac_optarg ;;
  938. -infodir | --infodir | --infodi | --infod | --info | --inf)
  939. ac_prev=infodir ;;
  940. -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
  941. infodir=$ac_optarg ;;
  942. -libdir | --libdir | --libdi | --libd)
  943. ac_prev=libdir ;;
  944. -libdir=* | --libdir=* | --libdi=* | --libd=*)
  945. libdir=$ac_optarg ;;
  946. -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  947. | --libexe | --libex | --libe)
  948. ac_prev=libexecdir ;;
  949. -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  950. | --libexe=* | --libex=* | --libe=*)
  951. libexecdir=$ac_optarg ;;
  952. -localedir | --localedir | --localedi | --localed | --locale)
  953. ac_prev=localedir ;;
  954. -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
  955. localedir=$ac_optarg ;;
  956. -localstatedir | --localstatedir | --localstatedi | --localstated \
  957. | --localstate | --localstat | --localsta | --localst | --locals)
  958. ac_prev=localstatedir ;;
  959. -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  960. | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
  961. localstatedir=$ac_optarg ;;
  962. -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
  963. ac_prev=mandir ;;
  964. -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
  965. mandir=$ac_optarg ;;
  966. -nfp | --nfp | --nf)
  967. # Obsolete; use --without-fp.
  968. with_fp=no ;;
  969. -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  970. | --no-cr | --no-c | -n)
  971. no_create=yes ;;
  972. -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  973. | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  974. no_recursion=yes ;;
  975. -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  976. | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  977. | --oldin | --oldi | --old | --ol | --o)
  978. ac_prev=oldincludedir ;;
  979. -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  980. | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  981. | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
  982. oldincludedir=$ac_optarg ;;
  983. -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  984. ac_prev=prefix ;;
  985. -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  986. prefix=$ac_optarg ;;
  987. -program-prefix | --program-prefix | --program-prefi | --program-pref \
  988. | --program-pre | --program-pr | --program-p)
  989. ac_prev=program_prefix ;;
  990. -program-prefix=* | --program-prefix=* | --program-prefi=* \
  991. | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  992. program_prefix=$ac_optarg ;;
  993. -program-suffix | --program-suffix | --program-suffi | --program-suff \
  994. | --program-suf | --program-su | --program-s)
  995. ac_prev=program_suffix ;;
  996. -program-suffix=* | --program-suffix=* | --program-suffi=* \
  997. | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  998. program_suffix=$ac_optarg ;;
  999. -program-transform-name | --program-transform-name \
  1000. | --program-transform-nam | --program-transform-na \
  1001. | --program-transform-n | --program-transform- \
  1002. | --program-transform | --program-transfor \
  1003. | --program-transfo | --program-transf \
  1004. | --program-trans | --program-tran \
  1005. | --progr-tra | --program-tr | --program-t)
  1006. ac_prev=program_transform_name ;;
  1007. -program-transform-name=* | --program-transform-name=* \
  1008. | --program-transform-nam=* | --program-transform-na=* \
  1009. | --program-transform-n=* | --program-transform-=* \
  1010. | --program-transform=* | --program-transfor=* \
  1011. | --program-transfo=* | --program-transf=* \
  1012. | --program-trans=* | --program-tran=* \
  1013. | --progr-tra=* | --program-tr=* | --program-t=*)
  1014. program_transform_name=$ac_optarg ;;
  1015. -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
  1016. ac_prev=pdfdir ;;
  1017. -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
  1018. pdfdir=$ac_optarg ;;
  1019. -psdir | --psdir | --psdi | --psd | --ps)
  1020. ac_prev=psdir ;;
  1021. -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
  1022. psdir=$ac_optarg ;;
  1023. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  1024. | -silent | --silent | --silen | --sile | --sil)
  1025. silent=yes ;;
  1026. -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
  1027. ac_prev=sbindir ;;
  1028. -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  1029. | --sbi=* | --sb=*)
  1030. sbindir=$ac_optarg ;;
  1031. -sharedstatedir | --sharedstatedir | --sharedstatedi \
  1032. | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  1033. | --sharedst | --shareds | --shared | --share | --shar \
  1034. | --sha | --sh)
  1035. ac_prev=sharedstatedir ;;
  1036. -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  1037. | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  1038. | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  1039. | --sha=* | --sh=*)
  1040. sharedstatedir=$ac_optarg ;;
  1041. -site | --site | --sit)
  1042. ac_prev=site ;;
  1043. -site=* | --site=* | --sit=*)
  1044. site=$ac_optarg ;;
  1045. -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  1046. ac_prev=srcdir ;;
  1047. -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  1048. srcdir=$ac_optarg ;;
  1049. -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  1050. | --syscon | --sysco | --sysc | --sys | --sy)
  1051. ac_prev=sysconfdir ;;
  1052. -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  1053. | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
  1054. sysconfdir=$ac_optarg ;;
  1055. -target | --target | --targe | --targ | --tar | --ta | --t)
  1056. ac_prev=target_alias ;;
  1057. -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  1058. target_alias=$ac_optarg ;;
  1059. -v | -verbose | --verbose | --verbos | --verbo | --verb)
  1060. verbose=yes ;;
  1061. -version | --version | --versio | --versi | --vers | -V)
  1062. ac_init_version=: ;;
  1063. -with-* | --with-*)
  1064. ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
  1065. # Reject names that are not valid shell variable names.
  1066. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1067. as_fn_error $? "invalid package name: $ac_useropt"
  1068. ac_useropt_orig=$ac_useropt
  1069. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1070. case $ac_user_opts in
  1071. *"
  1072. "with_$ac_useropt"
  1073. "*) ;;
  1074. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
  1075. ac_unrecognized_sep=', ';;
  1076. esac
  1077. eval with_$ac_useropt=\$ac_optarg ;;
  1078. -without-* | --without-*)
  1079. ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
  1080. # Reject names that are not valid shell variable names.
  1081. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1082. as_fn_error $? "invalid package name: $ac_useropt"
  1083. ac_useropt_orig=$ac_useropt
  1084. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1085. case $ac_user_opts in
  1086. *"
  1087. "with_$ac_useropt"
  1088. "*) ;;
  1089. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
  1090. ac_unrecognized_sep=', ';;
  1091. esac
  1092. eval with_$ac_useropt=no ;;
  1093. --x)
  1094. # Obsolete; use --with-x.
  1095. with_x=yes ;;
  1096. -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  1097. | --x-incl | --x-inc | --x-in | --x-i)
  1098. ac_prev=x_includes ;;
  1099. -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  1100. | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  1101. x_includes=$ac_optarg ;;
  1102. -x-libraries | --x-libraries | --x-librarie | --x-librari \
  1103. | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  1104. ac_prev=x_libraries ;;
  1105. -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  1106. | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  1107. x_libraries=$ac_optarg ;;
  1108. -*) as_fn_error $? "unrecognized option: \`$ac_option'
  1109. Try \`$0 --help' for more information"
  1110. ;;
  1111. *=*)
  1112. ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
  1113. # Reject names that are not valid shell variable names.
  1114. case $ac_envvar in #(
  1115. '' | [0-9]* | *[!_$as_cr_alnum]* )
  1116. as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
  1117. esac
  1118. eval $ac_envvar=\$ac_optarg
  1119. export $ac_envvar ;;
  1120. *)
  1121. # FIXME: should be removed in autoconf 3.0.
  1122. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
  1123. expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
  1124. $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
  1125. : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
  1126. ;;
  1127. esac
  1128. done
  1129. if test -n "$ac_prev"; then
  1130. ac_option=--`echo $ac_prev | sed 's/_/-/g'`
  1131. as_fn_error $? "missing argument to $ac_option"
  1132. fi
  1133. if test -n "$ac_unrecognized_opts"; then
  1134. case $enable_option_checking in
  1135. no) ;;
  1136. fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
  1137. *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
  1138. esac
  1139. fi
  1140. # Check all directory arguments for consistency.
  1141. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
  1142. datadir sysconfdir sharedstatedir localstatedir includedir \
  1143. oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
  1144. libdir localedir mandir
  1145. do
  1146. eval ac_val=\$$ac_var
  1147. # Remove trailing slashes.
  1148. case $ac_val in
  1149. */ )
  1150. ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
  1151. eval $ac_var=\$ac_val;;
  1152. esac
  1153. # Be sure to have absolute directory names.
  1154. case $ac_val in
  1155. [\\/$]* | ?:[\\/]* ) continue;;
  1156. NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
  1157. esac
  1158. as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
  1159. done
  1160. # There might be people who depend on the old broken behavior: `$host'
  1161. # used to hold the argument of --host etc.
  1162. # FIXME: To remove some day.
  1163. build=$build_alias
  1164. host=$host_alias
  1165. target=$target_alias
  1166. # FIXME: To remove some day.
  1167. if test "x$host_alias" != x; then
  1168. if test "x$build_alias" = x; then
  1169. cross_compiling=maybe
  1170. elif test "x$build_alias" != "x$host_alias"; then
  1171. cross_compiling=yes
  1172. fi
  1173. fi
  1174. ac_tool_prefix=
  1175. test -n "$host_alias" && ac_tool_prefix=$host_alias-
  1176. test "$silent" = yes && exec 6>/dev/null
  1177. ac_pwd=`pwd` && test -n "$ac_pwd" &&
  1178. ac_ls_di=`ls -di .` &&
  1179. ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
  1180. as_fn_error $? "working directory cannot be determined"
  1181. test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
  1182. as_fn_error $? "pwd does not report name of working directory"
  1183. # Find the source files, if location was not specified.
  1184. if test -z "$srcdir"; then
  1185. ac_srcdir_defaulted=yes
  1186. # Try the directory containing this script, then the parent directory.
  1187. ac_confdir=`$as_dirname -- "$as_myself" ||
  1188. $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  1189. X"$as_myself" : 'X\(//\)[^/]' \| \
  1190. X"$as_myself" : 'X\(//\)$' \| \
  1191. X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
  1192. $as_echo X"$as_myself" |
  1193. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  1194. s//\1/
  1195. q
  1196. }
  1197. /^X\(\/\/\)[^/].*/{
  1198. s//\1/
  1199. q
  1200. }
  1201. /^X\(\/\/\)$/{
  1202. s//\1/
  1203. q
  1204. }
  1205. /^X\(\/\).*/{
  1206. s//\1/
  1207. q
  1208. }
  1209. s/.*/./; q'`
  1210. srcdir=$ac_confdir
  1211. if test ! -r "$srcdir/$ac_unique_file"; then
  1212. srcdir=..
  1213. fi
  1214. else
  1215. ac_srcdir_defaulted=no
  1216. fi
  1217. if test ! -r "$srcdir/$ac_unique_file"; then
  1218. test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
  1219. as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
  1220. fi
  1221. ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
  1222. ac_abs_confdir=`(
  1223. cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
  1224. pwd)`
  1225. # When building in place, set srcdir=.
  1226. if test "$ac_abs_confdir" = "$ac_pwd"; then
  1227. srcdir=.
  1228. fi
  1229. # Remove unnecessary trailing slashes from srcdir.
  1230. # Double slashes in file names in object file debugging info
  1231. # mess up M-x gdb in Emacs.
  1232. case $srcdir in
  1233. */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
  1234. esac
  1235. for ac_var in $ac_precious_vars; do
  1236. eval ac_env_${ac_var}_set=\${${ac_var}+set}
  1237. eval ac_env_${ac_var}_value=\$${ac_var}
  1238. eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
  1239. eval ac_cv_env_${ac_var}_value=\$${ac_var}
  1240. done
  1241. #
  1242. # Report the --help message.
  1243. #
  1244. if test "$ac_init_help" = "long"; then
  1245. # Omit some internal or obsolete options to make the list less imposing.
  1246. # This message is too long to be a string in the A/UX 3.1 sh.
  1247. cat <<_ACEOF
  1248. \`configure' configures this package to adapt to many kinds of systems.
  1249. Usage: $0 [OPTION]... [VAR=VALUE]...
  1250. To assign environment variables (e.g., CC, CFLAGS...), specify them as
  1251. VAR=VALUE. See below for descriptions of some of the useful variables.
  1252. Defaults for the options are specified in brackets.
  1253. Configuration:
  1254. -h, --help display this help and exit
  1255. --help=short display options specific to this package
  1256. --help=recursive display the short help of all the included packages
  1257. -V, --version display version information and exit
  1258. -q, --quiet, --silent do not print \`checking ...' messages
  1259. --cache-file=FILE cache test results in FILE [disabled]
  1260. -C, --config-cache alias for \`--cache-file=config.cache'
  1261. -n, --no-create do not create output files
  1262. --srcdir=DIR find the sources in DIR [configure dir or \`..']
  1263. Installation directories:
  1264. --prefix=PREFIX install architecture-independent files in PREFIX
  1265. [$ac_default_prefix]
  1266. --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
  1267. [PREFIX]
  1268. By default, \`make install' will install all the files in
  1269. \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
  1270. an installation prefix other than \`$ac_default_prefix' using \`--prefix',
  1271. for instance \`--prefix=\$HOME'.
  1272. For better control, use the options below.
  1273. Fine tuning of the installation directories:
  1274. --bindir=DIR user executables [EPREFIX/bin]
  1275. --sbindir=DIR system admin executables [EPREFIX/sbin]
  1276. --libexecdir=DIR program executables [EPREFIX/libexec]
  1277. --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
  1278. --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
  1279. --localstatedir=DIR modifiable single-machine data [PREFIX/var]
  1280. --libdir=DIR object code libraries [EPREFIX/lib]
  1281. --includedir=DIR C header files [PREFIX/include]
  1282. --oldincludedir=DIR C header files for non-gcc [/usr/include]
  1283. --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
  1284. --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
  1285. --infodir=DIR info documentation [DATAROOTDIR/info]
  1286. --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
  1287. --mandir=DIR man documentation [DATAROOTDIR/man]
  1288. --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
  1289. --htmldir=DIR html documentation [DOCDIR]
  1290. --dvidir=DIR dvi documentation [DOCDIR]
  1291. --pdfdir=DIR pdf documentation [DOCDIR]
  1292. --psdir=DIR ps documentation [DOCDIR]
  1293. _ACEOF
  1294. cat <<\_ACEOF
  1295. System types:
  1296. --build=BUILD configure for building on BUILD [guessed]
  1297. --host=HOST cross-compile to build programs to run on HOST [BUILD]
  1298. _ACEOF
  1299. fi
  1300. if test -n "$ac_init_help"; then
  1301. cat <<\_ACEOF
  1302. Optional Features:
  1303. --disable-option-checking ignore unrecognized --enable/--with options
  1304. --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
  1305. --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
  1306. --enable-static[=PKGS] build static libraries [default=no]
  1307. --enable-shared[=PKGS] build shared libraries [default=yes]
  1308. --enable-fast-install[=PKGS]
  1309. optimize for fast installation [default=yes]
  1310. --disable-libtool-lock avoid locking (might break parallel builds)
  1311. --enable-debug Enable debug build
  1312. --enable-version-string add mod-mapcache version string to the apache server
  1313. header
  1314. --enable-module Enable apache module building
  1315. --enable-memcache Enable memcache backend
  1316. --enable-tiff-write-support
  1317. Enable tiff cache write support (experimental)
  1318. Optional Packages:
  1319. --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
  1320. --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
  1321. --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
  1322. both]
  1323. --with-gnu-ld assume the C compiler uses GNU ld [default=no]
  1324. --with-sysroot=DIR Search for dependent libraries within DIR
  1325. (or the compiler's sysroot if not specified).
  1326. --with-apxs[=PATH] Apache 2 apxs tool location
  1327. --with-fastcgi[=DIR] Specify where FASTCGI is installed
  1328. --with-apr-config path to apr-config program
  1329. --with-apu-config path to apu-config program
  1330. --with-sqlite path to sqlite-config program
  1331. --with-pkg-config[=PATH]
  1332. path to pkg-config)
  1333. --with-pixman[=ARG] Include Pixman Support (ARG=yes/no/path to
  1334. pixman.pc)
  1335. --with-png[=DIR] Specify where PNG is installed
  1336. --with-jpeg[=DIR] Specify where JPEG is installed
  1337. --with-tiff[=DIR] Specify where TIFF is installed
  1338. --with-geotiff[=ARG] Libgeotiff library to use (ARG=yes or path)
  1339. --with-pcre[=prefix] use pcre instead of posix regular expressions
  1340. --with-gdal path to gdal-config program
  1341. --with-geos path to geos-config program
  1342. --with-mapserver[=/path/to/mapserver-src-dir]
  1343. Enable mapserver sources (experimental)
  1344. --with-bdb enable berkeley db support
  1345. --with-bdb-dir=DIR Berkeley DB installation directory
  1346. --with-curl-config path to curl-config program
  1347. --with-tokyo-cabinet[=/path]
  1348. Enable tokyo cabinet backend (experimental)
  1349. --with-s3 Enable caching to Amazon S3 (experimental)
  1350. Some influential environment variables:
  1351. CC C compiler command
  1352. CFLAGS C compiler flags
  1353. LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
  1354. nonstandard directory <lib dir>
  1355. LIBS libraries to pass to the linker, e.g. -l<library>
  1356. CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
  1357. you have headers in a nonstandard directory <include dir>
  1358. CPP C preprocessor
  1359. Use these variables to override the choices made by `configure' or to help
  1360. it to find libraries and programs with nonstandard names/locations.
  1361. Report bugs to the package provider.
  1362. _ACEOF
  1363. ac_status=$?
  1364. fi
  1365. if test "$ac_init_help" = "recursive"; then
  1366. # If there are subdirs, report their specific --help.
  1367. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
  1368. test -d "$ac_dir" ||
  1369. { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
  1370. continue
  1371. ac_builddir=.
  1372. case "$ac_dir" in
  1373. .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
  1374. *)
  1375. ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
  1376. # A ".." for each directory in $ac_dir_suffix.
  1377. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
  1378. case $ac_top_builddir_sub in
  1379. "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
  1380. *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
  1381. esac ;;
  1382. esac
  1383. ac_abs_top_builddir=$ac_pwd
  1384. ac_abs_builddir=$ac_pwd$ac_dir_suffix
  1385. # for backward compatibility:
  1386. ac_top_builddir=$ac_top_build_prefix
  1387. case $srcdir in
  1388. .) # We are building in place.
  1389. ac_srcdir=.
  1390. ac_top_srcdir=$ac_top_builddir_sub
  1391. ac_abs_top_srcdir=$ac_pwd ;;
  1392. [\\/]* | ?:[\\/]* ) # Absolute name.
  1393. ac_srcdir=$srcdir$ac_dir_suffix;
  1394. ac_top_srcdir=$srcdir
  1395. ac_abs_top_srcdir=$srcdir ;;
  1396. *) # Relative name.
  1397. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
  1398. ac_top_srcdir=$ac_top_build_prefix$srcdir
  1399. ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
  1400. esac
  1401. ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
  1402. cd "$ac_dir" || { ac_status=$?; continue; }
  1403. # Check for guested configure.
  1404. if test -f "$ac_srcdir/configure.gnu"; then
  1405. echo &&
  1406. $SHELL "$ac_srcdir/configure.gnu" --help=recursive
  1407. elif test -f "$ac_srcdir/configure"; then
  1408. echo &&
  1409. $SHELL "$ac_srcdir/configure" --help=recursive
  1410. else
  1411. $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
  1412. fi || ac_status=$?
  1413. cd "$ac_pwd" || { ac_status=$?; break; }
  1414. done
  1415. fi
  1416. test -n "$ac_init_help" && exit $ac_status
  1417. if $ac_init_version; then
  1418. cat <<\_ACEOF
  1419. configure
  1420. generated by GNU Autoconf 2.69
  1421. Copyright (C) 2012 Free Software Foundation, Inc.
  1422. This configure script is free software; the Free Software Foundation
  1423. gives unlimited permission to copy, distribute and modify it.
  1424. _ACEOF
  1425. exit
  1426. fi
  1427. ## ------------------------ ##
  1428. ## Autoconf initialization. ##
  1429. ## ------------------------ ##
  1430. # ac_fn_c_try_compile LINENO
  1431. # --------------------------
  1432. # Try to compile conftest.$ac_ext, and return whether this succeeded.
  1433. ac_fn_c_try_compile ()
  1434. {
  1435. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  1436. rm -f conftest.$ac_objext
  1437. if { { ac_try="$ac_compile"
  1438. case "(($ac_try" in
  1439. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  1440. *) ac_try_echo=$ac_try;;
  1441. esac
  1442. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  1443. $as_echo "$ac_try_echo"; } >&5
  1444. (eval "$ac_compile") 2>conftest.err
  1445. ac_status=$?
  1446. if test -s conftest.err; then
  1447. grep -v '^ *+' conftest.err >conftest.er1
  1448. cat conftest.er1 >&5
  1449. mv -f conftest.er1 conftest.err
  1450. fi
  1451. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  1452. test $ac_status = 0; } && {
  1453. test -z "$ac_c_werror_flag" ||
  1454. test ! -s conftest.err
  1455. } && test -s conftest.$ac_objext; then :
  1456. ac_retval=0
  1457. else
  1458. $as_echo "$as_me: failed program was:" >&5
  1459. sed 's/^/| /' conftest.$ac_ext >&5
  1460. ac_retval=1
  1461. fi
  1462. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  1463. as_fn_set_status $ac_retval
  1464. } # ac_fn_c_try_compile
  1465. # ac_fn_c_try_link LINENO
  1466. # -----------------------
  1467. # Try to link conftest.$ac_ext, and return whether this succeeded.
  1468. ac_fn_c_try_link ()
  1469. {
  1470. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  1471. rm -f conftest.$ac_objext conftest$ac_exeext
  1472. if { { ac_try="$ac_link"
  1473. case "(($ac_try" in
  1474. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  1475. *) ac_try_echo=$ac_try;;
  1476. esac
  1477. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  1478. $as_echo "$ac_try_echo"; } >&5
  1479. (eval "$ac_link") 2>conftest.err
  1480. ac_status=$?
  1481. if test -s conftest.err; then
  1482. grep -v '^ *+' conftest.err >conftest.er1
  1483. cat conftest.er1 >&5
  1484. mv -f conftest.er1 conftest.err
  1485. fi
  1486. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  1487. test $ac_status = 0; } && {
  1488. test -z "$ac_c_werror_flag" ||
  1489. test ! -s conftest.err
  1490. } && test -s conftest$ac_exeext && {
  1491. test "$cross_compiling" = yes ||
  1492. test -x conftest$ac_exeext
  1493. }; then :
  1494. ac_retval=0
  1495. else
  1496. $as_echo "$as_me: failed program was:" >&5
  1497. sed 's/^/| /' conftest.$ac_ext >&5
  1498. ac_retval=1
  1499. fi
  1500. # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
  1501. # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
  1502. # interfere with the next link command; also delete a directory that is
  1503. # left behind by Apple's compiler. We do this before executing the actions.
  1504. rm -rf conftest.dSYM conftest_ipa8_conftest.oo
  1505. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  1506. as_fn_set_status $ac_retval
  1507. } # ac_fn_c_try_link
  1508. # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
  1509. # -------------------------------------------------------
  1510. # Tests whether HEADER exists and can be compiled using the include files in
  1511. # INCLUDES, setting the cache variable VAR accordingly.
  1512. ac_fn_c_check_header_compile ()
  1513. {
  1514. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  1515. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  1516. $as_echo_n "checking for $2... " >&6; }
  1517. if eval \${$3+:} false; then :
  1518. $as_echo_n "(cached) " >&6
  1519. else
  1520. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  1521. /* end confdefs.h. */
  1522. $4
  1523. #include <$2>
  1524. _ACEOF
  1525. if ac_fn_c_try_compile "$LINENO"; then :
  1526. eval "$3=yes"
  1527. else
  1528. eval "$3=no"
  1529. fi
  1530. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  1531. fi
  1532. eval ac_res=\$$3
  1533. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  1534. $as_echo "$ac_res" >&6; }
  1535. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  1536. } # ac_fn_c_check_header_compile
  1537. # ac_fn_c_try_cpp LINENO
  1538. # ----------------------
  1539. # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
  1540. ac_fn_c_try_cpp ()
  1541. {
  1542. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  1543. if { { ac_try="$ac_cpp conftest.$ac_ext"
  1544. case "(($ac_try" in
  1545. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  1546. *) ac_try_echo=$ac_try;;
  1547. esac
  1548. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  1549. $as_echo "$ac_try_echo"; } >&5
  1550. (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
  1551. ac_status=$?
  1552. if test -s conftest.err; then
  1553. grep -v '^ *+' conftest.err >conftest.er1
  1554. cat conftest.er1 >&5
  1555. mv -f conftest.er1 conftest.err
  1556. fi
  1557. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  1558. test $ac_status = 0; } > conftest.i && {
  1559. test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
  1560. test ! -s conftest.err
  1561. }; then :
  1562. ac_retval=0
  1563. else
  1564. $as_echo "$as_me: failed program was:" >&5
  1565. sed 's/^/| /' conftest.$ac_ext >&5
  1566. ac_retval=1
  1567. fi
  1568. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  1569. as_fn_set_status $ac_retval
  1570. } # ac_fn_c_try_cpp
  1571. # ac_fn_c_try_run LINENO
  1572. # ----------------------
  1573. # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
  1574. # that executables *can* be run.
  1575. ac_fn_c_try_run ()
  1576. {
  1577. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  1578. if { { ac_try="$ac_link"
  1579. case "(($ac_try" in
  1580. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  1581. *) ac_try_echo=$ac_try;;
  1582. esac
  1583. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  1584. $as_echo "$ac_try_echo"; } >&5
  1585. (eval "$ac_link") 2>&5
  1586. ac_status=$?
  1587. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  1588. test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
  1589. { { case "(($ac_try" in
  1590. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  1591. *) ac_try_echo=$ac_try;;
  1592. esac
  1593. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  1594. $as_echo "$ac_try_echo"; } >&5
  1595. (eval "$ac_try") 2>&5
  1596. ac_status=$?
  1597. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  1598. test $ac_status = 0; }; }; then :
  1599. ac_retval=0
  1600. else
  1601. $as_echo "$as_me: program exited with status $ac_status" >&5
  1602. $as_echo "$as_me: failed program was:" >&5
  1603. sed 's/^/| /' conftest.$ac_ext >&5
  1604. ac_retval=$ac_status
  1605. fi
  1606. rm -rf conftest.dSYM conftest_ipa8_conftest.oo
  1607. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  1608. as_fn_set_status $ac_retval
  1609. } # ac_fn_c_try_run
  1610. # ac_fn_c_check_func LINENO FUNC VAR
  1611. # ----------------------------------
  1612. # Tests whether FUNC exists, setting the cache variable VAR accordingly
  1613. ac_fn_c_check_func ()
  1614. {
  1615. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  1616. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  1617. $as_echo_n "checking for $2... " >&6; }
  1618. if eval \${$3+:} false; then :
  1619. $as_echo_n "(cached) " >&6
  1620. else
  1621. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  1622. /* end confdefs.h. */
  1623. /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
  1624. For example, HP-UX 11i <limits.h> declares gettimeofday. */
  1625. #define $2 innocuous_$2
  1626. /* System header to define __stub macros and hopefully few prototypes,
  1627. which can conflict with char $2 (); below.
  1628. Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  1629. <limits.h> exists even on freestanding compilers. */
  1630. #ifdef __STDC__
  1631. # include <limits.h>
  1632. #else
  1633. # include <assert.h>
  1634. #endif
  1635. #undef $2
  1636. /* Override any GCC internal prototype to avoid an error.
  1637. Use char because int might match the return type of a GCC
  1638. builtin and then its argument prototype would still apply. */
  1639. #ifdef __cplusplus
  1640. extern "C"
  1641. #endif
  1642. char $2 ();
  1643. /* The GNU C library defines this for functions which it implements
  1644. to always fail with ENOSYS. Some functions are actually named
  1645. something starting with __ and the normal name is an alias. */
  1646. #if defined __stub_$2 || defined __stub___$2
  1647. choke me
  1648. #endif
  1649. int
  1650. main ()
  1651. {
  1652. return $2 ();
  1653. ;
  1654. return 0;
  1655. }
  1656. _ACEOF
  1657. if ac_fn_c_try_link "$LINENO"; then :
  1658. eval "$3=yes"
  1659. else
  1660. eval "$3=no"
  1661. fi
  1662. rm -f core conftest.err conftest.$ac_objext \
  1663. conftest$ac_exeext conftest.$ac_ext
  1664. fi
  1665. eval ac_res=\$$3
  1666. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  1667. $as_echo "$ac_res" >&6; }
  1668. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  1669. } # ac_fn_c_check_func
  1670. # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
  1671. # -------------------------------------------------------
  1672. # Tests whether HEADER exists, giving a warning if it cannot be compiled using
  1673. # the include files in INCLUDES and setting the cache variable VAR
  1674. # accordingly.
  1675. ac_fn_c_check_header_mongrel ()
  1676. {
  1677. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  1678. if eval \${$3+:} false; then :
  1679. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  1680. $as_echo_n "checking for $2... " >&6; }
  1681. if eval \${$3+:} false; then :
  1682. $as_echo_n "(cached) " >&6
  1683. fi
  1684. eval ac_res=\$$3
  1685. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  1686. $as_echo "$ac_res" >&6; }
  1687. else
  1688. # Is the header compilable?
  1689. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
  1690. $as_echo_n "checking $2 usability... " >&6; }
  1691. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  1692. /* end confdefs.h. */
  1693. $4
  1694. #include <$2>
  1695. _ACEOF
  1696. if ac_fn_c_try_compile "$LINENO"; then :
  1697. ac_header_compiler=yes
  1698. else
  1699. ac_header_compiler=no
  1700. fi
  1701. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  1702. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
  1703. $as_echo "$ac_header_compiler" >&6; }
  1704. # Is the header present?
  1705. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
  1706. $as_echo_n "checking $2 presence... " >&6; }
  1707. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  1708. /* end confdefs.h. */
  1709. #include <$2>
  1710. _ACEOF
  1711. if ac_fn_c_try_cpp "$LINENO"; then :
  1712. ac_header_preproc=yes
  1713. else
  1714. ac_header_preproc=no
  1715. fi
  1716. rm -f conftest.err conftest.i conftest.$ac_ext
  1717. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
  1718. $as_echo "$ac_header_preproc" >&6; }
  1719. # So? What about this header?
  1720. case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
  1721. yes:no: )
  1722. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
  1723. $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
  1724. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  1725. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  1726. ;;
  1727. no:yes:* )
  1728. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
  1729. $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
  1730. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
  1731. $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
  1732. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
  1733. $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
  1734. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
  1735. $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
  1736. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  1737. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  1738. ;;
  1739. esac
  1740. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  1741. $as_echo_n "checking for $2... " >&6; }
  1742. if eval \${$3+:} false; then :
  1743. $as_echo_n "(cached) " >&6
  1744. else
  1745. eval "$3=\$ac_header_compiler"
  1746. fi
  1747. eval ac_res=\$$3
  1748. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  1749. $as_echo "$ac_res" >&6; }
  1750. fi
  1751. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  1752. } # ac_fn_c_check_header_mongrel
  1753. cat >config.log <<_ACEOF
  1754. This file contains any messages produced by compilers while
  1755. running configure, to aid debugging if configure makes a mistake.
  1756. It was created by $as_me, which was
  1757. generated by GNU Autoconf 2.69. Invocation command line was
  1758. $ $0 $@
  1759. _ACEOF
  1760. exec 5>>config.log
  1761. {
  1762. cat <<_ASUNAME
  1763. ## --------- ##
  1764. ## Platform. ##
  1765. ## --------- ##
  1766. hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
  1767. uname -m = `(uname -m) 2>/dev/null || echo unknown`
  1768. uname -r = `(uname -r) 2>/dev/null || echo unknown`
  1769. uname -s = `(uname -s) 2>/dev/null || echo unknown`
  1770. uname -v = `(uname -v) 2>/dev/null || echo unknown`
  1771. /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
  1772. /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
  1773. /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
  1774. /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
  1775. /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
  1776. /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
  1777. /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
  1778. /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
  1779. /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
  1780. _ASUNAME
  1781. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  1782. for as_dir in $PATH
  1783. do
  1784. IFS=$as_save_IFS
  1785. test -z "$as_dir" && as_dir=.
  1786. $as_echo "PATH: $as_dir"
  1787. done
  1788. IFS=$as_save_IFS
  1789. } >&5
  1790. cat >&5 <<_ACEOF
  1791. ## ----------- ##
  1792. ## Core tests. ##
  1793. ## ----------- ##
  1794. _ACEOF
  1795. # Keep a trace of the command line.
  1796. # Strip out --no-create and --no-recursion so they do not pile up.
  1797. # Strip out --silent because we don't want to record it for future runs.
  1798. # Also quote any args containing shell meta-characters.
  1799. # Make two passes to allow for proper duplicate-argument suppression.
  1800. ac_configure_args=
  1801. ac_configure_args0=
  1802. ac_configure_args1=
  1803. ac_must_keep_next=false
  1804. for ac_pass in 1 2
  1805. do
  1806. for ac_arg
  1807. do
  1808. case $ac_arg in
  1809. -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
  1810. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  1811. | -silent | --silent | --silen | --sile | --sil)
  1812. continue ;;
  1813. *\'*)
  1814. ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
  1815. esac
  1816. case $ac_pass in
  1817. 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
  1818. 2)
  1819. as_fn_append ac_configure_args1 " '$ac_arg'"
  1820. if test $ac_must_keep_next = true; then
  1821. ac_must_keep_next=false # Got value, back to normal.
  1822. else
  1823. case $ac_arg in
  1824. *=* | --config-cache | -C | -disable-* | --disable-* \
  1825. | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
  1826. | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
  1827. | -with-* | --with-* | -without-* | --without-* | --x)
  1828. case "$ac_configure_args0 " in
  1829. "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
  1830. esac
  1831. ;;
  1832. -* ) ac_must_keep_next=true ;;
  1833. esac
  1834. fi
  1835. as_fn_append ac_configure_args " '$ac_arg'"
  1836. ;;
  1837. esac
  1838. done
  1839. done
  1840. { ac_configure_args0=; unset ac_configure_args0;}
  1841. { ac_configure_args1=; unset ac_configure_args1;}
  1842. # When interrupted or exit'd, cleanup temporary files, and complete
  1843. # config.log. We remove comments because anyway the quotes in there
  1844. # would cause problems or look ugly.
  1845. # WARNING: Use '\'' to represent an apostrophe within the trap.
  1846. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
  1847. trap 'exit_status=$?
  1848. # Save into config.log some information that might help in debugging.
  1849. {
  1850. echo
  1851. $as_echo "## ---------------- ##
  1852. ## Cache variables. ##
  1853. ## ---------------- ##"
  1854. echo
  1855. # The following way of writing the cache mishandles newlines in values,
  1856. (
  1857. for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
  1858. eval ac_val=\$$ac_var
  1859. case $ac_val in #(
  1860. *${as_nl}*)
  1861. case $ac_var in #(
  1862. *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
  1863. $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
  1864. esac
  1865. case $ac_var in #(
  1866. _ | IFS | as_nl) ;; #(
  1867. BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
  1868. *) { eval $ac_var=; unset $ac_var;} ;;
  1869. esac ;;
  1870. esac
  1871. done
  1872. (set) 2>&1 |
  1873. case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
  1874. *${as_nl}ac_space=\ *)
  1875. sed -n \
  1876. "s/'\''/'\''\\\\'\'''\''/g;
  1877. s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
  1878. ;; #(
  1879. *)
  1880. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
  1881. ;;
  1882. esac |
  1883. sort
  1884. )
  1885. echo
  1886. $as_echo "## ----------------- ##
  1887. ## Output variables. ##
  1888. ## ----------------- ##"
  1889. echo
  1890. for ac_var in $ac_subst_vars
  1891. do
  1892. eval ac_val=\$$ac_var
  1893. case $ac_val in
  1894. *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
  1895. esac
  1896. $as_echo "$ac_var='\''$ac_val'\''"
  1897. done | sort
  1898. echo
  1899. if test -n "$ac_subst_files"; then
  1900. $as_echo "## ------------------- ##
  1901. ## File substitutions. ##
  1902. ## ------------------- ##"
  1903. echo
  1904. for ac_var in $ac_subst_files
  1905. do
  1906. eval ac_val=\$$ac_var
  1907. case $ac_val in
  1908. *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
  1909. esac
  1910. $as_echo "$ac_var='\''$ac_val'\''"
  1911. done | sort
  1912. echo
  1913. fi
  1914. if test -s confdefs.h; then
  1915. $as_echo "## ----------- ##
  1916. ## confdefs.h. ##
  1917. ## ----------- ##"
  1918. echo
  1919. cat confdefs.h
  1920. echo
  1921. fi
  1922. test "$ac_signal" != 0 &&
  1923. $as_echo "$as_me: caught signal $ac_signal"
  1924. $as_echo "$as_me: exit $exit_status"
  1925. } >&5
  1926. rm -f core *.core core.conftest.* &&
  1927. rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
  1928. exit $exit_status
  1929. ' 0
  1930. for ac_signal in 1 2 13 15; do
  1931. trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
  1932. done
  1933. ac_signal=0
  1934. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  1935. rm -f -r conftest* confdefs.h
  1936. $as_echo "/* confdefs.h */" > confdefs.h
  1937. # Predefined preprocessor variables.
  1938. cat >>confdefs.h <<_ACEOF
  1939. #define PACKAGE_NAME "$PACKAGE_NAME"
  1940. _ACEOF
  1941. cat >>confdefs.h <<_ACEOF
  1942. #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
  1943. _ACEOF
  1944. cat >>confdefs.h <<_ACEOF
  1945. #define PACKAGE_VERSION "$PACKAGE_VERSION"
  1946. _ACEOF
  1947. cat >>confdefs.h <<_ACEOF
  1948. #define PACKAGE_STRING "$PACKAGE_STRING"
  1949. _ACEOF
  1950. cat >>confdefs.h <<_ACEOF
  1951. #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
  1952. _ACEOF
  1953. cat >>confdefs.h <<_ACEOF
  1954. #define PACKAGE_URL "$PACKAGE_URL"
  1955. _ACEOF
  1956. # Let the site file select an alternate cache file if it wants to.
  1957. # Prefer an explicitly selected file to automatically selected ones.
  1958. ac_site_file1=NONE
  1959. ac_site_file2=NONE
  1960. if test -n "$CONFIG_SITE"; then
  1961. # We do not want a PATH search for config.site.
  1962. case $CONFIG_SITE in #((
  1963. -*) ac_site_file1=./$CONFIG_SITE;;
  1964. */*) ac_site_file1=$CONFIG_SITE;;
  1965. *) ac_site_file1=./$CONFIG_SITE;;
  1966. esac
  1967. elif test "x$prefix" != xNONE; then
  1968. ac_site_file1=$prefix/share/config.site
  1969. ac_site_file2=$prefix/etc/config.site
  1970. else
  1971. ac_site_file1=$ac_default_prefix/share/config.site
  1972. ac_site_file2=$ac_default_prefix/etc/config.site
  1973. fi
  1974. for ac_site_file in "$ac_site_file1" "$ac_site_file2"
  1975. do
  1976. test "x$ac_site_file" = xNONE && continue
  1977. if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
  1978. { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
  1979. $as_echo "$as_me: loading site script $ac_site_file" >&6;}
  1980. sed 's/^/| /' "$ac_site_file" >&5
  1981. . "$ac_site_file" \
  1982. || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  1983. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  1984. as_fn_error $? "failed to load site script $ac_site_file
  1985. See \`config.log' for more details" "$LINENO" 5; }
  1986. fi
  1987. done
  1988. if test -r "$cache_file"; then
  1989. # Some versions of bash will fail to source /dev/null (special files
  1990. # actually), so we avoid doing that. DJGPP emulates it as a regular file.
  1991. if test /dev/null != "$cache_file" && test -f "$cache_file"; then
  1992. { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
  1993. $as_echo "$as_me: loading cache $cache_file" >&6;}
  1994. case $cache_file in
  1995. [\\/]* | ?:[\\/]* ) . "$cache_file";;
  1996. *) . "./$cache_file";;
  1997. esac
  1998. fi
  1999. else
  2000. { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
  2001. $as_echo "$as_me: creating cache $cache_file" >&6;}
  2002. >$cache_file
  2003. fi
  2004. # Check that the precious variables saved in the cache have kept the same
  2005. # value.
  2006. ac_cache_corrupted=false
  2007. for ac_var in $ac_precious_vars; do
  2008. eval ac_old_set=\$ac_cv_env_${ac_var}_set
  2009. eval ac_new_set=\$ac_env_${ac_var}_set
  2010. eval ac_old_val=\$ac_cv_env_${ac_var}_value
  2011. eval ac_new_val=\$ac_env_${ac_var}_value
  2012. case $ac_old_set,$ac_new_set in
  2013. set,)
  2014. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
  2015. $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
  2016. ac_cache_corrupted=: ;;
  2017. ,set)
  2018. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
  2019. $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
  2020. ac_cache_corrupted=: ;;
  2021. ,);;
  2022. *)
  2023. if test "x$ac_old_val" != "x$ac_new_val"; then
  2024. # differences in whitespace do not lead to failure.
  2025. ac_old_val_w=`echo x $ac_old_val`
  2026. ac_new_val_w=`echo x $ac_new_val`
  2027. if test "$ac_old_val_w" != "$ac_new_val_w"; then
  2028. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
  2029. $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
  2030. ac_cache_corrupted=:
  2031. else
  2032. { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
  2033. $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
  2034. eval $ac_var=\$ac_old_val
  2035. fi
  2036. { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
  2037. $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
  2038. { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
  2039. $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
  2040. fi;;
  2041. esac
  2042. # Pass precious variables to config.status.
  2043. if test "$ac_new_set" = set; then
  2044. case $ac_new_val in
  2045. *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
  2046. *) ac_arg=$ac_var=$ac_new_val ;;
  2047. esac
  2048. case " $ac_configure_args " in
  2049. *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
  2050. *) as_fn_append ac_configure_args " '$ac_arg'" ;;
  2051. esac
  2052. fi
  2053. done
  2054. if $ac_cache_corrupted; then
  2055. { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  2056. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  2057. { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
  2058. $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
  2059. as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
  2060. fi
  2061. ## -------------------- ##
  2062. ## Main body of script. ##
  2063. ## -------------------- ##
  2064. ac_ext=c
  2065. ac_cpp='$CPP $CPPFLAGS'
  2066. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  2067. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  2068. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  2069. # don't let AC_PROG_CC force "-g -O2"
  2070. : ${CFLAGS="-Wall"}
  2071. ac_aux_dir=
  2072. for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
  2073. if test -f "$ac_dir/install-sh"; then
  2074. ac_aux_dir=$ac_dir
  2075. ac_install_sh="$ac_aux_dir/install-sh -c"
  2076. break
  2077. elif test -f "$ac_dir/install.sh"; then
  2078. ac_aux_dir=$ac_dir
  2079. ac_install_sh="$ac_aux_dir/install.sh -c"
  2080. break
  2081. elif test -f "$ac_dir/shtool"; then
  2082. ac_aux_dir=$ac_dir
  2083. ac_install_sh="$ac_aux_dir/shtool install -c"
  2084. break
  2085. fi
  2086. done
  2087. if test -z "$ac_aux_dir"; then
  2088. as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
  2089. fi
  2090. # These three variables are undocumented and unsupported,
  2091. # and are intended to be withdrawn in a future Autoconf release.
  2092. # They can cause serious problems if a builder's source tree is in a directory
  2093. # whose full name contains unusual characters.
  2094. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
  2095. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
  2096. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
  2097. case `pwd` in
  2098. *\ * | *\ *)
  2099. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
  2100. $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
  2101. esac
  2102. macro_version='2.4.2'
  2103. macro_revision='1.3337'
  2104. ltmain="$ac_aux_dir/ltmain.sh"
  2105. # Make sure we can run config.sub.
  2106. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
  2107. as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
  2108. { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
  2109. $as_echo_n "checking build system type... " >&6; }
  2110. if ${ac_cv_build+:} false; then :
  2111. $as_echo_n "(cached) " >&6
  2112. else
  2113. ac_build_alias=$build_alias
  2114. test "x$ac_build_alias" = x &&
  2115. ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
  2116. test "x$ac_build_alias" = x &&
  2117. as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
  2118. ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
  2119. as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
  2120. fi
  2121. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
  2122. $as_echo "$ac_cv_build" >&6; }
  2123. case $ac_cv_build in
  2124. *-*-*) ;;
  2125. *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
  2126. esac
  2127. build=$ac_cv_build
  2128. ac_save_IFS=$IFS; IFS='-'
  2129. set x $ac_cv_build
  2130. shift
  2131. build_cpu=$1
  2132. build_vendor=$2
  2133. shift; shift
  2134. # Remember, the first character of IFS is used to create $*,
  2135. # except with old shells:
  2136. build_os=$*
  2137. IFS=$ac_save_IFS
  2138. case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
  2139. { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
  2140. $as_echo_n "checking host system type... " >&6; }
  2141. if ${ac_cv_host+:} false; then :
  2142. $as_echo_n "(cached) " >&6
  2143. else
  2144. if test "x$host_alias" = x; then
  2145. ac_cv_host=$ac_cv_build
  2146. else
  2147. ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
  2148. as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
  2149. fi
  2150. fi
  2151. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
  2152. $as_echo "$ac_cv_host" >&6; }
  2153. case $ac_cv_host in
  2154. *-*-*) ;;
  2155. *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
  2156. esac
  2157. host=$ac_cv_host
  2158. ac_save_IFS=$IFS; IFS='-'
  2159. set x $ac_cv_host
  2160. shift
  2161. host_cpu=$1
  2162. host_vendor=$2
  2163. shift; shift
  2164. # Remember, the first character of IFS is used to create $*,
  2165. # except with old shells:
  2166. host_os=$*
  2167. IFS=$ac_save_IFS
  2168. case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
  2169. # Backslashify metacharacters that are still active within
  2170. # double-quoted strings.
  2171. sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
  2172. # Same as above, but do not quote variable references.
  2173. double_quote_subst='s/\(["`\\]\)/\\\1/g'
  2174. # Sed substitution to delay expansion of an escaped shell variable in a
  2175. # double_quote_subst'ed string.
  2176. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
  2177. # Sed substitution to delay expansion of an escaped single quote.
  2178. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
  2179. # Sed substitution to avoid accidental globbing in evaled expressions
  2180. no_glob_subst='s/\*/\\\*/g'
  2181. ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  2182. ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
  2183. ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  2184. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  2185. $as_echo_n "checking how to print strings... " >&6; }
  2186. # Test print first, because it will be a builtin if present.
  2187. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
  2188. test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
  2189. ECHO='print -r --'
  2190. elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
  2191. ECHO='printf %s\n'
  2192. else
  2193. # Use this function as a fallback that always works.
  2194. func_fallback_echo ()
  2195. {
  2196. eval 'cat <<_LTECHO_EOF
  2197. $1
  2198. _LTECHO_EOF'
  2199. }
  2200. ECHO='func_fallback_echo'
  2201. fi
  2202. # func_echo_all arg...
  2203. # Invoke $ECHO with all args, space-separated.
  2204. func_echo_all ()
  2205. {
  2206. $ECHO ""
  2207. }
  2208. case "$ECHO" in
  2209. printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
  2210. $as_echo "printf" >&6; } ;;
  2211. print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
  2212. $as_echo "print -r" >&6; } ;;
  2213. *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
  2214. $as_echo "cat" >&6; } ;;
  2215. esac
  2216. ac_ext=c
  2217. ac_cpp='$CPP $CPPFLAGS'
  2218. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  2219. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  2220. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  2221. if test -n "$ac_tool_prefix"; then
  2222. # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
  2223. set dummy ${ac_tool_prefix}gcc; ac_word=$2
  2224. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  2225. $as_echo_n "checking for $ac_word... " >&6; }
  2226. if ${ac_cv_prog_CC+:} false; then :
  2227. $as_echo_n "(cached) " >&6
  2228. else
  2229. if test -n "$CC"; then
  2230. ac_cv_prog_CC="$CC" # Let the user override the test.
  2231. else
  2232. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2233. for as_dir in $PATH
  2234. do
  2235. IFS=$as_save_IFS
  2236. test -z "$as_dir" && as_dir=.
  2237. for ac_exec_ext in '' $ac_executable_extensions; do
  2238. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  2239. ac_cv_prog_CC="${ac_tool_prefix}gcc"
  2240. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  2241. break 2
  2242. fi
  2243. done
  2244. done
  2245. IFS=$as_save_IFS
  2246. fi
  2247. fi
  2248. CC=$ac_cv_prog_CC
  2249. if test -n "$CC"; then
  2250. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  2251. $as_echo "$CC" >&6; }
  2252. else
  2253. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  2254. $as_echo "no" >&6; }
  2255. fi
  2256. fi
  2257. if test -z "$ac_cv_prog_CC"; then
  2258. ac_ct_CC=$CC
  2259. # Extract the first word of "gcc", so it can be a program name with args.
  2260. set dummy gcc; ac_word=$2
  2261. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  2262. $as_echo_n "checking for $ac_word... " >&6; }
  2263. if ${ac_cv_prog_ac_ct_CC+:} false; then :
  2264. $as_echo_n "(cached) " >&6
  2265. else
  2266. if test -n "$ac_ct_CC"; then
  2267. ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
  2268. else
  2269. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2270. for as_dir in $PATH
  2271. do
  2272. IFS=$as_save_IFS
  2273. test -z "$as_dir" && as_dir=.
  2274. for ac_exec_ext in '' $ac_executable_extensions; do
  2275. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  2276. ac_cv_prog_ac_ct_CC="gcc"
  2277. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  2278. break 2
  2279. fi
  2280. done
  2281. done
  2282. IFS=$as_save_IFS
  2283. fi
  2284. fi
  2285. ac_ct_CC=$ac_cv_prog_ac_ct_CC
  2286. if test -n "$ac_ct_CC"; then
  2287. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
  2288. $as_echo "$ac_ct_CC" >&6; }
  2289. else
  2290. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  2291. $as_echo "no" >&6; }
  2292. fi
  2293. if test "x$ac_ct_CC" = x; then
  2294. CC=""
  2295. else
  2296. case $cross_compiling:$ac_tool_warned in
  2297. yes:)
  2298. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  2299. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  2300. ac_tool_warned=yes ;;
  2301. esac
  2302. CC=$ac_ct_CC
  2303. fi
  2304. else
  2305. CC="$ac_cv_prog_CC"
  2306. fi
  2307. if test -z "$CC"; then
  2308. if test -n "$ac_tool_prefix"; then
  2309. # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
  2310. set dummy ${ac_tool_prefix}cc; ac_word=$2
  2311. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  2312. $as_echo_n "checking for $ac_word... " >&6; }
  2313. if ${ac_cv_prog_CC+:} false; then :
  2314. $as_echo_n "(cached) " >&6
  2315. else
  2316. if test -n "$CC"; then
  2317. ac_cv_prog_CC="$CC" # Let the user override the test.
  2318. else
  2319. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2320. for as_dir in $PATH
  2321. do
  2322. IFS=$as_save_IFS
  2323. test -z "$as_dir" && as_dir=.
  2324. for ac_exec_ext in '' $ac_executable_extensions; do
  2325. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  2326. ac_cv_prog_CC="${ac_tool_prefix}cc"
  2327. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  2328. break 2
  2329. fi
  2330. done
  2331. done
  2332. IFS=$as_save_IFS
  2333. fi
  2334. fi
  2335. CC=$ac_cv_prog_CC
  2336. if test -n "$CC"; then
  2337. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  2338. $as_echo "$CC" >&6; }
  2339. else
  2340. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  2341. $as_echo "no" >&6; }
  2342. fi
  2343. fi
  2344. fi
  2345. if test -z "$CC"; then
  2346. # Extract the first word of "cc", so it can be a program name with args.
  2347. set dummy cc; ac_word=$2
  2348. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  2349. $as_echo_n "checking for $ac_word... " >&6; }
  2350. if ${ac_cv_prog_CC+:} false; then :
  2351. $as_echo_n "(cached) " >&6
  2352. else
  2353. if test -n "$CC"; then
  2354. ac_cv_prog_CC="$CC" # Let the user override the test.
  2355. else
  2356. ac_prog_rejected=no
  2357. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2358. for as_dir in $PATH
  2359. do
  2360. IFS=$as_save_IFS
  2361. test -z "$as_dir" && as_dir=.
  2362. for ac_exec_ext in '' $ac_executable_extensions; do
  2363. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  2364. if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
  2365. ac_prog_rejected=yes
  2366. continue
  2367. fi
  2368. ac_cv_prog_CC="cc"
  2369. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  2370. break 2
  2371. fi
  2372. done
  2373. done
  2374. IFS=$as_save_IFS
  2375. if test $ac_prog_rejected = yes; then
  2376. # We found a bogon in the path, so make sure we never use it.
  2377. set dummy $ac_cv_prog_CC
  2378. shift
  2379. if test $# != 0; then
  2380. # We chose a different compiler from the bogus one.
  2381. # However, it has the same basename, so the bogon will be chosen
  2382. # first if we set CC to just the basename; use the full file name.
  2383. shift
  2384. ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
  2385. fi
  2386. fi
  2387. fi
  2388. fi
  2389. CC=$ac_cv_prog_CC
  2390. if test -n "$CC"; then
  2391. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  2392. $as_echo "$CC" >&6; }
  2393. else
  2394. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  2395. $as_echo "no" >&6; }
  2396. fi
  2397. fi
  2398. if test -z "$CC"; then
  2399. if test -n "$ac_tool_prefix"; then
  2400. for ac_prog in cl.exe
  2401. do
  2402. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  2403. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  2404. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  2405. $as_echo_n "checking for $ac_word... " >&6; }
  2406. if ${ac_cv_prog_CC+:} false; then :
  2407. $as_echo_n "(cached) " >&6
  2408. else
  2409. if test -n "$CC"; then
  2410. ac_cv_prog_CC="$CC" # Let the user override the test.
  2411. else
  2412. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2413. for as_dir in $PATH
  2414. do
  2415. IFS=$as_save_IFS
  2416. test -z "$as_dir" && as_dir=.
  2417. for ac_exec_ext in '' $ac_executable_extensions; do
  2418. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  2419. ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
  2420. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  2421. break 2
  2422. fi
  2423. done
  2424. done
  2425. IFS=$as_save_IFS
  2426. fi
  2427. fi
  2428. CC=$ac_cv_prog_CC
  2429. if test -n "$CC"; then
  2430. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  2431. $as_echo "$CC" >&6; }
  2432. else
  2433. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  2434. $as_echo "no" >&6; }
  2435. fi
  2436. test -n "$CC" && break
  2437. done
  2438. fi
  2439. if test -z "$CC"; then
  2440. ac_ct_CC=$CC
  2441. for ac_prog in cl.exe
  2442. do
  2443. # Extract the first word of "$ac_prog", so it can be a program name with args.
  2444. set dummy $ac_prog; ac_word=$2
  2445. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  2446. $as_echo_n "checking for $ac_word... " >&6; }
  2447. if ${ac_cv_prog_ac_ct_CC+:} false; then :
  2448. $as_echo_n "(cached) " >&6
  2449. else
  2450. if test -n "$ac_ct_CC"; then
  2451. ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
  2452. else
  2453. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2454. for as_dir in $PATH
  2455. do
  2456. IFS=$as_save_IFS
  2457. test -z "$as_dir" && as_dir=.
  2458. for ac_exec_ext in '' $ac_executable_extensions; do
  2459. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  2460. ac_cv_prog_ac_ct_CC="$ac_prog"
  2461. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  2462. break 2
  2463. fi
  2464. done
  2465. done
  2466. IFS=$as_save_IFS
  2467. fi
  2468. fi
  2469. ac_ct_CC=$ac_cv_prog_ac_ct_CC
  2470. if test -n "$ac_ct_CC"; then
  2471. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
  2472. $as_echo "$ac_ct_CC" >&6; }
  2473. else
  2474. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  2475. $as_echo "no" >&6; }
  2476. fi
  2477. test -n "$ac_ct_CC" && break
  2478. done
  2479. if test "x$ac_ct_CC" = x; then
  2480. CC=""
  2481. else
  2482. case $cross_compiling:$ac_tool_warned in
  2483. yes:)
  2484. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  2485. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  2486. ac_tool_warned=yes ;;
  2487. esac
  2488. CC=$ac_ct_CC
  2489. fi
  2490. fi
  2491. fi
  2492. test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  2493. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  2494. as_fn_error $? "no acceptable C compiler found in \$PATH
  2495. See \`config.log' for more details" "$LINENO" 5; }
  2496. # Provide some information about the compiler.
  2497. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
  2498. set X $ac_compile
  2499. ac_compiler=$2
  2500. for ac_option in --version -v -V -qversion; do
  2501. { { ac_try="$ac_compiler $ac_option >&5"
  2502. case "(($ac_try" in
  2503. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2504. *) ac_try_echo=$ac_try;;
  2505. esac
  2506. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2507. $as_echo "$ac_try_echo"; } >&5
  2508. (eval "$ac_compiler $ac_option >&5") 2>conftest.err
  2509. ac_status=$?
  2510. if test -s conftest.err; then
  2511. sed '10a\
  2512. ... rest of stderr output deleted ...
  2513. 10q' conftest.err >conftest.er1
  2514. cat conftest.er1 >&5
  2515. fi
  2516. rm -f conftest.er1 conftest.err
  2517. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2518. test $ac_status = 0; }
  2519. done
  2520. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2521. /* end confdefs.h. */
  2522. int
  2523. main ()
  2524. {
  2525. ;
  2526. return 0;
  2527. }
  2528. _ACEOF
  2529. ac_clean_files_save=$ac_clean_files
  2530. ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
  2531. # Try to create an executable without -o first, disregard a.out.
  2532. # It will help us diagnose broken compilers, and finding out an intuition
  2533. # of exeext.
  2534. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
  2535. $as_echo_n "checking whether the C compiler works... " >&6; }
  2536. ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
  2537. # The possible output files:
  2538. ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
  2539. ac_rmfiles=
  2540. for ac_file in $ac_files
  2541. do
  2542. case $ac_file in
  2543. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
  2544. * ) ac_rmfiles="$ac_rmfiles $ac_file";;
  2545. esac
  2546. done
  2547. rm -f $ac_rmfiles
  2548. if { { ac_try="$ac_link_default"
  2549. case "(($ac_try" in
  2550. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2551. *) ac_try_echo=$ac_try;;
  2552. esac
  2553. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2554. $as_echo "$ac_try_echo"; } >&5
  2555. (eval "$ac_link_default") 2>&5
  2556. ac_status=$?
  2557. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2558. test $ac_status = 0; }; then :
  2559. # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
  2560. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
  2561. # in a Makefile. We should not override ac_cv_exeext if it was cached,
  2562. # so that the user can short-circuit this test for compilers unknown to
  2563. # Autoconf.
  2564. for ac_file in $ac_files ''
  2565. do
  2566. test -f "$ac_file" || continue
  2567. case $ac_file in
  2568. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
  2569. ;;
  2570. [ab].out )
  2571. # We found the default executable, but exeext='' is most
  2572. # certainly right.
  2573. break;;
  2574. *.* )
  2575. if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
  2576. then :; else
  2577. ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
  2578. fi
  2579. # We set ac_cv_exeext here because the later test for it is not
  2580. # safe: cross compilers may not add the suffix if given an `-o'
  2581. # argument, so we may need to know it at that point already.
  2582. # Even if this section looks crufty: it has the advantage of
  2583. # actually working.
  2584. break;;
  2585. * )
  2586. break;;
  2587. esac
  2588. done
  2589. test "$ac_cv_exeext" = no && ac_cv_exeext=
  2590. else
  2591. ac_file=''
  2592. fi
  2593. if test -z "$ac_file"; then :
  2594. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  2595. $as_echo "no" >&6; }
  2596. $as_echo "$as_me: failed program was:" >&5
  2597. sed 's/^/| /' conftest.$ac_ext >&5
  2598. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  2599. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  2600. as_fn_error 77 "C compiler cannot create executables
  2601. See \`config.log' for more details" "$LINENO" 5; }
  2602. else
  2603. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  2604. $as_echo "yes" >&6; }
  2605. fi
  2606. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
  2607. $as_echo_n "checking for C compiler default output file name... " >&6; }
  2608. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
  2609. $as_echo "$ac_file" >&6; }
  2610. ac_exeext=$ac_cv_exeext
  2611. rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
  2612. ac_clean_files=$ac_clean_files_save
  2613. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
  2614. $as_echo_n "checking for suffix of executables... " >&6; }
  2615. if { { ac_try="$ac_link"
  2616. case "(($ac_try" in
  2617. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2618. *) ac_try_echo=$ac_try;;
  2619. esac
  2620. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2621. $as_echo "$ac_try_echo"; } >&5
  2622. (eval "$ac_link") 2>&5
  2623. ac_status=$?
  2624. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2625. test $ac_status = 0; }; then :
  2626. # If both `conftest.exe' and `conftest' are `present' (well, observable)
  2627. # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
  2628. # work properly (i.e., refer to `conftest.exe'), while it won't with
  2629. # `rm'.
  2630. for ac_file in conftest.exe conftest conftest.*; do
  2631. test -f "$ac_file" || continue
  2632. case $ac_file in
  2633. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
  2634. *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
  2635. break;;
  2636. * ) break;;
  2637. esac
  2638. done
  2639. else
  2640. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  2641. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  2642. as_fn_error $? "cannot compute suffix of executables: cannot compile and link
  2643. See \`config.log' for more details" "$LINENO" 5; }
  2644. fi
  2645. rm -f conftest conftest$ac_cv_exeext
  2646. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
  2647. $as_echo "$ac_cv_exeext" >&6; }
  2648. rm -f conftest.$ac_ext
  2649. EXEEXT=$ac_cv_exeext
  2650. ac_exeext=$EXEEXT
  2651. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2652. /* end confdefs.h. */
  2653. #include <stdio.h>
  2654. int
  2655. main ()
  2656. {
  2657. FILE *f = fopen ("conftest.out", "w");
  2658. return ferror (f) || fclose (f) != 0;
  2659. ;
  2660. return 0;
  2661. }
  2662. _ACEOF
  2663. ac_clean_files="$ac_clean_files conftest.out"
  2664. # Check that the compiler produces executables we can run. If not, either
  2665. # the compiler is broken, or we cross compile.
  2666. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
  2667. $as_echo_n "checking whether we are cross compiling... " >&6; }
  2668. if test "$cross_compiling" != yes; then
  2669. { { ac_try="$ac_link"
  2670. case "(($ac_try" in
  2671. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2672. *) ac_try_echo=$ac_try;;
  2673. esac
  2674. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2675. $as_echo "$ac_try_echo"; } >&5
  2676. (eval "$ac_link") 2>&5
  2677. ac_status=$?
  2678. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2679. test $ac_status = 0; }
  2680. if { ac_try='./conftest$ac_cv_exeext'
  2681. { { case "(($ac_try" in
  2682. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2683. *) ac_try_echo=$ac_try;;
  2684. esac
  2685. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2686. $as_echo "$ac_try_echo"; } >&5
  2687. (eval "$ac_try") 2>&5
  2688. ac_status=$?
  2689. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2690. test $ac_status = 0; }; }; then
  2691. cross_compiling=no
  2692. else
  2693. if test "$cross_compiling" = maybe; then
  2694. cross_compiling=yes
  2695. else
  2696. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  2697. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  2698. as_fn_error $? "cannot run C compiled programs.
  2699. If you meant to cross compile, use \`--host'.
  2700. See \`config.log' for more details" "$LINENO" 5; }
  2701. fi
  2702. fi
  2703. fi
  2704. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
  2705. $as_echo "$cross_compiling" >&6; }
  2706. rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
  2707. ac_clean_files=$ac_clean_files_save
  2708. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
  2709. $as_echo_n "checking for suffix of object files... " >&6; }
  2710. if ${ac_cv_objext+:} false; then :
  2711. $as_echo_n "(cached) " >&6
  2712. else
  2713. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2714. /* end confdefs.h. */
  2715. int
  2716. main ()
  2717. {
  2718. ;
  2719. return 0;
  2720. }
  2721. _ACEOF
  2722. rm -f conftest.o conftest.obj
  2723. if { { ac_try="$ac_compile"
  2724. case "(($ac_try" in
  2725. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2726. *) ac_try_echo=$ac_try;;
  2727. esac
  2728. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2729. $as_echo "$ac_try_echo"; } >&5
  2730. (eval "$ac_compile") 2>&5
  2731. ac_status=$?
  2732. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2733. test $ac_status = 0; }; then :
  2734. for ac_file in conftest.o conftest.obj conftest.*; do
  2735. test -f "$ac_file" || continue;
  2736. case $ac_file in
  2737. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
  2738. *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
  2739. break;;
  2740. esac
  2741. done
  2742. else
  2743. $as_echo "$as_me: failed program was:" >&5
  2744. sed 's/^/| /' conftest.$ac_ext >&5
  2745. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  2746. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  2747. as_fn_error $? "cannot compute suffix of object files: cannot compile
  2748. See \`config.log' for more details" "$LINENO" 5; }
  2749. fi
  2750. rm -f conftest.$ac_cv_objext conftest.$ac_ext
  2751. fi
  2752. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
  2753. $as_echo "$ac_cv_objext" >&6; }
  2754. OBJEXT=$ac_cv_objext
  2755. ac_objext=$OBJEXT
  2756. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
  2757. $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
  2758. if ${ac_cv_c_compiler_gnu+:} false; then :
  2759. $as_echo_n "(cached) " >&6
  2760. else
  2761. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2762. /* end confdefs.h. */
  2763. int
  2764. main ()
  2765. {
  2766. #ifndef __GNUC__
  2767. choke me
  2768. #endif
  2769. ;
  2770. return 0;
  2771. }
  2772. _ACEOF
  2773. if ac_fn_c_try_compile "$LINENO"; then :
  2774. ac_compiler_gnu=yes
  2775. else
  2776. ac_compiler_gnu=no
  2777. fi
  2778. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2779. ac_cv_c_compiler_gnu=$ac_compiler_gnu
  2780. fi
  2781. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
  2782. $as_echo "$ac_cv_c_compiler_gnu" >&6; }
  2783. if test $ac_compiler_gnu = yes; then
  2784. GCC=yes
  2785. else
  2786. GCC=
  2787. fi
  2788. ac_test_CFLAGS=${CFLAGS+set}
  2789. ac_save_CFLAGS=$CFLAGS
  2790. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
  2791. $as_echo_n "checking whether $CC accepts -g... " >&6; }
  2792. if ${ac_cv_prog_cc_g+:} false; then :
  2793. $as_echo_n "(cached) " >&6
  2794. else
  2795. ac_save_c_werror_flag=$ac_c_werror_flag
  2796. ac_c_werror_flag=yes
  2797. ac_cv_prog_cc_g=no
  2798. CFLAGS="-g"
  2799. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2800. /* end confdefs.h. */
  2801. int
  2802. main ()
  2803. {
  2804. ;
  2805. return 0;
  2806. }
  2807. _ACEOF
  2808. if ac_fn_c_try_compile "$LINENO"; then :
  2809. ac_cv_prog_cc_g=yes
  2810. else
  2811. CFLAGS=""
  2812. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2813. /* end confdefs.h. */
  2814. int
  2815. main ()
  2816. {
  2817. ;
  2818. return 0;
  2819. }
  2820. _ACEOF
  2821. if ac_fn_c_try_compile "$LINENO"; then :
  2822. else
  2823. ac_c_werror_flag=$ac_save_c_werror_flag
  2824. CFLAGS="-g"
  2825. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2826. /* end confdefs.h. */
  2827. int
  2828. main ()
  2829. {
  2830. ;
  2831. return 0;
  2832. }
  2833. _ACEOF
  2834. if ac_fn_c_try_compile "$LINENO"; then :
  2835. ac_cv_prog_cc_g=yes
  2836. fi
  2837. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2838. fi
  2839. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2840. fi
  2841. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2842. ac_c_werror_flag=$ac_save_c_werror_flag
  2843. fi
  2844. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
  2845. $as_echo "$ac_cv_prog_cc_g" >&6; }
  2846. if test "$ac_test_CFLAGS" = set; then
  2847. CFLAGS=$ac_save_CFLAGS
  2848. elif test $ac_cv_prog_cc_g = yes; then
  2849. if test "$GCC" = yes; then
  2850. CFLAGS="-g -O2"
  2851. else
  2852. CFLAGS="-g"
  2853. fi
  2854. else
  2855. if test "$GCC" = yes; then
  2856. CFLAGS="-O2"
  2857. else
  2858. CFLAGS=
  2859. fi
  2860. fi
  2861. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
  2862. $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
  2863. if ${ac_cv_prog_cc_c89+:} false; then :
  2864. $as_echo_n "(cached) " >&6
  2865. else
  2866. ac_cv_prog_cc_c89=no
  2867. ac_save_CC=$CC
  2868. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2869. /* end confdefs.h. */
  2870. #include <stdarg.h>
  2871. #include <stdio.h>
  2872. struct stat;
  2873. /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
  2874. struct buf { int x; };
  2875. FILE * (*rcsopen) (struct buf *, struct stat *, int);
  2876. static char *e (p, i)
  2877. char **p;
  2878. int i;
  2879. {
  2880. return p[i];
  2881. }
  2882. static char *f (char * (*g) (char **, int), char **p, ...)
  2883. {
  2884. char *s;
  2885. va_list v;
  2886. va_start (v,p);
  2887. s = g (p, va_arg (v,int));
  2888. va_end (v);
  2889. return s;
  2890. }
  2891. /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
  2892. function prototypes and stuff, but not '\xHH' hex character constants.
  2893. These don't provoke an error unfortunately, instead are silently treated
  2894. as 'x'. The following induces an error, until -std is added to get
  2895. proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
  2896. array size at least. It's necessary to write '\x00'==0 to get something
  2897. that's true only with -std. */
  2898. int osf4_cc_array ['\x00' == 0 ? 1 : -1];
  2899. /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
  2900. inside strings and character constants. */
  2901. #define FOO(x) 'x'
  2902. int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
  2903. int test (int i, double x);
  2904. struct s1 {int (*f) (int a);};
  2905. struct s2 {int (*f) (double a);};
  2906. int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
  2907. int argc;
  2908. char **argv;
  2909. int
  2910. main ()
  2911. {
  2912. return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
  2913. ;
  2914. return 0;
  2915. }
  2916. _ACEOF
  2917. for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
  2918. -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
  2919. do
  2920. CC="$ac_save_CC $ac_arg"
  2921. if ac_fn_c_try_compile "$LINENO"; then :
  2922. ac_cv_prog_cc_c89=$ac_arg
  2923. fi
  2924. rm -f core conftest.err conftest.$ac_objext
  2925. test "x$ac_cv_prog_cc_c89" != "xno" && break
  2926. done
  2927. rm -f conftest.$ac_ext
  2928. CC=$ac_save_CC
  2929. fi
  2930. # AC_CACHE_VAL
  2931. case "x$ac_cv_prog_cc_c89" in
  2932. x)
  2933. { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
  2934. $as_echo "none needed" >&6; } ;;
  2935. xno)
  2936. { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
  2937. $as_echo "unsupported" >&6; } ;;
  2938. *)
  2939. CC="$CC $ac_cv_prog_cc_c89"
  2940. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
  2941. $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
  2942. esac
  2943. if test "x$ac_cv_prog_cc_c89" != xno; then :
  2944. fi
  2945. ac_ext=c
  2946. ac_cpp='$CPP $CPPFLAGS'
  2947. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  2948. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  2949. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  2950. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
  2951. $as_echo_n "checking for a sed that does not truncate output... " >&6; }
  2952. if ${ac_cv_path_SED+:} false; then :
  2953. $as_echo_n "(cached) " >&6
  2954. else
  2955. ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
  2956. for ac_i in 1 2 3 4 5 6 7; do
  2957. ac_script="$ac_script$as_nl$ac_script"
  2958. done
  2959. echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
  2960. { ac_script=; unset ac_script;}
  2961. if test -z "$SED"; then
  2962. ac_path_SED_found=false
  2963. # Loop through the user's path and test for each of PROGNAME-LIST
  2964. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2965. for as_dir in $PATH
  2966. do
  2967. IFS=$as_save_IFS
  2968. test -z "$as_dir" && as_dir=.
  2969. for ac_prog in sed gsed; do
  2970. for ac_exec_ext in '' $ac_executable_extensions; do
  2971. ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
  2972. as_fn_executable_p "$ac_path_SED" || continue
  2973. # Check for GNU ac_path_SED and select it if it is found.
  2974. # Check for GNU $ac_path_SED
  2975. case `"$ac_path_SED" --version 2>&1` in
  2976. *GNU*)
  2977. ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
  2978. *)
  2979. ac_count=0
  2980. $as_echo_n 0123456789 >"conftest.in"
  2981. while :
  2982. do
  2983. cat "conftest.in" "conftest.in" >"conftest.tmp"
  2984. mv "conftest.tmp" "conftest.in"
  2985. cp "conftest.in" "conftest.nl"
  2986. $as_echo '' >> "conftest.nl"
  2987. "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
  2988. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  2989. as_fn_arith $ac_count + 1 && ac_count=$as_val
  2990. if test $ac_count -gt ${ac_path_SED_max-0}; then
  2991. # Best one so far, save it but keep looking for a better one
  2992. ac_cv_path_SED="$ac_path_SED"
  2993. ac_path_SED_max=$ac_count
  2994. fi
  2995. # 10*(2^10) chars as input seems more than enough
  2996. test $ac_count -gt 10 && break
  2997. done
  2998. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  2999. esac
  3000. $ac_path_SED_found && break 3
  3001. done
  3002. done
  3003. done
  3004. IFS=$as_save_IFS
  3005. if test -z "$ac_cv_path_SED"; then
  3006. as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
  3007. fi
  3008. else
  3009. ac_cv_path_SED=$SED
  3010. fi
  3011. fi
  3012. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
  3013. $as_echo "$ac_cv_path_SED" >&6; }
  3014. SED="$ac_cv_path_SED"
  3015. rm -f conftest.sed
  3016. test -z "$SED" && SED=sed
  3017. Xsed="$SED -e 1s/^X//"
  3018. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
  3019. $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
  3020. if ${ac_cv_path_GREP+:} false; then :
  3021. $as_echo_n "(cached) " >&6
  3022. else
  3023. if test -z "$GREP"; then
  3024. ac_path_GREP_found=false
  3025. # Loop through the user's path and test for each of PROGNAME-LIST
  3026. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3027. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  3028. do
  3029. IFS=$as_save_IFS
  3030. test -z "$as_dir" && as_dir=.
  3031. for ac_prog in grep ggrep; do
  3032. for ac_exec_ext in '' $ac_executable_extensions; do
  3033. ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
  3034. as_fn_executable_p "$ac_path_GREP" || continue
  3035. # Check for GNU ac_path_GREP and select it if it is found.
  3036. # Check for GNU $ac_path_GREP
  3037. case `"$ac_path_GREP" --version 2>&1` in
  3038. *GNU*)
  3039. ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
  3040. *)
  3041. ac_count=0
  3042. $as_echo_n 0123456789 >"conftest.in"
  3043. while :
  3044. do
  3045. cat "conftest.in" "conftest.in" >"conftest.tmp"
  3046. mv "conftest.tmp" "conftest.in"
  3047. cp "conftest.in" "conftest.nl"
  3048. $as_echo 'GREP' >> "conftest.nl"
  3049. "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
  3050. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  3051. as_fn_arith $ac_count + 1 && ac_count=$as_val
  3052. if test $ac_count -gt ${ac_path_GREP_max-0}; then
  3053. # Best one so far, save it but keep looking for a better one
  3054. ac_cv_path_GREP="$ac_path_GREP"
  3055. ac_path_GREP_max=$ac_count
  3056. fi
  3057. # 10*(2^10) chars as input seems more than enough
  3058. test $ac_count -gt 10 && break
  3059. done
  3060. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  3061. esac
  3062. $ac_path_GREP_found && break 3
  3063. done
  3064. done
  3065. done
  3066. IFS=$as_save_IFS
  3067. if test -z "$ac_cv_path_GREP"; then
  3068. as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  3069. fi
  3070. else
  3071. ac_cv_path_GREP=$GREP
  3072. fi
  3073. fi
  3074. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
  3075. $as_echo "$ac_cv_path_GREP" >&6; }
  3076. GREP="$ac_cv_path_GREP"
  3077. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
  3078. $as_echo_n "checking for egrep... " >&6; }
  3079. if ${ac_cv_path_EGREP+:} false; then :
  3080. $as_echo_n "(cached) " >&6
  3081. else
  3082. if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
  3083. then ac_cv_path_EGREP="$GREP -E"
  3084. else
  3085. if test -z "$EGREP"; then
  3086. ac_path_EGREP_found=false
  3087. # Loop through the user's path and test for each of PROGNAME-LIST
  3088. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3089. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  3090. do
  3091. IFS=$as_save_IFS
  3092. test -z "$as_dir" && as_dir=.
  3093. for ac_prog in egrep; do
  3094. for ac_exec_ext in '' $ac_executable_extensions; do
  3095. ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
  3096. as_fn_executable_p "$ac_path_EGREP" || continue
  3097. # Check for GNU ac_path_EGREP and select it if it is found.
  3098. # Check for GNU $ac_path_EGREP
  3099. case `"$ac_path_EGREP" --version 2>&1` in
  3100. *GNU*)
  3101. ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
  3102. *)
  3103. ac_count=0
  3104. $as_echo_n 0123456789 >"conftest.in"
  3105. while :
  3106. do
  3107. cat "conftest.in" "conftest.in" >"conftest.tmp"
  3108. mv "conftest.tmp" "conftest.in"
  3109. cp "conftest.in" "conftest.nl"
  3110. $as_echo 'EGREP' >> "conftest.nl"
  3111. "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
  3112. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  3113. as_fn_arith $ac_count + 1 && ac_count=$as_val
  3114. if test $ac_count -gt ${ac_path_EGREP_max-0}; then
  3115. # Best one so far, save it but keep looking for a better one
  3116. ac_cv_path_EGREP="$ac_path_EGREP"
  3117. ac_path_EGREP_max=$ac_count
  3118. fi
  3119. # 10*(2^10) chars as input seems more than enough
  3120. test $ac_count -gt 10 && break
  3121. done
  3122. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  3123. esac
  3124. $ac_path_EGREP_found && break 3
  3125. done
  3126. done
  3127. done
  3128. IFS=$as_save_IFS
  3129. if test -z "$ac_cv_path_EGREP"; then
  3130. as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  3131. fi
  3132. else
  3133. ac_cv_path_EGREP=$EGREP
  3134. fi
  3135. fi
  3136. fi
  3137. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
  3138. $as_echo "$ac_cv_path_EGREP" >&6; }
  3139. EGREP="$ac_cv_path_EGREP"
  3140. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
  3141. $as_echo_n "checking for fgrep... " >&6; }
  3142. if ${ac_cv_path_FGREP+:} false; then :
  3143. $as_echo_n "(cached) " >&6
  3144. else
  3145. if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
  3146. then ac_cv_path_FGREP="$GREP -F"
  3147. else
  3148. if test -z "$FGREP"; then
  3149. ac_path_FGREP_found=false
  3150. # Loop through the user's path and test for each of PROGNAME-LIST
  3151. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3152. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  3153. do
  3154. IFS=$as_save_IFS
  3155. test -z "$as_dir" && as_dir=.
  3156. for ac_prog in fgrep; do
  3157. for ac_exec_ext in '' $ac_executable_extensions; do
  3158. ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
  3159. as_fn_executable_p "$ac_path_FGREP" || continue
  3160. # Check for GNU ac_path_FGREP and select it if it is found.
  3161. # Check for GNU $ac_path_FGREP
  3162. case `"$ac_path_FGREP" --version 2>&1` in
  3163. *GNU*)
  3164. ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
  3165. *)
  3166. ac_count=0
  3167. $as_echo_n 0123456789 >"conftest.in"
  3168. while :
  3169. do
  3170. cat "conftest.in" "conftest.in" >"conftest.tmp"
  3171. mv "conftest.tmp" "conftest.in"
  3172. cp "conftest.in" "conftest.nl"
  3173. $as_echo 'FGREP' >> "conftest.nl"
  3174. "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
  3175. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  3176. as_fn_arith $ac_count + 1 && ac_count=$as_val
  3177. if test $ac_count -gt ${ac_path_FGREP_max-0}; then
  3178. # Best one so far, save it but keep looking for a better one
  3179. ac_cv_path_FGREP="$ac_path_FGREP"
  3180. ac_path_FGREP_max=$ac_count
  3181. fi
  3182. # 10*(2^10) chars as input seems more than enough
  3183. test $ac_count -gt 10 && break
  3184. done
  3185. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  3186. esac
  3187. $ac_path_FGREP_found && break 3
  3188. done
  3189. done
  3190. done
  3191. IFS=$as_save_IFS
  3192. if test -z "$ac_cv_path_FGREP"; then
  3193. as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  3194. fi
  3195. else
  3196. ac_cv_path_FGREP=$FGREP
  3197. fi
  3198. fi
  3199. fi
  3200. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
  3201. $as_echo "$ac_cv_path_FGREP" >&6; }
  3202. FGREP="$ac_cv_path_FGREP"
  3203. test -z "$GREP" && GREP=grep
  3204. # Check whether --with-gnu-ld was given.
  3205. if test "${with_gnu_ld+set}" = set; then :
  3206. withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
  3207. else
  3208. with_gnu_ld=no
  3209. fi
  3210. ac_prog=ld
  3211. if test "$GCC" = yes; then
  3212. # Check if gcc -print-prog-name=ld gives a path.
  3213. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
  3214. $as_echo_n "checking for ld used by $CC... " >&6; }
  3215. case $host in
  3216. *-*-mingw*)
  3217. # gcc leaves a trailing carriage return which upsets mingw
  3218. ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
  3219. *)
  3220. ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
  3221. esac
  3222. case $ac_prog in
  3223. # Accept absolute paths.
  3224. [\\/]* | ?:[\\/]*)
  3225. re_direlt='/[^/][^/]*/\.\./'
  3226. # Canonicalize the pathname of ld
  3227. ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
  3228. while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
  3229. ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
  3230. done
  3231. test -z "$LD" && LD="$ac_prog"
  3232. ;;
  3233. "")
  3234. # If it fails, then pretend we aren't using GCC.
  3235. ac_prog=ld
  3236. ;;
  3237. *)
  3238. # If it is relative, then search for the first ld in PATH.
  3239. with_gnu_ld=unknown
  3240. ;;
  3241. esac
  3242. elif test "$with_gnu_ld" = yes; then
  3243. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
  3244. $as_echo_n "checking for GNU ld... " >&6; }
  3245. else
  3246. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
  3247. $as_echo_n "checking for non-GNU ld... " >&6; }
  3248. fi
  3249. if ${lt_cv_path_LD+:} false; then :
  3250. $as_echo_n "(cached) " >&6
  3251. else
  3252. if test -z "$LD"; then
  3253. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  3254. for ac_dir in $PATH; do
  3255. IFS="$lt_save_ifs"
  3256. test -z "$ac_dir" && ac_dir=.
  3257. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
  3258. lt_cv_path_LD="$ac_dir/$ac_prog"
  3259. # Check to see if the program is GNU ld. I'd rather use --version,
  3260. # but apparently some variants of GNU ld only accept -v.
  3261. # Break only if it was the GNU/non-GNU ld that we prefer.
  3262. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
  3263. *GNU* | *'with BFD'*)
  3264. test "$with_gnu_ld" != no && break
  3265. ;;
  3266. *)
  3267. test "$with_gnu_ld" != yes && break
  3268. ;;
  3269. esac
  3270. fi
  3271. done
  3272. IFS="$lt_save_ifs"
  3273. else
  3274. lt_cv_path_LD="$LD" # Let the user override the test with a path.
  3275. fi
  3276. fi
  3277. LD="$lt_cv_path_LD"
  3278. if test -n "$LD"; then
  3279. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
  3280. $as_echo "$LD" >&6; }
  3281. else
  3282. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3283. $as_echo "no" >&6; }
  3284. fi
  3285. test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
  3286. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
  3287. $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
  3288. if ${lt_cv_prog_gnu_ld+:} false; then :
  3289. $as_echo_n "(cached) " >&6
  3290. else
  3291. # I'd rather use --version here, but apparently some GNU lds only accept -v.
  3292. case `$LD -v 2>&1 </dev/null` in
  3293. *GNU* | *'with BFD'*)
  3294. lt_cv_prog_gnu_ld=yes
  3295. ;;
  3296. *)
  3297. lt_cv_prog_gnu_ld=no
  3298. ;;
  3299. esac
  3300. fi
  3301. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
  3302. $as_echo "$lt_cv_prog_gnu_ld" >&6; }
  3303. with_gnu_ld=$lt_cv_prog_gnu_ld
  3304. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
  3305. $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
  3306. if ${lt_cv_path_NM+:} false; then :
  3307. $as_echo_n "(cached) " >&6
  3308. else
  3309. if test -n "$NM"; then
  3310. # Let the user override the test.
  3311. lt_cv_path_NM="$NM"
  3312. else
  3313. lt_nm_to_check="${ac_tool_prefix}nm"
  3314. if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
  3315. lt_nm_to_check="$lt_nm_to_check nm"
  3316. fi
  3317. for lt_tmp_nm in $lt_nm_to_check; do
  3318. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  3319. for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
  3320. IFS="$lt_save_ifs"
  3321. test -z "$ac_dir" && ac_dir=.
  3322. tmp_nm="$ac_dir/$lt_tmp_nm"
  3323. if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
  3324. # Check to see if the nm accepts a BSD-compat flag.
  3325. # Adding the `sed 1q' prevents false positives on HP-UX, which says:
  3326. # nm: unknown option "B" ignored
  3327. # Tru64's nm complains that /dev/null is an invalid object file
  3328. case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
  3329. */dev/null* | *'Invalid file or object type'*)
  3330. lt_cv_path_NM="$tmp_nm -B"
  3331. break
  3332. ;;
  3333. *)
  3334. case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
  3335. */dev/null*)
  3336. lt_cv_path_NM="$tmp_nm -p"
  3337. break
  3338. ;;
  3339. *)
  3340. lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
  3341. continue # so that we can try to find one that supports BSD flags
  3342. ;;
  3343. esac
  3344. ;;
  3345. esac
  3346. fi
  3347. done
  3348. IFS="$lt_save_ifs"
  3349. done
  3350. : ${lt_cv_path_NM=no}
  3351. fi
  3352. fi
  3353. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
  3354. $as_echo "$lt_cv_path_NM" >&6; }
  3355. if test "$lt_cv_path_NM" != "no"; then
  3356. NM="$lt_cv_path_NM"
  3357. else
  3358. # Didn't find any BSD compatible name lister, look for dumpbin.
  3359. if test -n "$DUMPBIN"; then :
  3360. # Let the user override the test.
  3361. else
  3362. if test -n "$ac_tool_prefix"; then
  3363. for ac_prog in dumpbin "link -dump"
  3364. do
  3365. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  3366. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  3367. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  3368. $as_echo_n "checking for $ac_word... " >&6; }
  3369. if ${ac_cv_prog_DUMPBIN+:} false; then :
  3370. $as_echo_n "(cached) " >&6
  3371. else
  3372. if test -n "$DUMPBIN"; then
  3373. ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
  3374. else
  3375. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3376. for as_dir in $PATH
  3377. do
  3378. IFS=$as_save_IFS
  3379. test -z "$as_dir" && as_dir=.
  3380. for ac_exec_ext in '' $ac_executable_extensions; do
  3381. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  3382. ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
  3383. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  3384. break 2
  3385. fi
  3386. done
  3387. done
  3388. IFS=$as_save_IFS
  3389. fi
  3390. fi
  3391. DUMPBIN=$ac_cv_prog_DUMPBIN
  3392. if test -n "$DUMPBIN"; then
  3393. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
  3394. $as_echo "$DUMPBIN" >&6; }
  3395. else
  3396. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3397. $as_echo "no" >&6; }
  3398. fi
  3399. test -n "$DUMPBIN" && break
  3400. done
  3401. fi
  3402. if test -z "$DUMPBIN"; then
  3403. ac_ct_DUMPBIN=$DUMPBIN
  3404. for ac_prog in dumpbin "link -dump"
  3405. do
  3406. # Extract the first word of "$ac_prog", so it can be a program name with args.
  3407. set dummy $ac_prog; ac_word=$2
  3408. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  3409. $as_echo_n "checking for $ac_word... " >&6; }
  3410. if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
  3411. $as_echo_n "(cached) " >&6
  3412. else
  3413. if test -n "$ac_ct_DUMPBIN"; then
  3414. ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
  3415. else
  3416. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3417. for as_dir in $PATH
  3418. do
  3419. IFS=$as_save_IFS
  3420. test -z "$as_dir" && as_dir=.
  3421. for ac_exec_ext in '' $ac_executable_extensions; do
  3422. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  3423. ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
  3424. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  3425. break 2
  3426. fi
  3427. done
  3428. done
  3429. IFS=$as_save_IFS
  3430. fi
  3431. fi
  3432. ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
  3433. if test -n "$ac_ct_DUMPBIN"; then
  3434. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
  3435. $as_echo "$ac_ct_DUMPBIN" >&6; }
  3436. else
  3437. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3438. $as_echo "no" >&6; }
  3439. fi
  3440. test -n "$ac_ct_DUMPBIN" && break
  3441. done
  3442. if test "x$ac_ct_DUMPBIN" = x; then
  3443. DUMPBIN=":"
  3444. else
  3445. case $cross_compiling:$ac_tool_warned in
  3446. yes:)
  3447. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  3448. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  3449. ac_tool_warned=yes ;;
  3450. esac
  3451. DUMPBIN=$ac_ct_DUMPBIN
  3452. fi
  3453. fi
  3454. case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
  3455. *COFF*)
  3456. DUMPBIN="$DUMPBIN -symbols"
  3457. ;;
  3458. *)
  3459. DUMPBIN=:
  3460. ;;
  3461. esac
  3462. fi
  3463. if test "$DUMPBIN" != ":"; then
  3464. NM="$DUMPBIN"
  3465. fi
  3466. fi
  3467. test -z "$NM" && NM=nm
  3468. { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
  3469. $as_echo_n "checking the name lister ($NM) interface... " >&6; }
  3470. if ${lt_cv_nm_interface+:} false; then :
  3471. $as_echo_n "(cached) " >&6
  3472. else
  3473. lt_cv_nm_interface="BSD nm"
  3474. echo "int some_variable = 0;" > conftest.$ac_ext
  3475. (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
  3476. (eval "$ac_compile" 2>conftest.err)
  3477. cat conftest.err >&5
  3478. (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
  3479. (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
  3480. cat conftest.err >&5
  3481. (eval echo "\"\$as_me:$LINENO: output\"" >&5)
  3482. cat conftest.out >&5
  3483. if $GREP 'External.*some_variable' conftest.out > /dev/null; then
  3484. lt_cv_nm_interface="MS dumpbin"
  3485. fi
  3486. rm -f conftest*
  3487. fi
  3488. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
  3489. $as_echo "$lt_cv_nm_interface" >&6; }
  3490. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
  3491. $as_echo_n "checking whether ln -s works... " >&6; }
  3492. LN_S=$as_ln_s
  3493. if test "$LN_S" = "ln -s"; then
  3494. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  3495. $as_echo "yes" >&6; }
  3496. else
  3497. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
  3498. $as_echo "no, using $LN_S" >&6; }
  3499. fi
  3500. # find the maximum length of command line arguments
  3501. { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
  3502. $as_echo_n "checking the maximum length of command line arguments... " >&6; }
  3503. if ${lt_cv_sys_max_cmd_len+:} false; then :
  3504. $as_echo_n "(cached) " >&6
  3505. else
  3506. i=0
  3507. teststring="ABCD"
  3508. case $build_os in
  3509. msdosdjgpp*)
  3510. # On DJGPP, this test can blow up pretty badly due to problems in libc
  3511. # (any single argument exceeding 2000 bytes causes a buffer overrun
  3512. # during glob expansion). Even if it were fixed, the result of this
  3513. # check would be larger than it should be.
  3514. lt_cv_sys_max_cmd_len=12288; # 12K is about right
  3515. ;;
  3516. gnu*)
  3517. # Under GNU Hurd, this test is not required because there is
  3518. # no limit to the length of command line arguments.
  3519. # Libtool will interpret -1 as no limit whatsoever
  3520. lt_cv_sys_max_cmd_len=-1;
  3521. ;;
  3522. cygwin* | mingw* | cegcc*)
  3523. # On Win9x/ME, this test blows up -- it succeeds, but takes
  3524. # about 5 minutes as the teststring grows exponentially.
  3525. # Worse, since 9x/ME are not pre-emptively multitasking,
  3526. # you end up with a "frozen" computer, even though with patience
  3527. # the test eventually succeeds (with a max line length of 256k).
  3528. # Instead, let's just punt: use the minimum linelength reported by
  3529. # all of the supported platforms: 8192 (on NT/2K/XP).
  3530. lt_cv_sys_max_cmd_len=8192;
  3531. ;;
  3532. mint*)
  3533. # On MiNT this can take a long time and run out of memory.
  3534. lt_cv_sys_max_cmd_len=8192;
  3535. ;;
  3536. amigaos*)
  3537. # On AmigaOS with pdksh, this test takes hours, literally.
  3538. # So we just punt and use a minimum line length of 8192.
  3539. lt_cv_sys_max_cmd_len=8192;
  3540. ;;
  3541. netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
  3542. # This has been around since 386BSD, at least. Likely further.
  3543. if test -x /sbin/sysctl; then
  3544. lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
  3545. elif test -x /usr/sbin/sysctl; then
  3546. lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
  3547. else
  3548. lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
  3549. fi
  3550. # And add a safety zone
  3551. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
  3552. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
  3553. ;;
  3554. interix*)
  3555. # We know the value 262144 and hardcode it with a safety zone (like BSD)
  3556. lt_cv_sys_max_cmd_len=196608
  3557. ;;
  3558. os2*)
  3559. # The test takes a long time on OS/2.
  3560. lt_cv_sys_max_cmd_len=8192
  3561. ;;
  3562. osf*)
  3563. # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
  3564. # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
  3565. # nice to cause kernel panics so lets avoid the loop below.
  3566. # First set a reasonable default.
  3567. lt_cv_sys_max_cmd_len=16384
  3568. #
  3569. if test -x /sbin/sysconfig; then
  3570. case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
  3571. *1*) lt_cv_sys_max_cmd_len=-1 ;;
  3572. esac
  3573. fi
  3574. ;;
  3575. sco3.2v5*)
  3576. lt_cv_sys_max_cmd_len=102400
  3577. ;;
  3578. sysv5* | sco5v6* | sysv4.2uw2*)
  3579. kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
  3580. if test -n "$kargmax"; then
  3581. lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
  3582. else
  3583. lt_cv_sys_max_cmd_len=32768
  3584. fi
  3585. ;;
  3586. *)
  3587. lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
  3588. if test -n "$lt_cv_sys_max_cmd_len"; then
  3589. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
  3590. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
  3591. else
  3592. # Make teststring a little bigger before we do anything with it.
  3593. # a 1K string should be a reasonable start.
  3594. for i in 1 2 3 4 5 6 7 8 ; do
  3595. teststring=$teststring$teststring
  3596. done
  3597. SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
  3598. # If test is not a shell built-in, we'll probably end up computing a
  3599. # maximum length that is only half of the actual maximum length, but
  3600. # we can't tell.
  3601. while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
  3602. = "X$teststring$teststring"; } >/dev/null 2>&1 &&
  3603. test $i != 17 # 1/2 MB should be enough
  3604. do
  3605. i=`expr $i + 1`
  3606. teststring=$teststring$teststring
  3607. done
  3608. # Only check the string length outside the loop.
  3609. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
  3610. teststring=
  3611. # Add a significant safety factor because C++ compilers can tack on
  3612. # massive amounts of additional arguments before passing them to the
  3613. # linker. It appears as though 1/2 is a usable value.
  3614. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
  3615. fi
  3616. ;;
  3617. esac
  3618. fi
  3619. if test -n $lt_cv_sys_max_cmd_len ; then
  3620. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
  3621. $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
  3622. else
  3623. { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
  3624. $as_echo "none" >&6; }
  3625. fi
  3626. max_cmd_len=$lt_cv_sys_max_cmd_len
  3627. : ${CP="cp -f"}
  3628. : ${MV="mv -f"}
  3629. : ${RM="rm -f"}
  3630. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
  3631. $as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
  3632. # Try some XSI features
  3633. xsi_shell=no
  3634. ( _lt_dummy="a/b/c"
  3635. test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
  3636. = c,a/b,b/c, \
  3637. && eval 'test $(( 1 + 1 )) -eq 2 \
  3638. && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
  3639. && xsi_shell=yes
  3640. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
  3641. $as_echo "$xsi_shell" >&6; }
  3642. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
  3643. $as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
  3644. lt_shell_append=no
  3645. ( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
  3646. >/dev/null 2>&1 \
  3647. && lt_shell_append=yes
  3648. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
  3649. $as_echo "$lt_shell_append" >&6; }
  3650. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
  3651. lt_unset=unset
  3652. else
  3653. lt_unset=false
  3654. fi
  3655. # test EBCDIC or ASCII
  3656. case `echo X|tr X '\101'` in
  3657. A) # ASCII based system
  3658. # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
  3659. lt_SP2NL='tr \040 \012'
  3660. lt_NL2SP='tr \015\012 \040\040'
  3661. ;;
  3662. *) # EBCDIC based system
  3663. lt_SP2NL='tr \100 \n'
  3664. lt_NL2SP='tr \r\n \100\100'
  3665. ;;
  3666. esac
  3667. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
  3668. $as_echo_n "checking how to convert $build file names to $host format... " >&6; }
  3669. if ${lt_cv_to_host_file_cmd+:} false; then :
  3670. $as_echo_n "(cached) " >&6
  3671. else
  3672. case $host in
  3673. *-*-mingw* )
  3674. case $build in
  3675. *-*-mingw* ) # actually msys
  3676. lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
  3677. ;;
  3678. *-*-cygwin* )
  3679. lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
  3680. ;;
  3681. * ) # otherwise, assume *nix
  3682. lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
  3683. ;;
  3684. esac
  3685. ;;
  3686. *-*-cygwin* )
  3687. case $build in
  3688. *-*-mingw* ) # actually msys
  3689. lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
  3690. ;;
  3691. *-*-cygwin* )
  3692. lt_cv_to_host_file_cmd=func_convert_file_noop
  3693. ;;
  3694. * ) # otherwise, assume *nix
  3695. lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
  3696. ;;
  3697. esac
  3698. ;;
  3699. * ) # unhandled hosts (and "normal" native builds)
  3700. lt_cv_to_host_file_cmd=func_convert_file_noop
  3701. ;;
  3702. esac
  3703. fi
  3704. to_host_file_cmd=$lt_cv_to_host_file_cmd
  3705. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
  3706. $as_echo "$lt_cv_to_host_file_cmd" >&6; }
  3707. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
  3708. $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
  3709. if ${lt_cv_to_tool_file_cmd+:} false; then :
  3710. $as_echo_n "(cached) " >&6
  3711. else
  3712. #assume ordinary cross tools, or native build.
  3713. lt_cv_to_tool_file_cmd=func_convert_file_noop
  3714. case $host in
  3715. *-*-mingw* )
  3716. case $build in
  3717. *-*-mingw* ) # actually msys
  3718. lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
  3719. ;;
  3720. esac
  3721. ;;
  3722. esac
  3723. fi
  3724. to_tool_file_cmd=$lt_cv_to_tool_file_cmd
  3725. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
  3726. $as_echo "$lt_cv_to_tool_file_cmd" >&6; }
  3727. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  3728. $as_echo_n "checking for $LD option to reload object files... " >&6; }
  3729. if ${lt_cv_ld_reload_flag+:} false; then :
  3730. $as_echo_n "(cached) " >&6
  3731. else
  3732. lt_cv_ld_reload_flag='-r'
  3733. fi
  3734. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
  3735. $as_echo "$lt_cv_ld_reload_flag" >&6; }
  3736. reload_flag=$lt_cv_ld_reload_flag
  3737. case $reload_flag in
  3738. "" | " "*) ;;
  3739. *) reload_flag=" $reload_flag" ;;
  3740. esac
  3741. reload_cmds='$LD$reload_flag -o $output$reload_objs'
  3742. case $host_os in
  3743. cygwin* | mingw* | pw32* | cegcc*)
  3744. if test "$GCC" != yes; then
  3745. reload_cmds=false
  3746. fi
  3747. ;;
  3748. darwin*)
  3749. if test "$GCC" = yes; then
  3750. reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
  3751. else
  3752. reload_cmds='$LD$reload_flag -o $output$reload_objs'
  3753. fi
  3754. ;;
  3755. esac
  3756. if test -n "$ac_tool_prefix"; then
  3757. # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
  3758. set dummy ${ac_tool_prefix}objdump; ac_word=$2
  3759. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  3760. $as_echo_n "checking for $ac_word... " >&6; }
  3761. if ${ac_cv_prog_OBJDUMP+:} false; then :
  3762. $as_echo_n "(cached) " >&6
  3763. else
  3764. if test -n "$OBJDUMP"; then
  3765. ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
  3766. else
  3767. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3768. for as_dir in $PATH
  3769. do
  3770. IFS=$as_save_IFS
  3771. test -z "$as_dir" && as_dir=.
  3772. for ac_exec_ext in '' $ac_executable_extensions; do
  3773. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  3774. ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
  3775. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  3776. break 2
  3777. fi
  3778. done
  3779. done
  3780. IFS=$as_save_IFS
  3781. fi
  3782. fi
  3783. OBJDUMP=$ac_cv_prog_OBJDUMP
  3784. if test -n "$OBJDUMP"; then
  3785. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
  3786. $as_echo "$OBJDUMP" >&6; }
  3787. else
  3788. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3789. $as_echo "no" >&6; }
  3790. fi
  3791. fi
  3792. if test -z "$ac_cv_prog_OBJDUMP"; then
  3793. ac_ct_OBJDUMP=$OBJDUMP
  3794. # Extract the first word of "objdump", so it can be a program name with args.
  3795. set dummy objdump; ac_word=$2
  3796. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  3797. $as_echo_n "checking for $ac_word... " >&6; }
  3798. if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
  3799. $as_echo_n "(cached) " >&6
  3800. else
  3801. if test -n "$ac_ct_OBJDUMP"; then
  3802. ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
  3803. else
  3804. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3805. for as_dir in $PATH
  3806. do
  3807. IFS=$as_save_IFS
  3808. test -z "$as_dir" && as_dir=.
  3809. for ac_exec_ext in '' $ac_executable_extensions; do
  3810. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  3811. ac_cv_prog_ac_ct_OBJDUMP="objdump"
  3812. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  3813. break 2
  3814. fi
  3815. done
  3816. done
  3817. IFS=$as_save_IFS
  3818. fi
  3819. fi
  3820. ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
  3821. if test -n "$ac_ct_OBJDUMP"; then
  3822. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
  3823. $as_echo "$ac_ct_OBJDUMP" >&6; }
  3824. else
  3825. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3826. $as_echo "no" >&6; }
  3827. fi
  3828. if test "x$ac_ct_OBJDUMP" = x; then
  3829. OBJDUMP="false"
  3830. else
  3831. case $cross_compiling:$ac_tool_warned in
  3832. yes:)
  3833. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  3834. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  3835. ac_tool_warned=yes ;;
  3836. esac
  3837. OBJDUMP=$ac_ct_OBJDUMP
  3838. fi
  3839. else
  3840. OBJDUMP="$ac_cv_prog_OBJDUMP"
  3841. fi
  3842. test -z "$OBJDUMP" && OBJDUMP=objdump
  3843. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
  3844. $as_echo_n "checking how to recognize dependent libraries... " >&6; }
  3845. if ${lt_cv_deplibs_check_method+:} false; then :
  3846. $as_echo_n "(cached) " >&6
  3847. else
  3848. lt_cv_file_magic_cmd='$MAGIC_CMD'
  3849. lt_cv_file_magic_test_file=
  3850. lt_cv_deplibs_check_method='unknown'
  3851. # Need to set the preceding variable on all platforms that support
  3852. # interlibrary dependencies.
  3853. # 'none' -- dependencies not supported.
  3854. # `unknown' -- same as none, but documents that we really don't know.
  3855. # 'pass_all' -- all dependencies passed with no checks.
  3856. # 'test_compile' -- check by making test program.
  3857. # 'file_magic [[regex]]' -- check by looking for files in library path
  3858. # which responds to the $file_magic_cmd with a given extended regex.
  3859. # If you have `file' or equivalent on your system and you're not sure
  3860. # whether `pass_all' will *always* work, you probably want this one.
  3861. case $host_os in
  3862. aix[4-9]*)
  3863. lt_cv_deplibs_check_method=pass_all
  3864. ;;
  3865. beos*)
  3866. lt_cv_deplibs_check_method=pass_all
  3867. ;;
  3868. bsdi[45]*)
  3869. lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
  3870. lt_cv_file_magic_cmd='/usr/bin/file -L'
  3871. lt_cv_file_magic_test_file=/shlib/libc.so
  3872. ;;
  3873. cygwin*)
  3874. # func_win32_libid is a shell function defined in ltmain.sh
  3875. lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
  3876. lt_cv_file_magic_cmd='func_win32_libid'
  3877. ;;
  3878. mingw* | pw32*)
  3879. # Base MSYS/MinGW do not provide the 'file' command needed by
  3880. # func_win32_libid shell function, so use a weaker test based on 'objdump',
  3881. # unless we find 'file', for example because we are cross-compiling.
  3882. # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
  3883. if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
  3884. lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
  3885. lt_cv_file_magic_cmd='func_win32_libid'
  3886. else
  3887. # Keep this pattern in sync with the one in func_win32_libid.
  3888. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
  3889. lt_cv_file_magic_cmd='$OBJDUMP -f'
  3890. fi
  3891. ;;
  3892. cegcc*)
  3893. # use the weaker test based on 'objdump'. See mingw*.
  3894. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
  3895. lt_cv_file_magic_cmd='$OBJDUMP -f'
  3896. ;;
  3897. darwin* | rhapsody*)
  3898. lt_cv_deplibs_check_method=pass_all
  3899. ;;
  3900. freebsd* | dragonfly*)
  3901. if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
  3902. case $host_cpu in
  3903. i*86 )
  3904. # Not sure whether the presence of OpenBSD here was a mistake.
  3905. # Let's accept both of them until this is cleared up.
  3906. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
  3907. lt_cv_file_magic_cmd=/usr/bin/file
  3908. lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
  3909. ;;
  3910. esac
  3911. else
  3912. lt_cv_deplibs_check_method=pass_all
  3913. fi
  3914. ;;
  3915. gnu*)
  3916. lt_cv_deplibs_check_method=pass_all
  3917. ;;
  3918. haiku*)
  3919. lt_cv_deplibs_check_method=pass_all
  3920. ;;
  3921. hpux10.20* | hpux11*)
  3922. lt_cv_file_magic_cmd=/usr/bin/file
  3923. case $host_cpu in
  3924. ia64*)
  3925. lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
  3926. lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
  3927. ;;
  3928. hppa*64*)
  3929. lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
  3930. lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
  3931. ;;
  3932. *)
  3933. lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
  3934. lt_cv_file_magic_test_file=/usr/lib/libc.sl
  3935. ;;
  3936. esac
  3937. ;;
  3938. interix[3-9]*)
  3939. # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
  3940. lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
  3941. ;;
  3942. irix5* | irix6* | nonstopux*)
  3943. case $LD in
  3944. *-32|*"-32 ") libmagic=32-bit;;
  3945. *-n32|*"-n32 ") libmagic=N32;;
  3946. *-64|*"-64 ") libmagic=64-bit;;
  3947. *) libmagic=never-match;;
  3948. esac
  3949. lt_cv_deplibs_check_method=pass_all
  3950. ;;
  3951. # This must be glibc/ELF.
  3952. linux* | k*bsd*-gnu | kopensolaris*-gnu)
  3953. lt_cv_deplibs_check_method=pass_all
  3954. ;;
  3955. netbsd* | netbsdelf*-gnu)
  3956. if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
  3957. lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
  3958. else
  3959. lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
  3960. fi
  3961. ;;
  3962. newos6*)
  3963. lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
  3964. lt_cv_file_magic_cmd=/usr/bin/file
  3965. lt_cv_file_magic_test_file=/usr/lib/libnls.so
  3966. ;;
  3967. *nto* | *qnx*)
  3968. lt_cv_deplibs_check_method=pass_all
  3969. ;;
  3970. openbsd*)
  3971. if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  3972. lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
  3973. else
  3974. lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
  3975. fi
  3976. ;;
  3977. osf3* | osf4* | osf5*)
  3978. lt_cv_deplibs_check_method=pass_all
  3979. ;;
  3980. rdos*)
  3981. lt_cv_deplibs_check_method=pass_all
  3982. ;;
  3983. solaris*)
  3984. lt_cv_deplibs_check_method=pass_all
  3985. ;;
  3986. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
  3987. lt_cv_deplibs_check_method=pass_all
  3988. ;;
  3989. sysv4 | sysv4.3*)
  3990. case $host_vendor in
  3991. motorola)
  3992. lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
  3993. lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
  3994. ;;
  3995. ncr)
  3996. lt_cv_deplibs_check_method=pass_all
  3997. ;;
  3998. sequent)
  3999. lt_cv_file_magic_cmd='/bin/file'
  4000. lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
  4001. ;;
  4002. sni)
  4003. lt_cv_file_magic_cmd='/bin/file'
  4004. lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
  4005. lt_cv_file_magic_test_file=/lib/libc.so
  4006. ;;
  4007. siemens)
  4008. lt_cv_deplibs_check_method=pass_all
  4009. ;;
  4010. pc)
  4011. lt_cv_deplibs_check_method=pass_all
  4012. ;;
  4013. esac
  4014. ;;
  4015. tpf*)
  4016. lt_cv_deplibs_check_method=pass_all
  4017. ;;
  4018. esac
  4019. fi
  4020. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  4021. $as_echo "$lt_cv_deplibs_check_method" >&6; }
  4022. file_magic_glob=
  4023. want_nocaseglob=no
  4024. if test "$build" = "$host"; then
  4025. case $host_os in
  4026. mingw* | pw32*)
  4027. if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
  4028. want_nocaseglob=yes
  4029. else
  4030. file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
  4031. fi
  4032. ;;
  4033. esac
  4034. fi
  4035. file_magic_cmd=$lt_cv_file_magic_cmd
  4036. deplibs_check_method=$lt_cv_deplibs_check_method
  4037. test -z "$deplibs_check_method" && deplibs_check_method=unknown
  4038. if test -n "$ac_tool_prefix"; then
  4039. # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
  4040. set dummy ${ac_tool_prefix}dlltool; ac_word=$2
  4041. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4042. $as_echo_n "checking for $ac_word... " >&6; }
  4043. if ${ac_cv_prog_DLLTOOL+:} false; then :
  4044. $as_echo_n "(cached) " >&6
  4045. else
  4046. if test -n "$DLLTOOL"; then
  4047. ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
  4048. else
  4049. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4050. for as_dir in $PATH
  4051. do
  4052. IFS=$as_save_IFS
  4053. test -z "$as_dir" && as_dir=.
  4054. for ac_exec_ext in '' $ac_executable_extensions; do
  4055. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4056. ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
  4057. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4058. break 2
  4059. fi
  4060. done
  4061. done
  4062. IFS=$as_save_IFS
  4063. fi
  4064. fi
  4065. DLLTOOL=$ac_cv_prog_DLLTOOL
  4066. if test -n "$DLLTOOL"; then
  4067. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
  4068. $as_echo "$DLLTOOL" >&6; }
  4069. else
  4070. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4071. $as_echo "no" >&6; }
  4072. fi
  4073. fi
  4074. if test -z "$ac_cv_prog_DLLTOOL"; then
  4075. ac_ct_DLLTOOL=$DLLTOOL
  4076. # Extract the first word of "dlltool", so it can be a program name with args.
  4077. set dummy dlltool; ac_word=$2
  4078. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4079. $as_echo_n "checking for $ac_word... " >&6; }
  4080. if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
  4081. $as_echo_n "(cached) " >&6
  4082. else
  4083. if test -n "$ac_ct_DLLTOOL"; then
  4084. ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
  4085. else
  4086. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4087. for as_dir in $PATH
  4088. do
  4089. IFS=$as_save_IFS
  4090. test -z "$as_dir" && as_dir=.
  4091. for ac_exec_ext in '' $ac_executable_extensions; do
  4092. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4093. ac_cv_prog_ac_ct_DLLTOOL="dlltool"
  4094. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4095. break 2
  4096. fi
  4097. done
  4098. done
  4099. IFS=$as_save_IFS
  4100. fi
  4101. fi
  4102. ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
  4103. if test -n "$ac_ct_DLLTOOL"; then
  4104. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
  4105. $as_echo "$ac_ct_DLLTOOL" >&6; }
  4106. else
  4107. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4108. $as_echo "no" >&6; }
  4109. fi
  4110. if test "x$ac_ct_DLLTOOL" = x; then
  4111. DLLTOOL="false"
  4112. else
  4113. case $cross_compiling:$ac_tool_warned in
  4114. yes:)
  4115. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4116. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4117. ac_tool_warned=yes ;;
  4118. esac
  4119. DLLTOOL=$ac_ct_DLLTOOL
  4120. fi
  4121. else
  4122. DLLTOOL="$ac_cv_prog_DLLTOOL"
  4123. fi
  4124. test -z "$DLLTOOL" && DLLTOOL=dlltool
  4125. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
  4126. $as_echo_n "checking how to associate runtime and link libraries... " >&6; }
  4127. if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
  4128. $as_echo_n "(cached) " >&6
  4129. else
  4130. lt_cv_sharedlib_from_linklib_cmd='unknown'
  4131. case $host_os in
  4132. cygwin* | mingw* | pw32* | cegcc*)
  4133. # two different shell functions defined in ltmain.sh
  4134. # decide which to use based on capabilities of $DLLTOOL
  4135. case `$DLLTOOL --help 2>&1` in
  4136. *--identify-strict*)
  4137. lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
  4138. ;;
  4139. *)
  4140. lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
  4141. ;;
  4142. esac
  4143. ;;
  4144. *)
  4145. # fallback: assume linklib IS sharedlib
  4146. lt_cv_sharedlib_from_linklib_cmd="$ECHO"
  4147. ;;
  4148. esac
  4149. fi
  4150. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
  4151. $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
  4152. sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
  4153. test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
  4154. if test -n "$ac_tool_prefix"; then
  4155. for ac_prog in ar
  4156. do
  4157. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  4158. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  4159. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4160. $as_echo_n "checking for $ac_word... " >&6; }
  4161. if ${ac_cv_prog_AR+:} false; then :
  4162. $as_echo_n "(cached) " >&6
  4163. else
  4164. if test -n "$AR"; then
  4165. ac_cv_prog_AR="$AR" # Let the user override the test.
  4166. else
  4167. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4168. for as_dir in $PATH
  4169. do
  4170. IFS=$as_save_IFS
  4171. test -z "$as_dir" && as_dir=.
  4172. for ac_exec_ext in '' $ac_executable_extensions; do
  4173. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4174. ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
  4175. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4176. break 2
  4177. fi
  4178. done
  4179. done
  4180. IFS=$as_save_IFS
  4181. fi
  4182. fi
  4183. AR=$ac_cv_prog_AR
  4184. if test -n "$AR"; then
  4185. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
  4186. $as_echo "$AR" >&6; }
  4187. else
  4188. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4189. $as_echo "no" >&6; }
  4190. fi
  4191. test -n "$AR" && break
  4192. done
  4193. fi
  4194. if test -z "$AR"; then
  4195. ac_ct_AR=$AR
  4196. for ac_prog in ar
  4197. do
  4198. # Extract the first word of "$ac_prog", so it can be a program name with args.
  4199. set dummy $ac_prog; ac_word=$2
  4200. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4201. $as_echo_n "checking for $ac_word... " >&6; }
  4202. if ${ac_cv_prog_ac_ct_AR+:} false; then :
  4203. $as_echo_n "(cached) " >&6
  4204. else
  4205. if test -n "$ac_ct_AR"; then
  4206. ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
  4207. else
  4208. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4209. for as_dir in $PATH
  4210. do
  4211. IFS=$as_save_IFS
  4212. test -z "$as_dir" && as_dir=.
  4213. for ac_exec_ext in '' $ac_executable_extensions; do
  4214. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4215. ac_cv_prog_ac_ct_AR="$ac_prog"
  4216. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4217. break 2
  4218. fi
  4219. done
  4220. done
  4221. IFS=$as_save_IFS
  4222. fi
  4223. fi
  4224. ac_ct_AR=$ac_cv_prog_ac_ct_AR
  4225. if test -n "$ac_ct_AR"; then
  4226. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
  4227. $as_echo "$ac_ct_AR" >&6; }
  4228. else
  4229. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4230. $as_echo "no" >&6; }
  4231. fi
  4232. test -n "$ac_ct_AR" && break
  4233. done
  4234. if test "x$ac_ct_AR" = x; then
  4235. AR="false"
  4236. else
  4237. case $cross_compiling:$ac_tool_warned in
  4238. yes:)
  4239. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4240. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4241. ac_tool_warned=yes ;;
  4242. esac
  4243. AR=$ac_ct_AR
  4244. fi
  4245. fi
  4246. : ${AR=ar}
  4247. : ${AR_FLAGS=cru}
  4248. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
  4249. $as_echo_n "checking for archiver @FILE support... " >&6; }
  4250. if ${lt_cv_ar_at_file+:} false; then :
  4251. $as_echo_n "(cached) " >&6
  4252. else
  4253. lt_cv_ar_at_file=no
  4254. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4255. /* end confdefs.h. */
  4256. int
  4257. main ()
  4258. {
  4259. ;
  4260. return 0;
  4261. }
  4262. _ACEOF
  4263. if ac_fn_c_try_compile "$LINENO"; then :
  4264. echo conftest.$ac_objext > conftest.lst
  4265. lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
  4266. { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
  4267. (eval $lt_ar_try) 2>&5
  4268. ac_status=$?
  4269. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4270. test $ac_status = 0; }
  4271. if test "$ac_status" -eq 0; then
  4272. # Ensure the archiver fails upon bogus file names.
  4273. rm -f conftest.$ac_objext libconftest.a
  4274. { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
  4275. (eval $lt_ar_try) 2>&5
  4276. ac_status=$?
  4277. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4278. test $ac_status = 0; }
  4279. if test "$ac_status" -ne 0; then
  4280. lt_cv_ar_at_file=@
  4281. fi
  4282. fi
  4283. rm -f conftest.* libconftest.a
  4284. fi
  4285. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  4286. fi
  4287. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
  4288. $as_echo "$lt_cv_ar_at_file" >&6; }
  4289. if test "x$lt_cv_ar_at_file" = xno; then
  4290. archiver_list_spec=
  4291. else
  4292. archiver_list_spec=$lt_cv_ar_at_file
  4293. fi
  4294. if test -n "$ac_tool_prefix"; then
  4295. # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
  4296. set dummy ${ac_tool_prefix}strip; ac_word=$2
  4297. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4298. $as_echo_n "checking for $ac_word... " >&6; }
  4299. if ${ac_cv_prog_STRIP+:} false; then :
  4300. $as_echo_n "(cached) " >&6
  4301. else
  4302. if test -n "$STRIP"; then
  4303. ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
  4304. else
  4305. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4306. for as_dir in $PATH
  4307. do
  4308. IFS=$as_save_IFS
  4309. test -z "$as_dir" && as_dir=.
  4310. for ac_exec_ext in '' $ac_executable_extensions; do
  4311. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4312. ac_cv_prog_STRIP="${ac_tool_prefix}strip"
  4313. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4314. break 2
  4315. fi
  4316. done
  4317. done
  4318. IFS=$as_save_IFS
  4319. fi
  4320. fi
  4321. STRIP=$ac_cv_prog_STRIP
  4322. if test -n "$STRIP"; then
  4323. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
  4324. $as_echo "$STRIP" >&6; }
  4325. else
  4326. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4327. $as_echo "no" >&6; }
  4328. fi
  4329. fi
  4330. if test -z "$ac_cv_prog_STRIP"; then
  4331. ac_ct_STRIP=$STRIP
  4332. # Extract the first word of "strip", so it can be a program name with args.
  4333. set dummy strip; ac_word=$2
  4334. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4335. $as_echo_n "checking for $ac_word... " >&6; }
  4336. if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
  4337. $as_echo_n "(cached) " >&6
  4338. else
  4339. if test -n "$ac_ct_STRIP"; then
  4340. ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
  4341. else
  4342. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4343. for as_dir in $PATH
  4344. do
  4345. IFS=$as_save_IFS
  4346. test -z "$as_dir" && as_dir=.
  4347. for ac_exec_ext in '' $ac_executable_extensions; do
  4348. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4349. ac_cv_prog_ac_ct_STRIP="strip"
  4350. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4351. break 2
  4352. fi
  4353. done
  4354. done
  4355. IFS=$as_save_IFS
  4356. fi
  4357. fi
  4358. ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
  4359. if test -n "$ac_ct_STRIP"; then
  4360. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
  4361. $as_echo "$ac_ct_STRIP" >&6; }
  4362. else
  4363. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4364. $as_echo "no" >&6; }
  4365. fi
  4366. if test "x$ac_ct_STRIP" = x; then
  4367. STRIP=":"
  4368. else
  4369. case $cross_compiling:$ac_tool_warned in
  4370. yes:)
  4371. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4372. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4373. ac_tool_warned=yes ;;
  4374. esac
  4375. STRIP=$ac_ct_STRIP
  4376. fi
  4377. else
  4378. STRIP="$ac_cv_prog_STRIP"
  4379. fi
  4380. test -z "$STRIP" && STRIP=:
  4381. if test -n "$ac_tool_prefix"; then
  4382. # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
  4383. set dummy ${ac_tool_prefix}ranlib; ac_word=$2
  4384. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4385. $as_echo_n "checking for $ac_word... " >&6; }
  4386. if ${ac_cv_prog_RANLIB+:} false; then :
  4387. $as_echo_n "(cached) " >&6
  4388. else
  4389. if test -n "$RANLIB"; then
  4390. ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  4391. else
  4392. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4393. for as_dir in $PATH
  4394. do
  4395. IFS=$as_save_IFS
  4396. test -z "$as_dir" && as_dir=.
  4397. for ac_exec_ext in '' $ac_executable_extensions; do
  4398. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4399. ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
  4400. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4401. break 2
  4402. fi
  4403. done
  4404. done
  4405. IFS=$as_save_IFS
  4406. fi
  4407. fi
  4408. RANLIB=$ac_cv_prog_RANLIB
  4409. if test -n "$RANLIB"; then
  4410. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
  4411. $as_echo "$RANLIB" >&6; }
  4412. else
  4413. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4414. $as_echo "no" >&6; }
  4415. fi
  4416. fi
  4417. if test -z "$ac_cv_prog_RANLIB"; then
  4418. ac_ct_RANLIB=$RANLIB
  4419. # Extract the first word of "ranlib", so it can be a program name with args.
  4420. set dummy ranlib; ac_word=$2
  4421. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4422. $as_echo_n "checking for $ac_word... " >&6; }
  4423. if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
  4424. $as_echo_n "(cached) " >&6
  4425. else
  4426. if test -n "$ac_ct_RANLIB"; then
  4427. ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
  4428. else
  4429. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4430. for as_dir in $PATH
  4431. do
  4432. IFS=$as_save_IFS
  4433. test -z "$as_dir" && as_dir=.
  4434. for ac_exec_ext in '' $ac_executable_extensions; do
  4435. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4436. ac_cv_prog_ac_ct_RANLIB="ranlib"
  4437. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4438. break 2
  4439. fi
  4440. done
  4441. done
  4442. IFS=$as_save_IFS
  4443. fi
  4444. fi
  4445. ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
  4446. if test -n "$ac_ct_RANLIB"; then
  4447. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
  4448. $as_echo "$ac_ct_RANLIB" >&6; }
  4449. else
  4450. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4451. $as_echo "no" >&6; }
  4452. fi
  4453. if test "x$ac_ct_RANLIB" = x; then
  4454. RANLIB=":"
  4455. else
  4456. case $cross_compiling:$ac_tool_warned in
  4457. yes:)
  4458. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4459. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4460. ac_tool_warned=yes ;;
  4461. esac
  4462. RANLIB=$ac_ct_RANLIB
  4463. fi
  4464. else
  4465. RANLIB="$ac_cv_prog_RANLIB"
  4466. fi
  4467. test -z "$RANLIB" && RANLIB=:
  4468. # Determine commands to create old-style static archives.
  4469. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
  4470. old_postinstall_cmds='chmod 644 $oldlib'
  4471. old_postuninstall_cmds=
  4472. if test -n "$RANLIB"; then
  4473. case $host_os in
  4474. openbsd*)
  4475. old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
  4476. ;;
  4477. *)
  4478. old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
  4479. ;;
  4480. esac
  4481. old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
  4482. fi
  4483. case $host_os in
  4484. darwin*)
  4485. lock_old_archive_extraction=yes ;;
  4486. *)
  4487. lock_old_archive_extraction=no ;;
  4488. esac
  4489. for ac_prog in gawk mawk nawk awk
  4490. do
  4491. # Extract the first word of "$ac_prog", so it can be a program name with args.
  4492. set dummy $ac_prog; ac_word=$2
  4493. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4494. $as_echo_n "checking for $ac_word... " >&6; }
  4495. if ${ac_cv_prog_AWK+:} false; then :
  4496. $as_echo_n "(cached) " >&6
  4497. else
  4498. if test -n "$AWK"; then
  4499. ac_cv_prog_AWK="$AWK" # Let the user override the test.
  4500. else
  4501. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4502. for as_dir in $PATH
  4503. do
  4504. IFS=$as_save_IFS
  4505. test -z "$as_dir" && as_dir=.
  4506. for ac_exec_ext in '' $ac_executable_extensions; do
  4507. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4508. ac_cv_prog_AWK="$ac_prog"
  4509. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4510. break 2
  4511. fi
  4512. done
  4513. done
  4514. IFS=$as_save_IFS
  4515. fi
  4516. fi
  4517. AWK=$ac_cv_prog_AWK
  4518. if test -n "$AWK"; then
  4519. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
  4520. $as_echo "$AWK" >&6; }
  4521. else
  4522. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4523. $as_echo "no" >&6; }
  4524. fi
  4525. test -n "$AWK" && break
  4526. done
  4527. # If no C compiler was specified, use CC.
  4528. LTCC=${LTCC-"$CC"}
  4529. # If no C compiler flags were specified, use CFLAGS.
  4530. LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
  4531. # Allow CC to be a program name with arguments.
  4532. compiler=$CC
  4533. # Check for command to grab the raw symbol name followed by C symbol from nm.
  4534. { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
  4535. $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
  4536. if ${lt_cv_sys_global_symbol_pipe+:} false; then :
  4537. $as_echo_n "(cached) " >&6
  4538. else
  4539. # These are sane defaults that work on at least a few old systems.
  4540. # [They come from Ultrix. What could be older than Ultrix?!! ;)]
  4541. # Character class describing NM global symbol codes.
  4542. symcode='[BCDEGRST]'
  4543. # Regexp to match symbols that can be accessed directly from C.
  4544. sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
  4545. # Define system-specific variables.
  4546. case $host_os in
  4547. aix*)
  4548. symcode='[BCDT]'
  4549. ;;
  4550. cygwin* | mingw* | pw32* | cegcc*)
  4551. symcode='[ABCDGISTW]'
  4552. ;;
  4553. hpux*)
  4554. if test "$host_cpu" = ia64; then
  4555. symcode='[ABCDEGRST]'
  4556. fi
  4557. ;;
  4558. irix* | nonstopux*)
  4559. symcode='[BCDEGRST]'
  4560. ;;
  4561. osf*)
  4562. symcode='[BCDEGQRST]'
  4563. ;;
  4564. solaris*)
  4565. symcode='[BDRT]'
  4566. ;;
  4567. sco3.2v5*)
  4568. symcode='[DT]'
  4569. ;;
  4570. sysv4.2uw2*)
  4571. symcode='[DT]'
  4572. ;;
  4573. sysv5* | sco5v6* | unixware* | OpenUNIX*)
  4574. symcode='[ABDT]'
  4575. ;;
  4576. sysv4)
  4577. symcode='[DFNSTU]'
  4578. ;;
  4579. esac
  4580. # If we're using GNU nm, then use its standard symbol codes.
  4581. case `$NM -V 2>&1` in
  4582. *GNU* | *'with BFD'*)
  4583. symcode='[ABCDGIRSTW]' ;;
  4584. esac
  4585. # Transform an extracted symbol line into a proper C declaration.
  4586. # Some systems (esp. on ia64) link data and code symbols differently,
  4587. # so use this general approach.
  4588. lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  4589. # Transform an extracted symbol line into symbol name and symbol address
  4590. lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
  4591. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
  4592. # Handle CRLF in mingw tool chain
  4593. opt_cr=
  4594. case $build_os in
  4595. mingw*)
  4596. opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
  4597. ;;
  4598. esac
  4599. # Try without a prefix underscore, then with it.
  4600. for ac_symprfx in "" "_"; do
  4601. # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
  4602. symxfrm="\\1 $ac_symprfx\\2 \\2"
  4603. # Write the raw and C identifiers.
  4604. if test "$lt_cv_nm_interface" = "MS dumpbin"; then
  4605. # Fake it for dumpbin and say T for any non-static function
  4606. # and D for any global variable.
  4607. # Also find C++ and __fastcall symbols from MSVC++,
  4608. # which start with @ or ?.
  4609. lt_cv_sys_global_symbol_pipe="$AWK '"\
  4610. " {last_section=section; section=\$ 3};"\
  4611. " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
  4612. " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
  4613. " \$ 0!~/External *\|/{next};"\
  4614. " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
  4615. " {if(hide[section]) next};"\
  4616. " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
  4617. " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
  4618. " s[1]~/^[@?]/{print s[1], s[1]; next};"\
  4619. " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
  4620. " ' prfx=^$ac_symprfx"
  4621. else
  4622. lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
  4623. fi
  4624. lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
  4625. # Check to see that the pipe works correctly.
  4626. pipe_works=no
  4627. rm -f conftest*
  4628. cat > conftest.$ac_ext <<_LT_EOF
  4629. #ifdef __cplusplus
  4630. extern "C" {
  4631. #endif
  4632. char nm_test_var;
  4633. void nm_test_func(void);
  4634. void nm_test_func(void){}
  4635. #ifdef __cplusplus
  4636. }
  4637. #endif
  4638. int main(){nm_test_var='a';nm_test_func();return(0);}
  4639. _LT_EOF
  4640. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
  4641. (eval $ac_compile) 2>&5
  4642. ac_status=$?
  4643. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4644. test $ac_status = 0; }; then
  4645. # Now try to grab the symbols.
  4646. nlist=conftest.nm
  4647. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
  4648. (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
  4649. ac_status=$?
  4650. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4651. test $ac_status = 0; } && test -s "$nlist"; then
  4652. # Try sorting and uniquifying the output.
  4653. if sort "$nlist" | uniq > "$nlist"T; then
  4654. mv -f "$nlist"T "$nlist"
  4655. else
  4656. rm -f "$nlist"T
  4657. fi
  4658. # Make sure that we snagged all the symbols we need.
  4659. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  4660. if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  4661. cat <<_LT_EOF > conftest.$ac_ext
  4662. /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
  4663. #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
  4664. /* DATA imports from DLLs on WIN32 con't be const, because runtime
  4665. relocations are performed -- see ld's documentation on pseudo-relocs. */
  4666. # define LT_DLSYM_CONST
  4667. #elif defined(__osf__)
  4668. /* This system does not cope well with relocations in const data. */
  4669. # define LT_DLSYM_CONST
  4670. #else
  4671. # define LT_DLSYM_CONST const
  4672. #endif
  4673. #ifdef __cplusplus
  4674. extern "C" {
  4675. #endif
  4676. _LT_EOF
  4677. # Now generate the symbol file.
  4678. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
  4679. cat <<_LT_EOF >> conftest.$ac_ext
  4680. /* The mapping between symbol names and symbols. */
  4681. LT_DLSYM_CONST struct {
  4682. const char *name;
  4683. void *address;
  4684. }
  4685. lt__PROGRAM__LTX_preloaded_symbols[] =
  4686. {
  4687. { "@PROGRAM@", (void *) 0 },
  4688. _LT_EOF
  4689. $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
  4690. cat <<\_LT_EOF >> conftest.$ac_ext
  4691. {0, (void *) 0}
  4692. };
  4693. /* This works around a problem in FreeBSD linker */
  4694. #ifdef FREEBSD_WORKAROUND
  4695. static const void *lt_preloaded_setup() {
  4696. return lt__PROGRAM__LTX_preloaded_symbols;
  4697. }
  4698. #endif
  4699. #ifdef __cplusplus
  4700. }
  4701. #endif
  4702. _LT_EOF
  4703. # Now try linking the two files.
  4704. mv conftest.$ac_objext conftstm.$ac_objext
  4705. lt_globsym_save_LIBS=$LIBS
  4706. lt_globsym_save_CFLAGS=$CFLAGS
  4707. LIBS="conftstm.$ac_objext"
  4708. CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  4709. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
  4710. (eval $ac_link) 2>&5
  4711. ac_status=$?
  4712. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4713. test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  4714. pipe_works=yes
  4715. fi
  4716. LIBS=$lt_globsym_save_LIBS
  4717. CFLAGS=$lt_globsym_save_CFLAGS
  4718. else
  4719. echo "cannot find nm_test_func in $nlist" >&5
  4720. fi
  4721. else
  4722. echo "cannot find nm_test_var in $nlist" >&5
  4723. fi
  4724. else
  4725. echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
  4726. fi
  4727. else
  4728. echo "$progname: failed program was:" >&5
  4729. cat conftest.$ac_ext >&5
  4730. fi
  4731. rm -rf conftest* conftst*
  4732. # Do not use the global_symbol_pipe unless it works.
  4733. if test "$pipe_works" = yes; then
  4734. break
  4735. else
  4736. lt_cv_sys_global_symbol_pipe=
  4737. fi
  4738. done
  4739. fi
  4740. if test -z "$lt_cv_sys_global_symbol_pipe"; then
  4741. lt_cv_sys_global_symbol_to_cdecl=
  4742. fi
  4743. if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
  4744. { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
  4745. $as_echo "failed" >&6; }
  4746. else
  4747. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
  4748. $as_echo "ok" >&6; }
  4749. fi
  4750. # Response file support.
  4751. if test "$lt_cv_nm_interface" = "MS dumpbin"; then
  4752. nm_file_list_spec='@'
  4753. elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
  4754. nm_file_list_spec='@'
  4755. fi
  4756. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
  4757. $as_echo_n "checking for sysroot... " >&6; }
  4758. # Check whether --with-sysroot was given.
  4759. if test "${with_sysroot+set}" = set; then :
  4760. withval=$with_sysroot;
  4761. else
  4762. with_sysroot=no
  4763. fi
  4764. lt_sysroot=
  4765. case ${with_sysroot} in #(
  4766. yes)
  4767. if test "$GCC" = yes; then
  4768. lt_sysroot=`$CC --print-sysroot 2>/dev/null`
  4769. fi
  4770. ;; #(
  4771. /*)
  4772. lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
  4773. ;; #(
  4774. no|'')
  4775. ;; #(
  4776. *)
  4777. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5
  4778. $as_echo "${with_sysroot}" >&6; }
  4779. as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
  4780. ;;
  4781. esac
  4782. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
  4783. $as_echo "${lt_sysroot:-no}" >&6; }
  4784. # Check whether --enable-libtool-lock was given.
  4785. if test "${enable_libtool_lock+set}" = set; then :
  4786. enableval=$enable_libtool_lock;
  4787. fi
  4788. test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
  4789. # Some flags need to be propagated to the compiler or linker for good
  4790. # libtool support.
  4791. case $host in
  4792. ia64-*-hpux*)
  4793. # Find out which ABI we are using.
  4794. echo 'int i;' > conftest.$ac_ext
  4795. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
  4796. (eval $ac_compile) 2>&5
  4797. ac_status=$?
  4798. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4799. test $ac_status = 0; }; then
  4800. case `/usr/bin/file conftest.$ac_objext` in
  4801. *ELF-32*)
  4802. HPUX_IA64_MODE="32"
  4803. ;;
  4804. *ELF-64*)
  4805. HPUX_IA64_MODE="64"
  4806. ;;
  4807. esac
  4808. fi
  4809. rm -rf conftest*
  4810. ;;
  4811. *-*-irix6*)
  4812. # Find out which ABI we are using.
  4813. echo '#line '$LINENO' "configure"' > conftest.$ac_ext
  4814. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
  4815. (eval $ac_compile) 2>&5
  4816. ac_status=$?
  4817. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4818. test $ac_status = 0; }; then
  4819. if test "$lt_cv_prog_gnu_ld" = yes; then
  4820. case `/usr/bin/file conftest.$ac_objext` in
  4821. *32-bit*)
  4822. LD="${LD-ld} -melf32bsmip"
  4823. ;;
  4824. *N32*)
  4825. LD="${LD-ld} -melf32bmipn32"
  4826. ;;
  4827. *64-bit*)
  4828. LD="${LD-ld} -melf64bmip"
  4829. ;;
  4830. esac
  4831. else
  4832. case `/usr/bin/file conftest.$ac_objext` in
  4833. *32-bit*)
  4834. LD="${LD-ld} -32"
  4835. ;;
  4836. *N32*)
  4837. LD="${LD-ld} -n32"
  4838. ;;
  4839. *64-bit*)
  4840. LD="${LD-ld} -64"
  4841. ;;
  4842. esac
  4843. fi
  4844. fi
  4845. rm -rf conftest*
  4846. ;;
  4847. x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
  4848. s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
  4849. # Find out which ABI we are using.
  4850. echo 'int i;' > conftest.$ac_ext
  4851. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
  4852. (eval $ac_compile) 2>&5
  4853. ac_status=$?
  4854. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4855. test $ac_status = 0; }; then
  4856. case `/usr/bin/file conftest.o` in
  4857. *32-bit*)
  4858. case $host in
  4859. x86_64-*kfreebsd*-gnu)
  4860. LD="${LD-ld} -m elf_i386_fbsd"
  4861. ;;
  4862. x86_64-*linux*)
  4863. LD="${LD-ld} -m elf_i386"
  4864. ;;
  4865. ppc64-*linux*|powerpc64-*linux*)
  4866. LD="${LD-ld} -m elf32ppclinux"
  4867. ;;
  4868. s390x-*linux*)
  4869. LD="${LD-ld} -m elf_s390"
  4870. ;;
  4871. sparc64-*linux*)
  4872. LD="${LD-ld} -m elf32_sparc"
  4873. ;;
  4874. esac
  4875. ;;
  4876. *64-bit*)
  4877. case $host in
  4878. x86_64-*kfreebsd*-gnu)
  4879. LD="${LD-ld} -m elf_x86_64_fbsd"
  4880. ;;
  4881. x86_64-*linux*)
  4882. LD="${LD-ld} -m elf_x86_64"
  4883. ;;
  4884. ppc*-*linux*|powerpc*-*linux*)
  4885. LD="${LD-ld} -m elf64ppc"
  4886. ;;
  4887. s390*-*linux*|s390*-*tpf*)
  4888. LD="${LD-ld} -m elf64_s390"
  4889. ;;
  4890. sparc*-*linux*)
  4891. LD="${LD-ld} -m elf64_sparc"
  4892. ;;
  4893. esac
  4894. ;;
  4895. esac
  4896. fi
  4897. rm -rf conftest*
  4898. ;;
  4899. *-*-sco3.2v5*)
  4900. # On SCO OpenServer 5, we need -belf to get full-featured binaries.
  4901. SAVE_CFLAGS="$CFLAGS"
  4902. CFLAGS="$CFLAGS -belf"
  4903. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
  4904. $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
  4905. if ${lt_cv_cc_needs_belf+:} false; then :
  4906. $as_echo_n "(cached) " >&6
  4907. else
  4908. ac_ext=c
  4909. ac_cpp='$CPP $CPPFLAGS'
  4910. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  4911. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  4912. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  4913. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4914. /* end confdefs.h. */
  4915. int
  4916. main ()
  4917. {
  4918. ;
  4919. return 0;
  4920. }
  4921. _ACEOF
  4922. if ac_fn_c_try_link "$LINENO"; then :
  4923. lt_cv_cc_needs_belf=yes
  4924. else
  4925. lt_cv_cc_needs_belf=no
  4926. fi
  4927. rm -f core conftest.err conftest.$ac_objext \
  4928. conftest$ac_exeext conftest.$ac_ext
  4929. ac_ext=c
  4930. ac_cpp='$CPP $CPPFLAGS'
  4931. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  4932. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  4933. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  4934. fi
  4935. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
  4936. $as_echo "$lt_cv_cc_needs_belf" >&6; }
  4937. if test x"$lt_cv_cc_needs_belf" != x"yes"; then
  4938. # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
  4939. CFLAGS="$SAVE_CFLAGS"
  4940. fi
  4941. ;;
  4942. *-*solaris*)
  4943. # Find out which ABI we are using.
  4944. echo 'int i;' > conftest.$ac_ext
  4945. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
  4946. (eval $ac_compile) 2>&5
  4947. ac_status=$?
  4948. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  4949. test $ac_status = 0; }; then
  4950. case `/usr/bin/file conftest.o` in
  4951. *64-bit*)
  4952. case $lt_cv_prog_gnu_ld in
  4953. yes*)
  4954. case $host in
  4955. i?86-*-solaris*)
  4956. LD="${LD-ld} -m elf_x86_64"
  4957. ;;
  4958. sparc*-*-solaris*)
  4959. LD="${LD-ld} -m elf64_sparc"
  4960. ;;
  4961. esac
  4962. # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
  4963. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
  4964. LD="${LD-ld}_sol2"
  4965. fi
  4966. ;;
  4967. *)
  4968. if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
  4969. LD="${LD-ld} -64"
  4970. fi
  4971. ;;
  4972. esac
  4973. ;;
  4974. esac
  4975. fi
  4976. rm -rf conftest*
  4977. ;;
  4978. esac
  4979. need_locks="$enable_libtool_lock"
  4980. if test -n "$ac_tool_prefix"; then
  4981. # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
  4982. set dummy ${ac_tool_prefix}mt; ac_word=$2
  4983. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4984. $as_echo_n "checking for $ac_word... " >&6; }
  4985. if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
  4986. $as_echo_n "(cached) " >&6
  4987. else
  4988. if test -n "$MANIFEST_TOOL"; then
  4989. ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
  4990. else
  4991. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4992. for as_dir in $PATH
  4993. do
  4994. IFS=$as_save_IFS
  4995. test -z "$as_dir" && as_dir=.
  4996. for ac_exec_ext in '' $ac_executable_extensions; do
  4997. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4998. ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
  4999. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5000. break 2
  5001. fi
  5002. done
  5003. done
  5004. IFS=$as_save_IFS
  5005. fi
  5006. fi
  5007. MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
  5008. if test -n "$MANIFEST_TOOL"; then
  5009. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
  5010. $as_echo "$MANIFEST_TOOL" >&6; }
  5011. else
  5012. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5013. $as_echo "no" >&6; }
  5014. fi
  5015. fi
  5016. if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
  5017. ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
  5018. # Extract the first word of "mt", so it can be a program name with args.
  5019. set dummy mt; ac_word=$2
  5020. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5021. $as_echo_n "checking for $ac_word... " >&6; }
  5022. if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
  5023. $as_echo_n "(cached) " >&6
  5024. else
  5025. if test -n "$ac_ct_MANIFEST_TOOL"; then
  5026. ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
  5027. else
  5028. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5029. for as_dir in $PATH
  5030. do
  5031. IFS=$as_save_IFS
  5032. test -z "$as_dir" && as_dir=.
  5033. for ac_exec_ext in '' $ac_executable_extensions; do
  5034. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5035. ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
  5036. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5037. break 2
  5038. fi
  5039. done
  5040. done
  5041. IFS=$as_save_IFS
  5042. fi
  5043. fi
  5044. ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
  5045. if test -n "$ac_ct_MANIFEST_TOOL"; then
  5046. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
  5047. $as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
  5048. else
  5049. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5050. $as_echo "no" >&6; }
  5051. fi
  5052. if test "x$ac_ct_MANIFEST_TOOL" = x; then
  5053. MANIFEST_TOOL=":"
  5054. else
  5055. case $cross_compiling:$ac_tool_warned in
  5056. yes:)
  5057. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5058. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5059. ac_tool_warned=yes ;;
  5060. esac
  5061. MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
  5062. fi
  5063. else
  5064. MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
  5065. fi
  5066. test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
  5067. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
  5068. $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
  5069. if ${lt_cv_path_mainfest_tool+:} false; then :
  5070. $as_echo_n "(cached) " >&6
  5071. else
  5072. lt_cv_path_mainfest_tool=no
  5073. echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
  5074. $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
  5075. cat conftest.err >&5
  5076. if $GREP 'Manifest Tool' conftest.out > /dev/null; then
  5077. lt_cv_path_mainfest_tool=yes
  5078. fi
  5079. rm -f conftest*
  5080. fi
  5081. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
  5082. $as_echo "$lt_cv_path_mainfest_tool" >&6; }
  5083. if test "x$lt_cv_path_mainfest_tool" != xyes; then
  5084. MANIFEST_TOOL=:
  5085. fi
  5086. case $host_os in
  5087. rhapsody* | darwin*)
  5088. if test -n "$ac_tool_prefix"; then
  5089. # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
  5090. set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
  5091. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5092. $as_echo_n "checking for $ac_word... " >&6; }
  5093. if ${ac_cv_prog_DSYMUTIL+:} false; then :
  5094. $as_echo_n "(cached) " >&6
  5095. else
  5096. if test -n "$DSYMUTIL"; then
  5097. ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
  5098. else
  5099. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5100. for as_dir in $PATH
  5101. do
  5102. IFS=$as_save_IFS
  5103. test -z "$as_dir" && as_dir=.
  5104. for ac_exec_ext in '' $ac_executable_extensions; do
  5105. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5106. ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
  5107. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5108. break 2
  5109. fi
  5110. done
  5111. done
  5112. IFS=$as_save_IFS
  5113. fi
  5114. fi
  5115. DSYMUTIL=$ac_cv_prog_DSYMUTIL
  5116. if test -n "$DSYMUTIL"; then
  5117. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
  5118. $as_echo "$DSYMUTIL" >&6; }
  5119. else
  5120. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5121. $as_echo "no" >&6; }
  5122. fi
  5123. fi
  5124. if test -z "$ac_cv_prog_DSYMUTIL"; then
  5125. ac_ct_DSYMUTIL=$DSYMUTIL
  5126. # Extract the first word of "dsymutil", so it can be a program name with args.
  5127. set dummy dsymutil; ac_word=$2
  5128. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5129. $as_echo_n "checking for $ac_word... " >&6; }
  5130. if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
  5131. $as_echo_n "(cached) " >&6
  5132. else
  5133. if test -n "$ac_ct_DSYMUTIL"; then
  5134. ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
  5135. else
  5136. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5137. for as_dir in $PATH
  5138. do
  5139. IFS=$as_save_IFS
  5140. test -z "$as_dir" && as_dir=.
  5141. for ac_exec_ext in '' $ac_executable_extensions; do
  5142. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5143. ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
  5144. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5145. break 2
  5146. fi
  5147. done
  5148. done
  5149. IFS=$as_save_IFS
  5150. fi
  5151. fi
  5152. ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
  5153. if test -n "$ac_ct_DSYMUTIL"; then
  5154. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
  5155. $as_echo "$ac_ct_DSYMUTIL" >&6; }
  5156. else
  5157. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5158. $as_echo "no" >&6; }
  5159. fi
  5160. if test "x$ac_ct_DSYMUTIL" = x; then
  5161. DSYMUTIL=":"
  5162. else
  5163. case $cross_compiling:$ac_tool_warned in
  5164. yes:)
  5165. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5166. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5167. ac_tool_warned=yes ;;
  5168. esac
  5169. DSYMUTIL=$ac_ct_DSYMUTIL
  5170. fi
  5171. else
  5172. DSYMUTIL="$ac_cv_prog_DSYMUTIL"
  5173. fi
  5174. if test -n "$ac_tool_prefix"; then
  5175. # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
  5176. set dummy ${ac_tool_prefix}nmedit; ac_word=$2
  5177. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5178. $as_echo_n "checking for $ac_word... " >&6; }
  5179. if ${ac_cv_prog_NMEDIT+:} false; then :
  5180. $as_echo_n "(cached) " >&6
  5181. else
  5182. if test -n "$NMEDIT"; then
  5183. ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
  5184. else
  5185. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5186. for as_dir in $PATH
  5187. do
  5188. IFS=$as_save_IFS
  5189. test -z "$as_dir" && as_dir=.
  5190. for ac_exec_ext in '' $ac_executable_extensions; do
  5191. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5192. ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
  5193. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5194. break 2
  5195. fi
  5196. done
  5197. done
  5198. IFS=$as_save_IFS
  5199. fi
  5200. fi
  5201. NMEDIT=$ac_cv_prog_NMEDIT
  5202. if test -n "$NMEDIT"; then
  5203. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
  5204. $as_echo "$NMEDIT" >&6; }
  5205. else
  5206. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5207. $as_echo "no" >&6; }
  5208. fi
  5209. fi
  5210. if test -z "$ac_cv_prog_NMEDIT"; then
  5211. ac_ct_NMEDIT=$NMEDIT
  5212. # Extract the first word of "nmedit", so it can be a program name with args.
  5213. set dummy nmedit; ac_word=$2
  5214. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5215. $as_echo_n "checking for $ac_word... " >&6; }
  5216. if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
  5217. $as_echo_n "(cached) " >&6
  5218. else
  5219. if test -n "$ac_ct_NMEDIT"; then
  5220. ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
  5221. else
  5222. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5223. for as_dir in $PATH
  5224. do
  5225. IFS=$as_save_IFS
  5226. test -z "$as_dir" && as_dir=.
  5227. for ac_exec_ext in '' $ac_executable_extensions; do
  5228. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5229. ac_cv_prog_ac_ct_NMEDIT="nmedit"
  5230. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5231. break 2
  5232. fi
  5233. done
  5234. done
  5235. IFS=$as_save_IFS
  5236. fi
  5237. fi
  5238. ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
  5239. if test -n "$ac_ct_NMEDIT"; then
  5240. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
  5241. $as_echo "$ac_ct_NMEDIT" >&6; }
  5242. else
  5243. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5244. $as_echo "no" >&6; }
  5245. fi
  5246. if test "x$ac_ct_NMEDIT" = x; then
  5247. NMEDIT=":"
  5248. else
  5249. case $cross_compiling:$ac_tool_warned in
  5250. yes:)
  5251. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5252. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5253. ac_tool_warned=yes ;;
  5254. esac
  5255. NMEDIT=$ac_ct_NMEDIT
  5256. fi
  5257. else
  5258. NMEDIT="$ac_cv_prog_NMEDIT"
  5259. fi
  5260. if test -n "$ac_tool_prefix"; then
  5261. # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
  5262. set dummy ${ac_tool_prefix}lipo; ac_word=$2
  5263. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5264. $as_echo_n "checking for $ac_word... " >&6; }
  5265. if ${ac_cv_prog_LIPO+:} false; then :
  5266. $as_echo_n "(cached) " >&6
  5267. else
  5268. if test -n "$LIPO"; then
  5269. ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
  5270. else
  5271. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5272. for as_dir in $PATH
  5273. do
  5274. IFS=$as_save_IFS
  5275. test -z "$as_dir" && as_dir=.
  5276. for ac_exec_ext in '' $ac_executable_extensions; do
  5277. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5278. ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
  5279. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5280. break 2
  5281. fi
  5282. done
  5283. done
  5284. IFS=$as_save_IFS
  5285. fi
  5286. fi
  5287. LIPO=$ac_cv_prog_LIPO
  5288. if test -n "$LIPO"; then
  5289. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
  5290. $as_echo "$LIPO" >&6; }
  5291. else
  5292. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5293. $as_echo "no" >&6; }
  5294. fi
  5295. fi
  5296. if test -z "$ac_cv_prog_LIPO"; then
  5297. ac_ct_LIPO=$LIPO
  5298. # Extract the first word of "lipo", so it can be a program name with args.
  5299. set dummy lipo; ac_word=$2
  5300. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5301. $as_echo_n "checking for $ac_word... " >&6; }
  5302. if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
  5303. $as_echo_n "(cached) " >&6
  5304. else
  5305. if test -n "$ac_ct_LIPO"; then
  5306. ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
  5307. else
  5308. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5309. for as_dir in $PATH
  5310. do
  5311. IFS=$as_save_IFS
  5312. test -z "$as_dir" && as_dir=.
  5313. for ac_exec_ext in '' $ac_executable_extensions; do
  5314. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5315. ac_cv_prog_ac_ct_LIPO="lipo"
  5316. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5317. break 2
  5318. fi
  5319. done
  5320. done
  5321. IFS=$as_save_IFS
  5322. fi
  5323. fi
  5324. ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
  5325. if test -n "$ac_ct_LIPO"; then
  5326. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
  5327. $as_echo "$ac_ct_LIPO" >&6; }
  5328. else
  5329. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5330. $as_echo "no" >&6; }
  5331. fi
  5332. if test "x$ac_ct_LIPO" = x; then
  5333. LIPO=":"
  5334. else
  5335. case $cross_compiling:$ac_tool_warned in
  5336. yes:)
  5337. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5338. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5339. ac_tool_warned=yes ;;
  5340. esac
  5341. LIPO=$ac_ct_LIPO
  5342. fi
  5343. else
  5344. LIPO="$ac_cv_prog_LIPO"
  5345. fi
  5346. if test -n "$ac_tool_prefix"; then
  5347. # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
  5348. set dummy ${ac_tool_prefix}otool; ac_word=$2
  5349. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5350. $as_echo_n "checking for $ac_word... " >&6; }
  5351. if ${ac_cv_prog_OTOOL+:} false; then :
  5352. $as_echo_n "(cached) " >&6
  5353. else
  5354. if test -n "$OTOOL"; then
  5355. ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
  5356. else
  5357. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5358. for as_dir in $PATH
  5359. do
  5360. IFS=$as_save_IFS
  5361. test -z "$as_dir" && as_dir=.
  5362. for ac_exec_ext in '' $ac_executable_extensions; do
  5363. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5364. ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
  5365. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5366. break 2
  5367. fi
  5368. done
  5369. done
  5370. IFS=$as_save_IFS
  5371. fi
  5372. fi
  5373. OTOOL=$ac_cv_prog_OTOOL
  5374. if test -n "$OTOOL"; then
  5375. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
  5376. $as_echo "$OTOOL" >&6; }
  5377. else
  5378. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5379. $as_echo "no" >&6; }
  5380. fi
  5381. fi
  5382. if test -z "$ac_cv_prog_OTOOL"; then
  5383. ac_ct_OTOOL=$OTOOL
  5384. # Extract the first word of "otool", so it can be a program name with args.
  5385. set dummy otool; ac_word=$2
  5386. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5387. $as_echo_n "checking for $ac_word... " >&6; }
  5388. if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
  5389. $as_echo_n "(cached) " >&6
  5390. else
  5391. if test -n "$ac_ct_OTOOL"; then
  5392. ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
  5393. else
  5394. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5395. for as_dir in $PATH
  5396. do
  5397. IFS=$as_save_IFS
  5398. test -z "$as_dir" && as_dir=.
  5399. for ac_exec_ext in '' $ac_executable_extensions; do
  5400. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5401. ac_cv_prog_ac_ct_OTOOL="otool"
  5402. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5403. break 2
  5404. fi
  5405. done
  5406. done
  5407. IFS=$as_save_IFS
  5408. fi
  5409. fi
  5410. ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
  5411. if test -n "$ac_ct_OTOOL"; then
  5412. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
  5413. $as_echo "$ac_ct_OTOOL" >&6; }
  5414. else
  5415. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5416. $as_echo "no" >&6; }
  5417. fi
  5418. if test "x$ac_ct_OTOOL" = x; then
  5419. OTOOL=":"
  5420. else
  5421. case $cross_compiling:$ac_tool_warned in
  5422. yes:)
  5423. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5424. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5425. ac_tool_warned=yes ;;
  5426. esac
  5427. OTOOL=$ac_ct_OTOOL
  5428. fi
  5429. else
  5430. OTOOL="$ac_cv_prog_OTOOL"
  5431. fi
  5432. if test -n "$ac_tool_prefix"; then
  5433. # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
  5434. set dummy ${ac_tool_prefix}otool64; ac_word=$2
  5435. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5436. $as_echo_n "checking for $ac_word... " >&6; }
  5437. if ${ac_cv_prog_OTOOL64+:} false; then :
  5438. $as_echo_n "(cached) " >&6
  5439. else
  5440. if test -n "$OTOOL64"; then
  5441. ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
  5442. else
  5443. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5444. for as_dir in $PATH
  5445. do
  5446. IFS=$as_save_IFS
  5447. test -z "$as_dir" && as_dir=.
  5448. for ac_exec_ext in '' $ac_executable_extensions; do
  5449. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5450. ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
  5451. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5452. break 2
  5453. fi
  5454. done
  5455. done
  5456. IFS=$as_save_IFS
  5457. fi
  5458. fi
  5459. OTOOL64=$ac_cv_prog_OTOOL64
  5460. if test -n "$OTOOL64"; then
  5461. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
  5462. $as_echo "$OTOOL64" >&6; }
  5463. else
  5464. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5465. $as_echo "no" >&6; }
  5466. fi
  5467. fi
  5468. if test -z "$ac_cv_prog_OTOOL64"; then
  5469. ac_ct_OTOOL64=$OTOOL64
  5470. # Extract the first word of "otool64", so it can be a program name with args.
  5471. set dummy otool64; ac_word=$2
  5472. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5473. $as_echo_n "checking for $ac_word... " >&6; }
  5474. if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
  5475. $as_echo_n "(cached) " >&6
  5476. else
  5477. if test -n "$ac_ct_OTOOL64"; then
  5478. ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
  5479. else
  5480. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5481. for as_dir in $PATH
  5482. do
  5483. IFS=$as_save_IFS
  5484. test -z "$as_dir" && as_dir=.
  5485. for ac_exec_ext in '' $ac_executable_extensions; do
  5486. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5487. ac_cv_prog_ac_ct_OTOOL64="otool64"
  5488. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5489. break 2
  5490. fi
  5491. done
  5492. done
  5493. IFS=$as_save_IFS
  5494. fi
  5495. fi
  5496. ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
  5497. if test -n "$ac_ct_OTOOL64"; then
  5498. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
  5499. $as_echo "$ac_ct_OTOOL64" >&6; }
  5500. else
  5501. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5502. $as_echo "no" >&6; }
  5503. fi
  5504. if test "x$ac_ct_OTOOL64" = x; then
  5505. OTOOL64=":"
  5506. else
  5507. case $cross_compiling:$ac_tool_warned in
  5508. yes:)
  5509. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5510. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5511. ac_tool_warned=yes ;;
  5512. esac
  5513. OTOOL64=$ac_ct_OTOOL64
  5514. fi
  5515. else
  5516. OTOOL64="$ac_cv_prog_OTOOL64"
  5517. fi
  5518. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
  5519. $as_echo_n "checking for -single_module linker flag... " >&6; }
  5520. if ${lt_cv_apple_cc_single_mod+:} false; then :
  5521. $as_echo_n "(cached) " >&6
  5522. else
  5523. lt_cv_apple_cc_single_mod=no
  5524. if test -z "${LT_MULTI_MODULE}"; then
  5525. # By default we will add the -single_module flag. You can override
  5526. # by either setting the environment variable LT_MULTI_MODULE
  5527. # non-empty at configure time, or by adding -multi_module to the
  5528. # link flags.
  5529. rm -rf libconftest.dylib*
  5530. echo "int foo(void){return 1;}" > conftest.c
  5531. echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
  5532. -dynamiclib -Wl,-single_module conftest.c" >&5
  5533. $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
  5534. -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
  5535. _lt_result=$?
  5536. # If there is a non-empty error log, and "single_module"
  5537. # appears in it, assume the flag caused a linker warning
  5538. if test -s conftest.err && $GREP single_module conftest.err; then
  5539. cat conftest.err >&5
  5540. # Otherwise, if the output was created with a 0 exit code from
  5541. # the compiler, it worked.
  5542. elif test -f libconftest.dylib && test $_lt_result -eq 0; then
  5543. lt_cv_apple_cc_single_mod=yes
  5544. else
  5545. cat conftest.err >&5
  5546. fi
  5547. rm -rf libconftest.dylib*
  5548. rm -f conftest.*
  5549. fi
  5550. fi
  5551. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
  5552. $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
  5553. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
  5554. $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
  5555. if ${lt_cv_ld_exported_symbols_list+:} false; then :
  5556. $as_echo_n "(cached) " >&6
  5557. else
  5558. lt_cv_ld_exported_symbols_list=no
  5559. save_LDFLAGS=$LDFLAGS
  5560. echo "_main" > conftest.sym
  5561. LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
  5562. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5563. /* end confdefs.h. */
  5564. int
  5565. main ()
  5566. {
  5567. ;
  5568. return 0;
  5569. }
  5570. _ACEOF
  5571. if ac_fn_c_try_link "$LINENO"; then :
  5572. lt_cv_ld_exported_symbols_list=yes
  5573. else
  5574. lt_cv_ld_exported_symbols_list=no
  5575. fi
  5576. rm -f core conftest.err conftest.$ac_objext \
  5577. conftest$ac_exeext conftest.$ac_ext
  5578. LDFLAGS="$save_LDFLAGS"
  5579. fi
  5580. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
  5581. $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
  5582. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
  5583. $as_echo_n "checking for -force_load linker flag... " >&6; }
  5584. if ${lt_cv_ld_force_load+:} false; then :
  5585. $as_echo_n "(cached) " >&6
  5586. else
  5587. lt_cv_ld_force_load=no
  5588. cat > conftest.c << _LT_EOF
  5589. int forced_loaded() { return 2;}
  5590. _LT_EOF
  5591. echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
  5592. $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
  5593. echo "$AR cru libconftest.a conftest.o" >&5
  5594. $AR cru libconftest.a conftest.o 2>&5
  5595. echo "$RANLIB libconftest.a" >&5
  5596. $RANLIB libconftest.a 2>&5
  5597. cat > conftest.c << _LT_EOF
  5598. int main() { return 0;}
  5599. _LT_EOF
  5600. echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
  5601. $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
  5602. _lt_result=$?
  5603. if test -s conftest.err && $GREP force_load conftest.err; then
  5604. cat conftest.err >&5
  5605. elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
  5606. lt_cv_ld_force_load=yes
  5607. else
  5608. cat conftest.err >&5
  5609. fi
  5610. rm -f conftest.err libconftest.a conftest conftest.c
  5611. rm -rf conftest.dSYM
  5612. fi
  5613. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
  5614. $as_echo "$lt_cv_ld_force_load" >&6; }
  5615. case $host_os in
  5616. rhapsody* | darwin1.[012])
  5617. _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
  5618. darwin1.*)
  5619. _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
  5620. darwin*) # darwin 5.x on
  5621. # if running on 10.5 or later, the deployment target defaults
  5622. # to the OS version, if on x86, and 10.4, the deployment
  5623. # target defaults to 10.4. Don't you love it?
  5624. case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
  5625. 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
  5626. _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
  5627. 10.[012]*)
  5628. _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
  5629. 10.*)
  5630. _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
  5631. esac
  5632. ;;
  5633. esac
  5634. if test "$lt_cv_apple_cc_single_mod" = "yes"; then
  5635. _lt_dar_single_mod='$single_module'
  5636. fi
  5637. if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
  5638. _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
  5639. else
  5640. _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
  5641. fi
  5642. if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
  5643. _lt_dsymutil='~$DSYMUTIL $lib || :'
  5644. else
  5645. _lt_dsymutil=
  5646. fi
  5647. ;;
  5648. esac
  5649. ac_ext=c
  5650. ac_cpp='$CPP $CPPFLAGS'
  5651. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5652. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5653. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5654. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
  5655. $as_echo_n "checking how to run the C preprocessor... " >&6; }
  5656. # On Suns, sometimes $CPP names a directory.
  5657. if test -n "$CPP" && test -d "$CPP"; then
  5658. CPP=
  5659. fi
  5660. if test -z "$CPP"; then
  5661. if ${ac_cv_prog_CPP+:} false; then :
  5662. $as_echo_n "(cached) " >&6
  5663. else
  5664. # Double quotes because CPP needs to be expanded
  5665. for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
  5666. do
  5667. ac_preproc_ok=false
  5668. for ac_c_preproc_warn_flag in '' yes
  5669. do
  5670. # Use a header file that comes with gcc, so configuring glibc
  5671. # with a fresh cross-compiler works.
  5672. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5673. # <limits.h> exists even on freestanding compilers.
  5674. # On the NeXT, cc -E runs the code through the compiler's parser,
  5675. # not just through cpp. "Syntax error" is here to catch this case.
  5676. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5677. /* end confdefs.h. */
  5678. #ifdef __STDC__
  5679. # include <limits.h>
  5680. #else
  5681. # include <assert.h>
  5682. #endif
  5683. Syntax error
  5684. _ACEOF
  5685. if ac_fn_c_try_cpp "$LINENO"; then :
  5686. else
  5687. # Broken: fails on valid input.
  5688. continue
  5689. fi
  5690. rm -f conftest.err conftest.i conftest.$ac_ext
  5691. # OK, works on sane cases. Now check whether nonexistent headers
  5692. # can be detected and how.
  5693. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5694. /* end confdefs.h. */
  5695. #include <ac_nonexistent.h>
  5696. _ACEOF
  5697. if ac_fn_c_try_cpp "$LINENO"; then :
  5698. # Broken: success on invalid input.
  5699. continue
  5700. else
  5701. # Passes both tests.
  5702. ac_preproc_ok=:
  5703. break
  5704. fi
  5705. rm -f conftest.err conftest.i conftest.$ac_ext
  5706. done
  5707. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5708. rm -f conftest.i conftest.err conftest.$ac_ext
  5709. if $ac_preproc_ok; then :
  5710. break
  5711. fi
  5712. done
  5713. ac_cv_prog_CPP=$CPP
  5714. fi
  5715. CPP=$ac_cv_prog_CPP
  5716. else
  5717. ac_cv_prog_CPP=$CPP
  5718. fi
  5719. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
  5720. $as_echo "$CPP" >&6; }
  5721. ac_preproc_ok=false
  5722. for ac_c_preproc_warn_flag in '' yes
  5723. do
  5724. # Use a header file that comes with gcc, so configuring glibc
  5725. # with a fresh cross-compiler works.
  5726. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5727. # <limits.h> exists even on freestanding compilers.
  5728. # On the NeXT, cc -E runs the code through the compiler's parser,
  5729. # not just through cpp. "Syntax error" is here to catch this case.
  5730. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5731. /* end confdefs.h. */
  5732. #ifdef __STDC__
  5733. # include <limits.h>
  5734. #else
  5735. # include <assert.h>
  5736. #endif
  5737. Syntax error
  5738. _ACEOF
  5739. if ac_fn_c_try_cpp "$LINENO"; then :
  5740. else
  5741. # Broken: fails on valid input.
  5742. continue
  5743. fi
  5744. rm -f conftest.err conftest.i conftest.$ac_ext
  5745. # OK, works on sane cases. Now check whether nonexistent headers
  5746. # can be detected and how.
  5747. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5748. /* end confdefs.h. */
  5749. #include <ac_nonexistent.h>
  5750. _ACEOF
  5751. if ac_fn_c_try_cpp "$LINENO"; then :
  5752. # Broken: success on invalid input.
  5753. continue
  5754. else
  5755. # Passes both tests.
  5756. ac_preproc_ok=:
  5757. break
  5758. fi
  5759. rm -f conftest.err conftest.i conftest.$ac_ext
  5760. done
  5761. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5762. rm -f conftest.i conftest.err conftest.$ac_ext
  5763. if $ac_preproc_ok; then :
  5764. else
  5765. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  5766. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  5767. as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
  5768. See \`config.log' for more details" "$LINENO" 5; }
  5769. fi
  5770. ac_ext=c
  5771. ac_cpp='$CPP $CPPFLAGS'
  5772. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5773. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5774. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5775. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
  5776. $as_echo_n "checking for ANSI C header files... " >&6; }
  5777. if ${ac_cv_header_stdc+:} false; then :
  5778. $as_echo_n "(cached) " >&6
  5779. else
  5780. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5781. /* end confdefs.h. */
  5782. #include <stdlib.h>
  5783. #include <stdarg.h>
  5784. #include <string.h>
  5785. #include <float.h>
  5786. int
  5787. main ()
  5788. {
  5789. ;
  5790. return 0;
  5791. }
  5792. _ACEOF
  5793. if ac_fn_c_try_compile "$LINENO"; then :
  5794. ac_cv_header_stdc=yes
  5795. else
  5796. ac_cv_header_stdc=no
  5797. fi
  5798. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5799. if test $ac_cv_header_stdc = yes; then
  5800. # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  5801. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5802. /* end confdefs.h. */
  5803. #include <string.h>
  5804. _ACEOF
  5805. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  5806. $EGREP "memchr" >/dev/null 2>&1; then :
  5807. else
  5808. ac_cv_header_stdc=no
  5809. fi
  5810. rm -f conftest*
  5811. fi
  5812. if test $ac_cv_header_stdc = yes; then
  5813. # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  5814. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5815. /* end confdefs.h. */
  5816. #include <stdlib.h>
  5817. _ACEOF
  5818. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  5819. $EGREP "free" >/dev/null 2>&1; then :
  5820. else
  5821. ac_cv_header_stdc=no
  5822. fi
  5823. rm -f conftest*
  5824. fi
  5825. if test $ac_cv_header_stdc = yes; then
  5826. # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  5827. if test "$cross_compiling" = yes; then :
  5828. :
  5829. else
  5830. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5831. /* end confdefs.h. */
  5832. #include <ctype.h>
  5833. #include <stdlib.h>
  5834. #if ((' ' & 0x0FF) == 0x020)
  5835. # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  5836. # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  5837. #else
  5838. # define ISLOWER(c) \
  5839. (('a' <= (c) && (c) <= 'i') \
  5840. || ('j' <= (c) && (c) <= 'r') \
  5841. || ('s' <= (c) && (c) <= 'z'))
  5842. # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
  5843. #endif
  5844. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  5845. int
  5846. main ()
  5847. {
  5848. int i;
  5849. for (i = 0; i < 256; i++)
  5850. if (XOR (islower (i), ISLOWER (i))
  5851. || toupper (i) != TOUPPER (i))
  5852. return 2;
  5853. return 0;
  5854. }
  5855. _ACEOF
  5856. if ac_fn_c_try_run "$LINENO"; then :
  5857. else
  5858. ac_cv_header_stdc=no
  5859. fi
  5860. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  5861. conftest.$ac_objext conftest.beam conftest.$ac_ext
  5862. fi
  5863. fi
  5864. fi
  5865. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
  5866. $as_echo "$ac_cv_header_stdc" >&6; }
  5867. if test $ac_cv_header_stdc = yes; then
  5868. $as_echo "#define STDC_HEADERS 1" >>confdefs.h
  5869. fi
  5870. # On IRIX 5.3, sys/types and inttypes.h are conflicting.
  5871. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
  5872. inttypes.h stdint.h unistd.h
  5873. do :
  5874. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  5875. ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
  5876. "
  5877. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  5878. cat >>confdefs.h <<_ACEOF
  5879. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  5880. _ACEOF
  5881. fi
  5882. done
  5883. for ac_header in dlfcn.h
  5884. do :
  5885. ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
  5886. "
  5887. if test "x$ac_cv_header_dlfcn_h" = xyes; then :
  5888. cat >>confdefs.h <<_ACEOF
  5889. #define HAVE_DLFCN_H 1
  5890. _ACEOF
  5891. fi
  5892. done
  5893. # Set options
  5894. # Check whether --enable-static was given.
  5895. if test "${enable_static+set}" = set; then :
  5896. enableval=$enable_static; p=${PACKAGE-default}
  5897. case $enableval in
  5898. yes) enable_static=yes ;;
  5899. no) enable_static=no ;;
  5900. *)
  5901. enable_static=no
  5902. # Look at the argument we got. We use all the common list separators.
  5903. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
  5904. for pkg in $enableval; do
  5905. IFS="$lt_save_ifs"
  5906. if test "X$pkg" = "X$p"; then
  5907. enable_static=yes
  5908. fi
  5909. done
  5910. IFS="$lt_save_ifs"
  5911. ;;
  5912. esac
  5913. else
  5914. enable_static=no
  5915. fi
  5916. enable_dlopen=no
  5917. enable_win32_dll=no
  5918. # Check whether --enable-shared was given.
  5919. if test "${enable_shared+set}" = set; then :
  5920. enableval=$enable_shared; p=${PACKAGE-default}
  5921. case $enableval in
  5922. yes) enable_shared=yes ;;
  5923. no) enable_shared=no ;;
  5924. *)
  5925. enable_shared=no
  5926. # Look at the argument we got. We use all the common list separators.
  5927. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
  5928. for pkg in $enableval; do
  5929. IFS="$lt_save_ifs"
  5930. if test "X$pkg" = "X$p"; then
  5931. enable_shared=yes
  5932. fi
  5933. done
  5934. IFS="$lt_save_ifs"
  5935. ;;
  5936. esac
  5937. else
  5938. enable_shared=yes
  5939. fi
  5940. # Check whether --with-pic was given.
  5941. if test "${with_pic+set}" = set; then :
  5942. withval=$with_pic; lt_p=${PACKAGE-default}
  5943. case $withval in
  5944. yes|no) pic_mode=$withval ;;
  5945. *)
  5946. pic_mode=default
  5947. # Look at the argument we got. We use all the common list separators.
  5948. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
  5949. for lt_pkg in $withval; do
  5950. IFS="$lt_save_ifs"
  5951. if test "X$lt_pkg" = "X$lt_p"; then
  5952. pic_mode=yes
  5953. fi
  5954. done
  5955. IFS="$lt_save_ifs"
  5956. ;;
  5957. esac
  5958. else
  5959. pic_mode=default
  5960. fi
  5961. test -z "$pic_mode" && pic_mode=default
  5962. # Check whether --enable-fast-install was given.
  5963. if test "${enable_fast_install+set}" = set; then :
  5964. enableval=$enable_fast_install; p=${PACKAGE-default}
  5965. case $enableval in
  5966. yes) enable_fast_install=yes ;;
  5967. no) enable_fast_install=no ;;
  5968. *)
  5969. enable_fast_install=no
  5970. # Look at the argument we got. We use all the common list separators.
  5971. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
  5972. for pkg in $enableval; do
  5973. IFS="$lt_save_ifs"
  5974. if test "X$pkg" = "X$p"; then
  5975. enable_fast_install=yes
  5976. fi
  5977. done
  5978. IFS="$lt_save_ifs"
  5979. ;;
  5980. esac
  5981. else
  5982. enable_fast_install=yes
  5983. fi
  5984. # This can be used to rebuild libtool when needed
  5985. LIBTOOL_DEPS="$ltmain"
  5986. # Always use our own libtool.
  5987. LIBTOOL='$(SHELL) $(top_builddir)/libtool'
  5988. test -z "$LN_S" && LN_S="ln -s"
  5989. if test -n "${ZSH_VERSION+set}" ; then
  5990. setopt NO_GLOB_SUBST
  5991. fi
  5992. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
  5993. $as_echo_n "checking for objdir... " >&6; }
  5994. if ${lt_cv_objdir+:} false; then :
  5995. $as_echo_n "(cached) " >&6
  5996. else
  5997. rm -f .libs 2>/dev/null
  5998. mkdir .libs 2>/dev/null
  5999. if test -d .libs; then
  6000. lt_cv_objdir=.libs
  6001. else
  6002. # MS-DOS does not allow filenames that begin with a dot.
  6003. lt_cv_objdir=_libs
  6004. fi
  6005. rmdir .libs 2>/dev/null
  6006. fi
  6007. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
  6008. $as_echo "$lt_cv_objdir" >&6; }
  6009. objdir=$lt_cv_objdir
  6010. cat >>confdefs.h <<_ACEOF
  6011. #define LT_OBJDIR "$lt_cv_objdir/"
  6012. _ACEOF
  6013. case $host_os in
  6014. aix3*)
  6015. # AIX sometimes has problems with the GCC collect2 program. For some
  6016. # reason, if we set the COLLECT_NAMES environment variable, the problems
  6017. # vanish in a puff of smoke.
  6018. if test "X${COLLECT_NAMES+set}" != Xset; then
  6019. COLLECT_NAMES=
  6020. export COLLECT_NAMES
  6021. fi
  6022. ;;
  6023. esac
  6024. # Global variables:
  6025. ofile=libtool
  6026. can_build_shared=yes
  6027. # All known linkers require a `.a' archive for static linking (except MSVC,
  6028. # which needs '.lib').
  6029. libext=a
  6030. with_gnu_ld="$lt_cv_prog_gnu_ld"
  6031. old_CC="$CC"
  6032. old_CFLAGS="$CFLAGS"
  6033. # Set sane defaults for various variables
  6034. test -z "$CC" && CC=cc
  6035. test -z "$LTCC" && LTCC=$CC
  6036. test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
  6037. test -z "$LD" && LD=ld
  6038. test -z "$ac_objext" && ac_objext=o
  6039. for cc_temp in $compiler""; do
  6040. case $cc_temp in
  6041. compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
  6042. distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
  6043. \-*) ;;
  6044. *) break;;
  6045. esac
  6046. done
  6047. cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
  6048. # Only perform the check for file, if the check method requires it
  6049. test -z "$MAGIC_CMD" && MAGIC_CMD=file
  6050. case $deplibs_check_method in
  6051. file_magic*)
  6052. if test "$file_magic_cmd" = '$MAGIC_CMD'; then
  6053. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
  6054. $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
  6055. if ${lt_cv_path_MAGIC_CMD+:} false; then :
  6056. $as_echo_n "(cached) " >&6
  6057. else
  6058. case $MAGIC_CMD in
  6059. [\\/*] | ?:[\\/]*)
  6060. lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
  6061. ;;
  6062. *)
  6063. lt_save_MAGIC_CMD="$MAGIC_CMD"
  6064. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  6065. ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
  6066. for ac_dir in $ac_dummy; do
  6067. IFS="$lt_save_ifs"
  6068. test -z "$ac_dir" && ac_dir=.
  6069. if test -f $ac_dir/${ac_tool_prefix}file; then
  6070. lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
  6071. if test -n "$file_magic_test_file"; then
  6072. case $deplibs_check_method in
  6073. "file_magic "*)
  6074. file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
  6075. MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
  6076. if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
  6077. $EGREP "$file_magic_regex" > /dev/null; then
  6078. :
  6079. else
  6080. cat <<_LT_EOF 1>&2
  6081. *** Warning: the command libtool uses to detect shared libraries,
  6082. *** $file_magic_cmd, produces output that libtool cannot recognize.
  6083. *** The result is that libtool may fail to recognize shared libraries
  6084. *** as such. This will affect the creation of libtool libraries that
  6085. *** depend on shared libraries, but programs linked with such libtool
  6086. *** libraries will work regardless of this problem. Nevertheless, you
  6087. *** may want to report the problem to your system manager and/or to
  6088. *** bug-libtool@gnu.org
  6089. _LT_EOF
  6090. fi ;;
  6091. esac
  6092. fi
  6093. break
  6094. fi
  6095. done
  6096. IFS="$lt_save_ifs"
  6097. MAGIC_CMD="$lt_save_MAGIC_CMD"
  6098. ;;
  6099. esac
  6100. fi
  6101. MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
  6102. if test -n "$MAGIC_CMD"; then
  6103. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
  6104. $as_echo "$MAGIC_CMD" >&6; }
  6105. else
  6106. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6107. $as_echo "no" >&6; }
  6108. fi
  6109. if test -z "$lt_cv_path_MAGIC_CMD"; then
  6110. if test -n "$ac_tool_prefix"; then
  6111. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
  6112. $as_echo_n "checking for file... " >&6; }
  6113. if ${lt_cv_path_MAGIC_CMD+:} false; then :
  6114. $as_echo_n "(cached) " >&6
  6115. else
  6116. case $MAGIC_CMD in
  6117. [\\/*] | ?:[\\/]*)
  6118. lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
  6119. ;;
  6120. *)
  6121. lt_save_MAGIC_CMD="$MAGIC_CMD"
  6122. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  6123. ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
  6124. for ac_dir in $ac_dummy; do
  6125. IFS="$lt_save_ifs"
  6126. test -z "$ac_dir" && ac_dir=.
  6127. if test -f $ac_dir/file; then
  6128. lt_cv_path_MAGIC_CMD="$ac_dir/file"
  6129. if test -n "$file_magic_test_file"; then
  6130. case $deplibs_check_method in
  6131. "file_magic "*)
  6132. file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
  6133. MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
  6134. if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
  6135. $EGREP "$file_magic_regex" > /dev/null; then
  6136. :
  6137. else
  6138. cat <<_LT_EOF 1>&2
  6139. *** Warning: the command libtool uses to detect shared libraries,
  6140. *** $file_magic_cmd, produces output that libtool cannot recognize.
  6141. *** The result is that libtool may fail to recognize shared libraries
  6142. *** as such. This will affect the creation of libtool libraries that
  6143. *** depend on shared libraries, but programs linked with such libtool
  6144. *** libraries will work regardless of this problem. Nevertheless, you
  6145. *** may want to report the problem to your system manager and/or to
  6146. *** bug-libtool@gnu.org
  6147. _LT_EOF
  6148. fi ;;
  6149. esac
  6150. fi
  6151. break
  6152. fi
  6153. done
  6154. IFS="$lt_save_ifs"
  6155. MAGIC_CMD="$lt_save_MAGIC_CMD"
  6156. ;;
  6157. esac
  6158. fi
  6159. MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
  6160. if test -n "$MAGIC_CMD"; then
  6161. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
  6162. $as_echo "$MAGIC_CMD" >&6; }
  6163. else
  6164. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6165. $as_echo "no" >&6; }
  6166. fi
  6167. else
  6168. MAGIC_CMD=:
  6169. fi
  6170. fi
  6171. fi
  6172. ;;
  6173. esac
  6174. # Use C for the default configuration in the libtool script
  6175. lt_save_CC="$CC"
  6176. ac_ext=c
  6177. ac_cpp='$CPP $CPPFLAGS'
  6178. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  6179. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  6180. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  6181. # Source file extension for C test sources.
  6182. ac_ext=c
  6183. # Object file extension for compiled C test sources.
  6184. objext=o
  6185. objext=$objext
  6186. # Code to be used in simple compile tests
  6187. lt_simple_compile_test_code="int some_variable = 0;"
  6188. # Code to be used in simple link tests
  6189. lt_simple_link_test_code='int main(){return(0);}'
  6190. # If no C compiler was specified, use CC.
  6191. LTCC=${LTCC-"$CC"}
  6192. # If no C compiler flags were specified, use CFLAGS.
  6193. LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
  6194. # Allow CC to be a program name with arguments.
  6195. compiler=$CC
  6196. # Save the default compiler, since it gets overwritten when the other
  6197. # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
  6198. compiler_DEFAULT=$CC
  6199. # save warnings/boilerplate of simple test code
  6200. ac_outfile=conftest.$ac_objext
  6201. echo "$lt_simple_compile_test_code" >conftest.$ac_ext
  6202. eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
  6203. _lt_compiler_boilerplate=`cat conftest.err`
  6204. $RM conftest*
  6205. ac_outfile=conftest.$ac_objext
  6206. echo "$lt_simple_link_test_code" >conftest.$ac_ext
  6207. eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
  6208. _lt_linker_boilerplate=`cat conftest.err`
  6209. $RM -r conftest*
  6210. if test -n "$compiler"; then
  6211. lt_prog_compiler_no_builtin_flag=
  6212. if test "$GCC" = yes; then
  6213. case $cc_basename in
  6214. nvcc*)
  6215. lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
  6216. *)
  6217. lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
  6218. esac
  6219. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
  6220. $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
  6221. if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
  6222. $as_echo_n "(cached) " >&6
  6223. else
  6224. lt_cv_prog_compiler_rtti_exceptions=no
  6225. ac_outfile=conftest.$ac_objext
  6226. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  6227. lt_compiler_flag="-fno-rtti -fno-exceptions"
  6228. # Insert the option either (1) after the last *FLAGS variable, or
  6229. # (2) before a word containing "conftest.", or (3) at the end.
  6230. # Note that $ac_compile itself does not contain backslashes and begins
  6231. # with a dollar sign (not a hyphen), so the echo should work correctly.
  6232. # The option is referenced via a variable to avoid confusing sed.
  6233. lt_compile=`echo "$ac_compile" | $SED \
  6234. -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
  6235. -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
  6236. -e 's:$: $lt_compiler_flag:'`
  6237. (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
  6238. (eval "$lt_compile" 2>conftest.err)
  6239. ac_status=$?
  6240. cat conftest.err >&5
  6241. echo "$as_me:$LINENO: \$? = $ac_status" >&5
  6242. if (exit $ac_status) && test -s "$ac_outfile"; then
  6243. # The compiler can only warn and ignore the option if not recognized
  6244. # So say no if there are warnings other than the usual output.
  6245. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
  6246. $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
  6247. if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
  6248. lt_cv_prog_compiler_rtti_exceptions=yes
  6249. fi
  6250. fi
  6251. $RM conftest*
  6252. fi
  6253. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
  6254. $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
  6255. if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
  6256. lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
  6257. else
  6258. :
  6259. fi
  6260. fi
  6261. lt_prog_compiler_wl=
  6262. lt_prog_compiler_pic=
  6263. lt_prog_compiler_static=
  6264. if test "$GCC" = yes; then
  6265. lt_prog_compiler_wl='-Wl,'
  6266. lt_prog_compiler_static='-static'
  6267. case $host_os in
  6268. aix*)
  6269. # All AIX code is PIC.
  6270. if test "$host_cpu" = ia64; then
  6271. # AIX 5 now supports IA64 processor
  6272. lt_prog_compiler_static='-Bstatic'
  6273. fi
  6274. ;;
  6275. amigaos*)
  6276. case $host_cpu in
  6277. powerpc)
  6278. # see comment about AmigaOS4 .so support
  6279. lt_prog_compiler_pic='-fPIC'
  6280. ;;
  6281. m68k)
  6282. # FIXME: we need at least 68020 code to build shared libraries, but
  6283. # adding the `-m68020' flag to GCC prevents building anything better,
  6284. # like `-m68040'.
  6285. lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
  6286. ;;
  6287. esac
  6288. ;;
  6289. beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
  6290. # PIC is the default for these OSes.
  6291. ;;
  6292. mingw* | cygwin* | pw32* | os2* | cegcc*)
  6293. # This hack is so that the source file can tell whether it is being
  6294. # built for inclusion in a dll (and should export symbols for example).
  6295. # Although the cygwin gcc ignores -fPIC, still need this for old-style
  6296. # (--disable-auto-import) libraries
  6297. lt_prog_compiler_pic='-DDLL_EXPORT'
  6298. ;;
  6299. darwin* | rhapsody*)
  6300. # PIC is the default on this platform
  6301. # Common symbols not allowed in MH_DYLIB files
  6302. lt_prog_compiler_pic='-fno-common'
  6303. ;;
  6304. haiku*)
  6305. # PIC is the default for Haiku.
  6306. # The "-static" flag exists, but is broken.
  6307. lt_prog_compiler_static=
  6308. ;;
  6309. hpux*)
  6310. # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
  6311. # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
  6312. # sets the default TLS model and affects inlining.
  6313. case $host_cpu in
  6314. hppa*64*)
  6315. # +Z the default
  6316. ;;
  6317. *)
  6318. lt_prog_compiler_pic='-fPIC'
  6319. ;;
  6320. esac
  6321. ;;
  6322. interix[3-9]*)
  6323. # Interix 3.x gcc -fpic/-fPIC options generate broken code.
  6324. # Instead, we relocate shared libraries at runtime.
  6325. ;;
  6326. msdosdjgpp*)
  6327. # Just because we use GCC doesn't mean we suddenly get shared libraries
  6328. # on systems that don't support them.
  6329. lt_prog_compiler_can_build_shared=no
  6330. enable_shared=no
  6331. ;;
  6332. *nto* | *qnx*)
  6333. # QNX uses GNU C++, but need to define -shared option too, otherwise
  6334. # it will coredump.
  6335. lt_prog_compiler_pic='-fPIC -shared'
  6336. ;;
  6337. sysv4*MP*)
  6338. if test -d /usr/nec; then
  6339. lt_prog_compiler_pic=-Kconform_pic
  6340. fi
  6341. ;;
  6342. *)
  6343. lt_prog_compiler_pic='-fPIC'
  6344. ;;
  6345. esac
  6346. case $cc_basename in
  6347. nvcc*) # Cuda Compiler Driver 2.2
  6348. lt_prog_compiler_wl='-Xlinker '
  6349. if test -n "$lt_prog_compiler_pic"; then
  6350. lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
  6351. fi
  6352. ;;
  6353. esac
  6354. else
  6355. # PORTME Check for flag to pass linker flags through the system compiler.
  6356. case $host_os in
  6357. aix*)
  6358. lt_prog_compiler_wl='-Wl,'
  6359. if test "$host_cpu" = ia64; then
  6360. # AIX 5 now supports IA64 processor
  6361. lt_prog_compiler_static='-Bstatic'
  6362. else
  6363. lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
  6364. fi
  6365. ;;
  6366. mingw* | cygwin* | pw32* | os2* | cegcc*)
  6367. # This hack is so that the source file can tell whether it is being
  6368. # built for inclusion in a dll (and should export symbols for example).
  6369. lt_prog_compiler_pic='-DDLL_EXPORT'
  6370. ;;
  6371. hpux9* | hpux10* | hpux11*)
  6372. lt_prog_compiler_wl='-Wl,'
  6373. # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
  6374. # not for PA HP-UX.
  6375. case $host_cpu in
  6376. hppa*64*|ia64*)
  6377. # +Z the default
  6378. ;;
  6379. *)
  6380. lt_prog_compiler_pic='+Z'
  6381. ;;
  6382. esac
  6383. # Is there a better lt_prog_compiler_static that works with the bundled CC?
  6384. lt_prog_compiler_static='${wl}-a ${wl}archive'
  6385. ;;
  6386. irix5* | irix6* | nonstopux*)
  6387. lt_prog_compiler_wl='-Wl,'
  6388. # PIC (with -KPIC) is the default.
  6389. lt_prog_compiler_static='-non_shared'
  6390. ;;
  6391. linux* | k*bsd*-gnu | kopensolaris*-gnu)
  6392. case $cc_basename in
  6393. # old Intel for x86_64 which still supported -KPIC.
  6394. ecc*)
  6395. lt_prog_compiler_wl='-Wl,'
  6396. lt_prog_compiler_pic='-KPIC'
  6397. lt_prog_compiler_static='-static'
  6398. ;;
  6399. # icc used to be incompatible with GCC.
  6400. # ICC 10 doesn't accept -KPIC any more.
  6401. icc* | ifort*)
  6402. lt_prog_compiler_wl='-Wl,'
  6403. lt_prog_compiler_pic='-fPIC'
  6404. lt_prog_compiler_static='-static'
  6405. ;;
  6406. # Lahey Fortran 8.1.
  6407. lf95*)
  6408. lt_prog_compiler_wl='-Wl,'
  6409. lt_prog_compiler_pic='--shared'
  6410. lt_prog_compiler_static='--static'
  6411. ;;
  6412. nagfor*)
  6413. # NAG Fortran compiler
  6414. lt_prog_compiler_wl='-Wl,-Wl,,'
  6415. lt_prog_compiler_pic='-PIC'
  6416. lt_prog_compiler_static='-Bstatic'
  6417. ;;
  6418. pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
  6419. # Portland Group compilers (*not* the Pentium gcc compiler,
  6420. # which looks to be a dead project)
  6421. lt_prog_compiler_wl='-Wl,'
  6422. lt_prog_compiler_pic='-fpic'
  6423. lt_prog_compiler_static='-Bstatic'
  6424. ;;
  6425. ccc*)
  6426. lt_prog_compiler_wl='-Wl,'
  6427. # All Alpha code is PIC.
  6428. lt_prog_compiler_static='-non_shared'
  6429. ;;
  6430. xl* | bgxl* | bgf* | mpixl*)
  6431. # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
  6432. lt_prog_compiler_wl='-Wl,'
  6433. lt_prog_compiler_pic='-qpic'
  6434. lt_prog_compiler_static='-qstaticlink'
  6435. ;;
  6436. *)
  6437. case `$CC -V 2>&1 | sed 5q` in
  6438. *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
  6439. # Sun Fortran 8.3 passes all unrecognized flags to the linker
  6440. lt_prog_compiler_pic='-KPIC'
  6441. lt_prog_compiler_static='-Bstatic'
  6442. lt_prog_compiler_wl=''
  6443. ;;
  6444. *Sun\ F* | *Sun*Fortran*)
  6445. lt_prog_compiler_pic='-KPIC'
  6446. lt_prog_compiler_static='-Bstatic'
  6447. lt_prog_compiler_wl='-Qoption ld '
  6448. ;;
  6449. *Sun\ C*)
  6450. # Sun C 5.9
  6451. lt_prog_compiler_pic='-KPIC'
  6452. lt_prog_compiler_static='-Bstatic'
  6453. lt_prog_compiler_wl='-Wl,'
  6454. ;;
  6455. *Intel*\ [CF]*Compiler*)
  6456. lt_prog_compiler_wl='-Wl,'
  6457. lt_prog_compiler_pic='-fPIC'
  6458. lt_prog_compiler_static='-static'
  6459. ;;
  6460. *Portland\ Group*)
  6461. lt_prog_compiler_wl='-Wl,'
  6462. lt_prog_compiler_pic='-fpic'
  6463. lt_prog_compiler_static='-Bstatic'
  6464. ;;
  6465. esac
  6466. ;;
  6467. esac
  6468. ;;
  6469. newsos6)
  6470. lt_prog_compiler_pic='-KPIC'
  6471. lt_prog_compiler_static='-Bstatic'
  6472. ;;
  6473. *nto* | *qnx*)
  6474. # QNX uses GNU C++, but need to define -shared option too, otherwise
  6475. # it will coredump.
  6476. lt_prog_compiler_pic='-fPIC -shared'
  6477. ;;
  6478. osf3* | osf4* | osf5*)
  6479. lt_prog_compiler_wl='-Wl,'
  6480. # All OSF/1 code is PIC.
  6481. lt_prog_compiler_static='-non_shared'
  6482. ;;
  6483. rdos*)
  6484. lt_prog_compiler_static='-non_shared'
  6485. ;;
  6486. solaris*)
  6487. lt_prog_compiler_pic='-KPIC'
  6488. lt_prog_compiler_static='-Bstatic'
  6489. case $cc_basename in
  6490. f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
  6491. lt_prog_compiler_wl='-Qoption ld ';;
  6492. *)
  6493. lt_prog_compiler_wl='-Wl,';;
  6494. esac
  6495. ;;
  6496. sunos4*)
  6497. lt_prog_compiler_wl='-Qoption ld '
  6498. lt_prog_compiler_pic='-PIC'
  6499. lt_prog_compiler_static='-Bstatic'
  6500. ;;
  6501. sysv4 | sysv4.2uw2* | sysv4.3*)
  6502. lt_prog_compiler_wl='-Wl,'
  6503. lt_prog_compiler_pic='-KPIC'
  6504. lt_prog_compiler_static='-Bstatic'
  6505. ;;
  6506. sysv4*MP*)
  6507. if test -d /usr/nec ;then
  6508. lt_prog_compiler_pic='-Kconform_pic'
  6509. lt_prog_compiler_static='-Bstatic'
  6510. fi
  6511. ;;
  6512. sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
  6513. lt_prog_compiler_wl='-Wl,'
  6514. lt_prog_compiler_pic='-KPIC'
  6515. lt_prog_compiler_static='-Bstatic'
  6516. ;;
  6517. unicos*)
  6518. lt_prog_compiler_wl='-Wl,'
  6519. lt_prog_compiler_can_build_shared=no
  6520. ;;
  6521. uts4*)
  6522. lt_prog_compiler_pic='-pic'
  6523. lt_prog_compiler_static='-Bstatic'
  6524. ;;
  6525. *)
  6526. lt_prog_compiler_can_build_shared=no
  6527. ;;
  6528. esac
  6529. fi
  6530. case $host_os in
  6531. # For platforms which do not support PIC, -DPIC is meaningless:
  6532. *djgpp*)
  6533. lt_prog_compiler_pic=
  6534. ;;
  6535. *)
  6536. lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
  6537. ;;
  6538. esac
  6539. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
  6540. $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
  6541. if ${lt_cv_prog_compiler_pic+:} false; then :
  6542. $as_echo_n "(cached) " >&6
  6543. else
  6544. lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
  6545. fi
  6546. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
  6547. $as_echo "$lt_cv_prog_compiler_pic" >&6; }
  6548. lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
  6549. #
  6550. # Check to make sure the PIC flag actually works.
  6551. #
  6552. if test -n "$lt_prog_compiler_pic"; then
  6553. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
  6554. $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
  6555. if ${lt_cv_prog_compiler_pic_works+:} false; then :
  6556. $as_echo_n "(cached) " >&6
  6557. else
  6558. lt_cv_prog_compiler_pic_works=no
  6559. ac_outfile=conftest.$ac_objext
  6560. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  6561. lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
  6562. # Insert the option either (1) after the last *FLAGS variable, or
  6563. # (2) before a word containing "conftest.", or (3) at the end.
  6564. # Note that $ac_compile itself does not contain backslashes and begins
  6565. # with a dollar sign (not a hyphen), so the echo should work correctly.
  6566. # The option is referenced via a variable to avoid confusing sed.
  6567. lt_compile=`echo "$ac_compile" | $SED \
  6568. -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
  6569. -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
  6570. -e 's:$: $lt_compiler_flag:'`
  6571. (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
  6572. (eval "$lt_compile" 2>conftest.err)
  6573. ac_status=$?
  6574. cat conftest.err >&5
  6575. echo "$as_me:$LINENO: \$? = $ac_status" >&5
  6576. if (exit $ac_status) && test -s "$ac_outfile"; then
  6577. # The compiler can only warn and ignore the option if not recognized
  6578. # So say no if there are warnings other than the usual output.
  6579. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
  6580. $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
  6581. if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
  6582. lt_cv_prog_compiler_pic_works=yes
  6583. fi
  6584. fi
  6585. $RM conftest*
  6586. fi
  6587. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
  6588. $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
  6589. if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
  6590. case $lt_prog_compiler_pic in
  6591. "" | " "*) ;;
  6592. *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
  6593. esac
  6594. else
  6595. lt_prog_compiler_pic=
  6596. lt_prog_compiler_can_build_shared=no
  6597. fi
  6598. fi
  6599. #
  6600. # Check to make sure the static flag actually works.
  6601. #
  6602. wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
  6603. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
  6604. $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
  6605. if ${lt_cv_prog_compiler_static_works+:} false; then :
  6606. $as_echo_n "(cached) " >&6
  6607. else
  6608. lt_cv_prog_compiler_static_works=no
  6609. save_LDFLAGS="$LDFLAGS"
  6610. LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
  6611. echo "$lt_simple_link_test_code" > conftest.$ac_ext
  6612. if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
  6613. # The linker can only warn and ignore the option if not recognized
  6614. # So say no if there are warnings
  6615. if test -s conftest.err; then
  6616. # Append any errors to the config.log.
  6617. cat conftest.err 1>&5
  6618. $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
  6619. $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
  6620. if diff conftest.exp conftest.er2 >/dev/null; then
  6621. lt_cv_prog_compiler_static_works=yes
  6622. fi
  6623. else
  6624. lt_cv_prog_compiler_static_works=yes
  6625. fi
  6626. fi
  6627. $RM -r conftest*
  6628. LDFLAGS="$save_LDFLAGS"
  6629. fi
  6630. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
  6631. $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
  6632. if test x"$lt_cv_prog_compiler_static_works" = xyes; then
  6633. :
  6634. else
  6635. lt_prog_compiler_static=
  6636. fi
  6637. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
  6638. $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
  6639. if ${lt_cv_prog_compiler_c_o+:} false; then :
  6640. $as_echo_n "(cached) " >&6
  6641. else
  6642. lt_cv_prog_compiler_c_o=no
  6643. $RM -r conftest 2>/dev/null
  6644. mkdir conftest
  6645. cd conftest
  6646. mkdir out
  6647. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  6648. lt_compiler_flag="-o out/conftest2.$ac_objext"
  6649. # Insert the option either (1) after the last *FLAGS variable, or
  6650. # (2) before a word containing "conftest.", or (3) at the end.
  6651. # Note that $ac_compile itself does not contain backslashes and begins
  6652. # with a dollar sign (not a hyphen), so the echo should work correctly.
  6653. lt_compile=`echo "$ac_compile" | $SED \
  6654. -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
  6655. -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
  6656. -e 's:$: $lt_compiler_flag:'`
  6657. (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
  6658. (eval "$lt_compile" 2>out/conftest.err)
  6659. ac_status=$?
  6660. cat out/conftest.err >&5
  6661. echo "$as_me:$LINENO: \$? = $ac_status" >&5
  6662. if (exit $ac_status) && test -s out/conftest2.$ac_objext
  6663. then
  6664. # The compiler can only warn and ignore the option if not recognized
  6665. # So say no if there are warnings
  6666. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
  6667. $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
  6668. if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
  6669. lt_cv_prog_compiler_c_o=yes
  6670. fi
  6671. fi
  6672. chmod u+w . 2>&5
  6673. $RM conftest*
  6674. # SGI C++ compiler will create directory out/ii_files/ for
  6675. # template instantiation
  6676. test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
  6677. $RM out/* && rmdir out
  6678. cd ..
  6679. $RM -r conftest
  6680. $RM conftest*
  6681. fi
  6682. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
  6683. $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
  6684. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
  6685. $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
  6686. if ${lt_cv_prog_compiler_c_o+:} false; then :
  6687. $as_echo_n "(cached) " >&6
  6688. else
  6689. lt_cv_prog_compiler_c_o=no
  6690. $RM -r conftest 2>/dev/null
  6691. mkdir conftest
  6692. cd conftest
  6693. mkdir out
  6694. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  6695. lt_compiler_flag="-o out/conftest2.$ac_objext"
  6696. # Insert the option either (1) after the last *FLAGS variable, or
  6697. # (2) before a word containing "conftest.", or (3) at the end.
  6698. # Note that $ac_compile itself does not contain backslashes and begins
  6699. # with a dollar sign (not a hyphen), so the echo should work correctly.
  6700. lt_compile=`echo "$ac_compile" | $SED \
  6701. -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
  6702. -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
  6703. -e 's:$: $lt_compiler_flag:'`
  6704. (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
  6705. (eval "$lt_compile" 2>out/conftest.err)
  6706. ac_status=$?
  6707. cat out/conftest.err >&5
  6708. echo "$as_me:$LINENO: \$? = $ac_status" >&5
  6709. if (exit $ac_status) && test -s out/conftest2.$ac_objext
  6710. then
  6711. # The compiler can only warn and ignore the option if not recognized
  6712. # So say no if there are warnings
  6713. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
  6714. $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
  6715. if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
  6716. lt_cv_prog_compiler_c_o=yes
  6717. fi
  6718. fi
  6719. chmod u+w . 2>&5
  6720. $RM conftest*
  6721. # SGI C++ compiler will create directory out/ii_files/ for
  6722. # template instantiation
  6723. test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
  6724. $RM out/* && rmdir out
  6725. cd ..
  6726. $RM -r conftest
  6727. $RM conftest*
  6728. fi
  6729. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
  6730. $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
  6731. hard_links="nottested"
  6732. if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
  6733. # do not overwrite the value of need_locks provided by the user
  6734. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
  6735. $as_echo_n "checking if we can lock with hard links... " >&6; }
  6736. hard_links=yes
  6737. $RM conftest*
  6738. ln conftest.a conftest.b 2>/dev/null && hard_links=no
  6739. touch conftest.a
  6740. ln conftest.a conftest.b 2>&5 || hard_links=no
  6741. ln conftest.a conftest.b 2>/dev/null && hard_links=no
  6742. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
  6743. $as_echo "$hard_links" >&6; }
  6744. if test "$hard_links" = no; then
  6745. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
  6746. $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
  6747. need_locks=warn
  6748. fi
  6749. else
  6750. need_locks=no
  6751. fi
  6752. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
  6753. $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
  6754. runpath_var=
  6755. allow_undefined_flag=
  6756. always_export_symbols=no
  6757. archive_cmds=
  6758. archive_expsym_cmds=
  6759. compiler_needs_object=no
  6760. enable_shared_with_static_runtimes=no
  6761. export_dynamic_flag_spec=
  6762. export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
  6763. hardcode_automatic=no
  6764. hardcode_direct=no
  6765. hardcode_direct_absolute=no
  6766. hardcode_libdir_flag_spec=
  6767. hardcode_libdir_separator=
  6768. hardcode_minus_L=no
  6769. hardcode_shlibpath_var=unsupported
  6770. inherit_rpath=no
  6771. link_all_deplibs=unknown
  6772. module_cmds=
  6773. module_expsym_cmds=
  6774. old_archive_from_new_cmds=
  6775. old_archive_from_expsyms_cmds=
  6776. thread_safe_flag_spec=
  6777. whole_archive_flag_spec=
  6778. # include_expsyms should be a list of space-separated symbols to be *always*
  6779. # included in the symbol list
  6780. include_expsyms=
  6781. # exclude_expsyms can be an extended regexp of symbols to exclude
  6782. # it will be wrapped by ` (' and `)$', so one must not match beginning or
  6783. # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
  6784. # as well as any symbol that contains `d'.
  6785. exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
  6786. # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
  6787. # platforms (ab)use it in PIC code, but their linkers get confused if
  6788. # the symbol is explicitly referenced. Since portable code cannot
  6789. # rely on this symbol name, it's probably fine to never include it in
  6790. # preloaded symbol tables.
  6791. # Exclude shared library initialization/finalization symbols.
  6792. extract_expsyms_cmds=
  6793. case $host_os in
  6794. cygwin* | mingw* | pw32* | cegcc*)
  6795. # FIXME: the MSVC++ port hasn't been tested in a loooong time
  6796. # When not using gcc, we currently assume that we are using
  6797. # Microsoft Visual C++.
  6798. if test "$GCC" != yes; then
  6799. with_gnu_ld=no
  6800. fi
  6801. ;;
  6802. interix*)
  6803. # we just hope/assume this is gcc and not c89 (= MSVC++)
  6804. with_gnu_ld=yes
  6805. ;;
  6806. openbsd*)
  6807. with_gnu_ld=no
  6808. ;;
  6809. linux* | k*bsd*-gnu | gnu*)
  6810. link_all_deplibs=no
  6811. ;;
  6812. esac
  6813. ld_shlibs=yes
  6814. # On some targets, GNU ld is compatible enough with the native linker
  6815. # that we're better off using the native interface for both.
  6816. lt_use_gnu_ld_interface=no
  6817. if test "$with_gnu_ld" = yes; then
  6818. case $host_os in
  6819. aix*)
  6820. # The AIX port of GNU ld has always aspired to compatibility
  6821. # with the native linker. However, as the warning in the GNU ld
  6822. # block says, versions before 2.19.5* couldn't really create working
  6823. # shared libraries, regardless of the interface used.
  6824. case `$LD -v 2>&1` in
  6825. *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
  6826. *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
  6827. *\ \(GNU\ Binutils\)\ [3-9]*) ;;
  6828. *)
  6829. lt_use_gnu_ld_interface=yes
  6830. ;;
  6831. esac
  6832. ;;
  6833. *)
  6834. lt_use_gnu_ld_interface=yes
  6835. ;;
  6836. esac
  6837. fi
  6838. if test "$lt_use_gnu_ld_interface" = yes; then
  6839. # If archive_cmds runs LD, not CC, wlarc should be empty
  6840. wlarc='${wl}'
  6841. # Set some defaults for GNU ld with shared library support. These
  6842. # are reset later if shared libraries are not supported. Putting them
  6843. # here allows them to be overridden if necessary.
  6844. runpath_var=LD_RUN_PATH
  6845. hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  6846. export_dynamic_flag_spec='${wl}--export-dynamic'
  6847. # ancient GNU ld didn't support --whole-archive et. al.
  6848. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
  6849. whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
  6850. else
  6851. whole_archive_flag_spec=
  6852. fi
  6853. supports_anon_versioning=no
  6854. case `$LD -v 2>&1` in
  6855. *GNU\ gold*) supports_anon_versioning=yes ;;
  6856. *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
  6857. *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
  6858. *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
  6859. *\ 2.11.*) ;; # other 2.11 versions
  6860. *) supports_anon_versioning=yes ;;
  6861. esac
  6862. # See if GNU ld supports shared libraries.
  6863. case $host_os in
  6864. aix[3-9]*)
  6865. # On AIX/PPC, the GNU linker is very broken
  6866. if test "$host_cpu" != ia64; then
  6867. ld_shlibs=no
  6868. cat <<_LT_EOF 1>&2
  6869. *** Warning: the GNU linker, at least up to release 2.19, is reported
  6870. *** to be unable to reliably create shared libraries on AIX.
  6871. *** Therefore, libtool is disabling shared libraries support. If you
  6872. *** really care for shared libraries, you may want to install binutils
  6873. *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
  6874. *** You will then need to restart the configuration process.
  6875. _LT_EOF
  6876. fi
  6877. ;;
  6878. amigaos*)
  6879. case $host_cpu in
  6880. powerpc)
  6881. # see comment about AmigaOS4 .so support
  6882. archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  6883. archive_expsym_cmds=''
  6884. ;;
  6885. m68k)
  6886. archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
  6887. hardcode_libdir_flag_spec='-L$libdir'
  6888. hardcode_minus_L=yes
  6889. ;;
  6890. esac
  6891. ;;
  6892. beos*)
  6893. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  6894. allow_undefined_flag=unsupported
  6895. # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
  6896. # support --undefined. This deserves some investigation. FIXME
  6897. archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  6898. else
  6899. ld_shlibs=no
  6900. fi
  6901. ;;
  6902. cygwin* | mingw* | pw32* | cegcc*)
  6903. # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
  6904. # as there is no search path for DLLs.
  6905. hardcode_libdir_flag_spec='-L$libdir'
  6906. export_dynamic_flag_spec='${wl}--export-all-symbols'
  6907. allow_undefined_flag=unsupported
  6908. always_export_symbols=no
  6909. enable_shared_with_static_runtimes=yes
  6910. export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
  6911. exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
  6912. if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
  6913. archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
  6914. # If the export-symbols file already is a .def file (1st line
  6915. # is EXPORTS), use it as is; otherwise, prepend...
  6916. archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
  6917. cp $export_symbols $output_objdir/$soname.def;
  6918. else
  6919. echo EXPORTS > $output_objdir/$soname.def;
  6920. cat $export_symbols >> $output_objdir/$soname.def;
  6921. fi~
  6922. $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
  6923. else
  6924. ld_shlibs=no
  6925. fi
  6926. ;;
  6927. haiku*)
  6928. archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  6929. link_all_deplibs=yes
  6930. ;;
  6931. interix[3-9]*)
  6932. hardcode_direct=no
  6933. hardcode_shlibpath_var=no
  6934. hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
  6935. export_dynamic_flag_spec='${wl}-E'
  6936. # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
  6937. # Instead, shared libraries are loaded at an image base (0x10000000 by
  6938. # default) and relocated if they conflict, which is a slow very memory
  6939. # consuming and fragmenting process. To avoid this, we pick a random,
  6940. # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
  6941. # time. Moving up from 0x10000000 also allows more sbrk(2) space.
  6942. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
  6943. archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
  6944. ;;
  6945. gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
  6946. tmp_diet=no
  6947. if test "$host_os" = linux-dietlibc; then
  6948. case $cc_basename in
  6949. diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
  6950. esac
  6951. fi
  6952. if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
  6953. && test "$tmp_diet" = no
  6954. then
  6955. tmp_addflag=' $pic_flag'
  6956. tmp_sharedflag='-shared'
  6957. case $cc_basename,$host_cpu in
  6958. pgcc*) # Portland Group C compiler
  6959. whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
  6960. tmp_addflag=' $pic_flag'
  6961. ;;
  6962. pgf77* | pgf90* | pgf95* | pgfortran*)
  6963. # Portland Group f77 and f90 compilers
  6964. whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
  6965. tmp_addflag=' $pic_flag -Mnomain' ;;
  6966. ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
  6967. tmp_addflag=' -i_dynamic' ;;
  6968. efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
  6969. tmp_addflag=' -i_dynamic -nofor_main' ;;
  6970. ifc* | ifort*) # Intel Fortran compiler
  6971. tmp_addflag=' -nofor_main' ;;
  6972. lf95*) # Lahey Fortran 8.1
  6973. whole_archive_flag_spec=
  6974. tmp_sharedflag='--shared' ;;
  6975. xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
  6976. tmp_sharedflag='-qmkshrobj'
  6977. tmp_addflag= ;;
  6978. nvcc*) # Cuda Compiler Driver 2.2
  6979. whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
  6980. compiler_needs_object=yes
  6981. ;;
  6982. esac
  6983. case `$CC -V 2>&1 | sed 5q` in
  6984. *Sun\ C*) # Sun C 5.9
  6985. whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
  6986. compiler_needs_object=yes
  6987. tmp_sharedflag='-G' ;;
  6988. *Sun\ F*) # Sun Fortran 8.3
  6989. tmp_sharedflag='-G' ;;
  6990. esac
  6991. archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  6992. if test "x$supports_anon_versioning" = xyes; then
  6993. archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
  6994. cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
  6995. echo "local: *; };" >> $output_objdir/$libname.ver~
  6996. $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
  6997. fi
  6998. case $cc_basename in
  6999. xlf* | bgf* | bgxlf* | mpixlf*)
  7000. # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
  7001. whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  7002. hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  7003. archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
  7004. if test "x$supports_anon_versioning" = xyes; then
  7005. archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
  7006. cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
  7007. echo "local: *; };" >> $output_objdir/$libname.ver~
  7008. $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
  7009. fi
  7010. ;;
  7011. esac
  7012. else
  7013. ld_shlibs=no
  7014. fi
  7015. ;;
  7016. netbsd* | netbsdelf*-gnu)
  7017. if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
  7018. archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  7019. wlarc=
  7020. else
  7021. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  7022. archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  7023. fi
  7024. ;;
  7025. solaris*)
  7026. if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
  7027. ld_shlibs=no
  7028. cat <<_LT_EOF 1>&2
  7029. *** Warning: The releases 2.8.* of the GNU linker cannot reliably
  7030. *** create shared libraries on Solaris systems. Therefore, libtool
  7031. *** is disabling shared libraries support. We urge you to upgrade GNU
  7032. *** binutils to release 2.9.1 or newer. Another option is to modify
  7033. *** your PATH or compiler configuration so that the native linker is
  7034. *** used, and then restart.
  7035. _LT_EOF
  7036. elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  7037. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  7038. archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  7039. else
  7040. ld_shlibs=no
  7041. fi
  7042. ;;
  7043. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
  7044. case `$LD -v 2>&1` in
  7045. *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
  7046. ld_shlibs=no
  7047. cat <<_LT_EOF 1>&2
  7048. *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
  7049. *** reliably create shared libraries on SCO systems. Therefore, libtool
  7050. *** is disabling shared libraries support. We urge you to upgrade GNU
  7051. *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
  7052. *** your PATH or compiler configuration so that the native linker is
  7053. *** used, and then restart.
  7054. _LT_EOF
  7055. ;;
  7056. *)
  7057. # For security reasons, it is highly recommended that you always
  7058. # use absolute paths for naming shared libraries, and exclude the
  7059. # DT_RUNPATH tag from executables and libraries. But doing so
  7060. # requires that you compile everything twice, which is a pain.
  7061. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  7062. hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  7063. archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  7064. archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  7065. else
  7066. ld_shlibs=no
  7067. fi
  7068. ;;
  7069. esac
  7070. ;;
  7071. sunos4*)
  7072. archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  7073. wlarc=
  7074. hardcode_direct=yes
  7075. hardcode_shlibpath_var=no
  7076. ;;
  7077. *)
  7078. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  7079. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  7080. archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  7081. else
  7082. ld_shlibs=no
  7083. fi
  7084. ;;
  7085. esac
  7086. if test "$ld_shlibs" = no; then
  7087. runpath_var=
  7088. hardcode_libdir_flag_spec=
  7089. export_dynamic_flag_spec=
  7090. whole_archive_flag_spec=
  7091. fi
  7092. else
  7093. # PORTME fill in a description of your system's linker (not GNU ld)
  7094. case $host_os in
  7095. aix3*)
  7096. allow_undefined_flag=unsupported
  7097. always_export_symbols=yes
  7098. archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
  7099. # Note: this linker hardcodes the directories in LIBPATH if there
  7100. # are no directories specified by -L.
  7101. hardcode_minus_L=yes
  7102. if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
  7103. # Neither direct hardcoding nor static linking is supported with a
  7104. # broken collect2.
  7105. hardcode_direct=unsupported
  7106. fi
  7107. ;;
  7108. aix[4-9]*)
  7109. if test "$host_cpu" = ia64; then
  7110. # On IA64, the linker does run time linking by default, so we don't
  7111. # have to do anything special.
  7112. aix_use_runtimelinking=no
  7113. exp_sym_flag='-Bexport'
  7114. no_entry_flag=""
  7115. else
  7116. # If we're using GNU nm, then we don't want the "-C" option.
  7117. # -C means demangle to AIX nm, but means don't demangle with GNU nm
  7118. # Also, AIX nm treats weak defined symbols like other global
  7119. # defined symbols, whereas GNU nm marks them as "W".
  7120. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
  7121. export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
  7122. else
  7123. export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
  7124. fi
  7125. aix_use_runtimelinking=no
  7126. # Test if we are trying to use run time linking or normal
  7127. # AIX style linking. If -brtl is somewhere in LDFLAGS, we
  7128. # need to do runtime linking.
  7129. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
  7130. for ld_flag in $LDFLAGS; do
  7131. if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
  7132. aix_use_runtimelinking=yes
  7133. break
  7134. fi
  7135. done
  7136. ;;
  7137. esac
  7138. exp_sym_flag='-bexport'
  7139. no_entry_flag='-bnoentry'
  7140. fi
  7141. # When large executables or shared objects are built, AIX ld can
  7142. # have problems creating the table of contents. If linking a library
  7143. # or program results in "error TOC overflow" add -mminimal-toc to
  7144. # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
  7145. # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
  7146. archive_cmds=''
  7147. hardcode_direct=yes
  7148. hardcode_direct_absolute=yes
  7149. hardcode_libdir_separator=':'
  7150. link_all_deplibs=yes
  7151. file_list_spec='${wl}-f,'
  7152. if test "$GCC" = yes; then
  7153. case $host_os in aix4.[012]|aix4.[012].*)
  7154. # We only want to do this on AIX 4.2 and lower, the check
  7155. # below for broken collect2 doesn't work under 4.3+
  7156. collect2name=`${CC} -print-prog-name=collect2`
  7157. if test -f "$collect2name" &&
  7158. strings "$collect2name" | $GREP resolve_lib_name >/dev/null
  7159. then
  7160. # We have reworked collect2
  7161. :
  7162. else
  7163. # We have old collect2
  7164. hardcode_direct=unsupported
  7165. # It fails to find uninstalled libraries when the uninstalled
  7166. # path is not listed in the libpath. Setting hardcode_minus_L
  7167. # to unsupported forces relinking
  7168. hardcode_minus_L=yes
  7169. hardcode_libdir_flag_spec='-L$libdir'
  7170. hardcode_libdir_separator=
  7171. fi
  7172. ;;
  7173. esac
  7174. shared_flag='-shared'
  7175. if test "$aix_use_runtimelinking" = yes; then
  7176. shared_flag="$shared_flag "'${wl}-G'
  7177. fi
  7178. link_all_deplibs=no
  7179. else
  7180. # not using gcc
  7181. if test "$host_cpu" = ia64; then
  7182. # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
  7183. # chokes on -Wl,-G. The following line is correct:
  7184. shared_flag='-G'
  7185. else
  7186. if test "$aix_use_runtimelinking" = yes; then
  7187. shared_flag='${wl}-G'
  7188. else
  7189. shared_flag='${wl}-bM:SRE'
  7190. fi
  7191. fi
  7192. fi
  7193. export_dynamic_flag_spec='${wl}-bexpall'
  7194. # It seems that -bexpall does not export symbols beginning with
  7195. # underscore (_), so it is better to generate a list of symbols to export.
  7196. always_export_symbols=yes
  7197. if test "$aix_use_runtimelinking" = yes; then
  7198. # Warning - without using the other runtime loading flags (-brtl),
  7199. # -berok will link without error, but may produce a broken library.
  7200. allow_undefined_flag='-berok'
  7201. # Determine the default libpath from the value encoded in an
  7202. # empty executable.
  7203. if test "${lt_cv_aix_libpath+set}" = set; then
  7204. aix_libpath=$lt_cv_aix_libpath
  7205. else
  7206. if ${lt_cv_aix_libpath_+:} false; then :
  7207. $as_echo_n "(cached) " >&6
  7208. else
  7209. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7210. /* end confdefs.h. */
  7211. int
  7212. main ()
  7213. {
  7214. ;
  7215. return 0;
  7216. }
  7217. _ACEOF
  7218. if ac_fn_c_try_link "$LINENO"; then :
  7219. lt_aix_libpath_sed='
  7220. /Import File Strings/,/^$/ {
  7221. /^0/ {
  7222. s/^0 *\([^ ]*\) *$/\1/
  7223. p
  7224. }
  7225. }'
  7226. lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
  7227. # Check for a 64-bit object if we didn't find anything.
  7228. if test -z "$lt_cv_aix_libpath_"; then
  7229. lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
  7230. fi
  7231. fi
  7232. rm -f core conftest.err conftest.$ac_objext \
  7233. conftest$ac_exeext conftest.$ac_ext
  7234. if test -z "$lt_cv_aix_libpath_"; then
  7235. lt_cv_aix_libpath_="/usr/lib:/lib"
  7236. fi
  7237. fi
  7238. aix_libpath=$lt_cv_aix_libpath_
  7239. fi
  7240. hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  7241. archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
  7242. else
  7243. if test "$host_cpu" = ia64; then
  7244. hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
  7245. allow_undefined_flag="-z nodefs"
  7246. archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
  7247. else
  7248. # Determine the default libpath from the value encoded in an
  7249. # empty executable.
  7250. if test "${lt_cv_aix_libpath+set}" = set; then
  7251. aix_libpath=$lt_cv_aix_libpath
  7252. else
  7253. if ${lt_cv_aix_libpath_+:} false; then :
  7254. $as_echo_n "(cached) " >&6
  7255. else
  7256. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7257. /* end confdefs.h. */
  7258. int
  7259. main ()
  7260. {
  7261. ;
  7262. return 0;
  7263. }
  7264. _ACEOF
  7265. if ac_fn_c_try_link "$LINENO"; then :
  7266. lt_aix_libpath_sed='
  7267. /Import File Strings/,/^$/ {
  7268. /^0/ {
  7269. s/^0 *\([^ ]*\) *$/\1/
  7270. p
  7271. }
  7272. }'
  7273. lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
  7274. # Check for a 64-bit object if we didn't find anything.
  7275. if test -z "$lt_cv_aix_libpath_"; then
  7276. lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
  7277. fi
  7278. fi
  7279. rm -f core conftest.err conftest.$ac_objext \
  7280. conftest$ac_exeext conftest.$ac_ext
  7281. if test -z "$lt_cv_aix_libpath_"; then
  7282. lt_cv_aix_libpath_="/usr/lib:/lib"
  7283. fi
  7284. fi
  7285. aix_libpath=$lt_cv_aix_libpath_
  7286. fi
  7287. hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  7288. # Warning - without using the other run time loading flags,
  7289. # -berok will link without error, but may produce a broken library.
  7290. no_undefined_flag=' ${wl}-bernotok'
  7291. allow_undefined_flag=' ${wl}-berok'
  7292. if test "$with_gnu_ld" = yes; then
  7293. # We only use this code for GNU lds that support --whole-archive.
  7294. whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
  7295. else
  7296. # Exported symbols can be pulled into shared objects from archives
  7297. whole_archive_flag_spec='$convenience'
  7298. fi
  7299. archive_cmds_need_lc=yes
  7300. # This is similar to how AIX traditionally builds its shared libraries.
  7301. archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
  7302. fi
  7303. fi
  7304. ;;
  7305. amigaos*)
  7306. case $host_cpu in
  7307. powerpc)
  7308. # see comment about AmigaOS4 .so support
  7309. archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  7310. archive_expsym_cmds=''
  7311. ;;
  7312. m68k)
  7313. archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
  7314. hardcode_libdir_flag_spec='-L$libdir'
  7315. hardcode_minus_L=yes
  7316. ;;
  7317. esac
  7318. ;;
  7319. bsdi[45]*)
  7320. export_dynamic_flag_spec=-rdynamic
  7321. ;;
  7322. cygwin* | mingw* | pw32* | cegcc*)
  7323. # When not using gcc, we currently assume that we are using
  7324. # Microsoft Visual C++.
  7325. # hardcode_libdir_flag_spec is actually meaningless, as there is
  7326. # no search path for DLLs.
  7327. case $cc_basename in
  7328. cl*)
  7329. # Native MSVC
  7330. hardcode_libdir_flag_spec=' '
  7331. allow_undefined_flag=unsupported
  7332. always_export_symbols=yes
  7333. file_list_spec='@'
  7334. # Tell ltmain to make .lib files, not .a files.
  7335. libext=lib
  7336. # Tell ltmain to make .dll files, not .so files.
  7337. shrext_cmds=".dll"
  7338. # FIXME: Setting linknames here is a bad hack.
  7339. archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
  7340. archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
  7341. sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
  7342. else
  7343. sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
  7344. fi~
  7345. $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
  7346. linknames='
  7347. # The linker will not automatically build a static lib if we build a DLL.
  7348. # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
  7349. enable_shared_with_static_runtimes=yes
  7350. exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
  7351. export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
  7352. # Don't use ranlib
  7353. old_postinstall_cmds='chmod 644 $oldlib'
  7354. postlink_cmds='lt_outputfile="@OUTPUT@"~
  7355. lt_tool_outputfile="@TOOL_OUTPUT@"~
  7356. case $lt_outputfile in
  7357. *.exe|*.EXE) ;;
  7358. *)
  7359. lt_outputfile="$lt_outputfile.exe"
  7360. lt_tool_outputfile="$lt_tool_outputfile.exe"
  7361. ;;
  7362. esac~
  7363. if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
  7364. $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
  7365. $RM "$lt_outputfile.manifest";
  7366. fi'
  7367. ;;
  7368. *)
  7369. # Assume MSVC wrapper
  7370. hardcode_libdir_flag_spec=' '
  7371. allow_undefined_flag=unsupported
  7372. # Tell ltmain to make .lib files, not .a files.
  7373. libext=lib
  7374. # Tell ltmain to make .dll files, not .so files.
  7375. shrext_cmds=".dll"
  7376. # FIXME: Setting linknames here is a bad hack.
  7377. archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
  7378. # The linker will automatically build a .lib file if we build a DLL.
  7379. old_archive_from_new_cmds='true'
  7380. # FIXME: Should let the user specify the lib program.
  7381. old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
  7382. enable_shared_with_static_runtimes=yes
  7383. ;;
  7384. esac
  7385. ;;
  7386. darwin* | rhapsody*)
  7387. archive_cmds_need_lc=no
  7388. hardcode_direct=no
  7389. hardcode_automatic=yes
  7390. hardcode_shlibpath_var=unsupported
  7391. if test "$lt_cv_ld_force_load" = "yes"; then
  7392. whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
  7393. else
  7394. whole_archive_flag_spec=''
  7395. fi
  7396. link_all_deplibs=yes
  7397. allow_undefined_flag="$_lt_dar_allow_undefined"
  7398. case $cc_basename in
  7399. ifort*) _lt_dar_can_shared=yes ;;
  7400. *) _lt_dar_can_shared=$GCC ;;
  7401. esac
  7402. if test "$_lt_dar_can_shared" = "yes"; then
  7403. output_verbose_link_cmd=func_echo_all
  7404. archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
  7405. module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
  7406. archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
  7407. module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
  7408. else
  7409. ld_shlibs=no
  7410. fi
  7411. ;;
  7412. dgux*)
  7413. archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  7414. hardcode_libdir_flag_spec='-L$libdir'
  7415. hardcode_shlibpath_var=no
  7416. ;;
  7417. # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
  7418. # support. Future versions do this automatically, but an explicit c++rt0.o
  7419. # does not break anything, and helps significantly (at the cost of a little
  7420. # extra space).
  7421. freebsd2.2*)
  7422. archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
  7423. hardcode_libdir_flag_spec='-R$libdir'
  7424. hardcode_direct=yes
  7425. hardcode_shlibpath_var=no
  7426. ;;
  7427. # Unfortunately, older versions of FreeBSD 2 do not have this feature.
  7428. freebsd2.*)
  7429. archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  7430. hardcode_direct=yes
  7431. hardcode_minus_L=yes
  7432. hardcode_shlibpath_var=no
  7433. ;;
  7434. # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
  7435. freebsd* | dragonfly*)
  7436. archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  7437. hardcode_libdir_flag_spec='-R$libdir'
  7438. hardcode_direct=yes
  7439. hardcode_shlibpath_var=no
  7440. ;;
  7441. hpux9*)
  7442. if test "$GCC" = yes; then
  7443. archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
  7444. else
  7445. archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
  7446. fi
  7447. hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
  7448. hardcode_libdir_separator=:
  7449. hardcode_direct=yes
  7450. # hardcode_minus_L: Not really in the search PATH,
  7451. # but as the default location of the library.
  7452. hardcode_minus_L=yes
  7453. export_dynamic_flag_spec='${wl}-E'
  7454. ;;
  7455. hpux10*)
  7456. if test "$GCC" = yes && test "$with_gnu_ld" = no; then
  7457. archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
  7458. else
  7459. archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
  7460. fi
  7461. if test "$with_gnu_ld" = no; then
  7462. hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
  7463. hardcode_libdir_separator=:
  7464. hardcode_direct=yes
  7465. hardcode_direct_absolute=yes
  7466. export_dynamic_flag_spec='${wl}-E'
  7467. # hardcode_minus_L: Not really in the search PATH,
  7468. # but as the default location of the library.
  7469. hardcode_minus_L=yes
  7470. fi
  7471. ;;
  7472. hpux11*)
  7473. if test "$GCC" = yes && test "$with_gnu_ld" = no; then
  7474. case $host_cpu in
  7475. hppa*64*)
  7476. archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  7477. ;;
  7478. ia64*)
  7479. archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
  7480. ;;
  7481. *)
  7482. archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
  7483. ;;
  7484. esac
  7485. else
  7486. case $host_cpu in
  7487. hppa*64*)
  7488. archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  7489. ;;
  7490. ia64*)
  7491. archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
  7492. ;;
  7493. *)
  7494. # Older versions of the 11.00 compiler do not understand -b yet
  7495. # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
  7496. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
  7497. $as_echo_n "checking if $CC understands -b... " >&6; }
  7498. if ${lt_cv_prog_compiler__b+:} false; then :
  7499. $as_echo_n "(cached) " >&6
  7500. else
  7501. lt_cv_prog_compiler__b=no
  7502. save_LDFLAGS="$LDFLAGS"
  7503. LDFLAGS="$LDFLAGS -b"
  7504. echo "$lt_simple_link_test_code" > conftest.$ac_ext
  7505. if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
  7506. # The linker can only warn and ignore the option if not recognized
  7507. # So say no if there are warnings
  7508. if test -s conftest.err; then
  7509. # Append any errors to the config.log.
  7510. cat conftest.err 1>&5
  7511. $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
  7512. $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
  7513. if diff conftest.exp conftest.er2 >/dev/null; then
  7514. lt_cv_prog_compiler__b=yes
  7515. fi
  7516. else
  7517. lt_cv_prog_compiler__b=yes
  7518. fi
  7519. fi
  7520. $RM -r conftest*
  7521. LDFLAGS="$save_LDFLAGS"
  7522. fi
  7523. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
  7524. $as_echo "$lt_cv_prog_compiler__b" >&6; }
  7525. if test x"$lt_cv_prog_compiler__b" = xyes; then
  7526. archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
  7527. else
  7528. archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
  7529. fi
  7530. ;;
  7531. esac
  7532. fi
  7533. if test "$with_gnu_ld" = no; then
  7534. hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
  7535. hardcode_libdir_separator=:
  7536. case $host_cpu in
  7537. hppa*64*|ia64*)
  7538. hardcode_direct=no
  7539. hardcode_shlibpath_var=no
  7540. ;;
  7541. *)
  7542. hardcode_direct=yes
  7543. hardcode_direct_absolute=yes
  7544. export_dynamic_flag_spec='${wl}-E'
  7545. # hardcode_minus_L: Not really in the search PATH,
  7546. # but as the default location of the library.
  7547. hardcode_minus_L=yes
  7548. ;;
  7549. esac
  7550. fi
  7551. ;;
  7552. irix5* | irix6* | nonstopux*)
  7553. if test "$GCC" = yes; then
  7554. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  7555. # Try to use the -exported_symbol ld option, if it does not
  7556. # work, assume that -exports_file does not work either and
  7557. # implicitly export all symbols.
  7558. # This should be the same for all languages, so no per-tag cache variable.
  7559. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
  7560. $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
  7561. if ${lt_cv_irix_exported_symbol+:} false; then :
  7562. $as_echo_n "(cached) " >&6
  7563. else
  7564. save_LDFLAGS="$LDFLAGS"
  7565. LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
  7566. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7567. /* end confdefs.h. */
  7568. int foo (void) { return 0; }
  7569. _ACEOF
  7570. if ac_fn_c_try_link "$LINENO"; then :
  7571. lt_cv_irix_exported_symbol=yes
  7572. else
  7573. lt_cv_irix_exported_symbol=no
  7574. fi
  7575. rm -f core conftest.err conftest.$ac_objext \
  7576. conftest$ac_exeext conftest.$ac_ext
  7577. LDFLAGS="$save_LDFLAGS"
  7578. fi
  7579. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
  7580. $as_echo "$lt_cv_irix_exported_symbol" >&6; }
  7581. if test "$lt_cv_irix_exported_symbol" = yes; then
  7582. archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
  7583. fi
  7584. else
  7585. archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  7586. archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
  7587. fi
  7588. archive_cmds_need_lc='no'
  7589. hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  7590. hardcode_libdir_separator=:
  7591. inherit_rpath=yes
  7592. link_all_deplibs=yes
  7593. ;;
  7594. netbsd* | netbsdelf*-gnu)
  7595. if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
  7596. archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
  7597. else
  7598. archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
  7599. fi
  7600. hardcode_libdir_flag_spec='-R$libdir'
  7601. hardcode_direct=yes
  7602. hardcode_shlibpath_var=no
  7603. ;;
  7604. newsos6)
  7605. archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  7606. hardcode_direct=yes
  7607. hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  7608. hardcode_libdir_separator=:
  7609. hardcode_shlibpath_var=no
  7610. ;;
  7611. *nto* | *qnx*)
  7612. ;;
  7613. openbsd*)
  7614. if test -f /usr/libexec/ld.so; then
  7615. hardcode_direct=yes
  7616. hardcode_shlibpath_var=no
  7617. hardcode_direct_absolute=yes
  7618. if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  7619. archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  7620. archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
  7621. hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
  7622. export_dynamic_flag_spec='${wl}-E'
  7623. else
  7624. case $host_os in
  7625. openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
  7626. archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  7627. hardcode_libdir_flag_spec='-R$libdir'
  7628. ;;
  7629. *)
  7630. archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  7631. hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
  7632. ;;
  7633. esac
  7634. fi
  7635. else
  7636. ld_shlibs=no
  7637. fi
  7638. ;;
  7639. os2*)
  7640. hardcode_libdir_flag_spec='-L$libdir'
  7641. hardcode_minus_L=yes
  7642. allow_undefined_flag=unsupported
  7643. archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
  7644. old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
  7645. ;;
  7646. osf3*)
  7647. if test "$GCC" = yes; then
  7648. allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
  7649. archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  7650. else
  7651. allow_undefined_flag=' -expect_unresolved \*'
  7652. archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  7653. fi
  7654. archive_cmds_need_lc='no'
  7655. hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  7656. hardcode_libdir_separator=:
  7657. ;;
  7658. osf4* | osf5*) # as osf3* with the addition of -msym flag
  7659. if test "$GCC" = yes; then
  7660. allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
  7661. archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  7662. hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  7663. else
  7664. allow_undefined_flag=' -expect_unresolved \*'
  7665. archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  7666. archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
  7667. $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
  7668. # Both c and cxx compiler support -rpath directly
  7669. hardcode_libdir_flag_spec='-rpath $libdir'
  7670. fi
  7671. archive_cmds_need_lc='no'
  7672. hardcode_libdir_separator=:
  7673. ;;
  7674. solaris*)
  7675. no_undefined_flag=' -z defs'
  7676. if test "$GCC" = yes; then
  7677. wlarc='${wl}'
  7678. archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  7679. archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  7680. $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
  7681. else
  7682. case `$CC -V 2>&1` in
  7683. *"Compilers 5.0"*)
  7684. wlarc=''
  7685. archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
  7686. archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  7687. $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
  7688. ;;
  7689. *)
  7690. wlarc='${wl}'
  7691. archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
  7692. archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  7693. $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
  7694. ;;
  7695. esac
  7696. fi
  7697. hardcode_libdir_flag_spec='-R$libdir'
  7698. hardcode_shlibpath_var=no
  7699. case $host_os in
  7700. solaris2.[0-5] | solaris2.[0-5].*) ;;
  7701. *)
  7702. # The compiler driver will combine and reorder linker options,
  7703. # but understands `-z linker_flag'. GCC discards it without `$wl',
  7704. # but is careful enough not to reorder.
  7705. # Supported since Solaris 2.6 (maybe 2.5.1?)
  7706. if test "$GCC" = yes; then
  7707. whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
  7708. else
  7709. whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
  7710. fi
  7711. ;;
  7712. esac
  7713. link_all_deplibs=yes
  7714. ;;
  7715. sunos4*)
  7716. if test "x$host_vendor" = xsequent; then
  7717. # Use $CC to link under sequent, because it throws in some extra .o
  7718. # files that make .init and .fini sections work.
  7719. archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
  7720. else
  7721. archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
  7722. fi
  7723. hardcode_libdir_flag_spec='-L$libdir'
  7724. hardcode_direct=yes
  7725. hardcode_minus_L=yes
  7726. hardcode_shlibpath_var=no
  7727. ;;
  7728. sysv4)
  7729. case $host_vendor in
  7730. sni)
  7731. archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  7732. hardcode_direct=yes # is this really true???
  7733. ;;
  7734. siemens)
  7735. ## LD is ld it makes a PLAMLIB
  7736. ## CC just makes a GrossModule.
  7737. archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
  7738. reload_cmds='$CC -r -o $output$reload_objs'
  7739. hardcode_direct=no
  7740. ;;
  7741. motorola)
  7742. archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  7743. hardcode_direct=no #Motorola manual says yes, but my tests say they lie
  7744. ;;
  7745. esac
  7746. runpath_var='LD_RUN_PATH'
  7747. hardcode_shlibpath_var=no
  7748. ;;
  7749. sysv4.3*)
  7750. archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  7751. hardcode_shlibpath_var=no
  7752. export_dynamic_flag_spec='-Bexport'
  7753. ;;
  7754. sysv4*MP*)
  7755. if test -d /usr/nec; then
  7756. archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  7757. hardcode_shlibpath_var=no
  7758. runpath_var=LD_RUN_PATH
  7759. hardcode_runpath_var=yes
  7760. ld_shlibs=yes
  7761. fi
  7762. ;;
  7763. sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
  7764. no_undefined_flag='${wl}-z,text'
  7765. archive_cmds_need_lc=no
  7766. hardcode_shlibpath_var=no
  7767. runpath_var='LD_RUN_PATH'
  7768. if test "$GCC" = yes; then
  7769. archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  7770. archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  7771. else
  7772. archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  7773. archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  7774. fi
  7775. ;;
  7776. sysv5* | sco3.2v5* | sco5v6*)
  7777. # Note: We can NOT use -z defs as we might desire, because we do not
  7778. # link with -lc, and that would cause any symbols used from libc to
  7779. # always be unresolved, which means just about no library would
  7780. # ever link correctly. If we're not using GNU ld we use -z text
  7781. # though, which does catch some bad symbols but isn't as heavy-handed
  7782. # as -z defs.
  7783. no_undefined_flag='${wl}-z,text'
  7784. allow_undefined_flag='${wl}-z,nodefs'
  7785. archive_cmds_need_lc=no
  7786. hardcode_shlibpath_var=no
  7787. hardcode_libdir_flag_spec='${wl}-R,$libdir'
  7788. hardcode_libdir_separator=':'
  7789. link_all_deplibs=yes
  7790. export_dynamic_flag_spec='${wl}-Bexport'
  7791. runpath_var='LD_RUN_PATH'
  7792. if test "$GCC" = yes; then
  7793. archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  7794. archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  7795. else
  7796. archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  7797. archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  7798. fi
  7799. ;;
  7800. uts4*)
  7801. archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  7802. hardcode_libdir_flag_spec='-L$libdir'
  7803. hardcode_shlibpath_var=no
  7804. ;;
  7805. *)
  7806. ld_shlibs=no
  7807. ;;
  7808. esac
  7809. if test x$host_vendor = xsni; then
  7810. case $host in
  7811. sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
  7812. export_dynamic_flag_spec='${wl}-Blargedynsym'
  7813. ;;
  7814. esac
  7815. fi
  7816. fi
  7817. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
  7818. $as_echo "$ld_shlibs" >&6; }
  7819. test "$ld_shlibs" = no && can_build_shared=no
  7820. with_gnu_ld=$with_gnu_ld
  7821. #
  7822. # Do we need to explicitly link libc?
  7823. #
  7824. case "x$archive_cmds_need_lc" in
  7825. x|xyes)
  7826. # Assume -lc should be added
  7827. archive_cmds_need_lc=yes
  7828. if test "$enable_shared" = yes && test "$GCC" = yes; then
  7829. case $archive_cmds in
  7830. *'~'*)
  7831. # FIXME: we may have to deal with multi-command sequences.
  7832. ;;
  7833. '$CC '*)
  7834. # Test whether the compiler implicitly links with -lc since on some
  7835. # systems, -lgcc has to come before -lc. If gcc already passes -lc
  7836. # to ld, don't add -lc before -lgcc.
  7837. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
  7838. $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
  7839. if ${lt_cv_archive_cmds_need_lc+:} false; then :
  7840. $as_echo_n "(cached) " >&6
  7841. else
  7842. $RM conftest*
  7843. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  7844. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
  7845. (eval $ac_compile) 2>&5
  7846. ac_status=$?
  7847. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  7848. test $ac_status = 0; } 2>conftest.err; then
  7849. soname=conftest
  7850. lib=conftest
  7851. libobjs=conftest.$ac_objext
  7852. deplibs=
  7853. wl=$lt_prog_compiler_wl
  7854. pic_flag=$lt_prog_compiler_pic
  7855. compiler_flags=-v
  7856. linker_flags=-v
  7857. verstring=
  7858. output_objdir=.
  7859. libname=conftest
  7860. lt_save_allow_undefined_flag=$allow_undefined_flag
  7861. allow_undefined_flag=
  7862. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
  7863. (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
  7864. ac_status=$?
  7865. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  7866. test $ac_status = 0; }
  7867. then
  7868. lt_cv_archive_cmds_need_lc=no
  7869. else
  7870. lt_cv_archive_cmds_need_lc=yes
  7871. fi
  7872. allow_undefined_flag=$lt_save_allow_undefined_flag
  7873. else
  7874. cat conftest.err 1>&5
  7875. fi
  7876. $RM conftest*
  7877. fi
  7878. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
  7879. $as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
  7880. archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
  7881. ;;
  7882. esac
  7883. fi
  7884. ;;
  7885. esac
  7886. { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
  7887. $as_echo_n "checking dynamic linker characteristics... " >&6; }
  7888. if test "$GCC" = yes; then
  7889. case $host_os in
  7890. darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
  7891. *) lt_awk_arg="/^libraries:/" ;;
  7892. esac
  7893. case $host_os in
  7894. mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
  7895. *) lt_sed_strip_eq="s,=/,/,g" ;;
  7896. esac
  7897. lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
  7898. case $lt_search_path_spec in
  7899. *\;*)
  7900. # if the path contains ";" then we assume it to be the separator
  7901. # otherwise default to the standard path separator (i.e. ":") - it is
  7902. # assumed that no part of a normal pathname contains ";" but that should
  7903. # okay in the real world where ";" in dirpaths is itself problematic.
  7904. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
  7905. ;;
  7906. *)
  7907. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
  7908. ;;
  7909. esac
  7910. # Ok, now we have the path, separated by spaces, we can step through it
  7911. # and add multilib dir if necessary.
  7912. lt_tmp_lt_search_path_spec=
  7913. lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
  7914. for lt_sys_path in $lt_search_path_spec; do
  7915. if test -d "$lt_sys_path/$lt_multi_os_dir"; then
  7916. lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
  7917. else
  7918. test -d "$lt_sys_path" && \
  7919. lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
  7920. fi
  7921. done
  7922. lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
  7923. BEGIN {RS=" "; FS="/|\n";} {
  7924. lt_foo="";
  7925. lt_count=0;
  7926. for (lt_i = NF; lt_i > 0; lt_i--) {
  7927. if ($lt_i != "" && $lt_i != ".") {
  7928. if ($lt_i == "..") {
  7929. lt_count++;
  7930. } else {
  7931. if (lt_count == 0) {
  7932. lt_foo="/" $lt_i lt_foo;
  7933. } else {
  7934. lt_count--;
  7935. }
  7936. }
  7937. }
  7938. }
  7939. if (lt_foo != "") { lt_freq[lt_foo]++; }
  7940. if (lt_freq[lt_foo] == 1) { print lt_foo; }
  7941. }'`
  7942. # AWK program above erroneously prepends '/' to C:/dos/paths
  7943. # for these hosts.
  7944. case $host_os in
  7945. mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
  7946. $SED 's,/\([A-Za-z]:\),\1,g'` ;;
  7947. esac
  7948. sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
  7949. else
  7950. sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
  7951. fi
  7952. library_names_spec=
  7953. libname_spec='lib$name'
  7954. soname_spec=
  7955. shrext_cmds=".so"
  7956. postinstall_cmds=
  7957. postuninstall_cmds=
  7958. finish_cmds=
  7959. finish_eval=
  7960. shlibpath_var=
  7961. shlibpath_overrides_runpath=unknown
  7962. version_type=none
  7963. dynamic_linker="$host_os ld.so"
  7964. sys_lib_dlsearch_path_spec="/lib /usr/lib"
  7965. need_lib_prefix=unknown
  7966. hardcode_into_libs=no
  7967. # when you set need_version to no, make sure it does not cause -set_version
  7968. # flags to be left without arguments
  7969. need_version=unknown
  7970. case $host_os in
  7971. aix3*)
  7972. version_type=linux # correct to gnu/linux during the next big refactor
  7973. library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
  7974. shlibpath_var=LIBPATH
  7975. # AIX 3 has no versioning support, so we append a major version to the name.
  7976. soname_spec='${libname}${release}${shared_ext}$major'
  7977. ;;
  7978. aix[4-9]*)
  7979. version_type=linux # correct to gnu/linux during the next big refactor
  7980. need_lib_prefix=no
  7981. need_version=no
  7982. hardcode_into_libs=yes
  7983. if test "$host_cpu" = ia64; then
  7984. # AIX 5 supports IA64
  7985. library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
  7986. shlibpath_var=LD_LIBRARY_PATH
  7987. else
  7988. # With GCC up to 2.95.x, collect2 would create an import file
  7989. # for dependence libraries. The import file would start with
  7990. # the line `#! .'. This would cause the generated library to
  7991. # depend on `.', always an invalid library. This was fixed in
  7992. # development snapshots of GCC prior to 3.0.
  7993. case $host_os in
  7994. aix4 | aix4.[01] | aix4.[01].*)
  7995. if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
  7996. echo ' yes '
  7997. echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
  7998. :
  7999. else
  8000. can_build_shared=no
  8001. fi
  8002. ;;
  8003. esac
  8004. # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
  8005. # soname into executable. Probably we can add versioning support to
  8006. # collect2, so additional links can be useful in future.
  8007. if test "$aix_use_runtimelinking" = yes; then
  8008. # If using run time linking (on AIX 4.2 or later) use lib<name>.so
  8009. # instead of lib<name>.a to let people know that these are not
  8010. # typical AIX shared libraries.
  8011. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8012. else
  8013. # We preserve .a as extension for shared libraries through AIX4.2
  8014. # and later when we are not doing run time linking.
  8015. library_names_spec='${libname}${release}.a $libname.a'
  8016. soname_spec='${libname}${release}${shared_ext}$major'
  8017. fi
  8018. shlibpath_var=LIBPATH
  8019. fi
  8020. ;;
  8021. amigaos*)
  8022. case $host_cpu in
  8023. powerpc)
  8024. # Since July 2007 AmigaOS4 officially supports .so libraries.
  8025. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
  8026. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8027. ;;
  8028. m68k)
  8029. library_names_spec='$libname.ixlibrary $libname.a'
  8030. # Create ${libname}_ixlibrary.a entries in /sys/libs.
  8031. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
  8032. ;;
  8033. esac
  8034. ;;
  8035. beos*)
  8036. library_names_spec='${libname}${shared_ext}'
  8037. dynamic_linker="$host_os ld.so"
  8038. shlibpath_var=LIBRARY_PATH
  8039. ;;
  8040. bsdi[45]*)
  8041. version_type=linux # correct to gnu/linux during the next big refactor
  8042. need_version=no
  8043. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8044. soname_spec='${libname}${release}${shared_ext}$major'
  8045. finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
  8046. shlibpath_var=LD_LIBRARY_PATH
  8047. sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
  8048. sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
  8049. # the default ld.so.conf also contains /usr/contrib/lib and
  8050. # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
  8051. # libtool to hard-code these into programs
  8052. ;;
  8053. cygwin* | mingw* | pw32* | cegcc*)
  8054. version_type=windows
  8055. shrext_cmds=".dll"
  8056. need_version=no
  8057. need_lib_prefix=no
  8058. case $GCC,$cc_basename in
  8059. yes,*)
  8060. # gcc
  8061. library_names_spec='$libname.dll.a'
  8062. # DLL is installed to $(libdir)/../bin by postinstall_cmds
  8063. postinstall_cmds='base_file=`basename \${file}`~
  8064. dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
  8065. dldir=$destdir/`dirname \$dlpath`~
  8066. test -d \$dldir || mkdir -p \$dldir~
  8067. $install_prog $dir/$dlname \$dldir/$dlname~
  8068. chmod a+x \$dldir/$dlname~
  8069. if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
  8070. eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
  8071. fi'
  8072. postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
  8073. dlpath=$dir/\$dldll~
  8074. $RM \$dlpath'
  8075. shlibpath_overrides_runpath=yes
  8076. case $host_os in
  8077. cygwin*)
  8078. # Cygwin DLLs use 'cyg' prefix rather than 'lib'
  8079. soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
  8080. sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
  8081. ;;
  8082. mingw* | cegcc*)
  8083. # MinGW DLLs use traditional 'lib' prefix
  8084. soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
  8085. ;;
  8086. pw32*)
  8087. # pw32 DLLs use 'pw' prefix rather than 'lib'
  8088. library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
  8089. ;;
  8090. esac
  8091. dynamic_linker='Win32 ld.exe'
  8092. ;;
  8093. *,cl*)
  8094. # Native MSVC
  8095. libname_spec='$name'
  8096. soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
  8097. library_names_spec='${libname}.dll.lib'
  8098. case $build_os in
  8099. mingw*)
  8100. sys_lib_search_path_spec=
  8101. lt_save_ifs=$IFS
  8102. IFS=';'
  8103. for lt_path in $LIB
  8104. do
  8105. IFS=$lt_save_ifs
  8106. # Let DOS variable expansion print the short 8.3 style file name.
  8107. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
  8108. sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
  8109. done
  8110. IFS=$lt_save_ifs
  8111. # Convert to MSYS style.
  8112. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
  8113. ;;
  8114. cygwin*)
  8115. # Convert to unix form, then to dos form, then back to unix form
  8116. # but this time dos style (no spaces!) so that the unix form looks
  8117. # like /cygdrive/c/PROGRA~1:/cygdr...
  8118. sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
  8119. sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
  8120. sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
  8121. ;;
  8122. *)
  8123. sys_lib_search_path_spec="$LIB"
  8124. if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
  8125. # It is most probably a Windows format PATH.
  8126. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
  8127. else
  8128. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
  8129. fi
  8130. # FIXME: find the short name or the path components, as spaces are
  8131. # common. (e.g. "Program Files" -> "PROGRA~1")
  8132. ;;
  8133. esac
  8134. # DLL is installed to $(libdir)/../bin by postinstall_cmds
  8135. postinstall_cmds='base_file=`basename \${file}`~
  8136. dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
  8137. dldir=$destdir/`dirname \$dlpath`~
  8138. test -d \$dldir || mkdir -p \$dldir~
  8139. $install_prog $dir/$dlname \$dldir/$dlname'
  8140. postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
  8141. dlpath=$dir/\$dldll~
  8142. $RM \$dlpath'
  8143. shlibpath_overrides_runpath=yes
  8144. dynamic_linker='Win32 link.exe'
  8145. ;;
  8146. *)
  8147. # Assume MSVC wrapper
  8148. library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
  8149. dynamic_linker='Win32 ld.exe'
  8150. ;;
  8151. esac
  8152. # FIXME: first we should search . and the directory the executable is in
  8153. shlibpath_var=PATH
  8154. ;;
  8155. darwin* | rhapsody*)
  8156. dynamic_linker="$host_os dyld"
  8157. version_type=darwin
  8158. need_lib_prefix=no
  8159. need_version=no
  8160. library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
  8161. soname_spec='${libname}${release}${major}$shared_ext'
  8162. shlibpath_overrides_runpath=yes
  8163. shlibpath_var=DYLD_LIBRARY_PATH
  8164. shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
  8165. sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
  8166. sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
  8167. ;;
  8168. dgux*)
  8169. version_type=linux # correct to gnu/linux during the next big refactor
  8170. need_lib_prefix=no
  8171. need_version=no
  8172. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
  8173. soname_spec='${libname}${release}${shared_ext}$major'
  8174. shlibpath_var=LD_LIBRARY_PATH
  8175. ;;
  8176. freebsd* | dragonfly*)
  8177. # DragonFly does not have aout. When/if they implement a new
  8178. # versioning mechanism, adjust this.
  8179. if test -x /usr/bin/objformat; then
  8180. objformat=`/usr/bin/objformat`
  8181. else
  8182. case $host_os in
  8183. freebsd[23].*) objformat=aout ;;
  8184. *) objformat=elf ;;
  8185. esac
  8186. fi
  8187. version_type=freebsd-$objformat
  8188. case $version_type in
  8189. freebsd-elf*)
  8190. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
  8191. need_version=no
  8192. need_lib_prefix=no
  8193. ;;
  8194. freebsd-*)
  8195. library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
  8196. need_version=yes
  8197. ;;
  8198. esac
  8199. shlibpath_var=LD_LIBRARY_PATH
  8200. case $host_os in
  8201. freebsd2.*)
  8202. shlibpath_overrides_runpath=yes
  8203. ;;
  8204. freebsd3.[01]* | freebsdelf3.[01]*)
  8205. shlibpath_overrides_runpath=yes
  8206. hardcode_into_libs=yes
  8207. ;;
  8208. freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
  8209. freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
  8210. shlibpath_overrides_runpath=no
  8211. hardcode_into_libs=yes
  8212. ;;
  8213. *) # from 4.6 on, and DragonFly
  8214. shlibpath_overrides_runpath=yes
  8215. hardcode_into_libs=yes
  8216. ;;
  8217. esac
  8218. ;;
  8219. gnu*)
  8220. version_type=linux # correct to gnu/linux during the next big refactor
  8221. need_lib_prefix=no
  8222. need_version=no
  8223. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
  8224. soname_spec='${libname}${release}${shared_ext}$major'
  8225. shlibpath_var=LD_LIBRARY_PATH
  8226. shlibpath_overrides_runpath=no
  8227. hardcode_into_libs=yes
  8228. ;;
  8229. haiku*)
  8230. version_type=linux # correct to gnu/linux during the next big refactor
  8231. need_lib_prefix=no
  8232. need_version=no
  8233. dynamic_linker="$host_os runtime_loader"
  8234. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
  8235. soname_spec='${libname}${release}${shared_ext}$major'
  8236. shlibpath_var=LIBRARY_PATH
  8237. shlibpath_overrides_runpath=yes
  8238. sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
  8239. hardcode_into_libs=yes
  8240. ;;
  8241. hpux9* | hpux10* | hpux11*)
  8242. # Give a soname corresponding to the major version so that dld.sl refuses to
  8243. # link against other versions.
  8244. version_type=sunos
  8245. need_lib_prefix=no
  8246. need_version=no
  8247. case $host_cpu in
  8248. ia64*)
  8249. shrext_cmds='.so'
  8250. hardcode_into_libs=yes
  8251. dynamic_linker="$host_os dld.so"
  8252. shlibpath_var=LD_LIBRARY_PATH
  8253. shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
  8254. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8255. soname_spec='${libname}${release}${shared_ext}$major'
  8256. if test "X$HPUX_IA64_MODE" = X32; then
  8257. sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
  8258. else
  8259. sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
  8260. fi
  8261. sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
  8262. ;;
  8263. hppa*64*)
  8264. shrext_cmds='.sl'
  8265. hardcode_into_libs=yes
  8266. dynamic_linker="$host_os dld.sl"
  8267. shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
  8268. shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
  8269. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8270. soname_spec='${libname}${release}${shared_ext}$major'
  8271. sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
  8272. sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
  8273. ;;
  8274. *)
  8275. shrext_cmds='.sl'
  8276. dynamic_linker="$host_os dld.sl"
  8277. shlibpath_var=SHLIB_PATH
  8278. shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
  8279. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8280. soname_spec='${libname}${release}${shared_ext}$major'
  8281. ;;
  8282. esac
  8283. # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
  8284. postinstall_cmds='chmod 555 $lib'
  8285. # or fails outright, so override atomically:
  8286. install_override_mode=555
  8287. ;;
  8288. interix[3-9]*)
  8289. version_type=linux # correct to gnu/linux during the next big refactor
  8290. need_lib_prefix=no
  8291. need_version=no
  8292. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
  8293. soname_spec='${libname}${release}${shared_ext}$major'
  8294. dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
  8295. shlibpath_var=LD_LIBRARY_PATH
  8296. shlibpath_overrides_runpath=no
  8297. hardcode_into_libs=yes
  8298. ;;
  8299. irix5* | irix6* | nonstopux*)
  8300. case $host_os in
  8301. nonstopux*) version_type=nonstopux ;;
  8302. *)
  8303. if test "$lt_cv_prog_gnu_ld" = yes; then
  8304. version_type=linux # correct to gnu/linux during the next big refactor
  8305. else
  8306. version_type=irix
  8307. fi ;;
  8308. esac
  8309. need_lib_prefix=no
  8310. need_version=no
  8311. soname_spec='${libname}${release}${shared_ext}$major'
  8312. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
  8313. case $host_os in
  8314. irix5* | nonstopux*)
  8315. libsuff= shlibsuff=
  8316. ;;
  8317. *)
  8318. case $LD in # libtool.m4 will add one of these switches to LD
  8319. *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
  8320. libsuff= shlibsuff= libmagic=32-bit;;
  8321. *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
  8322. libsuff=32 shlibsuff=N32 libmagic=N32;;
  8323. *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
  8324. libsuff=64 shlibsuff=64 libmagic=64-bit;;
  8325. *) libsuff= shlibsuff= libmagic=never-match;;
  8326. esac
  8327. ;;
  8328. esac
  8329. shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
  8330. shlibpath_overrides_runpath=no
  8331. sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
  8332. sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
  8333. hardcode_into_libs=yes
  8334. ;;
  8335. # No shared lib support for Linux oldld, aout, or coff.
  8336. linux*oldld* | linux*aout* | linux*coff*)
  8337. dynamic_linker=no
  8338. ;;
  8339. # This must be glibc/ELF.
  8340. linux* | k*bsd*-gnu | kopensolaris*-gnu)
  8341. version_type=linux # correct to gnu/linux during the next big refactor
  8342. need_lib_prefix=no
  8343. need_version=no
  8344. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8345. soname_spec='${libname}${release}${shared_ext}$major'
  8346. finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
  8347. shlibpath_var=LD_LIBRARY_PATH
  8348. shlibpath_overrides_runpath=no
  8349. # Some binutils ld are patched to set DT_RUNPATH
  8350. if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
  8351. $as_echo_n "(cached) " >&6
  8352. else
  8353. lt_cv_shlibpath_overrides_runpath=no
  8354. save_LDFLAGS=$LDFLAGS
  8355. save_libdir=$libdir
  8356. eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
  8357. LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
  8358. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  8359. /* end confdefs.h. */
  8360. int
  8361. main ()
  8362. {
  8363. ;
  8364. return 0;
  8365. }
  8366. _ACEOF
  8367. if ac_fn_c_try_link "$LINENO"; then :
  8368. if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
  8369. lt_cv_shlibpath_overrides_runpath=yes
  8370. fi
  8371. fi
  8372. rm -f core conftest.err conftest.$ac_objext \
  8373. conftest$ac_exeext conftest.$ac_ext
  8374. LDFLAGS=$save_LDFLAGS
  8375. libdir=$save_libdir
  8376. fi
  8377. shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
  8378. # This implies no fast_install, which is unacceptable.
  8379. # Some rework will be needed to allow for fast_install
  8380. # before this can be enabled.
  8381. hardcode_into_libs=yes
  8382. # Append ld.so.conf contents to the search path
  8383. if test -f /etc/ld.so.conf; then
  8384. lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
  8385. sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
  8386. fi
  8387. # We used to test for /lib/ld.so.1 and disable shared libraries on
  8388. # powerpc, because MkLinux only supported shared libraries with the
  8389. # GNU dynamic linker. Since this was broken with cross compilers,
  8390. # most powerpc-linux boxes support dynamic linking these days and
  8391. # people can always --disable-shared, the test was removed, and we
  8392. # assume the GNU/Linux dynamic linker is in use.
  8393. dynamic_linker='GNU/Linux ld.so'
  8394. ;;
  8395. netbsdelf*-gnu)
  8396. version_type=linux
  8397. need_lib_prefix=no
  8398. need_version=no
  8399. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
  8400. soname_spec='${libname}${release}${shared_ext}$major'
  8401. shlibpath_var=LD_LIBRARY_PATH
  8402. shlibpath_overrides_runpath=no
  8403. hardcode_into_libs=yes
  8404. dynamic_linker='NetBSD ld.elf_so'
  8405. ;;
  8406. netbsd*)
  8407. version_type=sunos
  8408. need_lib_prefix=no
  8409. need_version=no
  8410. if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
  8411. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
  8412. finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
  8413. dynamic_linker='NetBSD (a.out) ld.so'
  8414. else
  8415. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
  8416. soname_spec='${libname}${release}${shared_ext}$major'
  8417. dynamic_linker='NetBSD ld.elf_so'
  8418. fi
  8419. shlibpath_var=LD_LIBRARY_PATH
  8420. shlibpath_overrides_runpath=yes
  8421. hardcode_into_libs=yes
  8422. ;;
  8423. newsos6)
  8424. version_type=linux # correct to gnu/linux during the next big refactor
  8425. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8426. shlibpath_var=LD_LIBRARY_PATH
  8427. shlibpath_overrides_runpath=yes
  8428. ;;
  8429. *nto* | *qnx*)
  8430. version_type=qnx
  8431. need_lib_prefix=no
  8432. need_version=no
  8433. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8434. soname_spec='${libname}${release}${shared_ext}$major'
  8435. shlibpath_var=LD_LIBRARY_PATH
  8436. shlibpath_overrides_runpath=no
  8437. hardcode_into_libs=yes
  8438. dynamic_linker='ldqnx.so'
  8439. ;;
  8440. openbsd*)
  8441. version_type=sunos
  8442. sys_lib_dlsearch_path_spec="/usr/lib"
  8443. need_lib_prefix=no
  8444. # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
  8445. case $host_os in
  8446. openbsd3.3 | openbsd3.3.*) need_version=yes ;;
  8447. *) need_version=no ;;
  8448. esac
  8449. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
  8450. finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
  8451. shlibpath_var=LD_LIBRARY_PATH
  8452. if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  8453. case $host_os in
  8454. openbsd2.[89] | openbsd2.[89].*)
  8455. shlibpath_overrides_runpath=no
  8456. ;;
  8457. *)
  8458. shlibpath_overrides_runpath=yes
  8459. ;;
  8460. esac
  8461. else
  8462. shlibpath_overrides_runpath=yes
  8463. fi
  8464. ;;
  8465. os2*)
  8466. libname_spec='$name'
  8467. shrext_cmds=".dll"
  8468. need_lib_prefix=no
  8469. library_names_spec='$libname${shared_ext} $libname.a'
  8470. dynamic_linker='OS/2 ld.exe'
  8471. shlibpath_var=LIBPATH
  8472. ;;
  8473. osf3* | osf4* | osf5*)
  8474. version_type=osf
  8475. need_lib_prefix=no
  8476. need_version=no
  8477. soname_spec='${libname}${release}${shared_ext}$major'
  8478. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8479. shlibpath_var=LD_LIBRARY_PATH
  8480. sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
  8481. sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
  8482. ;;
  8483. rdos*)
  8484. dynamic_linker=no
  8485. ;;
  8486. solaris*)
  8487. version_type=linux # correct to gnu/linux during the next big refactor
  8488. need_lib_prefix=no
  8489. need_version=no
  8490. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8491. soname_spec='${libname}${release}${shared_ext}$major'
  8492. shlibpath_var=LD_LIBRARY_PATH
  8493. shlibpath_overrides_runpath=yes
  8494. hardcode_into_libs=yes
  8495. # ldd complains unless libraries are executable
  8496. postinstall_cmds='chmod +x $lib'
  8497. ;;
  8498. sunos4*)
  8499. version_type=sunos
  8500. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
  8501. finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
  8502. shlibpath_var=LD_LIBRARY_PATH
  8503. shlibpath_overrides_runpath=yes
  8504. if test "$with_gnu_ld" = yes; then
  8505. need_lib_prefix=no
  8506. fi
  8507. need_version=yes
  8508. ;;
  8509. sysv4 | sysv4.3*)
  8510. version_type=linux # correct to gnu/linux during the next big refactor
  8511. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8512. soname_spec='${libname}${release}${shared_ext}$major'
  8513. shlibpath_var=LD_LIBRARY_PATH
  8514. case $host_vendor in
  8515. sni)
  8516. shlibpath_overrides_runpath=no
  8517. need_lib_prefix=no
  8518. runpath_var=LD_RUN_PATH
  8519. ;;
  8520. siemens)
  8521. need_lib_prefix=no
  8522. ;;
  8523. motorola)
  8524. need_lib_prefix=no
  8525. need_version=no
  8526. shlibpath_overrides_runpath=no
  8527. sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
  8528. ;;
  8529. esac
  8530. ;;
  8531. sysv4*MP*)
  8532. if test -d /usr/nec ;then
  8533. version_type=linux # correct to gnu/linux during the next big refactor
  8534. library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
  8535. soname_spec='$libname${shared_ext}.$major'
  8536. shlibpath_var=LD_LIBRARY_PATH
  8537. fi
  8538. ;;
  8539. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
  8540. version_type=freebsd-elf
  8541. need_lib_prefix=no
  8542. need_version=no
  8543. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
  8544. soname_spec='${libname}${release}${shared_ext}$major'
  8545. shlibpath_var=LD_LIBRARY_PATH
  8546. shlibpath_overrides_runpath=yes
  8547. hardcode_into_libs=yes
  8548. if test "$with_gnu_ld" = yes; then
  8549. sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
  8550. else
  8551. sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
  8552. case $host_os in
  8553. sco3.2v5*)
  8554. sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
  8555. ;;
  8556. esac
  8557. fi
  8558. sys_lib_dlsearch_path_spec='/usr/lib'
  8559. ;;
  8560. tpf*)
  8561. # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
  8562. version_type=linux # correct to gnu/linux during the next big refactor
  8563. need_lib_prefix=no
  8564. need_version=no
  8565. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8566. shlibpath_var=LD_LIBRARY_PATH
  8567. shlibpath_overrides_runpath=no
  8568. hardcode_into_libs=yes
  8569. ;;
  8570. uts4*)
  8571. version_type=linux # correct to gnu/linux during the next big refactor
  8572. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  8573. soname_spec='${libname}${release}${shared_ext}$major'
  8574. shlibpath_var=LD_LIBRARY_PATH
  8575. ;;
  8576. *)
  8577. dynamic_linker=no
  8578. ;;
  8579. esac
  8580. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
  8581. $as_echo "$dynamic_linker" >&6; }
  8582. test "$dynamic_linker" = no && can_build_shared=no
  8583. variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
  8584. if test "$GCC" = yes; then
  8585. variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
  8586. fi
  8587. if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
  8588. sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
  8589. fi
  8590. if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
  8591. sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
  8592. fi
  8593. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
  8594. $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
  8595. hardcode_action=
  8596. if test -n "$hardcode_libdir_flag_spec" ||
  8597. test -n "$runpath_var" ||
  8598. test "X$hardcode_automatic" = "Xyes" ; then
  8599. # We can hardcode non-existent directories.
  8600. if test "$hardcode_direct" != no &&
  8601. # If the only mechanism to avoid hardcoding is shlibpath_var, we
  8602. # have to relink, otherwise we might link with an installed library
  8603. # when we should be linking with a yet-to-be-installed one
  8604. ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
  8605. test "$hardcode_minus_L" != no; then
  8606. # Linking always hardcodes the temporary library directory.
  8607. hardcode_action=relink
  8608. else
  8609. # We can link without hardcoding, and we can hardcode nonexisting dirs.
  8610. hardcode_action=immediate
  8611. fi
  8612. else
  8613. # We cannot hardcode anything, or else we can only hardcode existing
  8614. # directories.
  8615. hardcode_action=unsupported
  8616. fi
  8617. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
  8618. $as_echo "$hardcode_action" >&6; }
  8619. if test "$hardcode_action" = relink ||
  8620. test "$inherit_rpath" = yes; then
  8621. # Fast installation is not supported
  8622. enable_fast_install=no
  8623. elif test "$shlibpath_overrides_runpath" = yes ||
  8624. test "$enable_shared" = no; then
  8625. # Fast installation is not necessary
  8626. enable_fast_install=needless
  8627. fi
  8628. if test "x$enable_dlopen" != xyes; then
  8629. enable_dlopen=unknown
  8630. enable_dlopen_self=unknown
  8631. enable_dlopen_self_static=unknown
  8632. else
  8633. lt_cv_dlopen=no
  8634. lt_cv_dlopen_libs=
  8635. case $host_os in
  8636. beos*)
  8637. lt_cv_dlopen="load_add_on"
  8638. lt_cv_dlopen_libs=
  8639. lt_cv_dlopen_self=yes
  8640. ;;
  8641. mingw* | pw32* | cegcc*)
  8642. lt_cv_dlopen="LoadLibrary"
  8643. lt_cv_dlopen_libs=
  8644. ;;
  8645. cygwin*)
  8646. lt_cv_dlopen="dlopen"
  8647. lt_cv_dlopen_libs=
  8648. ;;
  8649. darwin*)
  8650. # if libdl is installed we need to link against it
  8651. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
  8652. $as_echo_n "checking for dlopen in -ldl... " >&6; }
  8653. if ${ac_cv_lib_dl_dlopen+:} false; then :
  8654. $as_echo_n "(cached) " >&6
  8655. else
  8656. ac_check_lib_save_LIBS=$LIBS
  8657. LIBS="-ldl $LIBS"
  8658. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  8659. /* end confdefs.h. */
  8660. /* Override any GCC internal prototype to avoid an error.
  8661. Use char because int might match the return type of a GCC
  8662. builtin and then its argument prototype would still apply. */
  8663. #ifdef __cplusplus
  8664. extern "C"
  8665. #endif
  8666. char dlopen ();
  8667. int
  8668. main ()
  8669. {
  8670. return dlopen ();
  8671. ;
  8672. return 0;
  8673. }
  8674. _ACEOF
  8675. if ac_fn_c_try_link "$LINENO"; then :
  8676. ac_cv_lib_dl_dlopen=yes
  8677. else
  8678. ac_cv_lib_dl_dlopen=no
  8679. fi
  8680. rm -f core conftest.err conftest.$ac_objext \
  8681. conftest$ac_exeext conftest.$ac_ext
  8682. LIBS=$ac_check_lib_save_LIBS
  8683. fi
  8684. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
  8685. $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
  8686. if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
  8687. lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
  8688. else
  8689. lt_cv_dlopen="dyld"
  8690. lt_cv_dlopen_libs=
  8691. lt_cv_dlopen_self=yes
  8692. fi
  8693. ;;
  8694. *)
  8695. ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
  8696. if test "x$ac_cv_func_shl_load" = xyes; then :
  8697. lt_cv_dlopen="shl_load"
  8698. else
  8699. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
  8700. $as_echo_n "checking for shl_load in -ldld... " >&6; }
  8701. if ${ac_cv_lib_dld_shl_load+:} false; then :
  8702. $as_echo_n "(cached) " >&6
  8703. else
  8704. ac_check_lib_save_LIBS=$LIBS
  8705. LIBS="-ldld $LIBS"
  8706. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  8707. /* end confdefs.h. */
  8708. /* Override any GCC internal prototype to avoid an error.
  8709. Use char because int might match the return type of a GCC
  8710. builtin and then its argument prototype would still apply. */
  8711. #ifdef __cplusplus
  8712. extern "C"
  8713. #endif
  8714. char shl_load ();
  8715. int
  8716. main ()
  8717. {
  8718. return shl_load ();
  8719. ;
  8720. return 0;
  8721. }
  8722. _ACEOF
  8723. if ac_fn_c_try_link "$LINENO"; then :
  8724. ac_cv_lib_dld_shl_load=yes
  8725. else
  8726. ac_cv_lib_dld_shl_load=no
  8727. fi
  8728. rm -f core conftest.err conftest.$ac_objext \
  8729. conftest$ac_exeext conftest.$ac_ext
  8730. LIBS=$ac_check_lib_save_LIBS
  8731. fi
  8732. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
  8733. $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
  8734. if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
  8735. lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
  8736. else
  8737. ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
  8738. if test "x$ac_cv_func_dlopen" = xyes; then :
  8739. lt_cv_dlopen="dlopen"
  8740. else
  8741. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
  8742. $as_echo_n "checking for dlopen in -ldl... " >&6; }
  8743. if ${ac_cv_lib_dl_dlopen+:} false; then :
  8744. $as_echo_n "(cached) " >&6
  8745. else
  8746. ac_check_lib_save_LIBS=$LIBS
  8747. LIBS="-ldl $LIBS"
  8748. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  8749. /* end confdefs.h. */
  8750. /* Override any GCC internal prototype to avoid an error.
  8751. Use char because int might match the return type of a GCC
  8752. builtin and then its argument prototype would still apply. */
  8753. #ifdef __cplusplus
  8754. extern "C"
  8755. #endif
  8756. char dlopen ();
  8757. int
  8758. main ()
  8759. {
  8760. return dlopen ();
  8761. ;
  8762. return 0;
  8763. }
  8764. _ACEOF
  8765. if ac_fn_c_try_link "$LINENO"; then :
  8766. ac_cv_lib_dl_dlopen=yes
  8767. else
  8768. ac_cv_lib_dl_dlopen=no
  8769. fi
  8770. rm -f core conftest.err conftest.$ac_objext \
  8771. conftest$ac_exeext conftest.$ac_ext
  8772. LIBS=$ac_check_lib_save_LIBS
  8773. fi
  8774. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
  8775. $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
  8776. if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
  8777. lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
  8778. else
  8779. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
  8780. $as_echo_n "checking for dlopen in -lsvld... " >&6; }
  8781. if ${ac_cv_lib_svld_dlopen+:} false; then :
  8782. $as_echo_n "(cached) " >&6
  8783. else
  8784. ac_check_lib_save_LIBS=$LIBS
  8785. LIBS="-lsvld $LIBS"
  8786. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  8787. /* end confdefs.h. */
  8788. /* Override any GCC internal prototype to avoid an error.
  8789. Use char because int might match the return type of a GCC
  8790. builtin and then its argument prototype would still apply. */
  8791. #ifdef __cplusplus
  8792. extern "C"
  8793. #endif
  8794. char dlopen ();
  8795. int
  8796. main ()
  8797. {
  8798. return dlopen ();
  8799. ;
  8800. return 0;
  8801. }
  8802. _ACEOF
  8803. if ac_fn_c_try_link "$LINENO"; then :
  8804. ac_cv_lib_svld_dlopen=yes
  8805. else
  8806. ac_cv_lib_svld_dlopen=no
  8807. fi
  8808. rm -f core conftest.err conftest.$ac_objext \
  8809. conftest$ac_exeext conftest.$ac_ext
  8810. LIBS=$ac_check_lib_save_LIBS
  8811. fi
  8812. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
  8813. $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
  8814. if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
  8815. lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
  8816. else
  8817. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
  8818. $as_echo_n "checking for dld_link in -ldld... " >&6; }
  8819. if ${ac_cv_lib_dld_dld_link+:} false; then :
  8820. $as_echo_n "(cached) " >&6
  8821. else
  8822. ac_check_lib_save_LIBS=$LIBS
  8823. LIBS="-ldld $LIBS"
  8824. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  8825. /* end confdefs.h. */
  8826. /* Override any GCC internal prototype to avoid an error.
  8827. Use char because int might match the return type of a GCC
  8828. builtin and then its argument prototype would still apply. */
  8829. #ifdef __cplusplus
  8830. extern "C"
  8831. #endif
  8832. char dld_link ();
  8833. int
  8834. main ()
  8835. {
  8836. return dld_link ();
  8837. ;
  8838. return 0;
  8839. }
  8840. _ACEOF
  8841. if ac_fn_c_try_link "$LINENO"; then :
  8842. ac_cv_lib_dld_dld_link=yes
  8843. else
  8844. ac_cv_lib_dld_dld_link=no
  8845. fi
  8846. rm -f core conftest.err conftest.$ac_objext \
  8847. conftest$ac_exeext conftest.$ac_ext
  8848. LIBS=$ac_check_lib_save_LIBS
  8849. fi
  8850. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
  8851. $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
  8852. if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
  8853. lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
  8854. fi
  8855. fi
  8856. fi
  8857. fi
  8858. fi
  8859. fi
  8860. ;;
  8861. esac
  8862. if test "x$lt_cv_dlopen" != xno; then
  8863. enable_dlopen=yes
  8864. else
  8865. enable_dlopen=no
  8866. fi
  8867. case $lt_cv_dlopen in
  8868. dlopen)
  8869. save_CPPFLAGS="$CPPFLAGS"
  8870. test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
  8871. save_LDFLAGS="$LDFLAGS"
  8872. wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
  8873. save_LIBS="$LIBS"
  8874. LIBS="$lt_cv_dlopen_libs $LIBS"
  8875. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
  8876. $as_echo_n "checking whether a program can dlopen itself... " >&6; }
  8877. if ${lt_cv_dlopen_self+:} false; then :
  8878. $as_echo_n "(cached) " >&6
  8879. else
  8880. if test "$cross_compiling" = yes; then :
  8881. lt_cv_dlopen_self=cross
  8882. else
  8883. lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
  8884. lt_status=$lt_dlunknown
  8885. cat > conftest.$ac_ext <<_LT_EOF
  8886. #line $LINENO "configure"
  8887. #include "confdefs.h"
  8888. #if HAVE_DLFCN_H
  8889. #include <dlfcn.h>
  8890. #endif
  8891. #include <stdio.h>
  8892. #ifdef RTLD_GLOBAL
  8893. # define LT_DLGLOBAL RTLD_GLOBAL
  8894. #else
  8895. # ifdef DL_GLOBAL
  8896. # define LT_DLGLOBAL DL_GLOBAL
  8897. # else
  8898. # define LT_DLGLOBAL 0
  8899. # endif
  8900. #endif
  8901. /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
  8902. find out it does not work in some platform. */
  8903. #ifndef LT_DLLAZY_OR_NOW
  8904. # ifdef RTLD_LAZY
  8905. # define LT_DLLAZY_OR_NOW RTLD_LAZY
  8906. # else
  8907. # ifdef DL_LAZY
  8908. # define LT_DLLAZY_OR_NOW DL_LAZY
  8909. # else
  8910. # ifdef RTLD_NOW
  8911. # define LT_DLLAZY_OR_NOW RTLD_NOW
  8912. # else
  8913. # ifdef DL_NOW
  8914. # define LT_DLLAZY_OR_NOW DL_NOW
  8915. # else
  8916. # define LT_DLLAZY_OR_NOW 0
  8917. # endif
  8918. # endif
  8919. # endif
  8920. # endif
  8921. #endif
  8922. /* When -fvisbility=hidden is used, assume the code has been annotated
  8923. correspondingly for the symbols needed. */
  8924. #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
  8925. int fnord () __attribute__((visibility("default")));
  8926. #endif
  8927. int fnord () { return 42; }
  8928. int main ()
  8929. {
  8930. void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
  8931. int status = $lt_dlunknown;
  8932. if (self)
  8933. {
  8934. if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
  8935. else
  8936. {
  8937. if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
  8938. else puts (dlerror ());
  8939. }
  8940. /* dlclose (self); */
  8941. }
  8942. else
  8943. puts (dlerror ());
  8944. return status;
  8945. }
  8946. _LT_EOF
  8947. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
  8948. (eval $ac_link) 2>&5
  8949. ac_status=$?
  8950. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  8951. test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
  8952. (./conftest; exit; ) >&5 2>/dev/null
  8953. lt_status=$?
  8954. case x$lt_status in
  8955. x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
  8956. x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
  8957. x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
  8958. esac
  8959. else :
  8960. # compilation failed
  8961. lt_cv_dlopen_self=no
  8962. fi
  8963. fi
  8964. rm -fr conftest*
  8965. fi
  8966. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
  8967. $as_echo "$lt_cv_dlopen_self" >&6; }
  8968. if test "x$lt_cv_dlopen_self" = xyes; then
  8969. wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
  8970. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
  8971. $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
  8972. if ${lt_cv_dlopen_self_static+:} false; then :
  8973. $as_echo_n "(cached) " >&6
  8974. else
  8975. if test "$cross_compiling" = yes; then :
  8976. lt_cv_dlopen_self_static=cross
  8977. else
  8978. lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
  8979. lt_status=$lt_dlunknown
  8980. cat > conftest.$ac_ext <<_LT_EOF
  8981. #line $LINENO "configure"
  8982. #include "confdefs.h"
  8983. #if HAVE_DLFCN_H
  8984. #include <dlfcn.h>
  8985. #endif
  8986. #include <stdio.h>
  8987. #ifdef RTLD_GLOBAL
  8988. # define LT_DLGLOBAL RTLD_GLOBAL
  8989. #else
  8990. # ifdef DL_GLOBAL
  8991. # define LT_DLGLOBAL DL_GLOBAL
  8992. # else
  8993. # define LT_DLGLOBAL 0
  8994. # endif
  8995. #endif
  8996. /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
  8997. find out it does not work in some platform. */
  8998. #ifndef LT_DLLAZY_OR_NOW
  8999. # ifdef RTLD_LAZY
  9000. # define LT_DLLAZY_OR_NOW RTLD_LAZY
  9001. # else
  9002. # ifdef DL_LAZY
  9003. # define LT_DLLAZY_OR_NOW DL_LAZY
  9004. # else
  9005. # ifdef RTLD_NOW
  9006. # define LT_DLLAZY_OR_NOW RTLD_NOW
  9007. # else
  9008. # ifdef DL_NOW
  9009. # define LT_DLLAZY_OR_NOW DL_NOW
  9010. # else
  9011. # define LT_DLLAZY_OR_NOW 0
  9012. # endif
  9013. # endif
  9014. # endif
  9015. # endif
  9016. #endif
  9017. /* When -fvisbility=hidden is used, assume the code has been annotated
  9018. correspondingly for the symbols needed. */
  9019. #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
  9020. int fnord () __attribute__((visibility("default")));
  9021. #endif
  9022. int fnord () { return 42; }
  9023. int main ()
  9024. {
  9025. void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
  9026. int status = $lt_dlunknown;
  9027. if (self)
  9028. {
  9029. if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
  9030. else
  9031. {
  9032. if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
  9033. else puts (dlerror ());
  9034. }
  9035. /* dlclose (self); */
  9036. }
  9037. else
  9038. puts (dlerror ());
  9039. return status;
  9040. }
  9041. _LT_EOF
  9042. if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
  9043. (eval $ac_link) 2>&5
  9044. ac_status=$?
  9045. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  9046. test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
  9047. (./conftest; exit; ) >&5 2>/dev/null
  9048. lt_status=$?
  9049. case x$lt_status in
  9050. x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
  9051. x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
  9052. x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
  9053. esac
  9054. else :
  9055. # compilation failed
  9056. lt_cv_dlopen_self_static=no
  9057. fi
  9058. fi
  9059. rm -fr conftest*
  9060. fi
  9061. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
  9062. $as_echo "$lt_cv_dlopen_self_static" >&6; }
  9063. fi
  9064. CPPFLAGS="$save_CPPFLAGS"
  9065. LDFLAGS="$save_LDFLAGS"
  9066. LIBS="$save_LIBS"
  9067. ;;
  9068. esac
  9069. case $lt_cv_dlopen_self in
  9070. yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
  9071. *) enable_dlopen_self=unknown ;;
  9072. esac
  9073. case $lt_cv_dlopen_self_static in
  9074. yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
  9075. *) enable_dlopen_self_static=unknown ;;
  9076. esac
  9077. fi
  9078. striplib=
  9079. old_striplib=
  9080. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
  9081. $as_echo_n "checking whether stripping libraries is possible... " >&6; }
  9082. if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
  9083. test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
  9084. test -z "$striplib" && striplib="$STRIP --strip-unneeded"
  9085. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  9086. $as_echo "yes" >&6; }
  9087. else
  9088. # FIXME - insert some real tests, host_os isn't really good enough
  9089. case $host_os in
  9090. darwin*)
  9091. if test -n "$STRIP" ; then
  9092. striplib="$STRIP -x"
  9093. old_striplib="$STRIP -S"
  9094. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  9095. $as_echo "yes" >&6; }
  9096. else
  9097. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  9098. $as_echo "no" >&6; }
  9099. fi
  9100. ;;
  9101. *)
  9102. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  9103. $as_echo "no" >&6; }
  9104. ;;
  9105. esac
  9106. fi
  9107. # Report which library types will actually be built
  9108. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
  9109. $as_echo_n "checking if libtool supports shared libraries... " >&6; }
  9110. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
  9111. $as_echo "$can_build_shared" >&6; }
  9112. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
  9113. $as_echo_n "checking whether to build shared libraries... " >&6; }
  9114. test "$can_build_shared" = "no" && enable_shared=no
  9115. # On AIX, shared libraries and static libraries use the same namespace, and
  9116. # are all built from PIC.
  9117. case $host_os in
  9118. aix3*)
  9119. test "$enable_shared" = yes && enable_static=no
  9120. if test -n "$RANLIB"; then
  9121. archive_cmds="$archive_cmds~\$RANLIB \$lib"
  9122. postinstall_cmds='$RANLIB $lib'
  9123. fi
  9124. ;;
  9125. aix[4-9]*)
  9126. if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
  9127. test "$enable_shared" = yes && enable_static=no
  9128. fi
  9129. ;;
  9130. esac
  9131. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
  9132. $as_echo "$enable_shared" >&6; }
  9133. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
  9134. $as_echo_n "checking whether to build static libraries... " >&6; }
  9135. # Make sure either enable_shared or enable_static is yes.
  9136. test "$enable_shared" = yes || enable_static=yes
  9137. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
  9138. $as_echo "$enable_static" >&6; }
  9139. fi
  9140. ac_ext=c
  9141. ac_cpp='$CPP $CPPFLAGS'
  9142. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  9143. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  9144. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  9145. CC="$lt_save_CC"
  9146. ac_config_commands="$ac_config_commands libtool"
  9147. # Only expand once:
  9148. ac_ext=c
  9149. ac_cpp='$CPP $CPPFLAGS'
  9150. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  9151. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  9152. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  9153. if test -n "$ac_tool_prefix"; then
  9154. # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
  9155. set dummy ${ac_tool_prefix}gcc; ac_word=$2
  9156. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  9157. $as_echo_n "checking for $ac_word... " >&6; }
  9158. if ${ac_cv_prog_CC+:} false; then :
  9159. $as_echo_n "(cached) " >&6
  9160. else
  9161. if test -n "$CC"; then
  9162. ac_cv_prog_CC="$CC" # Let the user override the test.
  9163. else
  9164. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  9165. for as_dir in $PATH
  9166. do
  9167. IFS=$as_save_IFS
  9168. test -z "$as_dir" && as_dir=.
  9169. for ac_exec_ext in '' $ac_executable_extensions; do
  9170. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  9171. ac_cv_prog_CC="${ac_tool_prefix}gcc"
  9172. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  9173. break 2
  9174. fi
  9175. done
  9176. done
  9177. IFS=$as_save_IFS
  9178. fi
  9179. fi
  9180. CC=$ac_cv_prog_CC
  9181. if test -n "$CC"; then
  9182. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  9183. $as_echo "$CC" >&6; }
  9184. else
  9185. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  9186. $as_echo "no" >&6; }
  9187. fi
  9188. fi
  9189. if test -z "$ac_cv_prog_CC"; then
  9190. ac_ct_CC=$CC
  9191. # Extract the first word of "gcc", so it can be a program name with args.
  9192. set dummy gcc; ac_word=$2
  9193. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  9194. $as_echo_n "checking for $ac_word... " >&6; }
  9195. if ${ac_cv_prog_ac_ct_CC+:} false; then :
  9196. $as_echo_n "(cached) " >&6
  9197. else
  9198. if test -n "$ac_ct_CC"; then
  9199. ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
  9200. else
  9201. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  9202. for as_dir in $PATH
  9203. do
  9204. IFS=$as_save_IFS
  9205. test -z "$as_dir" && as_dir=.
  9206. for ac_exec_ext in '' $ac_executable_extensions; do
  9207. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  9208. ac_cv_prog_ac_ct_CC="gcc"
  9209. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  9210. break 2
  9211. fi
  9212. done
  9213. done
  9214. IFS=$as_save_IFS
  9215. fi
  9216. fi
  9217. ac_ct_CC=$ac_cv_prog_ac_ct_CC
  9218. if test -n "$ac_ct_CC"; then
  9219. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
  9220. $as_echo "$ac_ct_CC" >&6; }
  9221. else
  9222. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  9223. $as_echo "no" >&6; }
  9224. fi
  9225. if test "x$ac_ct_CC" = x; then
  9226. CC=""
  9227. else
  9228. case $cross_compiling:$ac_tool_warned in
  9229. yes:)
  9230. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  9231. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  9232. ac_tool_warned=yes ;;
  9233. esac
  9234. CC=$ac_ct_CC
  9235. fi
  9236. else
  9237. CC="$ac_cv_prog_CC"
  9238. fi
  9239. if test -z "$CC"; then
  9240. if test -n "$ac_tool_prefix"; then
  9241. # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
  9242. set dummy ${ac_tool_prefix}cc; ac_word=$2
  9243. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  9244. $as_echo_n "checking for $ac_word... " >&6; }
  9245. if ${ac_cv_prog_CC+:} false; then :
  9246. $as_echo_n "(cached) " >&6
  9247. else
  9248. if test -n "$CC"; then
  9249. ac_cv_prog_CC="$CC" # Let the user override the test.
  9250. else
  9251. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  9252. for as_dir in $PATH
  9253. do
  9254. IFS=$as_save_IFS
  9255. test -z "$as_dir" && as_dir=.
  9256. for ac_exec_ext in '' $ac_executable_extensions; do
  9257. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  9258. ac_cv_prog_CC="${ac_tool_prefix}cc"
  9259. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  9260. break 2
  9261. fi
  9262. done
  9263. done
  9264. IFS=$as_save_IFS
  9265. fi
  9266. fi
  9267. CC=$ac_cv_prog_CC
  9268. if test -n "$CC"; then
  9269. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  9270. $as_echo "$CC" >&6; }
  9271. else
  9272. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  9273. $as_echo "no" >&6; }
  9274. fi
  9275. fi
  9276. fi
  9277. if test -z "$CC"; then
  9278. # Extract the first word of "cc", so it can be a program name with args.
  9279. set dummy cc; ac_word=$2
  9280. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  9281. $as_echo_n "checking for $ac_word... " >&6; }
  9282. if ${ac_cv_prog_CC+:} false; then :
  9283. $as_echo_n "(cached) " >&6
  9284. else
  9285. if test -n "$CC"; then
  9286. ac_cv_prog_CC="$CC" # Let the user override the test.
  9287. else
  9288. ac_prog_rejected=no
  9289. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  9290. for as_dir in $PATH
  9291. do
  9292. IFS=$as_save_IFS
  9293. test -z "$as_dir" && as_dir=.
  9294. for ac_exec_ext in '' $ac_executable_extensions; do
  9295. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  9296. if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
  9297. ac_prog_rejected=yes
  9298. continue
  9299. fi
  9300. ac_cv_prog_CC="cc"
  9301. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  9302. break 2
  9303. fi
  9304. done
  9305. done
  9306. IFS=$as_save_IFS
  9307. if test $ac_prog_rejected = yes; then
  9308. # We found a bogon in the path, so make sure we never use it.
  9309. set dummy $ac_cv_prog_CC
  9310. shift
  9311. if test $# != 0; then
  9312. # We chose a different compiler from the bogus one.
  9313. # However, it has the same basename, so the bogon will be chosen
  9314. # first if we set CC to just the basename; use the full file name.
  9315. shift
  9316. ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
  9317. fi
  9318. fi
  9319. fi
  9320. fi
  9321. CC=$ac_cv_prog_CC
  9322. if test -n "$CC"; then
  9323. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  9324. $as_echo "$CC" >&6; }
  9325. else
  9326. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  9327. $as_echo "no" >&6; }
  9328. fi
  9329. fi
  9330. if test -z "$CC"; then
  9331. if test -n "$ac_tool_prefix"; then
  9332. for ac_prog in cl.exe
  9333. do
  9334. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  9335. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  9336. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  9337. $as_echo_n "checking for $ac_word... " >&6; }
  9338. if ${ac_cv_prog_CC+:} false; then :
  9339. $as_echo_n "(cached) " >&6
  9340. else
  9341. if test -n "$CC"; then
  9342. ac_cv_prog_CC="$CC" # Let the user override the test.
  9343. else
  9344. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  9345. for as_dir in $PATH
  9346. do
  9347. IFS=$as_save_IFS
  9348. test -z "$as_dir" && as_dir=.
  9349. for ac_exec_ext in '' $ac_executable_extensions; do
  9350. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  9351. ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
  9352. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  9353. break 2
  9354. fi
  9355. done
  9356. done
  9357. IFS=$as_save_IFS
  9358. fi
  9359. fi
  9360. CC=$ac_cv_prog_CC
  9361. if test -n "$CC"; then
  9362. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  9363. $as_echo "$CC" >&6; }
  9364. else
  9365. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  9366. $as_echo "no" >&6; }
  9367. fi
  9368. test -n "$CC" && break
  9369. done
  9370. fi
  9371. if test -z "$CC"; then
  9372. ac_ct_CC=$CC
  9373. for ac_prog in cl.exe
  9374. do
  9375. # Extract the first word of "$ac_prog", so it can be a program name with args.
  9376. set dummy $ac_prog; ac_word=$2
  9377. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  9378. $as_echo_n "checking for $ac_word... " >&6; }
  9379. if ${ac_cv_prog_ac_ct_CC+:} false; then :
  9380. $as_echo_n "(cached) " >&6
  9381. else
  9382. if test -n "$ac_ct_CC"; then
  9383. ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
  9384. else
  9385. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  9386. for as_dir in $PATH
  9387. do
  9388. IFS=$as_save_IFS
  9389. test -z "$as_dir" && as_dir=.
  9390. for ac_exec_ext in '' $ac_executable_extensions; do
  9391. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  9392. ac_cv_prog_ac_ct_CC="$ac_prog"
  9393. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  9394. break 2
  9395. fi
  9396. done
  9397. done
  9398. IFS=$as_save_IFS
  9399. fi
  9400. fi
  9401. ac_ct_CC=$ac_cv_prog_ac_ct_CC
  9402. if test -n "$ac_ct_CC"; then
  9403. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
  9404. $as_echo "$ac_ct_CC" >&6; }
  9405. else
  9406. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  9407. $as_echo "no" >&6; }
  9408. fi
  9409. test -n "$ac_ct_CC" && break
  9410. done
  9411. if test "x$ac_ct_CC" = x; then
  9412. CC=""
  9413. else
  9414. case $cross_compiling:$ac_tool_warned in
  9415. yes:)
  9416. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  9417. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  9418. ac_tool_warned=yes ;;
  9419. esac
  9420. CC=$ac_ct_CC
  9421. fi
  9422. fi
  9423. fi
  9424. test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  9425. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  9426. as_fn_error $? "no acceptable C compiler found in \$PATH
  9427. See \`config.log' for more details" "$LINENO" 5; }
  9428. # Provide some information about the compiler.
  9429. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
  9430. set X $ac_compile
  9431. ac_compiler=$2
  9432. for ac_option in --version -v -V -qversion; do
  9433. { { ac_try="$ac_compiler $ac_option >&5"
  9434. case "(($ac_try" in
  9435. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  9436. *) ac_try_echo=$ac_try;;
  9437. esac
  9438. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  9439. $as_echo "$ac_try_echo"; } >&5
  9440. (eval "$ac_compiler $ac_option >&5") 2>conftest.err
  9441. ac_status=$?
  9442. if test -s conftest.err; then
  9443. sed '10a\
  9444. ... rest of stderr output deleted ...
  9445. 10q' conftest.err >conftest.er1
  9446. cat conftest.er1 >&5
  9447. fi
  9448. rm -f conftest.er1 conftest.err
  9449. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  9450. test $ac_status = 0; }
  9451. done
  9452. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
  9453. $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
  9454. if ${ac_cv_c_compiler_gnu+:} false; then :
  9455. $as_echo_n "(cached) " >&6
  9456. else
  9457. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9458. /* end confdefs.h. */
  9459. int
  9460. main ()
  9461. {
  9462. #ifndef __GNUC__
  9463. choke me
  9464. #endif
  9465. ;
  9466. return 0;
  9467. }
  9468. _ACEOF
  9469. if ac_fn_c_try_compile "$LINENO"; then :
  9470. ac_compiler_gnu=yes
  9471. else
  9472. ac_compiler_gnu=no
  9473. fi
  9474. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  9475. ac_cv_c_compiler_gnu=$ac_compiler_gnu
  9476. fi
  9477. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
  9478. $as_echo "$ac_cv_c_compiler_gnu" >&6; }
  9479. if test $ac_compiler_gnu = yes; then
  9480. GCC=yes
  9481. else
  9482. GCC=
  9483. fi
  9484. ac_test_CFLAGS=${CFLAGS+set}
  9485. ac_save_CFLAGS=$CFLAGS
  9486. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
  9487. $as_echo_n "checking whether $CC accepts -g... " >&6; }
  9488. if ${ac_cv_prog_cc_g+:} false; then :
  9489. $as_echo_n "(cached) " >&6
  9490. else
  9491. ac_save_c_werror_flag=$ac_c_werror_flag
  9492. ac_c_werror_flag=yes
  9493. ac_cv_prog_cc_g=no
  9494. CFLAGS="-g"
  9495. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9496. /* end confdefs.h. */
  9497. int
  9498. main ()
  9499. {
  9500. ;
  9501. return 0;
  9502. }
  9503. _ACEOF
  9504. if ac_fn_c_try_compile "$LINENO"; then :
  9505. ac_cv_prog_cc_g=yes
  9506. else
  9507. CFLAGS=""
  9508. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9509. /* end confdefs.h. */
  9510. int
  9511. main ()
  9512. {
  9513. ;
  9514. return 0;
  9515. }
  9516. _ACEOF
  9517. if ac_fn_c_try_compile "$LINENO"; then :
  9518. else
  9519. ac_c_werror_flag=$ac_save_c_werror_flag
  9520. CFLAGS="-g"
  9521. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9522. /* end confdefs.h. */
  9523. int
  9524. main ()
  9525. {
  9526. ;
  9527. return 0;
  9528. }
  9529. _ACEOF
  9530. if ac_fn_c_try_compile "$LINENO"; then :
  9531. ac_cv_prog_cc_g=yes
  9532. fi
  9533. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  9534. fi
  9535. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  9536. fi
  9537. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  9538. ac_c_werror_flag=$ac_save_c_werror_flag
  9539. fi
  9540. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
  9541. $as_echo "$ac_cv_prog_cc_g" >&6; }
  9542. if test "$ac_test_CFLAGS" = set; then
  9543. CFLAGS=$ac_save_CFLAGS
  9544. elif test $ac_cv_prog_cc_g = yes; then
  9545. if test "$GCC" = yes; then
  9546. CFLAGS="-g -O2"
  9547. else
  9548. CFLAGS="-g"
  9549. fi
  9550. else
  9551. if test "$GCC" = yes; then
  9552. CFLAGS="-O2"
  9553. else
  9554. CFLAGS=
  9555. fi
  9556. fi
  9557. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
  9558. $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
  9559. if ${ac_cv_prog_cc_c89+:} false; then :
  9560. $as_echo_n "(cached) " >&6
  9561. else
  9562. ac_cv_prog_cc_c89=no
  9563. ac_save_CC=$CC
  9564. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9565. /* end confdefs.h. */
  9566. #include <stdarg.h>
  9567. #include <stdio.h>
  9568. struct stat;
  9569. /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
  9570. struct buf { int x; };
  9571. FILE * (*rcsopen) (struct buf *, struct stat *, int);
  9572. static char *e (p, i)
  9573. char **p;
  9574. int i;
  9575. {
  9576. return p[i];
  9577. }
  9578. static char *f (char * (*g) (char **, int), char **p, ...)
  9579. {
  9580. char *s;
  9581. va_list v;
  9582. va_start (v,p);
  9583. s = g (p, va_arg (v,int));
  9584. va_end (v);
  9585. return s;
  9586. }
  9587. /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
  9588. function prototypes and stuff, but not '\xHH' hex character constants.
  9589. These don't provoke an error unfortunately, instead are silently treated
  9590. as 'x'. The following induces an error, until -std is added to get
  9591. proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
  9592. array size at least. It's necessary to write '\x00'==0 to get something
  9593. that's true only with -std. */
  9594. int osf4_cc_array ['\x00' == 0 ? 1 : -1];
  9595. /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
  9596. inside strings and character constants. */
  9597. #define FOO(x) 'x'
  9598. int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
  9599. int test (int i, double x);
  9600. struct s1 {int (*f) (int a);};
  9601. struct s2 {int (*f) (double a);};
  9602. int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
  9603. int argc;
  9604. char **argv;
  9605. int
  9606. main ()
  9607. {
  9608. return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
  9609. ;
  9610. return 0;
  9611. }
  9612. _ACEOF
  9613. for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
  9614. -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
  9615. do
  9616. CC="$ac_save_CC $ac_arg"
  9617. if ac_fn_c_try_compile "$LINENO"; then :
  9618. ac_cv_prog_cc_c89=$ac_arg
  9619. fi
  9620. rm -f core conftest.err conftest.$ac_objext
  9621. test "x$ac_cv_prog_cc_c89" != "xno" && break
  9622. done
  9623. rm -f conftest.$ac_ext
  9624. CC=$ac_save_CC
  9625. fi
  9626. # AC_CACHE_VAL
  9627. case "x$ac_cv_prog_cc_c89" in
  9628. x)
  9629. { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
  9630. $as_echo "none needed" >&6; } ;;
  9631. xno)
  9632. { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
  9633. $as_echo "unsupported" >&6; } ;;
  9634. *)
  9635. CC="$CC $ac_cv_prog_cc_c89"
  9636. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
  9637. $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
  9638. esac
  9639. if test "x$ac_cv_prog_cc_c89" != xno; then :
  9640. fi
  9641. ac_ext=c
  9642. ac_cpp='$CPP $CPPFLAGS'
  9643. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  9644. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  9645. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  9646. # Find a good install program. We prefer a C program (faster),
  9647. # so one script is as good as another. But avoid the broken or
  9648. # incompatible versions:
  9649. # SysV /etc/install, /usr/sbin/install
  9650. # SunOS /usr/etc/install
  9651. # IRIX /sbin/install
  9652. # AIX /bin/install
  9653. # AmigaOS /C/install, which installs bootblocks on floppy discs
  9654. # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
  9655. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  9656. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  9657. # OS/2's system install, which has a completely different semantic
  9658. # ./install, which can be erroneously created by make from ./install.sh.
  9659. # Reject install programs that cannot install multiple files.
  9660. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
  9661. $as_echo_n "checking for a BSD-compatible install... " >&6; }
  9662. if test -z "$INSTALL"; then
  9663. if ${ac_cv_path_install+:} false; then :
  9664. $as_echo_n "(cached) " >&6
  9665. else
  9666. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  9667. for as_dir in $PATH
  9668. do
  9669. IFS=$as_save_IFS
  9670. test -z "$as_dir" && as_dir=.
  9671. # Account for people who put trailing slashes in PATH elements.
  9672. case $as_dir/ in #((
  9673. ./ | .// | /[cC]/* | \
  9674. /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
  9675. ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
  9676. /usr/ucb/* ) ;;
  9677. *)
  9678. # OSF1 and SCO ODT 3.0 have their own names for install.
  9679. # Don't use installbsd from OSF since it installs stuff as root
  9680. # by default.
  9681. for ac_prog in ginstall scoinst install; do
  9682. for ac_exec_ext in '' $ac_executable_extensions; do
  9683. if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
  9684. if test $ac_prog = install &&
  9685. grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
  9686. # AIX install. It has an incompatible calling convention.
  9687. :
  9688. elif test $ac_prog = install &&
  9689. grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
  9690. # program-specific install script used by HP pwplus--don't use.
  9691. :
  9692. else
  9693. rm -rf conftest.one conftest.two conftest.dir
  9694. echo one > conftest.one
  9695. echo two > conftest.two
  9696. mkdir conftest.dir
  9697. if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
  9698. test -s conftest.one && test -s conftest.two &&
  9699. test -s conftest.dir/conftest.one &&
  9700. test -s conftest.dir/conftest.two
  9701. then
  9702. ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
  9703. break 3
  9704. fi
  9705. fi
  9706. fi
  9707. done
  9708. done
  9709. ;;
  9710. esac
  9711. done
  9712. IFS=$as_save_IFS
  9713. rm -rf conftest.one conftest.two conftest.dir
  9714. fi
  9715. if test "${ac_cv_path_install+set}" = set; then
  9716. INSTALL=$ac_cv_path_install
  9717. else
  9718. # As a last resort, use the slow shell script. Don't cache a
  9719. # value for INSTALL within a source directory, because that will
  9720. # break other packages using the cache if that directory is
  9721. # removed, or if the value is a relative name.
  9722. INSTALL=$ac_install_sh
  9723. fi
  9724. fi
  9725. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
  9726. $as_echo "$INSTALL" >&6; }
  9727. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  9728. # It thinks the first close brace ends the variable substitution.
  9729. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  9730. test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
  9731. test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  9732. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
  9733. $as_echo_n "checking for ANSI C header files... " >&6; }
  9734. if ${ac_cv_header_stdc+:} false; then :
  9735. $as_echo_n "(cached) " >&6
  9736. else
  9737. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9738. /* end confdefs.h. */
  9739. #include <stdlib.h>
  9740. #include <stdarg.h>
  9741. #include <string.h>
  9742. #include <float.h>
  9743. int
  9744. main ()
  9745. {
  9746. ;
  9747. return 0;
  9748. }
  9749. _ACEOF
  9750. if ac_fn_c_try_compile "$LINENO"; then :
  9751. ac_cv_header_stdc=yes
  9752. else
  9753. ac_cv_header_stdc=no
  9754. fi
  9755. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  9756. if test $ac_cv_header_stdc = yes; then
  9757. # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  9758. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9759. /* end confdefs.h. */
  9760. #include <string.h>
  9761. _ACEOF
  9762. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  9763. $EGREP "memchr" >/dev/null 2>&1; then :
  9764. else
  9765. ac_cv_header_stdc=no
  9766. fi
  9767. rm -f conftest*
  9768. fi
  9769. if test $ac_cv_header_stdc = yes; then
  9770. # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  9771. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9772. /* end confdefs.h. */
  9773. #include <stdlib.h>
  9774. _ACEOF
  9775. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  9776. $EGREP "free" >/dev/null 2>&1; then :
  9777. else
  9778. ac_cv_header_stdc=no
  9779. fi
  9780. rm -f conftest*
  9781. fi
  9782. if test $ac_cv_header_stdc = yes; then
  9783. # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  9784. if test "$cross_compiling" = yes; then :
  9785. :
  9786. else
  9787. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9788. /* end confdefs.h. */
  9789. #include <ctype.h>
  9790. #include <stdlib.h>
  9791. #if ((' ' & 0x0FF) == 0x020)
  9792. # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  9793. # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  9794. #else
  9795. # define ISLOWER(c) \
  9796. (('a' <= (c) && (c) <= 'i') \
  9797. || ('j' <= (c) && (c) <= 'r') \
  9798. || ('s' <= (c) && (c) <= 'z'))
  9799. # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
  9800. #endif
  9801. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  9802. int
  9803. main ()
  9804. {
  9805. int i;
  9806. for (i = 0; i < 256; i++)
  9807. if (XOR (islower (i), ISLOWER (i))
  9808. || toupper (i) != TOUPPER (i))
  9809. return 2;
  9810. return 0;
  9811. }
  9812. _ACEOF
  9813. if ac_fn_c_try_run "$LINENO"; then :
  9814. else
  9815. ac_cv_header_stdc=no
  9816. fi
  9817. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  9818. conftest.$ac_objext conftest.beam conftest.$ac_ext
  9819. fi
  9820. fi
  9821. fi
  9822. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
  9823. $as_echo "$ac_cv_header_stdc" >&6; }
  9824. if test $ac_cv_header_stdc = yes; then
  9825. $as_echo "#define STDC_HEADERS 1" >>confdefs.h
  9826. fi
  9827. ac_fn_c_check_func "$LINENO" "symlink" "ac_cv_func_symlink"
  9828. if test "x$ac_cv_func_symlink" = xyes; then :
  9829. CFLAGS="$CFLAGS -DHAVE_SYMLINK"
  9830. fi
  9831. TARGETS=
  9832. # macro that is used to parse a --with-apxs parameter
  9833. GEOTIFF_ENABLED=""
  9834. # ===========================================================================
  9835. # http://www.gnu.org/software/autoconf-archive/ax_compare_version.html
  9836. # ===========================================================================
  9837. #
  9838. # SYNOPSIS
  9839. #
  9840. # AX_COMPARE_VERSION(VERSION_A, OP, VERSION_B, [ACTION-IF-TRUE], [ACTION-IF-FALSE])
  9841. #
  9842. # DESCRIPTION
  9843. #
  9844. # This macro compares two version strings. Due to the various number of
  9845. # minor-version numbers that can exist, and the fact that string
  9846. # comparisons are not compatible with numeric comparisons, this is not
  9847. # necessarily trivial to do in a autoconf script. This macro makes doing
  9848. # these comparisons easy.
  9849. #
  9850. # The six basic comparisons are available, as well as checking equality
  9851. # limited to a certain number of minor-version levels.
  9852. #
  9853. # The operator OP determines what type of comparison to do, and can be one
  9854. # of:
  9855. #
  9856. # eq - equal (test A == B)
  9857. # ne - not equal (test A != B)
  9858. # le - less than or equal (test A <= B)
  9859. # ge - greater than or equal (test A >= B)
  9860. # lt - less than (test A < B)
  9861. # gt - greater than (test A > B)
  9862. #
  9863. # Additionally, the eq and ne operator can have a number after it to limit
  9864. # the test to that number of minor versions.
  9865. #
  9866. # eq0 - equal up to the length of the shorter version
  9867. # ne0 - not equal up to the length of the shorter version
  9868. # eqN - equal up to N sub-version levels
  9869. # neN - not equal up to N sub-version levels
  9870. #
  9871. # When the condition is true, shell commands ACTION-IF-TRUE are run,
  9872. # otherwise shell commands ACTION-IF-FALSE are run. The environment
  9873. # variable 'ax_compare_version' is always set to either 'true' or 'false'
  9874. # as well.
  9875. #
  9876. # Examples:
  9877. #
  9878. # AX_COMPARE_VERSION([3.15.7],[lt],[3.15.8])
  9879. # AX_COMPARE_VERSION([3.15],[lt],[3.15.8])
  9880. #
  9881. # would both be true.
  9882. #
  9883. # AX_COMPARE_VERSION([3.15.7],[eq],[3.15.8])
  9884. # AX_COMPARE_VERSION([3.15],[gt],[3.15.8])
  9885. #
  9886. # would both be false.
  9887. #
  9888. # AX_COMPARE_VERSION([3.15.7],[eq2],[3.15.8])
  9889. #
  9890. # would be true because it is only comparing two minor versions.
  9891. #
  9892. # AX_COMPARE_VERSION([3.15.7],[eq0],[3.15])
  9893. #
  9894. # would be true because it is only comparing the lesser number of minor
  9895. # versions of the two values.
  9896. #
  9897. # Note: The characters that separate the version numbers do not matter. An
  9898. # empty string is the same as version 0. OP is evaluated by autoconf, not
  9899. # configure, so must be a string, not a variable.
  9900. #
  9901. # The author would like to acknowledge Guido Draheim whose advice about
  9902. # the m4_case and m4_ifvaln functions make this macro only include the
  9903. # portions necessary to perform the specific comparison specified by the
  9904. # OP argument in the final configure script.
  9905. #
  9906. # LICENSE
  9907. #
  9908. # Copyright (c) 2008 Tim Toolan <toolan@ele.uri.edu>
  9909. #
  9910. # Copying and distribution of this file, with or without modification, are
  9911. # permitted in any medium without royalty provided the copyright notice
  9912. # and this notice are preserved. This file is offered as-is, without any
  9913. # warranty.
  9914. #serial 11
  9915. # ===========================================================================
  9916. # http://www.gnu.org/software/autoconf-archive/ax_path_bdb.html
  9917. # ===========================================================================
  9918. #
  9919. # SYNOPSIS
  9920. #
  9921. # AX_PATH_BDB([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
  9922. #
  9923. # DESCRIPTION
  9924. #
  9925. # This macro finds the latest version of Berkeley DB on the system, and
  9926. # ensures that the header file and library versions match. If
  9927. # MINIMUM-VERSION is specified, it will ensure that the library found is
  9928. # at least that version.
  9929. #
  9930. # It determines the name of the library as well as the path to the header
  9931. # file and library. It will check both the default environment as well as
  9932. # the default Berkeley DB install location. When found, it sets BDB_LIBS,
  9933. # BDB_CPPFLAGS, and BDB_LDFLAGS to the necessary values to add to LIBS,
  9934. # CPPFLAGS, and LDFLAGS, as well as setting BDB_VERSION to the version
  9935. # found. HAVE_DB_H is defined also.
  9936. #
  9937. # The option --with-bdb-dir=DIR can be used to specify a specific Berkeley
  9938. # DB installation to use.
  9939. #
  9940. # An example of it's use is:
  9941. #
  9942. # AX_PATH_BDB([3],[
  9943. # LIBS="$BDB_LIBS $LIBS"
  9944. # LDFLAGS="$BDB_LDFLAGS $LDFLAGS"
  9945. # CPPFLAGS="$CPPFLAGS $BDB_CPPFLAGS"
  9946. # ])
  9947. #
  9948. # which will locate the latest version of Berkeley DB on the system, and
  9949. # ensure that it is version 3.0 or higher.
  9950. #
  9951. # Details: This macro does not use either AC_CHECK_HEADERS or AC_CHECK_LIB
  9952. # because, first, the functions inside the library are sometimes renamed
  9953. # to contain a version code that is only available from the db.h on the
  9954. # system, and second, because it is common to have multiple db.h and libdb
  9955. # files on a system it is important to make sure the ones being used
  9956. # correspond to the same version. Additionally, there are many different
  9957. # possible names for libdb when installed by an OS distribution, and these
  9958. # need to be checked if db.h does not correspond to libdb.
  9959. #
  9960. # When cross compiling, only header versions are verified since it would
  9961. # be difficult to check the library version. Additionally the default
  9962. # Berkeley DB installation locations /usr/local/BerkeleyDB* are not
  9963. # searched for higher versions of the library.
  9964. #
  9965. # The format for the list of library names to search came from the Cyrus
  9966. # IMAP distribution, although they are generated dynamically here, and
  9967. # only for the version found in db.h.
  9968. #
  9969. # The macro AX_COMPARE_VERSION is required to use this macro, and should
  9970. # be available from the Autoconf Macro Archive.
  9971. #
  9972. # The author would like to acknowledge the generous and valuable feedback
  9973. # from Guido Draheim, without which this macro would be far less robust,
  9974. # and have poor and inconsistent cross compilation support.
  9975. #
  9976. # Changes:
  9977. #
  9978. # 1/5/05 applied patch from Rafal Rzepecki to eliminate compiler
  9979. # warning about unused variable, argv
  9980. #
  9981. # LICENSE
  9982. #
  9983. # Copyright (c) 2008 Tim Toolan <toolan@ele.uri.edu>
  9984. #
  9985. # Copying and distribution of this file, with or without modification, are
  9986. # permitted in any medium without royalty provided the copyright notice
  9987. # and this notice are preserved. This file is offered as-is, without any
  9988. # warranty.
  9989. #serial 11
  9990. #############################################################################
  9991. #############################################################################
  9992. #############################################################################
  9993. # Check whether --enable-debug was given.
  9994. if test "${enable_debug+set}" = set; then :
  9995. enableval=$enable_debug;
  9996. else
  9997. enable_debug=no
  9998. fi
  9999. if test "$enable_debug" == "yes"; then
  10000. CFLAGS="$CFLAGS -g -O0 -DDEBUG"
  10001. else
  10002. CFLAGS="-O2 $CFLAGS -DNDEBUG"
  10003. fi
  10004. CFLAGS=$CFLAGS
  10005. # Check whether --enable-version_string was given.
  10006. if test "${enable_version_string+set}" = set; then :
  10007. enableval=$enable_version_string;
  10008. else
  10009. enable_version_string=yes
  10010. fi
  10011. if test "$enable_version_string" != "yes"; then
  10012. MISC_ENABLED="-DDISABLE_VERSION_STRING $MISC_ENABLED"
  10013. fi
  10014. # Check whether --enable-module was given.
  10015. if test "${enable_module+set}" = set; then :
  10016. enableval=$enable_module;
  10017. else
  10018. enable_module=yes
  10019. fi
  10020. if test "$enable_module" == "yes"; then
  10021. # Check whether --with-apxs was given.
  10022. if test "${with_apxs+set}" = set; then :
  10023. withval=$with_apxs;
  10024. else
  10025. with_apxs="yes"
  10026. fi
  10027. if test "$with_apxs" = "yes"; then
  10028. # Extract the first word of "apxs2", so it can be a program name with args.
  10029. set dummy apxs2; ac_word=$2
  10030. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10031. $as_echo_n "checking for $ac_word... " >&6; }
  10032. if ${ac_cv_path_APXS+:} false; then :
  10033. $as_echo_n "(cached) " >&6
  10034. else
  10035. case $APXS in
  10036. [\\/]* | ?:[\\/]*)
  10037. ac_cv_path_APXS="$APXS" # Let the user override the test with a path.
  10038. ;;
  10039. *)
  10040. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10041. for as_dir in $PATH
  10042. do
  10043. IFS=$as_save_IFS
  10044. test -z "$as_dir" && as_dir=.
  10045. for ac_exec_ext in '' $ac_executable_extensions; do
  10046. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10047. ac_cv_path_APXS="$as_dir/$ac_word$ac_exec_ext"
  10048. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10049. break 2
  10050. fi
  10051. done
  10052. done
  10053. IFS=$as_save_IFS
  10054. ;;
  10055. esac
  10056. fi
  10057. APXS=$ac_cv_path_APXS
  10058. if test -n "$APXS"; then
  10059. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APXS" >&5
  10060. $as_echo "$APXS" >&6; }
  10061. else
  10062. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10063. $as_echo "no" >&6; }
  10064. fi
  10065. if test -z "$APXS"; then
  10066. # Extract the first word of "apxs", so it can be a program name with args.
  10067. set dummy apxs; ac_word=$2
  10068. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10069. $as_echo_n "checking for $ac_word... " >&6; }
  10070. if ${ac_cv_path_APXS+:} false; then :
  10071. $as_echo_n "(cached) " >&6
  10072. else
  10073. case $APXS in
  10074. [\\/]* | ?:[\\/]*)
  10075. ac_cv_path_APXS="$APXS" # Let the user override the test with a path.
  10076. ;;
  10077. *)
  10078. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10079. for as_dir in $PATH
  10080. do
  10081. IFS=$as_save_IFS
  10082. test -z "$as_dir" && as_dir=.
  10083. for ac_exec_ext in '' $ac_executable_extensions; do
  10084. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10085. ac_cv_path_APXS="$as_dir/$ac_word$ac_exec_ext"
  10086. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10087. break 2
  10088. fi
  10089. done
  10090. done
  10091. IFS=$as_save_IFS
  10092. ;;
  10093. esac
  10094. fi
  10095. APXS=$ac_cv_path_APXS
  10096. if test -n "$APXS"; then
  10097. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APXS" >&5
  10098. $as_echo "$APXS" >&6; }
  10099. else
  10100. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10101. $as_echo "no" >&6; }
  10102. fi
  10103. fi
  10104. elif test "$with_apxs" = "no"; then
  10105. as_fn_error $? "apxs is required and cannot be disabled" "$LINENO" 5
  10106. else
  10107. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apxs usability in $with_apxs" >&5
  10108. $as_echo_n "checking for apxs usability in $with_apxs... " >&6; }
  10109. if test -x "$with_apxs"; then
  10110. APXS=$with_apxs
  10111. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  10112. $as_echo "yes" >&6; }
  10113. else
  10114. as_fn_error $? "$with_apxs not found or not executable" "$LINENO" 5
  10115. fi
  10116. fi
  10117. if test -z "$APXS"; then
  10118. as_fn_error $? "apxs utility not found. use --with-apxs to specify its location." "$LINENO" 5
  10119. fi
  10120. APACHE_SBINDIR=`$APXS -q SBINDIR`
  10121. APACHE_BINDIR=`$APXS -q BINDIR`
  10122. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apachectl utility" >&5
  10123. $as_echo_n "checking for apachectl utility... " >&6; }
  10124. APACHECTL=
  10125. if test -x "$APACHE_SBINDIR/apachectl" ; then
  10126. APACHECTL="$APACHE_SBINDIR/apachectl"
  10127. else
  10128. if test -x "$APACHE_SBINDIR/apache2ctl" ; then
  10129. APACHECTL="$APACHE_SBINDIR/apache2ctl"
  10130. else
  10131. # Extract the first word of "apachectl", so it can be a program name with args.
  10132. set dummy apachectl; ac_word=$2
  10133. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10134. $as_echo_n "checking for $ac_word... " >&6; }
  10135. if ${ac_cv_path_APACHECTL+:} false; then :
  10136. $as_echo_n "(cached) " >&6
  10137. else
  10138. case $APACHECTL in
  10139. [\\/]* | ?:[\\/]*)
  10140. ac_cv_path_APACHECTL="$APACHECTL" # Let the user override the test with a path.
  10141. ;;
  10142. *)
  10143. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10144. for as_dir in $PATH
  10145. do
  10146. IFS=$as_save_IFS
  10147. test -z "$as_dir" && as_dir=.
  10148. for ac_exec_ext in '' $ac_executable_extensions; do
  10149. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10150. ac_cv_path_APACHECTL="$as_dir/$ac_word$ac_exec_ext"
  10151. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10152. break 2
  10153. fi
  10154. done
  10155. done
  10156. IFS=$as_save_IFS
  10157. ;;
  10158. esac
  10159. fi
  10160. APACHECTL=$ac_cv_path_APACHECTL
  10161. if test -n "$APACHECTL"; then
  10162. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APACHECTL" >&5
  10163. $as_echo "$APACHECTL" >&6; }
  10164. else
  10165. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10166. $as_echo "no" >&6; }
  10167. fi
  10168. if test -z "$APACHECTL"; then
  10169. # Extract the first word of "apache2ctl", so it can be a program name with args.
  10170. set dummy apache2ctl; ac_word=$2
  10171. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10172. $as_echo_n "checking for $ac_word... " >&6; }
  10173. if ${ac_cv_path_APACHECTL+:} false; then :
  10174. $as_echo_n "(cached) " >&6
  10175. else
  10176. case $APACHECTL in
  10177. [\\/]* | ?:[\\/]*)
  10178. ac_cv_path_APACHECTL="$APACHECTL" # Let the user override the test with a path.
  10179. ;;
  10180. *)
  10181. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10182. for as_dir in $PATH
  10183. do
  10184. IFS=$as_save_IFS
  10185. test -z "$as_dir" && as_dir=.
  10186. for ac_exec_ext in '' $ac_executable_extensions; do
  10187. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10188. ac_cv_path_APACHECTL="$as_dir/$ac_word$ac_exec_ext"
  10189. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10190. break 2
  10191. fi
  10192. done
  10193. done
  10194. IFS=$as_save_IFS
  10195. ;;
  10196. esac
  10197. fi
  10198. APACHECTL=$ac_cv_path_APACHECTL
  10199. if test -n "$APACHECTL"; then
  10200. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APACHECTL" >&5
  10201. $as_echo "$APACHECTL" >&6; }
  10202. else
  10203. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10204. $as_echo "no" >&6; }
  10205. fi
  10206. fi
  10207. fi
  10208. fi
  10209. if test -z "$APACHECTL"; then
  10210. { $as_echo "$as_me:${as_lineno-$LINENO}: result: Unable to find apachectl utility, you will not be able to restart
  10211. and install module with the created Makefile" >&5
  10212. $as_echo "Unable to find apachectl utility, you will not be able to restart
  10213. and install module with the created Makefile" >&6; }
  10214. else
  10215. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APACHECTL" >&5
  10216. $as_echo "$APACHECTL" >&6; }
  10217. fi
  10218. APXS_INC=-I`$APXS -q INCLUDEDIR`
  10219. APXS_LIBS=`$APXS -q LIBS`
  10220. APXS_LDFLAGS=`$APXS -q LDFLAGS`
  10221. SBINDIR=`$APXS -q SBINDIR`
  10222. TARGET=`$APXS -q TARGET`
  10223. HTTPD="$SBINDIR/$TARGET"
  10224. HTTPD="$HTTPD"
  10225. MODULE_TARGET="mod_mapcache.la"
  10226. else
  10227. MODULE_TARGET=""
  10228. fi
  10229. # Check whether --with-fastcgi was given.
  10230. if test "${with_fastcgi+set}" = set; then :
  10231. withval=$with_fastcgi;
  10232. else
  10233. with_fastcgi=no
  10234. fi
  10235. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable FASTCGI" >&5
  10236. $as_echo_n "checking whether to enable FASTCGI... " >&6; }
  10237. FASTCGI_LIB=''
  10238. FASTCGI_INC=''
  10239. FASTCGI_ENABLED=''
  10240. if test x"$with_fastcgi" == "xno"; then
  10241. { $as_echo "$as_me:${as_lineno-$LINENO}: result: not requested. use --with-fastcgi=dir to enable" >&5
  10242. $as_echo "not requested. use --with-fastcgi=dir to enable" >&6; }
  10243. else
  10244. if test x"$with_fastcgi" != "xyes"; then
  10245. FASTCGI_DIR="$with_fastcgi"
  10246. if test -z "$FASTCGI_DIR" || echo "$FASTCGI_DIR" | grep '^/' >/dev/null ; then
  10247. FASTCGI_DIR="$FASTCGI_DIR"
  10248. else
  10249. FASTCGI_DIR="`pwd`/$FASTCGI_DIR"
  10250. fi
  10251. test -f $FASTCGI_DIR/lib/libfcgi.a -o -f $FASTCGI_DIR/lib/libfcgi.so -o -f $FASTCGI_DIR/lib/libfcgi.sl -o -f $FASTCGI_DIR/lib/libfcgi.dylib && FASTCGI_LIBDIR="$FASTCGI_DIR/lib"
  10252. test -f $FASTCGI_DIR/lib64/libfcgi.a -o -f $FASTCGI_DIR/lib64/libfcgi.so -o -f $FASTCGI_DIR/lib64/libfcgi.sl -o -f $FASTCGI_DIR/libfcgi.dylib && FASTCGI_LIBDIR="$FASTCGI_DIR/lib64"
  10253. test -f $FASTCGI_DIR/libfcgi.a -o -f $FASTCGI_DIR/libfcgi.so -o -f $FASTCGI_DIR/libfcgi.sl -o -f $FASTCGI_DIR/libfcgi.dylib && FASTCGI_LIBDIR="$FASTCGI_DIR"
  10254. test -f $FASTCGI_DIR/include/fcgiapp.h && FASTCGI_INCLUDE="$FASTCGI_DIR/include"
  10255. test -f $FASTCGI_DIR/lib/fcgiapp.h && FASTCGI_INCLUDE="$FASTCGI_DIR/lib"
  10256. test -f $FASTCGI_DIR/fcgiapp.h && FASTCGI_INCLUDE="$FASTCGI_DIR"
  10257. if test -n "$FASTCGI_LIBDIR" ; then
  10258. FASTCGI_LIB="-L$FASTCGI_LIBDIR -lfcgi"
  10259. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using libfastcgi from $FASTCGI_LIB" >&5
  10260. $as_echo "using libfastcgi from $FASTCGI_LIB" >&6; }
  10261. else
  10262. as_fn_error $? "cannot find fastcgi lib in $FASTCGI_DIR" "$LINENO" 5
  10263. fi
  10264. if test -n "$FASTCGI_INCLUDE" ; then
  10265. FASTCGI_INC=-I$FASTCGI_INCLUDE
  10266. FASTCGI_ENABLED="-DUSE_FASTCGI"
  10267. else
  10268. as_fn_error $? "cannot find fastcgi header fcgiapp.h in $FASTCGI_DIR" "$LINENO" 5
  10269. fi
  10270. else
  10271. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FCGI_Accept in -lfcgi" >&5
  10272. $as_echo_n "checking for FCGI_Accept in -lfcgi... " >&6; }
  10273. if ${ac_cv_lib_fcgi_FCGI_Accept+:} false; then :
  10274. $as_echo_n "(cached) " >&6
  10275. else
  10276. ac_check_lib_save_LIBS=$LIBS
  10277. LIBS="-lfcgi $LIBS"
  10278. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10279. /* end confdefs.h. */
  10280. /* Override any GCC internal prototype to avoid an error.
  10281. Use char because int might match the return type of a GCC
  10282. builtin and then its argument prototype would still apply. */
  10283. #ifdef __cplusplus
  10284. extern "C"
  10285. #endif
  10286. char FCGI_Accept ();
  10287. int
  10288. main ()
  10289. {
  10290. return FCGI_Accept ();
  10291. ;
  10292. return 0;
  10293. }
  10294. _ACEOF
  10295. if ac_fn_c_try_link "$LINENO"; then :
  10296. ac_cv_lib_fcgi_FCGI_Accept=yes
  10297. else
  10298. ac_cv_lib_fcgi_FCGI_Accept=no
  10299. fi
  10300. rm -f core conftest.err conftest.$ac_objext \
  10301. conftest$ac_exeext conftest.$ac_ext
  10302. LIBS=$ac_check_lib_save_LIBS
  10303. fi
  10304. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fcgi_FCGI_Accept" >&5
  10305. $as_echo "$ac_cv_lib_fcgi_FCGI_Accept" >&6; }
  10306. if test "x$ac_cv_lib_fcgi_FCGI_Accept" = xyes; then :
  10307. FASTCGI_LIB="-lfcgi"
  10308. else
  10309. as_fn_error $? "cannot find fastcgi lib in system path" "$LINENO" 5
  10310. fi
  10311. ac_fn_c_check_header_mongrel "$LINENO" "fcgi_stdio.h" "ac_cv_header_fcgi_stdio_h" "$ac_includes_default"
  10312. if test "x$ac_cv_header_fcgi_stdio_h" = xyes; then :
  10313. else
  10314. as_fn_error $? "cannot find fastcgi headers in system path" "$LINENO" 5
  10315. fi
  10316. FASTCGI_ENABLED="-DUSE_FASTCGI"
  10317. fi
  10318. fi
  10319. FASTCGI_INC=$FASTCGI_INC
  10320. FASTCGI_LIB=$FASTCGI_LIB
  10321. FASTCGI_ENABLED=$FASTCGI_ENABLED
  10322. # Check whether --with-apr_config was given.
  10323. if test "${with_apr_config+set}" = set; then :
  10324. withval=$with_apr_config;
  10325. else
  10326. with_apr_config=yes
  10327. fi
  10328. if test "$with_apr_config" = "yes"; then
  10329. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apr-config in default locations" >&5
  10330. $as_echo_n "checking for apr-config in default locations... " >&6; }
  10331. if test -n "$APXS"; then
  10332. APXSFULL=`which "$APXS"`
  10333. APXSDIR=`dirname "$APXSFULL"`
  10334. if test -x "$APXSDIR/apr-config"; then
  10335. APRCONFIG="$APXSDIR/apr-config"
  10336. elif test -x "$APACHE_SBINDIR/apr-config"; then
  10337. APRCONFIG="$APACHE_SBINDIR/apr-config"
  10338. elif test -x "$APACHE_BINDIR/apr-config"; then
  10339. APRCONFIG="$APACHE_BINDIR/apr-config"
  10340. elif test -x "$APXSDIR/apr-1-config"; then
  10341. APRCONFIG="$APXSDIR/apr-1-config"
  10342. elif test -x "$APACHE_SBINDIR/apr-1-config"; then
  10343. APRCONFIG="$APACHE_SBINDIR/apr-1-config"
  10344. elif test -x "$APACHE_BINDIR/apr-1-config"; then
  10345. APRCONFIG="$APACHE_BINDIR/apr-1-config"
  10346. fi
  10347. fi
  10348. if test -z "$APRCONFIG"; then
  10349. # Extract the first word of "apr-config", so it can be a program name with args.
  10350. set dummy apr-config; ac_word=$2
  10351. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10352. $as_echo_n "checking for $ac_word... " >&6; }
  10353. if ${ac_cv_path_APRCONFIG+:} false; then :
  10354. $as_echo_n "(cached) " >&6
  10355. else
  10356. case $APRCONFIG in
  10357. [\\/]* | ?:[\\/]*)
  10358. ac_cv_path_APRCONFIG="$APRCONFIG" # Let the user override the test with a path.
  10359. ;;
  10360. *)
  10361. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10362. for as_dir in $PATH
  10363. do
  10364. IFS=$as_save_IFS
  10365. test -z "$as_dir" && as_dir=.
  10366. for ac_exec_ext in '' $ac_executable_extensions; do
  10367. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10368. ac_cv_path_APRCONFIG="$as_dir/$ac_word$ac_exec_ext"
  10369. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10370. break 2
  10371. fi
  10372. done
  10373. done
  10374. IFS=$as_save_IFS
  10375. ;;
  10376. esac
  10377. fi
  10378. APRCONFIG=$ac_cv_path_APRCONFIG
  10379. if test -n "$APRCONFIG"; then
  10380. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APRCONFIG" >&5
  10381. $as_echo "$APRCONFIG" >&6; }
  10382. else
  10383. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10384. $as_echo "no" >&6; }
  10385. fi
  10386. fi
  10387. if test -z "$APRCONFIG"; then
  10388. # Extract the first word of "apr-1-config", so it can be a program name with args.
  10389. set dummy apr-1-config; ac_word=$2
  10390. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10391. $as_echo_n "checking for $ac_word... " >&6; }
  10392. if ${ac_cv_path_APRCONFIG+:} false; then :
  10393. $as_echo_n "(cached) " >&6
  10394. else
  10395. case $APRCONFIG in
  10396. [\\/]* | ?:[\\/]*)
  10397. ac_cv_path_APRCONFIG="$APRCONFIG" # Let the user override the test with a path.
  10398. ;;
  10399. *)
  10400. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10401. for as_dir in $PATH
  10402. do
  10403. IFS=$as_save_IFS
  10404. test -z "$as_dir" && as_dir=.
  10405. for ac_exec_ext in '' $ac_executable_extensions; do
  10406. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10407. ac_cv_path_APRCONFIG="$as_dir/$ac_word$ac_exec_ext"
  10408. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10409. break 2
  10410. fi
  10411. done
  10412. done
  10413. IFS=$as_save_IFS
  10414. ;;
  10415. esac
  10416. fi
  10417. APRCONFIG=$ac_cv_path_APRCONFIG
  10418. if test -n "$APRCONFIG"; then
  10419. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APRCONFIG" >&5
  10420. $as_echo "$APRCONFIG" >&6; }
  10421. else
  10422. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10423. $as_echo "no" >&6; }
  10424. fi
  10425. fi
  10426. if test -n "$APRCONFIG"; then
  10427. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $APRCONFIG, use --with-apr-config=/path/to/apr-(1-)config to modify" >&5
  10428. $as_echo "using $APRCONFIG, use --with-apr-config=/path/to/apr-(1-)config to modify" >&6; }
  10429. else
  10430. { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
  10431. $as_echo "not found" >&6; }
  10432. fi
  10433. elif test "$with_apr_config" = "no"; then
  10434. as_fn_error $? "apr-config is required and cannot be disabled" "$LINENO" 5
  10435. else
  10436. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apr-config usability in $with_apr_config" >&5
  10437. $as_echo_n "checking for apr-config usability in $with_apr_config... " >&6; }
  10438. if test -x "$with_apr_config"; then
  10439. APRCONFIG=$with_apr_config
  10440. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  10441. $as_echo "yes" >&6; }
  10442. else
  10443. as_fn_error $? "$with_apr_config not found or not executable" "$LINENO" 5
  10444. fi
  10445. fi
  10446. if test -z "$APRCONFIG"; then
  10447. as_fn_error $? "apr-config utility not found. use --with-apr-config to specify its location." "$LINENO" 5
  10448. fi
  10449. APR_CFLAGS=`$APRCONFIG --cppflags --cflags`
  10450. APR_INC=`$APRCONFIG --includes`
  10451. APR_INCDIR=`$APRCONFIG --includedir`
  10452. APR_LIBS=`$APRCONFIG --link-libtool`
  10453. APR_LDLIBS=`$APRCONFIG --link-ld`
  10454. # Check whether --with-apu_config was given.
  10455. if test "${with_apu_config+set}" = set; then :
  10456. withval=$with_apu_config;
  10457. else
  10458. with_apu_config=yes
  10459. fi
  10460. if test "$with_apu_config" = "yes"; then
  10461. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apu-config in default locations" >&5
  10462. $as_echo_n "checking for apu-config in default locations... " >&6; }
  10463. if test -n "$APXS"; then
  10464. APXSFULL=`which "$APXS"`
  10465. APXSDIR=`dirname "$APXSFULL"`
  10466. if test -x "$APXSDIR/apu-config"; then
  10467. APUCONFIG="$APXSDIR/apu-config"
  10468. elif test -x "$APACHE_SBINDIR/apu-config"; then
  10469. APUCONFIG="$APACHE_SBINDIR/apu-config"
  10470. elif test -x "$APACHE_BINDIR/apu-config"; then
  10471. APUCONFIG="$APACHE_BINDIR/apu-config"
  10472. elif test -x "$APXSDIR/apu-1-config"; then
  10473. APUCONFIG="$APXSDIR/apu-1-config"
  10474. elif test -x "$APACHE_SBINDIR/apu-1-config"; then
  10475. APUCONFIG="$APACHE_SBINDIR/apu-1-config"
  10476. elif test -x "$APACHE_BINDIR/apu-1-config"; then
  10477. APUCONFIG="$APACHE_BINDIR/apu-1-config"
  10478. fi
  10479. fi
  10480. if test -z "$APUCONFIG"; then
  10481. # Extract the first word of "apu-config", so it can be a program name with args.
  10482. set dummy apu-config; ac_word=$2
  10483. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10484. $as_echo_n "checking for $ac_word... " >&6; }
  10485. if ${ac_cv_path_APUCONFIG+:} false; then :
  10486. $as_echo_n "(cached) " >&6
  10487. else
  10488. case $APUCONFIG in
  10489. [\\/]* | ?:[\\/]*)
  10490. ac_cv_path_APUCONFIG="$APUCONFIG" # Let the user override the test with a path.
  10491. ;;
  10492. *)
  10493. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10494. for as_dir in $PATH
  10495. do
  10496. IFS=$as_save_IFS
  10497. test -z "$as_dir" && as_dir=.
  10498. for ac_exec_ext in '' $ac_executable_extensions; do
  10499. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10500. ac_cv_path_APUCONFIG="$as_dir/$ac_word$ac_exec_ext"
  10501. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10502. break 2
  10503. fi
  10504. done
  10505. done
  10506. IFS=$as_save_IFS
  10507. ;;
  10508. esac
  10509. fi
  10510. APUCONFIG=$ac_cv_path_APUCONFIG
  10511. if test -n "$APUCONFIG"; then
  10512. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APUCONFIG" >&5
  10513. $as_echo "$APUCONFIG" >&6; }
  10514. else
  10515. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10516. $as_echo "no" >&6; }
  10517. fi
  10518. fi
  10519. if test -z "$APUCONFIG"; then
  10520. # Extract the first word of "apu-1-config", so it can be a program name with args.
  10521. set dummy apu-1-config; ac_word=$2
  10522. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10523. $as_echo_n "checking for $ac_word... " >&6; }
  10524. if ${ac_cv_path_APUCONFIG+:} false; then :
  10525. $as_echo_n "(cached) " >&6
  10526. else
  10527. case $APUCONFIG in
  10528. [\\/]* | ?:[\\/]*)
  10529. ac_cv_path_APUCONFIG="$APUCONFIG" # Let the user override the test with a path.
  10530. ;;
  10531. *)
  10532. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10533. for as_dir in $PATH
  10534. do
  10535. IFS=$as_save_IFS
  10536. test -z "$as_dir" && as_dir=.
  10537. for ac_exec_ext in '' $ac_executable_extensions; do
  10538. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10539. ac_cv_path_APUCONFIG="$as_dir/$ac_word$ac_exec_ext"
  10540. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10541. break 2
  10542. fi
  10543. done
  10544. done
  10545. IFS=$as_save_IFS
  10546. ;;
  10547. esac
  10548. fi
  10549. APUCONFIG=$ac_cv_path_APUCONFIG
  10550. if test -n "$APUCONFIG"; then
  10551. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $APUCONFIG" >&5
  10552. $as_echo "$APUCONFIG" >&6; }
  10553. else
  10554. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10555. $as_echo "no" >&6; }
  10556. fi
  10557. fi
  10558. if test -n "$APUCONFIG"; then
  10559. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $APUCONFIG, use --with-apu-config=/path/to/apu-(1-)config to modify" >&5
  10560. $as_echo "using $APUCONFIG, use --with-apu-config=/path/to/apu-(1-)config to modify" >&6; }
  10561. else
  10562. { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
  10563. $as_echo "not found" >&6; }
  10564. fi
  10565. else
  10566. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apu-config usability in $with_apu_config" >&5
  10567. $as_echo_n "checking for apu-config usability in $with_apu_config... " >&6; }
  10568. if test -x "$with_apu_config"; then
  10569. APUCONFIG=$with_apu_config
  10570. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  10571. $as_echo "yes" >&6; }
  10572. else
  10573. as_fn_error $? "$with_apu_config not found or not executable" "$LINENO" 5
  10574. fi
  10575. fi
  10576. if test -z "$APUCONFIG"; then
  10577. as_fn_error $? "apu-config utility not found" "$LINENO" 5
  10578. else
  10579. APU_LIBS=`$APUCONFIG --link-libtool`
  10580. APU_LDLIBS=`$APUCONFIG --link-ld`
  10581. APU_INC=`$APUCONFIG --includes`
  10582. APU_INCDIR=`$APUCONFIG --includedir`
  10583. fi
  10584. # Check whether --enable-memcache was given.
  10585. if test "${enable_memcache+set}" = set; then :
  10586. enableval=$enable_memcache;
  10587. else
  10588. enable_memcache=yes
  10589. fi
  10590. if test "$enable_memcache" == "yes"; then
  10591. if test -z "$APUCONFIG"; then
  10592. as_fn_error $? "memcache check failed: apu-config utility not found" "$LINENO" 5
  10593. fi
  10594. OLDLDFLAGS="$LDFLAGS" ; LDFLAGS="$LDFLAGS `$APUCONFIG --ldflags --libs --link-libtool`"
  10595. OLDCPPFLAGS="$CPPFLAGS" ; CPPFLAGS="$CPPFLAGS `$APUCONFIG --includes`"
  10596. #check we can link against the memcache functions (i.e. is apr-util recent enough)
  10597. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apr_memcache_hash in -laprutil-1" >&5
  10598. $as_echo_n "checking for apr_memcache_hash in -laprutil-1... " >&6; }
  10599. if ${ac_cv_lib_aprutil_1_apr_memcache_hash+:} false; then :
  10600. $as_echo_n "(cached) " >&6
  10601. else
  10602. ac_check_lib_save_LIBS=$LIBS
  10603. LIBS="-laprutil-1 $LIBS"
  10604. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10605. /* end confdefs.h. */
  10606. /* Override any GCC internal prototype to avoid an error.
  10607. Use char because int might match the return type of a GCC
  10608. builtin and then its argument prototype would still apply. */
  10609. #ifdef __cplusplus
  10610. extern "C"
  10611. #endif
  10612. char apr_memcache_hash ();
  10613. int
  10614. main ()
  10615. {
  10616. return apr_memcache_hash ();
  10617. ;
  10618. return 0;
  10619. }
  10620. _ACEOF
  10621. if ac_fn_c_try_link "$LINENO"; then :
  10622. ac_cv_lib_aprutil_1_apr_memcache_hash=yes
  10623. else
  10624. ac_cv_lib_aprutil_1_apr_memcache_hash=no
  10625. fi
  10626. rm -f core conftest.err conftest.$ac_objext \
  10627. conftest$ac_exeext conftest.$ac_ext
  10628. LIBS=$ac_check_lib_save_LIBS
  10629. fi
  10630. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_aprutil_1_apr_memcache_hash" >&5
  10631. $as_echo "$ac_cv_lib_aprutil_1_apr_memcache_hash" >&6; }
  10632. if test "x$ac_cv_lib_aprutil_1_apr_memcache_hash" = xyes; then :
  10633. MEMCACHE_ENABLED=-DUSE_MEMCACHE
  10634. fi
  10635. if test -z "$APU_LIBS"; then
  10636. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apr_memcache_hash in -laprutil" >&5
  10637. $as_echo_n "checking for apr_memcache_hash in -laprutil... " >&6; }
  10638. if ${ac_cv_lib_aprutil_apr_memcache_hash+:} false; then :
  10639. $as_echo_n "(cached) " >&6
  10640. else
  10641. ac_check_lib_save_LIBS=$LIBS
  10642. LIBS="-laprutil $LIBS"
  10643. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10644. /* end confdefs.h. */
  10645. /* Override any GCC internal prototype to avoid an error.
  10646. Use char because int might match the return type of a GCC
  10647. builtin and then its argument prototype would still apply. */
  10648. #ifdef __cplusplus
  10649. extern "C"
  10650. #endif
  10651. char apr_memcache_hash ();
  10652. int
  10653. main ()
  10654. {
  10655. return apr_memcache_hash ();
  10656. ;
  10657. return 0;
  10658. }
  10659. _ACEOF
  10660. if ac_fn_c_try_link "$LINENO"; then :
  10661. ac_cv_lib_aprutil_apr_memcache_hash=yes
  10662. else
  10663. ac_cv_lib_aprutil_apr_memcache_hash=no
  10664. fi
  10665. rm -f core conftest.err conftest.$ac_objext \
  10666. conftest$ac_exeext conftest.$ac_ext
  10667. LIBS=$ac_check_lib_save_LIBS
  10668. fi
  10669. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_aprutil_apr_memcache_hash" >&5
  10670. $as_echo "$ac_cv_lib_aprutil_apr_memcache_hash" >&6; }
  10671. if test "x$ac_cv_lib_aprutil_apr_memcache_hash" = xyes; then :
  10672. MEMCACHE_ENABLED=-DUSE_MEMCACHE
  10673. fi
  10674. fi
  10675. if test -n "$MEMCACHE_ENABLED"; then
  10676. #we managed to link against the memcache functions. are the headers available?
  10677. ac_fn_c_check_header_mongrel "$LINENO" "apr_memcache.h" "ac_cv_header_apr_memcache_h" "$ac_includes_default"
  10678. if test "x$ac_cv_header_apr_memcache_h" = xyes; then :
  10679. else
  10680. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: apr-util contains memcache functions, but the headers where not found. memcache cache backend disabled" >&5
  10681. $as_echo "$as_me: WARNING: apr-util contains memcache functions, but the headers where not found. memcache cache backend disabled" >&2;}
  10682. MEMCACHE_ENABLED=""
  10683. fi
  10684. else
  10685. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: supplied apr-util does not contain memcache functions. memcache cache backend disabled" >&5
  10686. $as_echo "$as_me: WARNING: supplied apr-util does not contain memcache functions. memcache cache backend disabled" >&2;}
  10687. fi
  10688. CPPFLAGS="$OLDCPPFLAGS"
  10689. LDFLAGS="$OLDLDFLAGS"
  10690. fi
  10691. # Check whether --with-sqlite was given.
  10692. if test "${with_sqlite+set}" = set; then :
  10693. withval=$with_sqlite;
  10694. else
  10695. with_sqlite=yes
  10696. fi
  10697. SQLITE_DIR=""
  10698. if test x"$with_sqlite" != "xyes" -a x"$with_sqlite" != "xno"; then
  10699. if test -z "$with_sqlite" || echo "$with_sqlite" | grep '^/' >/dev/null ; then
  10700. SQLITE_DIR="$with_sqlite"
  10701. else
  10702. SQLITE_DIR="`pwd`/$with_sqlite"
  10703. fi
  10704. fi
  10705. SQLITE_LIB=''
  10706. SQLITE_INC=''
  10707. SQLITE_ENABLED=''
  10708. if test -n "$SQLITE_DIR" ; then
  10709. test -f $SQLITE_DIR/lib/libsqlite3.a -o -f $SQLITE_DIR/lib/libsqlite3.so -o -f $SQLITE_DIR/lib/libsqlite3.sl -o -f $SQLITE_DIR/lib/libsqlite3.dylib && SQLITE_LIBDIR="$SQLITE_DIR/lib"
  10710. test -f $SQLITE_DIR/lib64/libsqlite.a -o -f $SQLITE_DIR/lib64/libsqlite3.so -o -f $SQLITE_DIR/lib64/libsqlite3.sl -o -f $SQLITE_DIR/libsqlite3.dylib && SQLITE_LIBDIR="$SQLITE_DIR/lib64"
  10711. test -f $SQLITE_DIR/libsqlite3.a -o -f $SQLITE_DIR/libsqlite3.so -o -f $SQLITE_DIR/libsqlite3.sl -o -f $SQLITE_DIR/libsqlite3.dylib && SQLITE_LIBDIR="$SQLITE_DIR"
  10712. test -f $SQLITE_DIR/include/sqlite3.h && SQLITE_INCLUDE="$SQLITE_DIR/include"
  10713. test -f $SQLITE_DIR/include/sqlite/sqlite3.h && SQLITE_INCLUDE="$SQLITE_DIR/include/sqlite"
  10714. test -f $SQLITE_DIR/lib/sqlite3.h && SQLITE_INCLUDE="$SQLITE_DIR/lib"
  10715. test -f $SQLITE_DIR/sqlite3.h && SQLITE_INCLUDE="$SQLITE_DIR"
  10716. if test -n "$SQLITE_LIBDIR" ; then
  10717. OLDLDFLAGS="$LDFLAGS" ; LDFLAGS="$LDFLAGS -L$SQLITE_LIBDIR -lsqlite3"
  10718. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqlite3_open_v2 in -lsqlite3" >&5
  10719. $as_echo_n "checking for sqlite3_open_v2 in -lsqlite3... " >&6; }
  10720. if ${ac_cv_lib_sqlite3_sqlite3_open_v2+:} false; then :
  10721. $as_echo_n "(cached) " >&6
  10722. else
  10723. ac_check_lib_save_LIBS=$LIBS
  10724. LIBS="-lsqlite3 $LIBS"
  10725. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10726. /* end confdefs.h. */
  10727. /* Override any GCC internal prototype to avoid an error.
  10728. Use char because int might match the return type of a GCC
  10729. builtin and then its argument prototype would still apply. */
  10730. #ifdef __cplusplus
  10731. extern "C"
  10732. #endif
  10733. char sqlite3_open_v2 ();
  10734. int
  10735. main ()
  10736. {
  10737. return sqlite3_open_v2 ();
  10738. ;
  10739. return 0;
  10740. }
  10741. _ACEOF
  10742. if ac_fn_c_try_link "$LINENO"; then :
  10743. ac_cv_lib_sqlite3_sqlite3_open_v2=yes
  10744. else
  10745. ac_cv_lib_sqlite3_sqlite3_open_v2=no
  10746. fi
  10747. rm -f core conftest.err conftest.$ac_objext \
  10748. conftest$ac_exeext conftest.$ac_ext
  10749. LIBS=$ac_check_lib_save_LIBS
  10750. fi
  10751. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_open_v2" >&5
  10752. $as_echo "$ac_cv_lib_sqlite3_sqlite3_open_v2" >&6; }
  10753. if test "x$ac_cv_lib_sqlite3_sqlite3_open_v2" = xyes; then :
  10754. SQLITE_LIB="-L$SQLITE_LIBDIR -lsqlite3"
  10755. fi
  10756. if test -z "$SQLITE_LIB" ; then
  10757. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqlite3_open in -lsqlite3" >&5
  10758. $as_echo_n "checking for sqlite3_open in -lsqlite3... " >&6; }
  10759. if ${ac_cv_lib_sqlite3_sqlite3_open+:} false; then :
  10760. $as_echo_n "(cached) " >&6
  10761. else
  10762. ac_check_lib_save_LIBS=$LIBS
  10763. LIBS="-lsqlite3 $LIBS"
  10764. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10765. /* end confdefs.h. */
  10766. /* Override any GCC internal prototype to avoid an error.
  10767. Use char because int might match the return type of a GCC
  10768. builtin and then its argument prototype would still apply. */
  10769. #ifdef __cplusplus
  10770. extern "C"
  10771. #endif
  10772. char sqlite3_open ();
  10773. int
  10774. main ()
  10775. {
  10776. return sqlite3_open ();
  10777. ;
  10778. return 0;
  10779. }
  10780. _ACEOF
  10781. if ac_fn_c_try_link "$LINENO"; then :
  10782. ac_cv_lib_sqlite3_sqlite3_open=yes
  10783. else
  10784. ac_cv_lib_sqlite3_sqlite3_open=no
  10785. fi
  10786. rm -f core conftest.err conftest.$ac_objext \
  10787. conftest$ac_exeext conftest.$ac_ext
  10788. LIBS=$ac_check_lib_save_LIBS
  10789. fi
  10790. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_open" >&5
  10791. $as_echo "$ac_cv_lib_sqlite3_sqlite3_open" >&6; }
  10792. if test "x$ac_cv_lib_sqlite3_sqlite3_open" = xyes; then :
  10793. as_fn_error $? "SQLITE library found but is too old. Need at least 3.5.0" "$LINENO" 5
  10794. else
  10795. as_fn_error $? "SQLITE (libsqlite3) library cannot be found. install or reconfigure with --with-sqlite=DIR" "$LINENO" 5
  10796. fi
  10797. fi
  10798. LDFLAGS="$OLDLDFLAGS"
  10799. else
  10800. as_fn_error $? "cannot find sqlite lib in $SQLITE_DIR" "$LINENO" 5
  10801. fi
  10802. if test -n "$SQLITE_INCLUDE" ; then
  10803. as_ac_Header=`$as_echo "ac_cv_header_$SQLITE_INCLUDE/sqlite3.h" | $as_tr_sh`
  10804. ac_fn_c_check_header_mongrel "$LINENO" "$SQLITE_INCLUDE/sqlite3.h" "$as_ac_Header" "$ac_includes_default"
  10805. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  10806. SQLITE_INC=-I$SQLITE_INCLUDE
  10807. else
  10808. as_fn_error $? "cannot use sqlite3.h headers from $SQLITE_INCLUDE" "$LINENO" 5
  10809. fi
  10810. else
  10811. as_fn_error $? "cannot find sqlite3.h" "$LINENO" 5
  10812. fi
  10813. SQLITE_ENABLED="-DUSE_SQLITE"
  10814. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using sqlite from $SQLITE_DIR" >&5
  10815. $as_echo "using sqlite from $SQLITE_DIR" >&6; }
  10816. elif test x"$with_sqlite" = "xyes"; then
  10817. ac_fn_c_check_header_mongrel "$LINENO" "sqlite3.h" "ac_cv_header_sqlite3_h" "$ac_includes_default"
  10818. if test "x$ac_cv_header_sqlite3_h" = xyes; then :
  10819. else
  10820. as_fn_error $? "cannot find sqlite3.h header in system path" "$LINENO" 5
  10821. fi
  10822. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqlite3_open_v2 in -lsqlite3" >&5
  10823. $as_echo_n "checking for sqlite3_open_v2 in -lsqlite3... " >&6; }
  10824. if ${ac_cv_lib_sqlite3_sqlite3_open_v2+:} false; then :
  10825. $as_echo_n "(cached) " >&6
  10826. else
  10827. ac_check_lib_save_LIBS=$LIBS
  10828. LIBS="-lsqlite3 $LIBS"
  10829. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10830. /* end confdefs.h. */
  10831. /* Override any GCC internal prototype to avoid an error.
  10832. Use char because int might match the return type of a GCC
  10833. builtin and then its argument prototype would still apply. */
  10834. #ifdef __cplusplus
  10835. extern "C"
  10836. #endif
  10837. char sqlite3_open_v2 ();
  10838. int
  10839. main ()
  10840. {
  10841. return sqlite3_open_v2 ();
  10842. ;
  10843. return 0;
  10844. }
  10845. _ACEOF
  10846. if ac_fn_c_try_link "$LINENO"; then :
  10847. ac_cv_lib_sqlite3_sqlite3_open_v2=yes
  10848. else
  10849. ac_cv_lib_sqlite3_sqlite3_open_v2=no
  10850. fi
  10851. rm -f core conftest.err conftest.$ac_objext \
  10852. conftest$ac_exeext conftest.$ac_ext
  10853. LIBS=$ac_check_lib_save_LIBS
  10854. fi
  10855. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_open_v2" >&5
  10856. $as_echo "$ac_cv_lib_sqlite3_sqlite3_open_v2" >&6; }
  10857. if test "x$ac_cv_lib_sqlite3_sqlite3_open_v2" = xyes; then :
  10858. SQLITE_LIB="-lsqlite3"
  10859. fi
  10860. if test -n "$SQLITE_LIB" ; then
  10861. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using libsqlite3 from system libs." >&5
  10862. $as_echo "using libsqlite3 from system libs." >&6; }
  10863. SQLITE_ENABLED="-DUSE_SQLITE"
  10864. else
  10865. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqlite3_open in -lsqlite3" >&5
  10866. $as_echo_n "checking for sqlite3_open in -lsqlite3... " >&6; }
  10867. if ${ac_cv_lib_sqlite3_sqlite3_open+:} false; then :
  10868. $as_echo_n "(cached) " >&6
  10869. else
  10870. ac_check_lib_save_LIBS=$LIBS
  10871. LIBS="-lsqlite3 $LIBS"
  10872. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10873. /* end confdefs.h. */
  10874. /* Override any GCC internal prototype to avoid an error.
  10875. Use char because int might match the return type of a GCC
  10876. builtin and then its argument prototype would still apply. */
  10877. #ifdef __cplusplus
  10878. extern "C"
  10879. #endif
  10880. char sqlite3_open ();
  10881. int
  10882. main ()
  10883. {
  10884. return sqlite3_open ();
  10885. ;
  10886. return 0;
  10887. }
  10888. _ACEOF
  10889. if ac_fn_c_try_link "$LINENO"; then :
  10890. ac_cv_lib_sqlite3_sqlite3_open=yes
  10891. else
  10892. ac_cv_lib_sqlite3_sqlite3_open=no
  10893. fi
  10894. rm -f core conftest.err conftest.$ac_objext \
  10895. conftest$ac_exeext conftest.$ac_ext
  10896. LIBS=$ac_check_lib_save_LIBS
  10897. fi
  10898. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_open" >&5
  10899. $as_echo "$ac_cv_lib_sqlite3_sqlite3_open" >&6; }
  10900. if test "x$ac_cv_lib_sqlite3_sqlite3_open" = xyes; then :
  10901. as_fn_error $? "SQLITE library found but is too old. Need at least 3.5.0" "$LINENO" 5
  10902. else
  10903. as_fn_error $? "SQLITE (libsqlite3) library cannot be found. install or reconfigure with --with-sqlite=DIR" "$LINENO" 5
  10904. fi
  10905. fi
  10906. else
  10907. { $as_echo "$as_me:${as_lineno-$LINENO}: result: sqlite support disabled by request" >&5
  10908. $as_echo "sqlite support disabled by request" >&6; }
  10909. fi
  10910. SQLITE_INC=$SQLITE_INC
  10911. SQLITE_LIB=$SQLITE_LIB
  10912. SQLITE_ENABLED=$SQLITE_ENABLED
  10913. # Check whether --with-pkg-config was given.
  10914. if test "${with_pkg_config+set}" = set; then :
  10915. withval=$with_pkg_config;
  10916. else
  10917. with_pkg_config=yes
  10918. fi
  10919. if test "$with_pkg_config" = "no"; then
  10920. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pkg-config usability" >&5
  10921. $as_echo_n "checking for pkg-config usability... " >&6; }
  10922. { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled by request" >&5
  10923. $as_echo "disabled by request" >&6; }
  10924. else
  10925. if test "$with_pkg_config" = "yes" ; then
  10926. # Extract the first word of "pkg-config", so it can be a program name with args.
  10927. set dummy pkg-config; ac_word=$2
  10928. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10929. $as_echo_n "checking for $ac_word... " >&6; }
  10930. if ${ac_cv_path_PKGCONFIG+:} false; then :
  10931. $as_echo_n "(cached) " >&6
  10932. else
  10933. case $PKGCONFIG in
  10934. [\\/]* | ?:[\\/]*)
  10935. ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
  10936. ;;
  10937. *)
  10938. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10939. for as_dir in $PATH
  10940. do
  10941. IFS=$as_save_IFS
  10942. test -z "$as_dir" && as_dir=.
  10943. for ac_exec_ext in '' $ac_executable_extensions; do
  10944. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10945. ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
  10946. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10947. break 2
  10948. fi
  10949. done
  10950. done
  10951. IFS=$as_save_IFS
  10952. ;;
  10953. esac
  10954. fi
  10955. PKGCONFIG=$ac_cv_path_PKGCONFIG
  10956. if test -n "$PKGCONFIG"; then
  10957. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
  10958. $as_echo "$PKGCONFIG" >&6; }
  10959. else
  10960. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10961. $as_echo "no" >&6; }
  10962. fi
  10963. else
  10964. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pkg-config usability in $with_pkg_config" >&5
  10965. $as_echo_n "checking for pkg-config usability in $with_pkg_config... " >&6; }
  10966. if test -x "$with_pkg_config"; then
  10967. PKGCONFIG=$with_pkg_config
  10968. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  10969. $as_echo "yes" >&6; }
  10970. else
  10971. as_fn_error $? "$with_pkg_config not found or not executable" "$LINENO" 5
  10972. fi
  10973. fi
  10974. if test -z "$PKGCONFIG"; then
  10975. as_fn_error $? "pkg-config utility not found. use --with-pkg-config to specify its location." "$LINENO" 5
  10976. fi
  10977. fi
  10978. # CAIRO_CHECK
  10979. # Check whether --with-pixman was given.
  10980. if test "${with_pixman+set}" = set; then :
  10981. withval=$with_pixman;
  10982. else
  10983. with_pixman=yes
  10984. fi
  10985. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Pixman" >&5
  10986. $as_echo_n "checking for Pixman... " >&6; }
  10987. if test "$with_pixman" = "no" -o "$with_pixman" = "" ; then
  10988. { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5
  10989. $as_echo "disabled" >&6; }
  10990. PIXMAN_CONFIG="no"
  10991. else
  10992. if test -z "$PKGCONFIG"; then
  10993. as_fn_error $? "pixman support requested, but pkg-config not found/configured" "$LINENO" 5
  10994. fi
  10995. if test "$with_pixman" = "yes" ; then
  10996. { $as_echo "$as_me:${as_lineno-$LINENO}: result: searching default locations" >&5
  10997. $as_echo "searching default locations" >&6; }
  10998. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pixman pkg-config entry" >&5
  10999. $as_echo_n "checking for pixman pkg-config entry... " >&6; }
  11000. `$PKGCONFIG --silence-errors -- pixman >> /dev/null`
  11001. if test $? -eq 0 ; then
  11002. { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
  11003. $as_echo "found" >&6; }
  11004. PIXMAN_CONFIG="pixman"
  11005. else
  11006. `$PKGCONFIG --silence-errors -- pixman-1 >> /dev/null`
  11007. if test $? -eq 0 ; then
  11008. { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
  11009. $as_echo "found" >&6; }
  11010. PIXMAN_CONFIG="pixman-1"
  11011. else
  11012. as_fn_error $? "pixman support requested, but not found.Try installing the pixman development headers" "$LINENO" 5
  11013. fi
  11014. fi
  11015. else
  11016. `$PKGCONFIG $with_pixman`
  11017. if test $? -eq 0 ; then
  11018. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using supplied pkg-config definition $with_pixman" >&5
  11019. $as_echo "using supplied pkg-config definition $with_pixman" >&6; }
  11020. PIXMAN_CONFIG=$with_pixman
  11021. else
  11022. as_fn_error $? "failed to use $with_pixman" "$LINENO" 5
  11023. fi
  11024. fi
  11025. fi
  11026. if test "$PIXMAN_CONFIG" = "no" ; then
  11027. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pixman support has been disabled or could not be configured.
  11028. full WMS will use the internal (usually slower) image merging functions" >&5
  11029. $as_echo "$as_me: WARNING: pixman support has been disabled or could not be configured.
  11030. full WMS will use the internal (usually slower) image merging functions" >&2;}
  11031. PIXMAN_ENABLED=
  11032. PIXMAN_INC=
  11033. PIXMAN_LIB=
  11034. else
  11035. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pixman version is >= 0.13.2" >&5
  11036. $as_echo_n "checking if pixman version is >= 0.13.2... " >&6; }
  11037. PIXMAN_VERSION=`$PKGCONFIG --modversion -- "$PIXMAN_CONFIG"`
  11038. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PIXMAN_VERSION" >&5
  11039. $as_echo "$PIXMAN_VERSION" >&6; }
  11040. `$PKGCONFIG --silence-errors -- "$PIXMAN_CONFIG >= 0.13.2" >> /dev/null`
  11041. if test $? -eq 0 ; then
  11042. PIXMAN_ENABLED="-DUSE_PIXMAN"
  11043. PIXMAN_LIB=`$PKGCONFIG --libs $PIXMAN_CONFIG`
  11044. PIXMAN_INC=`$PKGCONFIG --cflags $PIXMAN_CONFIG`
  11045. else
  11046. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pixman support has been disabled because your version is too old.
  11047. full WMS will use the internal (usually slower) image merging functions" >&5
  11048. $as_echo "$as_me: WARNING: pixman support has been disabled because your version is too old.
  11049. full WMS will use the internal (usually slower) image merging functions" >&2;}
  11050. PIXMAN_ENABLED=
  11051. PIXMAN_INC=
  11052. PIXMAN_LIB=
  11053. fi
  11054. fi
  11055. PIXMAN_ENABLED=$PIXMAN_ENABLED
  11056. PIXMAN_INC=$PIXMAN_INC
  11057. PIXMAN_LIB=$PIXMAN_LIB
  11058. # Check whether --with-png was given.
  11059. if test "${with_png+set}" = set; then :
  11060. withval=$with_png; PNG_DIR=$withval
  11061. else
  11062. PNG_DIR=''
  11063. fi
  11064. if test -z "$PNG_DIR" || echo "$PNG_DIR" | grep '^/' >/dev/null ; then
  11065. PNG_DIR="$PNG_DIR"
  11066. else
  11067. PNG_DIR="`pwd`/$PNG_DIR"
  11068. fi
  11069. { $as_echo "$as_me:${as_lineno-$LINENO}: checking where PNG is installed..." >&5
  11070. $as_echo "$as_me: checking where PNG is installed..." >&6;}
  11071. PNG_LIB=''
  11072. PNG_INC=''
  11073. PNG_FOUND='no'
  11074. if test -n "$PNG_DIR" ; then
  11075. test -f $PNG_DIR/lib/libpng.a -o -f $PNG_DIR/lib/libpng.so -o -f $PNG_DIR/lib/libpng.sl -o -f $PNG_DIR/lib/libpng.dylib && PNG_LIBDIR="$PNG_DIR/lib"
  11076. test -f $PNG_DIR/lib64/libpng.a -o -f $PNG_DIR/lib64/libpng.so -o -f $PNG_DIR/lib64/libpng.sl -o -f $PNG_DIR/libpng.dylib && PNG_LIBDIR="$PNG_DIR/lib64"
  11077. test -f $PNG_DIR/libpng.a -o -f $PNG_DIR/libpng.so -o -f $PNG_DIR/libpng.sl -o -f $PNG_DIR/libpng.dylib && PNG_LIBDIR="$PNG_DIR"
  11078. test -f $PNG_DIR/include/png.h && PNG_INCLUDE="$PNG_DIR/include"
  11079. test -f $PNG_DIR/lib/png.h && PNG_INCLUDE="$PNG_DIR/lib"
  11080. test -f $PNG_DIR/png.h && PNG_INCLUDE="$PNG_DIR"
  11081. if test -n "$PNG_LIBDIR" ; then
  11082. PNG_LIB="-L$PNG_LIBDIR -lpng"
  11083. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using libpng from $PNG_LIB" >&5
  11084. $as_echo " using libpng from $PNG_LIB" >&6; }
  11085. else
  11086. as_fn_error $? "cannot find png lib in $PNG_DIR" "$LINENO" 5
  11087. fi
  11088. if test -n "$PNG_INCLUDE" ; then
  11089. as_ac_Header=`$as_echo "ac_cv_header_$PNG_INCLUDE/png.h" | $as_tr_sh`
  11090. ac_fn_c_check_header_mongrel "$LINENO" "$PNG_INCLUDE/png.h" "$as_ac_Header" "$ac_includes_default"
  11091. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  11092. PNG_INC=-I$PNG_INCLUDE
  11093. else
  11094. as_fn_error $? "cannot find png headers" "$LINENO" 5
  11095. fi
  11096. else
  11097. as_fn_error $? "cannot find png headers in $PNG_DIR" "$LINENO" 5
  11098. fi
  11099. else
  11100. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_init_io in -lpng" >&5
  11101. $as_echo_n "checking for png_init_io in -lpng... " >&6; }
  11102. if ${ac_cv_lib_png_png_init_io+:} false; then :
  11103. $as_echo_n "(cached) " >&6
  11104. else
  11105. ac_check_lib_save_LIBS=$LIBS
  11106. LIBS="-lpng $ZLIB_LIB $LIBS"
  11107. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11108. /* end confdefs.h. */
  11109. /* Override any GCC internal prototype to avoid an error.
  11110. Use char because int might match the return type of a GCC
  11111. builtin and then its argument prototype would still apply. */
  11112. #ifdef __cplusplus
  11113. extern "C"
  11114. #endif
  11115. char png_init_io ();
  11116. int
  11117. main ()
  11118. {
  11119. return png_init_io ();
  11120. ;
  11121. return 0;
  11122. }
  11123. _ACEOF
  11124. if ac_fn_c_try_link "$LINENO"; then :
  11125. ac_cv_lib_png_png_init_io=yes
  11126. else
  11127. ac_cv_lib_png_png_init_io=no
  11128. fi
  11129. rm -f core conftest.err conftest.$ac_objext \
  11130. conftest$ac_exeext conftest.$ac_ext
  11131. LIBS=$ac_check_lib_save_LIBS
  11132. fi
  11133. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_init_io" >&5
  11134. $as_echo "$ac_cv_lib_png_png_init_io" >&6; }
  11135. if test "x$ac_cv_lib_png_png_init_io" = xyes; then :
  11136. PNG_LIB="-lpng"
  11137. fi
  11138. ac_fn_c_check_header_mongrel "$LINENO" "png.h" "ac_cv_header_png_h" "$ac_includes_default"
  11139. if test "x$ac_cv_header_png_h" = xyes; then :
  11140. else
  11141. as_fn_error $? "cannot find png headers in system path" "$LINENO" 5
  11142. fi
  11143. if test -n "$PNG_LIB" ; then
  11144. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using libpng from system libs." >&5
  11145. $as_echo "using libpng from system libs." >&6; }
  11146. else
  11147. as_fn_error $? "PNG (libpng) library cannot be found. install or reconfigure with --with-png=DIR" "$LINENO" 5
  11148. fi
  11149. fi
  11150. ac_fn_c_check_header_mongrel "$LINENO" "setjmp.h" "ac_cv_header_setjmp_h" "$ac_includes_default"
  11151. if test "x$ac_cv_header_setjmp_h" = xyes; then :
  11152. else
  11153. as_fn_error $? "setjmp.h is required with libpng" "$LINENO" 5
  11154. fi
  11155. PNG_INC=$PNG_INC
  11156. PNG_LIB=$PNG_LIB
  11157. # Check whether --with-jpeg was given.
  11158. if test "${with_jpeg+set}" = set; then :
  11159. withval=$with_jpeg; JPEG_DIR=$withval
  11160. else
  11161. JPEG_DIR=''
  11162. fi
  11163. if test -z "$JPEG_DIR" || echo "$JPEG_DIR" | grep '^/' >/dev/null ; then
  11164. JPEG_DIR="$JPEG_DIR"
  11165. else
  11166. JPEG_DIR="`pwd`/$JPEG_DIR"
  11167. fi
  11168. { $as_echo "$as_me:${as_lineno-$LINENO}: checking where JPEG is installed..." >&5
  11169. $as_echo "$as_me: checking where JPEG is installed..." >&6;}
  11170. JPEG_LIB=''
  11171. JPEG_INC=''
  11172. JPEG_FOUND='no'
  11173. if test -n "$JPEG_DIR" ; then
  11174. test -f $JPEG_DIR/lib/libjpeg.a -o -f $JPEG_DIR/lib/libjpeg.so -o -f $JPEG_DIR/lib/libjpeg.sl -o -f $JPEG_DIR/lib/libjpeg.dylib && JPEG_LIBDIR="$JPEG_DIR/lib"
  11175. test -f $JPEG_DIR/lib64/libjpeg.a -o -f $JPEG_DIR/lib64/libjpeg.so -o -f $JPEG_DIR/lib64/libjpeg.sl -o -f $JPEG_DIR/libjpeg.dylib && JPEG_LIBDIR="$JPEG_DIR/lib64"
  11176. test -f $JPEG_DIR/libjpeg.a -o -f $JPEG_DIR/libjpeg.so -o -f $JPEG_DIR/libjpeg.sl -o -f $JPEG_DIR/libjpeg.dylib && JPEG_LIBDIR="$JPEG_DIR"
  11177. test -f $JPEG_DIR/include/jpeglib.h && JPEG_INCLUDE="$JPEG_DIR/include"
  11178. test -f $JPEG_DIR/include/jpeg/jpeglib.h && JPEG_INCLUDE="$JPEG_DIR/include/jpeg"
  11179. test -f $JPEG_DIR/lib/jpeglib.h && JPEG_INCLUDE="$JPEG_DIR/lib"
  11180. test -f $JPEG_DIR/jpeglib.h && JPEG_INCLUDE="$JPEG_DIR"
  11181. if test -n "$JPEG_LIBDIR" ; then
  11182. JPEG_LIB="-L$JPEG_LIBDIR -ljpeg"
  11183. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using libjpeg from $JPEG_LIB" >&5
  11184. $as_echo "using libjpeg from $JPEG_LIB" >&6; }
  11185. else
  11186. as_fn_error $? "cannot find jpeg lib in $JPEG_DIR" "$LINENO" 5
  11187. fi
  11188. if test -n "$JPEG_INCLUDE" ; then
  11189. as_ac_Header=`$as_echo "ac_cv_header_$JPEG_INCLUDE/jpeglib.h" | $as_tr_sh`
  11190. ac_fn_c_check_header_mongrel "$LINENO" "$JPEG_INCLUDE/jpeglib.h" "$as_ac_Header" "$ac_includes_default"
  11191. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  11192. JPEG_INC=-I$JPEG_INCLUDE
  11193. else
  11194. as_fn_error $? "cannot find jpeg headers" "$LINENO" 5
  11195. fi
  11196. else
  11197. as_fn_error $? "cannot find jpeg headers in $JPEG_DIR" "$LINENO" 5
  11198. fi
  11199. else
  11200. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_read_header in -ljpeg" >&5
  11201. $as_echo_n "checking for jpeg_read_header in -ljpeg... " >&6; }
  11202. if ${ac_cv_lib_jpeg_jpeg_read_header+:} false; then :
  11203. $as_echo_n "(cached) " >&6
  11204. else
  11205. ac_check_lib_save_LIBS=$LIBS
  11206. LIBS="-ljpeg $LIBS"
  11207. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11208. /* end confdefs.h. */
  11209. /* Override any GCC internal prototype to avoid an error.
  11210. Use char because int might match the return type of a GCC
  11211. builtin and then its argument prototype would still apply. */
  11212. #ifdef __cplusplus
  11213. extern "C"
  11214. #endif
  11215. char jpeg_read_header ();
  11216. int
  11217. main ()
  11218. {
  11219. return jpeg_read_header ();
  11220. ;
  11221. return 0;
  11222. }
  11223. _ACEOF
  11224. if ac_fn_c_try_link "$LINENO"; then :
  11225. ac_cv_lib_jpeg_jpeg_read_header=yes
  11226. else
  11227. ac_cv_lib_jpeg_jpeg_read_header=no
  11228. fi
  11229. rm -f core conftest.err conftest.$ac_objext \
  11230. conftest$ac_exeext conftest.$ac_ext
  11231. LIBS=$ac_check_lib_save_LIBS
  11232. fi
  11233. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_read_header" >&5
  11234. $as_echo "$ac_cv_lib_jpeg_jpeg_read_header" >&6; }
  11235. if test "x$ac_cv_lib_jpeg_jpeg_read_header" = xyes; then :
  11236. JPEG_LIB="-ljpeg"
  11237. fi
  11238. ac_fn_c_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default"
  11239. if test "x$ac_cv_header_jpeglib_h" = xyes; then :
  11240. else
  11241. as_fn_error $? "cannot find jpeg headers in system path" "$LINENO" 5
  11242. fi
  11243. if test -n "$JPEG_LIB" ; then
  11244. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using libjpeg from system libs." >&5
  11245. $as_echo "using libjpeg from system libs." >&6; }
  11246. else
  11247. as_fn_error $? "JPEG (libjpeg) library cannot be found. install or reconfigure with --with-jpeg=DIR" "$LINENO" 5
  11248. fi
  11249. fi
  11250. JPEG_INC=$JPEG_INC
  11251. JPEG_LIB=$JPEG_LIB
  11252. # Check whether --with-tiff was given.
  11253. if test "${with_tiff+set}" = set; then :
  11254. withval=$with_tiff; TIFF_DIR=$withval
  11255. else
  11256. TIFF_DIR=''
  11257. fi
  11258. if test -z "$TIFF_DIR" || echo "$TIFF_DIR" | grep '^/' >/dev/null ; then
  11259. TIFF_DIR="$TIFF_DIR"
  11260. else
  11261. TIFF_DIR="`pwd`/$TIFF_DIR"
  11262. fi
  11263. { $as_echo "$as_me:${as_lineno-$LINENO}: checking where TIFF is installed..." >&5
  11264. $as_echo "$as_me: checking where TIFF is installed..." >&6;}
  11265. TIFF_LIB=''
  11266. TIFF_INC=''
  11267. TIFF_FOUND='no'
  11268. TIFF_ENABLED="-DUSE_TIFF"
  11269. if test -n "$TIFF_DIR" -a x$withval != "xno" -a x$withval != "xyes"; then
  11270. test -f $TIFF_DIR/lib/libtiff.a -o -f $TIFF_DIR/lib/libtiff.so -o -f $TIFF_DIR/lib/libtiff.sl -o -f $TIFF_DIR/lib/libtiff.dylib && TIFF_LIBDIR="$TIFF_DIR/lib"
  11271. test -f $TIFF_DIR/lib64/libtiff.a -o -f $TIFF_DIR/lib64/libtiff.so -o -f $TIFF_DIR/lib64/libtiff.sl -o -f $TIFF_DIR/libtiff.dylib && TIFF_LIBDIR="$TIFF_DIR/lib64"
  11272. test -f $TIFF_DIR/libtiff.a -o -f $TIFF_DIR/libtiff.so -o -f $TIFF_DIR/libtiff.sl -o -f $TIFF_DIR/libtiff.dylib && TIFF_LIBDIR="$TIFF_DIR"
  11273. test -f $TIFF_DIR/include/tiffio.h && TIFF_INCLUDE="$TIFF_DIR/include"
  11274. test -f $TIFF_DIR/lib/tiffio.h && TIFF_INCLUDE="$TIFF_DIR/lib"
  11275. test -f $TIFF_DIR/tiffio.h && TIFF_INCLUDE="$TIFF_DIR"
  11276. if test -n "$TIFF_LIBDIR" ; then
  11277. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFReadScanline in -ltiff" >&5
  11278. $as_echo_n "checking for TIFFReadScanline in -ltiff... " >&6; }
  11279. if ${ac_cv_lib_tiff_TIFFReadScanline+:} false; then :
  11280. $as_echo_n "(cached) " >&6
  11281. else
  11282. ac_check_lib_save_LIBS=$LIBS
  11283. LIBS="-ltiff -L$TIFF_LIBDIR -ltiff $LIBS"
  11284. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11285. /* end confdefs.h. */
  11286. /* Override any GCC internal prototype to avoid an error.
  11287. Use char because int might match the return type of a GCC
  11288. builtin and then its argument prototype would still apply. */
  11289. #ifdef __cplusplus
  11290. extern "C"
  11291. #endif
  11292. char TIFFReadScanline ();
  11293. int
  11294. main ()
  11295. {
  11296. return TIFFReadScanline ();
  11297. ;
  11298. return 0;
  11299. }
  11300. _ACEOF
  11301. if ac_fn_c_try_link "$LINENO"; then :
  11302. ac_cv_lib_tiff_TIFFReadScanline=yes
  11303. else
  11304. ac_cv_lib_tiff_TIFFReadScanline=no
  11305. fi
  11306. rm -f core conftest.err conftest.$ac_objext \
  11307. conftest$ac_exeext conftest.$ac_ext
  11308. LIBS=$ac_check_lib_save_LIBS
  11309. fi
  11310. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFReadScanline" >&5
  11311. $as_echo "$ac_cv_lib_tiff_TIFFReadScanline" >&6; }
  11312. if test "x$ac_cv_lib_tiff_TIFFReadScanline" = xyes; then :
  11313. TIFF_LIB=-L$TIFF_LIBDIR -ltiff
  11314. else
  11315. as_fn_error $? "failed to link against libtiff" "$LINENO" 5
  11316. fi
  11317. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using libtiff from $TIFF_LIB" >&5
  11318. $as_echo " using libtiff from $TIFF_LIB" >&6; }
  11319. else
  11320. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find tiff lib in $TIFF_DIR" >&5
  11321. $as_echo "$as_me: WARNING: cannot find tiff lib in $TIFF_DIR" >&2;}
  11322. TIFF_ENABLED=""
  11323. fi
  11324. if test -n "$TIFF_INCLUDE" ; then
  11325. as_ac_Header=`$as_echo "ac_cv_header_$TIFF_INCLUDE/tiffio.h" | $as_tr_sh`
  11326. ac_fn_c_check_header_mongrel "$LINENO" "$TIFF_INCLUDE/tiffio.h" "$as_ac_Header" "$ac_includes_default"
  11327. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  11328. TIFF_INC=-I$TIFF_INCLUDE
  11329. else
  11330. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find tiff headers" >&5
  11331. $as_echo "$as_me: WARNING: cannot find tiff headers" >&2;}
  11332. TIFF_ENABLED=""
  11333. fi
  11334. else
  11335. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find tiff headers in $TIFF_DIR" >&5
  11336. $as_echo "$as_me: WARNING: cannot find tiff headers in $TIFF_DIR" >&2;}
  11337. TIFF_ENABLED=""
  11338. fi
  11339. else if test x$withval != "xno";
  11340. then
  11341. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFReadScanline in -ltiff" >&5
  11342. $as_echo_n "checking for TIFFReadScanline in -ltiff... " >&6; }
  11343. if ${ac_cv_lib_tiff_TIFFReadScanline+:} false; then :
  11344. $as_echo_n "(cached) " >&6
  11345. else
  11346. ac_check_lib_save_LIBS=$LIBS
  11347. LIBS="-ltiff $LIBS"
  11348. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11349. /* end confdefs.h. */
  11350. /* Override any GCC internal prototype to avoid an error.
  11351. Use char because int might match the return type of a GCC
  11352. builtin and then its argument prototype would still apply. */
  11353. #ifdef __cplusplus
  11354. extern "C"
  11355. #endif
  11356. char TIFFReadScanline ();
  11357. int
  11358. main ()
  11359. {
  11360. return TIFFReadScanline ();
  11361. ;
  11362. return 0;
  11363. }
  11364. _ACEOF
  11365. if ac_fn_c_try_link "$LINENO"; then :
  11366. ac_cv_lib_tiff_TIFFReadScanline=yes
  11367. else
  11368. ac_cv_lib_tiff_TIFFReadScanline=no
  11369. fi
  11370. rm -f core conftest.err conftest.$ac_objext \
  11371. conftest$ac_exeext conftest.$ac_ext
  11372. LIBS=$ac_check_lib_save_LIBS
  11373. fi
  11374. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFReadScanline" >&5
  11375. $as_echo "$ac_cv_lib_tiff_TIFFReadScanline" >&6; }
  11376. if test "x$ac_cv_lib_tiff_TIFFReadScanline" = xyes; then :
  11377. TIFF_LIB="-ltiff"
  11378. fi
  11379. ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
  11380. if test "x$ac_cv_header_tiffio_h" = xyes; then :
  11381. else
  11382. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find tiff headers in system path" >&5
  11383. $as_echo "$as_me: WARNING: cannot find tiff headers in system path" >&2;}
  11384. TIFF_ENABLED=""
  11385. fi
  11386. if test -n "$TIFF_LIB" ; then
  11387. { $as_echo "$as_me:${as_lineno-$LINENO}: result: using libtiff from system libs." >&5
  11388. $as_echo "using libtiff from system libs." >&6; }
  11389. else
  11390. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: TIFF (libtiff) library cannot be found. install or reconfigure with --with-tiff=DIR" >&5
  11391. $as_echo "$as_me: WARNING: TIFF (libtiff) library cannot be found. install or reconfigure with --with-tiff=DIR" >&2;}
  11392. TIFF_ENABLED=""
  11393. fi
  11394. else
  11395. TIFF_ENABLED=""
  11396. fi
  11397. fi
  11398. if test -n $TIFF_ENABLED; then
  11399. # Check whether --enable-tiff_write_support was given.
  11400. if test "${enable_tiff_write_support+set}" = set; then :
  11401. enableval=$enable_tiff_write_support;
  11402. else
  11403. enable_tiff_write_support=no
  11404. fi
  11405. if test "$enable_tiff_write_support" == "yes"; then
  11406. TIFF_ENABLED="$TIFF_ENABLED -DUSE_TIFF_WRITE"
  11407. fi
  11408. fi
  11409. TIFF_INC=$TIFF_INC
  11410. TIFF_LIB=$TIFF_LIB
  11411. TIFF_ENABLED=$TIFF_ENABLED
  11412. # Check whether --with-geotiff was given.
  11413. if test "${with_geotiff+set}" = set; then :
  11414. withval=$with_geotiff;
  11415. else
  11416. with_geotiff=no
  11417. fi
  11418. if test "$with_geotiff" = "yes" -o "$with_geotiff" = "" ; then
  11419. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XTIFFClientOpen in -lgeotiff" >&5
  11420. $as_echo_n "checking for XTIFFClientOpen in -lgeotiff... " >&6; }
  11421. if ${ac_cv_lib_geotiff_XTIFFClientOpen+:} false; then :
  11422. $as_echo_n "(cached) " >&6
  11423. else
  11424. ac_check_lib_save_LIBS=$LIBS
  11425. LIBS="-lgeotiff $LIBS"
  11426. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11427. /* end confdefs.h. */
  11428. /* Override any GCC internal prototype to avoid an error.
  11429. Use char because int might match the return type of a GCC
  11430. builtin and then its argument prototype would still apply. */
  11431. #ifdef __cplusplus
  11432. extern "C"
  11433. #endif
  11434. char XTIFFClientOpen ();
  11435. int
  11436. main ()
  11437. {
  11438. return XTIFFClientOpen ();
  11439. ;
  11440. return 0;
  11441. }
  11442. _ACEOF
  11443. if ac_fn_c_try_link "$LINENO"; then :
  11444. ac_cv_lib_geotiff_XTIFFClientOpen=yes
  11445. else
  11446. ac_cv_lib_geotiff_XTIFFClientOpen=no
  11447. fi
  11448. rm -f core conftest.err conftest.$ac_objext \
  11449. conftest$ac_exeext conftest.$ac_ext
  11450. LIBS=$ac_check_lib_save_LIBS
  11451. fi
  11452. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_geotiff_XTIFFClientOpen" >&5
  11453. $as_echo "$ac_cv_lib_geotiff_XTIFFClientOpen" >&6; }
  11454. if test "x$ac_cv_lib_geotiff_XTIFFClientOpen" = xyes; then :
  11455. GEOTIFF_LIB="-lgeotiff"
  11456. else
  11457. as_fn_error $? "failed to link with libgeotiff. Specify path" "$LINENO" 5
  11458. fi
  11459. ac_fn_c_check_header_mongrel "$LINENO" "geotiff.h" "ac_cv_header_geotiff_h" "$ac_includes_default"
  11460. if test "x$ac_cv_header_geotiff_h" = xyes; then :
  11461. GEOTIFF_ENABLED="-DUSE_GEOTIFF"
  11462. echo "using system libgeotiff."
  11463. else
  11464. if test -r /usr/include/geotiff/geotiff.h ; then
  11465. GEOTIFF_INC="-I/usr/include/geotiff"
  11466. echo "using system libgeotiff from /usr/include/geotiff/."
  11467. elif test -r /usr/local/include/geotiff/geotiff.h ; then
  11468. GEOTIFF_INC="-I/usr/local/include/geotiff"
  11469. echo "using system libgeotiff from /usr/local/include/geotiff/."
  11470. else
  11471. as_fn_error $? "failed to find geotiff.h in system locations. Specify path" "$LINENO" 5
  11472. fi
  11473. GEOTIFF_ENABLED="-DUSE_GEOTIFF"
  11474. fi
  11475. elif test "$with_geotiff" != "no" ; then
  11476. GEOTIFF_LIB="-L$with_geotiff/lib -lgeotiff"
  11477. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XTIFFClientOpen in -lgeotiff" >&5
  11478. $as_echo_n "checking for XTIFFClientOpen in -lgeotiff... " >&6; }
  11479. if ${ac_cv_lib_geotiff_XTIFFClientOpen+:} false; then :
  11480. $as_echo_n "(cached) " >&6
  11481. else
  11482. ac_check_lib_save_LIBS=$LIBS
  11483. LIBS="-lgeotiff "$GEOTIFF_LIB" $LIBS"
  11484. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11485. /* end confdefs.h. */
  11486. /* Override any GCC internal prototype to avoid an error.
  11487. Use char because int might match the return type of a GCC
  11488. builtin and then its argument prototype would still apply. */
  11489. #ifdef __cplusplus
  11490. extern "C"
  11491. #endif
  11492. char XTIFFClientOpen ();
  11493. int
  11494. main ()
  11495. {
  11496. return XTIFFClientOpen ();
  11497. ;
  11498. return 0;
  11499. }
  11500. _ACEOF
  11501. if ac_fn_c_try_link "$LINENO"; then :
  11502. ac_cv_lib_geotiff_XTIFFClientOpen=yes
  11503. else
  11504. ac_cv_lib_geotiff_XTIFFClientOpen=no
  11505. fi
  11506. rm -f core conftest.err conftest.$ac_objext \
  11507. conftest$ac_exeext conftest.$ac_ext
  11508. LIBS=$ac_check_lib_save_LIBS
  11509. fi
  11510. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_geotiff_XTIFFClientOpen" >&5
  11511. $as_echo "$ac_cv_lib_geotiff_XTIFFClientOpen" >&6; }
  11512. if test "x$ac_cv_lib_geotiff_XTIFFClientOpen" = xyes; then :
  11513. GEOTIFF_LIB="-L$with_geotiff/lib -lgeotiff"
  11514. else
  11515. as_fn_error $? "failed to link with libgeotiff. Specify path" "$LINENO" 5
  11516. fi
  11517. if test -r $with_geotiff/include/geotiff.h ; then
  11518. GEOTIFF_INC="-I$with_geotiff/include"
  11519. echo "using system libgeotiff from $with_geotiff/include/."
  11520. elif test -r $with_geotiff/include/geotiff/geotiff.h ; then
  11521. GEOTIFF_INC="-I$with_geotiff/include/geotiff"
  11522. echo "using system libgeotiff from $with_geotiff/geotiff/include/."
  11523. else
  11524. as_fn_error $? "failed to find geotiff.h in $with_geotiff" "$LINENO" 5
  11525. fi
  11526. GEOTIFF_ENABLED="-DUSE_GEOTIFF"
  11527. fi
  11528. GEOTIFF_ENABLED=$GEOTIFF_ENABLED
  11529. GEOTIFF_INC=$GEOTIFF_INC
  11530. GEOTIFF_LIB=$GEOTIFF_LIB
  11531. PCRE_LIBS=''
  11532. PCRE_CFLAGS=''
  11533. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcre library inclusion" >&5
  11534. $as_echo_n "checking for pcre library inclusion... " >&6; }
  11535. # Check whether --with-pcre was given.
  11536. if test "${with_pcre+set}" = set; then :
  11537. withval=$with_pcre;
  11538. else
  11539. with_pcre="yes"
  11540. fi
  11541. if test "x$with_pcre" = "xno" ; then
  11542. { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled by request" >&5
  11543. $as_echo "disabled by request" >&6; }
  11544. else
  11545. if test "x$with_pcre" = "xyes" ; then
  11546. { $as_echo "$as_me:${as_lineno-$LINENO}: result: in system locations" >&5
  11547. $as_echo "in system locations" >&6; }
  11548. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcre_compile in -lpcre" >&5
  11549. $as_echo_n "checking for pcre_compile in -lpcre... " >&6; }
  11550. if ${ac_cv_lib_pcre_pcre_compile+:} false; then :
  11551. $as_echo_n "(cached) " >&6
  11552. else
  11553. ac_check_lib_save_LIBS=$LIBS
  11554. LIBS="-lpcre $LIBS"
  11555. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11556. /* end confdefs.h. */
  11557. /* Override any GCC internal prototype to avoid an error.
  11558. Use char because int might match the return type of a GCC
  11559. builtin and then its argument prototype would still apply. */
  11560. #ifdef __cplusplus
  11561. extern "C"
  11562. #endif
  11563. char pcre_compile ();
  11564. int
  11565. main ()
  11566. {
  11567. return pcre_compile ();
  11568. ;
  11569. return 0;
  11570. }
  11571. _ACEOF
  11572. if ac_fn_c_try_link "$LINENO"; then :
  11573. ac_cv_lib_pcre_pcre_compile=yes
  11574. else
  11575. ac_cv_lib_pcre_pcre_compile=no
  11576. fi
  11577. rm -f core conftest.err conftest.$ac_objext \
  11578. conftest$ac_exeext conftest.$ac_ext
  11579. LIBS=$ac_check_lib_save_LIBS
  11580. fi
  11581. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pcre_pcre_compile" >&5
  11582. $as_echo "$ac_cv_lib_pcre_pcre_compile" >&6; }
  11583. if test "x$ac_cv_lib_pcre_pcre_compile" = xyes; then :
  11584. PCRE_LIBS=-lpcre
  11585. else
  11586. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pcre library not found, will fall back
  11587. to posix regular expressions which are less powerfull" >&5
  11588. $as_echo "$as_me: WARNING: pcre library not found, will fall back
  11589. to posix regular expressions which are less powerfull" >&2;}
  11590. fi
  11591. if test -n "$PCRE_LIBS"; then
  11592. ac_fn_c_check_header_mongrel "$LINENO" "pcre.h" "ac_cv_header_pcre_h" "$ac_includes_default"
  11593. if test "x$ac_cv_header_pcre_h" = xyes; then :
  11594. PCRE_ENABLED=-DUSE_PCRE
  11595. else
  11596. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pcre.h not found, will fall back
  11597. to posix regular expressions which are less powerfull" >&5
  11598. $as_echo "$as_me: WARNING: pcre.h not found, will fall back
  11599. to posix regular expressions which are less powerfull" >&2;}
  11600. fi
  11601. fi
  11602. else
  11603. OLDLDFLAGS="$LDFLAGS" ; LDFLAGS="$LDFLAGS -L$with_pcre/lib"
  11604. OLDCPPFLAGS="$CPPFLAGS" ; CPPFLAGS="$CPPFLAGS -I$with_pcre/include"
  11605. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcre_compile in -lpcre" >&5
  11606. $as_echo_n "checking for pcre_compile in -lpcre... " >&6; }
  11607. if ${ac_cv_lib_pcre_pcre_compile+:} false; then :
  11608. $as_echo_n "(cached) " >&6
  11609. else
  11610. ac_check_lib_save_LIBS=$LIBS
  11611. LIBS="-lpcre $LIBS"
  11612. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11613. /* end confdefs.h. */
  11614. /* Override any GCC internal prototype to avoid an error.
  11615. Use char because int might match the return type of a GCC
  11616. builtin and then its argument prototype would still apply. */
  11617. #ifdef __cplusplus
  11618. extern "C"
  11619. #endif
  11620. char pcre_compile ();
  11621. int
  11622. main ()
  11623. {
  11624. return pcre_compile ();
  11625. ;
  11626. return 0;
  11627. }
  11628. _ACEOF
  11629. if ac_fn_c_try_link "$LINENO"; then :
  11630. ac_cv_lib_pcre_pcre_compile=yes
  11631. else
  11632. ac_cv_lib_pcre_pcre_compile=no
  11633. fi
  11634. rm -f core conftest.err conftest.$ac_objext \
  11635. conftest$ac_exeext conftest.$ac_ext
  11636. LIBS=$ac_check_lib_save_LIBS
  11637. fi
  11638. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pcre_pcre_compile" >&5
  11639. $as_echo "$ac_cv_lib_pcre_pcre_compile" >&6; }
  11640. if test "x$ac_cv_lib_pcre_pcre_compile" = xyes; then :
  11641. PCRE_LIBS="-L$with_pcre/lib -lpcre"
  11642. else
  11643. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pcre library not found in $with_pcre/lib, will fall back
  11644. to posix regular expressions which are less powerfull" >&5
  11645. $as_echo "$as_me: WARNING: pcre library not found in $with_pcre/lib, will fall back
  11646. to posix regular expressions which are less powerfull" >&2;}
  11647. fi
  11648. CPPFLAGS="$OLDCPPFLAGS"
  11649. LDFLAGS="$OLDLDFLAGS"
  11650. if test -n "$PCRE_LIBS"; then
  11651. test -f $with_pcre/include/pcre.h && PCRE_CFLAGS="-I$with_pcre/include"
  11652. test -f $with_pcre/lib/pcre.h && PCRE_CFLAGS="-I$with_pcre/lib"
  11653. test -f $with_pcre/pcre.h && PCRE_CFLAGS="-I$with_pcre"
  11654. if test -z $PCRE_CFLAGS; then
  11655. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pcre.h not found, will fall back
  11656. to posix regular expressions which are less powerfull" >&5
  11657. $as_echo "$as_me: WARNING: pcre.h not found, will fall back
  11658. to posix regular expressions which are less powerfull" >&2;}
  11659. else
  11660. PCRE_ENABLED="-DUSE_PCRE"
  11661. fi
  11662. fi
  11663. fi
  11664. fi
  11665. # Check whether --with-gdal was given.
  11666. if test "${with_gdal+set}" = set; then :
  11667. withval=$with_gdal;
  11668. else
  11669. with_gdal=yes
  11670. fi
  11671. GDALCONFIG=""
  11672. if test "$with_gdal" = "no"; then
  11673. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: gdal support disabled by request: advanced seeding options will not be available" >&5
  11674. $as_echo "$as_me: WARNING: gdal support disabled by request: advanced seeding options will not be available" >&2;}
  11675. else
  11676. if test "$with_gdal" = "yes"; then
  11677. # Extract the first word of "gdal-config", so it can be a program name with args.
  11678. set dummy gdal-config; ac_word=$2
  11679. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  11680. $as_echo_n "checking for $ac_word... " >&6; }
  11681. if ${ac_cv_path_GDALCONFIG+:} false; then :
  11682. $as_echo_n "(cached) " >&6
  11683. else
  11684. case $GDALCONFIG in
  11685. [\\/]* | ?:[\\/]*)
  11686. ac_cv_path_GDALCONFIG="$GDALCONFIG" # Let the user override the test with a path.
  11687. ;;
  11688. *)
  11689. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  11690. for as_dir in $PATH
  11691. do
  11692. IFS=$as_save_IFS
  11693. test -z "$as_dir" && as_dir=.
  11694. for ac_exec_ext in '' $ac_executable_extensions; do
  11695. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  11696. ac_cv_path_GDALCONFIG="$as_dir/$ac_word$ac_exec_ext"
  11697. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  11698. break 2
  11699. fi
  11700. done
  11701. done
  11702. IFS=$as_save_IFS
  11703. ;;
  11704. esac
  11705. fi
  11706. GDALCONFIG=$ac_cv_path_GDALCONFIG
  11707. if test -n "$GDALCONFIG"; then
  11708. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDALCONFIG" >&5
  11709. $as_echo "$GDALCONFIG" >&6; }
  11710. else
  11711. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  11712. $as_echo "no" >&6; }
  11713. fi
  11714. else
  11715. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdal-config usability in $with_gdal" >&5
  11716. $as_echo_n "checking for gdal-config usability in $with_gdal... " >&6; }
  11717. if test -x "$with_gdal"; then
  11718. GDALCONFIG=$with_gdal
  11719. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
  11720. $as_echo "ok" >&6; }
  11721. else
  11722. as_fn_error $? "$with_gdal not found or not executable" "$LINENO" 5
  11723. fi
  11724. fi
  11725. if test -n "$GDALCONFIG"; then
  11726. GDAL_ENABLED="-DUSE_GDAL"
  11727. GDAL_CFLAGS=`$GDALCONFIG --cflags --includes`
  11728. GDAL_LIBS=`$GDALCONFIG --libs`
  11729. OGR_ENABLED=`$GDALCONFIG --ogr-enabled`
  11730. fi
  11731. fi
  11732. if test "x$OGR_ENABLED" == "xyes"; then
  11733. OGR_ENABLED="-DUSE_OGR"
  11734. fi
  11735. OGR_ENABLED=$OGR_ENABLED
  11736. GDAL_ENABLED=$GDAL_ENABLED
  11737. GDAL_INC=$GDAL_CFLAGS
  11738. GDAL_LIB=$GDAL_LIBS
  11739. # Check whether --with-geos was given.
  11740. if test "${with_geos+set}" = set; then :
  11741. withval=$with_geos;
  11742. else
  11743. with_geos=yes
  11744. fi
  11745. GEOSCONFIG=""
  11746. if test -z "$OGR_ENABLED"; then
  11747. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: geos support disabled as gdal/ogr support was disabled/not found" >&5
  11748. $as_echo "$as_me: WARNING: geos support disabled as gdal/ogr support was disabled/not found" >&2;}
  11749. fi
  11750. if test "$with_geos" = "no"; then
  11751. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: geos support disabled by request: advanced seeding options will not be available" >&5
  11752. $as_echo "$as_me: WARNING: geos support disabled by request: advanced seeding options will not be available" >&2;}
  11753. else
  11754. if test "$with_geos" = "yes"; then
  11755. # Extract the first word of "geos-config", so it can be a program name with args.
  11756. set dummy geos-config; ac_word=$2
  11757. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  11758. $as_echo_n "checking for $ac_word... " >&6; }
  11759. if ${ac_cv_path_GEOSCONFIG+:} false; then :
  11760. $as_echo_n "(cached) " >&6
  11761. else
  11762. case $GEOSCONFIG in
  11763. [\\/]* | ?:[\\/]*)
  11764. ac_cv_path_GEOSCONFIG="$GEOSCONFIG" # Let the user override the test with a path.
  11765. ;;
  11766. *)
  11767. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  11768. for as_dir in $PATH
  11769. do
  11770. IFS=$as_save_IFS
  11771. test -z "$as_dir" && as_dir=.
  11772. for ac_exec_ext in '' $ac_executable_extensions; do
  11773. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  11774. ac_cv_path_GEOSCONFIG="$as_dir/$ac_word$ac_exec_ext"
  11775. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  11776. break 2
  11777. fi
  11778. done
  11779. done
  11780. IFS=$as_save_IFS
  11781. ;;
  11782. esac
  11783. fi
  11784. GEOSCONFIG=$ac_cv_path_GEOSCONFIG
  11785. if test -n "$GEOSCONFIG"; then
  11786. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GEOSCONFIG" >&5
  11787. $as_echo "$GEOSCONFIG" >&6; }
  11788. else
  11789. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  11790. $as_echo "no" >&6; }
  11791. fi
  11792. else
  11793. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for geos-config usability in $with_geos" >&5
  11794. $as_echo_n "checking for geos-config usability in $with_geos... " >&6; }
  11795. if test -x "$with_geos"; then
  11796. GEOSCONFIG=$with_geos
  11797. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  11798. $as_echo "yes" >&6; }
  11799. else
  11800. as_fn_error $? "$with_geos not found or not executable" "$LINENO" 5
  11801. fi
  11802. fi
  11803. if test -n "$GEOSCONFIG"; then
  11804. GEOS_CFLAGS=`$GEOSCONFIG --cflags`
  11805. GEOS_LIBS="`$GEOSCONFIG --ldflags` -lgeos_c"
  11806. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GEOSPreparedIntersects in -lgeos_c" >&5
  11807. $as_echo_n "checking for GEOSPreparedIntersects in -lgeos_c... " >&6; }
  11808. if ${ac_cv_lib_geos_c_GEOSPreparedIntersects+:} false; then :
  11809. $as_echo_n "(cached) " >&6
  11810. else
  11811. ac_check_lib_save_LIBS=$LIBS
  11812. LIBS="-lgeos_c "$GEOS_LIBS" $LIBS"
  11813. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11814. /* end confdefs.h. */
  11815. /* Override any GCC internal prototype to avoid an error.
  11816. Use char because int might match the return type of a GCC
  11817. builtin and then its argument prototype would still apply. */
  11818. #ifdef __cplusplus
  11819. extern "C"
  11820. #endif
  11821. char GEOSPreparedIntersects ();
  11822. int
  11823. main ()
  11824. {
  11825. return GEOSPreparedIntersects ();
  11826. ;
  11827. return 0;
  11828. }
  11829. _ACEOF
  11830. if ac_fn_c_try_link "$LINENO"; then :
  11831. ac_cv_lib_geos_c_GEOSPreparedIntersects=yes
  11832. else
  11833. ac_cv_lib_geos_c_GEOSPreparedIntersects=no
  11834. fi
  11835. rm -f core conftest.err conftest.$ac_objext \
  11836. conftest$ac_exeext conftest.$ac_ext
  11837. LIBS=$ac_check_lib_save_LIBS
  11838. fi
  11839. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_geos_c_GEOSPreparedIntersects" >&5
  11840. $as_echo "$ac_cv_lib_geos_c_GEOSPreparedIntersects" >&6; }
  11841. if test "x$ac_cv_lib_geos_c_GEOSPreparedIntersects" = xyes; then :
  11842. GEOS_ENABLED="-DUSE_GEOS"
  11843. else
  11844. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Geos support disabled as installed version is too old" >&5
  11845. $as_echo "$as_me: WARNING: Geos support disabled as installed version is too old" >&2;}
  11846. fi
  11847. fi
  11848. fi
  11849. GEOS_ENABLED=$GEOS_ENABLED
  11850. GEOS_INC=$GEOS_CFLAGS
  11851. GEOS_LIB=$GEOS_LIBS
  11852. # Check whether --with-mapserver was given.
  11853. if test "${with_mapserver+set}" = set; then :
  11854. withval=$with_mapserver;
  11855. else
  11856. enable_mapserver=no
  11857. fi
  11858. if test "$with_mapserver" == "yes"; then
  11859. as_fn_error $? "--with-mapserver needs the path to the mapserver source directory" "$LINENO" 5
  11860. else
  11861. if test "$enable_mapserver" != "no"; then
  11862. MAPSERVER_DIR=$with_mapserver
  11863. fi
  11864. fi
  11865. if test -n "$MAPSERVER_DIR"; then
  11866. MSDEFS=`$MAPSERVER_DIR/mapserver-config --defines`
  11867. echo $MSDEFS | grep USE_THREAD > /dev/null
  11868. if test $? -ne 0 ; then
  11869. as_fn_error $? "mapserver-config from $MAPSERVER_DIR reports that the build does not have thread safety enabled. Reconfigure,recompile and reinstall mapserver build with --enable-threads" "$LINENO" 5
  11870. fi
  11871. MAPSERVER_ENABLED="-DUSE_MAPSERVER"
  11872. MAPSERVER_DEFS=$MSDEFS
  11873. MAPSERVER_INC="-I $MAPSERVER_DIR `$MAPSERVER_DIR/mapserver-config --includes`"
  11874. MAPSERVER_LIB="$MAPSERVER_DIR/libmapserver.la"
  11875. fi
  11876. # Check whether --with-bdb was given.
  11877. if test "${with_bdb+set}" = set; then :
  11878. withval=$with_bdb;
  11879. else
  11880. with_bdb=yes
  11881. fi
  11882. if test "x$with_bdb" != "xno"; then
  11883. ax_path_bdb_ok=no
  11884. # Add --with-bdb-dir option to configure.
  11885. # Check whether --with-bdb-dir was given.
  11886. if test "${with_bdb_dir+set}" = set; then :
  11887. withval=$with_bdb_dir;
  11888. fi
  11889. # Check if --with-bdb-dir was specified.
  11890. if test "x$with_bdb_dir" = "x" ; then
  11891. # No option specified, so just search the system.
  11892. ax_path_bdb_no_options_ok=no
  11893. # Values to add to environment to use Berkeley DB.
  11894. BDB_VERSION=''
  11895. BDB_LIBS=''
  11896. BDB_CPPFLAGS=''
  11897. BDB_LDFLAGS=''
  11898. # Check cross compilation here.
  11899. if test "x$cross_compiling" = "xyes" ; then
  11900. # If cross compiling, can't use AC_RUN_IFELSE so do these tests.
  11901. # The AC_PREPROC_IFELSE confirms that db.h is preprocessable,
  11902. # and extracts the version number from it.
  11903. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for db.h" >&5
  11904. $as_echo_n "checking for db.h... " >&6; }
  11905. ax_path_bdb_no_options_HEADER_VERSION=''
  11906. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11907. /* end confdefs.h. */
  11908. #include <db.h>
  11909. AX_PATH_BDB_STUFF DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH
  11910. _ACEOF
  11911. if ac_fn_c_try_cpp "$LINENO"; then :
  11912. # Extract version from preprocessor output.
  11913. ax_path_bdb_no_options_HEADER_VERSION=`eval "$ac_cpp conftest.$ac_ext" 2> /dev/null \
  11914. | grep AX_PATH_BDB_STUFF | sed 's/[^0-9,]//g;s/,/./g;1q'`
  11915. fi
  11916. rm -f conftest.err conftest.i conftest.$ac_ext
  11917. if test "x$ax_path_bdb_no_options_HEADER_VERSION" = "x" ; then
  11918. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  11919. $as_echo "no" >&6; }
  11920. else
  11921. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_no_options_HEADER_VERSION" >&5
  11922. $as_echo "$ax_path_bdb_no_options_HEADER_VERSION" >&6; }
  11923. # Check that version is high enough.
  11924. # Used to indicate true or false condition
  11925. ax_compare_version=false
  11926. # Convert the two version strings to be compared into a format that
  11927. # allows a simple string comparison. The end result is that a version
  11928. # string of the form 1.12.5-r617 will be converted to the form
  11929. # 0001001200050617. In other words, each number is zero padded to four
  11930. # digits, and non digits are removed.
  11931. ax_compare_version_A=`echo "$ax_path_bdb_no_options_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  11932. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  11933. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  11934. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  11935. -e 's/[^0-9]//g'`
  11936. ax_compare_version_B=`echo "4" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  11937. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  11938. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  11939. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  11940. -e 's/[^0-9]//g'`
  11941. ax_compare_version=`echo "x$ax_compare_version_A
  11942. x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"`
  11943. if test "$ax_compare_version" = "true" ; then
  11944. # get major and minor version numbers
  11945. ax_path_bdb_no_options_MAJOR=`echo $ax_path_bdb_no_options_HEADER_VERSION | sed 's,\..*,,'`
  11946. ax_path_bdb_no_options_MINOR=`echo $ax_path_bdb_no_options_HEADER_VERSION | sed 's,^[0-9]*\.,,;s,\.[0-9]*$,,'`
  11947. ax_path_bdb_no_options_save_LIBS="$LIBS"
  11948. # Check that we can link with the library.
  11949. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing db_version" >&5
  11950. $as_echo_n "checking for library containing db_version... " >&6; }
  11951. if ${ac_cv_search_db_version+:} false; then :
  11952. $as_echo_n "(cached) " >&6
  11953. else
  11954. ac_func_search_save_LIBS=$LIBS
  11955. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11956. /* end confdefs.h. */
  11957. /* Override any GCC internal prototype to avoid an error.
  11958. Use char because int might match the return type of a GCC
  11959. builtin and then its argument prototype would still apply. */
  11960. #ifdef __cplusplus
  11961. extern "C"
  11962. #endif
  11963. char db_version ();
  11964. int
  11965. main ()
  11966. {
  11967. return db_version ();
  11968. ;
  11969. return 0;
  11970. }
  11971. _ACEOF
  11972. for ac_lib in '' db db-$ax_path_bdb_no_options_MAJOR.$ax_path_bdb_no_options_MINOR db$ax_path_bdb_no_options_MAJOR.$ax_path_bdb_no_options_MINOR db$ax_path_bdb_no_options_MAJOR$ax_path_bdb_no_options_MINOR db-$ax_path_bdb_no_options_MAJOR db$ax_path_bdb_no_options_MAJOR; do
  11973. if test -z "$ac_lib"; then
  11974. ac_res="none required"
  11975. else
  11976. ac_res=-l$ac_lib
  11977. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  11978. fi
  11979. if ac_fn_c_try_link "$LINENO"; then :
  11980. ac_cv_search_db_version=$ac_res
  11981. fi
  11982. rm -f core conftest.err conftest.$ac_objext \
  11983. conftest$ac_exeext
  11984. if ${ac_cv_search_db_version+:} false; then :
  11985. break
  11986. fi
  11987. done
  11988. if ${ac_cv_search_db_version+:} false; then :
  11989. else
  11990. ac_cv_search_db_version=no
  11991. fi
  11992. rm conftest.$ac_ext
  11993. LIBS=$ac_func_search_save_LIBS
  11994. fi
  11995. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_db_version" >&5
  11996. $as_echo "$ac_cv_search_db_version" >&6; }
  11997. ac_res=$ac_cv_search_db_version
  11998. if test "$ac_res" != no; then :
  11999. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  12000. # Sucessfully found library.
  12001. ax_path_bdb_no_options_ok=yes
  12002. BDB_VERSION=$ax_path_bdb_no_options_HEADER_VERSION
  12003. # Extract library from LIBS
  12004. ax_path_bdb_no_options_LEN=` \
  12005. echo "x$ax_path_bdb_no_options_save_LIBS" \
  12006. | awk '{print(length)}'`
  12007. BDB_LIBS=`echo "x$LIBS " \
  12008. | sed "s/.\{$ax_path_bdb_no_options_LEN\}\$//;s/^x//;s/ //g"`
  12009. fi
  12010. LIBS="$ax_path_bdb_no_options_save_LIBS"
  12011. fi
  12012. fi
  12013. else
  12014. # Not cross compiling.
  12015. # Check version of Berkeley DB in the current environment.
  12016. ax_path_bdb_env_get_version_ok=no
  12017. ax_path_bdb_env_get_version_VERSION=''
  12018. ax_path_bdb_env_get_version_LIBS=''
  12019. # Indicate status of checking for Berkeley DB library.
  12020. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for db.h" >&5
  12021. $as_echo_n "checking for db.h... " >&6; }
  12022. # Compile and run a program that determines the Berkeley DB version
  12023. # in the header file db.h.
  12024. ax_path_bdb_env_get_version_HEADER_VERSION=''
  12025. if test "$cross_compiling" = yes; then :
  12026. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  12027. $as_echo "no" >&6; }
  12028. else
  12029. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12030. /* end confdefs.h. */
  12031. #include <stdio.h>
  12032. #include <db.h>
  12033. int main(int argc,char **argv)
  12034. {
  12035. (void) argv;
  12036. if (argc > 1)
  12037. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12038. return 0;
  12039. }
  12040. _ACEOF
  12041. if ac_fn_c_try_run "$LINENO"; then :
  12042. # Program compiled and ran, so get version by adding an argument.
  12043. ax_path_bdb_env_get_version_HEADER_VERSION=`./conftest$ac_exeext x`
  12044. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_env_get_version_HEADER_VERSION" >&5
  12045. $as_echo "$ax_path_bdb_env_get_version_HEADER_VERSION" >&6; }
  12046. else
  12047. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  12048. $as_echo "no" >&6; }
  12049. fi
  12050. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12051. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12052. fi
  12053. # Have header version, so try to find corresponding library.
  12054. # Looks for library names in the order:
  12055. # nothing, db, db-X.Y, dbX.Y, dbXY, db-X, dbX
  12056. # and stops when it finds the first one that matches the version
  12057. # of the header file.
  12058. if test "x$ax_path_bdb_env_get_version_HEADER_VERSION" != "x" ; then
  12059. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing Berkeley DB $ax_path_bdb_env_get_version_HEADER_VERSION" >&5
  12060. $as_echo_n "checking for library containing Berkeley DB $ax_path_bdb_env_get_version_HEADER_VERSION... " >&6; }
  12061. # get major and minor version numbers
  12062. ax_path_bdb_env_get_version_MAJOR=`echo $ax_path_bdb_env_get_version_HEADER_VERSION | sed 's,\..*,,'`
  12063. ax_path_bdb_env_get_version_MINOR=`echo $ax_path_bdb_env_get_version_HEADER_VERSION | sed 's,^[0-9]*\.,,;s,\.[0-9]*$,,'`
  12064. # see if it is already specified in LIBS
  12065. ax_path_bdb_env_get_version_TEST_LIBNAME=''
  12066. ax_path_bdb_env_confirm_lib_ok=no
  12067. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  12068. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  12069. # Compile and run a program that compares the version defined in
  12070. # the header file with a version defined in the library function
  12071. # db_version.
  12072. if test "$cross_compiling" = yes; then :
  12073. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12074. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12075. as_fn_error $? "cannot run test program while cross compiling
  12076. See \`config.log' for more details" "$LINENO" 5; }
  12077. else
  12078. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12079. /* end confdefs.h. */
  12080. #include <stdio.h>
  12081. #include <db.h>
  12082. int main(int argc,char **argv)
  12083. {
  12084. int major,minor,patch;
  12085. (void) argv;
  12086. db_version(&major,&minor,&patch);
  12087. if (argc > 1)
  12088. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12089. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12090. DB_VERSION_PATCH == patch)
  12091. return 0;
  12092. else
  12093. return 1;
  12094. }
  12095. _ACEOF
  12096. if ac_fn_c_try_run "$LINENO"; then :
  12097. # Program compiled and ran, so get version by giving an argument,
  12098. # which will tell the program to print the output.
  12099. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  12100. # If the versions all match up, indicate success.
  12101. # Used to indicate true or false condition
  12102. ax_compare_version=false
  12103. # Convert the two version strings to be compared into a format that
  12104. # allows a simple string comparison. The end result is that a version
  12105. # string of the form 1.12.5-r617 will be converted to the form
  12106. # 0001001200050617. In other words, each number is zero padded to four
  12107. # digits, and non digits are removed.
  12108. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12109. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12110. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12111. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12112. -e 's/[^0-9]//g'`
  12113. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12114. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12115. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12116. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12117. -e 's/[^0-9]//g'`
  12118. # Pad zeros at end of numbers to make same length.
  12119. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  12120. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  12121. ax_compare_version_A="$ax_compare_version_tmp_A"
  12122. # Check for equality or inequality as necessary.
  12123. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  12124. if test "$ax_compare_version" = "true" ; then
  12125. ax_path_bdb_env_confirm_lib_ok=yes
  12126. fi
  12127. fi
  12128. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12129. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12130. fi
  12131. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  12132. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  12133. # try format "db"
  12134. ax_path_bdb_env_get_version_TEST_LIBNAME='-ldb'
  12135. ax_path_bdb_env_confirm_lib_ok=no
  12136. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  12137. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  12138. # Compile and run a program that compares the version defined in
  12139. # the header file with a version defined in the library function
  12140. # db_version.
  12141. if test "$cross_compiling" = yes; then :
  12142. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12143. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12144. as_fn_error $? "cannot run test program while cross compiling
  12145. See \`config.log' for more details" "$LINENO" 5; }
  12146. else
  12147. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12148. /* end confdefs.h. */
  12149. #include <stdio.h>
  12150. #include <db.h>
  12151. int main(int argc,char **argv)
  12152. {
  12153. int major,minor,patch;
  12154. (void) argv;
  12155. db_version(&major,&minor,&patch);
  12156. if (argc > 1)
  12157. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12158. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12159. DB_VERSION_PATCH == patch)
  12160. return 0;
  12161. else
  12162. return 1;
  12163. }
  12164. _ACEOF
  12165. if ac_fn_c_try_run "$LINENO"; then :
  12166. # Program compiled and ran, so get version by giving an argument,
  12167. # which will tell the program to print the output.
  12168. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  12169. # If the versions all match up, indicate success.
  12170. # Used to indicate true or false condition
  12171. ax_compare_version=false
  12172. # Convert the two version strings to be compared into a format that
  12173. # allows a simple string comparison. The end result is that a version
  12174. # string of the form 1.12.5-r617 will be converted to the form
  12175. # 0001001200050617. In other words, each number is zero padded to four
  12176. # digits, and non digits are removed.
  12177. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12178. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12179. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12180. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12181. -e 's/[^0-9]//g'`
  12182. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12183. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12184. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12185. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12186. -e 's/[^0-9]//g'`
  12187. # Pad zeros at end of numbers to make same length.
  12188. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  12189. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  12190. ax_compare_version_A="$ax_compare_version_tmp_A"
  12191. # Check for equality or inequality as necessary.
  12192. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  12193. if test "$ax_compare_version" = "true" ; then
  12194. ax_path_bdb_env_confirm_lib_ok=yes
  12195. fi
  12196. fi
  12197. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12198. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12199. fi
  12200. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  12201. fi
  12202. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  12203. # try format "db-X.Y"
  12204. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb-${ax_path_bdb_env_get_version_MAJOR}.$ax_path_bdb_env_get_version_MINOR"
  12205. ax_path_bdb_env_confirm_lib_ok=no
  12206. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  12207. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  12208. # Compile and run a program that compares the version defined in
  12209. # the header file with a version defined in the library function
  12210. # db_version.
  12211. if test "$cross_compiling" = yes; then :
  12212. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12213. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12214. as_fn_error $? "cannot run test program while cross compiling
  12215. See \`config.log' for more details" "$LINENO" 5; }
  12216. else
  12217. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12218. /* end confdefs.h. */
  12219. #include <stdio.h>
  12220. #include <db.h>
  12221. int main(int argc,char **argv)
  12222. {
  12223. int major,minor,patch;
  12224. (void) argv;
  12225. db_version(&major,&minor,&patch);
  12226. if (argc > 1)
  12227. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12228. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12229. DB_VERSION_PATCH == patch)
  12230. return 0;
  12231. else
  12232. return 1;
  12233. }
  12234. _ACEOF
  12235. if ac_fn_c_try_run "$LINENO"; then :
  12236. # Program compiled and ran, so get version by giving an argument,
  12237. # which will tell the program to print the output.
  12238. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  12239. # If the versions all match up, indicate success.
  12240. # Used to indicate true or false condition
  12241. ax_compare_version=false
  12242. # Convert the two version strings to be compared into a format that
  12243. # allows a simple string comparison. The end result is that a version
  12244. # string of the form 1.12.5-r617 will be converted to the form
  12245. # 0001001200050617. In other words, each number is zero padded to four
  12246. # digits, and non digits are removed.
  12247. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12248. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12249. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12250. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12251. -e 's/[^0-9]//g'`
  12252. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12253. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12254. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12255. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12256. -e 's/[^0-9]//g'`
  12257. # Pad zeros at end of numbers to make same length.
  12258. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  12259. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  12260. ax_compare_version_A="$ax_compare_version_tmp_A"
  12261. # Check for equality or inequality as necessary.
  12262. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  12263. if test "$ax_compare_version" = "true" ; then
  12264. ax_path_bdb_env_confirm_lib_ok=yes
  12265. fi
  12266. fi
  12267. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12268. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12269. fi
  12270. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  12271. fi
  12272. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  12273. # try format "dbX.Y"
  12274. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb${ax_path_bdb_env_get_version_MAJOR}.$ax_path_bdb_env_get_version_MINOR"
  12275. ax_path_bdb_env_confirm_lib_ok=no
  12276. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  12277. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  12278. # Compile and run a program that compares the version defined in
  12279. # the header file with a version defined in the library function
  12280. # db_version.
  12281. if test "$cross_compiling" = yes; then :
  12282. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12283. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12284. as_fn_error $? "cannot run test program while cross compiling
  12285. See \`config.log' for more details" "$LINENO" 5; }
  12286. else
  12287. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12288. /* end confdefs.h. */
  12289. #include <stdio.h>
  12290. #include <db.h>
  12291. int main(int argc,char **argv)
  12292. {
  12293. int major,minor,patch;
  12294. (void) argv;
  12295. db_version(&major,&minor,&patch);
  12296. if (argc > 1)
  12297. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12298. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12299. DB_VERSION_PATCH == patch)
  12300. return 0;
  12301. else
  12302. return 1;
  12303. }
  12304. _ACEOF
  12305. if ac_fn_c_try_run "$LINENO"; then :
  12306. # Program compiled and ran, so get version by giving an argument,
  12307. # which will tell the program to print the output.
  12308. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  12309. # If the versions all match up, indicate success.
  12310. # Used to indicate true or false condition
  12311. ax_compare_version=false
  12312. # Convert the two version strings to be compared into a format that
  12313. # allows a simple string comparison. The end result is that a version
  12314. # string of the form 1.12.5-r617 will be converted to the form
  12315. # 0001001200050617. In other words, each number is zero padded to four
  12316. # digits, and non digits are removed.
  12317. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12318. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12319. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12320. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12321. -e 's/[^0-9]//g'`
  12322. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12323. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12324. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12325. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12326. -e 's/[^0-9]//g'`
  12327. # Pad zeros at end of numbers to make same length.
  12328. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  12329. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  12330. ax_compare_version_A="$ax_compare_version_tmp_A"
  12331. # Check for equality or inequality as necessary.
  12332. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  12333. if test "$ax_compare_version" = "true" ; then
  12334. ax_path_bdb_env_confirm_lib_ok=yes
  12335. fi
  12336. fi
  12337. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12338. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12339. fi
  12340. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  12341. fi
  12342. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  12343. # try format "dbXY"
  12344. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb$ax_path_bdb_env_get_version_MAJOR$ax_path_bdb_env_get_version_MINOR"
  12345. ax_path_bdb_env_confirm_lib_ok=no
  12346. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  12347. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  12348. # Compile and run a program that compares the version defined in
  12349. # the header file with a version defined in the library function
  12350. # db_version.
  12351. if test "$cross_compiling" = yes; then :
  12352. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12353. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12354. as_fn_error $? "cannot run test program while cross compiling
  12355. See \`config.log' for more details" "$LINENO" 5; }
  12356. else
  12357. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12358. /* end confdefs.h. */
  12359. #include <stdio.h>
  12360. #include <db.h>
  12361. int main(int argc,char **argv)
  12362. {
  12363. int major,minor,patch;
  12364. (void) argv;
  12365. db_version(&major,&minor,&patch);
  12366. if (argc > 1)
  12367. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12368. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12369. DB_VERSION_PATCH == patch)
  12370. return 0;
  12371. else
  12372. return 1;
  12373. }
  12374. _ACEOF
  12375. if ac_fn_c_try_run "$LINENO"; then :
  12376. # Program compiled and ran, so get version by giving an argument,
  12377. # which will tell the program to print the output.
  12378. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  12379. # If the versions all match up, indicate success.
  12380. # Used to indicate true or false condition
  12381. ax_compare_version=false
  12382. # Convert the two version strings to be compared into a format that
  12383. # allows a simple string comparison. The end result is that a version
  12384. # string of the form 1.12.5-r617 will be converted to the form
  12385. # 0001001200050617. In other words, each number is zero padded to four
  12386. # digits, and non digits are removed.
  12387. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12388. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12389. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12390. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12391. -e 's/[^0-9]//g'`
  12392. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12393. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12394. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12395. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12396. -e 's/[^0-9]//g'`
  12397. # Pad zeros at end of numbers to make same length.
  12398. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  12399. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  12400. ax_compare_version_A="$ax_compare_version_tmp_A"
  12401. # Check for equality or inequality as necessary.
  12402. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  12403. if test "$ax_compare_version" = "true" ; then
  12404. ax_path_bdb_env_confirm_lib_ok=yes
  12405. fi
  12406. fi
  12407. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12408. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12409. fi
  12410. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  12411. fi
  12412. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  12413. # try format "db-X"
  12414. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb-$ax_path_bdb_env_get_version_MAJOR"
  12415. ax_path_bdb_env_confirm_lib_ok=no
  12416. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  12417. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  12418. # Compile and run a program that compares the version defined in
  12419. # the header file with a version defined in the library function
  12420. # db_version.
  12421. if test "$cross_compiling" = yes; then :
  12422. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12423. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12424. as_fn_error $? "cannot run test program while cross compiling
  12425. See \`config.log' for more details" "$LINENO" 5; }
  12426. else
  12427. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12428. /* end confdefs.h. */
  12429. #include <stdio.h>
  12430. #include <db.h>
  12431. int main(int argc,char **argv)
  12432. {
  12433. int major,minor,patch;
  12434. (void) argv;
  12435. db_version(&major,&minor,&patch);
  12436. if (argc > 1)
  12437. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12438. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12439. DB_VERSION_PATCH == patch)
  12440. return 0;
  12441. else
  12442. return 1;
  12443. }
  12444. _ACEOF
  12445. if ac_fn_c_try_run "$LINENO"; then :
  12446. # Program compiled and ran, so get version by giving an argument,
  12447. # which will tell the program to print the output.
  12448. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  12449. # If the versions all match up, indicate success.
  12450. # Used to indicate true or false condition
  12451. ax_compare_version=false
  12452. # Convert the two version strings to be compared into a format that
  12453. # allows a simple string comparison. The end result is that a version
  12454. # string of the form 1.12.5-r617 will be converted to the form
  12455. # 0001001200050617. In other words, each number is zero padded to four
  12456. # digits, and non digits are removed.
  12457. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12458. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12459. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12460. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12461. -e 's/[^0-9]//g'`
  12462. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12463. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12464. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12465. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12466. -e 's/[^0-9]//g'`
  12467. # Pad zeros at end of numbers to make same length.
  12468. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  12469. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  12470. ax_compare_version_A="$ax_compare_version_tmp_A"
  12471. # Check for equality or inequality as necessary.
  12472. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  12473. if test "$ax_compare_version" = "true" ; then
  12474. ax_path_bdb_env_confirm_lib_ok=yes
  12475. fi
  12476. fi
  12477. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12478. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12479. fi
  12480. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  12481. fi
  12482. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  12483. # try format "dbX"
  12484. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb$ax_path_bdb_env_get_version_MAJOR"
  12485. ax_path_bdb_env_confirm_lib_ok=no
  12486. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  12487. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  12488. # Compile and run a program that compares the version defined in
  12489. # the header file with a version defined in the library function
  12490. # db_version.
  12491. if test "$cross_compiling" = yes; then :
  12492. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12493. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12494. as_fn_error $? "cannot run test program while cross compiling
  12495. See \`config.log' for more details" "$LINENO" 5; }
  12496. else
  12497. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12498. /* end confdefs.h. */
  12499. #include <stdio.h>
  12500. #include <db.h>
  12501. int main(int argc,char **argv)
  12502. {
  12503. int major,minor,patch;
  12504. (void) argv;
  12505. db_version(&major,&minor,&patch);
  12506. if (argc > 1)
  12507. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12508. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12509. DB_VERSION_PATCH == patch)
  12510. return 0;
  12511. else
  12512. return 1;
  12513. }
  12514. _ACEOF
  12515. if ac_fn_c_try_run "$LINENO"; then :
  12516. # Program compiled and ran, so get version by giving an argument,
  12517. # which will tell the program to print the output.
  12518. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  12519. # If the versions all match up, indicate success.
  12520. # Used to indicate true or false condition
  12521. ax_compare_version=false
  12522. # Convert the two version strings to be compared into a format that
  12523. # allows a simple string comparison. The end result is that a version
  12524. # string of the form 1.12.5-r617 will be converted to the form
  12525. # 0001001200050617. In other words, each number is zero padded to four
  12526. # digits, and non digits are removed.
  12527. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12528. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12529. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12530. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12531. -e 's/[^0-9]//g'`
  12532. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12533. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12534. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12535. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12536. -e 's/[^0-9]//g'`
  12537. # Pad zeros at end of numbers to make same length.
  12538. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  12539. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  12540. ax_compare_version_A="$ax_compare_version_tmp_A"
  12541. # Check for equality or inequality as necessary.
  12542. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  12543. if test "$ax_compare_version" = "true" ; then
  12544. ax_path_bdb_env_confirm_lib_ok=yes
  12545. fi
  12546. fi
  12547. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12548. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12549. fi
  12550. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  12551. fi
  12552. if test "$ax_path_bdb_env_confirm_lib_ok" = "yes" ; then
  12553. if test "x$ax_path_bdb_env_get_version_TEST_LIBNAME" = "x" ; then
  12554. { $as_echo "$as_me:${as_lineno-$LINENO}: result: none required" >&5
  12555. $as_echo "none required" >&6; }
  12556. else
  12557. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_env_get_version_TEST_LIBNAME" >&5
  12558. $as_echo "$ax_path_bdb_env_get_version_TEST_LIBNAME" >&6; }
  12559. fi
  12560. ax_path_bdb_env_get_version_VERSION="$ax_path_bdb_env_get_version_HEADER_VERSION"
  12561. ax_path_bdb_env_get_version_LIBS="$ax_path_bdb_env_get_version_TEST_LIBNAME"
  12562. ax_path_bdb_env_get_version_ok=yes
  12563. else
  12564. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  12565. $as_echo "no" >&6; }
  12566. fi
  12567. fi
  12568. if test "$ax_path_bdb_env_confirm_lib_ok" = "yes" ; then
  12569. # Used to indicate true or false condition
  12570. ax_compare_version=false
  12571. # Convert the two version strings to be compared into a format that
  12572. # allows a simple string comparison. The end result is that a version
  12573. # string of the form 1.12.5-r617 will be converted to the form
  12574. # 0001001200050617. In other words, each number is zero padded to four
  12575. # digits, and non digits are removed.
  12576. ax_compare_version_A=`echo "$ax_path_bdb_env_get_version_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12577. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12578. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12579. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12580. -e 's/[^0-9]//g'`
  12581. ax_compare_version_B=`echo "4" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12582. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12583. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12584. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12585. -e 's/[^0-9]//g'`
  12586. ax_compare_version=`echo "x$ax_compare_version_A
  12587. x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"`
  12588. if test "$ax_compare_version" = "true" ; then
  12589. # Found acceptable version in current environment.
  12590. ax_path_bdb_no_options_ok=yes
  12591. BDB_VERSION="$ax_path_bdb_env_get_version_VERSION"
  12592. BDB_LIBS="$ax_path_bdb_env_get_version_LIBS"
  12593. fi
  12594. fi
  12595. # Determine if we need to search /usr/local/BerkeleyDB*
  12596. ax_path_bdb_no_options_DONE=no
  12597. if test "xHIGHEST" = "xENVONLY" ; then
  12598. ax_path_bdb_no_options_DONE=yes
  12599. elif test "xHIGHEST" = "xENVFIRST" ; then
  12600. ax_path_bdb_no_options_DONE=$ax_path_bdb_no_options_ok
  12601. fi
  12602. if test "$ax_path_bdb_no_options_DONE" = "no" ; then
  12603. # Check for highest in /usr/local/BerkeleyDB*
  12604. ax_path_bdb_path_find_highest_ok=no
  12605. ax_path_bdb_path_find_highest_VERSION=''
  12606. ax_path_bdb_path_find_highest_DIR=''
  12607. # find highest verison in default install directory for Berkeley DB
  12608. for ax_path_bdb_path_find_highest_CURDIR in `ls -d /usr/local/BerkeleyDB* 2> /dev/null`
  12609. do
  12610. ax_path_bdb_path_get_version_ok=no
  12611. # Indicate status of checking for Berkeley DB header.
  12612. { $as_echo "$as_me:${as_lineno-$LINENO}: checking in $ax_path_bdb_path_find_highest_CURDIR/include for db.h" >&5
  12613. $as_echo_n "checking in $ax_path_bdb_path_find_highest_CURDIR/include for db.h... " >&6; }
  12614. ax_path_bdb_path_get_version_got_header=no
  12615. test -f "$ax_path_bdb_path_find_highest_CURDIR/include/db.h" && ax_path_bdb_path_get_version_got_header=yes
  12616. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_path_get_version_got_header" >&5
  12617. $as_echo "$ax_path_bdb_path_get_version_got_header" >&6; }
  12618. # Indicate status of checking for Berkeley DB library.
  12619. { $as_echo "$as_me:${as_lineno-$LINENO}: checking in $ax_path_bdb_path_find_highest_CURDIR/lib for library -ldb" >&5
  12620. $as_echo_n "checking in $ax_path_bdb_path_find_highest_CURDIR/lib for library -ldb... " >&6; }
  12621. ax_path_bdb_path_get_version_VERSION=''
  12622. if test -d "$ax_path_bdb_path_find_highest_CURDIR/include" && test -d "$ax_path_bdb_path_find_highest_CURDIR/lib" &&
  12623. test "$ax_path_bdb_path_get_version_got_header" = "yes" ; then
  12624. ax_path_bdb_path_get_version_save_CPPFLAGS="$CPPFLAGS"
  12625. CPPFLAGS="-I$ax_path_bdb_path_find_highest_CURDIR/include $CPPFLAGS"
  12626. ax_path_bdb_path_get_version_save_LIBS="$LIBS"
  12627. LIBS="$LIBS -ldb"
  12628. ax_path_bdb_path_get_version_save_LDFLAGS="$LDFLAGS"
  12629. LDFLAGS="-L$ax_path_bdb_path_find_highest_CURDIR/lib $LDFLAGS"
  12630. # Compile and run a program that compares the version defined in
  12631. # the header file with a version defined in the library function
  12632. # db_version.
  12633. if test "$cross_compiling" = yes; then :
  12634. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12635. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12636. as_fn_error $? "cannot run test program while cross compiling
  12637. See \`config.log' for more details" "$LINENO" 5; }
  12638. else
  12639. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12640. /* end confdefs.h. */
  12641. #include <stdio.h>
  12642. #include <db.h>
  12643. int main(int argc,char **argv)
  12644. {
  12645. int major,minor,patch;
  12646. (void) argv;
  12647. db_version(&major,&minor,&patch);
  12648. if (argc > 1)
  12649. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12650. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12651. DB_VERSION_PATCH == patch)
  12652. return 0;
  12653. else
  12654. return 1;
  12655. }
  12656. _ACEOF
  12657. if ac_fn_c_try_run "$LINENO"; then :
  12658. # Program compiled and ran, so get version by adding argument.
  12659. ax_path_bdb_path_get_version_VERSION=`./conftest$ac_exeext x`
  12660. ax_path_bdb_path_get_version_ok=yes
  12661. fi
  12662. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12663. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12664. fi
  12665. CPPFLAGS="$ax_path_bdb_path_get_version_save_CPPFLAGS"
  12666. LIBS="$ax_path_bdb_path_get_version_save_LIBS"
  12667. LDFLAGS="$ax_path_bdb_path_get_version_save_LDFLAGS"
  12668. fi
  12669. if test "$ax_path_bdb_path_get_version_ok" = "yes" ; then
  12670. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_path_get_version_VERSION" >&5
  12671. $as_echo "$ax_path_bdb_path_get_version_VERSION" >&6; }
  12672. # Used to indicate true or false condition
  12673. ax_compare_version=false
  12674. # Convert the two version strings to be compared into a format that
  12675. # allows a simple string comparison. The end result is that a version
  12676. # string of the form 1.12.5-r617 will be converted to the form
  12677. # 0001001200050617. In other words, each number is zero padded to four
  12678. # digits, and non digits are removed.
  12679. ax_compare_version_A=`echo "$ax_path_bdb_path_get_version_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12680. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12681. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12682. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12683. -e 's/[^0-9]//g'`
  12684. ax_compare_version_B=`echo "$ax_path_bdb_path_find_highest_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12685. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12686. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12687. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12688. -e 's/[^0-9]//g'`
  12689. ax_compare_version=`echo "x$ax_compare_version_A
  12690. x$ax_compare_version_B" | sed 's/^ *//' | sort | sed "s/x${ax_compare_version_A}/false/;s/x${ax_compare_version_B}/true/;1q"`
  12691. if test "$ax_compare_version" = "true" ; then
  12692. ax_path_bdb_path_find_highest_ok=yes
  12693. ax_path_bdb_path_find_highest_DIR="$ax_path_bdb_path_find_highest_CURDIR"
  12694. ax_path_bdb_path_find_highest_VERSION="$ax_path_bdb_path_get_version_VERSION"
  12695. fi
  12696. else
  12697. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  12698. $as_echo "no" >&6; }
  12699. fi
  12700. done
  12701. if test "$ax_path_bdb_path_find_highest_ok" = "yes" ; then
  12702. if test "$ax_path_bdb_no_options_ok" = "yes" ; then
  12703. # If we already have an acceptable version use this if higher.
  12704. # Used to indicate true or false condition
  12705. ax_compare_version=false
  12706. # Convert the two version strings to be compared into a format that
  12707. # allows a simple string comparison. The end result is that a version
  12708. # string of the form 1.12.5-r617 will be converted to the form
  12709. # 0001001200050617. In other words, each number is zero padded to four
  12710. # digits, and non digits are removed.
  12711. ax_compare_version_A=`echo "$ax_path_bdb_path_find_highest_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12712. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12713. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12714. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12715. -e 's/[^0-9]//g'`
  12716. ax_compare_version_B=`echo "$BDB_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12717. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12718. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12719. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12720. -e 's/[^0-9]//g'`
  12721. ax_compare_version=`echo "x$ax_compare_version_A
  12722. x$ax_compare_version_B" | sed 's/^ *//' | sort | sed "s/x${ax_compare_version_A}/false/;s/x${ax_compare_version_B}/true/;1q"`
  12723. if test "$ax_compare_version" = "true" ; then
  12724. :
  12725. fi
  12726. else
  12727. # Since we didn't have an acceptable version check if this one is.
  12728. # Used to indicate true or false condition
  12729. ax_compare_version=false
  12730. # Convert the two version strings to be compared into a format that
  12731. # allows a simple string comparison. The end result is that a version
  12732. # string of the form 1.12.5-r617 will be converted to the form
  12733. # 0001001200050617. In other words, each number is zero padded to four
  12734. # digits, and non digits are removed.
  12735. ax_compare_version_A=`echo "$ax_path_bdb_path_find_highest_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12736. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12737. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12738. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12739. -e 's/[^0-9]//g'`
  12740. ax_compare_version_B=`echo "4" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12741. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12742. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12743. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12744. -e 's/[^0-9]//g'`
  12745. ax_compare_version=`echo "x$ax_compare_version_A
  12746. x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"`
  12747. if test "$ax_compare_version" = "true" ; then
  12748. :
  12749. fi
  12750. fi
  12751. fi
  12752. if test "$ax_compare_version" = "true" ; then
  12753. ax_path_bdb_no_options_ok=yes
  12754. BDB_LIBS="-ldb"
  12755. if test "x$ax_path_bdb_path_find_highest_DIR" != x ; then
  12756. BDB_CPPFLAGS="-I$ax_path_bdb_path_find_highest_DIR/include"
  12757. BDB_LDFLAGS="-L$ax_path_bdb_path_find_highest_DIR/lib"
  12758. fi
  12759. BDB_VERSION="$ax_path_bdb_path_find_highest_VERSION"
  12760. fi
  12761. fi
  12762. fi
  12763. if test "$ax_path_bdb_no_options_ok" = "yes" ; then
  12764. { $as_echo "$as_me:${as_lineno-$LINENO}: using Berkeley DB version $BDB_VERSION" >&5
  12765. $as_echo "$as_me: using Berkeley DB version $BDB_VERSION" >&6;}
  12766. $as_echo "#define HAVE_DB_H 1" >>confdefs.h
  12767. ax_path_bdb_ok=yes
  12768. else
  12769. { $as_echo "$as_me:${as_lineno-$LINENO}: no Berkeley DB version 4 or higher found" >&5
  12770. $as_echo "$as_me: no Berkeley DB version 4 or higher found" >&6;}
  12771. fi
  12772. else
  12773. # Set --with-bdb-dir option.
  12774. ax_path_bdb_INC="$with_bdb_dir/include"
  12775. ax_path_bdb_LIB="$with_bdb_dir/lib"
  12776. ax_path_bdb_save_CPPFLAGS="$CPPFLAGS"
  12777. CPPFLAGS="-I$ax_path_bdb_INC $CPPFLAGS"
  12778. ax_path_bdb_save_LDFLAGS=$LDFLAGS
  12779. LDFLAGS="-L$ax_path_bdb_LIB $LDFLAGS"
  12780. # Check for specific header file db.h
  12781. { $as_echo "$as_me:${as_lineno-$LINENO}: checking db.h presence in $ax_path_bdb_INC" >&5
  12782. $as_echo_n "checking db.h presence in $ax_path_bdb_INC... " >&6; }
  12783. if test -f "$ax_path_bdb_INC/db.h" ; then
  12784. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  12785. $as_echo "yes" >&6; }
  12786. # Check for library
  12787. ax_path_bdb_no_options_ok=no
  12788. # Values to add to environment to use Berkeley DB.
  12789. BDB_VERSION=''
  12790. BDB_LIBS=''
  12791. BDB_CPPFLAGS=''
  12792. BDB_LDFLAGS=''
  12793. # Check cross compilation here.
  12794. if test "x$cross_compiling" = "xyes" ; then
  12795. # If cross compiling, can't use AC_RUN_IFELSE so do these tests.
  12796. # The AC_PREPROC_IFELSE confirms that db.h is preprocessable,
  12797. # and extracts the version number from it.
  12798. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for db.h" >&5
  12799. $as_echo_n "checking for db.h... " >&6; }
  12800. ax_path_bdb_no_options_HEADER_VERSION=''
  12801. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12802. /* end confdefs.h. */
  12803. #include <db.h>
  12804. AX_PATH_BDB_STUFF DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH
  12805. _ACEOF
  12806. if ac_fn_c_try_cpp "$LINENO"; then :
  12807. # Extract version from preprocessor output.
  12808. ax_path_bdb_no_options_HEADER_VERSION=`eval "$ac_cpp conftest.$ac_ext" 2> /dev/null \
  12809. | grep AX_PATH_BDB_STUFF | sed 's/[^0-9,]//g;s/,/./g;1q'`
  12810. fi
  12811. rm -f conftest.err conftest.i conftest.$ac_ext
  12812. if test "x$ax_path_bdb_no_options_HEADER_VERSION" = "x" ; then
  12813. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  12814. $as_echo "no" >&6; }
  12815. else
  12816. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_no_options_HEADER_VERSION" >&5
  12817. $as_echo "$ax_path_bdb_no_options_HEADER_VERSION" >&6; }
  12818. # Check that version is high enough.
  12819. # Used to indicate true or false condition
  12820. ax_compare_version=false
  12821. # Convert the two version strings to be compared into a format that
  12822. # allows a simple string comparison. The end result is that a version
  12823. # string of the form 1.12.5-r617 will be converted to the form
  12824. # 0001001200050617. In other words, each number is zero padded to four
  12825. # digits, and non digits are removed.
  12826. ax_compare_version_A=`echo "$ax_path_bdb_no_options_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12827. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12828. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12829. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12830. -e 's/[^0-9]//g'`
  12831. ax_compare_version_B=`echo "4" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  12832. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  12833. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  12834. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  12835. -e 's/[^0-9]//g'`
  12836. ax_compare_version=`echo "x$ax_compare_version_A
  12837. x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"`
  12838. if test "$ax_compare_version" = "true" ; then
  12839. # get major and minor version numbers
  12840. ax_path_bdb_no_options_MAJOR=`echo $ax_path_bdb_no_options_HEADER_VERSION | sed 's,\..*,,'`
  12841. ax_path_bdb_no_options_MINOR=`echo $ax_path_bdb_no_options_HEADER_VERSION | sed 's,^[0-9]*\.,,;s,\.[0-9]*$,,'`
  12842. ax_path_bdb_no_options_save_LIBS="$LIBS"
  12843. # Check that we can link with the library.
  12844. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing db_version" >&5
  12845. $as_echo_n "checking for library containing db_version... " >&6; }
  12846. if ${ac_cv_search_db_version+:} false; then :
  12847. $as_echo_n "(cached) " >&6
  12848. else
  12849. ac_func_search_save_LIBS=$LIBS
  12850. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12851. /* end confdefs.h. */
  12852. /* Override any GCC internal prototype to avoid an error.
  12853. Use char because int might match the return type of a GCC
  12854. builtin and then its argument prototype would still apply. */
  12855. #ifdef __cplusplus
  12856. extern "C"
  12857. #endif
  12858. char db_version ();
  12859. int
  12860. main ()
  12861. {
  12862. return db_version ();
  12863. ;
  12864. return 0;
  12865. }
  12866. _ACEOF
  12867. for ac_lib in '' db db-$ax_path_bdb_no_options_MAJOR.$ax_path_bdb_no_options_MINOR db$ax_path_bdb_no_options_MAJOR.$ax_path_bdb_no_options_MINOR db$ax_path_bdb_no_options_MAJOR$ax_path_bdb_no_options_MINOR db-$ax_path_bdb_no_options_MAJOR db$ax_path_bdb_no_options_MAJOR; do
  12868. if test -z "$ac_lib"; then
  12869. ac_res="none required"
  12870. else
  12871. ac_res=-l$ac_lib
  12872. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  12873. fi
  12874. if ac_fn_c_try_link "$LINENO"; then :
  12875. ac_cv_search_db_version=$ac_res
  12876. fi
  12877. rm -f core conftest.err conftest.$ac_objext \
  12878. conftest$ac_exeext
  12879. if ${ac_cv_search_db_version+:} false; then :
  12880. break
  12881. fi
  12882. done
  12883. if ${ac_cv_search_db_version+:} false; then :
  12884. else
  12885. ac_cv_search_db_version=no
  12886. fi
  12887. rm conftest.$ac_ext
  12888. LIBS=$ac_func_search_save_LIBS
  12889. fi
  12890. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_db_version" >&5
  12891. $as_echo "$ac_cv_search_db_version" >&6; }
  12892. ac_res=$ac_cv_search_db_version
  12893. if test "$ac_res" != no; then :
  12894. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  12895. # Sucessfully found library.
  12896. ax_path_bdb_no_options_ok=yes
  12897. BDB_VERSION=$ax_path_bdb_no_options_HEADER_VERSION
  12898. # Extract library from LIBS
  12899. ax_path_bdb_no_options_LEN=` \
  12900. echo "x$ax_path_bdb_no_options_save_LIBS" \
  12901. | awk '{print(length)}'`
  12902. BDB_LIBS=`echo "x$LIBS " \
  12903. | sed "s/.\{$ax_path_bdb_no_options_LEN\}\$//;s/^x//;s/ //g"`
  12904. fi
  12905. LIBS="$ax_path_bdb_no_options_save_LIBS"
  12906. fi
  12907. fi
  12908. else
  12909. # Not cross compiling.
  12910. # Check version of Berkeley DB in the current environment.
  12911. ax_path_bdb_env_get_version_ok=no
  12912. ax_path_bdb_env_get_version_VERSION=''
  12913. ax_path_bdb_env_get_version_LIBS=''
  12914. # Indicate status of checking for Berkeley DB library.
  12915. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for db.h" >&5
  12916. $as_echo_n "checking for db.h... " >&6; }
  12917. # Compile and run a program that determines the Berkeley DB version
  12918. # in the header file db.h.
  12919. ax_path_bdb_env_get_version_HEADER_VERSION=''
  12920. if test "$cross_compiling" = yes; then :
  12921. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  12922. $as_echo "no" >&6; }
  12923. else
  12924. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12925. /* end confdefs.h. */
  12926. #include <stdio.h>
  12927. #include <db.h>
  12928. int main(int argc,char **argv)
  12929. {
  12930. (void) argv;
  12931. if (argc > 1)
  12932. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12933. return 0;
  12934. }
  12935. _ACEOF
  12936. if ac_fn_c_try_run "$LINENO"; then :
  12937. # Program compiled and ran, so get version by adding an argument.
  12938. ax_path_bdb_env_get_version_HEADER_VERSION=`./conftest$ac_exeext x`
  12939. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_env_get_version_HEADER_VERSION" >&5
  12940. $as_echo "$ax_path_bdb_env_get_version_HEADER_VERSION" >&6; }
  12941. else
  12942. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  12943. $as_echo "no" >&6; }
  12944. fi
  12945. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12946. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12947. fi
  12948. # Have header version, so try to find corresponding library.
  12949. # Looks for library names in the order:
  12950. # nothing, db, db-X.Y, dbX.Y, dbXY, db-X, dbX
  12951. # and stops when it finds the first one that matches the version
  12952. # of the header file.
  12953. if test "x$ax_path_bdb_env_get_version_HEADER_VERSION" != "x" ; then
  12954. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing Berkeley DB $ax_path_bdb_env_get_version_HEADER_VERSION" >&5
  12955. $as_echo_n "checking for library containing Berkeley DB $ax_path_bdb_env_get_version_HEADER_VERSION... " >&6; }
  12956. # get major and minor version numbers
  12957. ax_path_bdb_env_get_version_MAJOR=`echo $ax_path_bdb_env_get_version_HEADER_VERSION | sed 's,\..*,,'`
  12958. ax_path_bdb_env_get_version_MINOR=`echo $ax_path_bdb_env_get_version_HEADER_VERSION | sed 's,^[0-9]*\.,,;s,\.[0-9]*$,,'`
  12959. # see if it is already specified in LIBS
  12960. ax_path_bdb_env_get_version_TEST_LIBNAME=''
  12961. ax_path_bdb_env_confirm_lib_ok=no
  12962. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  12963. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  12964. # Compile and run a program that compares the version defined in
  12965. # the header file with a version defined in the library function
  12966. # db_version.
  12967. if test "$cross_compiling" = yes; then :
  12968. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  12969. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  12970. as_fn_error $? "cannot run test program while cross compiling
  12971. See \`config.log' for more details" "$LINENO" 5; }
  12972. else
  12973. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12974. /* end confdefs.h. */
  12975. #include <stdio.h>
  12976. #include <db.h>
  12977. int main(int argc,char **argv)
  12978. {
  12979. int major,minor,patch;
  12980. (void) argv;
  12981. db_version(&major,&minor,&patch);
  12982. if (argc > 1)
  12983. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  12984. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  12985. DB_VERSION_PATCH == patch)
  12986. return 0;
  12987. else
  12988. return 1;
  12989. }
  12990. _ACEOF
  12991. if ac_fn_c_try_run "$LINENO"; then :
  12992. # Program compiled and ran, so get version by giving an argument,
  12993. # which will tell the program to print the output.
  12994. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  12995. # If the versions all match up, indicate success.
  12996. # Used to indicate true or false condition
  12997. ax_compare_version=false
  12998. # Convert the two version strings to be compared into a format that
  12999. # allows a simple string comparison. The end result is that a version
  13000. # string of the form 1.12.5-r617 will be converted to the form
  13001. # 0001001200050617. In other words, each number is zero padded to four
  13002. # digits, and non digits are removed.
  13003. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13004. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13005. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13006. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13007. -e 's/[^0-9]//g'`
  13008. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13009. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13010. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13011. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13012. -e 's/[^0-9]//g'`
  13013. # Pad zeros at end of numbers to make same length.
  13014. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  13015. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  13016. ax_compare_version_A="$ax_compare_version_tmp_A"
  13017. # Check for equality or inequality as necessary.
  13018. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  13019. if test "$ax_compare_version" = "true" ; then
  13020. ax_path_bdb_env_confirm_lib_ok=yes
  13021. fi
  13022. fi
  13023. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13024. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13025. fi
  13026. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  13027. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  13028. # try format "db"
  13029. ax_path_bdb_env_get_version_TEST_LIBNAME='-ldb'
  13030. ax_path_bdb_env_confirm_lib_ok=no
  13031. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  13032. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  13033. # Compile and run a program that compares the version defined in
  13034. # the header file with a version defined in the library function
  13035. # db_version.
  13036. if test "$cross_compiling" = yes; then :
  13037. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13038. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13039. as_fn_error $? "cannot run test program while cross compiling
  13040. See \`config.log' for more details" "$LINENO" 5; }
  13041. else
  13042. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13043. /* end confdefs.h. */
  13044. #include <stdio.h>
  13045. #include <db.h>
  13046. int main(int argc,char **argv)
  13047. {
  13048. int major,minor,patch;
  13049. (void) argv;
  13050. db_version(&major,&minor,&patch);
  13051. if (argc > 1)
  13052. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  13053. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  13054. DB_VERSION_PATCH == patch)
  13055. return 0;
  13056. else
  13057. return 1;
  13058. }
  13059. _ACEOF
  13060. if ac_fn_c_try_run "$LINENO"; then :
  13061. # Program compiled and ran, so get version by giving an argument,
  13062. # which will tell the program to print the output.
  13063. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  13064. # If the versions all match up, indicate success.
  13065. # Used to indicate true or false condition
  13066. ax_compare_version=false
  13067. # Convert the two version strings to be compared into a format that
  13068. # allows a simple string comparison. The end result is that a version
  13069. # string of the form 1.12.5-r617 will be converted to the form
  13070. # 0001001200050617. In other words, each number is zero padded to four
  13071. # digits, and non digits are removed.
  13072. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13073. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13074. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13075. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13076. -e 's/[^0-9]//g'`
  13077. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13078. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13079. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13080. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13081. -e 's/[^0-9]//g'`
  13082. # Pad zeros at end of numbers to make same length.
  13083. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  13084. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  13085. ax_compare_version_A="$ax_compare_version_tmp_A"
  13086. # Check for equality or inequality as necessary.
  13087. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  13088. if test "$ax_compare_version" = "true" ; then
  13089. ax_path_bdb_env_confirm_lib_ok=yes
  13090. fi
  13091. fi
  13092. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13093. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13094. fi
  13095. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  13096. fi
  13097. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  13098. # try format "db-X.Y"
  13099. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb-${ax_path_bdb_env_get_version_MAJOR}.$ax_path_bdb_env_get_version_MINOR"
  13100. ax_path_bdb_env_confirm_lib_ok=no
  13101. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  13102. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  13103. # Compile and run a program that compares the version defined in
  13104. # the header file with a version defined in the library function
  13105. # db_version.
  13106. if test "$cross_compiling" = yes; then :
  13107. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13108. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13109. as_fn_error $? "cannot run test program while cross compiling
  13110. See \`config.log' for more details" "$LINENO" 5; }
  13111. else
  13112. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13113. /* end confdefs.h. */
  13114. #include <stdio.h>
  13115. #include <db.h>
  13116. int main(int argc,char **argv)
  13117. {
  13118. int major,minor,patch;
  13119. (void) argv;
  13120. db_version(&major,&minor,&patch);
  13121. if (argc > 1)
  13122. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  13123. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  13124. DB_VERSION_PATCH == patch)
  13125. return 0;
  13126. else
  13127. return 1;
  13128. }
  13129. _ACEOF
  13130. if ac_fn_c_try_run "$LINENO"; then :
  13131. # Program compiled and ran, so get version by giving an argument,
  13132. # which will tell the program to print the output.
  13133. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  13134. # If the versions all match up, indicate success.
  13135. # Used to indicate true or false condition
  13136. ax_compare_version=false
  13137. # Convert the two version strings to be compared into a format that
  13138. # allows a simple string comparison. The end result is that a version
  13139. # string of the form 1.12.5-r617 will be converted to the form
  13140. # 0001001200050617. In other words, each number is zero padded to four
  13141. # digits, and non digits are removed.
  13142. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13143. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13144. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13145. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13146. -e 's/[^0-9]//g'`
  13147. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13148. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13149. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13150. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13151. -e 's/[^0-9]//g'`
  13152. # Pad zeros at end of numbers to make same length.
  13153. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  13154. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  13155. ax_compare_version_A="$ax_compare_version_tmp_A"
  13156. # Check for equality or inequality as necessary.
  13157. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  13158. if test "$ax_compare_version" = "true" ; then
  13159. ax_path_bdb_env_confirm_lib_ok=yes
  13160. fi
  13161. fi
  13162. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13163. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13164. fi
  13165. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  13166. fi
  13167. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  13168. # try format "dbX.Y"
  13169. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb${ax_path_bdb_env_get_version_MAJOR}.$ax_path_bdb_env_get_version_MINOR"
  13170. ax_path_bdb_env_confirm_lib_ok=no
  13171. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  13172. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  13173. # Compile and run a program that compares the version defined in
  13174. # the header file with a version defined in the library function
  13175. # db_version.
  13176. if test "$cross_compiling" = yes; then :
  13177. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13178. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13179. as_fn_error $? "cannot run test program while cross compiling
  13180. See \`config.log' for more details" "$LINENO" 5; }
  13181. else
  13182. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13183. /* end confdefs.h. */
  13184. #include <stdio.h>
  13185. #include <db.h>
  13186. int main(int argc,char **argv)
  13187. {
  13188. int major,minor,patch;
  13189. (void) argv;
  13190. db_version(&major,&minor,&patch);
  13191. if (argc > 1)
  13192. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  13193. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  13194. DB_VERSION_PATCH == patch)
  13195. return 0;
  13196. else
  13197. return 1;
  13198. }
  13199. _ACEOF
  13200. if ac_fn_c_try_run "$LINENO"; then :
  13201. # Program compiled and ran, so get version by giving an argument,
  13202. # which will tell the program to print the output.
  13203. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  13204. # If the versions all match up, indicate success.
  13205. # Used to indicate true or false condition
  13206. ax_compare_version=false
  13207. # Convert the two version strings to be compared into a format that
  13208. # allows a simple string comparison. The end result is that a version
  13209. # string of the form 1.12.5-r617 will be converted to the form
  13210. # 0001001200050617. In other words, each number is zero padded to four
  13211. # digits, and non digits are removed.
  13212. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13213. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13214. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13215. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13216. -e 's/[^0-9]//g'`
  13217. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13218. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13219. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13220. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13221. -e 's/[^0-9]//g'`
  13222. # Pad zeros at end of numbers to make same length.
  13223. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  13224. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  13225. ax_compare_version_A="$ax_compare_version_tmp_A"
  13226. # Check for equality or inequality as necessary.
  13227. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  13228. if test "$ax_compare_version" = "true" ; then
  13229. ax_path_bdb_env_confirm_lib_ok=yes
  13230. fi
  13231. fi
  13232. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13233. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13234. fi
  13235. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  13236. fi
  13237. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  13238. # try format "dbXY"
  13239. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb$ax_path_bdb_env_get_version_MAJOR$ax_path_bdb_env_get_version_MINOR"
  13240. ax_path_bdb_env_confirm_lib_ok=no
  13241. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  13242. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  13243. # Compile and run a program that compares the version defined in
  13244. # the header file with a version defined in the library function
  13245. # db_version.
  13246. if test "$cross_compiling" = yes; then :
  13247. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13248. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13249. as_fn_error $? "cannot run test program while cross compiling
  13250. See \`config.log' for more details" "$LINENO" 5; }
  13251. else
  13252. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13253. /* end confdefs.h. */
  13254. #include <stdio.h>
  13255. #include <db.h>
  13256. int main(int argc,char **argv)
  13257. {
  13258. int major,minor,patch;
  13259. (void) argv;
  13260. db_version(&major,&minor,&patch);
  13261. if (argc > 1)
  13262. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  13263. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  13264. DB_VERSION_PATCH == patch)
  13265. return 0;
  13266. else
  13267. return 1;
  13268. }
  13269. _ACEOF
  13270. if ac_fn_c_try_run "$LINENO"; then :
  13271. # Program compiled and ran, so get version by giving an argument,
  13272. # which will tell the program to print the output.
  13273. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  13274. # If the versions all match up, indicate success.
  13275. # Used to indicate true or false condition
  13276. ax_compare_version=false
  13277. # Convert the two version strings to be compared into a format that
  13278. # allows a simple string comparison. The end result is that a version
  13279. # string of the form 1.12.5-r617 will be converted to the form
  13280. # 0001001200050617. In other words, each number is zero padded to four
  13281. # digits, and non digits are removed.
  13282. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13283. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13284. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13285. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13286. -e 's/[^0-9]//g'`
  13287. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13288. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13289. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13290. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13291. -e 's/[^0-9]//g'`
  13292. # Pad zeros at end of numbers to make same length.
  13293. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  13294. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  13295. ax_compare_version_A="$ax_compare_version_tmp_A"
  13296. # Check for equality or inequality as necessary.
  13297. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  13298. if test "$ax_compare_version" = "true" ; then
  13299. ax_path_bdb_env_confirm_lib_ok=yes
  13300. fi
  13301. fi
  13302. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13303. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13304. fi
  13305. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  13306. fi
  13307. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  13308. # try format "db-X"
  13309. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb-$ax_path_bdb_env_get_version_MAJOR"
  13310. ax_path_bdb_env_confirm_lib_ok=no
  13311. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  13312. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  13313. # Compile and run a program that compares the version defined in
  13314. # the header file with a version defined in the library function
  13315. # db_version.
  13316. if test "$cross_compiling" = yes; then :
  13317. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13318. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13319. as_fn_error $? "cannot run test program while cross compiling
  13320. See \`config.log' for more details" "$LINENO" 5; }
  13321. else
  13322. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13323. /* end confdefs.h. */
  13324. #include <stdio.h>
  13325. #include <db.h>
  13326. int main(int argc,char **argv)
  13327. {
  13328. int major,minor,patch;
  13329. (void) argv;
  13330. db_version(&major,&minor,&patch);
  13331. if (argc > 1)
  13332. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  13333. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  13334. DB_VERSION_PATCH == patch)
  13335. return 0;
  13336. else
  13337. return 1;
  13338. }
  13339. _ACEOF
  13340. if ac_fn_c_try_run "$LINENO"; then :
  13341. # Program compiled and ran, so get version by giving an argument,
  13342. # which will tell the program to print the output.
  13343. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  13344. # If the versions all match up, indicate success.
  13345. # Used to indicate true or false condition
  13346. ax_compare_version=false
  13347. # Convert the two version strings to be compared into a format that
  13348. # allows a simple string comparison. The end result is that a version
  13349. # string of the form 1.12.5-r617 will be converted to the form
  13350. # 0001001200050617. In other words, each number is zero padded to four
  13351. # digits, and non digits are removed.
  13352. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13353. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13354. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13355. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13356. -e 's/[^0-9]//g'`
  13357. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13358. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13359. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13360. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13361. -e 's/[^0-9]//g'`
  13362. # Pad zeros at end of numbers to make same length.
  13363. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  13364. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  13365. ax_compare_version_A="$ax_compare_version_tmp_A"
  13366. # Check for equality or inequality as necessary.
  13367. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  13368. if test "$ax_compare_version" = "true" ; then
  13369. ax_path_bdb_env_confirm_lib_ok=yes
  13370. fi
  13371. fi
  13372. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13373. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13374. fi
  13375. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  13376. fi
  13377. if test "$ax_path_bdb_env_confirm_lib_ok" = "no" ; then
  13378. # try format "dbX"
  13379. ax_path_bdb_env_get_version_TEST_LIBNAME="-ldb$ax_path_bdb_env_get_version_MAJOR"
  13380. ax_path_bdb_env_confirm_lib_ok=no
  13381. ax_path_bdb_env_confirm_lib_save_LIBS="$LIBS"
  13382. LIBS="$LIBS $ax_path_bdb_env_get_version_TEST_LIBNAME"
  13383. # Compile and run a program that compares the version defined in
  13384. # the header file with a version defined in the library function
  13385. # db_version.
  13386. if test "$cross_compiling" = yes; then :
  13387. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13388. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13389. as_fn_error $? "cannot run test program while cross compiling
  13390. See \`config.log' for more details" "$LINENO" 5; }
  13391. else
  13392. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13393. /* end confdefs.h. */
  13394. #include <stdio.h>
  13395. #include <db.h>
  13396. int main(int argc,char **argv)
  13397. {
  13398. int major,minor,patch;
  13399. (void) argv;
  13400. db_version(&major,&minor,&patch);
  13401. if (argc > 1)
  13402. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  13403. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  13404. DB_VERSION_PATCH == patch)
  13405. return 0;
  13406. else
  13407. return 1;
  13408. }
  13409. _ACEOF
  13410. if ac_fn_c_try_run "$LINENO"; then :
  13411. # Program compiled and ran, so get version by giving an argument,
  13412. # which will tell the program to print the output.
  13413. ax_path_bdb_env_confirm_lib_VERSION=`./conftest$ac_exeext x`
  13414. # If the versions all match up, indicate success.
  13415. # Used to indicate true or false condition
  13416. ax_compare_version=false
  13417. # Convert the two version strings to be compared into a format that
  13418. # allows a simple string comparison. The end result is that a version
  13419. # string of the form 1.12.5-r617 will be converted to the form
  13420. # 0001001200050617. In other words, each number is zero padded to four
  13421. # digits, and non digits are removed.
  13422. ax_compare_version_A=`echo "$ax_path_bdb_env_confirm_lib_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13423. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13424. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13425. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13426. -e 's/[^0-9]//g'`
  13427. ax_compare_version_B=`echo "$ax_path_bdb_env_get_version_HEADER_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13428. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13429. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13430. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13431. -e 's/[^0-9]//g'`
  13432. # Pad zeros at end of numbers to make same length.
  13433. ax_compare_version_tmp_A="$ax_compare_version_A`echo $ax_compare_version_B | sed 's/./0/g'`"
  13434. ax_compare_version_B="$ax_compare_version_B`echo $ax_compare_version_A | sed 's/./0/g'`"
  13435. ax_compare_version_A="$ax_compare_version_tmp_A"
  13436. # Check for equality or inequality as necessary.
  13437. test "x$ax_compare_version_A" = "x$ax_compare_version_B" && ax_compare_version=true
  13438. if test "$ax_compare_version" = "true" ; then
  13439. ax_path_bdb_env_confirm_lib_ok=yes
  13440. fi
  13441. fi
  13442. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13443. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13444. fi
  13445. LIBS="$ax_path_bdb_env_confirm_lib_save_LIBS"
  13446. fi
  13447. if test "$ax_path_bdb_env_confirm_lib_ok" = "yes" ; then
  13448. if test "x$ax_path_bdb_env_get_version_TEST_LIBNAME" = "x" ; then
  13449. { $as_echo "$as_me:${as_lineno-$LINENO}: result: none required" >&5
  13450. $as_echo "none required" >&6; }
  13451. else
  13452. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_env_get_version_TEST_LIBNAME" >&5
  13453. $as_echo "$ax_path_bdb_env_get_version_TEST_LIBNAME" >&6; }
  13454. fi
  13455. ax_path_bdb_env_get_version_VERSION="$ax_path_bdb_env_get_version_HEADER_VERSION"
  13456. ax_path_bdb_env_get_version_LIBS="$ax_path_bdb_env_get_version_TEST_LIBNAME"
  13457. ax_path_bdb_env_get_version_ok=yes
  13458. else
  13459. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13460. $as_echo "no" >&6; }
  13461. fi
  13462. fi
  13463. if test "$ax_path_bdb_env_confirm_lib_ok" = "yes" ; then
  13464. # Used to indicate true or false condition
  13465. ax_compare_version=false
  13466. # Convert the two version strings to be compared into a format that
  13467. # allows a simple string comparison. The end result is that a version
  13468. # string of the form 1.12.5-r617 will be converted to the form
  13469. # 0001001200050617. In other words, each number is zero padded to four
  13470. # digits, and non digits are removed.
  13471. ax_compare_version_A=`echo "$ax_path_bdb_env_get_version_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13472. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13473. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13474. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13475. -e 's/[^0-9]//g'`
  13476. ax_compare_version_B=`echo "4" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13477. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13478. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13479. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13480. -e 's/[^0-9]//g'`
  13481. ax_compare_version=`echo "x$ax_compare_version_A
  13482. x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"`
  13483. if test "$ax_compare_version" = "true" ; then
  13484. # Found acceptable version in current environment.
  13485. ax_path_bdb_no_options_ok=yes
  13486. BDB_VERSION="$ax_path_bdb_env_get_version_VERSION"
  13487. BDB_LIBS="$ax_path_bdb_env_get_version_LIBS"
  13488. fi
  13489. fi
  13490. # Determine if we need to search /usr/local/BerkeleyDB*
  13491. ax_path_bdb_no_options_DONE=no
  13492. if test "xENVONLY" = "xENVONLY" ; then
  13493. ax_path_bdb_no_options_DONE=yes
  13494. elif test "xENVONLY" = "xENVFIRST" ; then
  13495. ax_path_bdb_no_options_DONE=$ax_path_bdb_no_options_ok
  13496. fi
  13497. if test "$ax_path_bdb_no_options_DONE" = "no" ; then
  13498. # Check for highest in /usr/local/BerkeleyDB*
  13499. ax_path_bdb_path_find_highest_ok=no
  13500. ax_path_bdb_path_find_highest_VERSION=''
  13501. ax_path_bdb_path_find_highest_DIR=''
  13502. # find highest verison in default install directory for Berkeley DB
  13503. for ax_path_bdb_path_find_highest_CURDIR in `ls -d /usr/local/BerkeleyDB* 2> /dev/null`
  13504. do
  13505. ax_path_bdb_path_get_version_ok=no
  13506. # Indicate status of checking for Berkeley DB header.
  13507. { $as_echo "$as_me:${as_lineno-$LINENO}: checking in $ax_path_bdb_path_find_highest_CURDIR/include for db.h" >&5
  13508. $as_echo_n "checking in $ax_path_bdb_path_find_highest_CURDIR/include for db.h... " >&6; }
  13509. ax_path_bdb_path_get_version_got_header=no
  13510. test -f "$ax_path_bdb_path_find_highest_CURDIR/include/db.h" && ax_path_bdb_path_get_version_got_header=yes
  13511. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_path_get_version_got_header" >&5
  13512. $as_echo "$ax_path_bdb_path_get_version_got_header" >&6; }
  13513. # Indicate status of checking for Berkeley DB library.
  13514. { $as_echo "$as_me:${as_lineno-$LINENO}: checking in $ax_path_bdb_path_find_highest_CURDIR/lib for library -ldb" >&5
  13515. $as_echo_n "checking in $ax_path_bdb_path_find_highest_CURDIR/lib for library -ldb... " >&6; }
  13516. ax_path_bdb_path_get_version_VERSION=''
  13517. if test -d "$ax_path_bdb_path_find_highest_CURDIR/include" && test -d "$ax_path_bdb_path_find_highest_CURDIR/lib" &&
  13518. test "$ax_path_bdb_path_get_version_got_header" = "yes" ; then
  13519. ax_path_bdb_path_get_version_save_CPPFLAGS="$CPPFLAGS"
  13520. CPPFLAGS="-I$ax_path_bdb_path_find_highest_CURDIR/include $CPPFLAGS"
  13521. ax_path_bdb_path_get_version_save_LIBS="$LIBS"
  13522. LIBS="$LIBS -ldb"
  13523. ax_path_bdb_path_get_version_save_LDFLAGS="$LDFLAGS"
  13524. LDFLAGS="-L$ax_path_bdb_path_find_highest_CURDIR/lib $LDFLAGS"
  13525. # Compile and run a program that compares the version defined in
  13526. # the header file with a version defined in the library function
  13527. # db_version.
  13528. if test "$cross_compiling" = yes; then :
  13529. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13530. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13531. as_fn_error $? "cannot run test program while cross compiling
  13532. See \`config.log' for more details" "$LINENO" 5; }
  13533. else
  13534. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13535. /* end confdefs.h. */
  13536. #include <stdio.h>
  13537. #include <db.h>
  13538. int main(int argc,char **argv)
  13539. {
  13540. int major,minor,patch;
  13541. (void) argv;
  13542. db_version(&major,&minor,&patch);
  13543. if (argc > 1)
  13544. printf("%d.%d.%d\n",DB_VERSION_MAJOR,DB_VERSION_MINOR,DB_VERSION_PATCH);
  13545. if (DB_VERSION_MAJOR == major && DB_VERSION_MINOR == minor &&
  13546. DB_VERSION_PATCH == patch)
  13547. return 0;
  13548. else
  13549. return 1;
  13550. }
  13551. _ACEOF
  13552. if ac_fn_c_try_run "$LINENO"; then :
  13553. # Program compiled and ran, so get version by adding argument.
  13554. ax_path_bdb_path_get_version_VERSION=`./conftest$ac_exeext x`
  13555. ax_path_bdb_path_get_version_ok=yes
  13556. fi
  13557. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13558. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13559. fi
  13560. CPPFLAGS="$ax_path_bdb_path_get_version_save_CPPFLAGS"
  13561. LIBS="$ax_path_bdb_path_get_version_save_LIBS"
  13562. LDFLAGS="$ax_path_bdb_path_get_version_save_LDFLAGS"
  13563. fi
  13564. if test "$ax_path_bdb_path_get_version_ok" = "yes" ; then
  13565. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_path_bdb_path_get_version_VERSION" >&5
  13566. $as_echo "$ax_path_bdb_path_get_version_VERSION" >&6; }
  13567. # Used to indicate true or false condition
  13568. ax_compare_version=false
  13569. # Convert the two version strings to be compared into a format that
  13570. # allows a simple string comparison. The end result is that a version
  13571. # string of the form 1.12.5-r617 will be converted to the form
  13572. # 0001001200050617. In other words, each number is zero padded to four
  13573. # digits, and non digits are removed.
  13574. ax_compare_version_A=`echo "$ax_path_bdb_path_get_version_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13575. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13576. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13577. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13578. -e 's/[^0-9]//g'`
  13579. ax_compare_version_B=`echo "$ax_path_bdb_path_find_highest_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13580. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13581. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13582. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13583. -e 's/[^0-9]//g'`
  13584. ax_compare_version=`echo "x$ax_compare_version_A
  13585. x$ax_compare_version_B" | sed 's/^ *//' | sort | sed "s/x${ax_compare_version_A}/false/;s/x${ax_compare_version_B}/true/;1q"`
  13586. if test "$ax_compare_version" = "true" ; then
  13587. ax_path_bdb_path_find_highest_ok=yes
  13588. ax_path_bdb_path_find_highest_DIR="$ax_path_bdb_path_find_highest_CURDIR"
  13589. ax_path_bdb_path_find_highest_VERSION="$ax_path_bdb_path_get_version_VERSION"
  13590. fi
  13591. else
  13592. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13593. $as_echo "no" >&6; }
  13594. fi
  13595. done
  13596. if test "$ax_path_bdb_path_find_highest_ok" = "yes" ; then
  13597. if test "$ax_path_bdb_no_options_ok" = "yes" ; then
  13598. # If we already have an acceptable version use this if higher.
  13599. # Used to indicate true or false condition
  13600. ax_compare_version=false
  13601. # Convert the two version strings to be compared into a format that
  13602. # allows a simple string comparison. The end result is that a version
  13603. # string of the form 1.12.5-r617 will be converted to the form
  13604. # 0001001200050617. In other words, each number is zero padded to four
  13605. # digits, and non digits are removed.
  13606. ax_compare_version_A=`echo "$ax_path_bdb_path_find_highest_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13607. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13608. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13609. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13610. -e 's/[^0-9]//g'`
  13611. ax_compare_version_B=`echo "$BDB_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13612. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13613. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13614. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13615. -e 's/[^0-9]//g'`
  13616. ax_compare_version=`echo "x$ax_compare_version_A
  13617. x$ax_compare_version_B" | sed 's/^ *//' | sort | sed "s/x${ax_compare_version_A}/false/;s/x${ax_compare_version_B}/true/;1q"`
  13618. if test "$ax_compare_version" = "true" ; then
  13619. :
  13620. fi
  13621. else
  13622. # Since we didn't have an acceptable version check if this one is.
  13623. # Used to indicate true or false condition
  13624. ax_compare_version=false
  13625. # Convert the two version strings to be compared into a format that
  13626. # allows a simple string comparison. The end result is that a version
  13627. # string of the form 1.12.5-r617 will be converted to the form
  13628. # 0001001200050617. In other words, each number is zero padded to four
  13629. # digits, and non digits are removed.
  13630. ax_compare_version_A=`echo "$ax_path_bdb_path_find_highest_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13631. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13632. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13633. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13634. -e 's/[^0-9]//g'`
  13635. ax_compare_version_B=`echo "4" | sed -e 's/\([0-9]*\)/Z\1Z/g' \
  13636. -e 's/Z\([0-9]\)Z/Z0\1Z/g' \
  13637. -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \
  13638. -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \
  13639. -e 's/[^0-9]//g'`
  13640. ax_compare_version=`echo "x$ax_compare_version_A
  13641. x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"`
  13642. if test "$ax_compare_version" = "true" ; then
  13643. :
  13644. fi
  13645. fi
  13646. fi
  13647. if test "$ax_compare_version" = "true" ; then
  13648. ax_path_bdb_no_options_ok=yes
  13649. BDB_LIBS="-ldb"
  13650. if test "x$ax_path_bdb_path_find_highest_DIR" != x ; then
  13651. BDB_CPPFLAGS="-I$ax_path_bdb_path_find_highest_DIR/include"
  13652. BDB_LDFLAGS="-L$ax_path_bdb_path_find_highest_DIR/lib"
  13653. fi
  13654. BDB_VERSION="$ax_path_bdb_path_find_highest_VERSION"
  13655. fi
  13656. fi
  13657. fi
  13658. if test "$ax_path_bdb_no_options_ok" = "yes" ; then
  13659. { $as_echo "$as_me:${as_lineno-$LINENO}: using Berkeley DB version $BDB_VERSION" >&5
  13660. $as_echo "$as_me: using Berkeley DB version $BDB_VERSION" >&6;}
  13661. $as_echo "#define HAVE_DB_H 1" >>confdefs.h
  13662. ax_path_bdb_ok=yes
  13663. BDB_CPPFLAGS="-I$ax_path_bdb_INC"
  13664. BDB_LDFLAGS="-L$ax_path_bdb_LIB"
  13665. else
  13666. { $as_echo "$as_me:${as_lineno-$LINENO}: no Berkeley DB version 4 or higher found" >&5
  13667. $as_echo "$as_me: no Berkeley DB version 4 or higher found" >&6;}
  13668. fi
  13669. else
  13670. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13671. $as_echo "no" >&6; }
  13672. { $as_echo "$as_me:${as_lineno-$LINENO}: no usable Berkeley DB not found" >&5
  13673. $as_echo "$as_me: no usable Berkeley DB not found" >&6;}
  13674. fi
  13675. CPPFLAGS="$ax_path_bdb_save_CPPFLAGS"
  13676. LDFLAGS="$ax_path_bdb_save_LDFLAGS"
  13677. fi
  13678. if test "$ax_path_bdb_ok" = "yes" ; then
  13679. BDB_ENABLED="-DUSE_BDB"
  13680. BDB_LIB="$BDB_LDFLAGS $BDB_LIBS"
  13681. BDB_INC="$BDB_CPPFLAGS"
  13682. fi
  13683. fi
  13684. BDB_ENABLED=$BDB_ENABLED
  13685. BDB_LIB=$BDB_LIB
  13686. BDB_INC=$BDB_INC
  13687. # Check whether --with-curl_config was given.
  13688. if test "${with_curl_config+set}" = set; then :
  13689. withval=$with_curl_config;
  13690. else
  13691. with_curl_config=yes
  13692. fi
  13693. if test "$with_curl_config" = "yes"; then
  13694. # Extract the first word of "curl-config", so it can be a program name with args.
  13695. set dummy curl-config; ac_word=$2
  13696. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  13697. $as_echo_n "checking for $ac_word... " >&6; }
  13698. if ${ac_cv_path_CURLCONFIG+:} false; then :
  13699. $as_echo_n "(cached) " >&6
  13700. else
  13701. case $CURLCONFIG in
  13702. [\\/]* | ?:[\\/]*)
  13703. ac_cv_path_CURLCONFIG="$CURLCONFIG" # Let the user override the test with a path.
  13704. ;;
  13705. *)
  13706. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  13707. for as_dir in $PATH
  13708. do
  13709. IFS=$as_save_IFS
  13710. test -z "$as_dir" && as_dir=.
  13711. for ac_exec_ext in '' $ac_executable_extensions; do
  13712. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  13713. ac_cv_path_CURLCONFIG="$as_dir/$ac_word$ac_exec_ext"
  13714. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  13715. break 2
  13716. fi
  13717. done
  13718. done
  13719. IFS=$as_save_IFS
  13720. ;;
  13721. esac
  13722. fi
  13723. CURLCONFIG=$ac_cv_path_CURLCONFIG
  13724. if test -n "$CURLCONFIG"; then
  13725. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CURLCONFIG" >&5
  13726. $as_echo "$CURLCONFIG" >&6; }
  13727. else
  13728. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13729. $as_echo "no" >&6; }
  13730. fi
  13731. elif test "$with_curl_config" = "no"; then
  13732. as_fn_error $? "curl-config is required and cannot be disabled" "$LINENO" 5
  13733. else
  13734. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for curl-config usability in $with_curl_config" >&5
  13735. $as_echo_n "checking for curl-config usability in $with_curl_config... " >&6; }
  13736. if test -x "$with_curl_config"; then
  13737. CURLCONFIG=$with_curl_config
  13738. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13739. $as_echo "yes" >&6; }
  13740. else
  13741. as_fn_error $? "$with_curl_config not found or not executable" "$LINENO" 5
  13742. fi
  13743. fi
  13744. if test -z "$CURLCONFIG"; then
  13745. as_fn_error $? "curl-config utility not found. use --with-curl-config to specify its location." "$LINENO" 5
  13746. fi
  13747. CURL_CFLAGS=`$CURLCONFIG --cflags`
  13748. CURL_LIBS=`$CURLCONFIG --libs`
  13749. MISC_ENABLED=$MISC_ENABLED
  13750. # Write config.status and the Makefile
  13751. ac_config_files="$ac_config_files Makefile.inc nginx/config lib/Makefile apache/Makefile util/Makefile cgi/Makefile"
  13752. # Check whether --with-tokyo-cabinet was given.
  13753. if test "${with_tokyo_cabinet+set}" = set; then :
  13754. withval=$with_tokyo_cabinet;
  13755. else
  13756. with_tokyo_cabinet=no
  13757. fi
  13758. if test $with_tokyo_cabinet == "yes"; then
  13759. TC_ENABLED="-DUSE_TC"
  13760. TC_INC=""
  13761. TC_LIB="-ltokyocabinet"
  13762. else
  13763. TC_ENABLED=""
  13764. TC_INC=""
  13765. TC_LIB=""
  13766. fi
  13767. # Check whether --with-s3 was given.
  13768. if test "${with_s3+set}" = set; then :
  13769. withval=$with_s3;
  13770. else
  13771. with_s3=no
  13772. fi
  13773. if test $with_s3 == "yes"; then
  13774. S3_ENABLED="-DUSE_S3"
  13775. S3_INC=""
  13776. S3_LIB="-ls3"
  13777. else
  13778. S3_ENABLED=""
  13779. S3_INC=""
  13780. S